Nodes/DarkPrompts/Dark LoRA Loader
ComfyUI Node

Dark LoRA Loader

Type LoRA tags straight into your prompt — the loader that also strips them out

By darkpixel·Created 3 years ago·Updated about a year ago· 11
Dark LoRA Loader
  • model
  • clip
  • MODEL
  • CLIP
  • STRING
  • LORA_STACK
text
adjust_model_weight_by0.00
adjust_clip_weight_by0.00

DarkLoRALoader is the node that lets you stop building a LoRA-chain of loader nodes and just write LoRA tags in your prompt text. You feed it a MODEL, a CLIP, and a string like 1girl, <lora:somechar:0.8>, detailed, and it finds the tags, loads each LoRA into the model, and hands you back a clean string with the tags removed - ready to feed straight to the text encoder. One node, one pass, done.

The idea isn't new. The tag-in-prompt pattern is how LoRAs are referenced in Civitai-style prompts and in the A1111 world, and a community pack called LoraTagLoader (by badjeff) popularized it in ComfyUI. DarkLoRALoader is a fork of that node, and it adds one thing: a LORA_STACK output alongside the usual MODEL/CLIP/clean-string. A LORA_STACK is the standard list-of-LoRAs container the Efficient Nodes ecosystem uses for XY plots and grid tests - so you can randomize over LoRAs the same way you'd plot over seeds or samplers.

How it works

It scans the input text with a tag regex, and for each tag splits it as lora:name:model_weight with an optional fourth part for the clip weight (lora:char:0.8:0.6). adjust_model_weight_by and adjust_clip_weight_by (FLOAT, -1 to 1, step 0.01) are global offsets added to every tag's weights - handy when a whole LoRA set was trained slightly too hot and you want to nudge everything down without editing each tag. Tags that don't match a file in your models/loras folder are skipped with a console message, not a crash. It also caches the last-loaded .safetensors per node instance, so repeated runs don't re-read the file from disk.

Outputs: MODEL and CLIP (the patched versions), STRING (your prompt minus the tags), and LORA_STACK (name, model weight, clip weight per LoRA).

The licensing wrinkle you should know about

The original LoraTagLoader is GPL-3.0, and the author is not quiet about it - the README calls it "freedom-hating" and keeps the fork in a separate gpl3/ folder, licensed separately from the rest of DarkPrompts. Practical impact for you: the node itself is fine to use, but don't copy its code into a closed-source project, and know the two licenses travel separately. It's an unusually honest way to ship a fork.

What to watch

  • Name matching is prefix-based. The loader matches a tag name against files that start with it (lora_file.startswith(name)), so <lora:char:0.8> can match char_v2.safetensors if that's the first hit. Vague names can grab the wrong LoRA - be specific.
  • Missing LoRAs fail quietly. Bad tag = skipped + console line, not an error. If a LoRA "isn't applying," check the console.
  • Tag format is strict. lora: prefix and colon-separated weights are required; other tag types (embeddings, etc.) are ignored.

Install

Manager → "DarkPrompts", or:

cd ComfyUI/custom_nodes
git clone https://github.com/darkpixel/darkprompts.git

Restart ComfyUI. No models to download - it reads your existing models/loras folder. If you're doing prompt-embedded LoRA loading with an eye toward XY plots, this is the one to reach for.

Categoryloaders

Inputs (5)

NameTypeDefaultDescription
modelMODEL
clipCLIP
textSTRING
adjust_model_weight_byFLOAT0.00-1–1
adjust_clip_weight_byFLOAT0.00-1–1

Outputs (4)

NameTypeDescription
MODELMODEL
CLIPCLIP
STRINGSTRING
LORA_STACKLORA_STACK