Tools Need Not Speak in Text: Latent Context Compression for Agents
On the map: LLM agents and tool use → Web, search, and research agents also fits: Agent memory systems
also in 1 more
Abstract (arXiv)
Large language model (LLM) agents typically append raw tool outputs to their context. Over multi-step interactions, long and noisy observations incur substantial context overhead and dilute the agent's attention to task-relevant information. Existing token pruning and summarization methods remain constrained by discrete text representations, limiting the achievable compression ratios. In this work, we challenge the prevailing assumption that agents must consume tool observations as explicit text tokens. To this end, we propose Coca-Cola, a continuous latent context compression model for LLM agents. Coca-Cola compresses tool observations into latent tokens and embeds them into the input embedding space of the agent. We further introduce Action-Preserving Training, which aligns the agent's next-action distributions under full and compressed observations. This trains the compression model to learn action-sufficient latent tokens that retain decision-critical information. Experiments with web-search agents on four QA benchmarks and two model families show that Coca-Cola reduces the agent's token consumption by 70.01%-89.24% and end-to-end runtime by 24.45%-55.97%, while consistently improving task performance. These results suggest that Coca-Cola offers a promising approach for context compression in agents. Our code is available at https://github.com/THU-Agent/Coca-cola.
Key facts. No citing papers in the map yet (data through 24 Nov 2026). Placed in Web, search, and research agents, one of 16 directions in LLM agents and tool use. Builds on 46 of its 50 references that are in the map. Submitted 4 Nov 2026.
Builds on
46 of 50 references.
Closest ancestors · 3
Same direction, newest first
- 2025Search-o1: Agentic Search-Enhanced Large Reasoning Models9 Jan
- 2024Data Interpreter: An LLM Agent For Data Science28 Feb
- 2024WebVoyager: Building an End-to-End Web Agent with Large Multimodal Models25 Jan
Other references · 43
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 9,589
- 2023Toolformer: Language Models Can Teach Themselves to Use Toolscited by 4,469
- 2018HotpotQA: A Dataset for Diverse, Explainable Multi-hop Question Answeringcited by 3,986
- 2023Lost in the Middle: How Language Models Use Long Contextscited by 3,765
- 2017TriviaQA: A Large Scale Distantly Supervised Challenge Dataset for Reading Comprehensioncited by 3,109
- 2023Voyager: An Open-Ended Embodied Agent with Large Language Modelscited by 2,483
- 2024SWE-agent: Agent-Computer Interfaces Enable Automated Software Engineeringcited by 2,069
- 2025Search-R1: Training LLMs to Reason and Leverage Search Engines with Reinforcement Learningcited by 1,602
- 2020Constructing A Multi-hop QA Dataset for Comprehensive Evaluation of Reasoning Stepscited by 1,392
- 2024ChatGLM: A Family of Large Language Models from GLM-130B to GLM-4 All Toolscited by 1,191
- 2023Large Language Models Can Be Easily Distracted by Irrelevant Contextcited by 909
- 2024Training Large Language Models to Reason in a Continuous Latent Spacecited by 894
31 more
- 2023LongLLMLingua: Accelerating and Enhancing LLMs in Long Context Scenarios via Prompt Compressioncited by 500
- 2023Learning to Compress Prompts with Gist Tokenscited by 426
- 2024LLMLingua-2: Data Distillation for Efficient and Faithful Task-Agnostic Prompt Compressioncited by 397
- 2023Adapting Language Models to Compress Contextscited by 390
- 2025WebThinker: Empowering Large Reasoning Models with Deep Research Capabilitycited by 375
- 2023LLMLingua: Compressing Prompts for Accelerated Inference of Large Language Modelscited by 324
- 2023RECOMP: Improving Retrieval-Augmented LMs with Compression and Selective Augmentationcited by 268
- 2023In-context Autoencoder for Context Compression in a Large Language Modelcited by 227
- 2024Compressed Chain of Thought: Efficient Reasoning Through Dense Representationscited by 212
- 2023Compressing Context to Enhance Inference Efficiency of Large Language Modelscited by 208
- 2023Implicit Chain of Thought Reasoning via Knowledge Distillationcited by 189
- 2024Same Task, More Tokens: the Impact of Input Length on the Reasoning Performance of Large Language Modelscited by 171
- 2025ACON: Optimizing Context Compression for Long-horizon LLM Agentscited by 171
- 2024xRAG: Extreme Context Compression for Retrieval-augmented Generation with One Tokencited by 137
- 2025SoftCoT: Soft Chain-of-Thought for Efficient Reasoning with LLMscited by 127
- 2025MemGen: Weaving Generative Latent Memory for Self-Evolving Agentscited by 117
- 2024MEMORYLLM: Towards Self-Updatable Large Language Modelscited by 111
- 2025Latent Collaboration in Multi-Agent Systemscited by 93
- 2025Reducing Cost of LLM Agents with Trajectory Reductioncited by 66
- 2026SWE-Pruner: Self-Adaptive Context Pruning for Coding Agentscited by 52
- 2024500xCompressor: Generalized Prompt Compression for Large Language Modelscited by 51
- 2025KVCOMM: Online Cross-context KV-cache Communication for Efficient LLM-based Multi-agent Systemscited by 49
- 2025Enabling Agents to Communicate Entirely in Latent Spacecited by 47
- 2026The Latent Space: Foundation, Evolution, Mechanism, Ability, and Outlookcited by 45
- 2025LongCodeZip: Compress Long Context for Code Language Modelscited by 42
- 2024Context Embeddings for Efficient Answer Generation in RAGcited by 30
- 2026Agent Primitives: Reusable Latent Building Blocks for Multi-Agent Systemscited by 17
- 2026NextMem: Towards Latent Factual Memory for LLM-based Agentscited by 14
- 2025LatentEvolve: Self-Evolving Test-Time Scaling in Latent Spacecited by 11
- 2026See What I See, Know What I Think: Dense Latent Communication Across Heterogeneous Agentscited by 10
- 2026CoACT: Action-Preserving Observation Compression for Coding Agentscited by 5
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Compress What You See, Not What You Say: Anchored Context Distillation for Latent-Observation Software Engineering Agents
- 2026In-Model Context Compression with Agentic Soft Tokens for Long-Horizon LLM Agents
- 2026FOCUS: Training-Free Decision-Preserving Context Compression for LLM Agents
- 2026AGORA: Adapter-Grounded Observation-Action Retention for Inference-Free Prompt Compression in LLM Agents
- 2026AgentCompress: Task-Aware Compression for Affordable Large Language Model Agents
- 2025Can Compressed LLMs Truly Act? An Empirical Evaluation of Agentic Capabilities in LLM Compression
- 2026Beyond Token Savings: A Systematic Study of Context Compression in LLM Agents
- 2026LatCom: Cross-Agent Latent Compression for Efficient Multi-Agent Collaboration