QuantMLA: Function-Aligned Dual-Path Quantization for Low-Bit MLA KV Caching
cs.LG, cs.CL
Submitted: 2026-09-29
Updated: 2026-09-30
Code: https://github.com/meituan-longcat/LongCat-2.0
License: http://creativecommons.org/licenses/by/4.0/
The gist: Multi-Head Latent Attention (MLA) enables expressive multi-head attention with compact caches for its content and decoupled RoPE paths, yet cache memory still scales linearly with context length and
Terminology
Abstract
Multi-Head Latent Attention (MLA) enables expressive multi-head attention with compact caches for its content and decoupled RoPE paths, yet cache memory still scales linearly with context length and batch size. In this work, we establish a systematic model of MLA's dual-path quantization errors, characterizing their distinct effects on attention-output distortion and explaining the pronounced amplification of RoPE-path errors. Guided by this analysis, we introduce QuantMLA, a function-aligned framework for low-bit dual-path quantization. We derive path-specific transformation spaces that preserve full-precision computation while remaining fully fusible into model parameters offline, eliminating online transformation overhead. Within these spaces, QuantMLA learns path-specific transformations with function-aligned objectives: attention-output reconstruction captures the content path's coupled matching and aggregation errors, while positional QK reconstruction preserves the RoPE-induced component of the attention logits and admits a theoretical bound on output distortion. Across four MLA model families, QuantMLA enables, to our knowledge, the first reported joint INT4 caching of the content and RoPE caches with minimal accuracy degradation. Further compressing the content cache to INT2 while retaining the RoPE key cache at INT4 maintains competitive performance on challenging reasoning and code benchmarks. We develop a native low-bit MLA attention kernel that integrates unpacking and dequantization directly into attention computation. The physical cache layout provides 3.59x compression at 128K context, while a cache-pressure serving workload achieves 5.168x higher whole-job output throughput than BF16. The code will be released upon acceptance.
Sources
- PIQA: Reasoning about Physical Commonsense in Natural Language
- Evaluating Large Language Models Trained on Code
- Think you have Solved Question Answering? Try ARC, the AI2 Reasoning Challenge
- Training Verifiers to Solve Math Word Problems
- DeepSeek-V2: A Strong, Economical, and Efficient Mixture-of-Experts Language Model
- DeepSeek-V3 Technical Report
- DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learning
- SKVQ: Sliding-window Key and Value Cache Quantization for Large Language Models
- PolarQuant: Quantizing KV Caches with Polar Transformation
- Measuring Mathematical Problem Solving With the MATH Dataset
- OstQuant: Refining Large Language Model Quantization with Orthogonal and Scaling Transformations for Better Distribution Fitting
- Kimi K2: Open Agentic Intelligence
- Kimi Linear: An Expressive, Efficient Attention Architecture
- Efficient Memory Management for Large Language Model Serving with PagedAttention
- DuQuant: Distributing Outliers via Dual Transformation Makes Stronger Quantized LLMs
- Muon is Scalable for LLM Training
- Quantization Hurts Reasoning? An Empirical Study on Quantized Reasoning Models
- LongCat-Flash Technical Report
- SQuAD: 100,000+ Questions for Machine Comprehension of Text
- WinoGrande: An Adversarial Winograd Schema Challenge at Scale
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