joshuadavidthomas/opencode-agent-memory
Memory blocks for OpenCode, inspired by Letta.
What it solves
This plugin provides persistent, long-term memory for OpenCode agents. By default, AI agents often "forget" details between sessions or when their conversation history is cleared. This tool allows the agent to store, retrieve, and update information across different sessions and projects, ensuring it remembers your preferences, project architecture, and past decisions.
How it works
The plugin uses a system of "memory blocks"—markdown files stored on your computer that the agent can read and modify using specific tools. You can define global memory (like your coding preferences) or project-specific memory (like codebase conventions). It also includes an optional "journal" feature that lets the agent save append-only notes, which can be searched later using local semantic search.
Who it’s for
It is designed for OpenCode users who want their AI coding assistant to act more like a long-term collaborator rather than a stateless chatbot. It is particularly useful for developers who work on complex, multi-session tasks and want the agent to retain context about their specific environment and habits.
Highlights
- Persistent memory that survives across different sessions and context resets.
- Self-editing capabilities allowing the agent to update its own knowledge base.
- Shared state that can be scoped globally or restricted to specific project folders.
- Private, local-only semantic search for journal entries—no data leaves your machine.
- Cache-stable design that prevents unnecessary prompt re-processing when memory is updated.
Related
- Project
- Project
- Project
- Project
- Project