Skip to content

beamwarden/mcp-memory-proxy

Repository files navigation

mcp-memory-proxy

A lightweight MCP server that wraps @modelcontextprotocol/server-memory with per-project namespace isolation.

All memory entities are prefixed by project slug ({project}::name) before being forwarded to the underlying memory server, preventing cross-project bleed. The prefix is stripped transparently on reads so callers see bare names.

How it works

Every tool call requires a project parameter matching a slug in config.json. The proxy:

  1. Prefixes entity names and relation endpoints with {project}:: before writing
  2. Filters results to the current project's namespace on reads
  3. Strips the prefix from returned values

config.json is re-read on every request — add a new project slug and it takes effect immediately without restarting the server.

Requirements

  • Python 3.11+
  • uv
  • Node.js / npx (for the underlying @modelcontextprotocol/server-memory server)

Setup

uv sync

Running

uv run python server.py

Configuration

Edit config.json to add or remove project slugs:

{
  "projects": ["my-project", "another-project"]
}

Changes take effect immediately with no server restart.

Tools

Tool Description
list_projects Return all known project slugs from config.json
create_entities Store entities scoped to a project
create_relations Store relations scoped to a project
search_nodes Search within a single project's namespace
open_nodes Retrieve specific entities by name within a project
delete_entities Delete entities from a project's namespace
cross_project_search Search across all projects (opt-in)

Development

# Type check
uv run mypy server.py --ignore-missing-imports

# Tests
uv run pytest tests/ -v

About

MCP server that wraps @modelcontextprotocol/server-memory with per-project namespace isolation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages