Nodes/ComfyUI-SA-Nodes-QQ/Lora Smart Combine (QQ)
ComfyUI Node

Lora Smart Combine (QQ)

Blend up to four LoRAs into one file, with rank control and no sampler

By siraxe·Created 11 months ago·Updated 2 days ago· 72
Lora Smart Combine (QQ)
      lora_1_name
      lora_2_name
      lora_3_name
      lora_4_name
      target_rank16
      blend_weight_11.0
      blend_weight_21.0
      blend_weight_31.0
      blend_weight_41.0
      alpha_handlingblend_proportional
      output_dtypematch_original
      verbosetrue

      Loading five LoRAs at once is a classic way to blow past your VRAM budget and stack conflicts you can't untangle. LoraSmartCombine's answer: take up to four LoRA files, blend them into one new safetensors on disk, and then load that. It's a file-merging node in the spirit of the old A1111 LoRA merge tools, but with two modern touches - an SVD-based rank extension so your merged LoRA can actually be bigger than its parts, and explicit per-LoRA blend weights.

      It's from siraxe/ComfyUI-WanVideoWrapper_QQ, filed under KJNodes/lora. Where the pack's LTX-specific merge (LoraMergeLTX) works on model chains, this one is the general-purpose "two LoRAs walk into a bar" node.

      How it works

      The node loads each selected LoRA's state dict, applies your blend_weight_N to its tensors, and sums the weighted contributions into one merged delta. Then comes the clever part: if the combined delta has higher rank than your target_rank, it runs an SVD decomposition to compress everything back down to that rank - so you can set a target rank that's higher than any individual input LoRA and let the merge extend capacity, or lower to slim the file down.

      The alpha_handling dropdown decides what happens to alpha values when combining:

      • preserve_original - keep each LoRA's own alpha as-is.
      • blend_proportional (default) - alpha follows the same weighted blend as the tensors.
      • recalculate_from_rank - recompute alpha from the target rank, which is the mathematically "cleanest" but changes the effective strength scaling.

      output_dtype lets you pin the result to fp16, bf16, fp32, or match_original (default). If you're targeting a GGUF-style quantized setup or a specific pipeline that's picky about dtype, this is the lever. verbose prints a detailed report of what got combined and how.

      Inputs and outputs that matter

      • lora_1_name / lora_2_name - required; you need at least two.
      • lora_3_name / lora_4_name - optional (set to "None").
      • target_rank - 1 to 4096, default 16.
      • blend_weight_1..4 - per-LoRA weights, 0–10.
      • alpha_handling, output_dtype, verbose - as above.

      There's no data output - it's an output node. It writes the merged safetensors into your ComfyUI output directory and prints the path in the console. The result appears in ComfyUI's LoRA dropdowns after a refresh.

      Installation

      cd ComfyUI/custom_nodes
      git clone https://github.com/siraxe/ComfyUI-WanVideoWrapper_QQ.git
      

      Restart ComfyUI (or ComfyUI Manager → "WanVideoWrapper_QQ"). No extra Python dependencies - torch and safetensors, both already in ComfyUI. The pack's requirements.txt is empty. After the v1.3.4 rename to ComfyUI-SA-Nodes-QQ, delete any old wanwrapper_qq folder to avoid duplicate-node warnings.

      Common issues

      The realistic pitfalls are conceptual more than mechanical. Blending weights don't average - a 1.0 + 1.0 merge of two identical LoRAs doubles the effect, which is why some merges come out overcooked; treat weights as strengths, not votes. Rank matters: setting target_rank below what the content needs crushes detail, above what it needs just bloats the file. And merging LoRAs trained for different purposes (a character and a style) can produce a genuinely unusable model - SVD can't fix incompatible intent. Always sample the result before deleting your originals, because there's no undo.

      CategoryKJNodes/lora

      Inputs (12)

      NameTypeDefaultDescription
      lora_1_nameCOMBOFirst LoRA to combine
      lora_2_nameCOMBOSecond LoRA to combine
      lora_3_nameCOMBOThird LoRA (optional)
      lora_4_nameCOMBOFourth LoRA (optional)
      target_rankINT161–4096Target rank for the combined LoRA
      blend_weight_1FLOAT1.00–10Blend weight for first LoRA
      blend_weight_2FLOAT1.00–10Blend weight for second LoRA
      blend_weight_3FLOAT1.00–10Blend weight for third LoRA
      blend_weight_4FLOAT1.00–10Blend weight for fourth LoRA
      alpha_handlingCOMBOblend_proportionalHow to handle alpha values when combining
      output_dtypeCOMBOmatch_originalData type for output LoRA
      verboseBOOLEANtruePrint detailed combination information

      Outputs (0)

      No outputs