ComfyUI Node

LoRA Stack Apply

The half of the LoRA stack that actually touches your model

By r-vage·Created 23 days ago·Updated 3 days ago· 0
LoRA Stack Apply
  • lora_stack
  • model
  • clip
  • model
  • clip
  • lora_names

LoRA Stack [SML2] is a list. LoRA Stack Apply [SML2] is what does something with it - it takes that list, your MODEL and (usually) your CLIP, and gives back patched versions plus a string naming what it applied.

What it does

Wire lora_stack in from the stack node, then connect whichever targets your rows need. It applies each enabled row in order, skipping any row whose strength for a given target is zero, and outputs model, clip and lora_names. That last output is a STRING listing each enabled row's filename and selected strengths - drop it into a filename template and your outputs carry their own provenance.

Three paths, depending on how the stack is configured:

  • Model mode - patches compatible diffusion-model weights on the incoming MODEL. CLIP is passed through unchanged, so you don't even need to connect it.
  • CLIP split - patches the model at STR and compatible text-encoder weights at CLIP STR. This one needs both MODEL and CLIP connected.
  • Audio (LTX) - splits an LTX audio-video model's weights: STR for non-audio keys, AUDIO STR for anything containing audio including cross-modal keys. Both patch the same model; CLIP passes through. These targets require ComfyUI's LTXAV model and are rejected on unrelated models.

If Nunchaku is installed, Flux and Qwen rows go through its native wrapper adapters rather than the standard patcher, including compiled-wrapper handling and offload settings, and rows are passed to the adapter together in order. CLIP-only rows don't replace a Nunchaku model's LoRA list. Z-Image keeps its native patcher through ComfyUI's clone/add-patches API.

The mechanism, honestly

LoRAs are low-rank adapters - small matrices that patch attention and linear weights at load time without touching the base checkpoint, which is why a 20–200MB file can add a character or a style that would otherwise need a fine-tune. Applying a stack is the same patch operation, just repeated per row and per target. Nothing is merged to disk, nothing is cached between runs, and the base MODEL object you passed in isn't mutated - you get a patched copy.

One performance note that only bites on some backends: on quantized models, per-layer patching forces a dequantize-patch-requantize cycle, which is exactly where GGUF setups get slower than you'd expect when LoRAs are in play. Same for Nunchaku - hence the dedicated adapters.

Inputs and outputs

lora_stack is the only required input - a custom SML2_LORA_STACK type that only the stack node produces. model and clip are optional in the schema but functionally required by the mode you chose.

Outputs: model, clip, lora_names. Take model (and clip) onward to your sampler, or, if you're on a PIPE, merge them back through IO Checkpoint Loader. The pack's own recommended pipe wiring is: IO Checkpoint Loader → Apply → IO Checkpoint Loader → conditioning/sampling.

Validation before patching

Apply is where a lot of the pack's checks land, which is genuinely helpful. It validates every active file, the required inputs per row, and the local integrity policy before loading any LoRA tensors. A missing input produces an error naming which row's Model or CLIP target needs a connection - not a generic "NoneType".

Local integrity defaults to Verify when the checkbox is on, and uses an entered or saved expected SHA-256; the sidecar policy records a local digest instead. Either way, verification happens here, not in the stack node.

Installing it

ComfyUI Manager → search Smart Model Loader Nova, or:

cd ComfyUI/custom_nodes
git clone https://github.com/r-vage/ComfyUI_SmartModelLoader_Nova.git
cd ComfyUI_SmartModelLoader_Nova
python -m pip install -r requirements.txt

ComfyUI's own Python environment, then restart. If you want Nunchaku LoRAs, install a nunchaku build matching your torch/CUDA separately - it's deliberately not in requirements.txt because it's a compiled CUDA package.

Where people get burned

CLIP split with no CLIP connected. The most common error in this node, and now a specific one. If you set a non-zero CLIP STR and didn't wire clip, Apply tells you which row needs it.

Zero means skip, not "off". Setting STR to 0 in CLIP split mode gives you a CLIP-only row; 0 for CLIP STR gives a model-only row. But zero in Audio mode skips that whole branch. Two different behaviours for the same number across modes - worth remembering.

Mode lives on the stack, not here. People hunt for a strength field on Apply. There isn't one; Apply is all-or-nothing per row and everything tunable is upstream in the stack node.

Wrong architecture, silent failure. The pack says it directly: the controls cannot make an incompatible LoRA compatible. An SDXL LoRA on a Flux model simply won't patch anything meaningful.

Both this and the loader's LoRA section. If Smart Model Loader already applied LoRAs and you also run the stack, you get double application. Pick one path per graph.

Category🌒 Smart Model Loader Nova/ Tools

Inputs (3)

NameTypeDefaultDescription
lora_stackSML2_LORA_STACK—
modeloptMODEL—
clipoptCLIP—

Outputs (3)

NameTypeDescription
modelMODEL—
clipCLIP—
lora_namesSTRING—