Near-Oracle KV Selection via Pre-hoc Sparsity for Long-Context Inference
Yifei Gao, Lei Wang, Rong-Cheng Tu, Qixin Zhang, Jun Cheng, Dacheng Tao

TL;DR
This paper introduces Pre-hoc Sparsity (PrHS), a method for selecting key-value entries before attention scoring in large language models, significantly reducing computation while maintaining accuracy.
Contribution
PrHS provides a novel pre-hoc KV selection approach with explicit accuracy control, addressing bias issues in posterior heuristics and enabling verifiable guarantees.
Findings
Reduces retrieval overhead by over 90% on benchmarks.
Achieves 3x higher retrieval sparsity with maintained or improved accuracy.
Yields 9.9x speedup in attention latency and 2.8x higher throughput.
Abstract
A core bottleneck in large language model (LLM) inference is the cost of attending over the ever-growing key-value (KV) cache. Although near-oracle top-k KV selection can preserve the quality of dense attention while sharply reducing computation and bandwidth, existing sparse methods generally rely on posterior heuristics, i.e., selectors conditioned on observed attention or proxy scores. Such conditioning introduces posterior bias: it tends to distort true token importance and miss salient tokens, thereby impairing long-range reasoning. To tackle this problem, we propose Pre-hoc Sparsity (PrHS), which selects KV entries before attention scoring and provides explicit accuracy control. Let the attention mass of discarded entries be delta (the dropped mass). Through a marginal-to-mutual-information analysis, we derive an upper bound on the mutual-information loss that depends only on the…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsCaching and Content Delivery · Data Quality and Management · Advanced Neural Network Applications
