Nodes/comfyui-conduit-optimizer/πŸ” Conduit Seal (Deterministic Cache)
ComfyUI Node

πŸ” Conduit Seal (Deterministic Cache)

The deterministic cache you configure but can't inspect

By JosephOIbrahimΒ·Created 8 months agoΒ·Updated 8 months agoΒ· 1
πŸ” Conduit Seal (Deterministic Cache)
    • cache_config
    β—„enable_embedding_cachetrueβ–Ί
    β—„enable_latent_cachetrueβ–Ί
    β—„step_cache_interval10β–Ί
    β—„verify_checksumstrueβ–Ί
    β—„cache_dirβ–Ί

    Conduit Seal is the pack's caching planner - the node that turns on deterministic caching and defines its rules. "Deterministic" is doing a lot of work here: the goal is that if you ask for the exact same generation again, you get the exact same result back instantly, verified by checksums rather than trusted blindly. That's a real pain point for people doing reproducible runs, seed farming on locked configs, or building pipelines where identical inputs should mean identical outputs.

    How it works

    Seal is a settings node. configure_cache reads your four toggles and returns a CONDUIT_SEAL config object describing the cache policy: whether embedding caching is on, whether latent caching is on, how often to snapshot partial steps (step_cache_interval, default 10), and whether checksums get verified (verify_checksums, on by default). It also reports current cache stats and a default cache directory under ~/.conduit_cache.

    The honest part is in the details. The real caching in this pack happens inside the functional nodes - ConduitEmbeddingCache and ConduitLatentCache - which use their own in-memory global store (ConduitGlobalCache), not the class-level caches Seal reports on. So the stats Seal shows can sit at zero even while the actual caches are full of hits. And nothing is persisted to that cache_dir yet: both caches live in RAM for the lifetime of the ComfyUI process, keyed by hashes of the prompt (for embeddings) or the full sampling config (for latents). The step-cache described in the source is a stated design, not a shipped feature.

    Inputs that matter

    • enable_embedding_cache (default true) and enable_latent_cache (default true) - which caches you want the pack using.
    • step_cache_interval (default 10, 0–50) - how often to checkpoint mid-sampling if partial-step caching lands. 0 effectively disables it.
    • verify_checksums (default true) - the "deterministic" half: recompute hashes and refuse stale entries.
    • cache_dir (optional) - where a future disk-backed cache would live.

    Output

    A single cache_config of type CONDUIT_SEAL, intended for ConduitApply.

    Install

    Same as every Conduit node:

    cd ComfyUI/custom_nodes
    git clone https://github.com/joe002/comfyui-conduit-optimizer
    

    Or ComfyUI Manager β†’ search "comfyui-conduit-optimizer" β†’ restart. No downloads, torch 2.0+ only.

    Common issues

    The big mismatch is between the "checksum-verified deterministic cache" branding and what's live: the actual caches are in-memory and unverified by default paths. If you restart ComfyUI, your "cache" is gone - that's expected. And if you swap checkpoints without clearing caches, the embedding cache can serve embeddings produced by a different CLIP, since its key is just the prompt text. When you change models, either tick force_recompute on the cache nodes or run ConduitCacheClear. For real reproducibility, remember the deeper rule the whole approach leans on: fixed seed, batch size 1, one variable changed at a time - caching is only as deterministic as the underlying sampler.

    CategoryConduit/Cache

    Inputs (5)

    NameTypeDefaultDescription
    enable_embedding_cacheBOOLEANtrueβ€”
    enable_latent_cacheBOOLEANtrueβ€”
    step_cache_intervalINT100–50β€”
    verify_checksumsBOOLEANtrueβ€”
    cache_diroptSTRINGβ€”

    Outputs (1)

    NameTypeDescription
    cache_configCONDUIT_SEALβ€”