Problem
The controlplane / overseer notion (#10) is fundamentally a long-running agent that must:
- Know about every project, every PR, every session
- Remember decisions made days/weeks ago
- Track which issue spawned which session that spawned which PR
This is more context than any single session window can hold. Without persistent searchable memory, the controlplane becomes amnesiac after a few hundred messages and either forgets prior decisions or asks the operator to re-ground it every time.
Claude has shipped the primitive we need:
https://support.claude.com/en/articles/11817273-use-claude-s-chat-search-and-memory-to-build-on-previous-context
Cross-conversation search + memory that builds on previous context.
Proposal
Implement a memory + search layer for the controlplane (and optionally for all sessions):
- Per-session memory -- already kind of exists in the message history.
- Cross-session memory -- FTS5 (SQLite full-text search) over all messages for a given user/project, with metadata filters (session id, role, timestamp, channel source).
- Memory tool -- agents call
searchMemory({query, scope?: 'session' | 'project' | 'all'}) to retrieve past context relevant to the current turn.
- Active recall -- agents emit "remember this" markers (
<memory>...</memory>) for important decisions. The memory layer indexes these with higher weight.
- Compaction-aware -- when a session's context window fills, the memory layer can serve compressed summaries of older turns from this store.
Inspiration: the context-mode MCP project that's already in use here uses FTS5 + auto-indexing for exactly this pattern. Steal liberally.
Acceptance
Notes
Problem
The controlplane / overseer notion (#10) is fundamentally a long-running agent that must:
This is more context than any single session window can hold. Without persistent searchable memory, the controlplane becomes amnesiac after a few hundred messages and either forgets prior decisions or asks the operator to re-ground it every time.
Claude has shipped the primitive we need:
Cross-conversation search + memory that builds on previous context.
Proposal
Implement a memory + search layer for the controlplane (and optionally for all sessions):
searchMemory({query, scope?: 'session' | 'project' | 'all'})to retrieve past context relevant to the current turn.<memory>...</memory>) for important decisions. The memory layer indexes these with higher weight.Inspiration: the
context-modeMCP project that's already in use here uses FTS5 + auto-indexing for exactly this pattern. Steal liberally.Acceptance
searchMemorytool callable from any sessionNotes
context-modeserver present in this dev environment is a working prototype of the same pattern -- maybe directly adopt as a HAPI integration?