EMNLP Findings2025
DynamicKV: Task-Aware Adaptive KV Cache Compression for Long Context LLMs
Xiabin Zhou, Wenbin Wang, Minyan Zeng, Jiaxian Guo, Xuebo Liu, Li Shen, Min Zhang, Liang Ding
摘要
Efficient KV cache management in LLMs is crucial for long-context tasks like RAG and summarization.Existing KV cache compression methods enforce a fixed pattern, neglecting task-specific characteristics and reducing the retention of essential information.However, we observe distinct activation patterns across layers in various tasks, highlighting the need for adaptive strategies tailored to each task's unique demands.Based on this insight, we propose DynamicKV, a method that dynamically optimizes token retention by adjusting the number of tokens retained at each layer to adapt to the specific task.DynamicKV establishes global and per-layer maximum KV cache budgets, temporarily retaining the maximum budget for the current layer, and periodically updating the KV cache sizes of all preceding layers during inference.Our method retains only 1.7% of the KV cache size while achieving ∼ 90% of the Full KV cache performance on LongBench.Notably, even under extreme compression (0.9%), DynamicKV surpasses state-of-the-art (SOTA) methods by 11% in the Needle-in-a-Haystack test using Mistral-7B-Instruct-v0.2.The code is available at repository https://github.com/DreamMr/ DynamicKV. KV Cache SizeLayer Step a. FullKV b.StreamingLLM/H2O/SnapKV c. PyramidKV d.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 9 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache Quantization 引用了 Efficient Streaming Language Models with Attention Sinks
- KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache Quantization 引用了 SnapKV: LLM Knows What You are Looking for Before Generation
- ReST-KV: Robust KV Cache Eviction with Layer-wise Output Reconstruction and Spatial-Temporal Smoothing 引用了 Efficient Streaming Language Models with Attention Sinks
- SnapKV: LLM Knows What You are Looking for Before Generation 引用了 Efficient Streaming Language Models with Attention Sinks
- Twilight: Adaptive Attention Sparsity with Hierarchical Top-p Pruning 引用了 Efficient Streaming Language Models with Attention Sinks
- Twilight: Adaptive Attention Sparsity with Hierarchical Top-p Pruning 引用了 SnapKV: LLM Knows What You are Looking for Before Generation
- Twilight: Adaptive Attention Sparsity with Hierarchical Top-p Pruning 引用了 Efficient Memory Management for Large Language Model Serving with PagedAttention
- Accurate KV Cache Eviction via Anchor Direction Projection for Efficient LLM Inference 引用了 Efficient Streaming Language Models with Attention Sinks
- Accurate KV Cache Eviction via Anchor Direction Projection for Efficient LLM Inference 引用了 KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache Quantization
- Accurate KV Cache Eviction via Anchor Direction Projection for Efficient LLM Inference 引用了 SnapKV: LLM Knows What You are Looking for Before Generation
- From Prefix Cache to Fusion RAG Cache: Accelerating LLM Inference in Retrieval-Augmented Generation 引用了 Efficient Streaming Language Models with Attention Sinks
- From Prefix Cache to Fusion RAG Cache: Accelerating LLM Inference in Retrieval-Augmented Generation 引用了 SnapKV: LLM Knows What You are Looking for Before Generation
- From Prefix Cache to Fusion RAG Cache: Accelerating LLM Inference in Retrieval-Augmented Generation 引用了 Efficient Memory Management for Large Language Model Serving with PagedAttention
- From Prefix Cache to Fusion RAG Cache: Accelerating LLM Inference in Retrieval-Augmented Generation 引用了 Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks
引用它的顶会 Paper9
- OmniSVG: A Unified Scalable Vector Graphics Generation ModelYiying Yang, Wei Cheng, Sijin Chen, Xianfang Zeng 等NeurIPS 2025 · 90 次引用
- Twilight: Adaptive Attention Sparsity with Hierarchical Top- PruningChaofan Lin, Jiaming Tang, Shuo Yang, Hanshuo Wang 等NeurIPS 2025 · 53 次引用
- ReST-KV: Robust KV Cache Eviction with Layer-wise Output Reconstruction and Spatial-Temporal SmoothingYongqi An, Chang Lu, Kuan Zhu, Tao Yu 等ICLR 2026 · 11 次引用
- Accurate KV Cache Eviction via Anchor Direction Projection for Efficient LLM InferenceZijie Geng, Jie Wang, Ziqi Liu, Feng Ju 等NeurIPS 2025 · 6 次引用
- From Prefix Cache to Fusion RAG Cache: Accelerating LLM Inference in Retrieval-Augmented GenerationJiahao Wang, Weiyu Xie, Mingxing Zhang, Boxin Zhang 等SIGMOD 2026 · 4 次引用
它引用的 Paper15
- Retrieval-Augmented Generation for Knowledge-Intensive NLP TasksPatrick Lewis, Ethan Perez, Aleksandra Piktus, Fabio Petroni 等NeurIPS 2020 · 19,162 次引用
- Efficient Streaming Language Models with Attention SinksGuangxuan Xiao, Yuandong Tian, Beidi Chen, Song Han 等ICLR 2024 · 1,714 次引用
- SnapKV: LLM Knows What You are Looking for Before GenerationYuhong Li, Yingbing Huang, Bowen Yang, Bharat Venkitesh 等NeurIPS 2024 · 1,019 次引用
- Efficient Memory Management for Large Language Model Serving with PagedAttentionWoosuk Kwon, Zhuohan Li, Siyuan Zhuang, Ying Sheng 等SOSP 2023 · 1,016 次引用
- KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache QuantizationColeman Hooper, Sehoon Kim, Hiva Mohammadzadeh, Michael W. Mahoney 等NeurIPS 2024 · 738 次引用
相关 Paper
- LAVa: Layer-wise KV Cache Eviction with Dynamic Budget AllocationYiqun Shen, Song Yuan, Zhengze Zhang, Xiaoliang Wang 等EMNLP Findings 2025
- Not All Heads Matter: A Head-Level KV Cache Compression Method with Integrated Retrieval and ReasoningYu Fu, Zefan Cai, Abedelkadir Asi, Wayne Xiong 等ICLR 2025
- IndexMem: Learned KV-Cache Eviction with Latent Memory for Long-Context LLM InferenceXintong Yang, Hao Gu, Binxing Xu, Lujun Li 等ICML 2026 · 2 次引用
- KVmix: Gradient-Based Layer Importance-Aware Mixed-Precision Quantization for KV CacheFei Li, Song Liu, Weiguo Wu, Shiqiang Nie 等AAAI 2026 · 1 次引用
- EntroKV: Entropy-Guided Dynamic Budget Allocation for KV-Cache CompressionWenhao Gao, Haoran Cao, Yueyan Li, YongGao Xiao 等ICML 2026
