mirror of
https://github.com/Pasta-Devs/Marinara-Agents.git
synced 2026-12-03 18:55:07 +07:00
[GH-ISSUE #675] [Bug]: Slurp discards character appearance and art style from image prompts #348
Labels
No labels
agent: chess
agent: conversation-calls
agent: eightball
agent: haptic
agent: hierarchical-maps
agent: hierarchical-maps
agent: illustrator
agent: poker
agent: rock-paper-scissors
agent: tic-tac-toe
agent: uno
artifacts
bug
bugfix
build
catalog
ci
client
dependencies
docs
documentation
enhancement
feature
fixed-in-staging
in-pr
normal-scope
packages
pull-request
qol
regression
roadmap
scope-risk
server
soup
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Agents#348
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 @Gunterlie on GitHub (Sep 1, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Agents/issues/675
Summary
Slurp drops the configured art style and the character appearance from the final image prompt. The leak guard that keeps private context out of provider prompts discards the whole rewritten prompt when the rewriter reproduces the guidance text, and the fallback is the bare draft prompt, which contains neither the style nor the appearance.
Reported by two users: constant loss for one, occasional style drift for another. The difference is explained below.
Root cause
selectNoodleImageProviderPrompt()inpackages/slurp/src/engine/packages/server/src/services/slurp/slurp-image-prompt.ts:8rejects the rewritten prompt when it contains anyprivateContextentry as a substring:Both call sites put
styleGuidanceinto that list:slurp-images.service.ts:222-228slurp-public-images.service.ts(same block)At the same time, the rewriter is explicitly instructed to apply that guidance —
slurp-image-prompt-rewrite.ts:71-75:So the feature fights itself. The rewriter is told to use the style guidance; the guard then throws the result away for having used it. The fallback
rawProviderPromptisinput.draftPrompt, which has never had appearance or style applied — which is why both are lost together.Why it is intermittent
The match is on the full guidance string. A rewriter that paraphrases survives; one that copies the phrase verbatim is discarded. Weaker local models copy verbatim far more often, which matches the report from a Gemma user seeing it constantly versus another user seeing three bad generations in one day.
Verified against the real function:
The third line is the important one for users. A short entry in Image generation instructions such as
anime styleis 11 characters, comfortably over thelength > 1floor, and will appear verbatim in almost any prompt that honours it. That entry is always discarded. This is exactly the workaround one user reported as no longer working: putting art-style text into the guidance field guarantees the rewrite is thrown away.Impact
Suggested fix
styleGuidanceis content that is meant to appear in the output. It does not belong inprivateContext. The same argument applies tocharacterImageInstructions, which is authored to steer the image.privateContextto genuinely private values:configuredImageInstructions,connectionImageInstructions, andcharacterPersonality.includes()test with a whole-block match, so a short user phrase cannot poison every prompt. ThehasInternalMarkerregex already covers the real leak shape — labelled blocks and tags — and should stay.Test that locks in the current behaviour
tests/slurp-image-instructions.regression.ts:26asserts the discard:Any fix must update this case. The neighbouring leak cases (
<art_style_guidance>tags,Character image preferences:labels) are correct and should be kept — those are true leaks of internal scaffolding, whereas an applied style phrase is the intended output.Affects
Slurp 1.0.20 onward. The guard was introduced in
64e76670"fix(slurp): keep image provider prompts visual-only".See also the review-modal bypass, which loses the same two things by a different mechanism.
@Gunterlie commented on GitHub (Sep 1, 2026):
Scope correction.
The original report that prompted this issue bundled two complaints: the review modal's text being broken, and appearance/style not reaching the prompt. Those are separate defects with separate causes.
The broken text is #677 — ten localization keys used by
ImagePromptReviewModalare missing from the package catalog, so the modal renders raw key names. That is a shared Engine component, so it affects Noodle too.This issue is only about the prompt content. The two are independent: fixing #677 will make the modal readable, and it will then legibly display a prompt that is still missing the appearance and the style.
@Gunterlie commented on GitHub (Sep 1, 2026):
Runnable reproduction — drop in a file and run with
npx tsx. No fixtures, no Engine boot needed;selectNoodleImageProviderPromptis pure.Observed output:
false / false / true.The middle case is the important one for the fix.
normalizedValue.length > 1is the only floor, so any short user-authored instruction —anime styleis 11 characters — appears verbatim in every prompt that honours it and poisons every generation. Whatever replaces the substring test must not have this property.Note the intermittency in the third case explains the two different user reports against this issue: a user on a model that paraphrases sees occasional style drift, a user on a model that copies verbatim sees it fail constantly.
@Gunterlie commented on GitHub (Sep 1, 2026):
Fix opened as draft #683.