All shelves / Mods / Workflow
better-memory
By xobotyi
better-memory is a Claude Code workflow mod by xobotyi.
Refuses the agent's writes to the memory folder except through its own save tool, which needs an anchor from the session, and clears stale entries when idle.
Holds a command
Install
The marketplace name is foundry.
/plugin install better-memory --marketplace xobotyi/cc-foundryIt runs inside the Claude Code process. The side panel is only what the author's README names. Read the repo before you install, or run claude plugin validate on the plugin folder.
- Version
- 0.0.1
- License
- MIT
- Repo stars
- 23
- Last change
- 2026-11-07
What it can reach
- Holds a command
- Sees tool calls
- Reaches the network or an outside service
- Calls another program on this machine
Claude Code 2.1.319 or newer. Two settings, both on by default: Guard auto memory and Sift when idle; change them in /config or with /plugin configure. Sift runs the claude command, so it needs claude on the PATH of your session, and it costs an Opus run per batch of up to twelve entries. A headless claude -p run never sifts; its entries are judged in your next interactive session in the project. A removed entry is deleted, and its report in ~/.claude/projects/<project>/better-memory/ is the only copy of its text, kept as long as Claude Code keeps transcripts. /better-memory:sift runs the same pass by hand, with you in the loop.
The marketplace, foundry, also holds more than twenty other plugins, the-statusline and wall-clock among them. Keeping auto memory to facts that still hold is why this page files it under workflow. memory-fork draws what the memory fork changed above the prompt, and refuses the session's writes into the memory folder. dream-pass tidies Claude's memory folder, merging duplicates and dropping dead entries, and shows the counts in a band with a pane, a backup, and undo. This one shows nothing in normal operation. The agent saves and removes memory only through two tools the plugin adds, and the plugin refuses any other write to the memory directory. The save tool takes each entry with its anchors, your exact words, a file the session read, a page it fetched, or a command it ran, and the plugin confirms each anchor is in the session. Guidance on how to work saved as feedback is refused, and the agent is told to offer you a CLAUDE.md edit instead. When an interactive session goes idle, a separate Claude process called sift judges up to twelve entries and promotes a fact, offers you an instruction as a CLAUDE.md line, or removes the entry. The plugin writes MEMORY.md itself.
Demo

What it hooks into
session.startWhen a session startstool.describeA Claude Code eventWriteEdittool.callAround a tool call, where it can hold onetool.checkA Claude Code eventBashturn.startWhen Claude starts a turnturn.completeWhen a turn ends
Read from the on() calls in its hook modules. Open its source under Files to check what each one does.
Files
The author's README and source, 4 files. They load when you open them.
Facts
- Author
- xobotyi
- Category
- Workflow
- Marketplace
- foundry
- Folder
- plugins/better-memory
- Version
- 0.0.1
- License
- MIT
- Repo stars
- 23
- Last change
- 2026-11-07
- Language
- TypeScript
- Files
- 10