Virtual Head Attention
Summary
论文提出 Virtual Head Attention (VHA),通过轻量级线性 Q Premix 与 Linear Postmix 操作同时优化 KV cache 大小、训练/prefill FLOPs 与模型质量,在多个规模上超越 GQA 基线,并将 KV cache 相比 GQA-8 减少 4 倍。
View Cached Full Text
Cached at: 10/16/26, 11:03 AM
Paper page - Virtual Head Attention
Source: https://huggingface.co/papers/2610.17959
Abstract
Virtual Head Attention improves long-context model efficiency by reducing KV cache and compute while preserving quality through lightweight linear query and output transformations.
The design ofattention mechanismsinlong-context large language modelsfaces an ``impossible triangle’’ amongKV cachesize, training and prefill FLOPs, and model quality.GQAachieves strong quality but incurs highKV cacheoverhead; alternative approaches such as MLA and MFA can compress the cache, but MLA suffers from quality loss while MFA substantially increases training and prefill compute. We proposeVirtual Head Attention(VHA), which simultaneously improves all three vertices through two lightweight linear operations:Q Premixapplies a near-identity transformation to queries within each KV group to recover virtual head diversity from halved physical query heads, andLinear Postmixfuses inter-head features via a low-rank I + AB^top residual structure. Since VHA introduces no nonlinear operations, Premix can be folded into the query projection and Postmix into the output projection at inference time, reducing the model to a standardGQA-2 architecture that directly reuses all existingGQAinference optimizations. With only two KV heads, the group size in large models readily reaches 64, fully exploitingTensor Coreparallelism during decoding. Across four scales with 4K-context 50B-token pretraining, VHA consistently surpasses the standardGQAbaseline at every scale (+0.05\% to +0.81\%), while reducingKV cacheby 4times vs.\GQA-8 at dense scales and 2times vs.\GQA-4 at theMoEscale, and lowering training and prefill FLOPs by 7.9\% (1.7B, S{=}4096). On an industrial 30B-A3BMoEmodel trained on 500B tokens at 8K context, VHA outperforms both MLA andGQA-4 by +0.70\,/\,+2.60\,\% on a 12-benchmark base-model evaluation suite; in a separate matched 10B-A1BMoEcomparison after long-context mid-training, VHA attains an average RULER score of 84.4 over 8K--128K versus 73.0 forGQA, while using two rather than four KV heads in the full-attention layers.
View arXiv pageView PDFGitHub3Add to collection
Get this paper in your agent:
hf papers read 2610\.17959
Don’t have the latest CLI?curl \-LsSf https://hf\.co/cli/install\.sh \| bash
Models citing this paper0
No model linking this paper
Cite arxiv.org/abs/2610.17959 in a model README.md to link it from this page.
Datasets citing this paper0
No dataset linking this paper
Cite arxiv.org/abs/2610.17959 in a dataset README.md to link it from this page.
Spaces citing this paper0
No Space linking this paper
Cite arxiv.org/abs/2610.17959 in a Space README.md to link it from this page.
Collections including this paper0
No Collection including this paper
Add this paper to acollectionto link it from this page.
Similar Articles
RoLaQ: Joint Rotation and Range Calibration for 2-Bit KV Caches in Multi-Head Latent Attention
RoLaQ提出了针对多头潜注意力(MLA)模型的2位KV缓存联合旋转与范围校准的离线量化方法,在DeepSeek-V2-Lite上实现3.96倍BF16 KV容量和2.51倍解码吞吐提升。
RAQ-MLA: Role-Aware Quantization for Multi-Head Latent Attention Caches
提出了 RAQ-MLA,一种针对 Multi-Head Latent Attention 缓存的角色感知量化方法,无需训练即可将 MLA 缓存压缩至约 2.5 比特,在四个 MLA 模型上推理与编码任务几乎无损。
QuantWM: Temporally Consistent 2-Bit KV Cache Quantization for Video World Models
QuantWM 提出一种免训练的 2-bit KV cache 量化框架,通过量化敏感性感知聚类(QSAC)与主子空间注意力补偿(PSAC)来稳定视频世界模型的注意力 logits,缓解时间闪烁与视觉退化,并在多个基准上实现最高 6.20 倍 KV cache 内存压缩。
HeadGuard: Selective Head Protection for Low-Bit VLM KV-Cache Quantization
The paper introduces HeadGuard, a composable method that protects a small subset of KV heads in high precision while applying low-bit quantization to the rest of a VLM's image KV cache, substantially recovering accuracy lost by aggressive 2-bit quantization across multiple models and benchmarks.
Grouped Value Attention: Efficient KV Caching via On-Demand Key Reconstruction
Grouped Value Attention reduces transformer KV cache size by storing grouped values and reconstructing keys via a learned linear map, achieving near-GQA accuracy with a smaller persistent cache.