SpecCompact: Accelerating LLM Agent Context Compaction with Slot-Parallel Semantic Speculative Verification
Yulu An, Yifei Feng, Xiangyang Yin
Abstract
LLM agents use context compaction to manage growing interaction histories, but summarizing long histories with large models can introduce substantial delays. Compaction therefore requires balancing information retention against latency. We observe that structured summary slots can retain information when generated independently. Based on this observation, we present SpecCompact, a framework that accelerates compaction through slot-parallel semantic speculation. SpecCompact fine-tunes a small drafter and generates slots in parallel. The target model verifies each proposed line and repairs rejected content, while subsequent drafting uses the updated slot prefix. System optimizations further reduce repeated context processing and model calls. Across AppWorld and τ3 benchmarks with two target models, SpecCompact achieves 2.04--5.63× compaction speedups over Hermes-style summarization. Separate downstream evaluations reveal model- and task-dependent performance trade-offs. A user study within Hermes further shows an 8.68× median compaction speedup.
Create a lesson
Related papers
Balancing hierarchical representation and quantization: A performance trade-off in text embeddings
Kai Ponel, Marco Polignano, Erasmo Purificato et al.
Persona Perspectives: Adopting Viewpoints Reorganizes Representations in LLMs
Austin C. Kozlowski, Avital Mintz, Madison Lee
Before You Continue: Evaluating Time-Sensitive Safety Awareness in Conversational Assistants
Peidi Dong, Yunze Xiao, Yu-Lin Tsai et al.
LooM: Loop-Invariant Memory for Causal Encoder-Decoder Language Models
Lele Yang, Muxi Diao, Zhonghao Yan et al.
SAUCE: Summary Analysis Using Conversation Entailment
Man-Ling Sung, Hemanth Kandula, Jeff Ma et al.
LLMs Don't Know What They Know: Benchmarking Temporal Self-Knowledge for Financial Backtesting
Lingfei Qian, Yan Wang, Xueqing Peng et al.