Krea2 Structured Prompt
Krea 2 wants prose, you want boxes — this node makes both happy
- prompt
- prompt_json
Krea 2 is picky in a specific way. It's a 12B diffusion transformer whose prompt runs through a Qwen3-VL LLM encoder, so it reads your text like a chat message rather than a tag bag - natural prose beats keyword lists, and Krea's own guidance says to write one or two flowing paragraphs. Great for output, awkward for you: keeping two organized paragraphs straight in one box while juggling three characters is a pain.
Krea2 Structured Prompt is the middle ground. You get labeled boxes - scene, composition, lighting, style, plus as many character blocks as you want - and the node assembles them into the prose Krea 2 was trained to read. Wire its prompt output into ethanfel's Text Encode (Krea2) and you're done.
Say the obvious thing up front: this is not an encoder, makes no API calls, needs no key, and never touches an image. It builds a string; the encoding happens in your Text Encode (Krea2) node.
How it works
Two paragraphs, assembled in Krea-2's trained ordering. Paragraph one is your subjects and scene: each character becomes one sentence in turn (who → pose/action → clothing/props), then the scene is woven in as the backdrop - the node prepends "In" unless your scene already opens with a preposition, so you never get "In on a rain-slicked street." Paragraph two is the visual treatment: composition, lighting, style, then the optional technical details.
The text hygiene is where the small care shows. Fragments get lowercased mid-sentence so presets don't produce "...features, Standing confidently" (the standalone "I" and all-caps acronyms survive). Whitespace and double periods collapse, sentences get capitalized, and everything ends in exactly one period. Empty fields silently disappear; an empty paragraph is dropped rather than leaving a blank line.
The character list is the reason this pack ships a JS file. ComfyUI can't do dynamic input lists natively, so the frontend owns the add / reorder / trash UI and serializes it into one hidden characters_data STRING widget as JSON; Python just parses and assembles. The preset dropdowns are pure UI sugar - they write into the text box, which is the only thing read at execution time. Hand-typed text gets a confirm dialog before a preset clobbers it; empty or still-preset boxes fill silently.
The inputs that matter
- scene - environment/background, the paragraph-1 backdrop
- composition - shot type, angle, framing, depth of field (paragraph 2)
- lighting - light quality, direction, color/mood (paragraph 2)
- style - medium and overall aesthetic (paragraph 2)
- technical_details (optional) - camera/lens language, grain (paragraph 2)
- characters_data - the hidden JSON channel for the character list. You don't type it; the "+ Add character" UI manages it, and each character gets three sub-fields: who/appearance, pose/action, clothing/props.
Two outputs: prompt - the assembled prose, wired into Text Encode (Krea2)'s prompt input - and prompt_json, a dump of every raw field value for debugging or a text-display node.
Installing it
ComfyUI Manager can find it as krea2-structured-prompt; the manual way:
cd ComfyUI/custom_nodes
git clone https://github.com/WaitWut/krea2-structured-prompt.git
Then restart ComfyUI completely - a browser refresh isn't enough; custom nodes only load on a fresh process. ComfyUI Desktop users: check Settings → System Paths, because the real custom_nodes folder may not be where you expect.
There are zero Python dependencies - pure standard-library string assembly, nothing to pip install, no model files. Don't take that to mean the node comes with Krea 2, though: you still need the checkpoint (Raw or Turbo), the Qwen3-VL text encoder (~8GB), and the Qwen-Image VAE. People routinely miss the last two and blame the model; that gotcha applies here too.
Where people get burned
- Wiring the output somewhere that expects conditioning. The
promptoutput is plain text; it only becomes conditioning inside ethanfel's Text Encode (Krea2). Hook it into a CLIP-based encoder and you'll get a type error. - Expecting it to fix Krea 2's quirks. The open-weights model went through an alignment pass the hosted version didn't, so it silently ignores some prompts - bodies, violence, expressions. No prompt-builder can fix that; the uncensor LoRA is the usual workaround.
- Overstuffing characters. Past roughly five subjects the node shows a muted notice - Krea 2 drops fine-grained per-character attributes as constraint density rises, and the ~75–100 effective-token attention cap is real. Split very dense scenes across generations if fidelity matters.
- The lazy restart. Install it, add it to the canvas, don't see it, and wonder why. It loads on a fresh process, not on reload.
If you mostly write one-line prompts, you don't need this. If you build multi-character scenes or just want prompts to stay organized, it's a clean little tool - and zero-risk to try: no dependencies, no model downloads, worst case you're back to the prompt box in thirty seconds.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| scene | STRING | Environment / background. Woven into paragraph 1 as the scene backdrop. | |
| composition | STRING | Shot type, angle, framing, depth of field. Paragraph 2. | |
| lighting | STRING | Light quality, direction, colour / mood. Paragraph 2. | |
| style | STRING | Medium and overall aesthetic. Paragraph 2. | |
| characters_data | STRING | [] | — |
| technical_detailsopt | STRING | Camera / lens language, grain, etc. Optional. Paragraph 2. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| prompt | STRING | — |
| prompt_json | STRING | — |