Nodes/ComfyUI_EmAySee_CustomNodes/Random LoRA Loader (EmAySee)
ComfyUI Node

Random LoRA Loader (EmAySee)

Roll a random one from your pool

By EmAySee·Created about a year ago·Updated 4 months ago· 2
Random LoRA Loader (EmAySee)
  • model
  • clip
  • model
  • clip
  • selected_lora_name
  • selected_lora_index
strength_model1.00
strength_clip1.00
seed0
lora_name_1
lora_active_1true
lora_name_2
lora_active_2true
lora_name_3
lora_active_3true
lora_name_4
lora_active_4true
lora_name_5
lora_active_5true
lora_name_6
lora_active_6true
lora_name_7
lora_active_7true
lora_name_8
lora_active_8true
lora_name_9
lora_active_9true
lora_name_10
lora_active_10true

LoRA roulette for when you're batch-generating and don't want every output wearing the same style hat. You fill up to ten LoRA slots from your loras folder, flip on the ones you want in the pool, and this node seeds a random choice, loads that one LoRA onto your model and CLIP, and tells you which one it picked. It's the "variety" cousin of a normal LoRA Loader, and it doubles as a nice discovery tool for a big lora library you've forgotten about.

How it works

Under the hood it's the standard ComfyUI LoRA path: it reads your loras directory into dropdowns, and when it fires it calls comfy.sd.load_lora_for_models exactly like the built-in loader does - so compatibility, strengths, and the merge mechanics are all the stock behavior, just randomized. The inputs that matter:

  • model and clip - wire your checkpoint's model and CLIP in, same as any LoRA loader.
  • strength_model and strength_clip (both default 1.0) - applied to whichever LoRA wins. This is where you keep a "gentle variety" roll by dropping strength to ~0.5.
  • seed - reproducibility. Same seed, same pool, same pick.
  • lora_name_1 through lora_name_10 - the dropdown slots, populated from your loras folder. Leave a slot at "None" to exclude it.
  • lora_active_1 through lora_active_10 (default on) - per-slot kill switches. This is how you curate the pool without deleting the dropdown values.

Outputs: model and clip (the patched versions, wired into your sampler), plus selected_lora_name (STRING) and selected_lora_index (INT) so you can display or log what won.

The two things that'll surprise you

First, if both strengths are 0, or no active slots have a real LoRA selected, the node silently passes your model through untouched and reports "None". That's a feature (a clean bypass) but it can look like a no-op bug when you expected a roll. Second, the seed governs the choice, not the sampling - the whole point is reproducible LoRA selection, so set it and the same lora comes up every time. Turn it to "randomize" on the widget if you want a new pick per run.

Installing it

Part of ComfyUI_EmAySee_CustomNodes. ComfyUI Manager → search the pack → Install, or:

cd ComfyUI/custom_nodes
git clone https://github.com/EmAySee/ComfyUI_EmAySee_CustomNodes
# restart ComfyUI

It sits under EmAySee in the menu. No extra dependencies beyond what ComfyUI already ships for LoRA loading.

Bottom line

If you're running style-exploration batches or you have a hoard of LoRAs you never actually load, this is a fun, zero-risk way to make the graph pick for you. Keep the strengths low for subtle variety, or full strength if you want the roulette to be the whole point of the run.

CategoryEmAySee

Inputs (25)

NameTypeDefaultDescription
modelMODEL
clipCLIP
strength_modelFLOAT1.00-10–10
strength_clipFLOAT1.00-10–10
seedINT00–18446744073709550000
lora_name_1COMBO1 options: None
lora_active_1BOOLEANtrue
lora_name_2COMBO1 options: None
lora_active_2BOOLEANtrue
lora_name_3COMBO1 options: None
lora_active_3BOOLEANtrue
lora_name_4COMBO1 options: None
lora_active_4BOOLEANtrue
lora_name_5COMBO1 options: None
lora_active_5BOOLEANtrue
lora_name_6COMBO1 options: None
lora_active_6BOOLEANtrue
lora_name_7COMBO1 options: None
lora_active_7BOOLEANtrue
lora_name_8COMBO1 options: None
lora_active_8BOOLEANtrue
lora_name_9COMBO1 options: None
lora_active_9BOOLEANtrue
lora_name_10COMBO1 options: None
lora_active_10BOOLEANtrue

Outputs (4)

NameTypeDescription
modelMODEL
clipCLIP
selected_lora_nameSTRING
selected_lora_indexINT