Skip to content

🧠 Roo Code Memory Bank - Now with new debug mode! (Thanks @TheRealAlexV) Solve the AI context challenge: maintain deep project understanding across sessions with our structured VS Code memory system. Never repeat project details again! ✨

License

Notifications You must be signed in to change notification settings

enerage/roo-code-memory-bank

Β 
Β 

Repository files navigation

🧠 Roo Code Memory Bank

Persistent Project Context for AI-Assisted Development

VS Code Extension GitHub

🎯 Overview

Roo Code Memory Bank solves a critical challenge in AI-assisted development: maintaining context across sessions. By providing a structured memory system integrated with VS Code, it ensures your AI assistant maintains a deep understanding of your project across sessions.

Key Components

graph LR
    A[Memory Bank] --> B[Core Files]
    A --> C[Mode Rules]
    A --> D[VS Code UI]
    B --> E[Project Context]
    B --> F[Decisions]
    B --> G[Progress]
    C --> H[Architect]
    C --> I[Code]
    C --> J[Ask]
    C --> K1[Debug]
    K[Real-time Updates] --> B
    K --> L[Continuous Sync]
    L --> M[Auto-save]
    L --> N[Event Tracking]
Loading
  • 🧠 Memory Bank: Persistent storage for project knowledge
  • πŸ“‹ Mode Rules: YAML-based behavior configuration
  • πŸ”§ VS Code Integration: Seamless development experience
  • ⚑ Real-time Updates: Continuous context synchronization

πŸš€ Quick Start

1. Configure Custom Instructions

a. Copy Rule Files

Download and copy these files to your project's root directory:

Mode Rule File Purpose
Code .clinerules-code Implementation and coding tasks
Architect .clinerules-architect System design and architecture
Ask .clinerules-ask Information and assistance
Debug .roomodes Troubleshooting and problem-solving

b. Configure VS Code Settings

⚠️ Important: Leave the "Custom Instructions" text boxes empty in VS Code settings (Roo Code Prompts section)

πŸ“· View Settings Screenshot

Roo Code Settings

2. Initialize Memory Bank

  1. Switch to Architect or Code mode in Roo Code chat
  2. Send a message (e.g., "hello")
  3. Roo will automatically:
    • πŸ” Scan for memory-bank/ directory
    • πŸ“ Create it if missing (with your approval)
    • πŸ“ Initialize core files
    • 🚦 Provide next steps
πŸ’‘ Pro Tip: Project Brief

Create a projectBrief.md in your project root before initialization to give Roo immediate project context.

File Organization

project-root/
β”œβ”€β”€ .clinerules-architect
β”œβ”€β”€ .clinerules-code
β”œβ”€β”€ .clinerules-ask
β”œβ”€β”€ .roomodes
β”œβ”€β”€ memory-bank/
β”‚   β”œβ”€β”€ activeContext.md
β”‚   β”œβ”€β”€ productContext.md
β”‚   β”œβ”€β”€ progress.md
β”‚   └── decisionLog.md
└── projectBrief.md

πŸ“š Memory Bank Structure

graph TD
    MB[memory-bank/] --> AC[activeContext.md]
    MB --> DL[decisionLog.md]
    MB --> PC[productContext.md]
    MB --> PR[progress.md]
    MB --> PB[projectBrief.md]
    MB --> SP[systemPatterns.md]
    
    subgraph Core Files
        AC[Current Session State]
        DL[Technical Decisions]
        PC[Project Overview]
        PR[Progress Tracking]
    end
    
    subgraph Optional
        PB[Project Brief]
        SP[System Patterns]
    end
Loading
πŸ“– View File Descriptions
File Purpose
activeContext.md Tracks current goals, decisions, and session state
decisionLog.md Records architectural choices and their rationale
productContext.md Maintains high-level project context and knowledge
progress.md Documents completed work and upcoming tasks
projectBrief.md Contains initial project requirements (optional)
systemPatterns.md Documents recurring patterns and standards

✨ Features

🧠 Persistent Context

  • Remembers project details across sessions
  • Maintains consistent understanding of your codebase
  • Tracks decisions and their rationale

πŸ”„ Smart Workflows

graph LR
    A[Architect Mode] -->|Real-time Design Updates| B[Memory Bank]
    C[Code Mode] -->|Real-time Implementation| B
    D[Ask Mode] -->|Real-time Insights| B
    F[Debug Mode] -->|Real-time Analysis| B
    B -->|Instant Context| A
    B -->|Instant Context| C
    B -->|Instant Context| D
    B -->|Instant Context| F
    E[Event Monitor] -->|Continuous Sync| B
Loading
  • Mode-based operation for specialized tasks
  • Automatic context switching
  • Project-specific customization via rules

πŸ“Š Knowledge Management

  • Structured documentation with clear purposes
  • Technical decision tracking with rationale
  • Automated progress monitoring
  • Cross-referenced project knowledge

πŸ’‘ Pro Tips

Multiple Projects

graph TD
    A[Workspace] --> B[Project 1]
    A --> C[Project 2]
    B --> D[memory-bank/]
    C --> E[memory-bank/]
    D --> F[Automatic Detection]
    E --> F
Loading

Roo automatically handles multiple Memory Banks in your workspace!

Debug Mode

Roo Code Memory Bank now includes a Debug mode for troubleshooting and problem-solving. This mode was added using a .roomodes file in the project root:

{
  "customModes": [
    {
      "slug": "debug",
      "name": "Debug",
      "roleDefinition": "You are Roo, a meticulous problem-solver with surgical precision...",
      "groups": [
        "read",
        "command"
      ]
    }
  ]
}

Debug mode provides:

  • Read-only access to files for safe analysis
  • Command execution for diagnostic tools
  • Systematic problem investigation
  • Root cause identification
  • Evidence-based verification

Switch to Debug mode when you need to troubleshoot issues in your project.

Session Management

  • ⚑ Real-time Updates: Memory Bank automatically stays synchronized with your work
  • πŸ’Ύ Manual Updates: Use "UMB" or "update memory bank" as a fallback when:
    • Ending a session unexpectedly
    • Halting mid-task
    • Recovering from connection issues
    • Forcing a full synchronization

πŸ“– Documentation


License

Apache 2.0 Β© 2025 GreatScottyMac

About

🧠 Roo Code Memory Bank - Now with new debug mode! (Thanks @TheRealAlexV) Solve the AI context challenge: maintain deep project understanding across sessions with our structured VS Code memory system. Never repeat project details again! ✨

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published