FD Random Switch
Flip a coin between two of anything, every single run
- value1
- value2
- VALUE
Sometimes you want the machine to decide. Feidorian_RandomSwitch (FD Random Switch) takes two inputs of any type - prompts, checkpoints, seeds, entire image tensors, whatever - and on every single run flips a coin and passes one of them through. Two things in, one thing out, chosen at random, no repeats-guarantee, no weighting. That's the whole contract.
The fun part is that it genuinely re-randomizes each queue. The node's IS_CHANGED returns NaN, the ComfyUI idiom for "never cache me," so ComfyUI can't skip it as unchanged. Every time you hit Queue, the coin flips again - you're not getting a cached pick from last run. If you want variety in a prompt, or you want to A/B test two checkpoints without touching the graph, this is the node.
Why you'd reach for it. A couple of classic uses: wire two prompt strings in and let the sampler pick which one it gets, so each generation in a batch is a surprise. Wire two models (or two LoRA stacks, if you've got a loader that returns any-type values) and let a queue of runs explore both. Or stick it in front of a seed literal for "sometimes fresh, sometimes this exact seed." Because the inputs are any-type, it works on conditioning, latents, images - anything that plugs in.
Inputs and output. value1 and value2, both * type (accepts anything), one output VALUE (*). That's it - there's no seed input, no "always pick value1" mode, no weighting knob. If you need more control, it's the wrong node.
The honest caveats. It's a hard coin flip, which means it can pick the same side several times in a row - with no seed input you can't make a run reproducible, and there's no way to force a specific outcome on a given queue. Also, a caveat that bites people: the any-type output lets you build a graph where the downstream node is fine with either branch, but if your two inputs are different types, whatever the coin lands on still has to match what's downstream. Two prompts is the safe, boring use. And this is from an archived pack - no fixes, no features, frozen.
Where it sits in the ecosystem. rgthree and the big utility packs give you manual switches, group muters, and reroutes, but a pure always-re-randomize any-type coin flip is genuinely handy and rarer than it should be. If you already have rgthree installed you might not miss this one; if you don't, this is a decent freebie that comes with the FD pack.
Install. ComfyUI Manager (search "feidorian-ComfyNodes"), or:
cd ComfyUI/custom_nodes
git clone https://github.com/Feidorian/feidorian-ComfyNodes
Restart ComfyUI and look under the "FD" prefix. No dependencies, no models - the pack installs clean, and the archived-repo status means no surprises waiting in future updates.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| value1 | * | — | |
| value2 | * | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| VALUE | * | — |