SD Lora Selector
Record a LoRA in your metadata without swapping your LoraLoader
- last_lora
- LORA_NAME
- NEXT_LORA
SD Lora Selector is the most modest node in the SD Prompt Reader pack, and honestly one of the more useful. It doesn't load anything. It doesn't patch a model. It takes a lora_name from a dropdown and outputs that name, plus a running list of names - and that list is what lets the pack's SD Prompt Saver write LoRA hashes into your image metadata.
What it's for
Here's the situation that makes this node worth knowing: you've got a working workflow with a LoraLoader you like - a custom one, a stack node, whatever - and you want your saved images to carry proper LoRA hashes so Civitai auto-detects them. Swapping out your loader for the pack's SD LoraLoader works, but it means touching a graph that already runs fine. SD LoraSelector gives you the metadata side without touching the model side.
You place it in parallel. Connect its LORA_NAME output to the lora_name input of whatever loader you're actually using, and connect its NEXT_LORA output to the SD Prompt Saver's lora_name input. The loader keeps doing the real work; the selector just tells the saver which LoRA was in the picture. One input each way, and your hashes are right.
Multiple LoRAs chain the same way as the loader version: each selector's NEXT_LORA feeds the next one's last_lora input, and the end of the chain goes to the saver. If you use this node, you do not also use SD LoraLoader for the same LoRA - the saver would get the name twice. It's a metadata recorder, not a loader, and it assumes the model loading happens elsewhere.
The inputs and outputs, such as they are
lora_name is the only required input - a dropdown of your models/loras folder. last_lora is the optional wildcard that receives the chain from a previous selector. Outputs are LORA_NAME (the chosen name, typed as a wildcard so any loader accepts it) and NEXT_LORA (the growing list for the saver). That's the whole node. There's nothing to tune, no strengths, no surprise settings - pick a name, wire two cables, move on.
Honestly, if you're using the pack's SD Parameter Generator and SD Prompt Saver as your save path and you never deviate from the built-in LoraLoader, this is the one you'll reach for. If you'd rather consolidate, SD LoraLoader does the loading and the recording in one node. Selector is the lightweight version for people with established graphs they don't want to rewire.
Installing it
Standard pack install - ComfyUI Manager, search "SD Prompt Reader," or:
cd ComfyUI/custom_nodes
git clone --recursive https://github.com/receyuki/comfyui-prompt-reader-node.git
cd comfyui-prompt-reader-node
pip install -r requirements.txt
Restart after. No models to download, nothing extra to configure - the pack's only dependency is piexif, and you only need it because the saver (which the selector feeds) uses it for non-PNG metadata.
The trap to avoid
Because LORA_NAME is a wildcard and NEXT_LORA is a wildcard, ComfyUI will happily let you connect either output to either input - and if you wire NEXT_LORA into your real LoraLoader's lora_name, nothing will happen the way you expect. Keep the direction straight: selector's LORA_NAME goes to the loader, selector's NEXT_LORA goes to the saver. It's a two-wire node; don't cross the streams.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| lora_name | COMBO | 0 options: | |
| last_loraopt | * | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| LORA_NAME | — | |
| NEXT_LORA | * | — |