Prompt Store Clear (CCN)
A reset button that doesn't need a re-run
- trigger
- store_name
Every Prompt Store has a clear toggle baked in, so why does this node exist? Because the toggle lives on the store node itself - which means clearing it is a widget action on a node that also does the writing. If you want a reset that lives somewhere else in the graph, runs at a specific point in execution, or fires conditionally, a dedicated clear node is much cleaner.
That's exactly what Prompt Store Clear is: type a store_name, and when it executes it wipes all keys for that store and prints a line to the console confirming it.
How to use it
Two inputs, one trivial output:
- store_name - which store to reset.
- trigger - ANY-typed. Wire something in to control when the clear happens.
The output is just the store_name string passed back through (trigger-style). The real work is the side effect: the named store's dict gets emptied, so the next Prompt Store that runs with that name starts fresh.
The trigger input is where this node earns its keep. Park it in a corner and wire a value from a branch that only runs under the condition you care about - ComfyUI's execution order means the clear fires exactly when that upstream branch fires, not whenever you happen to remember. Since stores are session memory (they survive across workflows until ComfyUI restarts), a stale value silently leaking into a new run is a real failure mode, and a clear node you can trigger deliberately is the fix.
Install
Part of ComfyCollectorNodes - one install for the whole pack:
cd ComfyUI/custom_nodes
git clone https://github.com/valkymaera/ComfyCollectorNodes
then restart ComfyUI, or install via ComfyUI Manager by searching "ComfyCollectorNodes". No models, no extra dependencies.
Where people get burned
The obvious one: it clears the store named in the widget, and store names are case- and whitespace-sensitive strings - a mismatch means it clears a different store than the one you're thinking of (or, if the name doesn't exist yet, nothing happens and it just prints "not found"). Also, clearing and then not re-running the store in the same workflow can leave downstream nodes reading an empty value. If that happens, run once after clearing so the empty state propagates. And remember it's a full reset: it empties the entire store dict for that name - so a PromptStore and PromptStoreB sharing a name get both their key sets wiped in one go, not just the one you were thinking of.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| store_name | STRING | default | — |
| triggeropt | * | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| store_name | STRING | — |