Long-term memory for AI agents.
Store, recall, and forget β just like humans do.
Quick Start Β· Docs Β· Why Mnemo Β· Self-hosted vs Cloud Β· Website
npm install @mnemoai/coreimport { createMnemo } from '@mnemoai/core';
const mnemo = await createMnemo({ dbPath: './memory-db' });
// Store
await mnemo.store({ text: 'User prefers dark mode and minimal UI' });
// Recall β vector search + BM25 + rerank + decay scoring
const results = await mnemo.recall('What does the user like?');
// β [{ text: "User prefers dark mode and minimal UI", score: 0.92 }]
// Old memories fade automatically. Important ones stick around.Auto-detects OPENAI_API_KEY from env. Or use a preset:
// 100% local, $0 API cost
const mnemo = await createMnemo({ preset: 'ollama', dbPath: './memory-db' });Available presets: openai Β· ollama Β· voyage Β· jina β configuration guide
Python
pip install mnemo-memory
npx @mnemoai/server # start the REST APIfrom mnemo import MnemoClient
client = MnemoClient()
client.store("User prefers dark mode", category="preference")
results = client.recall("UI preferences")100% Local with Ollama ($0)
ollama pull bge-m3 # embedding
ollama pull qwen3:8b # smart extraction LLM
ollama pull bge-reranker-v2-m3 # cross-encoder rerankconst mnemo = await createMnemo({ preset: 'ollama', dbPath: './memory-db' });Full Core functionality β embedding, extraction, rerank β all running locally.
Docker (full stack with Neo4j + Dashboard)
git clone https://github.com/Methux/mnemo.git
cd mnemo
cp .env.example .env # add your API keys
docker compose up -d # starts Neo4j + Graphiti + DashboardMost AI memory systems are glorified vector databases β they store everything and retrieve by similarity. That breaks at scale: your agent drowns in stale, contradictory, and irrelevant memories.
Mnemo is different. It models memory the way cognitive science says humans actually remember:
- Old memories fade. A Weibull decay model naturally deprioritizes stale information β no manual cleanup needed.
- Important memories consolidate. Frequently accessed, high-importance memories promote to a "core" tier with slower decay.
- Contradictions resolve automatically. When a user says "I moved to Tokyo" after previously saying "I live in NYC", Mnemo detects the contradiction and expires the old fact.
- Noise gets filtered. Debug logs, API errors, meta-questions β automatically excluded from long-term storage.
The result: your agent's memory stays sharp at 100 memories or 10,000.
| Mnemo | Mem0 | Zep | LangMem | |
|---|---|---|---|---|
| Local-first (no SaaS lock-in) | Yes | Yes | CE deprecated | Partial |
| Forgetting model | Weibull decay | None | Time window | None |
| Contradiction detection | 3-layer LLM | Graph layer | Temporal versioning | None |
| Multi-backend (LanceDB/Qdrant/Chroma/PGVector) | Yes | Qdrant | Postgres | Varies |
| Provider agnostic (BYO embedding/LLM) | Yes | Limited | No | LangChain only |
| Fully offline ($0 with Ollama) | Yes | Partial | No | No |
| Cross-encoder rerank | Yes | Yes | Yes | No |
User message
β
βΌ
ββββ Store ββββββββββββββββββββββββββββββββββββββββ
β Embed β Noise filter β Dedup β Contradiction β
β detection β LanceDB (vector + BM25 index) β
ββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ
ββββ Recall βββββββββββββββββββββββββββββββββββββββ
β Vector search + BM25 β RRF fusion β Rerank β
β β Decay scoring β MMR diversity β Top-K β
ββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
βΌ
ββββ Lifecycle ββββββββββββββββββββββββββββββββββββ
β Working β Core (consolidate) β
β Working β Peripheral β Archive (fade out) β
β Driven by composite score, no manual tuning β
ββββββββββββββββββββββββββββββββββββββββββββββββββββ
Every parameter adapts to your store size. No magic numbers to tune.
| Capability | Core (Free) | Cloud |
|---|---|---|
| Vector + BM25 + Knowledge Graph | Yes | Yes |
| Weibull forgetting model | Yes | Yes |
| Memory tiers (Core/Working/Peripheral) | Yes | Yes |
| Cross-encoder rerank | Yes | Yes |
| Contradiction detection | Yes | Yes |
| Multi-backend (LanceDB, Qdrant, Chroma, PGVector) | Yes | Yes |
| Scope isolation (multi-agent) | Yes | Yes |
| $0 local deployment (Ollama) | Yes | Yes |
| Adaptive retrieval (pool/score/frequency) | β | Yes |
| Extraction-time context injection | β | Yes |
| Session deduplication | β | Yes |
Self-hosted (Core) β the full framework, MIT licensed, no restrictions. npm install @mnemoai/core and run it yourself. You bring your own embedding/LLM keys.
Mnemo Cloud β hosted API, zero setup. Adaptive retrieval, intelligent extraction, and contradiction detection built in. No keys to manage, no infrastructure to run.
npm install @mnemoai/clientimport { createCloudMnemo } from "@mnemoai/client";
const mnemo = createCloudMnemo({ apiKey: "mn_your_key" });
await mnemo.store({ text: "User prefers dark mode" });
const memories = await mnemo.recall("UI preferences");| Plan | Price | What you get |
|---|---|---|
| Core | Free forever | Full framework, self-hosted, MIT |
| Cloud Starter | $29/month | 10K memories, 1K stores/day, 50K recalls/day |
| Cloud Pro | $99/month | 100K memories, 10K stores/day, unlimited recalls |
| Enterprise | Contact us | Custom limits, dedicated support, SLA |
Mnemo is a framework β you bring your own models. Choose a setup that fits your budget:
| Setup | Embedding | LLM Extraction | Rerank | Est. API Cost |
|---|---|---|---|---|
| Local | Ollama bge-m3 | Ollama qwen3:8b | Ollama bge-reranker | $0/mo |
| Hybrid | OpenAI text-embedding-3-small | GPT-4.1-mini | Jina reranker | ~$5/mo |
| Cloud | Voyage voyage-4 | GPT-4.1 | Voyage rerank-2 | ~$45/mo |
These are your own API costs, not Mnemo subscription fees.
| Package | Platform | Install |
|---|---|---|
| @mnemoai/core | npm | npm install @mnemoai/core |
| @mnemoai/client | npm | npm install @mnemoai/client |
| Mnemo Cloud | REST API | Sign up at api.m-nemo.ai/signup |
| @mnemoai/server | npm | npx @mnemoai/server |
| @mnemoai/vercel-ai | npm | npm install @mnemoai/vercel-ai |
| mnemo-memory | PyPI | pip install mnemo-memory |
Mnemo's design maps directly to established memory research:
| Human Memory | Mnemo |
|---|---|
| Ebbinghaus forgetting curve | Weibull decay model |
| Core vs peripheral memory | Tier system with differential decay rates |
| Interference / false memories | Deduplication + noise filtering |
| Metamemory | mnemo-doctor + Web Dashboard |
Read more: Architecture β Β· Retrieval Pipeline β Β· Ablation Tests β
Full docs at docs.m-nemo.ai
- Quick Start
- Local Setup ($0 Ollama)
- Configuration Reference
- Storage Backends
- Retrieval Pipeline
- API Reference
| Tool | Description | Run |
|---|---|---|
mnemo init |
Interactive config wizard | npm run init |
mnemo-doctor |
One-command health check | npm run doctor |
validate-config |
Config validation gate | npm run validate |
| Dashboard | Web UI for browsing, debugging, monitoring | http://localhost:18800 |
We welcome contributions to Mnemo Core (MIT-licensed files). See CONTRIBUTING.md.
Areas where we'd love help:
- Benchmark evaluation (LOCOMO, MemBench)
- New storage adapters and embedding providers
- Retrieval pipeline optimizations
- Documentation and examples
Dual-license model:
- MIT β Core framework (
SPDX-License-Identifier: MIT) - Commercial β Cloud features and advanced strategies
See LICENSE for details.
Built with cognitive science, not hype.
**Trademarks:** LanceDB is a trademark of LanceDB, Inc. Neo4j is a trademark of Neo4j, Inc. Qdrant is a trademark of Qdrant Solutions GmbH. Mnemo is not affiliated with, endorsed by, or sponsored by any of these organizations. Storage backends are used under their respective open-source licenses.