# open-primeagent

> open-primeagent is an open-source MCP server for developer tools. MCP server that writes what one coding agent learns into AGENTS.md for other agents. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Self-hosted
- **Repository:** https://github.com/softkleenex/open-primeagent
- **MCP Registry name:** io.github.softkleenex/open-primeagent
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-27

## About

Coding agents keep what they learn about a repository in their own private storage, so a teammate using a different agent starts from zero. This MCP server records those findings into a marked block inside the repo's AGENTS.md and CLAUDE.md files, so the knowledge is committed with the code and read by Claude Code, Codex and opencode.

The server runs over stdio and is added to whichever agent you use. Beyond the file projection it provides a persistent Python kernel that keeps variables between calls, and it can spawn and resume child agents running through your local claude or codex CLI. Only four MCP tools are exposed; the rest lives inside the kernel.

It suits developers who switch between coding agents on the same repository and want shared, version-controlled notes. The projection leaves everything outside its block untouched and can be removed cleanly. Because the kernel and child agents run with your OS permissions, the README advises running untrusted repositories inside a container or VM.

## Features

- **Shared repo knowledge:** Writes learned rules into a delimited block in AGENTS.md and CLAUDE.md so other agents read them.
- **Clean removal:** A single bootstrap call strips the managed block and restores the file contents outside it.
- **Persistent Python kernel:** Keeps Python variables alive between calls, with truncated output and saved full text.
- **Cross-agent sub-agents:** Spawns and resumes child agents through the local Claude Code or Codex CLI.
- **Four-tool surface:** Exposes only four MCP tools, with other capabilities available as kernel symbols.

## Good for

- Hand a repository's hidden build or test rules from one coding agent to another
- Keep a Codex sub-agent running and send it follow-up tasks from Claude Code
- Store intermediate Python results across multiple agent turns without filling the context window
- Install a shared project memory file that teammates pick up through version control

## Install

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

```sh
claude mcp add open-primeagent -- uvx open-primeagent
```

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": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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 open-primeagent -- uvx open-primeagent
```

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

```toml
[mcp_servers.open-primeagent]
command = "uvx"
args = ["open-primeagent"]
```

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user open-primeagent uvx -- open-primeagent

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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

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

```json
{
  "mcpServers": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

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": {
    "open-primeagent": {
      "command": "uvx",
      "args": [
        "open-primeagent"
      ]
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 1 of 4 tools reads data; 3 names don't say. From the server's own tool labels and tool names; not verified by us.

- `opa_python`: Runs Python in a persistent kernel.
- `opa_status` (name suggests: reads): Reports server status.
- `opa_kernel`: Manages the Python kernel.
- `opa_bootstrap`: Projects or removes the harness block in project files.

## FAQ

### How do I install open-primeagent in Claude Code?

Run claude mcp add opa -- uvx open-primeagent, or install it as a plugin from the softkleenex/open-primeagent marketplace.

### Which agents can read the projected files?

The README says the projected AGENTS.md is read by Claude Code, Codex and opencode.

### Can the projected block be removed?

Yes, calling opa_bootstrap with remove set to true removes the block and restores the file exactly.

### What license does open-primeagent use?

It is licensed under Apache-2.0.

### Is open-primeagent free?

Yes. open-primeagent is open source, so you can use and self-host it for free.

### How do I add open-primeagent to Claude Code?

Run this command in your terminal: claude mcp add open-primeagent -- uvx open-primeagent

### What are the best alternatives to open-primeagent?

The closest alternatives to open-primeagent are MCPProxy, Agent MCP Hub, codemem, AGENTS.md Generator and Chorus.

## Where this comes from

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

## Alternatives

- [MCPProxy](https://ai-powered.com/mcp/mcpproxy): MCPProxy is an open-source MCP server for developer tools.
- [Agent MCP Hub](https://ai-powered.com/mcp/agent-mcp-hub): Agent MCP Hub is an open-source MCP server for developer tools.
- [codemem](https://ai-powered.com/mcp/codemem): codemem is an open-source MCP server for developer tools.
- [AGENTS.md Generator](https://ai-powered.com/mcp/agents-md-generator): AGENTS.md Generator is an open-source MCP server for developer tools.
- [Chorus](https://ai-powered.com/mcp/chorus-3): Chorus is an open-source MCP server for developer tools.
- [Sub Agents MCP](https://ai-powered.com/mcp/sub-agents-mcp): Sub Agents MCP is an open-source MCP server for developer tools.
- [Brigade Memory](https://ai-powered.com/mcp/brigade-memory): Brigade Memory is an open-source MCP server for knowledge and memory.
- [agentchan](https://ai-powered.com/mcp/agentchan): agentchan is an open-source MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/open-primeagent
