LoCoCo: Dropping In Convolutions for Long Context Compression
Ruisi Cai, Yuandong Tian, Zhangyang Wang, Beidi Chen
Abstract
This paper tackles the memory hurdle of processing long context sequences in Large Language Models (LLMs), by presenting a novel approach, Dropping In Convolutions for Long Context Compression (LoCoCo). LoCoCo employs only a fixed-size Key-Value (KV) cache, and can enhance efficiency in both inference and fine-tuning stages. Diverging from prior methods that selectively drop KV pairs based on heuristics, LoCoCo leverages a data-driven adaptive fusion technique, blending previous KV pairs with incoming tokens to minimize the loss of contextual information and ensure accurate attention modeling. This token integration is achieved through injecting one-dimensional convolutional kernels that dynamically calculate mixing weights for each KV cache slot. Designed for broad compatibility with existing LLM frameworks, Lo-CoCo allows for straightforward "drop-in" integration without needing architectural modifications, while incurring minimal tuning overhead. Experiments demonstrate that LoCoCo maintains consistently outstanding performance across various context lengths and can achieve a high context compression rate during both inference and finetuning phases. During inference, we successfully compressed up to 3482 tokens into a 128-size KV cache, while retaining comparable performance to the full sequence -an accuracy improvement of up to 0.2791 compared to baselines at the same cache size. During post-training tuning, we also effectively extended the context length from 4K to 32K using a KV cache of fixed size 512, achieving performance similar to fine-tuning with entire sequences. Codes are available at: https: //github.com/VITA-Group/LoCoCo .
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
3 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention cites Reformer: The Efficient Transformer
- Big Bird: Transformers for Longer Sequences cites Reformer: The Efficient Transformer
- APB: Accelerating Distributed Long-Context Inference by Passing Compressed Context Blocks across GPUs cites Big Bird: Transformers for Longer Sequences
- Efficiently Modeling Long Sequences with Structured State Spaces cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- Kinetics: Rethinking Test-Time Scaling Law cites Transformers are RNNs: Fast Autoregressive Transformers with Linear Attention
- Kinetics: Rethinking Test-Time Scaling Law cites Big Bird: Transformers for Longer Sequences
- Kinetics: Rethinking Test-Time Scaling Law cites Efficiently Modeling Long Sequences with Structured State Spaces
- Kinetics: Rethinking Test-Time Scaling Law cites Reformer: The Efficient Transformer
Cited by top-tier papers3
- Kinetics: Rethinking Test-Time Scaling LawRanajoy Sadhukhan, Zhuoming Chen, Haizhong Zheng, Beidi ChenNeurIPS 2025 · 2 citations
- APB: Accelerating Distributed Long-Context Inference by Passing Compressed Context Blocks across GPUsYuxiang Huang, Mingye Li, Xu Han, Chaojun Xiao et al.ACL 2025
- Cost-Optimal Grouped-Query Attention for Long-Context ModelingYingfa Chen, Yutong Wu, Chenyang Song, Zhen Leng Thai et al.EMNLP 2025
Builds on30
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
- Efficiently Modeling Long Sequences with Structured State SpacesAlbert Gu, Karan Goel, Christopher RéICLR 2022 · 3,482 citations
- Big Bird: Transformers for Longer SequencesManzil Zaheer, Guru Guruganesh, Kumar Avinava Dubey, Joshua Ainslie et al.NeurIPS 2020 · 3,159 citations
- Reformer: The Efficient TransformerNikita Kitaev, Lukasz Kaiser, Anselm LevskayaICLR 2020 · 2,878 citations
- Transformers are RNNs: Fast Autoregressive Transformers with Linear AttentionAngelos Katharopoulos, Apoorv Vyas, Nikolaos Pappas, François FleuretICML 2020 · 2,665 citations
Related papers
- LLoCO: Learning Long Contexts OfflineSijun Tan, Xiuyu Li, Shishir G. Patil, Ziyang Wu et al.EMNLP 2024 · 3 citations
- OjaKV: Context-Aware Online Low-Rank KV Cache CompressionYuxuan Zhu, David H. Yang, Mohammad Mohammadi Amiri, Keerthiram Murugesan et al.ACL Findings 2026 · 1 citation
- FreqKV: Key-Value Compression in Frequency Domain for Context Window ExtensionJushi Kai, Yixuan Wang, Boyi Zeng, Haoli Bai et al.ICLR 2026 · 7 citations
- UniGist: Towards General and Hardware-aligned Sequence-level Long Context CompressionChenlong Deng, Zhisong Zhang, Kelong Mao, Shuaiyi Li et al.NeurIPS 2025 · 10 citations
- More Tokens, Lower Precision: Towards the Optimal Token-Precision Trade-off in KV Cache CompressionJiebin Zhang, Dawei Zhu, Yifan Song, Wenhao Wu et al.EMNLP Findings 2025 · 2 citations
