abyz22_ImpactWildcardEncode
Wildcards, LoRA tags, and a batch of prompts in one node
- model
- clip
- model
- clip
- conditionings
- populated_text
If you've seen workflows that generate the "same" character across a grid of poses and lighting, the trick is usually wildcard prompts - a prompt template that draws random phrases from text files on every run. abyz22_ImpactWildcardEncode is that mechanic bundled into one node: it populates __wildcard__ references, applies <lora:name:weight> tags by actually loading the LoRA, encodes the result, and hands you a batch of conditionings so one queue gives you N varied generations.
It's the flagship utility of abyz22/image_control, a fork of ltdrdata's Impact Pack. The node is a reimplementation of Impact's own ImpactWildcardEncode, and it calls straight into Impact's ImpactWildcardProcessor under the hood - so Impact Pack must be installed or this errors out at execution.
What it does
wildcard_text- your template, e.g.1girl, __pose__, __lighting__, <lora:my_lora:0.7>. Wildcards resolve from the.txt/.yamlfiles in the pack'scustom_wildcardsfolder;<lora:...>tags load real LoRAs from yourmodels/lorasdirectory and swap the tag out of the text.batch_size- how many distinct populated prompts to generate. Each gets its own seed, and you get a CONDITIONINGS list out - wire it to a node that accepts a conditioning list, or use the single-conditioningsiblingabyz22_ImpactWildcardEncode_GetPromptfor a one-shot.mode-Populate(default) actually rolls the wildcards;Fixedpasses the text through untouched, which is handy for A/B comparing.Select to add LoRA/Select to add Wildcard- convenience dropdowns that list your installed LoRAs and known wildcards so you can click to insert instead of typing tags.seed- the base seed; each batch item usesseed + i.
Outputs: the (possibly LoRA-modified) model and clip, the conditionings list, and populated_text - the actual rolled prompt as a STRING, so you can save or display what each image was generated from.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/abyz22/image_control
or ComfyUI Manager → "image_control", restart. Install Impact Pack separately - this node's processor lookup depends on it. Pack requirements add openpyxl, pytorch-lightning, kornia.
Where people get burned
Wildcards only resolve if the files exist in the configured wildcards folder (the pack's custom_wildcards next to ComfyUI/custom_nodes). A __typo__ that matches no file gets passed through literally, so "my batch is full of pose text" means a folder or filename mismatch, not a broken node. Also, wildcard resolution is seeded per item, so the same seed reproduces the same rolls - set seed and you can chase down a specific generation. And mind the impact-pack.ini wrinkle: this pack and real Impact Pack both write that config file, so keep them from fighting over wildcard paths by pointing custom_wildcards at one shared folder.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| model | MODEL | — | |
| clip | CLIP | — | |
| batch_size | INT | 11–18446744073709550000 | — |
| wildcard_text | STRING | — | |
| mode | BOOLEAN | true | — |
| Select to add LoRA | COMBO | 1 options: Select the LoRA to add to the text | |
| Select to add Wildcard | COMBO | 1 options: Select the Wildcard to add to the text | |
| seed | INT | 00–18446744073709550000 | — |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| model | MODEL | — |
| clip | CLIP | — |
| conditionings | CONDITIONINGS | — |
| populated_text | STRING | — |