Mpi Prompt List Selector
A 50/50 coin flip between two entire prompt lists
- prompt_list_a
- prompt_list_b
- prompt_list
- boolean
- seed
Sometimes the variation you want isn't "pick an option from a list," it's "pick between two whole lists." Day/night scenes, indoor/outdoor, two completely different style directions - Mpi Prompt List Selector takes two PROMPT_LST chains, rolls a seeded probability, and passes exactly one through. It's the A/B router of the ComfyUi-MpiNodes prompt system.
How it works
You feed prompt_list_a and (optionally) prompt_list_b - each can be a single MpiPromptList or a whole chain. The probability slider decides: 0.0 always outputs list A, 1.0 always outputs list B, 0.5 is a perfect coin flip, and anything between biases it accordingly. The seed drives the roll, so the same seed reproduces the same choice - which is the whole point of having a seed here at all.
Two outputs are the useful ones:
prompt_list- the winning chain, ready to feed a MpiPromptProcessor.boolean-Falseif A won,Trueif B won. Wire this anywhere that needs to know which branch is live, or chain it into a second selector for a weighted cascade.
There's also a seed output that passes the value through so downstream randomness stays coordinated.
Installing it
cd ComfyUI/custom_nodes
git clone https://github.com/MadPonyInteractive/ComfyUi-MpiNodes
Restart, or grab it from ComfyUI Manager by searching ComfyUi-MpiNodes. No deps, no models - AGPL-3.0 from v1.2.7 (MIT through 1.2.6).
Where it fits
The honest use is A/B variation at the structure level rather than the option level. MpiPromptList already has its own probability for "this list sometimes skips itself"; this node is for when the two candidates are mutually exclusive directions that each carry their own chains, blocks, and probabilities. A classic rig: list A is a "cinematic day exterior" chain, list B is "moody night interior," and you want each run to commit to one vision instead of cross-pollinating tokens. Combine the boolean output with a MpiIfElse and you can even route non-prompt values - a different seed, a different LoRA - to match whichever direction won. That's where the selector stops being a novelty and starts being the backbone of a variation workflow.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt_list_a | PROMPT_LST | — | |
| probability | FLOAT | 0.500–1 | 0.0 will always output 'list a' and return False 1.0 will always output 'list b' and return True 0.5 gives both a 50% chance |
| seed | INT | 00–18446744073709550000 | — |
| prompt_list_bopt | PROMPT_LST | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| prompt_list | PROMPT_LST | — |
| boolean | BOOLEAN | — |
| seed | INT | — |