LeapQuant: Efficient Linear Attention with Accurate Recurrent State Quantization
cs.LG, cs.AI
Submitted: 2026-09-29
Updated: 2026-09-29
Comments: 17 pages, 11 figures
Code: https://github.com/fla-org/flash-linear-attention
License: http://creativecommons.org/licenses/by/4.0/
The gist: Recent LLMs increasingly adopt hybrid designs that replace standard attention with linear attention, such as Gated DeltaNet (GDN) and Kimi Delta Attention (KDA).
Terminology
Abstract
Recent LLMs increasingly adopt hybrid designs that replace standard attention with linear attention, such as Gated DeltaNet (GDN) and Kimi Delta Attention (KDA). Although they compress the context into a fixed-size recurrent state and substantially reduce the cost of long-context processing, repeatedly reading and updating that state remains a major inference bottleneck. Quantization offers a natural way to reduce this cost, but can significantly degrade model quality, due to the accumulation of rounding errors and the presence of outlier rows and columns in the state. To address these challenges, we propose LeapQuant, a training-free method that achieves near-lossless performance under 8-bit recurrent-state quantization. First, to mitigate error accumulation, we propose per-window quantization, which leaps over a window of tokens and quantizes the state only once at its end. Within a window, outputs are computed from the fixed low-bit state together with high-precision buffered updates. Second, to reduce the error introduced by each quantization, LeapQuant retains the state's largest outliers as a few high-precision Compensator Tokens, which share the update path of real tokens. We then smooth the remaining residual before quantization to further reduce the error. Comprehensive experiments across the Qwen, Kimi, and GLM model families show that LeapQuant substantially reduces memory and compute costs during inference. With accuracy comparable to the FP32 baseline, it achieves average speedups of 2.05--3.70 times at the kernel level and 1.47 times for end-to-end inference on NVIDIA B200, RTX PRO 6000, and RTX 5090 GPUs.
Sources
- Nemotron-H: A Family of Accurate and Efficient Hybrid Mamba-Transformer Models
- Quamba2: A Robust and Scalable Post-training Quantization Framework for Selective State Space Models
- Training Verifiers to Solve Math Word Problems
- Transformers are SSMs: Generalized Models and Efficient Algorithms Through Structured State Space Duality
- GPTQ: Accurate Post-Training Quantization for Generative Pre-trained Transformers
- GEAR: An Efficient KV Cache Compression Recipe for Near-Lossless Generative Inference of LLM
- SVDQuant: Absorbing Outliers by Low-Rank Components for 4-Bit Diffusion Models
- KIVI: A Tuning-Free Asymmetric 2bit Quantization for KV Cache
- Eagle and Finch: RWKV with Matrix-Valued States and Dynamic Recurrence
- RWKV-7 "Goose" with Expressive Dynamic State Evolution
- HGRN2: Gated Linear RNNs with State Expansion
- GPQA: A Graduate-Level Google-Proof Q&A Benchmark
- DeltaProduct: Improving State-Tracking in Linear RNNs via Householder Products
- Retentive Network: A Successor to Transformer for Large Language Models
- Kimi Linear: An Expressive, Efficient Attention Architecture
- Kimi K3: Open Frontier Intelligence
- TileLang: A Composable Tiled Programming Model for AI Systems
- Gated Linear Attention Transformers with Hardware-Efficient Training
Related papers
- Polynomial-Augmented Neural Networks (PANNs) with Weak Orthogonality Constraints for Enhanced Function and PDE Approximation
- AIRL-S: Unifying Reinforcement Learning and Search-Based Test-Time Scaling via Adversarial Inverse Reinforcement Learning
- Transformers as Bayesian In-Context Experimenters: Smoothness-Adaptive Efficient ATE Estimation
- Convergence issues in Relational Concept Analysis based on AOC-posets
- Beliefs Beyond Posteriors: The Predictive Cost of ELBO Binding
- Understanding Diffusion Models via Ratio-Based Function Approximation with SignReLU Networks