sum_stack_image
Sum_stack_image and the end of ControlNet spaghetti
- context
- model
- lora_stack
- ipa_stack
- redux_stack
- condi_stack
- union_stack
- cn_stack
- inpaint
- latent_stack
- context
- model
- positive
- negative
- latent
- vae
- clip
- image
A serious image workflow doesn't just prompt - it conditions. IPAdapter for style, Redux for composition transfer, Union ControlNet for structure, an inpaint pass for redraws. In stock ComfyUI, wiring all of that means five or six separate apply nodes strung through the graph, each one a place to miswire a connection. sum_stack_image is the Apt_Preset "Controller" for image work - the README's design doc in action. It takes the context and folds in every control stack the pack offers in one node: LoRA, IPAdapter, Redux, union ControlNet, classic ControlNet, inpaint, and latent stacks. You configure each stack in its own small node, feed the tokens here, and this node merges them all into the model, conditioning, and latent the sampler actually uses.
This is the node that most directly delivers the pack's pitch: fewer wires, clearer control concepts, and workflows that survive being reopened.
What it actually does
Reads the context (model, clip, latent, VAE, conditioning), then applies whatever stacks are connected, in a defined order:
- lora_stack → patches the model and clip, then re-encodes the stored prompt.
- ipa_stack → IPAdapter applied to the model (style/character reference conditioning).
- redux_stack → the FLUX Redux-style image composition transfer, folded into the positive conditioning.
- condi_stack / cn_stack → general conditioning and ControlNet stacks.
- union_stack → Union ControlNet token, the unified single-ControlNet approach the KB notes every post-Flux family now has.
- inpaint → inpaint stack for masked regeneration.
- latent_stack → stacked latents.
Each stack's individual node does the fiddly config (which image, which strength, which preprocessor); this node just applies them in the right order. That's the whole architecture of the pack's "Controller" layer - config small, apply centralized.
The inputs that matter
The context, the model (optional override), and the stack tokens. For a beginner the useful ones are:
- ipa_stack - IPAdapter reference: wire an image here for style or character consistency.
- redux_stack - Redux: keep an image's overall composition/subject and re-render it.
- union_stack - one ControlNet file covering multiple condition types (depth, edge, pose) from the union family.
- cn_stack - classic ControlNet conditioning for the SD/XL-era files.
- inpaint - masked redraw stack.
- latent_stack - batch latent handling.
The outputs that matter
context (updated bundle), plus direct taps on model, positive, negative, latent, vae, clip, and image (whatever the context was carrying as an image, often the inpaint source). The extra typed outputs are there so you can grab one value for a non-pack node without unwrapping the context.
Wiring it in
sum_load_simple → sum_TextEncode (prompts) → sum_stack_image with your stack tokens → sum_Ksampler. The stack tokens come from the pack's per-control nodes: IPAdapter stack builder, Redux stack builder, union ControlNet stack, inpaint stack.
Installing it
cd ComfyUI/custom_nodes
git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
cd ComfyUI-Apt_Preset
pip install -r requirements.txt # Windows: double-click install.bat
Or ComfyUI Manager → ComfyUI-Apt_Preset. For ControlNet scheduling, the README requires ComfyUI-Advanced-ControlNet (Kosinkadink) installed.
Common issues
Order of operations is fixed and not documented per-input - if you expected the LoRA stack to run after the IPAdapter stack, the code applies LoRA first, then IPA, then Redux/CN/inpaint, and there's no way to reorder without reconnecting. Also, several stacks silently no-op if you connect a token but didn't configure its node (no image, strength 0, etc.), so "I connected everything and got a plain generation" usually means one of the stack-builders is empty. Check each stack node individually before blaming the hub.
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| context | RUN_CONTEXT | — | |
| modelopt | MODEL | — | |
| lora_stackopt | LORASTACK | — | |
| ipa_stackopt | IPA_STACK | — | |
| redux_stackopt | REDUX_STACK | — | |
| condi_stackopt | STACK_CONDI | — | |
| union_stackopt | UNION_STACK | — | |
| cn_stackopt | CN_STACK | — | |
| inpaintopt | INPAINT_STACK | — | |
| latent_stackopt | LATENT_STACK | — |
Outputs (8)
| Name | Type | Description |
|---|---|---|
| context | RUN_CONTEXT | — |
| model | MODEL | — |
| positive | CONDITIONING | — |
| negative | CONDITIONING | — |
| latent | LATENT | — |
| vae | VAE | — |
| clip | CLIP | — |
| image | IMAGE | — |