Claude Code plugin

OAK.memory gives Claude Code a memory that outlives every session.

A persistent vector + graph long-term memory, backed by Postgres + pgvector and a local embedding model. Recall and store facts about you across every project and every session — running entirely on your own machine.

Two lines to add it — then one setup step below stands up the database. Free under the PolyForm Shield license.

Before you start

Three things, installed once

Installing the plugin copies files — it does not provision anything on its own. You stand up the database and embedding model a single time, and the memory is live in every project after that.

Node.js 18+

Runs the plugin's MCP server and the setup script.

Docker

Hosts the Postgres + pgvector container that stores your memory graph.

Ollama

Serves the local embedding model — nothing leaves your machine.

Install

From zero to remembering

  1. 01

    Add the marketplace & install the plugin

    Run these inside Claude Code. This repo is its own marketplace, so there is nothing else to register.

  2. 02

    Run the one-time setup

    From the plugin directory. It is idempotent: it starts Postgres, pulls the embedding model, and writes MEMORY_DATABASE_URL into ~/.claude/oak-memory.env.

  3. 03

    That's it — memory is live everywhere

    Claude now recalls before it answers and stores durable facts on its own. Confirm the server is wired up with /memory-recall or open the graph with /memory-graph-web.

Not zero-install, by design. The memory lives in a real Postgres database so concurrent Claude sessions never corrupt your graph. Setup keeps it effortless — the container restarts on boot and your memories survive reboots and docker rm.

What you get

Tools Claude calls, commands you run

recallMemory

Vector search + graph traversal to pull back what's relevant.

createMemory · updateMemory

Store or revise a durable fact; dedupes against neighbours.

openMemoryGraph

Open the whole memory graph as an interactive webpage.

suggestMemoryLinks

Propose edges between related memories, tune their strength.

Slash commands
/memory-recallRecall memories relevant to a query.
/memory-saveExplicitly save a fact to long-term memory.
/memory-graphShow all memories and how they link, in the terminal.
/memory-graph-webOpen the memory graph as an interactive webpage.
/memory-organiseCluster orphans, merge duplicates, tune edge strengths.
/memory-configChange what's remembered, when it saves, how hard it searches.
How it works

Vector similarity finds the door. Graph traversal walks the house.

Every fact is embedded and stored as a node. On recall, vector search finds the entry points, then the graph pulls in everything associated — so Claude gets the whole cluster of context, not just the single line that matched. Personalization without fine-tuning.

Claude CodeMCP server@openaikits/memoryPostgres · pgvector

Read the full reference

Configuration, hosted-Postgres setup, the memory policy, and troubleshooting all live in the repository README.

View on GitHub