EditUtils: Qwen Edit Output Extractor lrzjason
The encode node's kitchen sink, unpacked into 11 usable wires
- custom_output
- pad_info
- full_refs_cond
- main_ref_cond
- main_image
- vae_images
- ref_latents
- vl_images
- full_prompt
- llama_template
- no_refs_cond
- mask
The main encode node (EditTextEncode_EditUtils) is tidy on the outside - it hands you a conditioning and a latent - but it also packs a whole dictionary of intermediates into a single custom_output wire. QwenEditOutputExtractor_EditUtils is the tool that unpacks that dictionary back into named sockets. One custom_output (ANY) input, eleven outputs.
Most of them are the things you'll actually want on a real editing graph:
full_refs_cond(CONDITIONING) - the conditioning with all reference latents attached. This is your normal "feed the sampler" wire.no_refs_cond(CONDITIONING) - the same text conditioning with references stripped. Hugely useful as a negative conditioning, or for the pass where you don't want the reference driving the result.main_image(IMAGE) - the image that was chosen as main, post-processing.vae_images/ref_latents(LIST) - the VAE-side images and their encoded latents, one per reference. Feed these intoListExtractor_EditUtilsto grab a specific one.vl_images(LIST) - the downscaled images that went to Qwen2.5-VL.full_prompt(STRING) - the final prompt after the pack auto-prepends the "Picture n: <|vision_start|>..." tags. Great for checking what the model is actually being asked.pad_info(ANY) - the padding dict from the main image, for reversing padding later.mask(MASK) - the mask, if one was applied.main_ref_condandllama_template- both effectively dead weight in current code. The author's own docs saymain_ref_condis alwaysNone(the logic is commented out) andllama_templateis no longer written intocustom_output. Don't design around them; the outputs exist for compatibility.
So the practical pattern: wire custom_output from the encode node into this extractor, take full_refs_cond into the sampler's positive, no_refs_cond into the negative, and route vae_images or vl_images through ListExtractor to preview what each reference actually looks like after the pipeline mangled it. The full_prompt string is the single most useful debugging output in the whole pack - when an edit does something unexpected, read what prompt the pack built, because the answer is usually in there.
Install
Part of lrzjason/ComfyUI-EditUtils - Manager → "ComfyUI-EditUtils", or clone into custom_nodes and restart. No pip deps. The nodes that emit custom_output need real Qwen weights upstream, which are separate downloads.
Troubleshooting
The two dead outputs will throw you off if you hunt for values that were promised by older docs - main_ref_cond returns None and llama_template returns None in current code, by design. If a no_refs_cond-driven negative is behaving oddly, remember it still carries the text conditioning; it just drops the reference latents, it's not an "empty" negative. And mask is only populated when the encode ran with a mask attached - no mask, expect None.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| custom_output | ANY | — |
Outputs (11)
| Name | Type | Description |
|---|---|---|
| pad_info | ANY | — |
| full_refs_cond | CONDITIONING | — |
| main_ref_cond | CONDITIONING | — |
| main_image | IMAGE | — |
| vae_images | LIST | — |
| ref_latents | LIST | — |
| vl_images | LIST | — |
| full_prompt | STRING | — |
| llama_template | STRING | — |
| no_refs_cond | CONDITIONING | — |
| mask | MASK | — |