AVQ-Attention-2: Adaptive Vector-Quantized Attention with Exact Local Blocks and Linear-Cost Training
Winfried van den Dool, Patrick Forr\'e, Amir Habibian, Yuki M. Asano, Max Welling
Key points
From the paper's conclusion- We present AVQ-Attention-2, a better design that merges it with exact local attention and attends to the mean of each cluster's keys rather than to a codeword.
Abstract
Attention costs $\mathcal{O}(N^2)$ in the number of tokens. Vector-quantized attention reduces this to $\mathcal{O}(NM)$ by clustering the $N$ keys, attending to the $M$ codewords instead, and its adaptive form, AVQ-attention, concentrates codebook resolution where a query's attention mass actually falls. We present AVQ-Attention-2, a better design that merges it with exact local attention and attends to the mean of each cluster's keys rather than to a codeword. We show three improvements: consistently better quality at comparable cost; training that now also costs $\mathcal{O}(NM)$ rather than $\mathcal{O}(N^2)$; and an approximation accurate enough that the layer can be dropped into a pretrained transformer without fine-tuning. Across a variety of sequence lengths the result is competitive not merely with other approximate attention but with exact dense attention, running faster than FlashAttention at little to no loss in quality.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- DeCo-Attention: Decompose to Compensate for Low-Precision AttentionarXiv · 2026
- TriAttention: Unified Sparse Mixed-Precision Attention for Long-Context LLM InferencearXiv · 2026
- VAR-Q: Tuning-free KV Cache Quantization for Visual Autoregressive Image and Video GenerationarXiv · 2026
- CoS-VQ: Coordinated Shared-Scale Vector Quantization for Large Language ModelsarXiv · 2026
- Fast and Exact Relative-Position Attention via Structure-Aware KernelsarXiv · 2026
- Efficiently Approximating Attention Is HardarXiv · 2026