Does an Agent's History Tell You When Compaction Will Hurt? A Modest, Bounded Effect on the TRACE Paired-Replay Corpus
Can an AI's recent actions predict if forgetting will break it?
When AI agents forget old context to stay within memory limits, does their recent behavior predict whether they'll fail afterward? Researchers tested this on 590 real cases where an agent had to summarize its past, and found the answer is mostly no—what the agent was doing beforehand only weakly predicted post-forgetting errors. The best predictor they built could avoid harmful forgetting in 21% of cases while preserving most opportunities to compact memory, but didn't clearly beat simple token-counting rules.
Long-running AI systems need to forget old information to stay fast and cheap, but careless forgetting causes them to repeat actions or crash. If we could spot dangerous moments to compact memory before they happen, we could make agents more reliable without constantly expanding memory budgets. This work shows that moment-by-moment behavior alone isn't enough of a signal—smarter ways to predict memory-compaction risk will need additional information about what the agent is trying to do.