Wildcard Processor (Mikey)
Wildcard Processor (Mikey Nodes) — turn __filename__ tags into real prompt text
- STRING
If you've seen prompts online littered with things like __hairstyle__ or __pose__ and wondered what those double-underscore tags actually do, this is the node that resolves them. Wildcard Processor takes a block of text, finds every __something__ reference, swaps each one for a random line pulled from a matching text file, and hands you back a plain string ready for a CLIP Text Encode node.
How the wildcard system works
This is file-based wildcards, not the inline {option1|option2|option3} syntax some other tools use (that variant exists too, elsewhere in the ComfyUI ecosystem, but it's a different mechanism entirely - don't confuse the two). Mikey Nodes' version reads from .txt files living in ComfyUI/wildcards/, one option per line. Write __hairstyle__ in your prompt and it grabs a random line from wildcards/hairstyle.txt.
The syntax has real depth once you need it, straight from the README:
__word__- pick one random line fromword.txt.2$$__word__- pick 2 lines instead of 1.__word|term__- only consider lines in the file that contain "term."__!word__- lock the selection to the seed, so re-running with the same seed always picks the same line (useful for reproducing a specific result).__+word__/__-word__- step the selection one line forward or back from the seed-derived pick.__*word__- force a different random line than the seed would normally pick.
The inputs and output
Just two inputs: prompt (a multiline text box - this is where your wildcard-laden prompt goes) and seed (an integer that drives which lines get picked, including all the offset/lock behavior above). One output: a resolved STRING with every wildcard swapped out for real text, ready to feed a CLIP Text Encode node or any other prompt-consuming node downstream.
Pair the seed here with the same seed you're using on your KSampler if you want the wildcard selection to move in lockstep with your generation seed - that's the whole point of the __!word__ lock syntax.
Installing it
It's part of the full Mikey Nodes pack - search "Mikey Nodes" in ComfyUI Manager and install, or cd ComfyUI/custom_nodes && git clone https://github.com/bash-j/mikey_nodes then restart. The one thing to actually set up yourself: create the wildcards folder in your ComfyUI root if it doesn't exist, and drop in .txt files named after whatever tags you want to use. There's no bundled wildcard library - you're the one writing (or downloading community sets for) the actual word lists.
Where this trips people up
- Empty output for a wildcard tag. If
__hairstyle__resolves to nothing, the most common cause is a missing or misnamed file - it has to behairstyle.txtexactly, sitting directly inComfyUI/wildcards/, not a subfolder unless your workflow accounts for that. - "Random" that isn't actually random between runs. If you're getting the same wildcard pick every time and don't want that, check whether your seed is fixed upstream (common when you've locked a KSampler seed for A/B testing prompts) - the wildcard pick follows the same seed by design.
- Confusing this with the
<style:name>syntax. Mikey Nodes' separate Prompt With Style node uses a different tag format entirely for its built-in style library - that's not what Wildcard Processor reads. Keep the two systems mentally separate; they solve different problems and use different files.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | — | |
| seed | INT | 00–18446744073709550000 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| STRING | STRING | — |