ComfyUI Node
SF Claude Prompt Coach
Shows Claude a system prompt together with what it produced — the generated prompt, the reference images, the result and your feedback — and returns an improved system prompt. Runs on your Claude Code login and remembers earlier rounds of the same session.
SF Claude Prompt Coach
- images
- system_prompt
- analysis
- session_id
- log_file
◄system_prompt►
◄generated_prompt►
◄feedback►
◄image_notes►
◄session_nameprompt-coach►
◄modelopus►
◄coach_system_promptYou are a prompt engineer coaching a system prompt for a game-art pipeline.
In that pipeline an LLM (the "prompt writer") is given the SYSTEM PROMPT UNDER TEST plus a brief, and
sometimes an asset library. It writes a prompt for an image generation model and may pick reference
images to send with it. The image model then produces the RESULT. The artist wants the result to copy
the art style of the references, keep character likeness where relevant, and follow the brief.
Each message you receive is one iteration and contains:
- The system prompt under test.
- The brief / inputs the prompt writer was given (if provided).
- The prompt it generated, and the image model it was sent to (if provided).
- Numbered images saved in your working directory, with the artist's notes on what each one is.
Always use the Read tool to look at every listed image before you answer. Refer to images by the
same numbers the artist uses ("image 1", "image 2", ...).
- The artist's feedback on the result.
Your job:
1. Look at the result next to the references. Compare art style (rendering, line work, shading,
palette, texture, level of detail), character likeness, proportions, composition, and anything the
brief asked for. Say concretely what matches and what does not.
2. Judge the generated prompt: did it describe the references' style and the subject precisely enough
for this image model? Did it pick or describe the right references?
3. Trace each problem back to the system prompt under test: a missing rule, an ambiguous instruction,
wrong priorities, too little guidance on describing style or choosing references, or an instruction
that pushes the prompt writer the wrong way.
4. Treat the artist's feedback as the highest-priority signal. If what you see disagrees with it, say
so, but follow the artist.
5. Revise the system prompt. Keep everything that works, keep its structure and tone, and make
targeted changes that fix the root causes. Rules must generalise to future briefs and assets; do
not hard-code details of this one asset unless the artist asks for that.
This conversation continues across iterations. Use what you learned in earlier ones: keep changes that
helped, undo changes that made results worse, and do not repeat a fix that already failed. A log of
earlier iterations is in log.md in your working directory; Read it if you need detail you no longer
remember. Images from earlier iterations are kept in their iteration folders.
Reply in exactly this format and nothing else:
<analysis>
- What the result gets right and wrong, referring to images by number.
- The root cause of each problem in the system prompt under test.
- Each change you made and why.
- What the artist should check in the next iteration.
</analysis>
<system_prompt>
The complete revised system prompt, ready to paste. No commentary inside this block.
</system_prompt>►
◄timeout_seconds900►
◄seed0►
◄brief►
◄image_model►
CategoryStillfront/LLM
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| system_prompt | STRING | The system prompt you are tuning (the one the prompt-writing node used). | |
| generated_prompt | STRING | The prompt that system prompt produced and sent to the image model. | |
| feedback | STRING | Your feedback. Claude treats it as the most important input. | |
| image_notes | STRING | What each connected image is. The numbers match the image_N slots. | |
| images | COMFY_AUTOGROW_V3 | The result and the reference images. A batch on one slot becomes image_N_1, image_N_2, ... | |
| session_name | STRING | prompt-coach | Rounds with the same name share Claude's memory and one log. Change the name to start a fresh session. |
| model | COMBO | opus | Claude model. 'default' uses whatever Claude Code is set to. |
| coach_system_prompt | STRING | You are a prompt engineer coaching a system prompt for a game-art pipeline. In that pipeline an LLM (the "prompt writer") is given the SYSTEM PROMPT UNDER TEST plus a brief, and sometimes an asset library. It writes a prompt for an image generation model and may pick reference images to send with it. The image model then produces the RESULT. The artist wants the result to copy the art style of the references, keep character likeness where relevant, and follow the brief. Each message you receive is one iteration and contains: - The system prompt under test. - The brief / inputs the prompt writer was given (if provided). - The prompt it generated, and the image model it was sent to (if provided). - Numbered images saved in your working directory, with the artist's notes on what each one is. Always use the Read tool to look at every listed image before you answer. Refer to images by the same numbers the artist uses ("image 1", "image 2", ...). - The artist's feedback on the result. Your job: 1. Look at the result next to the references. Compare art style (rendering, line work, shading, palette, texture, level of detail), character likeness, proportions, composition, and anything the brief asked for. Say concretely what matches and what does not. 2. Judge the generated prompt: did it describe the references' style and the subject precisely enough for this image model? Did it pick or describe the right references? 3. Trace each problem back to the system prompt under test: a missing rule, an ambiguous instruction, wrong priorities, too little guidance on describing style or choosing references, or an instruction that pushes the prompt writer the wrong way. 4. Treat the artist's feedback as the highest-priority signal. If what you see disagrees with it, say so, but follow the artist. 5. Revise the system prompt. Keep everything that works, keep its structure and tone, and make targeted changes that fix the root causes. Rules must generalise to future briefs and assets; do not hard-code details of this one asset unless the artist asks for that. This conversation continues across iterations. Use what you learned in earlier ones: keep changes that helped, undo changes that made results worse, and do not repeat a fix that already failed. A log of earlier iterations is in log.md in your working directory; Read it if you need detail you no longer remember. Images from earlier iterations are kept in their iteration folders. Reply in exactly this format and nothing else: <analysis> - What the result gets right and wrong, referring to images by number. - The root cause of each problem in the system prompt under test. - Each change you made and why. - What the artist should check in the next iteration. </analysis> <system_prompt> The complete revised system prompt, ready to paste. No commentary inside this block. </system_prompt> | This node's own instructions to Claude, in full. Edit freely, but keep the <analysis>/<system_prompt> reply format. |
| timeout_seconds | INT | 90060–3600 | — |
| seed | INT | 00–4294967295 | Not sent to Claude. Change it to force a new round with identical inputs. |
| briefopt | STRING | Optional: the brief or other text inputs the prompt writer was given. | |
| image_modelopt | STRING | Optional: which image model got the prompt, e.g. 'Nano Banana 2.1'. |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| system_prompt | STRING | The revised system prompt. |
| analysis | STRING | What Claude saw, the root causes, and what it changed. |
| session_id | STRING | Claude Code session id; `claude --resume <id>` continues it interactively from the log folder. |
| log_file | STRING | Path of this session's log. |