# prism-coder

An MCP server that gives coding agents memory across restarts and routes part of the work to local models. Useful when a project runs for weeks.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed · ★ 156
- Author: dcostenco
- License: Apache-2.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/dcostenco/prism-coder
- Updated: 2026-10-24
- HTML: https://affpapa.org/en/nevibecode/mcp/prism-coder

## What it does

prism-coder keeps project state between sessions: handoff notes, recent work, open TODOs. Context comes in three depths — quick, standard or deep. Memory search applies ACT-R ranking on its own, weighing relevance against recency, frequency and associations, so you do not have to upvote anything.

Local inference runs through Ollama, picking a 2B, 4B, 9B or 27B model from what is installed based on available RAM and subscription entitlements. On Apple Silicon you can install oMLX and its model pack from `prism dashboard` under Settings → Local Coding. That route needs Prism's own oMLX integration and a separate classifier; stock oMLX is not enough. An explicit oMLX choice never falls back to Ollama or the cloud.

Setup starts with `npm install -g prism-mcp-server`, then `prism connect` writes the server into Claude, Claude Desktop, Cursor, Gemini CLI and Codex while leaving unrelated settings alone. No account or API keys are required — everything runs on your machine. `prism savings` reports how many tokens local serving kept off your cloud model, in tokens rather than invented dollar figures, with its assumptions printed inline. Lifecycle hooks are not needed to start, though on hosts that support them `prism connect` adds two.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `BRAVE_API_KEY`, `GEMINI_API_KEY`, `SUPABASE_URL`, `SUPABASE_KEY`, `PRISM_USER_ID`, `GCP_PROJECT_ID`, `VERTEX_LOCATION`, `VERTEX_DATA_STORE_ID` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env BRAVE_API_KEY=<BRAVE_API_KEY> --env GEMINI_API_KEY=<GEMINI_API_KEY> --env SUPABASE_URL=<SUPABASE_URL> --env SUPABASE_KEY=<SUPABASE_KEY> --env PRISM_USER_ID=<PRISM_USER_ID> --transport stdio prism-coder -- npx -y prism-mcp-server
```
Replace <…> with your own values. 3 more environment variables are in the server README

### Codex

**Platform CLI**
```bash
codex mcp add prism-coder --env BRAVE_API_KEY=<BRAVE_API_KEY> --env GEMINI_API_KEY=<GEMINI_API_KEY> --env SUPABASE_URL=<SUPABASE_URL> --env SUPABASE_KEY=<SUPABASE_KEY> --env PRISM_USER_ID=<PRISM_USER_ID> -- npx -y prism-mcp-server
```
Replace <…> with your own values. 3 more environment variables are in the server README

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "prism-coder": {
            "command": "npx",
            "args": [
                "-y",
                "prism-mcp-server"
            ],
            "env": {
                "BRAVE_API_KEY": "<BRAVE_API_KEY>",
                "GEMINI_API_KEY": "<GEMINI_API_KEY>",
                "SUPABASE_URL": "<SUPABASE_URL>",
                "SUPABASE_KEY": "<SUPABASE_KEY>",
                "PRISM_USER_ID": "<PRISM_USER_ID>"
            }
        }
    }
}
```
Replace <…> with your own values. 3 more environment variables are in the server README

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "prism-coder": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "prism-mcp-server"
            ],
            "env": {
                "BRAVE_API_KEY": "<BRAVE_API_KEY>",
                "GEMINI_API_KEY": "<GEMINI_API_KEY>",
                "SUPABASE_URL": "<SUPABASE_URL>",
                "SUPABASE_KEY": "<SUPABASE_KEY>",
                "PRISM_USER_ID": "<PRISM_USER_ID>"
            }
        }
    }
}
```
Replace <…> with your own values. 3 more environment variables are in the server README

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e BRAVE_API_KEY=<BRAVE_API_KEY> -e GEMINI_API_KEY=<GEMINI_API_KEY> -e SUPABASE_URL=<SUPABASE_URL> -e SUPABASE_KEY=<SUPABASE_KEY> -e PRISM_USER_ID=<PRISM_USER_ID> prism-coder npx -y prism-mcp-server
```
Replace <…> with your own values. 3 more environment variables are in the server README

## When to use it
- resume a project after the agent restarts
- move part of the inference to local models and count the tokens saved
- configure one MCP server for several hosts at once
- see which local models are installed and fit available RAM
- keep route output limited to tools the host actually advertised

## Example prompts
- Show the project state and open TODOs from Prism memory
- How many tokens went to local serving this month? Run `prism savings --period month`
- Load context from the last sessions at standard depth

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119160
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47392
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43872

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
