ComfyUI Node
Hunyuan Unified Generate V2
A ComfyUI node in Hunyuan/V2 with 15 inputs and 2 outputs.
Hunyuan Unified Generate V2
- images
- final_prompt
◄model_nameHunyuanImage-3-NF4►
◄prompta beautiful sunset over mountains►
◄resolution1024x1024 (1:1 Square)►
◄num_inference_steps40►
◄guidance_scale5.0►
◄seed-1►
◄blocks_to_swap20►
◄vae_placementauto►
◄post_actionfull_unload►
◄enable_vae_tilingfalse►
◄flow_shift2.8►
◄reserve_vram_gb0.0►
◄moe_drop_tokenstrue►
◄vae_dtypebfloat16►
◄force_reloadfalse►
CategoryHunyuan/V2
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| model_name | COMBO | HunyuanImage-3-NF4 | Model folder. Quant type is auto-detected from name (NF4/INT8/BF16). |
| prompt | STRING | a beautiful sunset over mountains | Text prompt for image generation. |
| resolution | COMBO | 1024x1024 (1:1 Square) | Image resolution at common photo ratios (~1MP base, ~1.5MP HD, ~2.4MP large). All divisible by 16. |
| num_inference_steps | INT | 4010–100 | Number of diffusion steps. 40 is balanced for ~1MP. Higher (50–80) reduces flow-matching artifacts at 2K+ resolutions but generation time scales linearly — expect a much longer wait. |
| guidance_scale | FLOAT | 5.01–20 | CFG scale. Higher = more prompt adherence. 5.0-7.0 typical. |
| seed | INT | -1-1–2147483647 | -1 = random seed. |
| blocks_to_swapopt | INT | 20-1–31 | -1 = auto calculate. 0 = no swapping (NF4 needs ~50GB; BF16 uses device_map). 1-31 = manual swap count. BF16 with block swap loads to CPU and is much faster than device_map. |
| vae_placementopt | COMBO | auto | auto: decide based on VRAM. always_gpu: VAE stays on GPU. managed: VAE moves to CPU when not decoding. |
| post_actionopt | COMBO | full_unload | keep_loaded: Keep model on GPU. soft_unload: Move to CPU, keep cached. full_unload: Remove from memory. |
| enable_vae_tilingopt | BOOLEAN | false | Enable VAE tiling for large images. Reduces VRAM but slower. |
| flow_shiftopt | FLOAT | 2.80–10 | Flow-matching shift. Default 2.8 is balanced. Presets: portraits/faces 2.0–2.5 (sharper detail), landscapes/illustrations 3.5–5.0 (cleaner gradients, less high-frequency noise). |
| reserve_vram_gbopt | FLOAT | 0.00–48 | Reserve VRAM for downstream nodes (upscalers, other models). |
| moe_drop_tokensopt | BOOLEAN | true | True (default): MoE drops tokens that exceed expert capacity (lower VRAM, ~1–3% quality cost on dense regions). False: route every token through its top-K experts (best quality, higher VRAM peak — recommended only on ≥48GB cards). |
| vae_dtypeopt | COMBO | bfloat16 | VAE decode precision. bfloat16 (default) is fast and matches model dtype. float32 reduces banding/chroma noise on smooth gradients with negligible cost on big cards. (Some users may already force this via ComfyUI launch flag.) |
| force_reloadopt | BOOLEAN | false | Force full reload: clears cache, empties VRAM, reloads model fresh. Use if orphaned VRAM from failed loads. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| final_prompt | STRING | — |