deepmemteam/deepmem
An open-source drop-in replacement for Mem0's AI memory service, claiming 2x faster and 10x cheaper
DeepMem is a server that lets AI agents remember past conversations with users, built to be a line-for-line compatible swap for the commercial Mem0 API - just change one import and the rest of your code stays the same. It runs a FastAPI server on top of the Qdrant vector database, using an LLM to pull facts out of conversations and a mix of search techniques to retrieve them later. It can be self-hosted for free or used as a paid managed cloud at deepmem.dev, and the repo's own benchmarks report a 73ms median self-hosted search time and cloud pricing at roughly one-tenth of Mem0's.
What it does
- When you send it conversation messages, an LLM extracts durable facts (like 'lives in Lisbon') and stores them as searchable long-term memory
- Search combines vector similarity, keyword matching (BM25), entity boosting, and time-decay scoring into one fused, re-ranked result
- Writes are queued and processed in batches ('async batched distillation'), which the project says cuts LLM calls by about 80% versus extracting per message
- The client library mirrors Mem0's MemoryClient class name and method signatures exactly, so migration is claimed to require only a one-line import change
- It ships a built-in MCP server so tools like Claude Desktop or Cursor can read and write memories directly as callable tools
Why it matters
For developers building AI agents, persistent memory is infrastructure that's tedious to build from scratch, so an option that claims drop-in compatibility with an existing API (Mem0) lowers the switching cost to either self-host or move to cheaper pricing. It also matters for teams who want conversation data to stay on their own infrastructure rather than a third-party cloud.
Terms in this repo
- vector database (Qdrant) · a store that converts text into numeric vectors and finds semantically similar entries quickly
- BM25 · a classic keyword-ranking method that scores documents by how often and how distinctively search terms appear
- MCP (Model Context Protocol) · a standard way for AI models to access external tools and data as callable functions
- p50/p95 · the median and 95th-percentile response times, used to gauge typical and worst-case latency
- BYOK (Bring Your Own Key) · a setup where users supply their own API keys, e.g. for OpenAI or Anthropic, rather than the service providing them
Repository description (English)
Drop-in AI memory layer with 2x faster response and 10x lower cost. Fully compatible with Mem0 API. Migrate in 5 minutes without any code changes. Self-host for free.
Open on GitHubTrending repos
- vorssaint/vorssaint-utilsOne free menu bar app replaces a dozen paid Mac utilities
- Alishahryar1/free-claude-codeA local proxy that lets coding AI agents run on 49 free or cheap model providers instead of one paid service
- freestylefly/awesome-gpt-image-2A library of 532 reverse-engineered prompts that turn GPT-Image2 into a predictable image-making tool
- block/buzzAn open-source workspace where humans and AI agents chat, code, and review in the same rooms
- NousResearch/hermes-agentNous Research's Hermes is an AI agent that gets smarter the more you use it
- virgiliojr94/book-to-skillA tool that turns technical book PDFs into on-demand reference skills for AI coding agents
- VoltAgent/awesome-agent-skillsA single hub collecting over 1000 'how-to' manuals that make AI coding assistants act like experts
- anthropics/claude-plugins-communityA shared shelf where anyone's Claude add-ons get listed for install