Nodes/raylight/LTXV Context Windows (Ray)
ComfyUI Node

LTXV Context Windows (Ray)

The node that lets LTX chew long videos it couldn't fit in VRAM

By komikndr·Created about a year ago·Updated 2 days ago· 409
LTXV Context Windows (Ray)
  • ray_actors
  • ray_actors
context_length145
context_overlap40
context_schedulestandard_uniform
fuse_methodpyramid
freenoisetrue
retain_first_framefalse
split_conds_to_windowsfalse
context_stride1
closed_loopfalse

LTXV Context Windows (Ray) is how you generate videos longer than the model can attend to in one pass - the raylight port of ComfyUI's context-window machinery, applied to LTX. If you've ever hit the wall where a video comes out coherent for the first few seconds and then the model "forgets" what it was doing, this is the node that attacks that exact problem.

The mechanism is sliding-window attention for diffusion. Instead of making the model attend to the entire sequence of frames at once - which is what blows up VRAM and degrades long-sequence coherence - the graph processes the video in context windows: chunks of frames, each with an overlap with its neighbor, fused back together at the end. Because the sequence is cut into overlapping pieces, the model never has to hold the whole clip's attention in memory at once, and each window is conditioned to stay consistent with the ones next to it.

The inputs that actually matter

  • context_length - window length in real frames, default 145, and it must be 8*n + 1. This is the LTX constraint baked into the tooltip; off-grid values get snapped down. Bigger windows = more context per pass, more VRAM.
  • context_overlap - overlap between windows in frames (default 40, in steps of 8). More overlap = smoother blending, more wasted compute.
  • context_schedule - how windows move across the clip: standard_static, standard_uniform (default), looped_uniform, or batched. Uniform schedules slide windows evenly; looped closes the loop for seamless looping clips.
  • fuse_method - how overlapping windows merge: pyramid, relative, flat, or overlap-linear. Pyramid is the default and the safe choice for smooth seams.
  • freenoise - FreeNoise noise shuffling, on by default, and the tooltip calls it out: it improves window blending. Leave it on unless a workflow tells you otherwise.

The rest - retain_first_frame (hold frame 0 in every window, handy for I2V), split_conds_to_windows, context_stride, closed_loop - are specialist settings. You'll know when you need them.

The honest guidance

Default 145 with standard_uniform and pyramid is the well-trodden path, and for most people the only thing worth tuning is context_length. Too short and you get window-boundary flicker; too long and you're back to the VRAM wall the node exists to avoid. If you see seams or flicker at window boundaries, raise overlap or check freenoise is on before you start rewriting the schedule. The looped schedule with closed_loop is genuinely good for seamless looping clips, but it's also the easiest way to introduce artifacts if you don't actually want a loop.

Because it's a raylight node it composes with the distributed sampler - ray_actors in, ray_actors out, and the workers each handle their slice of the windowed sequence, which is exactly the pairing this pack is for: context windows control the length problem while Raylight's parallelism controls the VRAM problem.

Install: ComfyUI Manager → "raylight", or clone + pip install -r requirements.txt. No model downloads.

CategoryRaylight/extra

Inputs (10)

NameTypeDefaultDescription
ray_actorsRAY_ACTORS
context_lengthINT1451–16384The length of the context window in real frames. Must be 8*n + 1.
context_overlapINT40The overlap of the context window in real frames.
context_scheduleCOMBOstandard_uniformStep-dependent scheduling algorithm for context windows.
fuse_methodCOMBOpyramidThe method to use to fuse the context windows.
freenoiseBOOLEANtrueWhether to apply FreeNoise noise shuffling, improves window blending.
retain_first_frameBOOLEANfalseRetain the first latent frame in every context window (may help retain initial reference).
split_conds_to_windowsBOOLEANfalseWhether to split multiple conditionings (created by ConditionCombine) to each window based on region index.
context_strideINT1The stride of the context window; only applicable to uniform schedules.
closed_loopBOOLEANfalseWhether to close the context window loop; only applicable to looped schedules.

Outputs (1)

NameTypeDescription
ray_actorsRAY_ACTORS