Nodes/Mecha Merge Node Pack/SD1-LDM Components Params
ComfyUI Node

SD1-LDM Components Params

Weigh each part of an SD1 model separately — CLIP, VAE, UNet, EMA, scheduler

By ljleb·Created 2 years ago·Updated 29 days ago· 101
SD1-LDM Components Params
    • recipe
    clip_l0.00
    vae0.00
    diffuser0.00
    ema0.00
    scheduler0.00

    SD1-LDM Components Params (class SD1 Defaults Hyper) is the node that gives you per-component weights for merging SD1 models. Instead of one global alpha for a whole merge, you get five sliders - clip_l, vae, diffuser, ema, scheduler - and the node turns them into a single MECHA_RECIPE that applies each weight only to its own part of the model.

    This is the thing SuperMerger users have been asking for in ComfyUI for years. The A1111 SuperMerger extension is famous for two features nobody could find an equivalent for elsewhere: block weights and per-component merging. This node is the per-component half, brought into the mecha graph - and it's the kind of control that changes what "merging" means. Want the UNet from model A, the VAE left alone, and the text encoder only lightly blended? That's five numbers away.

    How it works

    Each model config in sd-mecha defines components as sets of keys. This node builds, for each of the five components, a scalar recipe holding that component's weight, then ORs them together into one recipe. When you feed that recipe into a merge method's param input (like alpha on Weighted Sum or Add Difference), the merge engine looks up the weight per key - so clip_l gets its own value, diffuser gets its own, and so on.

    The inputs that matter:

    • clip_l - the CLIP text encoder. Weight 1 means merge it fully; 0 means leave the base's text encoder untouched.
    • diffuser - the UNet. This is the part that does the actual image generation, so it's usually the one you care about most.
    • vae - the variational autoencoder. Set to 0 and you never touch the VAE, which is a common ask because VAEs are notoriously fragile across merges.
    • ema - the EMA copy of the weights (present in SD1 checkpoints).
    • scheduler - the noise scheduler parameters.
    • recipe (output, param space) - the combined per-component param, wired into any merge method's weight/param input.

    Default is everything at 0. That sounds odd until you remember this is a param node: a 0 there doesn't mean "merge nothing," it means "don't apply extra weight to that component beyond the method's own default." Plug it into alpha on a Weighted Sum at 0.5 and then set diffuser: 1, vae: 0 - you get the half-strength blend on the UNet and no VAE mixing at all.

    Install

    It ships in the Mecha Merge Node Pack (ljleb/comfy-mecha):

    • ComfyUI Manager → Install Custom Nodes → search "mecha" → Mecha Merge Node Pack, or manually:
    cd ComfyUI/custom_nodes
    git clone https://github.com/ljleb/comfy-mecha.git
    pip install -r comfy-mecha/requirements.txt
    

    Restart ComfyUI. Only dependency: sd-mecha==1.1.7. No model downloads. (Note: the node's search name is "SD1-LDM Components Params" even though its class is SD1 Defaults Hyper - it's a backwards-compatibility alias in the pack.)

    Common issues

    • 0 is not "off" in every method. A param of 0 means the component gets the default treatment of whatever merge method you plugged it into. Read it as "no override," not "skip." If you genuinely want to skip a component, use Omit Component.
    • These are SD1-LDM component names. If your recipe is in a kohya or LoRA config, the components differ (see the SD1-KOHYA Components Params variants). The names must match the config the recipe actually uses.
    • Set the merge method's own alpha first. The components node controls relative per-part weight; the method's base strength still lives on the method node. Both are doing real work.

    If you've ever merged SD1 and wished you could leave the VAE alone, this is your node. Component params plus the pack's block weights cover most of the "why would I leave A1111" complaints - the last holdout, block-level control, is what SD1-LDM Blocks is for.

    Categorymecha

    Inputs (5)

    NameTypeDefaultDescription
    clip_lFLOAT0.00-18446744073709550000–18446744073709550000
    vaeFLOAT0.00-18446744073709550000–18446744073709550000
    diffuserFLOAT0.00-18446744073709550000–18446744073709550000
    emaFLOAT0.00-18446744073709550000–18446744073709550000
    schedulerFLOAT0.00-18446744073709550000–18446744073709550000

    Outputs (1)

    NameTypeDescription
    recipeMECHA_RECIPE