OpenLTM gives MCP agents persistent memory via SQLite
OpenLTM is an MIT-licensed MCP server that provides AI agents with persistent long-term memory across sessions, backed entirely by a local SQLite database with semantic search, a job queue, cron, and pub-sub — no cloud or external services required.
Score breakdown
OpenLTM demonstrates that a full agentic memory infrastructure — including semantic recall, a job queue, distributed cron, and cross-agent pub-sub — can be built entirely within a local SQLite file, eliminating the need for external services like Redis or Celery.
- 01OpenLTM is an MCP server providing persistent long-term memory to any MCP-capable host across sessions.
- 02Exposes six MCP tools: `recall`, `learn`, `context`, `forget`, `relate`, and a graph query.
- 03Recall uses FTS5 full-text search first, with `sqlite-vec` KNN vector search as a fallback.
OpenLTM is an MIT-licensed MCP server designed to give AI agents persistent long-term memory across sessions. It exposes six tools over MCP: `recall` for semantic search, `learn` for storing memories, `context` for restoring project goals, decisions, and gotchas, plus `forget`, `relate`, and a graph query. The recall mechanism is FTS5-first with a `sqlite-vec` KNN vector search as a fallback, keeping retrieval fast and local. The driver is `bun:sqlite`, and the project is described as provider-agnostic with a core-plus-adapters architecture.
The infrastructure layer is handled by an optional SQLite extension called **Honker**, which turns `openltm.db` into a durable embedding job queue supporting claim/embed/ack, retry, and dead-letter patterns.
For Claude Code specifically, OpenLTM pairs the MCP server with lifecycle hooks: session-end automatically extracts memories, session-start injects the top recalled ones, and a pre-compact hook preserves context before compaction. The infrastructure layer is handled by an optional SQLite extension called **Honker**, which turns `openltm.db` into a durable embedding job queue supporting claim/embed/ack, retry, and dead-letter patterns. Honker also provides leader-elected cron (so decay jobs run only once across processes) and NOTIFY/LISTEN pub-sub for cross-agent synchronization — effectively a transactional outbox entirely inside SQLite. When the native Honker binary is absent, the system degrades cleanly to inline embedding and polling. All data stays in a local SQLite file the user owns, with no cloud dependency or telemetry. The project is available on GitHub under the MIT license.
Key facts
- 01OpenLTM is an MCP server providing persistent long-term memory to any MCP-capable host across sessions.
- 02Exposes six MCP tools: `recall`, `learn`, `context`, `forget`, `relate`, and a graph query.
- 03Recall uses FTS5 full-text search first, with `sqlite-vec` KNN vector search as a fallback.
- 04On Claude Code, lifecycle hooks automate memory extraction at session-end, injection at session-start, and context preservation at pre-compact.
- 05Optional SQLite extension **Honker** adds a durable embedding job queue (claim/embed/ack, retry, dead-letter), leader-elected cron, and NOTIFY/LISTEN pub-sub — all inside SQLite, replacing Redis/Celery.
- 06Degrades cleanly to inline embedding and polling when the Honker native binary is absent.
- 07MIT-licensed, provider-agnostic, uses `bun:sqlite`, no cloud dependency or telemetry.
Topics
Summary and scoring are generated automatically from the original article. We always link back to the publisher and never republish images or paywalled content. Last processed Jun 9, 2026 · 17:05 UTC. How this works →