== Full Changelog ==

= 4.1.1 =
* Keyword Groups now pick **one** keyword at random per generated post instead of mashing every keyword into a single article. A "Chemistry" group with ten keywords becomes a queue of ten focused topics rather than one over-broad post.
* New `{keyword}` template placeholder holds the keyword chosen for the current post; `{keywords}` still renders the full comma-separated group for templates that want it. The default template now uses `{keyword}` so existing setups get the focused behavior automatically.
* Generation tracking meta records which keyword was selected; the post-editor meta box now shows the focus keyword alongside the source group.
* Fixed: the Default Template now displays its prompt body in a read-only textarea on the Content settings page instead of an empty placeholder.

= 4.1.0 =
* WP 7.0 Connectors API integration now works correctly (previously broken hook and registry calls removed)
* Admin notice shown when WordPress has AI disabled at site level (WP 7.0)
* Claude models refreshed: Sonnet 4.6 and Opus 4.7 (1M token context window each)
* Connections tab shows read-only legacy key reference when WP Connector is active for a provider
* Contextual "Learn more" links added to API Keys, Scheduling, and Bulk Generate sections
* ~1.9 MB runtime reduction: Gemini SDK replaced with direct wp_remote_post() calls, Composer vendor removed from runtime

= 4.0.1 =
* Fixes to "Validate" button for API keys
* Adding documentation URL to the dashboard

= 4.0.0 =
The biggest settings redesign since launch. Everything is easier to find, the dashboard tells you what's happening without digging, and settings that used to feel buried now live exactly where you'd look for them.

**A real dashboard, finally.**
The plugin now opens to a dashboard instead of a blank settings form. You can see your scheduling status at a glance, check the last few generation jobs without leaving the page, and get to common actions in one click. Provider health is summarized right there — green/yellow/red, with timestamps so you know if a key was last verified today or a week ago.

**Settings that make sense.**
The old flat tab layout is gone. Settings are now split into five focused sections: Content (keywords, templates, writing style), Media (images, audio, infographics), Connections (API keys and scheduling), Settings (post types, permissions, advanced), and the Dashboard. Everything that previously required hunting through a long page now has its own tab.

**Changes that save themselves.**
Toggles and sliders across the settings pages now save automatically as you adjust them, with a small "Saved" confirmation. No more scrolling to the bottom to hit a save button after every change. Fields that affect scheduling still require an explicit save (and warn you if you leave without saving).

**Per-role access control.**
You can now control which WordPress roles can access AI generation tools. Authors, editors, or just administrators — your call. Administrators are always enabled and can't be unchecked.

**Provider health checks run daily.**
The plugin now runs a background health check on your connected providers once a day and caches the result. The dashboard shows the freshness of each check so you know whether a "connected" status is from this morning or three days ago.

**Debug mode and settings export.**
The Advanced tab now has a one-click debug logging toggle (no more editing wp-config.php for basic troubleshooting) and a JSON export button so you can back up or migrate your settings.

= 3.8.0 =
Upgrades used to feel like a gamble — would your API keys survive? Would your keyword groups vanish? Not anymore.

Settings now follow a versioned migration path. When you update the plugin, it checks your current settings, upgrades what needs upgrading, and shows you a confirmation notice when it's done. Your API keys, keyword groups, content templates, and selected models all carry over cleanly.

All five AI providers (OpenAI, Claude, Gemini, Perplexity, Stability AI) are now defined in a single registry. Adding or changing providers no longer requires touching five different parts of the code — everything cascades from one source of truth.

= 3.7.0 =
Generation used to freeze the browser while it ran. Now it queues in the background and you can watch it happen.

Every content job — manual, bulk, scheduled, or regenerated — runs through a background queue. A live log shows status, the model used, keywords, how long it took, and a direct link to the post when it's done. If something fails, you get the error message and a one-click link to report it.

= 3.6.0 =
Two things that SaaS tools charge extra for, now built in.

WordPress 7.0 Connectors support: if your site already has API keys set up through the new WordPress Connectors screen, the plugin finds and uses them automatically. No re-entry. On WordPress 6.x, everything works the same as before.

Bulk generation: paste a list of keywords (or upload a .txt file), pick a template and model, and the plugin generates all the posts sequentially as drafts. Progress updates live. The kind of workflow most autoblogging SaaS platforms charge $99/month for.

= 3.5.0 =
RankMath SEO integration. Keyword groups with per-group categories and templates. A content template system with placeholders (`{keywords}`, `{title}`, `{tone}`, and more). One-click regeneration from the content history. All post-editor AI tools consolidated into a single meta box.

= 3.4.0 =
* Added:
  - **Inline API Key Validation**: Real-time verification for all AI providers directly from Advanced Settings. Displays "Verified" or "Failed" status and stores last validation result.
  - **Model Cost Transparency**: Each AI model now displays an estimated cost per post based on current token rates. Includes a new `abcc_model_cost_estimate` filter for advanced users.
  - **Advanced Image Controls**: Expanded size and quality options for OpenAI (DALL-E 3) and resolution presets for Stability AI.
  - **Automatic Image SEO**: Featured images now automatically receive SEO-optimized alt text in the format `{post title} - {primary keyword}`.
* Updated:
  - **Scheduling Clarity**: Raw timestamps replaced with human-friendly text (e.g., "Next post in 6 hours") and a direct link to scheduling settings.
  - **Contextual Help**: Added Dashicon-based tooltips for Keywords, Tone, Models, and API keys to explain settings without cluttering the UI.
  - **SEO Reliability**: Refactored the title and metadata generator to use structured JSON parsing and site-specific context (`site_info`).
  - **RankMath Integration**: Enhanced support with initial field mapping for Social Excerpts and focus keywords.
* Fixed:
  - Fixed minor bugs and improved overall stability.

= 3.3.0 =
* Added:
  - **Perplexity AI Integration**: Full support for web-grounded content generation with source citations. Three new models: Sonar, Sonar Pro, and Sonar Reasoning Pro. Configurable citation styles (inline, references section, or both) and source recency filters.
  - **Draft-First Workflow**: New option to always save generated content as drafts for review before publishing.
  - **Content History Log**: Track generated posts, models used, and publish status directly from Content Settings.
* Updated:
  - Keywords input is now a textarea supporting one topic per line.
  - Renamed "Max Token Limit" to "Content Length" with explanatory tooltip; updated writing tone labels.
  - Rebuilt "About" tab — focused on plugin philosophy and professional consulting services.
* Fixed:
  - Fixed several internal bugs and onboarding improvements.

= 3.2.0 =
* Added:
  - **Gemini Nano Banana Image Generation**: Native Google image generation with configurable sizes (1K, 2K, 4K) and smart fallback chain.
  - **OpenAI o-series Reasoning Models**: Support for o4-mini and proper routing for non-"gpt-" model names.
* Updated:
  - All models updated to latest versions: GPT-4.1 family, Claude 4.5 family, Gemini 2.5 family.
  - Added 1M token context window support for GPT-4.1 models.
* Fixed:
  - Fixed several internal bugs affecting Gemini model routing and image generation.

= 3.1.0 =
* Added:
  - **Complete Onboarding Experience**: 3-step setup with goal-based configuration, visual model selection, interactive API key testing, and automated first post generation.
* Fixed:
  - Fixed several internal bugs.

= 3.0.0 =
* Added:
 - Complete Admin Interface Redesign: New tabbed interface with dedicated sections for Content Settings, Advanced Settings, AI Models, Audio Transcription, and About
 - Audio Transcription Feature: Full OpenAI Whisper integration for converting audio files to blog posts
   - Support for multiple audio formats (MP3, WAV, M4A, WebM, FLAC, MP4)
   - Language selection for transcription
   - Two-step process: transcribe-only or transcribe-and-create-post
   - Audio player embedded in generated posts
 - AI Infographic Generation: Create visual infographics from blog post content using AI
   - Analyzes post content to generate visual descriptions
   - Creates professional infographics using DALL-E or Stability AI
   - Saves directly to WordPress Media Library
 - Enhanced Model Selection Interface: Visual model cards with cost indicators
   - Interactive card-based selection instead of dropdown
   - Clear cost tier indicators (Economy/Standard/Premium)
 - Smart Post Type Selection: Configure which post types show AI content tools
 - Advanced Admin Buttons:
   - "Create AI Post" button on post list screens
   - "Rewrite with AI" button in post editor
   - "Create Infographic" button for existing posts
 - Enhanced Error Handling: More detailed error messages and logging throughout

* Updated:
 - Model Offerings Updated:
   - OpenAI: Added GPT-4 Turbo Preview, updated model descriptions
   - Claude: Updated to Claude 3.5 Haiku, Claude 3.7 Sonnet, and Claude Sonnet 4
   - Gemini: Added Gemini 2.0 Flash, Gemini 1.5 Pro Latest, and Gemini 2.5 Pro Preview
 - Content Generation Flow: Improved prompt engineering for better content structure
 - Token Handling: Enhanced token calculation and management across all AI models
 - Admin Scripts: Completely refactored JavaScript for better user experience
 - CSS Styling: Modern, responsive design with improved visual hierarchy

* Fixed:
 - Model Compatibility: Better backward compatibility for existing model selections
 - Content Formatting: Better HTML structure and block generation
 - SEO Integration: Enhanced metadata generation and validation
 - Performance: Optimized AJAX calls and reduced redundant API requests

* Technical Improvements:
 - Code Organization: Better file structure and separation of concerns
 - WordPress Standards: Improved adherence to WordPress coding standards
 - Documentation: Enhanced PHPDoc comments and inline documentation
 - Accessibility: Better keyboard navigation and screen reader support
 - Internationalization: Improved translation readiness throughout the plugin

= 2.1 =
* Added:
  - Advanced Token Management: Better control over content length with intelligent token allocation across different AI models
  - SEO Integration: Automatic generation of SEO metadata with direct Yoast SEO plugin support
  - Improved Content Structure: Enhanced HTML output with proper heading hierarchy
  - Real-time Token Feedback: See estimated token usage before generating content
  - More Reliable AI Integration: Better error handling and model compatibility

* Changed:
  - Refactored content generation for better HTML structure
  - Improved model context window handling for each AI service
  - Enhanced error handling and logging system
  - Better prompt management for consistent output
  - Updated admin interface with token usage indicators

* Fixed:
  - Content formatting issues with HTML tags
  - Token limit calculation accuracy
  - Model selection and API handling edge cases
  - SEO metadata integration reliability
  - HTML structure validation and sanitization

= 2.0 =
* Added:
  - Claude 3 AI model integration (Haiku, Sonnet, and Opus)
  - Enhanced image generation with DALL-E 3
  - Stability AI integration as fallback
  - Cost-aware model selection interface
  - Better security features

* Changed:
  - Refactored code for better maintainability
  - Improved API handling architecture
  - Enhanced content generation quality

* Fixed:
  - Various bug fixes and improvements
  - Better error handling
  - Enhanced stability

= 1.9 =
* Added:
  - Support for selecting GPT-3.5, GPT-4 and GPT-4o models for content generation
  - Users of the old GPT-3.5 won't be affected by the change as there is backwards compatibility
  - Enhanced plugin settings UI for better user experience and clearer model selection

* Fixed:
  - Code refinements for better modularity and maintainability
  - Comprehensive error handling and logging
  - Updated documentation to guide users through new features and configurations

= 1.6 =
* Fixed:
  - Select2 integration
  - Tone Select keeping custom value saved

* Added:
  - Minor description of some options

= 1.5 =
* Changed:
  - Code linting and cleanup
  - Better form usability
  - Minor quality of life changes

= 1.4 =
* Added:
  - Gemini API — Now you can use Google AI to create your posts!
  - A tone selector so you can define how the post should be written

* Changed:
  - Now it's possible to use wp-config variables to store the OpenAI and GeminiAI API keys
  - The admin menu and form was remade for easier navigation
  - Minor changes for better usage

= 1.0 =
* Added:
  - Implemented image generation using OpenAI's DALL-E model
  - Option to select categories for posts
  - Email notifications when a new post is created automatically

* Changed:
  - Refactored code for better readability and maintainability
  - Updated UI/UX for the settings page
  - Better scheduled post generation (hourly, daily, weekly)
  - Revised error handling and logging

* Fixed:
  - Resolved issues related to API key validation and error handling
  - Fixed bugs reported by users in the previous version

= 0.9 =
- Bug fixes and quality of life updates

= 0.8 =
- WordPress Review Guidelines fixes

= 0.5 =
- Initial release
