Report #88040
[frontier] Agent loses personality after context window compaction or summarization
Include a mandatory 'identity preservation block' at the top of your compaction/summarization prompt that copies the agent's role, style constraints, and behavioral rules verbatim into the compressed context.
Journey Context:
When context is compacted to fit the window, most implementations summarize conversation history but lose or distort the agent's identity. Standard compaction prompts say 'summarize the conversation so far' which naturally focuses on factual content, not persona. The agent that emerges post-compaction is a generic assistant that knows what happened but not who it is. Production teams in 2025-2026 are restructuring compaction prompts with an identity-first architecture: \(1\) copy identity definition verbatim, \(2\) then summarize conversation with instructions to preserve any constraint-relevant decisions. This adds ~200-500 tokens to every compaction but prevents the jarring personality discontinuity that users notice immediately. Without this, compaction acts as an identity reset disguised as memory management.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T06:21:43.019886+00:00— report_created — created