Memory Bank MCP

Memory Bank MCP

An MCP server that helps teams create, manage, and access structured project documentation through six core document types, leveraging AI to generate comprehensive project knowledge management.

Category
Visit Server

README

Memory Bank MCP

<div align="center"> <img src="https://raw.githubusercontent.com/modelcontextprotocol/mcp/main/icon.png" height="128"> <h1>Memory Bank MCP</h1> <p> <b>A structured documentation system for project knowledge management via Model Context Protocol (MCP)</b> </p> </div>

Memory Bank is an MCP server that helps teams create, manage, and access structured project documentation. It generates and maintains a set of interconnected Markdown documents that capture different aspects of project knowledge, from high-level goals to technical details and day-to-day progress.

Features

  • AI-Generated Documentation: Leverages Gemini API to automatically generate comprehensive project documentation
  • Structured Knowledge System: Maintains six core document types in a hierarchical structure
  • MCP Integration: Implements the Model Context Protocol for seamless integration with AI assistants
  • Customizable Location: Specify where you want your Memory Bank directory created
  • Document Templates: Pre-defined templates for project brief, product context, system patterns, etc.
  • AI-Assisted Updates: Update documents manually or regenerate them with AI assistance
  • Advanced Querying: Search across all documents with context-aware relevance ranking

Installation

# Clone the repository
git clone https://github.com/yourusername/memory-bank-mcp.git
cd memory-bank-mcp

# Install dependencies
npm install

# Create .env file with your Gemini API key (optional)
echo "GEMINI_API_KEY=your_api_key_here" > .env

Usage

Development Mode

# Start in development mode
npm run dev

Production Mode

# Build the project
npm run build

# Start in production mode
npm run start

MCP Configuration

To integrate Memory Bank with the Model Context Protocol (MCP), add the following configuration to your mcp.json file:

{
  "memoryBank": {
    "command": "node",
    "args": ["/path/to/memory-bank-mcp/dist/index.js"],
    "env": {
      "GEMINI_API_KEY": "your_gemini_api_key_here"
    }
  }
}

Replace /path/to/memory-bank-mcp/dist/index.js with the absolute path to your built index.js file, and add your Gemini API key (if applicable).

Example:

{
  "memoryBank": {
    "command": "node",
    "args": ["/Users/username/memory-bank-mcp/dist/index.js"],
    "env": {
      "GEMINI_API_KEY": "AIzaSyXXXXXXXXXXXXXXXXXXXXXXXX"
    }
  }
}

MCP Tools

Memory Bank MCP provides the following tools via the Model Context Protocol:

initialize_memory_bank

Creates a new Memory Bank structure with all document templates.

Parameters:

  • goal (string): Project goal description (min 10 characters)
  • geminiApiKey (string, optional): Gemini API key for document generation
  • location (string, optional): Absolute path where memory-bank folder will be created

Example:

await callTool({
  name: "initialize_memory_bank",
  arguments: {
    goal: "Building a self-documenting AI-powered software development assistant",
    location: "/Users/username/Documents/projects/ai-assistant"
  }
});

update_document

Updates a specific document in the Memory Bank.

Parameters:

  • documentType (enum): One of: projectbrief, productContext, systemPatterns, techContext, activeContext, progress
  • content (string, optional): New content for the document
  • regenerate (boolean, default: false): Whether to regenerate the document using AI

Example:

await callTool({
  name: "update_document",
  arguments: {
    documentType: "projectbrief",
    content: "# Project Brief\n\n## Purpose\nTo develop an advanced and user-friendly AI..."
  }
});

query_memory_bank

Searches across all documents with context-aware relevance ranking.

Parameters:

  • query (string): Search query (min 5 characters)

Example:

await callTool({
  name: "query_memory_bank",
  arguments: {
    query: "system architecture components"
  }
});

export_memory_bank

Exports all Memory Bank documents.

Parameters:

  • format (enum, default: "folder"): Export format, either "json" or "folder"
  • outputPath (string, optional): Custom output path for the export

Example:

await callTool({
  name: "export_memory_bank",
  arguments: {
    format: "json",
    outputPath: "/Users/username/Documents/exports"
  }
});

Document Types

Memory Bank organizes project knowledge into six core document types:

  1. Project Brief (projectbrief.md): Core document defining project objectives, scope, and vision
  2. Product Context (productContext.md): Documents product functionality from a user perspective
  3. System Patterns (systemPatterns.md): Establishes system architecture and component relationships
  4. Tech Context (techContext.md): Specifies technology stack and implementation details
  5. Active Context (activeContext.md): Tracks current tasks, open issues, and development focus
  6. Progress (progress.md): Documents completed work, milestones, and project history

License

MIT

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured