TreeKV: Smooth Key-Value Cache Compression with Tree Structures
On the map: Efficient LLM inference and serving → KV cache optimization
Abstract (arXiv)
Efficient key-value (KV) cache compression is critical for scaling transformer-based Large Language Models (LLMs) in long sequences and resource-limited settings. Existing methods evict tokens based on their positions or importance scores, but position-based strategies can miss crucial information outside predefined regions, while those relying on global importance scores resulting in strong regional biases, limiting the KV cache's overall context retention and potentially impairing the performance of LLMs on complex tasks. Our wavelet analysis reveals that as tokens approach the end of sequence, their contributions to generation gradually increase and tends to diverge more from neighboring tokens, indicating a smooth transition with increasing complexity and variability from distant to nearby context. Motivated by this observation, we propose TreeKV, an intuitive, training-free method that employs a tree structure for smooth cache compression. TreeKV maintains a fixed cache size, allowing LLMs to deliver high-quality output even in long text scenarios. Unlike most compression methods, TreeKV is applicable to both the generation and prefilling stages. TreeKV consistently surpasses all baseline models in language modeling tasks on PG19 and OpenWebText2, allowing LLMs trained with short context window to generalize to longer window with a 16x cache reduction. On the Longbench benchmark, TreeKV achieves the best performance with only 6% of the budget at optimal efficiency.
Key facts. Cited by 3 papers in the map (data through 7 Oct 2026). Placed in KV cache optimization, one of 12 directions in Efficient LLM inference and serving. Builds on 20 of its 22 references that are in the map. First posted on arXiv 9 Jan 2025.
Builds on
20 of 22 references.
Closest ancestors · 5
Same direction, newest first
- 2024PyramidKV: Dynamic KV Cache Compression based on Pyramidal Information Funneling4 Jun
- 2024PyramidInfer: Pyramid KV Cache Compression for High-throughput LLM Inference21 May
- 2024SnapKV: LLM Knows What You are Looking for Before Generation22 Apr
- 2023H2O: Heavy-Hitter Oracle for Efficient Generative Inference of Large Language Models24 Jun
- 2023Scissorhands: Exploiting the Persistence of Importance Hypothesis for LLM KV Cache Compression at Test Time26 May
Other references · 15
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 12,865
- 2022Emergent Abilities of Large Language Modelscited by 2,483
- 2020The Pile: An 800GB Dataset of Diverse Text for Language Modelingcited by 2,346
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,115
- 2023LongBench: A Bilingual, Multitask Benchmark for Long Context Understandingcited by 1,378
- 2019Compressive Transformers for Long-Range Sequence Modellingcited by 699
- 2022Efficiently Scaling Transformer Inferencecited by 529
- 2023Benchmarking Large Language Models for News Summarizationcited by 444
- 2023LM-Infinite: Zero-Shot Extreme Length Generalization for Large Language Modelscited by 120
- 2024Transformers are Multi-State RNNscited by 120
- 2023Fourier Transformer: Fast Long Range Modeling by Removing Sequence Redundancy with FFT Operatorcited by 19
- 2022DCT-Former: Efficient Self-Attention with Discrete Cosine Transformcited by 12
Built on by
Citing papers per year: 2025: 2; 2026: 1.
3 papers.
Similar, not cited
Close in wording, no citation either way
- 2025Key, Value, Compress: A Systematic Exploration of KV Cache Compression Techniques
- 2025PackKV: Reducing KV Cache Memory Footprint through LLM-Aware Lossy Compression
- 2025FreqKV: Key-Value Compression in Frequency Domain for Context Window Extension
- 2026GRKV: Global Regression for Training-Free KV Cache Compression in Long-Context LLMs
- 2025Rethinking Key-Value Cache Compression Techniques for Large Language Model Serving
- 2026One Size Does Not Fit All: Token-Wise Adaptive Compression for KV Cache
- 2024MiniCache: KV Cache Compression in Depth Dimension for Large Language Models
- 2024ClusterKV: Manipulating LLM KV Cache in Semantic Space for Recallable Compression