[KongchangAI]
· 2 min read· 1,308 words

Spool: A New Framework for Low-Latency Streaming Inference in Hybrid Vision-Language Models

Spool: A New Framework for Low-Latency Streaming Inference in Hybrid Vision-Language Models

Spool leverages the affine nature of recurrent updates to achieve exact frame eviction in hybrid VLM sliding windows, greatly reducing latency and improving accuracy.

Spool is a training-free framework that addresses the high cost of maintaining a sliding window in hybrid vision-language models for streaming video understanding. Recurrent layers in hybrid models compress all historical frames into a shared state, forcing a full replay when old frames are evicted. Spool leverages the affine nature of recurrent updates to represent each frame's effect as associatively composable transformations, caching them per frame to exactly remove old frames without replay. Across 20 tests on five open-source hybrid VLMs and four video benchmarks, Spool achieves the lowest p95 time-to-first-token, a 6.6× geometric mean reduction versus vLLM baselines, while improving accuracy by 2.3 percentage points on average. This offers a promising infrastructure-layer innovation for real-time video understanding, though cross-layer decoupling and engineering integration complexity remain open.

Applications such as visual accessibility assistants and robots need to answer questions quickly based on the most recent segment of video content (for example, the past two minutes). Hybrid vision-language models (VLMs), which interleave attention mechanisms with linear recurrent layers such as Gated DeltaNet (GDN), are attractive for these scenarios, but maintaining a sliding window is expensive: the recurrent layers compress all historical frames into a single shared state, so evicting old frames typically requires re-running the entire window through the model.

Spool paper title screenshot

The Root of the Problem: The "Full Replay" Dilemma of Recurrent States

In a standard Transformer, the key-value cache allows frame-by-frame eviction, but the recurrent layers in hybrid models break this convenience. Because the recurrent update encodes all historical information into a fixed-dimensional state, removing any single frame changes the cumulative result for all subsequent frames. The most direct solution is to replay the entire window, but the computational cost grows linearly with window length, which is unacceptable for real-time applications that require low-latency responses.

The authors of Spool noticed a key property: the recurrent update is affine with respect to the state, and its coefficients depend on the input. This means that each frame's effect on the state can be represented as a transformation, and these transformations satisfy associativity—they can be composed and decomposed like a spool of thread.

Key-value cache (KV Cache) is a core optimization technique in Transformer inference: during autoregressive generation, the model stores the key (Key) and value (Value) vectors of already-processed tokens in memory, and subsequent steps reuse them directly to avoid redundant computation. For video streaming scenarios, this means the earliest key-value pairs can be evicted frame by frame, requiring only the deletion of the corresponding entries from the cache at a computational cost of O(1). However, recurrent layers in hybrid models (such as GDN) do not maintain explicit key-value pairs; instead, they compress all historical information into a fixed-dimensional recurrent state. Each time a new frame arrives, the state is rewritten through a nonlinear update function, and the information from old frames cannot be separated from the current state. Therefore, to remove the influence of a certain frame, one cannot simply delete entries as with a KV Cache; instead, one must replay the updates of all subsequent frames starting from that frame. This is the root of the "full replay" dilemma.

Spool's Core Mechanism: Transform Caching and Associative Composition

Spool is a training-free framework that caches state transformations for each frame and efficiently composes them as the window slides. When an old frame expires, Spool directly removes its influence from the recurrent layer's state without re-feeding the frame into the backbone network. This removal is exact within each recurrent layer; however, similar to key-value eviction in attention mechanisms, expired frames may still retain residual influence through cached inputs computed by earlier layers.

To minimize the overhead of caching and composition, the research team designed specialized data structures and GPU kernels. This low-level optimization enables Spool to truly deliver on its low-latency promise in real deployments, rather than remaining merely theoretically elegant.

Affine transformation mathematically refers to a mapping of the form ( y = Ax + b ), where ( A ) is a linear transformation matrix and ( b ) is a translation vector. In the recurrent layers targeted by Spool, the state update can be written as ( s_t = A_t s_{t-1} + b_t ), where ( A_t ) and ( b_t ) are determined by the current input frame. The key benefit of this structure is that the updates of multiple consecutive frames can be composed into a single affine transformation—if the first frame corresponds to ( (A_1, b_1) ) and the second frame corresponds to ( (A_2, b_2) ), then the combined effect of the two frames is ( s_2 = A_2 A_1 s_0 + A_2 b_1 + b_2 ). The composition operation satisfies associativity, so the transformations of all frames in the window can be pre-composed into a single total transformation, or "decomposed" in reverse order to remove a particular frame. Spool leverages exactly this algebraic property to cache the affine parameters of each frame, thereby replacing replay with composition/decomposition as the window slides.

Experimental Performance: Dual Benefits in Latency and Accuracy

On five open-source hybrid VLMs and four video reasoning benchmarks, Spool achieved the lowest p95 time-to-first-token in all 20 model-benchmark tests, with a geometric mean reduction of 6.6× compared to the faster of two recent vLLM baselines. At the same time, accuracy improved by an average of 2.3 percentage points.

What is notable about this result is that the reduction in latency did not come at the expense of accuracy—typically, evicting historical information harms the model's understanding of context, but Spool's exact removal mechanism avoids information contamination within each recurrent layer, thereby maintaining inference quality while accelerating.

p95 time-to-first-token (TTFT) is a key metric for measuring the responsiveness of interactive inference systems: it represents the 95th percentile of the time required from when a request is issued to when the model generates the first output token. Compared with average latency, p95 better reflects tail latency—that is, the experience of the slowest 5% of requests. This is particularly important for real-time applications such as visual accessibility assistants and robot control, because occasional long delays can directly disrupt user experience or cause control failures. Spool's reported geometric mean reduction of 6.6× means that latency is significantly improved on most requests, and tail latency is also systematically compressed, rather than merely the average being pulled down.

Significance for Streaming Video Understanding

Spool's value lies in clearing a key obstacle for the streaming deployment of hybrid VLMs. Visual accessibility agents need to describe their surroundings almost instantaneously, and robots need to react based on the most recent few seconds of video—these scenarios are extremely sensitive to first-token latency. Through a training-free approach, Spool enables existing hybrid models to run efficiently in sliding-window mode without retraining or modifying the model architecture.

Of course, Spool is not without boundaries: the residual influence of expired frames through cached inputs means that "exact removal" holds only within a layer, and complete decoupling across layers remains an open problem. In addition, the implementation complexity of the specialized data structures and GPU kernels is relatively high, and whether the community can quickly reproduce and integrate them into mainstream inference frameworks will determine its practical impact.

Conclusion

By leveraging the affine nature of recurrent updates and the associativity of transformations, Spool provides an exact eviction scheme for sliding-window inference in hybrid vision-language models without replaying historical frames. Across multiple open-source models and benchmarks, it simultaneously improves latency and accuracy, offering a promising infrastructure-layer innovation for real-time video understanding applications.

One-line Summary

Spool leverages the affine nature of recurrent updates to achieve exact frame eviction in hybrid VLM sliding windows, greatly reducing latency and improving accuracy.

Paragraph Summary

Spool is a training-free framework designed to solve the high cost of maintaining a sliding window in hybrid vision-language models for streaming video understanding. The recurrent layers in hybrid models compress all historical frames into a shared state, forcing a replay of the entire window when old frames are evicted. Spool leverages the affine nature of recurrent updates to represent each frame's effect on the state as associatively composable transformations, and caches these transformations for each frame, thereby exactly removing the influence of old frames as the window slides without replay. In 20 tests across five open-source hybrid VLMs and four video reasoning benchmarks, Spool achieved the lowest p95 time-to-first-token, with a geometric mean reduction of 6.6× compared to vLLM baselines, while improving accuracy by an average of 2.3 percentage points. This work provides a promising infrastructure-layer innovation for real-time video understanding applications, but complete cross-layer decoupling and engineering integration complexity remain open problems.

#Spool#hybrid vision-language models#streaming inference#low-latency#sliding window#recurrent layers#time-to-first-token#training-free framework
Share:

Related articles