π Text Input Switch (8 way)
Eight prompt slots, one dial β a prompt rotator for batching
- STRING
If the 2-way version is the A/B switch, π Text Input Switch (8 way) is the prompt rotator: eight text inputs, one integer dial from 1 to 8, one string output. Flip the dial and you select which of the eight prompts flows downstream. It's the same idea as its smaller sibling, just scaled up for the person who tests more than two looks in a sitting - or who wants a batch loop to march through a menu of prompts without rebuilding the graph.
How it works
The required input is an INT widget clamped to 1 through 8. The eight optional inputs - text1 through text8 - are multiline strings marked as force-input, so the design intent is wiring them from other nodes (like the pack's π
Text boxes). On execution the node compares the dial: 1 β text1, 2 β text2, and so on through 8. Values at or below 1 fall through to text1, and anything above 8 falls through to text8, so there's no error state - you just get the nearest valid slot.
The output is a single STRING. That's the whole contract, and it's refreshingly predictable for an eight-way switch.
Inputs and outputs
- input -
INT, default1, min 1, max 8. - text1 β¦ text8 -
STRING, optional. - Output:
STRING.
Where it shines
The pattern that makes this node worth having is driving the dial from a counter. Wire an integer that increments per run (via π Expression Eval or any counter you have) into input, and each queued run automatically cycles to the next prompt. Eight prompts, one queue, and you've built a mini batch-rotator out of a single node. For pure manual A/B work the 2-way is simpler; for "I have a mood board of looks and want to hit them all," this is the one.
Install
Ships in hay86/ComfyUI_AceNodes:
cd ComfyUI/custom_nodes
git clone https://github.com/hay86/ComfyUI_AceNodes
cd ComfyUI_AceNodes
pip install -r requirements.txt
Restart ComfyUI and look for π
Text Input Switch (8 way) under Ace Nodes. Manager users search ComfyUI_AceNodes.
Gotchas
Same family quirks as the 2-way: unwired slots silently output empty strings rather than erroring, so a missing text slot is easy to misread as a bad prompt. The dial is an integer, and there's no visual badge showing which slot is active beyond the number itself. And yes, the pack's heavy requirements.txt (rembg, transformers, boto3, insightfaceβ¦) installs alongside it. Eight slots is a lot of prompt real estate - keep the wiring tidy and let the counter do the walking.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| input | INT | 11β8 | β |
| text1opt | STRING | β | |
| text2opt | STRING | β | |
| text3opt | STRING | β | |
| text4opt | STRING | β | |
| text5opt | STRING | β | |
| text6opt | STRING | β | |
| text7opt | STRING | β | |
| text8opt | STRING | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | β |