mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[GH-ISSUE #3321] [Issue]: Game Mode NPC portraits image generation does not use description: 3.0+1.0 This time with actual useful information #1800
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#1800
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @JurijPietrowicz on GitHub (Jul 6, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/3321
Originally assigned to: @SpicyMarinara on GitHub.
Summary
NPC portrait prompts for Game Mode are being compacted too aggressively by the shared image prompt compiler. Important canonical NPC identity details such as species, fur/hair color, clothing, and carried objects are dropped, while generic boilerplate fragments like
body planandsilhouettesurvive.Expected behavior
NPC portrait generation should preserve the GM-created canonical visual description, especially identity-critical details such as species/body type, fur/hair/skin color, garments, accessories, tails/ears/horns/wings, and carried props.
For example, this description:
should produce a prompt that still contains something like:
A robust fix should also pass the entire unaltered canonical description alongside the distilled tags, so downstream image models still receive the full subject identity even when tag extraction misses a detail.
Actual behavior
The compiled provider prompt loses nearly all useful NPC-specific visual identity and keeps mostly generic tags:
Negative prompt:
The issue appears in the portrait compacting path:
packages/shared/src/utils/image-prompt-compiler.tscompileImagePrompt(...)starts the provider prompt pipeline: line 29compactVisualPromptis enabled forportrait,avatar, andspriteunless profile base style isz_image_turbo: lines 46-48deriveTaggedSourceCues(...)only extracts gender/human/age cues, not species or clothing: lines 414-425distillTaggedPromptSource(...)distills source prompt text before splitting: lines 356-412distillVisualPhrases(...)has a narrow visual vocabulary and missesfox-woman,silver-furred,kimono,sleeve, etc.: lines 531-570shouldKeepTaggedSourceFragment(...)rejects fragments containing words likedebt, which can discard visually relevant props such asdebt-scroll: lines 591-605hasVisualCue(...)does not include common non-human/fantasy/clothing cues likefox,kitsune,fur,kimono,tail, etc.: lines 608-612Related Game Mode prompt construction:
packages/server/src/services/game/game-asset-generation.tsbuildNpcAppearanceLine(...)creates the canonical appearance line: lines 359-374npcPortraitVariables(...)detects explicit non-human cues and adds non-human preservation instructions: lines 376-389buildNpcPortraitProviderPrompt(...)builds the raw prompt, optionally runs dynamic prompt generation, then compiles it: lines 460-481compileGameImagePrompt(...)calls the sharedcompileImagePrompt(...): lines 488-518packages/server/src/routes/game.routes.tsresolveNpcPortraitAppearance(...)merges canonical NPC description, request description, present-character appearance/outfit/mood, and notes: lines 3886-3910/game/generate-assets/previewbuilds the compiled review prompt: lines 10671-10705/game/generate-assetscallsgenerateNpcPortrait(...): lines 11090-11119packages/server/src/services/prompt-overrides/registry/game-assets.tsGAME_NPC_PORTRAITdefault prompt builder: lines 32-71Steps to reproduce
z-image-turbo.Environment
Logs, screenshots, or video
Observed compiled positive prompt:
Observed negative prompt:
The raw NPC description contains
silver-furred fox-woman,persimmon kimono, anddebt-scroll tucked in her sleeve, but these are absent from the final provider prompt.Additional context
Suggested fix:
distillVisualPhrases(...)/hasVisualCue(...)to recognize non-human and fantasy avatar cues:fox,kitsune,fur,furred,tail,ears,horns,wings,kimono,sleeve,scroll, etc.Temporary workaround: select the
z-image-turbostyle profile because the normal portrait compacting path is where the identity loss occurs. However, it creates another issue as the prompt then doesn't fit in the 1400-character limit.Template check
@SpicyMarinara commented on GitHub (Jul 7, 2026):
Codex is picking this up for the v2.1.1 issue sweep in draft PR #3331.
@SpicyMarinara commented on GitHub (Jul 7, 2026):
Fixed in PR #3331 and merged to staging for v2.1.1. Thank you for the report.