Text List Product With Single Both
Standalone items from both lists, plus every pair
- list_a
- list_b
- list
The "why not both" variant of the pack. TextListProductWithSingleBoth prepends an empty string to both lists, so you get every item from list A on its own, every item from list B on its own, and every pairing between them - one node, no typing the standalone prompts by hand.
The exact output order is worth knowing before you wire it into a batch, because it's not what you'd guess. With list_a = ["a", "b"] and list_b = ["1", "2"] it produces:
1
2
a
a, 1
a, 2
b
b, 1
b, 2
All the B items come out first, then each A item as a standalone, then the pairs. That sequence is deterministic - the empty-string entries sit at the front of each list in the product, and the pack filters them per-combination before joining.
Inputs and outputs
Same signature as TextListProduct: separator (default ", "), max_results (0 = unlimited), list_a and list_b as forced LIST inputs, one LIST output. max_results counts the standalone lines too, and this is the node where you'll actually want it - the total is |A| + |B| + |A×B|, which is the fastest-growing count of the three "single" variants.
When to reach for it
When both sides are meaningful standalone. The natural case is characters × locations: you want "just the beach", "just the character", and "character at the beach". SingleA and SingleB exist for when only one side needs the bare entries, and plain TextListProduct for when neither does.
Pack-wide gotchas: the LIST sockets only accept list-typed outputs (use MultilineStringToList or StringsToList to make lists), and max_results = 0 means unlimited - set a real number if you don't want the full explosion.
Install
ComfyUI Manager → Install Custom Nodes → search "Comfy UI Text List Product", or by hand:
cd ComfyUI/custom_nodes
git clone https://github.com/opvelll/ComfyUI_TextListProduct
Restart ComfyUI. No dependencies or model downloads - pure stdlib Python.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| separator | STRING | , | — |
| max_results | INT | 0 | — |
| list_a | LIST | — | |
| list_b | LIST | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| list | LIST | — |