Nodes/ComfyUI-WanActivationEditor/WanVideo Vector Interpolation
ComfyUI Node

WanVideo Vector Interpolation

Morph between two embeddings in smooth steps, not one abrupt swap

By fblissjr·Created about a year ago·Updated about a year ago· 9
WanVideo Vector Interpolation
  • start_embeds
  • end_embeds
  • interpolated_sequence
steps5
methodlinear
include_endpointstrue

Prompt travel is usually a frame-by-frame thing. This node does interpolation in embedding space instead: instead of jumping between two concepts, it walks from one embedding to the other in N discrete, mathematically chosen steps. The output is a WANVIDEOTEXTEMBEDS that carries the full interpolated sequence - and the interesting part of this pack is that you can hand those intermediate steps to the block-injection machinery, so different transformer depths read different points along the morph.

That's the killer move: interpolate between "a wolf" and "a liquid mercury statue," then feed the sequence into WanVideoSequentialMixer or an editor that consumes embeddings, and you've got a concept that evolves through depth instead of through time. The WanVideoVectorInterpolation node is the step-generator for exactly that experiment.

The inputs that matter

  • start_embeds / end_embeds - required WANVIDEOTEXTEMBEDS. The endpoints.
  • steps - 2 to 20, default 5. How many intermediate points along the walk. More steps = smoother morph, more embeddings to store and consume.
  • method - the math of the walk:
    • linear (default) - straight-line interpolation in embedding space. Simple, can pass through "weak" regions in the middle.
    • spherical - slerp, interpolating along the arc of the unit sphere. Keeps magnitudes stable and tends to produce cleaner midpoints. Usually the better default if you know what you're doing.
    • cubic - smoothstep, easing in and out so the changes concentrate in the middle of the range.
  • include_endpoints (default on) - whether the output sequence includes the exact start and end embeddings or just the in-between steps.

Output: interpolated_sequence, a WANVIDEOTEXTEMBEDS whose dict carries the full list of interpolated tensors plus the method/steps metadata. Each intermediate step is also stored in the pack's DuckDB database, so the whole morph is logged.

The honest caveats

Same recurring themes as the other vector nodes: it pads/truncates mismatched shapes with a warning (keep both embeddings at the same raw/projected stage), and interpolation quality is only as good as the space it happens in. In a 5120-dim transformer embedding space, straight-line interpolation between two distant points can pass through semantic no-man's-land - that's precisely why spherical exists, and why the author offers it. If a linear morph looks mushy in the middle, swap the method before you blame your prompts.

One quirk: the node returns a single representative embedding (the middle step) as the main output tensor while stashing the full sequence on the dict. Whether the downstream node consumes the whole sequence is up to that node - so verify the sampler is actually walking the steps, or the "morph" collapses to a single midpoint. That's the experimental-pack tax.

Install

Same pack, WanVideoWrapper first:

cd ComfyUI/custom_nodes
git clone https://github.com/kijai/ComfyUI-WanVideoWrapper   # required first
git clone https://github.com/fblissjr/ComfyUI-WanActivationEditor
cd ComfyUI-WanActivationEditor && pip install -r requirements.txt

Restart ComfyUI (ComfyUI Manager: search "ComfyUI-WanActivationEditor"). Deps: torch, numpy, duckdb, zstandard. Start with spherical, 5 steps, endpoints included - then explore from there.

CategoryWanVideoWrapper/VectorOps

Inputs (5)

NameTypeDefaultDescription
start_embedsWANVIDEOTEXTEMBEDS
end_embedsWANVIDEOTEXTEMBEDS
stepsINT52–20
methodCOMBOlinear3 options: linear, spherical, cubic
include_endpointsBOOLEANtrue

Outputs (1)

NameTypeDescription
interpolated_sequenceWANVIDEOTEXTEMBEDS