'🔢 Prompt Combinator' is a node that generates all possible combinations of prompts from several lists of strings. '🔢 Prompt Combinator Merger' is a node that enables merging the output of two different '🔢 Prompt Combinator' nodes.
ComfyUI-Prompt-Combinator
Copyright (c) 2024, Luis Quesada Torres - https://github.com/lquesada | www.luisquesada.com
Check ComfyUI here: https://github.com/comfyanonymous/ComfyUI
"🔢 Prompt Combinator" is a node that generates all possible combinations of prompts from several lists of strings.
"🔢 Prompt Combinator Merger" is a node that enables merging the output of two different "🔢 Prompt Combinator" nodes.
"🔢 Prompt Combinator Export Gallery" is a node that generates an .html gallery to navigate the output of Prompt Combinator (prompts vs. images)
"🔢 Pick Random Prompt from Prompt Combinator" is a node that picks a single random prompt from a Prompt Combinator output
See an example of gallery here, also a gallery with all embedded in a single html here.
Download the following example workflow from here or drag and drop the screenshot into ComfyUI.
Install via ComfyUI-Manager or go to the custom_nodes/ directory and run $ git clone https://github.com/lquesada/ComfyUI-Prompt-Combinator.git
You want to produce all possible combinations of prompts from several lists of strings, e.g.
Input list 1:
a cat
a dog
Input list 2:
with pointy ears
with fluffy tail
with two heads
Input list 3:
cute
scary
Expected output: a list of strings that contain
a cat
with pointy ears
cute
a cat
with pointy ears
scary
a cat
with fluffy tail
cute
a cat
with fluffy tail
scary
a cat
with two heads
cute
a cat
with two heads
scary
a dog
with pointy ears
cute
a dog
with pointy ears
scary
a dog
with fluffy tail
cute
a dog
with fluffy tail
scary
a dog
with two heads
cute
a dog
with two heads
scary
Additionally, you may want to be able to identify what inputs were used in order to craft the filename_prefix, e.g.: cat, pointy ears, scary_00001_.png dog, two heads, cute_00001_.png
In order to achieve that, prepend the prompts with ids, e.g.:
Input list 1:
cat@a cat
dog@a dog
Input list 2:
pointy ears@with pointy ears
fluffy tail@with fluffy tail
two heads@with two heads
Input list 3:
cute@cute
scary@scary
Creative Commons License Attribution-NonCommercial-ShareAlike 3.0 Unported (CC BY-NC-SA 3.0), see LICENSE