Nodes/Vector_Sculptor_ComfyUI/Conditioning (Slerp)
ComfyUI Node

Conditioning (Slerp)

Interpolate between prompts the mathematically right way

By Extraltodeus·Created 2 years ago·Updated 2 years ago· 127
Conditioning (Slerp)
  • conditioning_to
  • conditioning_from
  • CONDITIONING
conditioning_to_strength0.50

When you want a conditioning that sits between "prompt A" and "prompt B," you have two options: average the vectors (fast, slightly wrong) or slerp them (also fast, right). This node from the Vector Sculptor pack does the right one - spherical linear interpolation, the same math used to rotate cameras and keyframe 3D animation.

Here's the difference, because it's the whole point. A plain average pulls two vectors toward each other in a straight line through their middle, which shrinks the magnitude the more the prompts disagree. Slerp instead walks along the arc between the two directions, keeping the vector at a constant distance from the origin the whole way. You get a true in-between - direction blended without the volume collapsing. If your prompt blends have ever come out feeling watered down, this is the node that fixes it.

How it works

The implementation is a standard slerp: normalize both vectors, find the angle between them, then interpolate along the arc using sine weights for the current blend value. The author credits a PyTorch forum snippet, so this is battle-tested math, not an invention. The pack's version is polite about SDXL - it interpolates the clip_l and clip_g halves of the 2048-dim conditioning separately - and if the two conditionings have different token counts it trims to the shorter one instead of crashing.

Inputs and output

  • conditioning_to - one endpoint.
  • conditioning_from - the other endpoint.
  • conditioning_to_strength (0–1, default 0.5) - where along the arc you land; 1.0 is all of conditioning_to, 0.0 all of conditioning_from.

Output is a single CONDITIONING feeding straight into the sampler.

Installing it

Same pack, same one-time setup:

cd ComfyUI/custom_nodes
git clone https://github.com/Extraltodeus/Vector_Sculptor_ComfyUI

restart ComfyUI, or install via ComfyUI Manager by searching Vector_Sculptor_ComfyUI. No dependencies, no model files - pure torch.

Where it shines

Slerp is the endpoint-morphing node. Its sibling Conditioning (Average keep magnitude) is the cheap version you use when you just want a quick blend; this one is what you reach for when the interpolation itself is the point - prompt-to-prompt transitions, style morphs, or keyframed prompt animation where you're stepping through a series of blend values. The pack's README demo is literally a walk along a conditioning path, using average-keep-magnitude up to the middle and slerp on the way back, and the two are designed to be used like that. The one rule that isn't optional: both inputs need to come from the same model family. Slerping an SDXL conditioning into an SD 1.5 one is mixing units, and the sampler will let you know in the form of noise. It's CLIP-era tooling like the rest of this pack, so keep it pointed at SD 1.5 and SDXL models - on LLM-encoded models the whole premise evaporates.

Categoryconditioning

Inputs (3)

NameTypeDefaultDescription
conditioning_toCONDITIONING
conditioning_fromCONDITIONING
conditioning_to_strengthFLOAT0.500–1

Outputs (1)

NameTypeDescription
CONDITIONINGCONDITIONING