Skip to content

Noodle post images render in the wrong art style — no style-interpretation pass (Conversation selfies have one, Noodle doesn't) #4764

Description

@Gunterlie

Diagnosed by DSBwizzard (Release v2.4.2, build 28d16cb), via Prof. Mari.

Root cause

The two pipelines infer image style completely differently:

  • Conversation selfies run a text-LLM pass that builds the image prompt. Its system prompt (packages/server/src/services/prompt-overrides/registry/conversation.ts:75) explicitly instructs: "Infer the appropriate art style from the character… anime/game characters should use anime/illustration style, realistic characters should use photorealistic style." The character's appearance/personality/image-instructions and the active Style Profile's guidance are fed to that LLM, so style is woven in organically. The subsequent compileImagePrompt call sets omitProfileStyleText/omitProfileSubjectTags: true to avoid duplicating it.
  • Noodle post images have no equivalent LLM step. An upstream authoring LLM emits a draftPrompt; NOODLE_IMAGE_POST (packages/server/src/services/prompt-overrides/registry/noodle.ts) concatenates raw strings (draftPrompt + appearance + personality + image instructions); that goes to the image model verbatim via compileImagePrompt({ kind: "illustration" }). No art-style inference ever runs. On baseStyle: "auto" profiles the compiler contributes no style text either, so nothing pushes the image toward the character's art style.

User impact

  • Anime/cartoon/stylized characters get correct-style selfies but photorealistic Noodle posts — broken visual consistency.
  • Per-character characterImageInstructions are interpreted intelligently in selfies but dumped as trailing raw text in Noodle, where they compete weakly against the clean draftPrompt.
  • Only workaround today is manually editing the Noodle image override to prepend art-style tags — global, no per-character granularity.

Fix (agreed direction)

Add a shared style-interpretation LLM pass at the Noodle image-service choke point (both noodle-noodler-images.service.ts and noodle-public-images.service.ts), right before compileImagePrompt — the structural mirror of the selfie pipeline. Both services already load the character context; running the pass downstream fixes every Noodle surface (public + NoodleR + generated-activity) at once, regardless of which upstream authored the draftPrompt.

  • Reuses resolveIllustratorPromptRuntime, resolveImageStyleGuidanceText + formatImageStylePromptGuidance, and the selfie's omitProfileStyleText/omitProfileSubjectTags compile pattern.
  • New editable prompt-override key noodle.imageInterpret carrying the art-style-inference instruction (ported from conversation.ts:75), worded to defer to an explicitly specified style so it doesn't fight a non-auto profile.
  • New Noodle setting enableImageInterpretation, default on, with graceful fallback: if the pass errors/times out or the prompt connection can't resolve, compile the raw prompt as today so image generation never blocks.

Manual verification

  • Anime / auto-profile character: selfie and Noodle post now match style (incl. a NoodleR post).
  • Non-auto explicit profile: Noodle honors it; inference does not override it.
  • Fallback: invalid prompt connection or toggle off → images still generate, one warn logged, no crash.
  • Preview/review flow shows the interpreted prompt, not raw concatenation.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions