# Graphmem

Shared local memory for coding agents using SQLite and semantic retrieval. Keeps project conventions and context across sessions.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 8
- Author: sonic182
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/sonic182/graphmem
- Updated: 2026-10-22
- HTML: https://affpapa.org/en/nevibecode/mcp/graphmem

## What it does

Graphmem preserves project context across agent sessions. Data stays locally in SQLite at `~/.graphmem`. Records bind to the active Git repository or a global scope, while reading covers both zones.

The binary bundles code navigation tools that work without embeddings: symbol lookup and diffing across Git revisions. Setting `GRAPHMEM_CODE=off` disables this code analysis entirely.

Linux release binaries require glibc 2.39 and OpenSSL 3. Without `git` on your `PATH`, the server fails to detect repository boundaries and defaults writes to the global scope.

## Requirements
- Needs: Node.js (commands run via npx)

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add graphmem -- npx -y @sonic182/graphmem
```

### Codex

**Platform CLI**
```bash
codex mcp add graphmem -- npx -y @sonic182/graphmem
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "graphmem": {
            "command": "npx",
            "args": [
                "-y",
                "@sonic182/graphmem"
            ]
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "graphmem": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@sonic182/graphmem"
            ]
        }
    }
}
```

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add graphmem npx -y @sonic182/graphmem
```

## When to use it
- persist project architectural decisions across agent sessions
- share conventions between different coding tools through a single SQLite file
- locate symbol definitions and source ranges across the repository
- inspect symbol changes between Git branches or revisions

## Example prompts
- Remember that integration tests must run with nextest under convention type
- Search memory for our database migration guidelines
- Inspect the structure of `src/application/code.rs` using code_outline

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 392262
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33989
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81163
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119231
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47577
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43902

---
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
