{
  "markdown": "# Memori MCP\n\n> Persistent AI memory for any MCP-compatible agent — no SDK required.\n\n**memori-mcp** is the official [Memori](https://memorilabs.ai) MCP server. Connect it to your AI agent to give it long-term memory: recall relevant facts, retrieve broad state summaries, restore working state after context compaction, store durable preferences after responding, and maintain context across sessions.\n\n---\n\n## Why Memori MCP?\n\nMemori turns stateless agents into **stateful systems** by providing structured, persistent memory that works across sessions and workflows.\n\n1. **Persistent state beyond prompts** — Most agents rely on prompt context and lose state between runs. Memori provides **durable, structured memory** so agents can retain facts, decisions, and outcomes over time.\n2. **Memory from execution (not just natural language)** — Traditional systems extract memory from chat. Memori builds memory from **agent execution itself** — including tool calls, decisions, and results. This enables true **agent-native memory**, not just conversational recall.\n3. **Lower cost, higher accuracy** — Instead of expanding prompt context, Memori retrieves only what matters.\n   - Significantly reduced token usage\n   - Faster responses\n   - Improved accuracy vs long-context approaches\n4. **Works with any MCP client and production-ready** - No SDK, no code changes, just config\n\nMemori is **state infrastructure for production agents** — enabling persistent memory, efficient retrieval, and structured context across both natural language and agent execution.\n\n\n## LoCoMo Benchmark\n\nMemori was evaluated on the LoCoMo benchmark for long-conversation memory and achieved **81.95% overall accuracy** while using an average of **1,294 tokens per query**. That is just **4.97% of the full-context footprint**, showing that structured memory can preserve reasoning quality without forcing large prompts into every request.\n\nCompared with other retrieval-based memory systems, Memori outperformed Zep, LangMem, and Mem0 while reducing prompt size by roughly **67% vs. Zep** and lowering context cost by more than **20x vs. full-context prompting**.\n\nRead the [benchmark overview](https://memorilabs.ai/benchmark) or download the [paper](https://arxiv.org/abs/2603.19935).\n\n---\n\n## How It Works\n\nThe server exposes seven tools:\n\n| Tool | When to call | What it does |\n|------|-------------|--------------|\n| `memori_recall` | Start of each user turn | Fetches relevant memories at the start of a user turn |\n| `memori_recall_summary` | Session starts, daily briefs, status updates, project overviews | Fetches broad memory state for session starts, daily briefs, status updates, and project overviews |\n| `memori_compaction` | After context compaction | Fetches a structured post-compaction brief so an agent can resume operational work |\n| `memori_advanced_augmentation` | After composing a response | Stores durable memory after the agent has drafted a response |\n| `memori_feedback` | When the user flags a memory issue or praises a result | Reports irrelevant, missing, stale, or especially useful memory behavior |\n| `memori_signup` | When the user explicitly asks and provides an email | Requests a Memori account/API key when the user explicitly asks |\n| `memori_quota` | When the user asks about usage or quota errors appear | Checks current memory usage and limits when the user asks or quota errors appear |\n\n### Example Agent Flow\n\nGiven the user message: *\"I prefer Python and use uv for dependency management.\"*\n\n1. Agent calls `memori_recall` with the user message as `query`\n2. Agent composes a response using any returned facts\n3. Agent sends the response to the user\n4. Agent calls `memori_advanced_augmentation` with the `user_message` and `assistant_response`\n\nOn a later turn like *\"Write a hello world script\"*, the agent recalls the Python + uv preference and personalizes its response.\n\n---\n\n## Prerequisites\n\n- A Memori API key from [app.memorilabs.ai](https://app.memorilabs.ai)\n- An `entity_id` to identify the end user (e.g. `user_123`)\n- An optional `process_id` to identify the agent or workflow (e.g. `my_agent`)\n\nExport these in your shell or replace the placeholders directly in your config:\n\n```bash\nexport MEMORI_API_KEY=\"your-memori-api-key\"\nexport MEMORI_ENTITY_ID=\"user_123\"\nexport MEMORI_PROCESS_ID=\"my_agent\"   # optional\n```\n\n---\n\n## Server Details\n\n| Property | Value |\n|----------|-------|\n| **Server** | Memori MCP |\n| **Endpoint** | `https://api.memorilabs.ai/mcp/` |\n| **Transport** | Stateless HTTP |\n| **Auth** | API key via request headers |\n\n### Headers\n\n| Header | Required | Description |\n|--------|----------|-------------|\n| `X-Memori-API-Key` | Yes | Your Memori API key from [app.memorilabs.ai](https://app.memorilabs.ai) |\n| `X-Memori-Entity-Id` | Yes | Stable end-user or entity identifier (e.g. `user_123`) |\n| `X-Memori-Process-Id` | No | Optional process, app, or workflow identifier (e.g. `my_agent`) for memory isolation |\n\n`session_id` is derived automatically as `<entity_id>-<UTC year-month-day:hour>`. You do not need to provide it.\n\n---\n\n## Verifying the Connection\n\nAfter configuring your client, verify the setup:\n\n- MCP server shows as connected and healthy in your client UI\n- Tools list includes `memori_recall`, `memori_recall_summary`, `memori_compaction`, and `memori_advanced_augmentation`\n- Calls return non-401 responses\n- `memori_recall` returns memories for known entities\n- `memori_advanced_augmentation` accepts durable user/assistant turn data\n\nIf you receive `401` errors, double-check your `X-Memori-API-Key` value. See the [Troubleshooting guide](https://memorilabs.ai/docs/memori-cloud/support/troubleshooting) for more help.\n\n---\n\n## Links\n\n- [Memori Cloud](https://memorilabs.ai/docs/memori-cloud)\n- [Get an API key](https://app.memorilabs.ai)\n- [MCP Overview docs](https://memorilabs.ai/docs/memori-cloud/mcp/overview)\n- [Client Setup docs](https://memorilabs.ai/docs/memori-cloud/mcp/client-setup)\n- [Agent Skills docs](https://memorilabs.ai/docs/memori-cloud/mcp/agent-skills)\n",
  "bytes": 6065,
  "sha": "cfd7b09ebd49603b9f1247cba0b0925241a6accdaac13f31c81a9dc477fc5411",
  "repo_slug": "memorilabs/memori-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_memorilabs_memori_mcp_f78890c4/readme"
}