Nodes/ComfyUI-TeaCache/TeaCache For Img Gen
ComfyUI Node Runs on cloud

TeaCache For Img Gen

The original Flux-only TeaCache node (use TeaCache instead)

By welltop-cn·Created 2 years ago·Updated about a year ago· 1,085
TeaCache For Img Gen
  • model
  • model
model_type
rel_l1_thresh0.40

This is the node TeaCache started as, before the pack's maintainer folded everything into one. If your workflow - or a tutorial you're following - still calls out "TeaCache For Img Gen" by name, you're looking at the Flux-only predecessor of the general-purpose TeaCache node: same caching trick, same math, just scoped to one model family and missing a couple of the newer controls. Unless you're deliberately reproducing an old workflow, use TeaCache instead - it does everything this node does, plus more.

How it works

The mechanism is identical to its successor: TeaCache estimates how much a denoising step's output would differ from the cached one, and skips recomputing it when that estimate falls under your threshold. It's training-free - a runtime patch on the model, not a fine-tune - which is why it slots in as a model-in, model-out node with nothing to download.

The inputs and outputs that matter

The interface is deliberately narrow. model_type has exactly one option, flux, because that's all this node ever supported - there's no real decision to make there. rel_l1_thresh (default 0.4) is the only dial that matters: push it down if quality suffers, up if you want more speed and can tolerate the softening. Notice what's missing compared to the unified node - no start_percent/end_percent to restrict caching to part of the schedule, and no cache_device choice. Those got added when the pack's options were redesigned in May 2025, well after this node had already been superseded. Output is a patched model, same as always - wire it into your sampler.

How to install it

Same pack as the unified node. Via ComfyUI Manager: search "ComfyUI-TeaCache", install, restart. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/welltop-cn/ComfyUI-TeaCache
cd ComfyUI-TeaCache
pip install -r requirements.txt

No model files to download - this is a code-only node that patches a Flux model you've already loaded.

Common issues & troubleshooting

You inherited a workflow using this node and it errors after updating the pack. That's expected wear on an old node path. Swap in TeaCache with model_type set to flux and you'll get the same behavior plus the options this node never had.

You want to cache only part of the schedule. You can't, here - that control simply doesn't exist on this node. Move to TeaCache for start_percent/end_percent.

Speed isn't matching what the README promises. Double check you're actually running base Flux, not FLUX-Kontext or something adjacent - this node was only ever tuned against base Flux, so the recommended rel_l1_thresh of 0.4 assumes that specifically.

Multiple TeaCache-family nodes in one workflow, and the threshold seems to follow only one of them. That was a real bug early in this pack's life - with more than one TeaCache node present, rel_l1_thresh would silently use whichever node's value was set last, not each node's own setting. It's long since fixed, but if you're running a genuinely ancient pinned copy of the pack, update it before you spend an hour convinced your graph is wired wrong.

CategoryTeaCache

Inputs (3)

NameTypeDefaultDescription
modelMODELThe image diffusion model the TeaCache will be applied to.
model_typeCOMBO1 options: flux
rel_l1_threshFLOAT0.400–10How strongly to cache the output of diffusion model. This value must be non-negative.

Outputs (1)

NameTypeDescription
modelMODEL