TL;DR
Hybrid linear-attention LLMs replace ballooning KV caches with fixed-size memory matrices, yet serving AI agents still demands saving dozens of bulky "checkpoints" of these matrices to avoid re-reading long prompts from scratch. WEAVE solves this hidden memory bottleneck without any model retraining by realizing that while full memory states are complex, the changes between them are remarkably simple. By capturing these low-rank changes directly as the model runs, WEAVE shrinks checkpoint footprints by over 4×, slashing latency by up to nearly 7× under heavy traffic.
What Problem Does This Paper Address?
Standard Transformers remember past text using a Key-Value (KV) cache that grows linearly with prompt length. Newer hybrid architectures (like Qwen3.5 and Kimi-Linear) swap out most full-attention layers for linear attention, compressing history into a fixed-size matrix called a recurrent state.
Fixed size sounds like a free lunch for GPU memory—until you serve multi-turn AI agents. Agents constantly branch and reuse long prompt prefixes (often 100K+ tokens). With a standard KV cache, reusing a prefix is trivial because every token is indexed individually. A recurrent state, however, overwrites itself at every step; you can't "rewind" it to token 5,000 unless you saved a snapshot there.
To avoid recomputing prompts from zero, serving systems save periodic recurrent-state checkpoints. Ironically, each checkpoint is massive—equivalent to ~3,200 tokens of full-attention KV cache. Under concurrent load, GPUs run out of memory, evict checkpoints, and are forced to recompute huge prefixes anyway. Furthermore, naive compression fails: unlike independent KV vectors, recurrent states are tightly coupled matrices that get repeatedly multiplied and updated. Crushing them down to 4-bit integers (INT4) triggers severe, compounding accuracy collapse.
Methods
Instead of treating each checkpoint as an isolated dense tensor to be quantized, WEAVE compresses the trajectory of how the state evolves, combining three core techniques:
- Shared-Anchor Residual Factorization: Chaining differences from one checkpoint to the next ($H_t = H_{t-1} + \Delta$) creates fragile domino chains where losing one piece breaks everything downstream. Instead, WEAVE saves a full "anchor" state ($H_a$) and encodes subsequent checkpoints in that span as compact, low-rank residual factors ($U_t V_t^\top$, quantized to INT8) relative to that single shared anchor.
- Recurrence-Driven State Encoding: Computing a dense difference matrix and running Singular Value Decomposition (SVD) online takes nearly a second per checkpoint—way too slow for live serving. WEAVE bypasses dense matrices entirely. Because linear attention natively updates states using structured, skinny write vectors, WEAVE intercepts these native updates on the fly and projects them into tiny, fixed-width "sketches" (for Gated DeltaNet) or bounded factor cores (for Kimi Delta Attention), converting them to final factors only when publishing a checkpoint.
- System Co-Design & Periodic Compaction: WEAVE integrates directly into vLLM’s prefix-caching engine. It uses periodic compaction (bounding recovery to at most a one-step dependency) and custom, rank-bucketed Triton GPU kernels that run asynchronously without blocking token generation.
Datasets
Because WEAVE is completely training-free, no training datasets are used. The authors evaluate Qwen3.5-35B-A3B and Kimi-Linear-48B across six established benchmarks (no new benchmarks are introduced):
- Reasoning: MMLU, AIME2026
- Long-Context Understanding: RepoQA, QMSum
- Agentic Execution: SWE-bench Verified, AppWorld
Key Insights and Ideas
Motivation for recurrent-state compression showing low-rank residuals, quantization errors, and SVD costs.
- Full states are dense, but state evolution is low-rank: Linear attention updates memory by decaying old info and injecting structured writes that repeatedly reuse the same directions. Even across a massive 122K-token span from an anchor, a median rank of just 5 (out of 128 dimensions) captures 95% of the residual energy.
- Model evolution is a compression primitive: You don't need to wait until a massive state matrix is materialized to compress it. By tapping into the mathematical transition terms the LLM already computes during its forward pass, WEAVE cuts checkpoint encoding time by 94× compared to dense SVD (from 995 ms down to 10.6 ms).
- Surgical tail repair beats uniform bloat: Different attention heads compress differently. WEAVE assigns static rank buckets offline and applies lightweight, bounded error repair or exact fallback to the tiny handful of sensitive heads (e.g., just 7 out of 960 heads in ablation tests), preserving accuracy without inflating memory everywhere.
Key Results
- High Compression, Near-Lossless Quality: WEAVE compresses recurrent checkpoints by 4.26× on Qwen3.5-35B-A3B and 4.12× on Kimi-Linear-48B. While INT4 quantization (3.26× compression) causes Kimi's SWE-bench score to plummet by 47.2% (from 28.66 to 15.12), WEAVE scores 27.98, outperforming both INT4 and INT8 across all six benchmarks.
- Major Online Serving Gains: Replaying concurrent SWE-bench agent streams in vLLM (at concurrency 48), WEAVE slashes prefix recomputation from 68% down to ~8.5%. For Qwen, this yields up to 6.96× lower Time-To-First-Token (TTFT) (dropping from 21.25s to 3.05s) and 3.14× higher token goodput under Service Level Objective (SLO) constraints.
- Minimal Overhead: Asynchronous encoding and Triton kernels keep foreground latency interference under 3.51%.
Limitations and Future Work
While the paper does not feature a standalone limitations section, two constraints are apparent from the design: WEAVE relies on offline profiling to map each (layer, head) pair to static rank buckets, and its recurrence-driven encoders must be mathematically tailored to specific linear-attention update rules (such as GDN's scalar decay vs. KDA's channel-wise diagonal transport).
For future work, the authors note that WEAVE only compresses how checkpoints are stored, leaving which checkpoints to keep to existing cache policies. They envision building a unified cache manager that jointly optimizes memory allocation and compression effort across both linear-attention recurrent checkpoints and full-attention KV caches dynamically based on live workload demand.
Summary updated