sequentially read dynamic pools.
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
Description
### Feature Idea
ok, i've been trying to get chatgpt to make me a custom node. i'll have it give a quick writeup.
The Prompt Queue / Scene Queue node is designed to make managing multiple prompts in ComfyUI simple and automated. Instead of manually switching or editing your text prompt every time you want to generate a new scene or variation, this node lets you write out a list of prompts — one per line — and it automatically cycles through them each time you run a generation.
It works seamlessly with both CLIP Text Encode and CLIP Text Encode++, since both of those nodes accept a text input. You simply connect the output of the Prompt Queue node to the text input of whichever CLIP encoder you’re using. From there, the CLIP node will treat the selected line as its normal prompt, so your workflow continues to function as if you entered the prompt manually.
Internally, the node maintains a small counter (called a register) that keeps track of which prompt line was last used. Each time you trigger a generation, the register advances by one and selects the next prompt in your list. Once it reaches the end, it automatically loops back to the beginning. You can reset the register, advance it manually, or set it to a specific index if you want to jump to a certain prompt. There’s also a random selection mode if you want the order to be shuffled instead of fixed.
This design is especially useful for scene sequencing, animation keyframes, dataset creation, or style variation testing — any situation where you need to generate multiple images under the same workflow but with different textual prompts in a set order. You can think of it as a “playlist” of prompts for your CLIP node.
The node outputs two values: the currently selected prompt (as plain text) and the total number of prompt lines in the list. This makes it easy to plug into existing workflows while still being able to monitor how many prompts are available.
It also includes optional persistence features: if you provide a path to a JSON file, the node can save and load its current index between sessions. That means you can stop ComfyUI, come back later, and pick up exactly where you left off in your sequence.
For metadata compatibility, the node automatically formats its output so that any generated image file will still include the active prompt text in the metadata — just like a standard CLIP Text Encode node would. This ensures that external tools or scripts (such as prompt extractors or metadata readers) can read your images without any extra setup.
In short, the Prompt Queue node automates what users often do manually: stepping through a list of prompts one by one to generate a series of related scenes. It turns that process into a single, self-contained tool — simple, repeatable, and fully compatible with both CLIPTextEncode and CLIPTextEncode++ workflows.
it probably got some of what i imagine wrong, but im more trying to share the idea, than get exactly what i want made.
here is another one from another chat.
Sequential CLIP Encode Node (v1.9) — Feature Overview
Purpose:
A custom node for ComfyUI that extends the functionality of the standard CLIPTextEncode node by introducing sequential and random prompt pool expansion, enabling progressive text prompt variation while preserving full metadata compatibility with downstream nodes like ConditioningConcat and KSampler.
Core Functionality
Prompt Pool Expansion:
Supports nested and grouped prompt variations using curly-brace syntax similar to dynamic prompts, e.g.
{cat|{dog|wolf}|bird} → expands into one of the listed variants.
Nested structures are fully supported and parsed recursively.
Sequential and Random Modes:
Progressive Mode: Each execution advances one step deeper through the available pool options, cycling through combinations predictably.
Random Mode: Randomly selects one option per pool each execution, introducing prompt variety without sequential progression.
Metadata Preservation:
Outputs are structured identically to ComfyUI’s CLIPTextEncode, ensuring:
Compatibility with all standard conditioning pipelines.
Proper metadata embedding into sampler outputs (e.g. visible in saved PNG info).
Traceability of the expanded or selected prompt variant.
as a super basic functionality i want to be able to have a separate encode that will parse dynamic pools sequentially when using batch image generation
basically
"a {cat|{dog|wolf}|bird} in a {park|street|bedroom}" would turn into 4 prompts.
a cat in a park
a dog in a street
a wolf in a street
a bird in a bedroom
i may have gotten close but i've given up since i do not know how to code at all.
here is a catbox with all my failed attempts. i think v5 and its series were closest to working. but i got hung up on them not passing metadata.
https://files.catbox.moe/jcwik1.zip
but i notices pretty much only the default text encode passes the metadata the way i like (parsed prompt)
i really like using pools so idk.
i wanted to used this and have my main prompt separate.
maybe also add the function to have a prompt to text encode as well as pipe in a string. idk if that works but it greys out so idk. im very new. and feel like everyone is just doing everything with giant rolls of duct tape instead of getting something purpose built.
this kind of sounds like it will do what i wont, but fucking look at this mess.
https://civitai.com/models/1884978/comic-creator-text-to-sequence-workflow-multi-image-storytelling-wildcards-loras-and-comic-layout-comfyui
if you even find yourself bored, i could probably think of something new for you to make :P
if this goes anywhere thanks, if not, thanks for the read i guess.
sorry if this isn't the right place to ask about this kind of thing.
### Existing Solutions
probably something with wildcards and such. they all seem way more complicated than they need to be tbh.
P.S.
it could be a core feature of text encode if you have it use [ and ] brackets maybe. idk i dont know anything really. would make a lot of the junk i want unnecessary.
Contributor guide
Assessment
This issue has not been assessed yet.