Nodes/LF Nodes/LoRA and embedding selector
ComfyUI Node

LoRA and embedding selector

One picker that loads a LoRA *and* its twin embedding

By lucafoscili·Created 2 years ago·Updated 2 years ago· 50
LoRA and embedding selector
  • ui_widget
  • lora_combo
  • emb_combo
  • lora_tag
  • emb_prompt
  • lora_string
  • emb_string
  • lora_path
  • emb_path
  • lora_image
  • emb_image
get_civitai_infotrue
weight1.00
randomizefalse
filter
seed42
loraNone
lora_stack
embedding_stack

Most LoRA selectors are just a dropdown. This one exists for a specific workflow that everyone doing "pivotal tuning" runs into: trainers that emit a LoRA and an embedding with the same name (the embedding is the trigger word). Manually you'd pick the LoRA, then go find its matching embedding, then make sure you remembered the trigger word. LF_LoraAndEmbeddingSelector treats them as one unit - pick the LoRA and the embedding of the same name comes along for free.

The core input is lora, a dropdown that lists the LoRAs in your models folder. Select one and the node also selects the embedding with the matching filename. The weight input (default 1.0, range −3 to 3) applies to both the LoRA and the embedding, which is the pragmatic default for these paired training setups.

There's also a randomization mode, and it's more useful than it sounds. Flip randomize on and the node picks a LoRA/embedding pair randomly from your directories - filter narrows that down by filename (wildcards like *face* supported) and seed keeps the pick reproducible. That's your quick way to batch-sweep across your collection: same seed, deterministic pick; change the seed, new pair. get_civitai_info (on by default) fetches CivitAI metadata to render a preview card; turn it off if you're offline or don't want the API chatter.

Now, the outputs - there are ten, and you'll use maybe three:

  • lora_combo and emb_combo are the wireable picks: lora_combo goes into a LoraLoader's lora input, emb_combo into the equivalent embedding loader. (Their type shows as empty in the schema - that's a wildcard/dynamic type, so it'll connect to what you point it at.)
  • lora_tag and emb_prompt are the text forms for your prompt: lora_tag is the <lora:name:weight> token, emb_prompt is the trigger word. Paste those into your positive prompt.
  • lora_image / emb_image give you the preview thumbnails, lora_path / emb_path the file paths - handy if you're feeding a captioning or metadata node.
  • lora_string / emb_string and the lora_stack / embedding_stack inputs are for chaining: you can string several selector nodes together to stack multiple LoRA+embedding pairs, which is the "combo" the author built this for.

The one real gotcha: the "twin embedding" only works when your files are actually named in lockstep (mychar.safetensors / mychar.pt). If your embedding has a different name, this node won't pair them - rename the file or you'll be doing the manual lookup this node exists to kill.

It's a Selector-category node from LF Nodes, so install is the pack standard: ComfyUI Manager → "LF Nodes", or git clone https://github.com/lucafoscili/comfyui-lf into custom_nodes, then restart. And the usual reminder for this pack: the repo is in legacy mode (frozen early 2025, still fully functional) with active work now in lucafoscili/lf-nodes - same selector there if you're setting up fresh.

Category✨ LF Nodes/Selectors

Inputs (9)

NameTypeDefaultDescription
get_civitai_infoBOOLEANtrueAttempts to retrieve more info about the models from CivitAI.
weightFLOAT1.00-3–3Lora and embedding weights.
randomizeBOOLEANfalseSelects a combination of Lora and Embedding randomly from your directories.
filterSTRINGWhen randomization is active, this field can be used to filter file names. Supports wildcards (*).
seedINT420–18446744073709550000Seed value for when randomization is active.
loraoptCOMBONoneLora model to use, it will also select the embedding with the same name.
lora_stackoptSTRINGOptional string usable to concatenate subsequent Lora selector nodes.
embedding_stackoptSTRINGOptional string usable to concatenate subsequent embedding selector nodes.
ui_widgetoptKUL_CARD[object Object]

Outputs (10)

NameTypeDescription
lora_combo
emb_combo
lora_tagSTRING
emb_promptSTRING
lora_stringSTRING
emb_stringSTRING
lora_pathSTRING
emb_pathSTRING
lora_imageIMAGE
emb_imageIMAGE