EditUtils: Qwen Model Config lrzjason
The Qwen config node that can't be misconfigured — fixed name, fixed VAE unit
- model_config
QwenModelConfig_EditUtils is the foolproof version of the generic model config. Where ModelConfig_EditUtils makes you choose a model and (dangerously) a vae_unit, this node hard-codes everything that must be right for Qwen: model_name = "qwen" and vae_unit = 8. The only input is an optional instruction string, and the output is the same model_config dict that feeds EditTextEncode_EditUtils (or the one-box QwenEditTextEncode_EditUtils, which actually builds this exact config internally).
It's a one-purpose node, so the value is mostly about removing failure modes. Qwen-Image and Qwen-Image-Edit share the same VAE, which encodes in 8×8 pixel spatial units, and the pack's whole reference-latent scheme depends on padding your reference images to multiples of that unit before VAE encoding. Locking vae_unit to 8 means the alignment is always right and you never have to remember which model needs which unit. If you're a Qwen-only user, just reach for this instead of the generic switcher and you'll never hit the flux2klein-vs-8 trap described in the generic node's article.
The instruction field is where the actual knob is. It's a multiline string that becomes the system prompt via a llama chat template. Leave it empty and you get the pack's built-in default, which is tuned for instruction-following edits - roughly "describe the key features of the input image, then explain how the user's text instruction should alter it, maintaining consistency with the original where appropriate." That default is genuinely good for plain-language editing. Where you'd override it: you want the model to adopt a specific persona, always mention certain details, or you're using the node with a Krea2-style pipeline where the recommended system prompt is a detailed describe-then-edit instruction.
Under the hood there's nothing exotic: it returns {"model_name": "qwen", "vae_unit": 8, "llama_template": <system prompt>}. The encode node reads model_name to pick the Qwen code path, vae_unit for the padding grid, and llama_template to build the text-conditioning prompt. That's the whole mechanism, and it's the cleanest possible introduction to how this pack routes between models: a plain dict, no magic.
Install
Part of lrzjason/ComfyUI-EditUtils - one install covers all its nodes. ComfyUI Manager → search "ComfyUI-EditUtils", or clone into custom_nodes and restart. No pip deps. The Qwen weights (and their CLIP/VL/VAE) are separate downloads; a GGUF-quantized Qwen-Image-Edit is the usual practical choice on consumer VRAM.
Troubleshooting
The only real misconfig here is feeding the config to the wrong encode branch - it's a Qwen dict, so use it with the Qwen encode path, not Flux2Klein or Boogu. And remember the config is not a model loader: it carries no weights, so if your graph "does nothing," check that your CLIP/VAE/UNET loaders are actually connected upstream of the encode node.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| instructionopt | STRING | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| model_config | DICT | — |