Continuity RefMod Reference
Feed Klein a reference you already encoded, not a picture it re-encodes every render
- conditioning
- CONDITIONING
The one node in this pack you wire by hand
Most of ComfyUI-Continuity hides the graph: one giant node, type a sentence, attach media with @, press Render, and it compiles core nodes underneath. Continuity RefMod Reference is the odd one out - a small node with a CONDITIONING in and a CONDITIONING out, meant to sit inside a workflow you built.
Why you'd reach for it: references are how you hold a character across generations without training anything, and on Flux 2 Klein they're the whole point - single- and multi-reference editing live in the same checkpoint as generation, which is why people dropped the generate-then-edit stack. The textbook Klein path is LoadImage → ImageScaleToTotalPixels → VAEEncode → ReferenceLatent, which re-encodes your picture on every render. A RefMod is that encode already saved as one .safetensors, and this node is the ReferenceLatent step pointed at the file.
What a RefMod is
A RefMod is one VAE latent plus a JSON header, in the format ComfyUI-MiniMaxH3Mod reads and writes, so the two packs share characters. Files live in ComfyUI/models/refmods/ - a real model folder, so extra_model_paths.yaml can map more.
The important part is that a latent belongs to one VAE - an H3 mod is a 24-channel tensor in the H3 video VAE's space, a Klein mod a 128-channel Flux 2 latent - which is what the space widget is about. A pooled mod is also no concept extractor: it keeps colour and build, drops detail, and stops nothing bleeding.
The cost: at 1 MP a full Klein reference is a 64×64 grid and every cell is a token, so 4,096 of them. Compressed - pooled to a 32-grid and refined back - is a quarter of that. Those cells ride every sampling step - the difference between three references fitting a shot and eight.
How it works, mechanically
It doesn't hand you a LATENT for a ReferenceLatent node - it is that node, over a file. name resolves against your refmods folders, the header is read with stdlib JSON, and every latent in the file is appended onto the conditioning's reference_latents field. That "every" matters: the popular Klein files (fk9_* from malcolmrey's browser, DainamoLabs' ComfyUI-FluxKleinRefMods) are picture sets - twenty-odd latents of one person - and both those packs unroll them into one entry per picture. So does this one: a twenty-member set is twenty references, billed at every member's cells. A feature when you want it, a surprise when you don't.
Two details. A file whose header says h3_video, handed to a Klein graph, is refused by name rather than silently attended to - a tensor in the wrong space is nothing to the model. And the cache key includes the file's path, mtime and size, so swapping a mod's contents in place re-runs.
The inputs that matter
- conditioning - the encode you'd otherwise be chaining onto.
- name - the mod's path inside
models/refmods, without the.safetensors. Subfolders work (cast/anna); therefmod:prefix is optional;..is refused. - space -
flux2(the default, this is the Klein one) orh3_video. It's a plain string widget, not a dropdown, so a typo gives you an error naming what the pack actually reads.
Output is a single CONDITIONING: your guider's positive, and at real CFG the negative too, the way the pack's own Klein graph does. Both branches saw the references.
One caveat: on the MiniMax H3 path this node isn't your tool. H3 reads saved mods inside its own encode and never needs it, so in practice this is a Flux 2 Klein node.
Install
Manager works - search the pack title. Otherwise:
cd ComfyUI/custom_nodes
git clone https://github.com/roadmaus/ComfyUI-Continuity
Restart ComfyUI. No pip install, no extra packages - the model families ship in ComfyUI core.
If you already have ComfyUI-MiniMax-Creator installed, don't clone next to it. The pack was renamed and the old address redirects, so a git pull in the folder you have is the whole update:
cd ComfyUI/custom_nodes/ComfyUI-MiniMax-Creator
git pull
Where people get burned
- No node in the search at all. Two folders of this pack are two packs registering the same node ids - the reason the ids stayed frozen through the rename - and you end up with neither. Delete one, restart. Your settings live in ComfyUI's
user/, so nothing is lost. RefMod 'x' is not in models/refmods/. The name is a path inside that folder, not a filename with an extension. Case counts.- Wrong space. You get the "hang the picture it was made of on the member instead" message. Remake it through the right VAE.
- Bundles and audio mods are refused by count. One visual member is one reference here, so split a multi-reference bundle first.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| conditioning | CONDITIONING | — | |
| name | STRING | — | |
| space | STRING | flux2 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| CONDITIONING | CONDITIONING | — |