Featured

Deploy OpenClaw in 60 seconds — 20% off logoDeploy OpenClaw in 60 seconds — 20% off

Launch OpenClaw on Hostinger in about 60 seconds and keep your agent live 24/7. Our referral link gives you 20% off, no coupon code needed.

Launch on Hostinger
Run your Hermes agent on Hostinger, fully managed logoRun your Hermes agent on Hostinger, fully managed

Launch Hermes on Hostinger in one click, fully managed, no VPS knowledge needed. Use code ZACAARON10 for 10% off.

Launch on Hostinger
Crawl and scrape any site into clean data, 10% off logoCrawl and scrape any site into clean data, 10% off

Firecrawl crawls and scrapes any site into clean markdown for your agent. Get 1,000 free credits, and new users get 10% off their first purchase.

Try Firecrawl free
6,000+ web scrapers for your AI agent, start free logo6,000+ web scrapers for your AI agent, start free

Apify gives your agent live web data: 6,000+ prebuilt scrapers and actors, MCP-ready. Sign up free with $5 in usage credits.

Try Apify free
One API to scrape, enrich, and extract the internet. logoOne API to scrape, enrich, and extract the internet.

Context.dev gives your agents a single API to scrape, enrich, and extract live web data — no proxies, no parsers, no maintenance.

Start building free
SetupClaw: done-for-you OpenClaw for founders & exec teams logoSetupClaw: done-for-you OpenClaw for founders & exec teams

White-glove OpenClaw for founders and exec teams (4–50+ employees): we install, harden, integrate your tools, and maintain it — secured from day one.

Get it set up for you
SEO data APIs for your agent, $1 free credit logoSEO data APIs for your agent, $1 free credit

DataForSEO gives your agent live access to SERP results, keyword data, backlinks, and on-page SEO data through one API. New accounts get a $1 credit, good for up to 20,000 keyword or backlink lookups.

Try DataForSEO free
Reach 48,000+ AI builders

A flat monthly placement in front of developers actively installing AI tools. No lock-in, cancel anytime.

Advertise here

Works with

Claude CodeClaude DesktopCursorVS CodeClineCodex CLIOpenClaw+ any MCP client

Install to Claude Code

This server doesn't publish a one-line install command. Follow the setup in the source repository.

Summary

Persistent AI knowledge base for Claude via Model Context Protocol — fully offline, no cloud API key required. Stores architectural decisions, technical debt, project progress, and domain knowledge in versioned Markdown files.

README.md

project-memory-mcp

Persistent AI knowledge base for Claude via Model Context Protocol — fully offline, no cloud API key required.

Stores architectural decisions, technical debt, project progress, and domain knowledge in versioned Markdown files. Claude reads these files automatically via MCP Resources and writes new entries via MCP Tools.

Features

  • 4 MCP Resources — Claude reads memory://decisions, memory://tech-debt, memory://progress, memory://context automatically at session start
  • 7 MCP Toolsadd_decision, log_tech_debt, update_progress, add_context, get_memory, search_memory, reindex_memory
  • Semantic Search — Embedding-based search via @huggingface/transformers (all-MiniLM-L6-v2) stored locally in SQLite
  • Git Hook — Post-commit hook sends diff + message to Ollama for automatic summarization and auto-commits the updated memory files
  • Filesystem Watcher — Changes to CLAUDE.md, docs/adr/, etc. trigger memory updates
  • Session Summary — Inactivity timer writes a session summary to progress.md
  • Ollama Fallback — Keyword extraction when Ollama is unavailable

Prerequisites

  • Node.js >= 20
  • Ollama (optional, for automatic summarization)
ollama pull llama3.2

Installation

In a new project (recommended)

npx @pnientiedt/project-memory-mcp init

This sets up everything automatically:

  • Creates .project-memory/config.yaml with documented defaults
  • Adds project-memory entry to .mcp.json
  • Updates .gitignore with database/log exclusions
  • Installs the git post-commit hook
  • Pulls llama3.2 if Ollama is running

From source

npm install
npm run build

Register the MCP server in Claude Code (.mcp.json already pre-configured):

{
  "mcpServers": {
    "project-memory": {
      "command": "npx",
      "args": ["@pnientiedt/project-memory-mcp"]
    }
  }
}

Usage

After startup Claude reads the memory files automatically. New entries are written via tools:

add_decision    — Save an architectural decision (ADR format); upsert=true to replace existing
log_tech_debt   — Record technical debt; upsert=true to replace existing
update_progress — Update a milestone; upsert=true to replace existing
add_context     — Save domain knowledge / conventions; upsert=true to replace existing
get_memory      — Read a memory file directly
search_memory   — Semantic search across the knowledge base
reindex_memory  — Rebuild the embedding index

Configuration

.project-memory/config.yaml (created with defaults on first run):

ollama:
  base_url: "http://localhost:11434"
  model: "llama3.2"
  timeout_seconds: 60
  fallback_to_keywords: true

embeddings:
  model: "Xenova/all-MiniLM-L6-v2"
  db_path: ".project-memory/embeddings.db"

git:
  hook_enabled: true
  hook_port: 47832
  skip_keyword: "[skip-memory]"

watcher:
  enabled: true
  paths: ["CLAUDE.md", "docs/adr/", "README.md"]
  debounce_ms: 2000

session:
  inactivity_timeout_minutes: 30
  summarize_on_end: true

Environment variables override config:

| Variable | Overrides | |----------|-----------| | PMM_OLLAMA_URL | ollama.base_url | | PMM_OLLAMA_MODEL | ollama.model | | PMM_HOOK_PORT | git.hook_port | | PMM_LOG_LEVEL | logging.level |

Memory Files

Located in .project-memory/ and versioned in git (except embeddings.db and server.log):

| File | Contents | |------|----------| | decisions.md | Architectural decisions (ADRs) | | tech_debt.md | Technical debt | | progress.md | Project progress & session summaries | | context.md | Domain knowledge & conventions |

Development

npm test              # Run tests (101 tests)
npm run test:coverage # Coverage report (83% line coverage)
npm run build         # Compile TypeScript
npm run typecheck     # Type check only
npm run release       # typecheck + test + build + npm publish

Project Structure

src/
  index.ts              # Entry point, stdio transport
  server.ts             # MCP server factory
  config.ts             # Load & validate configuration (zod)
  types.ts              # Shared TypeScript types
  resources/
    memory.ts           # MCP resources (memory://)
  tools/
    write.ts            # add_decision, log_tech_debt, update_progress, add_context
    read.ts             # get_memory, search_memory
    admin.ts            # reindex_memory
  services/
    file.ts             # Atomic read/write of memory files
    embedding.ts        # transformers.js + cosine similarity
    db.ts               # SQLite schema (WAL mode)
    ollama.ts           # Ollama HTTP client + keyword fallback
    summarization.ts    # Prompts per memory category
    git.ts              # simple-git integration
  triggers/
    git-hook.ts         # HTTP server for post-commit hook
    watcher.ts          # Filesystem watcher (chokidar)
    session.ts          # Inactivity timer & session summary
hooks/
  post-commit           # Shell script for git hook

See related servers & alternatives →

Related MCP servers

Browse all →

Related guides

Hand-picked reading to help you choose and use Vector & Memory servers.