ComfyUI Node Runs on cloud

Text Shuffle

Reorder your prompt's tags without changing what's in it

By WASasquatch·Created 3 years ago·Updated about a year ago· 1,812
Text Shuffle

      This one's not documented with a description in WAS's own README (it's just listed by name), but it does exactly what it says: shuffle a text string. Given how the rest of WAS's randomization tools work - its Random Number node explicitly documents a "shuffled list of integers" mode that respects a seed for reproducibility, and its wildcard/NSP prompt parsing does the same - the safe bet is that Text Shuffle reorders comma-separated tokens (tags) in a prompt-style string, driven by a seed input so the same seed gives you the same shuffle every time rather than a fresh random order on every run.

      The obvious use case is exploring variation without touching content: you've got a working tag list, and you want to see whether reordering "1girl, red hair, forest, cinematic lighting" into a different sequence changes the composition or emphasis without adding or removing a single tag. That's a real, useful lever on classic CLIP-based prompting, where the model chunks and weights tokens in ways that can be genuinely sensitive to order.

      Here's the caveat worth knowing before you reach for it on everything, though: word order matters differently depending on what's reading your prompt. On older CLIP-text-encoder models, tag order is often closer to a bag of weighted tokens, so shuffling is low-risk exploration. On newer models using an LLM-style text encoder (several current-generation image models work this way), the prompt is read more like an actual sentence, and word order is doing real semantic work - deliberately, not incidentally. Shuffle a natural-language prompt on one of those and you're not exploring variation, you're breaking the sentence. Use this node on tag-style prompts for classic checkpoints; think twice before running it on a prose-style prompt meant for an LLM-conditioned model.

      Inputs are a text string and, almost certainly, a seed for reproducibility given the pattern the rest of the suite follows; the output is the shuffled STRING, ready to feed straight into CLIPTextEncode or wherever the rest of your prompt pipeline expects text.

      Installing it: ComfyUI Manager, search "WAS Node Suite," install, restart - the easy way. By hand: cd ComfyUI/custom_nodes && git clone https://github.com/WASasquatch/was-node-suite-comfyui, then pip install -r requirements.txt (portable: python_embeded\python.exe -s -m pip install -r requirements.txt; manual/venv: activate the venv first), then restart ComfyUI. No model, no special dependency for this one - it's string manipulation, nothing more.

      Where it bites: the node itself is low-risk in the sense that it can't really "fail" beyond doing string shuffling wrong, and there's no external service or download involved. The actual risk, as with everything in this pack, is the suite around it: WAS Node Suite has been unmaintained since December 2023 - the README says "Retired" right in the title - and the recurring complaint across the community is the entire pack failing to import after a ComfyUI or Python update, not individual text nodes misbehaving on their own. If Text Shuffle vanishes from your node list, check your startup console for an import failure on the whole suite before troubleshooting this node specifically. And if your shuffled results look worse rather than just different, revisit whether the model you're prompting actually wants tag order preserved - see above.

      Categoryx

      Inputs (0)

      No inputs

      Outputs (0)

      No outputs