Conduit Cache Clear
The reset button for the Conduit caches
- trigger
- status
Conduit Cache Clear does exactly one thing: wipes the in-memory caches that the other Conduit nodes build up. It's the maintenance node of the pack, and for anyone who's ever hit "why is my workflow ignoring my new model?" it's the answer in one click.
How it works
The Conduit caches live in a process-wide store (ConduitGlobalCache): the embedding cache remembers CLIP text-encoding results keyed by prompt string, and the latent cache remembers full sampling results keyed by the entire generation config. Both are bounded (100 embeddings, 50 latents, LRU eviction) and both live only in RAM - restart ComfyUI and they're gone. Cache Clear calls clear() on that store, runs gc.collect(), and empties the CUDA cache too, then reports what it removed.
The node takes a single required input, cache_type, with three options: all, embedding, or latent. Pick all for the nuclear option or target just one cache if you want to keep the other warm. There's also an optional trigger input of type * (anything) - it exists so you can chain the clear into a workflow at the right moment, like right before a sampling stage where you know the caches will be stale. The single output, status, is a STRING that tells you what was cleared, e.g. Cleared all: 12→0 embeddings, 5→0 latents. This is a terminal node - its output is meant to be read, not wired onward.
When to actually use it
The caches are self-healing for the common case: change the prompt and the embedding key changes (miss → re-encode), change any sampling parameter and the latent key changes (miss → re-sample). But two situations genuinely require a manual clear:
- Swapping checkpoints. The embedding cache keys on prompt text only - it doesn't remember which CLIP produced an entry. Load a different model and the cached embedding from the old CLIP can get served to the new one. Clear
embedding(or justall) after a model switch, or tickforce_recomputeon the cache node. - Chasing a bug with caching on. If you're debugging and caching keeps serving old results, the fixed-seed, one-variable-at-a-time rule (the community's universal debugging advice) is impossible to follow with a stale cache silently answering. Clear it, or disable the caches until you're done.
Install
Same routine as the whole pack:
cd ComfyUI/custom_nodes
git clone https://github.com/joe002/comfyui-conduit-optimizer
Or ComfyUI Manager → search "comfyui-conduit-optimizer" → restart. No model downloads, PyTorch 2.0+ only, and you'll see [CONDUIT] v1.1.0 loaded: 13 optimization nodes on startup.
Common issues
About the only way to misuse this node is to expect it to speed anything up - it's the opposite, it's the reset. And don't go hunting for the cached data on disk: cache_dir in the pack's settings is a plan, not a feature. Everything lives in RAM until you clear it or restart. If your "cache miss" runs are somehow still returning old images, check that you haven't got two copies of the pack loaded or an older cached .pyc; a fresh restart resolves most weirdness.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| cache_type | COMBO | 3 options: all, embedding, latent | |
| triggeropt | * | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| status | STRING | — |