ComfyUI Node

Wan Smart Blend

The node that turns one Wan prompt into a gradual scene change

By fblissjr·Created about a year ago·Updated about a year ago· 5
Wan Smart Blend
  • text_embeds
  • text_embeds
blend_width8
blend_methodsmooth
normalizationpad_truncate
optimize_ordertrue
verbosity1

Here's the problem WanSmartBlend solves, stated as the moment it shows up in your workflow: you want a longer Wan video than one clean generation gives you, so you feed the text encoder multiple prompts separated by | - "a red panda balancing on a bamboo stem | the camera pulls back to reveal the waterfall | a bird lands on the panda's head". On its own, Wan treats each prompt as its own segment and the cut between them lands like a jump cut. WanSmartBlend sits between the text encoder and the sampler and makes that cut a transition by interpolating the text embeddings across a band of frames instead of switching instantly.

It's part of the small ComfyUI-WanSeamlessFlow pack ("wanvideo - seamless flow") by fblissjr, which is built on top of Kijai's ComfyUI-WanVideoWrapper - the pack doesn't bring its own models, it works on the WANVIDEOTEXTEMBEDS objects the wrapper already produces. That's the first thing to know: install the wrapper first, this pack is a layer on top.

How it actually works

The node takes your bundle of per-prompt embeddings and does three things, in order:

  1. Harmonizes shapes. If your prompts encoded to different token lengths, it pads or truncates them to a common shape (normalization: pad_truncate) so they can be interpolated at all.
  2. Reorders the prompts so the semantic jumps are as small as possible. With optimize_order on it computes each embedding's centroid and does a greedy nearest-neighbor sort - prompt 3 goes after prompt 1 if they're more alike than prompt 2 is. If your |-list isn't already a sensible story order, this fixes it for you.
  3. Tags the embedding dict with blend_width, blend_method, and the other parameters, so downstream sampling knows where and how hard to blend.

One honest caveat the README states plainly: this pack "needs modifications, for now, to Kijai's wanvideo wrapper" for the sampler to actually consume those blend tags during windowed generation. The node does the embedding-side preparation - shape matching, ordering, tagging - and the actual per-frame interpolation happens in the wrapper's context-window logic. If you're on a stock, unpatched wrapper, treat the output as well-ordered, ready-to-blend embeddings rather than expecting the blending to be fully wired.

The inputs that matter

  • blend_width (default 8, 0–32) - width of the transition zone in frames. With 257 frames and 3 prompts you get ~85.6 frames per prompt, and the README recommends 8–16 frames of blend. Start at 8, widen if transitions feel abrupt.
  • blend_method (default smooth) - the interpolation curve. linear is the flat version; smooth (smoothstep) gives a natural ease; ease_in/ease_out/sine/circ/bounce are increasingly aggressive accents. bounce is a bit of a novelty - don't use it on anything you care about.
  • optimize_order (default true) - the nearest-neighbor reorder described above.
  • normalization (default pad_truncate) - how mismatched embedding shapes get fixed. Leave it unless you know you want none.

Output is a single text_embeds (WANVIDEOTEXTEMBEDS) that wires straight into WanVideoSampler - and, if you want to check your work before sampling, into WanEmbeddingPrevizCanvas from the same pack.

Install

ComfyUI Manager, search for wanvideo - seamless flow (or "WanSeamlessFlow"), or:

cd ComfyUI/custom_nodes
git clone https://github.com/fblissjr/ComfyUI-WanSeamlessFlow

Restart ComfyUI. No requirements.txt, no model downloads - the pack is pure Python on top of the wrapper, and all the Wan models (T5, DiT, VAE) come from your existing WanVideoWrapper setup. An example workflow ships in example_workflows/wanvideo_seamlessflow_long_T2V_example_01.json.

Where people get burned

  • Single prompt = no-op. With only one embedding in the bundle it logs "skipping optimization processing" and just passes the dict through. Check your WanVideoTextEncode actually has multiple |-separated prompts.
  • Shape mismatch that survives harmonization disables blending entirely - it forces blend_width to 0 and logs it, so your video will have hard cuts and you'll need to check the console to know why.
  • It's a young pack with zero community footprint. This is a "works on my machine, published for others" utility - read the logs, keep a backup of a working baseline workflow, and expect the rough edges.

For long-form Wan work where you're already chaining windows, this is the node that keeps the seams from showing. Just don't skip the previz step on the way out.

CategoryWanSeamlessFlow

Inputs (6)

NameTypeDefaultDescription
text_embedsWANVIDEOTEXTEMBEDS
blend_widthINT80–32Width of transition zone in frames (latent space)
blend_methodCOMBOsmoothInterpolation curve between prompts
normalizationCOMBOpad_truncateHow to handle different embedding shapes
optimize_orderoptBOOLEANtrueOptimize embedding order to minimize semantic distance
verbosityoptINT10–30: None, 1: Basic, 2: Detailed, 3: Debug

Outputs (1)

NameTypeDescription
text_embedsWANVIDEOTEXTEMBEDS