Project Brain

v2.0.3
io.github.Gentleelephant/project-brain Checked 2 days ago Published 3 months ago

Read-only source search and retrieval across configured GitHub repositories

Values you need

VariableWhat it is
PROJECT_BRAIN_REPO_LISTrequired Comma-separated owner/repo slugs or a path to a file with one slug per line
PROJECT_BRAIN_STATE_DIRrequired Writable directory for repository caches, indexes, and locks
PB_GITHUB_TOKENoptional secret Optional GitHub token for private repositories
PB_FETCH_TTLoptional Minimum interval between on-demand repository refreshes

Docker discovery passed

Requires Docker

Run in a terminal
claude mcp add project-brain -e 'PROJECT_BRAIN_REPO_LIST=<PROJECT_BRAIN_REPO_LIST>' -e 'PROJECT_BRAIN_STATE_DIR=<PROJECT_BRAIN_STATE_DIR>' -- docker run -i --rm -e PROJECT_BRAIN_REPO_LIST -e PROJECT_BRAIN_STATE_DIR ghcr.io/gentleelephant/project-brain:v2.0.3
Add to claude_desktop_config.json
{
  "mcpServers": {
    "project-brain": {
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "PROJECT_BRAIN_REPO_LIST",
        "-e",
        "PROJECT_BRAIN_STATE_DIR",
        "ghcr.io/gentleelephant/project-brain:v2.0.3"
      ],
      "command": "docker",
      "env": {
        "PROJECT_BRAIN_REPO_LIST": "<PROJECT_BRAIN_REPO_LIST>",
        "PROJECT_BRAIN_STATE_DIR": "<PROJECT_BRAIN_STATE_DIR>"
      }
    }
  }
}
Add to ~/.cursor/mcp.json
{
  "mcpServers": {
    "project-brain": {
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "PROJECT_BRAIN_REPO_LIST",
        "-e",
        "PROJECT_BRAIN_STATE_DIR",
        "ghcr.io/gentleelephant/project-brain:v2.0.3"
      ],
      "command": "docker",
      "env": {
        "PROJECT_BRAIN_REPO_LIST": "<PROJECT_BRAIN_REPO_LIST>",
        "PROJECT_BRAIN_STATE_DIR": "<PROJECT_BRAIN_STATE_DIR>"
      }
    }
  }
}
Add to .vscode/mcp.json
{
  "inputs": [
    {
      "description": "PROJECT_BRAIN_REPO_LIST",
      "id": "project-brain-repo-list",
      "password": true,
      "type": "promptString"
    },
    {
      "description": "PROJECT_BRAIN_STATE_DIR",
      "id": "project-brain-state-dir",
      "password": true,
      "type": "promptString"
    }
  ],
  "servers": {
    "project-brain": {
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "PROJECT_BRAIN_REPO_LIST",
        "-e",
        "PROJECT_BRAIN_STATE_DIR",
        "ghcr.io/gentleelephant/project-brain:v2.0.3"
      ],
      "command": "docker",
      "env": {
        "PROJECT_BRAIN_REPO_LIST": "${input:project-brain-repo-list}",
        "PROJECT_BRAIN_STATE_DIR": "${input:project-brain-state-dir}"
      },
      "type": "stdio"
    }
  }
}
Add to ~/.codex/config.toml
[mcp_servers.project-brain]
command = "docker"
args = ["run", "-i", "--rm", "-e", "PROJECT_BRAIN_REPO_LIST", "-e", "PROJECT_BRAIN_STATE_DIR", "ghcr.io/gentleelephant/project-brain:v2.0.3"]
env = { "PROJECT_BRAIN_REPO_LIST" = "<PROJECT_BRAIN_REPO_LIST>", "PROJECT_BRAIN_STATE_DIR" = "<PROJECT_BRAIN_STATE_DIR>" }

For AI agents

  1. Ask the user for: PROJECT_BRAIN_REPO_LIST, PROJECT_BRAIN_STATE_DIR. Never invent or guess these values; secrets go into the client config, not into chat logs.
  2. Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
  3. Restart or reload the client so it starts the server.
  4. Verify: the server should expose these tools: project_code_files, project_code_read, project_code_search, project_repo_list, project_repo_sync, project_symbol_search.
  5. If it fails, check that the required runtime is installed (Docker) and that the values above are set.

Machine-readable: install.md · manifest.json