🧠 Egregora Regional Conditioning
One prompt per region, line by line — and why your prompt count must match exactly
- clip
- region_plan
- regional_positive
- regional_negative
- placeholder_positive
- placeholder_negative
- prompt_count
Regional prompting has a simple failure mode: put two subjects in one global prompt and their attributes bleed into each other - the girl on the left steals the red hair, the sky starts describing the garden. The Egregora-ARMD answer is to give each region its own prompt, and Egregora Regional Conditioning is the node that turns a block of text into per-region conditioning the sampler can actually use.
The one rule that matters
ARMD reads prompts line by line, and the number of non-empty positive lines must equal the region count exactly. Blank lines are ignored, but if your Region Plan produced 9 regions, you need exactly 9 positive prompt lines - not 8, not 10. Mismatch and the node raises an error rather than guessing. If you're captioning regions with a VLM or captioner, feed it one caption per line; if your captioner spits out one big paragraph, reformat it first.
the sky
the sky
the sun
a beautiful mansion house
a beautiful garden
grass and flowers
a nice white ferrari on a grassy field
That's the whole ergonomic story. The region_order_text output from Egregora Region Plan tells you which line maps to which region (row-major, region 1 = top-left).
Negatives are more forgiving
negative_prompts accepts three shapes: leave it empty and every region gets an empty negative; give one line and it's reused for all regions; or give one line per region. That flexibility matters, because the naive alternative - repeating the same negative - is exactly the kind of thing that blows up. Older versions had real trouble when positive and negative prompt lengths diverged too much (the README documents an OOM/visual-deformation bug class from that); v0.1.2 fixed it by using max-length + zero-padding for cross-attention instead of trying to repeat or truncate. So keep your negatives short-ish and consistent and you're fine.
What comes out
- regional_positive / regional_negative - the
EGREGORA_REGIONAL_CONDITIONINGobjects. These feedEgregora Adaptive Diffusion Apply. That's the main path. - placeholder_positive / placeholder_negative - two plain
CONDITIONINGobjects built from empty-prompt encodes. They're compatibility shims for nodes that still expect a standard conditioning object even though you're running regionally. Usually you don't touch them. - prompt_count - the number of regions you encoded. Handy for sanity-checking that the plan and your prompt block agree.
How the encoding actually works
Under the hood it's just a CLIPTextEncode per line, wrapped into a regional payload. The part worth knowing: for SDXL-style architectures it now preserves pooled_output per region instead of dropping it, so each region injects its own pooled style embedding rather than inheriting a global placeholder. That's what makes regional style control actually hold up on SDXL and Z-Image Turbo, and it's a genuinely meaningful upgrade in v0.1.2. If your architecture's conditioning layout doesn't match what it expects, it validates the tensor shape and falls back safely instead of silently corrupting the run.
Installing
Same story as the rest of the pack:
cd ComfyUI/custom_nodes
git clone https://github.com/lucasgattas/ComfyUI-Egregora-ARMD
restart, or grab "ComfyUI-Egregora-ARMD" from ComfyUI Manager. No model downloads - it needs whatever CLIP came with your checkpoint, and the pack's own dependencies (numpy, opencv-python, PyWavelets, torch) are already satisfied by almost any ComfyUI install.
A word on the workflow shape
You'll almost always pair this with a captioning loop: build the plan, preview regions with Egregora Region Select, caption each, paste one per line here. Keep in mind the whole pack is explicitly research-grade - the author's README says it's an open implementation, not a benchmarked solution - so treat "9 lines, one per region" as the contract you can rely on and expect to iterate on the rest.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| clip | CLIP | — | |
| region_plan | EGREGORA_REGION_PLAN | — | |
| positive_prompts | STRING | — | |
| negative_promptsopt | STRING | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| regional_positive | EGREGORA_REGIONAL_CONDITIONING | — |
| regional_negative | EGREGORA_REGIONAL_CONDITIONING | — |
| placeholder_positive | CONDITIONING | — |
| placeholder_negative | CONDITIONING | — |
| prompt_count | INT | — |