Nodes/ComfyUI-Text-Utils-sp/GetNameForLoraStack
ComfyUI Node

GetNameForLoraStack

Get LoRA names out of a stack — the trigger-word bridge that started this whole pack

By sp8999·Created 6 months ago·Updated 6 months ago· 8
GetNameForLoraStack
  • lora_stack
  • nameBatch

The author admits it in the README: this whole pack basically exists so this node could work. GetNameForLoraStack takes a LoRA Stack and hands you the names of everything in it, as a batch list, instead of the models themselves. If you've ever loaded five LoRAs and then needed to know which ones they were as text, you know why that's useful. If you haven't, you're probably about to be.

Why you'd reach for it

The real reason, and the one the pack is built around, is trigger words. Your LoRA's trigger tags live in its metadata on Civitai, not in ComfyUI. There's a companion node called LoraTagsOnly (from idrirap's ComfyUI-Lora-Auto-Trigger-Words) that pulls those trigger tags automatically - but it wants a single LoRA name at a time, and it works great for one. Wire a full stack into it and you're stuck doing what the community was already complaining about in 2024: manually hunting trigger tags for every LoRA in your workflow. This node closes the loop. Pull the names out of the stack, hand them to LoraTagsOnly, get the tags back, and feed the result into this pack's SelectTexts node so you can switch individual tags on and off. That's the exact workflow in the pack's AutoLoraTagSelect.json example.

How it works

A LoRA Stack isn't one model - it's a list of entries, each an array like [lora_name, strength_model, strength_clip]. GetNameForLoraStack unwraps that structure and keeps only the first element of every entry, the name, then outputs them as a batch (OUTPUT_IS_LIST). That's the whole job, which is why the node is about as simple as they come and has no settings to fiddle with.

One input, one output:

  • lora_stack - the only required input. Plug in any node that emits the LORA_STACK type: Impact Pack's LoraLoaderBlockWeight, rgthree's Power Lora Loader, or the other stack-style loaders that share that convention.
  • nameBatch - the output. A list of LoRA filenames, one per stack entry, in the same order they're applied.

Wiring it in

The output is a list, and the nodes downstream that want a batch - LoraTagsOnly and this pack's SelectTexts/SelectLists both take lists - will light right up. If you just want to see the names, drag a PreviewAny or text preview onto nameBatch and you'll get each name as a row.

Gotchas

  • The name includes the file, not the display label. You get whatever the loader stores - usually the .safebooru-style filename. If your LoRA is named my_cool_style_v3.safetensors, that's what you'll see. That's fine for LoraTagsOnly, which resolves names against Civitai, but don't expect a friendly title.
  • Order matters. Names come out in stack order, and stack order is application order - which, per the LoRA stacking rules in the knowledge base, is a lever people forget they have. The trigger words will match the actual load order, so this node is also a quick way to sanity-check that your stack is applied the way you think it is.
  • It expects a real stack. Feed it a single LoRA blob rather than a stack and the unpacking logic gets confused. Use it on the LORA_STACK output, not the model output.

Installation

Same as the rest of this pack: no dependencies, no model downloads, just the JS and Python. ComfyUI Manager → search ComfyUI-Text-Utils-sp → Install, then restart. Or, from a terminal in custom_nodes:

cd ComfyUI/custom_nodes
git clone https://github.com/sp8999/ComfyUI-Text-Utils-sp.git

Restart ComfyUI and the node shows up in the text_utils_sp category. One caveat from the README: it's tuned for the Nodes 2.0 frontend - on the older v1 renderer it still runs, but some widgets render at the wrong size.

Categorytext_utils_sp

Inputs (1)

NameTypeDefaultDescription
lora_stackLORA_STACK

Outputs (1)

NameTypeDescription
nameBatch*