Nodes/WASABI/WASABI Conditioning Modulate
ComfyUI Node

WASABI Conditioning Modulate

Slerp, scale, and blend your conditioning

By WASasquatch·Created 12 months ago·Updated 12 months ago· 4
WASABI Conditioning Modulate
  • conditioning
  • schedule_options
  • reference_conditioning
  • advanced_options
  • CONDITIONING
modebislerp
scale1.00
blend_back0.00
ref_interpslerp
blend_back_interpslerp
keep_magnitudetrue
eps0
t_ref0.50

This is where WASABI actually does its thing

The other three nodes in the pack are plumbing. WASABI Conditioning Modulate is the engine. It takes any conditioning you already have - from a stock CLIPTextEncode, a Wan T5 encoder, anywhere - and runs token-level math on the embeddings: scaling them, interpolating them toward a reference, blending them back. The README's promise is better prompt adherence and controllability on Wan 2.1/2.2, and this node is where that promise is delivered or not. It's also the honest answer to "I installed WASABI, now what do I wire where?" - you wire this.

Everything is experimental (for_testing category), and the author only validates Wan 2.1/2.2, so keep expectations calibrated. But the mechanism is real and worth understanding, because it's the difference between "I flipped a slider" and "I know why the image changed."

How it works

Conditioning in ComfyUI is a per-token tensor - roughly [batch, tokens, dims] - plus a pooled vector for global intent. WASABI operates on that directly:

  • scale multiplies each token's embedding by a scalar (or a per-token schedule). Above 1 amplifies token strength, below 1 attenuates.
  • slerp / lerp move each token toward a reference embedding. Slerp rotates along the arc between two vectors, preserving angular relationships (semantic-preserving); lerp cuts straight across, punchier but less norm-stable.
  • The bi* modes - bislerp, bilerp, binlerp, bihybrid, biangleclamp, bisbezier, biease_slerp, biease_lerp - do the move-toward-reference, then blend back toward the original embedding by blend_back. That "interpolate, then soften the result" is what makes them feel less aggressive than a raw move.

keep_magnitude (default on) re-imposes the original L2 norm after each interpolation phase, so you change direction without accidentally making the prompt louder or quieter. Where a pooled output exists, the same logic is applied to it, so global prompt intent gets the treatment too.

The inputs that matter

  • conditioning - required. Your existing CONDITIONING, from any CLIP/T5 encoder.
  • mode - the nine modes above, default bislerp. For a first run, keep bislerp and a reference; drop to scale when you just want amplification.
  • scale - default 1.0; >1 amplifies token magnitudes, <1 reduces.
  • blend_back - 0–1, how much to blend the result back toward the original.
  • reference_conditioning - optional, but the important one. The target to slerp/lerp toward.
  • t_ref - default 0.5, how far toward the reference when no schedule is set.
  • keep_magnitude and eps - norm preservation and numerical stability; leave them alone until you have a reason.

The output is a single CONDITIONING that feeds your sampler's positive or negative input like any other.

The trap: interpolation modes need a reference

Anything except scale hard-errors with ValueError: reference_conditioning required for this mode if you leave the reference unwired. Beginners hit this instantly. Wire a second conditioning in, or switch to scale. And the reference has to line up with your input: token counts must match (or be T==1), or you get Token length mismatch. Use a reference encoded from a prompt of roughly the same length.

Install

Via ComfyUI Manager (search "WASABI") or:

cd ComfyUI/custom_nodes
git clone https://github.com/WASasquatch/wasabi

then restart. No model downloads, torch is the only dependency, ComfyUI 1.3.0+ required. Same author as the famous (now retired) WAS Node Suite - different pack, don't cross the wires.

Troubleshooting

  • "It won't run - reference_conditioning required." Pick a mode that doesn't need one (scale), or actually wire one in.
  • "Token length mismatch." Your reference conditioning was encoded from a very different-length prompt. Re-encode it at a similar length, or use a T==1 reference.
  • "I turned scale up and it sounds the same." With keep_magnitude on, the direction changes but the overall strength is pinned. That's the feature. Turn it off if you want brute amplitude.
Categoryfor_testing

Inputs (12)

NameTypeDefaultDescription
conditioningCONDITIONINGConditioning list from CLIP/T5 text encoders.
modeCOMBObislerpscale: multiply. slerp/lerp: move toward reference. bislerp/bilerp: then blend back toward original.
scaleFLOAT1.000–10Global scale when no scale_schedule. >1 amplifies token magnitudes; <1 reduces.
blend_backFLOAT0.000–1Amount to blend results back toward ORIGINAL (0-1). Overridden per-token by blend_schedule.
ref_interpCOMBOslerpInterpolation toward reference embeddings.
blend_back_interpCOMBOslerpInterpolation for the blend-back phase.
keep_magnitudeBOOLEANtruePreserve original L2 norm after each interpolation phase.
epsFLOAT01e-12–0.001Numerical stability epsilon for normalization and SLERP.
schedule_optionsoptDICTOptional schedules bundle from WASABI ScheduleOptions node.
reference_conditioningoptCONDITIONINGTarget conditioning for slerp/lerp modes.
t_refoptFLOAT0.500–1Global fraction toward reference when ref_schedule is empty.
advanced_optionsoptDICTOptional advanced interpolation parameters from WASABI AdvancedOptions node.

Outputs (1)

NameTypeDescription
CONDITIONINGCONDITIONING