mlsanityData to 14 Oct 2026

Beyond Hard and Soft: Hybrid Context Compression for Balancing Local and Global Information Retention

arXiv 2505.15774 ↗First posted 21 May 2025cs.CL cs.LGcited by 7

On the map: Efficient LLM inference and serving → Prompt and context compression

Abstract (arXiv)

Large Language Models (LLMs) encounter significant challenges in long-sequence inference due to computational inefficiency and redundant processing, driving interest in context compression techniques. Existing methods often rely on token importance to perform hard local compression or encode context into latent representations for soft global compression. However, the uneven distribution of textual content relevance and the diversity of demands for user instructions mean these approaches frequently lead to the loss of potentially valuable information. To address this, we propose Hybrid Context Compression (HyCo2) for LLMs, which integrates both global and local perspectives to guide context compression while retaining both the essential semantics and critical details for task completion. Specifically, we employ a hybrid adapter to refine global semantics with the global view, based on the observation that different adapters excel at different tasks. Then we incorporate a classification layer that assigns a retention probability to each context token based on the local view, determining whether it should be retained or discarded. To foster a balanced integration of global and local compression, we introduce auxiliary paraphrasing and completion pretraining before instruction tuning. This promotes a synergistic integration that emphasizes instruction-relevant information while preserving essential local details, ultimately balancing local and global information retention in context compression. Experiments show that our HyCo2 method significantly enhances long-text reasoning while reducing token usage. It improves the performance of various LLM series by an average of 13.1% across seven knowledge-intensive QA benchmarks. Moreover, HyCo2 matches the performance of uncompressed methods while reducing token consumption by 88.8%.

Key facts. Cited by 7 papers in the map (data through 14 Oct 2026). Placed in Prompt and context compression, one of 12 directions in Efficient LLM inference and serving. Builds on 61 of its 72 references that are in the map. First posted on arXiv 21 May 2025.

Builds on

61 of 72 references.

Closest ancestors · 14

Same direction, newest first

  1. 2025Understanding and Improving Information Preservation in Prompt Compression for LLMs24 Mar
  2. 2024A Silver Bullet or a Compromise for Full Attention? A Comprehensive Study of Gist Token-based Context Compression23 Dec
  3. 2024EXIT: Context-Aware Extractive Compression for Enhancing Retrieval-Augmented Generation17 Dec
  4. 2024Prompt Compression for Large Language Models: A Survey16 Oct
  5. 2024Selection-p: Self-Supervised Task-Agnostic Prompt Compression for Faithfulness and Transferability15 Oct
  6. 2024TACO-RL: Task Aware Prompt Compression Optimization with Reinforcement Learning19 Sep
  7. 2024AdaComp: Extractive Context Compression with Adaptive Predictor for Retrieval-Augmented Large Language Models3 Sep
  8. 2024500xCompressor: Generalized Prompt Compression for Large Language Models6 Aug
  9. 2024Characterizing Prompt Compression Methods for Long Context Inference11 Jul
  10. 2024xRAG: Extreme Context Compression for Retrieval-augmented Generation with One Token22 May
  11. 2024LLMLingua-2: Data Distillation for Efficient and Faithful Task-Agnostic Prompt Compression19 Mar
  12. 2023LongLLMLingua: Accelerating and Enhancing LLMs in Long Context Scenarios via Prompt Compression10 Oct
2 more
  1. 2023In-context Autoencoder for Context Compression in a Large Language Model13 Jul
  2. 2022Prompt Compression and Contrastive Conditioning for Controllability and Toxicity Reduction in Language Models6 Oct

Other references · 47

  1. 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,305
  2. 2023GPT-4 Technical Reportcited by 18,396
  3. 2024The Llama 3 Herd of Modelscited by 14,715
  4. 2023Visual Instruction Tuningcited by 7,869
  5. 2023BLIP-2: Bootstrapping Language-Image Pre-training with Frozen Image Encoders and Large Language Modelscited by 6,137
  6. 2024Qwen2.5 Technical Reportcited by 4,942
  7. 2022Flamingo: a Visual Language Model for Few-Shot Learningcited by 4,386
  8. 2023Let's Verify Step by Stepcited by 3,789
  9. 2018HotpotQA: A Dataset for Diverse, Explainable Multi-hop Question Answeringcited by 3,754
  10. 2023Lost in the Middle: How Language Models Use Long Contextscited by 3,455
  11. 2017TriviaQA: A Large Scale Distantly Supervised Challenge Dataset for Reading Comprehensioncited by 2,955
  12. 2018CommonsenseQA: A Question Answering Challenge Targeting Commonsense Knowledgecited by 1,822
35 more
  1. 2016MS MARCO: A Human Generated MAchine Reading COmprehension Datasetcited by 1,605
  2. 2018Know What You Don't Know: Unanswerable Questions for SQuADcited by 1,554
  3. 2017Get To The Point: Summarization with Pointer-Generator Networkscited by 1,292
  4. 2019PubMedQA: A Dataset for Biomedical Research Question Answeringcited by 1,288
  5. 2020Constructing A Multi-hop QA Dataset for Comprehensive Evaluation of Reasoning Stepscited by 1,282
  6. 2021Unsupervised Dense Information Retrieval with Contrastive Learningcited by 1,216
  7. 2022When Not to Trust Language Models: Investigating Effectiveness of Parametric and Non-Parametric Memoriescited by 1,128
  8. 2019DROP: A Reading Comprehension Benchmark Requiring Discrete Reasoning Over Paragraphscited by 903
  9. 2023Large Language Models Can Be Easily Distracted by Irrelevant Contextcited by 841
  10. 2018CoQA: A Conversational Question Answering Challengecited by 683
  11. 2021Prompt Programming for Large Language Models: Beyond the Few-Shot Paradigmcited by 606
  12. 2017The NarrativeQA Reading Comprehension Challengecited by 597
  13. 2019SAMSum Corpus: A Human-annotated Dialogue Dataset for Abstractive Summarizationcited by 535
  14. 2018The Web as a Knowledge-base for Answering Complex Questionscited by 410
  15. 2023Learning to Compress Prompts with Gist Tokenscited by 390
  16. 2023Adapting Language Models to Compress Contextscited by 356
  17. 2024HippoRAG: Neurobiologically Inspired Long-Term Memory for Large Language Modelscited by 281
  18. 2024Unlocking Efficiency in Large Language Model Inference: A Comprehensive Survey of Speculative Decodingcited by 269
  19. 2023Compressing Context to Enhance Inference Efficiency of Large Language Modelscited by 189
  20. 2024RedPajama: an Open Dataset for Training Large Language Modelscited by 182
  21. 2025A Comprehensive Survey on Long Context Language Modelingcited by 117
  22. 2024HiAgent: Hierarchical Working Memory Management for Solving Long-Horizon Agent Tasks with Large Language Modelcited by 106
  23. 2024MEMORYLLM: Towards Self-Updatable Large Language Modelscited by 93
  24. 2023Learning to Filter Context for Retrieval-Augmented Generationcited by 83
  25. 2024Beyond LLaVA-HD: Diving into High-Resolution Large Multimodal Modelscited by 76
  26. 2024Learning to Compress Prompt in Natural Language Formatscited by 55
  27. 2024LongRAG: A Dual-Perspective Retrieval-Augmented Generation Paradigm for Long-Context Question Answeringcited by 49
  28. 2024Efficient Prompting Methods for Large Language Models: A Surveycited by 47
  29. 2025Hybrid-Level Instruction Injection for Video Token Compression in Multi-modal Large Language Modelscited by 19
  30. 2024Extending Llama-3's Context Ten-Fold Overnightcited by 15
  31. 2025From 128K to 4M: Efficient Training of Ultra-Long Context Large Language Modelscited by 14
  32. 2024Improve Student's Reasoning Generalizability through Cascading Decomposed CoTs Distillationcited by 9
  33. 2024Instructing Large Language Models to Identify and Ignore Irrelevant Conditionscited by 7
  34. 2024Awakening Augmented Generation: Learning to Awaken Internal Knowledge of Large Language Models for Question Answeringcited by 7
  35. 2024Neural-Symbolic Collaborative Distillation: Advancing Small Language Models for Complex Reasoning Taskscited by 5

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2025: 2; 2026: 5.

7 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2025Autoencoding-Free Context Compression for LLMs via Contextual Semantic Anchors
  2. 2024Enhancing and Accelerating Large Language Models via Instruction-Aware Contextual Compression
  3. 2025CCF: A Context Compression Framework for Efficient Long-Sequence Language Modeling
  4. 2025Semantic Retention and Extreme Compression in LLMs: Can We Have Both?
  5. 2026End-to-End Context Compression at Scale
  6. 2025Sentence-Anchored Gist Compression for Long-Context LLMs
  7. 2025ChunkKV: Semantic-Preserving KV Cache Compression for Efficient Long-Context LLM Inference
  8. 2026From Similarity to Structure: Training-free LLM Context Compression with Hybrid Graph Priors