UNIQUE: Universal Top-k Sparse Attention for Training-free Inference and Sparsity-aware Training

Keqi Deng, Shaoshi Ling, Ruchao Fan, Jinyu Li


Abstract
Long-context inference in large language models (LLMs) is bottlenecked by the linear growth of the self-attention key-value (KV) cache. Top-k sparse attention alleviates this by loading only a small fraction of the KV cache, but accurately and cheaply estimating cache importance, for both training-free use and sparsity-aware training, remains challenging. This paper proposes UNIQUE, a universal top-k sparse attention framework that addresses both requirements and stays consistently effective across LLM modalities. UNIQUE operates at the granularity of KV pages and estimates per-page importance with a simple yet accurate score combining the mean of the page’s keys as a representative vector with their standard deviation as an offset term. To further close the train-inference gap, this paper introduces a soft-mask sparsity-aware training scheme that uses the top-k score boundary as a per-query threshold and a sigmoid soft mask around it, requiring neither auxiliary losses nor architectural changes. Experiments on text and speech LLMs show that UNIQUE preserves task performance on long-context benchmarks such as LongBench Pro and on long-form speech recognition, while delivering up to 11.4× attention-kernel speedup over FlashInfer dense attention and at least 5.3× end-to-end decoding speedup over a vLLM-based dense model.
Anthology ID:
2026.emnlp-main.1774
Volume:
Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing
Month:
October
Year:
2026
Address:
Budapest, Hungary
Editors:
Hung-Yi Lee, Sunipa Dev, Jessy Li, Desmond Elliott
Venue:
EMNLP
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
40428–40440
Language:
URL:
https://aclanthology.org/2026.emnlp-main.1774/
DOI:
Bibkey:
Cite (ACL):
Keqi Deng, Shaoshi Ling, Ruchao Fan, and Jinyu Li. 2026. UNIQUE: Universal Top-k Sparse Attention for Training-free Inference and Sparsity-aware Training. In Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing, pages 40428–40440, Budapest, Hungary. Association for Computational Linguistics.
Cite (Informal):
UNIQUE: Universal Top-k Sparse Attention for Training-free Inference and Sparsity-aware Training (Deng et al., EMNLP 2026)
Copy Citation:
PDF:
https://aclanthology.org/2026.emnlp-main.1774.pdf