Recall Int
Read back the number a Cyclist loop stored last iteration
- INT
Recall Int is the read half of Cyclist's integer memory. Memorize Int stashes a number at the end of a run; Recall Int pulls it back at the top of the next one. Together they give a ComfyUI loop a counter - the thing the platform otherwise can't do, because it wipes all node state between every Queue Prompt.
Where it sits in a loop
Put Recall Int near the start of your workflow, where you want last iteration's value. The classic shape is a counter: Recall Int → Int Math (add 1) → [do the work] → Memorize Int. First run there's nothing stored yet, so Recall Int returns its fallback and the counter starts from zero (or wherever you set the fallback). Every run after that it reads the incremented value, so you always know which pass you're on - and you can feed that count into a Compare Anything node and an Interrupt to stop after N iterations.
The fallback is the clever bit that makes the first iteration not blow up. It's optional: if you provide it, it's used when memory is empty; if you don't, and there's nothing stored, you'll get whatever the empty-memory behaviour is, so wiring a fallback is the safe habit.
The inputs that matter
loop_id(STRING, defaultForLoop_1) - which stored value to read. Must match theloop_idon the Memorize Int that wrote it.fallback(INT, optional, default0) - what to return when nothing's been memorized yet, i.e. the first iteration. This is your loop's starting count.
Output is a single INT - the recalled value, ready to feed into math, a comparison, a seed, a step count, whatever needs a number.
Install
- ComfyUI Manager: search comfyui-cyclist, install, restart.
- Manual:
cd ComfyUI/custom_nodes && git clone https://github.com/Pos13/comfyui-cyclist, restart.
Pure Python, no downloads.
What to watch
The whole memory system lives in RAM, so a ComfyUI restart clears it - after a restart, Recall Int falls back to your fallback value, which is usually what you want (a fresh loop starts over) but worth knowing. If you need persistence across restarts, Cyclist's disk-based Reload/Override nodes are the ones to use, though those are for images, latents and models, not bare ints.
Mind the loop_id matching: Recall and Memorize only find each other if their ids are identical. And when you press "New Cycle" to start a fresh loop, remember it only bumps loop_id widgets and connected Primitives - not ids produced by a Recall String or String Const node - so keep the id you increment in a plain widget.
Standard pack caveat: Cyclist is archived and unmaintained. It works, but nobody's shipping fixes.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| loop_id | STRING | ForLoop_1 | — |
| fallbackopt | INT | 0-9223372036854776000–9223372036854776000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| INT | INT | — |