pensieve
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
pensieve
A tiny MCP memory server for coding agents. One instance serves one store: a directory of markdown memories you own, usually a git checkout.
Standing text: at start it reads
<store>/about.mdand sends it to the agent as the server's instructions, so each store says what belongs in it.Tools: Anthropic's memory tool commands (
memory_view,memory_create,memory_str_replace,memory_insert,memory_delete,memory_rename) plusmemory_search, a keyword search.Every path is under
/memories, which means<store>/memory/. Paths that leave it (.., symlinks out, anything else) are refused. The agent cannot reachabout.mdor.git.Nothing is written outside the store. No network, no telemetry, no dependencies beyond the Python standard library (3.11+).
What goes in
What the agent decides on its own to remember for its next session: who you
are, your corrections and feedback on how to work, project context it will
need next time, and pointers to where things live. These are the things
Claude Code's automatic memory saves unprompted, kept in a store you own so
they travel with you across machines. When you tell the agent where to store
something, it does that instead; pensieve is not for user-directed saves or
for notes. Which store a session uses follows its persona (work or personal),
as each store's about.md says; the agent asks once when it is unclear.
Related MCP server: agtmem-mcp
Install
From a pinned commit, either way:
nix profile install github:kusimari/pensieve/<rev>
pipx install git+https://github.com/kusimari/pensieve@<rev>or run python3 pensieve.py --store <dir> from a checkout.
Run two stores side by side
Register one instance per store with Claude Code:
claude mcp add -s user personal-memory -- pensieve --store ~/stores/personal
claude mcp add -s user work-memory -- pensieve --store ~/stores/workThe instances share nothing; each sees only its own store. Turn off Claude
Code's automatic memory ("autoMemoryEnabled": false in settings) so it does
not save to its own memory directory instead. That also drops Claude's own
guidance on when to save; pensieve's standing text carries it.
Store layout
<store>/
about.md what belongs here and what does not, plus a short profile
memory/
MEMORY.md the index, one line per memory
coffee.md one file per memoryMemories use Claude Code's auto-memory format:
---
name: coffee
description: Pour-over grind setting
metadata:
type: user
---
Grind 18 clicks for pour-over.type is one of user, feedback, project, reference. Each memory has
one line in MEMORY.md, such as - [Coffee](coffee.md) - pour-over grind.
The agent keeps the index in step; the tool descriptions tell it to.
about.md
Plain markdown, short. Put what belongs here and what does not first, then a short profile. For example:
Belongs here: my personal life, hobbies, home setup.
Not here: anything about my employer or its projects; those go to the work store.
Profile: I live in Lisbon and drink a lot of coffee.The agent receives a fixed lead of about 700 characters (when to search, what
to save and what not to), then this file. Claude Code cuts server instructions
at 2,048 characters, so keep about.md under about 1,300. With no about.md,
the agent is told the store has no description and to ask before saving.
Test
python3 -m unittest discover -s testsThe tests start the server on temp stores with a temp HOME.
License
MIT, see LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
Hosted MCP memory for coding agents: persistent across sessions, editable markdown, team sharing.
Shared Markdown memory for your agents: docs, typed collections, files, skills and Dispatch.
Shared memory for coding agents. Stop re-explaining your codebase every session.
Portable AI memory shared across models and harnesses - plain markdown you own.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceProvides a local markdown-based memory system for coding agents through MCP, enabling search, add, register, inventory, sync, and ingest operations across user and project memory. It gives any agent tool a durable, provider-agnostic shared memory stored in folders you own.2MIT
- AlicenseAqualityBmaintenanceEnables coding agents to store, search, and retrieve long-term memory as plain Markdown files with a disposable SQLite index, including note management, decision/bug tracking, and codebase symbol lookup via MCP.8MIT
- AlicenseAqualityCmaintenanceGives AI coding agents persistent, searchable typed memory stored as plain markdown files, allowing them to record decisions, contracts, tasks, evaluations, and session logs and update entries by id.5MIT
- AlicenseAqualityCmaintenanceProvides AI coding agents with a local, Markdown-first shared memory, enabling them to record decisions, failures, progress, and handoffs and retrieve them across sessions via MCP tools.8MIT