Fix duplicate image, remove hardcoded model references
Three fixes in one: 1. Duplicate image: prepend_caption_to_post() was embedding the full image + caption as a <figure> block, but the theme already displays the featured image. Now only the caption text is prepended — no second copy of the image. 2. Hardcoded model names: removed all FLUX.1/FLUX.2 references from model-agnostic code (pipeline, prompt builder, sideloader, OpenRouter provider, interface, admin labels). The Cloudflare provider still references FLUX since it specifically wraps that model family. 3. Test alignment: OpenRouterImagePricingTest was asserting against removed models (flux-2-pro, seedream). Updated to match current COST_PER_IMAGE entries (Gemini Flash, GPT-5 Image). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -54,8 +54,9 @@ define( 'PRAUTOBLOGGER_DEFAULT_WRITING_MODEL', 'google/gemini-2.5-flash-lite' );
|
||||
define( 'PRAUTOBLOGGER_DEFAULT_EDITOR_MODEL', 'google/gemini-2.5-flash-lite' );
|
||||
|
||||
// Image generation defaults.
|
||||
// Default provider is OpenRouter (higher quality); Cloudflare is the fallback.
|
||||
// Default model is FLUX.2 Pro via OpenRouter (~$0.03/image, good quality).
|
||||
// Default provider is OpenRouter; Cloudflare is the fallback.
|
||||
// Default model is Gemini 2.5 Flash Image ($0.005/image, good for comics).
|
||||
// User can override via Settings → Images → Image Model.
|
||||
define( 'PRAUTOBLOGGER_DEFAULT_IMAGE_PROVIDER', 'openrouter' );
|
||||
define( 'PRAUTOBLOGGER_DEFAULT_IMAGE_MODEL', 'google/gemini-2.5-flash-image' );
|
||||
|
||||
|
||||
Reference in New Issue
Block a user