The Long-Term
Memory Layer for AI
A cognitive memory engine with a 6-phase recall pipeline, neural reranking, and adaptive query planning. 76.4% on LoCoMo. 51+ integrations. Production-ready.
from cortexdb import Cortex
client = Cortex(api_key="your-key")
client.remember(content="Q3 revenue: $2.4M",
tenant_id="acme")
result = client.recall(query="Q3 revenue?",
tenant_id="acme")
Architecture
How it works
A 6-phase cognitive recall pipeline backed by a distributed, Raft-consensus cluster.
Scaling
Features
Built for production AI workloads
Everything your AI agents need for reliable, accurate long-term memory. No compromises.
Event-Sourced Memory
Raw content preserved exactly as received. Never rewritten or hallucinated by an LLM. Full audit trail of every change.
Knowledge Graph
Auto-built knowledge graph with entity extraction, causal chains, and contradiction detection. Async enrichment pipeline extracts atomic facts with resolved dates — the graph enriches retrieval without blocking writes.
Cognitive Recall Pipeline
Six-phase retrieval pipeline: adaptive query planning, 4-channel hybrid search (BM25 + vector + entity + synonym diversity), neural cross-encoder reranking, statistical irrelevance detection, knowledge graph enrichment, and multi-signal adaptive scoring. Not a vector search wrapper — a ground-up cognitive memory engine.
Crash Durable
Battle-tested storage engine with zero data loss under any failure scenario. Your memories survive anything, guaranteed.
Multi-Tenant
Full isolation per tenant with namespace support. Predictable performance at any scale with automatic resource management.
16 Data Connectors
Slack, GitHub, Jira, Notion, Salesforce, and 11 more built-in. Ingest your team's knowledge automatically.
Architecture
Lossless vs. lossy
Other memory systems rewrite your data through an LLM before storing it. CortexDB preserves the original.
CortexDB
Lossless, event-sourced
Raw content stored as immutable events
Async enrichment extracts atomic facts + knowledge graph
4-channel retrieval + neural cross-encoder reranking
Adaptive query planner learns optimal strategy per query type
Others
Lossy, LLM-rewritten
Content rewritten by LLM before storage
LLM on critical write path — slow, unpredictable cost
Single-channel vector search (no reranking)
No irrelevance detection — always returns something
Comparison
How CortexDB is different
Architectural differences that matter at scale.
| Feature | CortexDB | Competition |
|---|---|---|
| Data preservation | Lossless (raw events) | Lossy (LLM-rewritten) |
| Write path | No LLM on write path | LLM required on every write |
| Retrieval | 4-channel hybrid + neural reranking | Vector-only |
| Irrelevance detection | Quad-signal gate (returns empty when nothing matches) | Always returns something (hallucination risk) |
| Knowledge graph | Auto-built with async enrichment | Separate add-on |
| Query understanding | Adaptive planner (6 query types, online learning) | One-size-fits-all |
| Crash durability | WAL + embedded storage (zero data loss) | Depends on vector DB |
| Benchmark (LoCoMo) | 76.4% | 66.9% (Mem0) |
| Data connectors | 16 built-in | 0 |
| Cluster mode | Built-in Raft consensus | N/A |
| Event sourcing | Full audit trail | None |
| Multi-tenant | Namespace isolation | Limited |
Benchmarks
Proven accuracy, not marketing claims
We evaluate against published academic benchmarks and share the results. No cherry-picked demos — real numbers on standardized tests.
LoCoMo Benchmark
Industry-standard long-term conversational memory benchmark. 10 conversations, 1,540 QA pairs across 4 categories.
LLM Judge
Binary CORRECT/WRONG judge (GPT-4o-mini). Categories 1–4. Same methodology as all published results.
Internal Precision Benchmark
69 queries across 107 memories. Tests domain filtering, irrelevance detection, causal reasoning, and temporal understanding.
pass rate
Domain Filtering & Irrelevance
28/28 queries
100%
CortexDB
0%
Vector DB
Preference Understanding
5/5 queries
100%
CortexDB
80%
Vector DB
Enterprise Incident Response
15/18 queries
83%
CortexDB
72%
Vector DB
Personal AI Assistant
17/18 queries
94%
CortexDB
83%
Vector DB
Average recall latency
6-phase pipeline including embedding + neural reranking. Statistical filtering adds <100ms.
sub-second for most queries
Developer Experience
First-class SDKs for every stack
Get started in minutes with our Python, TypeScript, or REST API.
from cortexdb import Cortex
client = Cortex("https://api.cortexdb.ai", api_key="your-key")
# Store a memory
client.remember(
content="Q3 revenue exceeded $2.4M, up 34% YoY",
tenant_id="acme-corp",
)
# Retrieve with hybrid search
result = client.recall(
query="What was Q3 revenue?",
tenant_id="acme-corp",
)
print(result.context)
# => "Q3 revenue exceeded $2.4M, up 34% YoY"Works with your favorite IDE
Install the CortexDB MCP server and give any AI-powered IDE persistent long-term memory. One command, every conversation remembers.
# Install the MCP server
pip install cortexdb-mcp
# Add to Claude Code (one command)
claude mcp add cortexdb cortexdb-mcp \
-e CORTEXDB_URL=https://api.cortexdb.ai \
-e CORTEXDB_API_KEY=your_key_here20 built-in tools
Store, search, forget, explore knowledge graphs, run deployment reviews — all from your IDE.
Zero local storage
The MCP server is a lightweight bridge. All data lives in CortexDB cloud — nothing stored on your machine.
Works everywhere MCP does
Any client that speaks Model Context Protocol gets instant access to CortexDB's full memory system.
Connects to everything you use
Drop-in support for 19 agent frameworks, 16 data connectors, 6 orchestration tools, and more. Click any integration for docs.
Ready to give your AI agents perfect memory?
Get started in under 5 minutes. Free tier available — no credit card required.