devmcp-context

mcp
Security Audit
Pass
Health Pass
  • License — License: MIT
  • Description — Repository has a description
  • Active repo — Last push 0 days ago
  • Community trust — 10 GitHub stars
Code Pass
  • Code scan — Scanned 12 files during light audit, no dangerous patterns found
Permissions Pass
  • Permissions — No dangerous permissions requested

No AI report is available for this listing yet.

SUMMARY

Structured AI memory layer. A single source of truth for what your agent knows across conversations. :)

README.md

devmcp-context

PyPI version
Python
License: MIT

devmcp-context logo

Structured AI memory layer. A single source of truth for what your agent knows across conversations.

devmcp-context is a Model Context Protocol (MCP) server that provides persistent, organized memory for AI agents. Your agent's memory is now visible, editable, and searchable - without retraining.

Published on PyPI: https://pypi.org/project/devmcp-context/

The Problem

AI agents are black boxes. You can't see what they remember. When they forget something important or remembers something wrong, you're stuck.

devmcp-context changes this. Your agent's memory is now:

  • Visible - Plain text files in your project folder
  • Editable - Change any entry, agent sees it immediately
  • Structured - Organized into 5 categories with automatic cleanup
  • Persistent - Survives across agent sessions and restarts
  • Recall-first - Memory loads automatically at session start

Installation

pip install devmcp-context

Or with uv:

uv add devmcp-context

Quick Start

cd your-project
devmcp-context init

That's it. This scaffolds ai-context/ and configures your MCP client automatically. Supports opencode, Cursor, and Claude Desktop - auto-detected from your project.

For multiple projects, run init in each project directory. Each gets its own config entry:

cd ~/projects/todo-app && devmcp-context init
cd ~/projects/blog && devmcp-context init

Manual setup (if auto-detection doesn't work):

devmcp-context init --client opencode   # or cursor, claude
devmcp-context init --name my-context   # custom entry name

Features

  • Auto-recall at session start - project + decisions memory loaded automatically, compact index of everything else
  • 5 memory categories (project, decisions, errors, tasks, ephemeral)
  • Outcome tracking - what_worked and what_failed fields for decisions and errors
  • Superseded entries - redirect recall to newer entries instead of deleting history
  • Key fact first - entry summaries lead with the most important line
  • Automatic expiration (TTL) - errors expire in 30 days, tasks in 14
  • Full-text search across all entries
  • Tagging system for organization
  • Persistent file-based storage (no database)
  • Session recall metric - tracks whether memory was used before edits
  • MCP-compliant server

Documentation

Full docs: https://kushal1o1.github.io/devmcp-context/

  • Getting Started guide
  • Installation instructions
  • API Reference (8 tools)
  • Memory categories explained
  • Architecture diagrams (Mermaid)
  • Deployment guide
  • Development guide

Usage Example

In your agent prompt:

Agent calls context_session_start first to load memory.

Use context_save to remember insights:
- save("decisions", "auth_strategy", "Use JWT with refresh tokens",
       tags=["security"],
       what_worked="Stateless, scales horizontally",
       what_failed="Token refresh is complex")

Use context_load to retrieve memories:
- load("decisions")

Use context_search to find specific memories:
- search("JWT")

Use superseded_by to redirect old entries:
- save("decisions", "new-auth", "Switched to OAuth2",
       superseded_by="old-auth")

License

MIT - See LICENSE for details.

Contributing

Contributions welcome! See CONTRIBUTING.md for guidelines.

Reviews (0)

No results found