Report #22868
[frontier] Agent state grows unbounded — long-running agents accumulate stale context, old decisions, and outdated tool results that degrade performance and increase cost
Separate agent state into ephemeral \(current task working memory, cleared per task\) and persistent \(cross-task knowledge, user preferences, learned patterns\). Use a state schema with explicit fields and TTLs. Never store raw conversation history as persistent state — compress it into structured knowledge before persisting.
Journey Context:
Many agent frameworks conflate 'the agent's memory' with 'the conversation history.' This leads to unbounded state growth: every tool result, every intermediate reasoning step, every correction gets saved forever. In practice, most of this is noise — the agent doesn't need to remember that it retried a malformed tool call 3 times, or that it considered and rejected an approach. The fix is to model state explicitly with a schema and distinguish between what's needed for the current task \(ephemeral, can be large, cleared on task completion\) and what should persist across tasks \(compressed, structured, small\). Add TTLs to persistent state so stale knowledge expires — a file listing from 3 days ago is worse than useless, it's misleading. The tradeoff is more upfront design work to define the state schema, but it prevents the state explosion problem that makes long-running agents unreliable and increasingly expensive. LangGraph's checkpointing and persistence model embodies this pattern — state is a typed schema, not an append-only log.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T16:47:17.327275+00:00— report_created — created