Nodes/ComfyUI-ALICE-Lab-Audio-Tools/ALICE Lab Cache Manager
ComfyUI Node

ALICE Lab Cache Manager

Your ALICE Lab pack left a cache behind — here's how to see it and safely kill it

By alice-lab-dev·Created 19 days ago·Updated a day ago· 2
ALICE Lab Cache Manager
    • cache_report
    action
    category
    confirm_clearfalse

    Every node in the ALICE Lab Audio Tools pack writes stuff to disk while you work: waveform thumbnails, browser preview proxies, the trimmed clips pulled down by Media Range (URL), the reference WAVs it bakes for Irodori TTS. It all lands in a persistent cache under ComfyUI/user/__alice_lab_audio_tools/cache/ that survives ComfyUI restarts - unlike the throwaway files under ComfyUI/temp. That's great for fast re-runs and terrible for your disk when you've been auditioning a lot of media. This node is the pack's housekeeping hatch: a one-stop "what's in there, and how do I delete it" panel.

    You reach for it in two situations. First, when you suspect a feature is stale - an old URL clip, a thumbnail that doesn't match the current file - because this cache is deliberately not cleared on restart. Second, when you've been range-testing video all afternoon and want the gigabytes back. It's not a node that goes into a workflow you queue; it's a maintenance tool you run on demand and read the result from.

    How it works

    It's a tiny output node with three inputs and one STRING output:

    • action - inspect (default frame of mind) or clear.
    • category - all, transcripts, thumbnails, media, or metadata. The media bucket is the fat one: Media Range waveform data, browser preview proxies, and URL interval clips all live there. metadata holds things like the content-addressed Irodori reference WAVs.
    • confirm_clear - a boolean, and the safety latch. Flip action to clear without it enabled and the node refuses with an error rather than touching anything. That's deliberate, and it's worth respecting: clearing is permanent.

    Run it and you get a cache_report - JSON text showing the action, the absolute cache root, each category path, and file counts plus byte sizes. On clear it adds a removed section tallying exactly what got deleted. The report renders in the node's UI output, and the STRING output also passes downstream if you want it in your graph.

    Two implementation details make this node better than the usual hand-rolled cache wiper. Deletion is whitelisted to just those four category directories and refuses to follow symbolic links out of the cache root - a real safety measure, since cached media files are server-side and path traversal is an actual attack surface in a pack that fetches remote URLs. And the node returns float("NaN") from its IS_CHANGED, the ComfyUI idiom that forces an output node to run fresh every single time (see ComfyUI's always-rerun trick) - so the report always reflects the current state of the cache rather than a cached answer about a cache. Nicely recursive.

    Installing it

    Same as the rest of the pack - there's no standalone version of this node. Via ComfyUI Manager, search "ComfyUI ALICE Lab Audio Tools" and install, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/alice-lab-dev/ComfyUI-ALICE-Lab-Audio-Tools
    # restart ComfyUI
    

    No pip dependencies beyond what ComfyUI ships, no models. But the pack as a whole needs ffmpeg and ffprobe reachable by the ComfyUI process, and a ComfyUI build with the current AUDIO/VIDEO APIs - so if the other ALICE nodes work, this one will load fine. If you updated the frontend, hard-refresh the browser (Ctrl+Shift+R) before judging anything.

    Gotchas worth knowing

    • It only manages ALICE Lab's own cache. Don't come here expecting to clear ComfyUI's temp, output, or other nodes' caches. It reports and clears exactly one tree.
    • The "error" on clear is a feature. If it complains about confirm_clear, that's the safety catch working, not a bug - enable the toggle and run again.
    • Alpha roughness. This pack is an early ALICE Lab release (Apache-2.0) with essentially no community chatter yet, so don't expect a broad support trail when you search for issues. When in doubt, inspect first and read the JSON before you clear.
    CategoryALICE_Lab/Utils

    Inputs (3)

    NameTypeDefaultDescription
    actionCOMBO2 options: inspect, clear
    categoryCOMBO5 options: all, transcripts, thumbnails, media, metadata
    confirm_clearBOOLEANfalseMust be enabled before the clear action deletes cache files.

    Outputs (1)

    NameTypeDescription
    cache_reportSTRING