MemPalace: A Local-First AI Memory System That Stores Verbatim, Not Summaries
The best-benchmarked open-source AI memory system. And it's free.
At a glance
- What is it?
- MemPalace is an open-source, MIT-licensed Python tool that stores conversation history as verbatim text and retrieves it via semantic search, with a structured index of wings, rooms, and drawers. It claims 96.6% R@5 on LongMemEval with zero API calls, but its real value is in its local-first design and pluggable backends.
- Who is it for?
- Adopt MemPalace if you need local-first, verbatim AI memory and can tolerate a Python dependency stack and first-run model downloads. Skip it if you require native Termux support or a GPU image on ARM.
- Can I use it commercially?
- Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
- Is it still maintained?
- Yes. The repository received new commits within the last day.
- What is it written in?
- Mainly Python, according to GitHub's language statistics.
Answers come from the project's GitHub data, last synced on September 15, 2026, and from our analysis. They are not legal advice.
DEEP OPEN-SOURCE ANALYSIS
What MemPalace Solves and Who It Is For
MemPalace addresses a specific failure in AI-assisted development: conversational memory that decays. Chat histories with coding agents like Claude Code are ephemeral, and summarization loses the exact wording of decisions, constraints, and code snippets. MemPalace stores conversation history as verbatim text, not as summaries or paraphrases. This matters for engineers who need to retrieve the exact phrasing of a requirement or a past debugging session. The intended user is a developer or team using an MCP-capable agent, who wants a searchable memory that stays on their machine. The README states that nothing leaves your machine unless you opt in, which positions it for privacy-conscious users and organizations with data-handling restrictions.
The Palace Metaphor: Wings, Rooms, and Drawers as a Scoping Mechanism
The retrieval index is not a flat vector store. MemPalace organizes content into a three-level structure: people and projects become wings, topics become rooms, and original content lives in drawers. This is not cosmetic. It allows searches to be scoped to a specific project or topic, which reduces noise compared to a global semantic search. The README explains that searches can be scoped rather than run against a flat corpus. For an engineer, this means you can ask 'what did we decide about the auth flow for project X' without wading through unrelated conversations. The trade-off is that you must maintain this structure, either manually or through the mining process, which adds a layer of organization overhead.
How Retrieval Works: Pluggable Backends and the ChromaDB Default
The retrieval layer is defined by an interface in mempalace/backends/base.py. The default backend is ChromaDB, but the design allows alternative backends to be dropped in without touching the rest of the system. This is a practical architecture: you can swap the vector store without rewriting the memory logic. The system uses semantic search, meaning it retrieves based on meaning rather than exact keyword match. The README claims a 96.6% R@5 raw score on LongMemEval, which is a retrieval benchmark, but it does not specify the exact configuration or whether this was measured on the default backend. You should treat that number as a marketing claim until you reproduce it on your own data.
Installation: Agent-Guided Setup, CLI, and Docker
There are three installation paths. The agent-guided setup uses npx skills add MemPalace/mempalace to install three skills: mempalace for guided installation, mempalace-recall for search-before-answer recall, and mempalace-task for logstream delegation. The setup skill detects your system, installs the Python package, configures MCP, and asks whether you want a private local palace, a shared-brain hub, or a client connected to an existing hub. The direct CLI path uses uv tool install mempalace, then mempalace init ~/projects/myapp. The README warns against plain pip install outside a virtualenv due to PEP 668 errors on Debian/Ubuntu and dependency conflicts. Docker is the third path: docker pull ghcr.io/mempalace/mempalace:latest, with everything persisting under /data. The image runs as uid 1000, which causes a permission gotcha on Linux: mounted directories must be readable by that uid, and a 0700 directory fails with PermissionError. Do not use --user to work around it, because /data is owned by uid 1000 and another uid cannot write the palace.
First-Run Costs: Model Downloads and Network Dependencies
The first command that needs embeddings downloads a model into /data. The default is minilm at about 80 MB, and embeddinggemma is about 300 MB. This is a one-off if the volume persists, but it makes the first call slow and requires network access. The README explicitly warns about this, saying it is worth knowing before assuming a hung container. For an engineer, this means a fresh deployment is not fully offline until the model is cached. It also means the container needs outbound network on first run, which may conflict with air-gapped environments. If you are considering MemPalace for a secure facility, factor this into your deployment plan.
Limitations: Termux, GPU on ARM, and Claude Code Session Expiry
MemPalace has three notable limitations. First, native Termux installation is not supported because ChromaDB and ONNX Runtime do not publish Android wheels. Android ARM64 users must run Linux packages in a Debian PRoot container. Second, the GPU image is x86_64-only; onnxruntime-gpu has no aarch64 Linux wheels, so building Dockerfile.gpu on Apple Silicon fails with a dependency-resolution error. Third, and most critically, the README contains a caution that Claude Code sessions expire in 30 days without auto-save hooks wired. There is a discussion link and a setup checklist, but the README does not explain how to wire these hooks. This is a failure mode that could silently lose months of memory if you assume the system works out of the box. You must read the linked guide before relying on it for long-term retention.
Maintenance and Upgrade Cost
The project is under active development, with recent releases at v3.8.0 and v3.7.1, and the default branch is develop. This suggests a fast-moving codebase, which means upgrades are frequent. The release notes mention items like 'mine completeness' and 'reconnect integrity', indicating that the mining and connection logic is still being hardened. You should expect to monitor releases if you deploy this in production. The license is MIT, which is permissive, but it comes with no warranty, and you are responsible for any legal implications of storing user conversation data, even locally. The README also warns about impostor sites, so you must only install from the official GitHub, PyPI, or mempalaceofficial.com to avoid malware.
Alternative: A Flat Vector Store with Summarization
A common alternative is to use a generic vector database like ChromaDB directly, combined with a summarization step. The difference is in the storage philosophy. MemPalace stores verbatim text, while many memory systems summarize or extract key points to save space and improve retrieval speed. Summarization loses exact wording but can reduce storage size and may be sufficient for high-level recall. The trade-off is precision versus recall of exact phrasing. If you need to retrieve a specific error message or a precise user requirement, verbatim storage is superior. If you only need the gist of past conversations, a summarization-based approach is simpler and requires less infrastructure. MemPalace's structured index is the other differentiator; a flat vector store requires you to implement your own scoping or tagging to achieve the same level of filter.
Editorial conclusion
Adopt MemPalace if you need local-first, verbatim AI memory and can tolerate a Python dependency stack and first-run model downloads. Skip it if you require native Termux support or a GPU image on ARM. Before committing, verify the current state of the Claude Code auto-save hooks, since sessions expire in 30 days without them, and test the retrieval quality on your own conversation types, as the 96.6% benchmark may not transfer to your data.
Community notes