Skip to content
< selected work

Independent exploration

Semantic memory for long-horizon agent sessions

A prototype exploring how an agent can keep its working context small over long sessions by querying a memory layer, instead of relying on an ever-bigger window.

agent-systemssemantic-memorycontext-engineering

A design where memory is a tool the agent calls deliberately (query, write, forget), keeping retrieval from derailing the plan. A personal exploration, not a delivered product.

Context

A personal exploration of a familiar agent problem: quality decays as a session grows because relevant facts get buried, not lost. This is my own prototype and thinking, not delivered client work.

Problem and constraint

A bigger context window just delays the cliff and costs more. The goal was a memory the agent treats as a tool it can query, write to, and forget from, so the working context stays small and relevant over long, multi-step tasks.

Approach and key decisions

  • Made memory a retrieval-backed tool the agent calls deliberately, with explicit write and forget steps, rather than an ever-growing flat context.
  • Kept retrieval from derailing the plan: memory returns are data the agent weighs, not instructions it follows.
  • Treated what to remember and when to forget as the real design surface; that, not the embedding store, is where the behavior lives.

What I explored

Where a deliberate remember/forget policy holds up better than a flat, ever-growing context on long, multi-step tasks, and where it doesn't. The interesting part is the policy, not the vector store.

What I'd do differently

Instrument memory hit/miss against task outcomes from the start, so the remember/forget policy is tuned on evidence rather than intuition.