ComfyUI Node

LoraTagsOnly

Pull a LoRA's trigger words without loading anything

By idrirap·Created 3 years ago·Updated about a year ago· 268
LoraTagsOnly
    • civitai_tags_list
    • meta_tags_list
    lora_name
    force_fetchfalse
    append_loraname_if_emptyfalse
    override_lora_name

    Sometimes you don't want to use a LoRA, you just want to know what it was trained on. LoraTagsOnly is the lightweight version of this pack's loaders that does exactly that: pick a LoRA from the dropdown, get its trigger words back as two lists, and never touch a MODEL or CLIP. It's the "look up the tags" node, and it's the one you'll grab when you're auditing your LoRA folder or building a prompt around a LoRA you haven't decided to commit to yet.

    It's a useful middle ground for a couple of real workflows. Want to know whether that character LoRA's trigger is spelled ch4racter or charact3r before you build around it? Run this, glance at the output. Building a reference workflow that dumps every LoRA's tags into a text file? Chain this into TagsFormater. Because it doesn't load the model, it also won't silently eat VRAM or throw a "model is incompatible" error - the tags come from the file's hash lookup and its metadata header, neither of which cares about the base checkpoint your workflow is using.

    How it works

    The inputs are the same two booleans the full loaders carry: force_fetch (re-query Civitai even if the tags are already cached in loras_tags.json) and append_loraname_if_empty (fall back to the filename if both tag sources come up empty). The optional override_lora_name lets you bypass the dropdown with a string - wire a LoraListNames node into it to drive the lookup from elsewhere in the graph.

    The two outputs, civitai_tags_list and meta_tags_list, are the same LIST types the big loaders emit:

    • civitai_tags_list - the model's trainedWords from the Civitai API, matched by file hash, cached locally.
    • meta_tags_list - training tags read from the safetensors metadata (ss_tag_frequency), sorted by how often each tag appeared during training.

    Both feed the usual downstream: TagsFormater to see the list with indexes, TagsSelector to filter and weight. Note there's no lora_name output on this node - if you need the resolved name back, pair it with LoraListNames or use one of the full loaders instead.

    Installing

    It ships in ComfyUI-Lora-Auto-Trigger-Words. Install via ComfyUI Manager (search "ComfyUI-Lora-Auto-Trigger-Words") and restart, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/idrirap/ComfyUI-Lora-Auto-Trigger-Words
    

    No model downloads, no extra dependencies. The usual caveats apply to the Civitai half: it needs network access and a file that's on Civitai under its hash - otherwise civitai_tags_list comes back empty and you're relying on the embedded metadata. That metadata is genuinely the better source anyway for locally-trained LoRAs; Civitai's trainedWords field is often missing or just a copy of the training tags.

    Categoryautotrigger

    Inputs (4)

    NameTypeDefaultDescription
    lora_nameCOMBO0 options:
    force_fetchBOOLEANfalse
    append_loraname_if_emptyBOOLEANfalse
    override_lora_nameoptSTRING

    Outputs (2)

    NameTypeDescription
    civitai_tags_listLIST
    meta_tags_listLIST