Nodes/Krea2 BBOX Prompter Suite/📦 Krea2 BBOX Export
ComfyUI Node

📦 Krea2 BBOX Export

The node that turns boxes and words into JSON Krea2 actually reads

By ukr8b3g-cmyk·Created 2 months ago·Updated 9 days ago· 41
📦 Krea2 BBOX Export
  • framing_data
  • prompt_ui_data
  • prompt_text
  • width
  • height
bbox_modenormalized_1000
output_formatcompact
output_modejson_with_safety_hint
skip_emptytrue
auto_position_hinttrue

This is the node the whole suite exists for. Krea2 BBOX Canvas gives you boxes, Krea2 BBOX Prompter gives you words, and this node - Krea2 BBOX Export - is the assembly line that fuses them into the structured JSON prompt that Krea 2 is supposed to understand. If you only read one page of this pack's docs, make it this one, because nearly every "it's not working" post about the suite traces back to the Export step.

Krea 2's bbox ability is a zero-shot quirk of its Qwen3-VL text encoder rather than something the model was explicitly trained to do, which is why the format you hand it matters so much. This node exists to produce the JSON layout description in the shape the model tolerates - and to be honest about how much control that buys you. It's guidance, not hard regional conditioning; think of it as "strongly worded suggestion" rather than a mask.

What it does

It takes your framing_data (from Canvas) and prompt_ui_data (from Prompter) and emits a compact JSON string with the structure:

aspect_ratio
high_level_description
compositional_deconstruction.background
compositional_deconstruction.elements   # each: type, bbox, desc (text elements also get text)

That aspect_ratio is computed straight from the Canvas width/height. Each element gets its bbox in the coordinate mode you pick, plus your description - and if you leave auto_position_hint on, the node derives a plain-English position phrase from each box's center and area ("positioned in the middle-left area, occupying a small area") and appends it to the description. That hint is doing a lot of the heavy lifting: it's how your box placement survives even when the raw JSON doesn't.

The inputs that matter

  • framing_data and prompt_ui_data - the two pipe inputs. Wire Canvas.framing_data and Prompter.prompt_ui_data here; that's the whole point.
  • bbox_mode - normalized_1000 (default, recommended) rescales boxes to a 0–1000 range; pixel keeps raw canvas coordinates for debugging or fixed-size workflows. Start with normalized_1000.
  • skip_empty - true by default: empty slots get dropped from the output instead of shipped as blank elements. Leave it on.
  • auto_position_hint - true by default; turns on that automatic "positioned in the..." text. You'll generally want it.

The output_format (compact/pretty) and output_mode (json_with_safety_hint/pure_json) widgets are kept purely for compatibility with old workflows - the README is explicit that the current code always emits compact JSON. Don't waste time flipping them. The json_with_safety_hint mode's concept survives though: when it's active, the emitted string carries a tail telling the model to treat the JSON as invisible layout metadata, not as text to render on screen.

Outputs

Three of them, and they map cleanly onto your graph:

  • prompt_text (STRING) - the JSON. Send it to Krea2 BBOX Prompt Effect (to append a style) or straight to a CLIP Text Encode's text input.
  • width and height (INT) - the canvas size, passed through so you can wire them straight into EmptyLatentImage and stay in sync with your layout.

How to install it

Same as the rest of the pack - it's a dependency-free node, no model downloads:

cd ComfyUI/custom_nodes
git clone https://github.com/ukr8b3g-cmyk/Krea2-BBOX-Prompter.git Krea2-BBOX-Prompter-Suite

Restart ComfyUI, Ctrl + F5 to clear the front-end cache, or grab it via ComfyUI Manager under "Krea2 BBOX Prompter Suite."

Where people get burned

Three classics. First, leaving scene/background empty on the Prompter - the JSON ships with an empty high_level_description and Krea2 ignores the boxes. Second, forgetting to wire width/height into EmptyLatentImage, so the render happens at a different aspect than your boxes assumed. Third, expecting pixel-perfect adherence: the community verdict on this suite is that it doesn't match Ideogram 4's accuracy, but the background/style/pose control still expands what you can get out of a flat prompt. Tune box, wording, and scene context together - not the box alone.

CategoryKrea2/BBOX Prompter Suite

Inputs (7)

NameTypeDefaultDescription
framing_dataKREA2_ELEMENT_FRAMING_DATA
prompt_ui_dataKREA2_ELEMENT_PROMPT_DATA
bbox_modeCOMBOnormalized_10002 options: normalized_1000, pixel
output_formatCOMBOcompact2 options: compact, pretty
output_modeCOMBOjson_with_safety_hint2 options: json_with_safety_hint, pure_json
skip_emptyBOOLEANtrue
auto_position_hintBOOLEANtrue

Outputs (3)

NameTypeDescription
prompt_textSTRING
widthINT
heightINT