[GH-ISSUE #1298] [Issue]: Illustrator Agent leaks the full character description into the positive image prompt when "Send avatars as reference images" is enabled #640

Closed
opened 2026-10-20 17:31:08 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @GetBeholder on GitHub (May 26, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1298

Originally assigned to: @SpicyMarinara on GitHub.

Summary

With "Send character & persona avatars as reference images" enabled, the
Illustrator Agent appends the complete character description into the positive
image prompt sent to ComfyUI (I2I workflow), producing weird/corrupted image
generations. With the option disabled, the agent provides only the (clean) image
prompts and generation behaves normally. The reporter isolated that the same agent
prompt is used in both cases — the description leak occurs only when
avatar-as-reference is enabled. Replicable in 1.6.0 and 1.6.1; no workaround found.

Expected behavior

When avatars are sent as reference images, only the avatar image(s) should be
attached as references; the agent's concise generated image prompt should be sent
as the positive prompt. The full character card description/definition should not
be concatenated into the positive prompt.

Actual behavior

Enabling avatar-as-reference causes the full character description to be appended
to the positive image prompt (in addition to attaching the avatar), corrupting
generation. Disabling it yields clean prompts and normal generation.

Steps to reproduce

  1. Configure a ComfyUI I2I workflow that uses the %reference_image% placeholder.
  2. Enable the Illustrator Agent's "Send character & persona avatars as reference
    images."
  3. Trigger illustration (RP/Convo selfie).
  4. Inspect the positive prompt sent to ComfyUI → it contains the complete
    character description, producing weird images.
  5. Disable the option → the prompt is clean and generation is normal.

Impact area

  • App shell, navigation, startup, or providers
  • Catalog resources
  • Chat mode
  • Roleplay mode
  • Game mode
  • Shared mode UI
  • Runtime systems: generation, world-state, visuals, tracker, or haptics
  • Professor Mari or shell tools
  • React-free engine behavior, contracts, agents, or capability ports
  • Shared API wrapper or remote runtime routing
  • Tauri/Rust storage, assets, LLM, integrations, security, imports, or HTTP runtime
  • Docs, contributor workflow, or templates

Environment

  • Branch or commit: v1.6.1 (also reproduced on v1.6.0), Build 3663484
  • Run mode: Linux / Docker
  • OS + version: Linux (Docker)
  • Node + pnpm versions: not provided
  • Rust version, if relevant: not provided
  • Remote Runtime URL configured? Docker runtime
  • Provider, model, or integration, if relevant: ComfyUI (I2I workflow), %reference_image% placeholder

Logs, screenshots, or video

None provided. A captured positive prompt showing the appended character
description would confirm.

Regression notes

Present in both 1.6.0 and 1.6.1 (the reporter tested from 1.6.0). Last known good
build unknown.

Additional context

Source: forum thread by m;aemoifmpfmmafe (2-Star), 5/23/26 11:38 PM, with
clarification 5/24/26 9:04 AM and maintainer Marinara [MARI] engagement. The
reporter's clarification: the agent prompt is identical in both cases; the
description leak only happens with avatar-as-reference on; and users have no
control over the RP/Convo selfie prompts (tracked separately as a preview/edit
feature gap). Related to reference-image handling for ComfyUI in #1275.

Triage pointer (from a scan, not from the reporter): the Illustrator Agent prompt
(src/engine/contracts/constants/agent-prompts.ts, ~L211/L215) instructs the
agent to (a) output a characters array used to attach each character's/persona's
avatar as a reference, and (b) include full physical descriptions in the prompt.
The reporter isolated that the FULL character DEFINITION is concatenated into the
positive prompt only when avatar-as-reference is enabled — suggesting the
reference-image path (resolving the characters array → avatars in the
selfie/illustrator image command, src/engine/generation/connected-commands.ts,
e.g. buildSelfiePrompt, which already reads appearance/description) also
injects the character description text into the positive prompt. It should attach
the avatar image without appending the description text.

Template check

Please uncheck the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @GetBeholder on GitHub (May 26, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1298 Originally assigned to: @SpicyMarinara on GitHub. ## Summary With "Send character & persona avatars as reference images" enabled, the Illustrator Agent appends the complete character description into the positive image prompt sent to ComfyUI (I2I workflow), producing weird/corrupted image generations. With the option disabled, the agent provides only the (clean) image prompts and generation behaves normally. The reporter isolated that the same agent prompt is used in both cases — the description leak occurs only when avatar-as-reference is enabled. Replicable in 1.6.0 and 1.6.1; no workaround found. ## Expected behavior When avatars are sent as reference images, only the avatar image(s) should be attached as references; the agent's concise generated image prompt should be sent as the positive prompt. The full character card description/definition should not be concatenated into the positive prompt. ## Actual behavior Enabling avatar-as-reference causes the full character description to be appended to the positive image prompt (in addition to attaching the avatar), corrupting generation. Disabling it yields clean prompts and normal generation. ## Steps to reproduce 1. Configure a ComfyUI I2I workflow that uses the `%reference_image%` placeholder. 2. Enable the Illustrator Agent's "Send character & persona avatars as reference images." 3. Trigger illustration (RP/Convo selfie). 4. Inspect the positive prompt sent to ComfyUI → it contains the complete character description, producing weird images. 5. Disable the option → the prompt is clean and generation is normal. ## Impact area - [ ] App shell, navigation, startup, or providers - [ ] Catalog resources - [ ] Chat mode - [ ] Roleplay mode - [ ] Game mode - [ ] Shared mode UI - [x] Runtime systems: generation, world-state, visuals, tracker, or haptics - [ ] Professor Mari or shell tools - [x] React-free engine behavior, contracts, agents, or capability ports - [ ] Shared API wrapper or remote runtime routing - [ ] Tauri/Rust storage, assets, LLM, integrations, security, imports, or HTTP runtime - [ ] Docs, contributor workflow, or templates ## Environment - Branch or commit: v1.6.1 (also reproduced on v1.6.0), Build 3663484 - Run mode: Linux / Docker - OS + version: Linux (Docker) - Node + pnpm versions: not provided - Rust version, if relevant: not provided - Remote Runtime URL configured? Docker runtime - Provider, model, or integration, if relevant: ComfyUI (I2I workflow), `%reference_image%` placeholder ## Logs, screenshots, or video None provided. A captured positive prompt showing the appended character description would confirm. ## Regression notes Present in both 1.6.0 and 1.6.1 (the reporter tested from 1.6.0). Last known good build unknown. ## Additional context Source: forum thread by m;aemoifmpfmmafe (2-Star), 5/23/26 11:38 PM, with clarification 5/24/26 9:04 AM and maintainer Marinara [MARI] engagement. The reporter's clarification: the agent prompt is identical in both cases; the description leak only happens with avatar-as-reference on; and users have no control over the RP/Convo selfie prompts (tracked separately as a preview/edit feature gap). Related to reference-image handling for ComfyUI in #1275. Triage pointer (from a scan, not from the reporter): the Illustrator Agent prompt (`src/engine/contracts/constants/agent-prompts.ts`, ~L211/L215) instructs the agent to (a) output a `characters` array used to attach each character's/persona's avatar as a reference, and (b) include full physical descriptions in the prompt. The reporter isolated that the FULL character DEFINITION is concatenated into the positive prompt only when avatar-as-reference is enabled — suggesting the reference-image path (resolving the `characters` array → avatars in the selfie/illustrator image command, `src/engine/generation/connected-commands.ts`, e.g. `buildSelfiePrompt`, which already reads `appearance`/`description`) also injects the character description text into the positive prompt. It should attach the avatar image without appending the description text. ## Template check Please uncheck the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-10-20 17:31:08 +07:00
  • closed this issue
  • added the
    shared
    bug
    labels
Author
Owner

@SpicyMarinara commented on GitHub (May 27, 2026):

Fixed on refactor in 8058f66dd4: the Illustrator prompt now forbids pasting full character/persona prose into image prompts and limits character wording to visual traits, especially when avatar reference images are attached. Validated with pnpm check.

<!-- gh-comment-id:4555717056 --> @SpicyMarinara commented on GitHub (May 27, 2026): Fixed on refactor in 8058f66dd4affb1e74e4bdbce3b7d4580554fb9b: the Illustrator prompt now forbids pasting full character/persona prose into image prompts and limits character wording to visual traits, especially when avatar reference images are attached. Validated with pnpm check.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#640
No description provided.