Skip to main content

Persistent semantic key-value memory MCP server with ChromaDB backend

Project description

memorious-mcp

Memorious-MCP is a minimal Model Context Protocol (MCP) server that provides a persistent key-value memory store with vector-similarity lookup using ChromaDB.

Features

  • FastMCP-based MCP stdio server exposing three tools: store, recall, and forget.
  • ChromaDB backend (ChromaMemoryBackend) persisting data on disk using Chroma's PersistentClient.
  • Tests (integration) that exercise store/recall/forget behavior.
  • Standard Python package layout for easy installation and distribution.

Getting Started

  1. Install the package (recommended in a virtual environment):
# Install in development mode
uv sync

# Or install from source
pip install .
  1. Run the server (stdio transport, suitable for local/CLI integrations):
# Using uv
uv run memorious-mcp --collection memories

# Or if installed globally
memorious-mcp --collection memories
  1. Call tools using an MCP client (FastMCP client or a compatible MCP client) over stdio.

Example Tool Signatures

  • store(key: str, value: str) -> {"id": str}
  • recall(key: str, top_k: int = 3) -> {"results": [...]} where each result includes id, key, value, distance, timestamp
  • forget(key: str, top_k: int = 3) -> {"deleted_ids": [...]}

Testing

Run tests with:

# Using uv
uv run python -m pytest tests/ -v

# Or if pytest is available globally
pytest tests/ -v

Package Structure

The project follows the standard Python package layout:

memorious-mcp/
├── src/
│   └── memorious_mcp/
│       ├── __init__.py
│       ├── main.py                 # MCP server entry point
│       └── backends/
│           ├── __init__.py
│           ├── memory_backend.py   # Abstract base class
│           └── chroma_backend.py   # ChromaDB implementation
├── tests/
│   └── test_chroma_backend.py      # Integration tests
├── pyproject.toml                  # Package configuration
└── README.md

Notes

  • By default memory persistence is enabled and stored under ./.memorious. You can override persist_directory when creating ChromaMemoryBackend in code.
  • The backend uses Chroma's default embedding function when available.
  • The package is configured with a console script entry point for easy command-line usage.

Contributing

Contributions are welcome. Open a PR with tests.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

memorious_mcp-0.0.2.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

memorious_mcp-0.0.2-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file memorious_mcp-0.0.2.tar.gz.

File metadata

  • Download URL: memorious_mcp-0.0.2.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for memorious_mcp-0.0.2.tar.gz
Algorithm Hash digest
SHA256 35d5dccd0961a74dbbc89e40748f7a392f96f2b969f55a52425d255889d879b4
MD5 5f4633cb2cf4394375d3c4569c4a752a
BLAKE2b-256 f1cf2f0dea2f9f6013dc6d218ac3163d750558e33dd966fb8b0b0583f09b7005

See more details on using hashes here.

File details

Details for the file memorious_mcp-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: memorious_mcp-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 7.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for memorious_mcp-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 7b3766774843aa64f379e3eba761319bdb4ee8c88482ec8fb68ab765f491b0df
MD5 fdf74001e4a075bc060217bd0b3faeef
BLAKE2b-256 8fc675a299ead1ae990f344d1e4a34ac447ed47051cda4455357d39ef9513632

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page