FLUX.2 Klein Ref Latent Controller
Dialing one reference's pull, with spatial control
- model
- conditioning
- MODEL
- CONDITIONING
When you've got multiple references loaded and one of them needs to hit harder - or softer - than the rest, this is the node for it. It's a straightforward strength dial on a single reference's contribution to attention, with an optional twist most similar nodes don't bother with: you can fade that strength spatially across the frame instead of applying it uniformly everywhere.
What it's actually doing
Every reference latent Klein has loaded contributes to attention via its own keys and values. This node scales one specific reference's keys and values, in every block, by a multiplier - turning that one reference up or down relative to the others without touching how the model reads the rest of your conditioning. It's the model-patching counterpart to what Text/Ref Balance does at the text-vs-reference level; this operates reference-by-reference instead.
The spatial fade is what sets it apart from its lighter sibling, Ref Latent Weight: instead of one flat multiplier everywhere, you can shape where that reference's influence is strongest across the canvas.
The inputs that matter
modelandconditioning- both required, and both come back out modified (this is one of the few nodes in the pack with two outputs).strength- default1, range up to1000. That huge ceiling is deliberate headroom for extreme experimentation, not a hint that you should routinely run high values - start near 1 and adjust in small steps.reference_index- which reference this affects, matching the order set in Multi ReferenceLatent.spatial_fade(optional, defaultnone) -center_out,edges_out,top_down, orleft_right. Instead of a flat multiplier, the reference's influence ramps across the canvas in the chosen direction.spatial_fade_strength(optional, default0.5) - how pronounced the fade is; only meaningful whenspatial_fadeisn'tnone.
Outputs are a patched MODEL and the (unchanged) CONDITIONING passed straight through - wire both onward as normal.
Installing it
ComfyUI Manager: search ComfyUI-Flux2Klein-Enhancer, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/capitan01R/ComfyUI-Flux2Klein-Enhancer.git
No extra dependencies.
Where people get burned
The strength range going up to 1000 catches people off guard - that's not a typo or a suggestion to run high values, it's headroom for people deliberately pushing the node to its limits. In practice, meaningful changes happen in a much narrower band close to 1; if you find yourself at 20 or 50 and still not seeing the effect you want, the reference probably isn't wired the way you think it is (wrong reference_index, or the reference never made it into conditioning via Multi ReferenceLatent in the first place) rather than needing an even bigger number.
spatial_fade is easy to forget entirely, since none is the default and the node works fine without it - but it's the one thing this node has that Ref Latent Weight doesn't, so if you're choosing between the two and don't need spatial shaping, the lighter model-only node is simpler for the same core job. Reach for this one specifically when a reference should matter more in, say, the center of the frame than at the edges - a natural fit for keeping a face reference dominant in a portrait crop while letting a background or outfit reference fade toward the border.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| conditioning | CONDITIONING | — | |
| strength | FLOAT | 1.000–1000 | — |
| reference_index | INT | 00–7 | — |
| spatial_fadeopt | COMBO | none | 5 options: none, center_out, edges_out, top_down, left_right |
| spatial_fade_strengthopt | FLOAT | 0.500–1 | — |
| debugopt | BOOLEAN | false | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| MODEL | MODEL | — |
| CONDITIONING | CONDITIONING | — |