OBCache: Optimal Brain KV Cache Pruning for Efficient Long-Context LLM Inference
On the map: Efficient LLM inference and serving → KV cache optimization
Abstract (arXiv)
Large language models (LLMs) with extended context windows enable powerful applications but impose significant memory overhead, as caching all key-value (KV) states scales linearly with sequence length and batch size. Existing cache eviction methods address this by exploiting attention sparsity, yet they typically rank tokens heuristically using accumulated attention weights without considering their true impact on attention outputs. We propose Optimal Brain Cache (OBCache), a principled framework that formulates cache eviction as a layer-wise structured pruning problem. Building upon the Optimal Brain Damage (OBD) theory, OBCache quantifies token saliency by measuring the perturbation in attention outputs induced by pruning tokens, with closed-form scores derived for isolated keys, isolated values, and joint key-value pairs. Our scores account not only for attention weights but also for information from value states and attention outputs, thereby enhancing existing eviction strategies with output-aware signals. Experiments on LLaMA and Qwen models demonstrate that replacing the heuristic scores in existing works, which estimate token saliency across different query positions, with OBCache's output-aware scores consistently improves long-context accuracy. Code is available at https://github.com/DreamSoul-AI/OBCache.
Key facts. Cited by 10 papers in the map (data through 14 Oct 2026). Placed in KV cache optimization, one of 12 directions in Efficient LLM inference and serving. Builds on 29 of its 41 references that are in the map. First posted on arXiv 9 Oct 2025.
Builds on
29 of 41 references.
Closest ancestors · 12
Same direction, newest first
- 2025Expected Attention: KV Cache Compression by Estimating Attention from Future Queries Distribution1 Oct
- 2025KVzip: Query-Agnostic KV Cache Compression with Context Reconstruction29 May
- 2025CAKE: Cascading and Adaptive KV Cache Eviction with Layer Preferences16 Mar
- 2024ShadowKV: KV Cache in Shadows for High-Throughput Long-Context LLM Inference28 Oct
- 2024Not All Heads Matter: A Head-Level KV Cache Compression Method with Integrated Retrieval and Reasoning25 Oct
- 2024Ada-KV: Optimizing KV Cache Eviction by Adaptive Budget Allocation for Efficient LLM Inference16 Jul
- 2024D2O: Dynamic Discriminative Operations for Efficient Long-Context Inference of Large Language Models18 Jun
- 2024Attention Score is not All You Need for Token Importance Indicator in KV Cache Reduction: Value Also Matters18 Jun
- 2024Quest: Query-Aware Sparsity for Efficient Long-Context LLM Inference16 Jun
- 2024PyramidKV: Dynamic KV Cache Compression based on Pyramidal Information Funneling4 Jun
- 2024SnapKV: LLM Knows What You are Looking for Before Generation22 Apr
- 2023H2O: Heavy-Hitter Oracle for Efficient Generative Inference of Large Language Models24 Jun
Other references · 17
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,305
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2023LLaMA: Open and Efficient Foundation Language Modelscited by 14,132
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 13,028
- 2023Qwen Technical Reportcited by 3,344
- 2023FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioningcited by 2,598
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,186
- 2023Code Llama: Open Foundation Models for Codecited by 2,139
- 2023LongBench: A Bilingual, Multitask Benchmark for Long Context Understandingcited by 1,417
- 2024RULER: What's the Real Context Size of Your Long-Context Language Models?cited by 1,346
- 2023SparseGPT: Massive Language Models Can Be Accurately Pruned in One-Shotcited by 1,121
- 2023A Simple and Effective Pruning Approach for Large Language Modelscited by 800
5 more
- 2019Compressive Transformers for Long-Range Sequence Modellingcited by 726
- 2023LLM-Pruner: On the Structural Pruning of Large Language Modelscited by 650
- 2023Benchmarking Large Language Models for News Summarizationcited by 445
- 2024Transformers are Multi-State RNNscited by 120
- 2023Evaluating Open-Domain Question Answering in the Era of Large Language Modelscited by 111
Built on by
Citing papers per year: 2026: 10.
10 papers.
- 2026Attention Sink in Transformers: A Survey on Utilization, Interpretation, and Mitigationcited by 11
- 2026RDKV: Rate-Distortion Bit Allocation for Joint Eviction and Quantization of the KV Cachecited by 4
- 2026ResKV: Reconstructing Omitted Attention Contributions for Fixed-Budget KV Cache Compressioncited by 3
- 2026Adaptive Filtering of the KV Cache: Diagnosing and Correcting Structural-Role Bias in LLM Inferencecited by 1
- 2026AnchorKV: Anchor-Residual KV Cache Compressioncited by 1
- 2026Monte Carlo Estimation for KV Cache Evictioncited by 1
- 2026KVSlimmer: Theoretical Insights and Practical Optimizations for Asymmetric KV Mergingcited by 0
- 2026ART: Attention Run-time Termination for Efficient Large Language Model Decodingcited by 0
- 2026ReSS: Residual-Restoring Sparse Attention for 3D Vision Transformerscited by 0
- 2026KVFetch: Temporal Prefetching for the Missing Half of KV Cache Compressioncited by 0
- 2026Monte Carlo Estimation for KV Cache Eviction6 Oct 2026
- 2026ReSS: Residual-Restoring Sparse Attention for 3D Vision Transformers28 Sep 2026
- 2026KVFetch: Temporal Prefetching for the Missing Half of KV Cache Compression23 Sep 2026
- 2026AnchorKV: Anchor-Residual KV Cache Compression3 Aug 2026
- 2026ResKV: Reconstructing Omitted Attention Contributions for Fixed-Budget KV Cache Compression31 Jul 2026
- 2026Adaptive Filtering of the KV Cache: Diagnosing and Correcting Structural-Role Bias in LLM Inference14 Jul 2026
- 2026RDKV: Rate-Distortion Bit Allocation for Joint Eviction and Quantization of the KV Cache8 May 2026
- 2026ART: Attention Run-time Termination for Efficient Large Language Model Decoding15 Apr 2026
- 2026Attention Sink in Transformers: A Survey on Utilization, Interpretation, and Mitigation11 Apr 2026
- 2026KVSlimmer: Theoretical Insights and Practical Optimizations for Asymmetric KV Merging1 Mar 2026
Similar, not cited
Close in wording, no citation either way
- 2025LLMs Know What to Drop: Self-Attention Guided KV Cache Eviction for Efficient Long-Context Inference
- 2024ThinK: Thinner Key Cache by Query-Driven Pruning
- 2026Reformulating KV Cache Eviction Problem for Long-Context LLM Inference
- 2026Make Each Token Count: Towards Improving Long-Context Performance with KV Cache Eviction
- 2024NACL: A General and Effective KV Cache Eviction Framework for LLMs at Inference Time
- 2025SmallKV: Small Model Assisted Compensation of KV Cache Compression for Efficient LLM Inference
- 2025Task-KV: Task-aware KV Cache Optimization via Semantic Differentiation of Attention Heads
- 2025Progressive Sparse Attention: Algorithm and System Co-design for Efficient Attention in LLM Serving