MADB — Agent Memory Database logo

MADB — Agent Memory Database

Stores local, causally linked agent memories with semantic recall, skills, and MCP tools for Claude clients.

Install MADB — Agent Memory Database

Pick your client, then add it in one click or paste the config.

STDIOPython
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "madb-agent-memory-database": {
      "command": "uvx",
      "args": [
        "madb-mcp-server"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Install not yet sandbox-tested— we haven't run this command through our automated sandbox yet. Not a red flag; we're working through the catalog.

Overview

MADB — Agent Memory Database provides persistent agent memory through an MCP server backed by a local `~/.madb` store. It combines semantic recall, causal relationships, importance-based retention, and ordered versioning in a compiled database engine. MCP clients receive tools for storing, finding, tracing, summarizing, and managing memories and reusable skills. Reach for it when an agent needs memory shared across sessions without assembling separate databases and vector stores.

Use cases

  • Persist memories across Claude sessions
  • Recall semantically related prior events
  • Trace causal relationships between memories
  • Store and retrieve reusable agent skills
  • Summarize selected memories for context

Key features

  • Local `~/.madb` memory storage
  • Composite-scored semantic recall
  • Causal DAG lineage tracing
  • Importance-based forgetting with tombstones
  • Reusable skill storage and recall
  • Multi-session daemon coordination

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 3d ago

Recent health check succeeded.

7/7 checks healthy over the last 46d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 11d ago via OSV.dev · madb-mcp-server (PyPI)

How MADB — Agent Memory Database works

What MADB — Agent Memory Database does

MADB — Agent Memory Database gives MCP-compatible agents a local persistence layer for memories, causal relationships, and reusable skills. The database engine uses a hybrid LSM design, a causal directed acyclic graph, composite scoring for recall, importance-based forgetting, and HLC-ordered MVCC. Data is stored locally under ~/.madb, rather than in a hosted service.

The project distributes compiled Python wheels. The MCP package includes the server and a bundled Claude Skill that instructs Claude to use MADB for persistent memory instead of creating ad hoc files, tables, or conversation-history structures. A separate Python package provides an Anthropic SDK shim that automatically persists calls made through the wrapped client.

How it works

An agent can write a memory with optional tags, importance, and a link to the memory that caused it. Recall ranks results using several signals: semantic similarity, recency, causal proximity, importance, and tag overlap. Memories can also be retrieved by event ID, searched using structured tenant, scope, and tag filters, or listed in newest-first order.

Causal lineage remains available after a memory is soft-deleted because forget creates a tombstone instead of removing the node from the graph. The trace_cause tool walks the graph forward or backward from a selected memory. Skills use a separate save and recall flow, with idempotent storage by name and protection from garbage collection.

Multiple Claude Code sessions can use one store through a local daemon. The first session starts it on demand, later sessions reuse it, and the daemon exits after an idle period. A token-guarded loopback HTTP connection separates MCP clients from the single store owner. The embedded mode restores direct single-session access, while daemon mode treats daemon failures as fatal.

Setup and configuration

For Claude Code, install the MCP server with claude mcp add madb -- uvx madb-mcp-server. The packages can also be installed with pip install madb-mcp-server or run through uvx madb-mcp-server. Claude Desktop users can install the supplied .mcpb extension. The first launch can install the bundled memory Skill into ~/.claude/skills/madb-memory/.

No external database service is required. The optional MADB_TELEMETRY=off setting disables anonymous usage telemetry. MADB_MODE=embedded selects direct single-session operation; MADB_MODE=daemon requires the daemon path; and MADB_DAEMON_IDLE_SEC changes the idle timeout, with values at or below zero disabling that timeout.

Tools and capabilities

The free tier exposes 13 memory tools:

  • remember, recall, get_memory, forget, search, and list_recent manage and retrieve memories.
  • save_skill, recall_skill, and list_skills store and find reusable patterns.
  • trace_cause follows causal lineage, while summarize condenses selected memories.
  • stats reports engine metrics, and capabilities reports workspace capabilities and entitlement information.

The MCP resource madb://memories/{event_id} exposes an individual memory as a URI. MADB — Agent Memory Database also includes an onboarding Skill that detects an empty store and offers a guided first-run tour. Developers using the raw Anthropic API can use the madb-anthropic package and replace the standard client import with its Anthropic wrapper.

Limitations and notes

MADB is distributed under the Meta-Agents.AI Proprietary License. The license permits installation and use in an organization’s infrastructure, including production use for its own users, but does not permit redistribution, reverse engineering, hosted-service offerings, or embedding in a commercial product sold to third parties. Source code is not public. Source access, OEM rights, and hosted-service rights require separate written agreements.

The bundled memory Skill has separate CC-BY-ND 4.0 terms. Earlier versions of some portions may remain available under Apache 2.0 for the specific versions released under that license; new releases use the proprietary license. The store is designed around a single owner, with the local daemon coordinating concurrent sessions.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about MADB — Agent Memory Database

MADB — Agent Memory Database is an MCP server that connects Claude-compatible MCP clients to a local `~/.madb` memory store. Its main tools let agents remember, recall, search, trace causes, manage skills, summarize memories, inspect metrics, and read memory resources. It also supports a Python Anthropic SDK shim for automatic persistence.

Install it for Claude Code with `claude mcp add madb -- uvx madb-mcp-server`. You can also use `pip install madb-mcp-server` or `uvx madb-mcp-server`; Claude Desktop users can install the provided `.mcpb` extension.

MADB stores memories locally in `~/.madb`. It does not require an external database service, and the local daemon allows multiple sessions to use the same store.

Yes, MADB works with Claude Code through the documented `claude mcp add` command. The MCP server can share one local memory store across multiple Claude Code sessions through its on-demand daemon.

Set `MADB_TELEMETRY=off` to disable anonymous usage telemetry.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewMADB — Agent Memory Database AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/madb-agent-memory-database?style=directory)](https://allmcps.com/mcp/madb-agent-memory-database)
HTML Embed
<a href="https://allmcps.com/mcp/madb-agent-memory-database"><img src="https://allmcps.com/api/badge/madb-agent-memory-database?style=directory" alt="MADB — Agent Memory Database on AllMCPs" /></a>