ADIndex: Layer-Adaptive Sparse Attention Indexing via Group-Level Distillation
Jin-Fei Qi, Yiduo Li, Jiang-Xin Shi, Kan Liu, Tao Lan, Hanlin Tang, Yu-Feng Li
Abstract
DeepSeek Sparse Attention (DSA) reduces the computational cost of attention through token-level selection. However, its indexer still scores the entire causal prefix for each query, making indexing a dominant source of latency in long-context inference. Notably, the indexer alone can account for more than 50% of total prefill GPU time at long context lengths. To address this bottleneck, we propose ADIndex, an Adaptive and Distillation-driven Indexing method for token-level sparse attention. ADIndex integrates three key components: (i) a layer-wise calibration strategy that adaptively accommodates cross-query retrieval overlap, motivated by our observation of pronounced inter-layer heterogeneity; (ii) a group-level distillation scheme that leverages this heterogeneity to efficiently train adaptive layer-wise group indexers, capturing salient retrieval signals from individual queries; and (iii) a low-latency inference strategy that reduces repeated full-prefix scans through token bank sharing within query groups while retaining query-specific refinement. Experiments on DeepSeek-V3.2 and GLM-5.1 demonstrate that ADIndex preserves near-lossless task performance on LongBench, LongBench v2, and RULER while delivering substantial efficiency gains over standard DSA, including prefill and decoding kernel speedups of up to 6.22x and 3.40x, respectively, at a context length of 256K across the layer-wise reuse configurations, as well as an end-to-end serving speedup of 1.54x at a context length of 128K.
Create a lesson
Metadata
- Categories
- cs.LG, cs.AI
- Comments
- 27 pages,13 figures
Related papers
QASparse: Query-Adaptive Sparse Attention with Tailored Budgets and Tokens
Shared title terminologycs.LGZhiyuan Chen, Zihao Yang, Quanjiang Li et al.
Translating KV Caches Between Hybrid-Attention Language Models: MLA Latents, Linear-Attention States and Sparse-Attention Indexers
Shared title terminologycs.LGPovilas Kvedaras, Tomas Rasymas
CLAIR: Consistent LLM Adaptation via Index-free Reprogramming
Shared title terminologycs.LGDongkuk Kim, Jungkyu Shin, Yoonhyuk Choi et al.
DisSparse: Pipelined Top-p Sparse Attention for Long-Context LLM Serving
Shared title terminologycs.LGNurlan Nazaraliyev, Elaheh Sadredini, Nael Abu-Ghazaleh
RefineKV: Query-Adaptive KV Cache Compression via Attention-Error Bounds
Shared title terminologycs.LGKewei Lian, Jiayi Zhai, Anji Liu
Coverage-Verified Sparse Attention: Closed-Loop Quality Control for Long-Context LLM Decoding
Shared title terminologycs.LGYan-Cheng Li, Chun-Yi Lee