# Robrain

> Robrain is a freemium MCP server for knowledge and memory. Self-hosted decision memory that warns coding agents before they repeat a rejected idea. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Freemium
- **Platforms:** CLI, Self-hosted
- **Repository:** https://github.com/adelinamart/robrain
- **MCP Registry name:** io.github.adelinamart/robrain
- **Categories:** [knowledge and memory](https://ai-powered.com/categories/knowledge-and-memory), [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-23

## About

RoBrain records the decisions a team and its agents make, along with what was rejected and why, who decided and when. Before an agent acts again, it surfaces the earlier rejection. Capture is passive: session turns are sensed, and a Perception service extracts each decision into Postgres, where rows can carry a structured `rejected[]` field.

The README says its VetoBench run found frontier models re-proposed a rejected approach in 3 to 9 of 9 tasks without the warning, versus 0 of 159 with veto warnings in context across six models. Those are the project's own figures. A batch Synthesis step reads the whole corpus to flag contradictions and stance drift.

The free self-hosted path runs `npx robrain@latest up` and needs Anthropic and OpenAI keys by default, with other provider setups documented. A managed cloud is included with paid Rory Plans plans and adds team sharing and rule pushing to production agents built on Vercel's eve. It wires into Claude Code, Cursor, GitHub Copilot, Codex CLI and Hermes.

## Features

- **Structured vetoes:** Rejected approaches are stored with rationale, author, date and source turn.
- **Passive capture:** Decisions are extracted from sessions without manual tagging.
- **Corpus synthesis:** Batch scans find contradictions and drift across sessions.
- **Self-hosted Postgres:** Everything runs on your own database in the free option.
- **Claude Code plugin:** Hooks add capture and pre-task warnings.
- **Production agent governance:** On cloud, admins push reviewed rules to agents built on eve.

## Good for

- Stop an agent re-suggesting a dependency you removed for a CVE
- Hand a design decision from one teammate's editor to another's
- Audit who decided what and from which turn
- Push approved rules to production agents

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add robrain --env PERCEPTION_API_KEY='<PERCEPTION_API_KEY>' -- npx -y robrain
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "robrain": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add robrain --env PERCEPTION_API_KEY='<PERCEPTION_API_KEY>' -- npx -y robrain
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.robrain]
command = "npx"
args = ["-y", "robrain"]
env = { PERCEPTION_API_KEY = "<PERCEPTION_API_KEY>" }
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Or run: gemini mcp add -s user -e PERCEPTION_API_KEY='<PERCEPTION_API_KEY>' robrain npx -- -y robrain

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

The AI Assistant docs only show command and args. If the env block is ignored, use Junie for this server.

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "robrain": {
      "command": "npx",
      "args": [
        "-y",
        "robrain"
      ],
      "env": {
        "PERCEPTION_API_KEY": "<PERCEPTION_API_KEY>"
      }
    }
  }
}
```

## FAQ

### What do I need to self-host?

Docker for the stack plus Anthropic and OpenAI keys by default; other providers are supported.

### Which editors work?

Claude Code, Cursor, GitHub Copilot in VS Code, Codex CLI and Hermes.

### Is the cloud option free?

It is included with paid Rory Plans plans; self-hosting is free.

### Does data leave my machine?

The README says self-hosted RoBrain keeps everything on your machine.

### How do I add Robrain to Claude Code?

Run this command in your terminal: claude mcp add robrain --env PERCEPTION_API_KEY='<PERCEPTION_API_KEY>' -- npx -y robrain

### What are the best alternatives to Robrain?

The closest alternatives to Robrain are REA, Context7, Chrome DevTools MCP, Codebase Memory and GitHub.

## Where this comes from

- Description: written from the project's README.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Context7](https://ai-powered.com/mcp/context7): Context7 is a freemium MCP server for developer tools.
- [Chrome DevTools MCP](https://ai-powered.com/mcp/chrome-devtools-mcp-2): Chrome DevTools MCP is an open-source MCP server for browser automation.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/robrain
