WordAI tier maintenance notes

- `feature-flags.json` is the central runtime registry for free vs pro availability and limits.
- `basic-features.json` and `pro-features.json` describe the visible product comparison copy and module grouping.
- `feature-comparison-ui.json` controls the Get Pro page hero cards, comparison table groups, and limited-feature cards.

Current free-tier rules

- Providers: OpenAI, Google Gemini, Anthropic Claude, and xAI Grok are available in free.
- Content settings: free keeps a curated subset of writing styles, tones, title lengths, paragraph counts, excerpt lengths, and tag counts.
- Image settings: free allows 1 generated image per request. Higher counts stay visible but locked.
- AI Agent: free uses the real AI Agent workflow with a global basic-tier embedded content limit across all providers, not a separate limit per provider.

Implementation notes

- Runtime clamping lives in `includes/class-sftcy-wordai-features.php`.
- Shared settings loaders in `includes/class-sftcy-wordai-base.php` apply the tier clamps on read.
- Free admin save handlers also apply the tier clamps on write so UI locks are not the only guard.
- Free AI Agent embedding limits are enforced in `includes/class-sftcy-wordai-openai-agent-ajax.php`.
- API Settings streaming is provider-aware: OpenAI can expose the checkbox only for compatible non-Responses models; Google Gemini, Anthropic Claude, and xAI Grok are intentionally locked to the stable non-streaming request path.

Sync rules

- If a feature is allowed in both free and pro, update both plugin codebases when that feature changes.
- If a feature is pro-only or limited in free, keep the Pro UI as the source layout and apply free locks inside the same view instead of building alternate pages.
- When changing limits, update the registry JSON and the related screen copy together so the Get Pro page stays accurate.

Provider model maintenance notes

- `includes/class-sftcy-wordai-openai.php` is the source for OpenAI text + image model dropdowns.
- `includes/class-sftcy-wordai-google-gemini-settings.php` is the source for Gemini text + image model dropdowns and normalization helpers.
- `includes/class-sftcy-wordai-anthropic-api.php` is the source for Claude model dropdowns and defaults.
- `admin/views/submenus-image-settings.php` must only expose settings rows that correspond to currently selectable models. Do not leave deprecated DALL·E-only rows active after removing those models from the dropdown.
- `includes/class-sftcy-wordai-base.php` should normalize removed or shut-down provider model slugs on read so old saved settings do not leave users on invisible broken models.
- `SftcyWordaiBase::sc_wordai_get_ai_providers()` is also the provider capability source. Keep `streaming => false` for providers that the backend forces through non-streaming paths.

2026-04-13 provider sync update

- OpenAI image UI now uses GPT Image models only. DALL·E 2 / DALL·E 3 rows were removed from active Free + Pro image settings views.
- Gemini text model lists were cleaned to current 2.5 stable models plus current preview entries, and deprecated 2.0 / shut-down preview options were removed from active dropdowns.
- Gemini text + image settings now normalize stale saved model slugs before the UI or request builder uses them.
- Anthropic defaults were moved to Claude Sonnet 4.6 while keeping older 4.x models available in compatibility groups.

2026-04-28 OpenAI model sync update

- OpenAI text dropdowns in Free + Pro now include `gpt-5.5` at the top of the frontier model group.
- OpenAI image dropdowns in Free + Pro now include `gpt-image-2` labeled as ChatGPT Images 2.0 / GPT Image 2.
- `gpt-image-2` is allowed in image setting normalization and uses the existing GPT Image request path with size and quality options.
- `gpt-image-1.5` remains the default OpenAI image model so image generation works immediately for users without GPT Image 2 organization verification.

2026-06-24 provider image model sync update

- Anthropic Claude still supports image input / vision workflows but does not provide a native image-generation output API like OpenAI or Gemini. Keep Claude out of image-generation routing unless Anthropic releases an official image-output API.
- OpenAI image model support remains `gpt-image-2`, `gpt-image-1.5`, `gpt-image-1`, and `gpt-image-1-mini`; keep `gpt-image-1.5` as the default because newer GPT Image models can require organization verification.
- Gemini image dropdowns in Free + Pro now expose `gemini-3.1-flash-image`, `gemini-3-pro-image`, and legacy `gemini-2.5-flash-image`. Gemini 3 image models route through the Gemini Interactions API, while Gemini 2.5 stays on the existing Generate Content compatibility path.
- Gemini 3 Interactions image requests must send `response_format.mime_type` as `image/jpeg`; the endpoint rejected `image/png` during live smoke testing. The legacy Gemini 2.5 path can keep the existing MIME setting behavior.
- Image Settings now show model-aware output format choices: Gemini 3 shows only JPEG, legacy Gemini image models can show PNG/JPEG/WEBP, and OpenAI GPT Image models expose PNG/JPEG/WEBP through `output_format`.
- Old Gemini image preview slugs normalize to their current stable equivalents so existing saved settings do not break after plugin updates.

2026-05-21 AI Agent model sync update

- `SftcyWordaiOpenai::$MODEL` is now `gpt-5.4-mini`; this is the shared default for OpenAI API Settings and AI Agent Chat.
- AI Agent Chat dropdowns use the same provider model registries as API Settings: `openai_models()`, `gemini_models()`, and `anthropic_models()`.
- The Contents Embedding `Scan & Estimate` card is hidden in the view, not deleted, while Start Indexing now explains that indexed content powers frontend AI Chat answers.
- The content-type selector now lives above the visible embedding cards as a global dropdown, while keeping `.wa-cpt` checkbox values so the backend `post_types[]` flow and free/basic embedding item limits remain unchanged.
