Full Report

A Spatio-Temporal Joint Post-Training Quantization Framework for Delta-Rule Recurrent States

In the memory ledger of large model inference, the two most familiar entries are weights and KV Cache. Linear Attention rewrites the latter: it compresses historical information into a fixed-size recurrent state that no longer grows with sequence length.
New-generation hybrid architecture models such as Qwen3.8 and Kimi Linear have all introduced Delta-rule-based linear attention into their backbones.
But "fixed size" does not mean "free."
In high-concurrency serving, each request must exclusively occupy a resident state, and the memory of the state pool grows linearly with the number of concurrent requests, independent of context length. In the official SGLang deployment, the FP32 state pool of Qwen3.8-27B already exceeds the memory footprint of the BF16 weights themselves at around 70 concurrent requests. More troublesome still, directly quantizing the state to low bits causes a sharp drop in accuracy.
To this end, researchers from Zhejiang University, the Institute of Automation of the Chinese Academy of Sciences, and other institutions propose STEPQuant: a spatio-temporal joint post-training quantization framework for Delta-rule recurrent states. It approaches the problem from two dimensions—"when errors accumulate and where they land"—nearly matching the accuracy of FP32 states under a nominal 6-bit budget, and achieving over 5× state compression in SGLang, with total serving memory reduced by up to 68.7%.

- Paper title: STEPQuant: When and Where Errors Matter in Delta-Rule Recurrent State Quantization
- Paper link: https://arxiv.org/abs/2609.38169
- Project repository: https://github.com/Dreamer-Toby/STEPQuant
- The Problem
Why do quantization errors "snowball"?
The error of weight quantization is static, but the recurrent state is different. The Delta rule must read the old state, write new information, and store the result back at every decoding step. Once the state is stored in low bits, every step updates on top of an "old state carrying errors," which is then quantized again: old errors are carried into the next step, and new errors continue to accumulate.
On seven long-reasoning tasks with Qwen3.8-27B, uniform INT6 drops the average accuracy from 80.60% to 45.04%, INT4 leaves only 12.73%, and even INT8 shows a gap of nearly 9 points.
The paper decomposes the impact of errors into two complementary questions:
- When:
How long does an error stay in the state?
- Where:
Which position in the state matrix does the error land on?
- The Temporal Dimension
The "longer-lived" the memory, the more it deserves higher precision
Theoretical analysis shows that accumulated errors fade through two mechanisms: the decay of the retention gate, and the correction of the current key direction by the Delta update. For directions rarely hit by subsequent keys, the error can only rely on gate decay; when the retention rate is close to 1, it survives for many steps.
The researchers verified this on the 2304 recurrent heads of Qwen3.8-27B: the longer the gate half-life, the larger the accumulated state error, with a Spearman correlation coefficient of about 0.80 between the two.
Based on this, the paper proposes Lifetime-aware Bit Allocation:
- Lifetime-weighted precision allocation:
During offline calibration, estimate the distortion of each state unit at different bit widths, as well as its memory lifetime; under a fixed average bit budget, allocate more bits to units with "large errors and long lifetimes."
- Sparse pivot protection:
A very small number of high-risk units are difficult to quantize even with mixed precision, so they are kept directly as FP16. On Qwen, only 1.39% of heads need protection, bringing almost no additional storage pressure.
The allocation scheme is determined offline and fixed for all requests, introducing no additional allocation overhead at inference time.
- The Spatial Dimension
Rows have varying importance, and outliers span two axes
Besides "how long it stays," "where the error lands" is equally critical. The paper makes two findings about the spatial structure of the state matrix.

- Key rows are not equally important
Errors of the same magnitude landing on different key rows have different impacts on the output. The paper defines an impact score for each row and divides the key rows into eight groups by score, quantizing only one group to INT4 at a time. The results show that the higher the score of a group, the more pronounced the perplexity increase.
- Outliers appear on both rows and columns
Traditional LLM quantization usually only needs to handle outliers on a single axis, but the recurrent state is different: along the key-row and value-column directions, the ratios of maximum magnitude to median magnitude reach 10.3× and 19.4× respectively, and persist throughout the decoding process. Scaling along only one axis inevitably trades off one for the other.
To this end, the paper proposes Key-Row-Aware Dual-Axis Fitting: each row and each column is assigned an independent scaling coefficient, and each element in the state is reconstructed as "row coefficient × column coefficient × low-bit integer."
- Row coefficients
Balance magnitude and importance. Rows with large magnitudes receive a wider quantization range, and rows with large impact receive finer quantization granularity.
- Column coefficients:
Fitted after the row coefficients are determined, with reconstruction errors on high-impact rows penalized more heavily.
- From Algorithm to System
Fused kernel integrated into SGLang
Simulated quantization alone cannot save real memory. The team implemented STEPQuant as a packed-state kernel and integrated it into SGLang's recurrent state pool:
- Fused computation:
State reconstruction, Delta update, and readout of the current token are fused into a single kernel, avoiding an extra traversal of the entire state for reconstruction.
- Asynchronous write-back:
After the readout is complete, subsequent layers continue processing the token, while scale fitting and packed write-back are performed on a separate CUDA stream.
The state remains in compressed form across tokens at all times. Taking Qwen as an example, the recurrent state per request drops from 144 MiB to 28.6 MiB.
V. Experimental Results
6-bit is nearly lossless, and 4-bit surpasses INT8
The experiments cover two models, Qwen3.8-27B and Kimi-Linear-48B-A3B-Instruct, including seven long-reasoning tasks (LiveCodeBench, AIME 2026, GPQA Diamond, etc., with a maximum generation length of 65536 tokens per sample) and six short-generation tasks. Calibration requires only 32 segments of WikiText-2 text. The table below shows the average accuracy (%) across the seven long-reasoning tasks:

- Accuracy:
The gap between 6-bit STEPQuant and the FP32 state is less than 0.1 points; the 4-bit configuration surpasses uniform INT8 on both models. After stacking 4-bit AWQ weight quantization, the 6-bit configuration remains nearly lossless.
- Ablation:
Both modules are indispensable. Under Qwen's 4-bit budget, using only the spatial module yields 73.95%, using only the temporal module yields 12.87%, and combining both reaches 84.72%, on par with FP32 (84.61%).
- Generation length:
Uniform quantization makes the model "think longer and longer." Under INT4, Kimi's AIME outputs average 63.4K tokens, approaching the limit, yet accuracy is 0. In contrast, STEPQuant's output length is essentially consistent with FP32.
- Efficiency:
At a batch size of 512, Qwen's (4-bit weights) total serving memory drops from 419.73 GiB to 131.18 GiB, a reduction of 68.7%; recurrent state memory is compressed by 5.03x, and state updates are 2.91x faster. With BF16 weights, overall decoding throughput also improves by about 20%.

VI. Conclusion and Outlook
STEPQuant points out an easily overlooked fact: linear attention eliminates the KV Cache that grows with sequence length, but shifts the memory pressure onto a state pool that grows with concurrency. The paper's contributions can be summarized in three points:
- Error analysis:
From the perspectives of memory lifetime and spatial structure, it explains why quantization error is amplified in Delta updates.
- Quantization method:
Lifetime-aware bit allocation plus Key row-aware dual-axis fitting brings the 6-bit state close to FP32 precision.
- System implementation:
Fused kernels are integrated into SGLang, turning the compression ratio into real gains in memory and speed.
As more and more models adopt hybrid architectures of "linear attention + a small amount of full attention," state compression is expected to become a standard means of inference memory optimization alongside weight quantization and KV Cache quantization.