# AgentWorkingMemory MCP server

> Provides persistent, local-first memory for AI agents using SQLite and ONNX to enable selective recall and project-wide learning without cloud dependencies.

- Repository: https://github.com/CompleteIdeas/agent-working-memory
- Page: https://hostedmcp.org/servers/completeideas/agent-working-memory
- Transport: stdio
- Stars: 4
- License: Apache-2.0

## Install

### Claude Code

```sh
claude mcp add agent-working-memory -- npx -y agent-working-memory
```

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

```json
{
  "mcpServers": {
    "agent-working-memory": {
      "command": "npx",
      "args": [
        "-y",
        "agent-working-memory"
      ]
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "agent-working-memory": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "agent-working-memory"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"agent-working-memory","type":"stdio","command":"npx","args":["-y","agent-working-memory"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "agent-working-memory": {
      "command": "npx",
      "args": [
        "-y",
        "agent-working-memory"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add agent-working-memory -- npx -y agent-working-memory
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.agent-working-memory]
command = "npx"
args = ["-y", "agent-working-memory"]
```

### Gemini CLI

```sh
gemini mcp add -s user agent-working-memory npx -- -y agent-working-memory
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "agent-working-memory": {
      "command": "npx",
      "args": [
        "-y",
        "agent-working-memory"
      ]
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `AWM_RERANK2` | no | no |  |

## FAQ

### How can I teach the agent about an entire project quickly?

You can use the `/awm-learn` command to read an entire repository, manuscript, or documentation folder into memory.

### How does it handle sensitive information like credentials?

Credentials are masked before being stored, and an optional vault feature can keep them sealed and usable within commands without exposing them.

### What happens when a fact is corrected?

A corrected fact replaces the old one instead of competing with it, ensuring recall serves the most current version.
