Roo Code Memory Bank MCP Server
The Roo Code Memory Bank MCP Server helps maintain project context across sessions using file-based memory management. With this server, you can:
Initialize a memory bank by creating a
memory-bank/directory with standard markdown filesCheck memory bank status and list existing files
Read the full content of specific memory bank files
Append timestamped entries to files, optionally under specific markdown headers, creating files if they don't exist
Manages a project memory bank using Markdown files, providing tools to initialize, read, and append to structured context files that maintain project knowledge across sessions.
Serves as the runtime environment for the memory bank system, allowing file operations to create, check, read, and update the contextual knowledge base.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Roo Code Memory Bank MCP Server append a note about the new authentication system to decisionLog.md"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Roo Code Memory Bank MCP Server
This project implements the core functionality of the Roo Code Memory Bank system as a Model Context Protocol (MCP) server. It allows AI assistants to maintain project context across sessions by interacting with a file-based memory bank using structured MCP tools.
Features
This MCP server provides the following tools:
initialize_memory_bank: Creates thememory-bank/directory and standard.mdfiles (productContext.md,activeContext.md,progress.md,decisionLog.md,systemPatterns.md) with initial templates.Input: (Optional)
{ "project_brief_content": string }Output:
{ "status": "success" | "error", "messages"?: string[], "message"?: string }
check_memory_bank_status: Checks if thememory-bank/directory exists and lists the.mdfiles within it.Input:
{}Output:
{ "exists": boolean, "files": string[] }
read_memory_bank_file: Reads the full content of a specified memory bank file.Input:
{ "file_name": string }Output:
{ "content": string }or error object.
append_memory_bank_entry: Appends a new, timestamped entry to a specified file, optionally under a specific markdown header. Creates the file if it doesn't exist.Input:
{ "file_name": string, "entry": string, "section_header"?: string }Output:
{ "status": "success" | "error", "message": string }
Related MCP server: ai-memory-mcp
Prerequisites
Node.js (v18 or later recommended)
npm (usually included with Node.js)
An MCP client environment (like the one used by Cline) capable of managing and launching MCP servers.
Installation
Clone the repository:
git clone https://github.com/IncomeStreamSurfer/roo-code-memory-bank-mcp-server.git cd roo-code-memory-bank-mcp-serverInstall dependencies:
npm installBuild the project:
npm run buildThis compiles the TypeScript code into JavaScript in the
dist/directory.
Configuration (for Cline MCP Client)
To make this server available to your AI assistant (like Cline), you need to add its configuration to your MCP settings file (e.g., cline_mcp_settings.json).
Find the mcpServers object in your settings file and add the following entry:
{
"mcpServers": {
// ... other server configurations ...
"roo-code-memory-bank-mcp": {
"autoApprove": [
"initialize_memory_bank",
"check_memory_bank_status",
"read_memory_bank_file",
"append_memory_bank_entry"
],
"disabled": false,
"timeout": 60,
"command": "node", // Or "cmd.exe" with "/c node ..." on Windows if needed
"args": [
// IMPORTANT: Replace this path with the actual absolute path
// to the compiled index.js file on your system
"/path/to/your/cloned/repo/roo-code-memory-bank-mcp-server/dist/index.js"
],
"env": {},
"transportType": "stdio"
}
// ... other server configurations ...
}
}Important: Replace /path/to/your/cloned/repo/ with the correct absolute path to where you cloned the repository on your machine. Ensure the path separator is correct for your operating system (e.g., use backslashes \ on Windows).
Running the Server
You don't typically need to run the server manually. The MCP client (like Cline) will automatically start the server using the command and args specified in the configuration file when one of its tools is called for the first time.
If you want to test it manually, you can run npm start from the project directory.
Usage
The AI assistant interacts with the server using the defined tools. The typical workflow involves:
Checking the memory bank status (
check_memory_bank_status).Initializing if needed (
initialize_memory_bank).Reading relevant files (
read_memory_bank_file) to gain context.Appending entries (
append_memory_bank_entry) as decisions are made or progress occurs.
The memory-bank/ directory will be created in the same directory where the server process is started (which should be the root of this project directory when launched via the MCP client configuration).
Custom instructions
Set these instructions inside Roo
You must use MCPs where needed
I have a specific MCP flow:
Use context7 to find any relevant documentation pieces you will need for this process, ensure to feed any relevant knoweldege to any relevant subtasks - use context7 at all times to do research on important documentation if you're unsure of something Use google maps mcp in order to search for + - this will allow us to find the basic businesses we need to accomplish our task Use brave search mcp to find URLs to scrape Use fetch mcp with fetch_txt and fetch_markdown to find text and images on pages in order to convert into JSON files and create something in-depth Use openrouter search to find general sentiment of topics, reviews, etc.
Utilize the roo-code-memory-bank-mcp server to maintain project context:
At the start of a task or significant subtask, use
check_memory_bank_status.If the memory bank exists (
exists: true), useread_memory_bank_filefor relevant files (e.g.,productContext.md,activeContext.md) to load the current project context.Incorporate this loaded context into your planning and execution.
When making significant decisions, progress updates, or architectural changes, use
append_memory_bank_entryto record the information in the appropriate file (decisionLog.md,progress.md, etc.), ensuring context persistence.If the memory bank doesn't exist, consider using
initialize_memory_bankif appropriate for the project.
Available Tools
4 toolsappend_memory_bank_entryC
Appends a new, timestamped entry to a specified file, optionally under a specific markdown header.
Inputs: entry (required), file_name (required), section_header.
check_memory_bank_statusA
Checks if the memory-bank directory exists and lists the .md files within it.
Inputs: no named parameters.
initialize_memory_bankB
Creates the memory-bank directory and standard .md files with initial templates.
Inputs: project_brief_content.
read_memory_bank_fileC
Reads the full content of a specified memory bank file.
Inputs: file_name (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Each tool has a clearly distinct purpose: append adds entries, check verifies directory status, initialize sets up the structure, and read retrieves content. There is no overlap in functionality, making it easy for an agent to select the correct tool without confusion.
All tool names follow a consistent verb_noun pattern (e.g., append_memory_bank_entry, check_memory_bank_status), with clear and descriptive verbs. There are no deviations in naming conventions, ensuring predictability and readability.
With 4 tools, the server is well-scoped for managing a memory bank system. Each tool serves a distinct and necessary function (setup, verification, reading, writing), and the count is neither too sparse nor excessive for the domain.
The tools cover core CRUD-like operations for a memory bank: initialize (create), check (status), read (retrieve), and append (update/add). A minor gap is the lack of a delete or modify tool for removing or editing entries, but agents can work around this with append for updates.
Maintenance
Related MCP Connectors
Portable AI memory shared across models and harnesses - plain markdown you own.
Project memory, documentation and controlled secret access for AI coding agents.
Shared project memory that keeps teammates and AI agents aligned across sessions.
Persistent memory for AI assistants: store, search, and connect knowledge across conversations.
Related MCP Servers
- AlicenseBqualityDmaintenanceProvides a structured documentation system for context preservation in AI assistant environments, helping users create and manage memory banks for their projects.377MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to retain memory across sessions by storing conversations locally in Markdown files, allowing personalization and continuity without external servers.MIT
- AlicenseNot gradedqualityDmaintenanceProvides persistent, project-specific memory to AI assistants via the Model Context Protocol, enabling context-aware collaboration across sessions without cloud dependencies.11 PyPI1Apache 2.0
- FlicenseNot gradedqualityFmaintenancePersistent memory for MCP-powered coding agents, allowing LLMs to remember preferences, project context, and decisions across sessions via Markdown files.6 npm-