Nodes/Krea2 Regional/Krea2 Regional Builder (canvas)
ComfyUI Node

Krea2 Regional Builder (canvas)

Draw the boxes, type the prompts, pick per-region LoRAs — all inside one ComfyUI node

By januspluto·Created 2 months ago·Updated about a month ago· 9
Krea2 Regional Builder (canvas)
  • clip
  • image
  • prev_regions
  • extra_base_loras
  • regions
  • base_conditioning
  • base_loras
  • masks
  • base_prompt
  • region_prompts
  • width
  • height
width1024
height1024
grow_px0
feather_px0
base_prompt
background
aesthetics
lighting
medium
region_append
import_modewhen empty
regions_data
layout_in_baseposition hints
import_json

This is the node you'll actually live in. Krea2 Regional Builder (canvas) is the main event of the Krea2 Regional pack: a full canvas editor inside ComfyUI where you draw rectangles or freehand lassos for each subject, type a prompt per region, and assign a LoRA to each one from a searchable dropdown - then hand the whole thing to Krea2 Apply Regional and generate in a single pass. The KB's regional-prompting panel notes that a paint surface is easier to steer than numeric region splits; this is exactly that, built for Krea 2 specifically.

The regional-prompter genealogy runs Latent Couple → Regional Prompter → Forge Couple → per-architecture custom nodes. Every architecture shift breaks the old tool and someone rebuilds it. This is Krea 2's rebuild, and it's the one with a canvas instead of coordinate boxes.

How it works

Draw a region, type its prompt, optionally attach a LoRA. The builder encodes each region's prompt into a CONDITIONING and pairs it with a mask, bundles everything into a KREA2_REGIONS object, and also assembles the base prompt (scene + background + aesthetics/lighting/medium fields) into a single base conditioning. It also serializes your whole layout back into its widget state, so workflows save and reload with your boxes intact.

Two features make it more than a paint editor:

  • layout_in_base (default "position hints") - this is the anti-frustration setting. Krea 2's Qwen3-VL text encoder reads positional and structured prompts as layout guidance, so the builder injects each region's placement into the base prompt ("in the left side of the image, prominent: an armored knight…") or the whole layout as Ideogram-style JSON. Without it, the masks fight whatever composition the model picks and your subjects drift away from the boxes. Leave it on; the "off" mode is the mode where people come back and complain.
  • The Caption button - wire any node that outputs Ideogram-style layout JSON into import_json and it auto-populates regions from an image, without running a full generation. The recommended captioner is the Qwen3.5 VL text encoder you already load for Krea 2 (system prompt in the repo's qwen_captioner_prompt.txt). import_mode ("when empty" vs "always") controls whether it overwrites what you've already drawn.

Regions are ordered front-to-back - the top of the list wins where masks overlap. Lassos are fully editable: drag vertices, press-drag an edge to split it, alt-click to delete, scale by bounding-box handles, convert rect ↔ lasso with one button. grow_px/feather_px dilate and soften every region mask; keep them small for tightly packed layouts (at 1024px each latent token is 16px).

Inputs that matter

Required: clip (your Krea 2 CLIP), width/height (wire the Empty Latent's WIDTH/HEIGHT ints here so canvas and latent agree), and the base-prompt fields. Everything else - regions_data - is a hidden serialized widget managed by the canvas; don't fight it directly.

Outputs

The ones you care about: regions → Apply Regional's regions input, base_conditioning → Apply Regional's conditioning (and the Detailer's), base_loras → Apply Regional's base_loras. masks is handy for previewing; width/height feed other nodes; region_prompts and base_prompt are just strings if you want to inspect what got built.

Install

Manager, search Krea2 Regional, or:

cd ComfyUI/custom_nodes
git clone https://github.com/januspluto/ComfyUI-Krea2-Regional.git

Requires ComfyUI with native Krea 2 support (v0.26+), no extra Python deps. One real gotcha: the canvas targets ComfyUI's standard graph renderer. If it misrenders under the experimental "Nodes 2.0" rendering mode, disable that setting - several DOM-widget-heavy packs are affected, and this one is very DOM-heavy.

Common issues

The "Caption" button 400-ing was a real bug in early releases (ComfyUI rejected the probe graph with no output node); it's fixed in 1.x - update if you hit it. And if subjects drift despite correct boxes, it's almost always layout_in_base having been switched off, or per-region LoRA strengths below ~1.3, which is the zone where a region-masked LoRA can't establish its identity in the fraction of the image it's allowed to touch.

Categoryconditioning/krea2_regional

Inputs (18)

NameTypeDefaultDescription
clipCLIP
widthINT102464–16384
heightINT102464–16384
grow_pxINT00–512
feather_pxINT00–512
base_promptSTRINGGlobal scene description. Filled from an imported caption.
backgroundSTRINGBackground description. Filled from an imported caption.
aestheticsSTRING
lightingSTRING
mediumSTRING
region_appendSTRINGAppended to every region prompt.
import_modeCOMBOwhen empty2 options: when empty, always
regions_dataSTRING
layout_in_baseCOMBOposition hintsPut the region layout INTO the base prompt so the model composes subjects where your boxes are. Krea 2's Qwen3-VL encoder reads layout guidance; the attention masks then handle isolation/LoRAs. 'position hints' appends natural-language placements; 'full JSON' uses an Ideogram-style structured prompt as the base.
import_jsonoptSTRING
imageoptIMAGE
prev_regionsoptKREA2_REGIONS
extra_base_lorasoptKREA2_LORAS

Outputs (8)

NameTypeDescription
regionsKREA2_REGIONS
base_conditioningCONDITIONING
base_lorasKREA2_LORAS
masksMASK
base_promptSTRING
region_promptsSTRING
widthINT
heightINT