The recall hook can only inject what it finds. On a miss it returned silently, and silence reads to the model as "there is nothing to search" — so it never reached for the tool, and history living in another container stayed invisible for the whole session. The guidance that would have fixed this already existed, but only inside formatRecall(), which runs when recall already found something. It was delivered in the case where it was least needed and withheld in the case where it mattered most. Emit a discovery block on the first genuinely-empty recall of a session: name the tool, point at ToolSearch to resolve it (the tool ships under three names depending on install shape, and deferred loading means the model holds a bare name with no schema), interpolate the repo containerTag, and note that read-only calls are auto-approved. Gated to fire once per session, and only when the container is truly empty rather than all-repeats — misses are the common case in an empty project, so repeating it would tax every prompt and invite searches on turns where memory is irrelevant. The marker is a file in the session dir next to recalled.json; writeState would have meant widening the EVENT_NAMES allowlist and touching the statusline renderer. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011qEtmi9chBJMgirVCTpSLu
Claude-Supermemory
A Claude Code plugin that gives your AI persistent memory across sessions using Supermemory. Your agent remembers what you worked on - across sessions, across projects.
Features
- Team Memory — Project knowledge shared across your team, separate from personal memories
- Auto Capture — Conversations saved when session ends
- Project Config — Per-repo settings, API keys, and container tags
Installation
Requires Node.js 18+ on your PATH — the memory hooks run as Node scripts.
/plugin marketplace add supermemoryai/claude-supermemory
/plugin install supermemory
Already have the old
claude-supermemoryplugin installed? It was renamed tosupermemory, so it won't update in place. Migrate with:/plugin marketplace update supermemory-plugins /plugin install supermemory@supermemory-pluginsThen, only if you still have the old plugin, remove it:
/plugin uninstall claude-supermemory@supermemory-plugins
Set your API key (get one at console.supermemory.ai):
export SUPERMEMORY_CC_API_KEY="sm_..."
How It Works
- Reasoned recall — Before each turn, Claude decides whether recalling memory would actually help your current message, and only searches when it's worth it — every turn, once in a while, or not at all. The search runs automatically (no permission prompt), just like auto-capture. Searching only when needed also keeps more usage on your plan
- supermemory-search — Ask about past work or previous sessions, Claude searches your memories
- supermemory-save — Ask to save something important, Claude saves it for the team
Shared Agents memory
Claude Code, Codex, and OpenCode use one container for a repository:
repo_<project-name>__<remote-hash>stores automatic capture and every explicit save.sm_scopemetadata keeps personal and project memories filterable inside that container.
The hash is derived from the normalized Git remote, so clones share memory while
same-named repositories do not collide. Repositories without a remote fall back to
a local path identity. The agent plugins also read the previous user_project_*,
repo_<project-name>, claudecode_project_*, codex_user_*,
codex_project_*, opencode_user_*, and opencode_project_* containers, so
existing memories remain searchable without a migration. Set
SUPERMEMORY_ISOLATE_WORKTREES=true to use the worktree path instead of the
remote identity.
Explicit repoContainerTag/projectContainerTag overrides remain the canonical
write destination. Older personal/user overrides remain in the legacy read set.
Commands
| Command | Description |
|---|---|
/supermemory:index |
Index codebase architecture and patterns |
/supermemory:project-config |
Configure project-level settings |
/supermemory:logout |
Clear saved credentials |
/supermemory:session |
Show clickable URL for the current session document in Supermemory |
/supermemory:status |
Show authentication status |
Configuration
Environment
SUPERMEMORY_CC_API_KEY=sm_... # Required
SUPERMEMORY_DEBUG=true # Optional: enable debug logging
Global Settings — ~/.supermemory-claude/settings.json
{
"maxProfileItems": 5,
"signalExtraction": true,
"signalKeywords": ["remember", "architecture", "decision", "bug", "fix"],
"signalTurnsBefore": 3,
"includeTools": ["Edit", "Write"]
}
| Option | Description |
|---|---|
maxProfileItems |
Max memories in context (default: 5) |
recallDirective |
Override the built-in reasoned-recall instruction Claude is given |
signalExtraction |
Only capture important turns (default: false) |
signalKeywords |
Keywords that trigger capture |
signalTurnsBefore |
Context turns before signal (default: 3) |
includeTools |
Tools to explicitly capture |
Project Config — .claude/.supermemory-claude/config.json
Per-repo overrides. Run /supermemory:project-config or create manually:
{
"apiKey": "sm_...",
"baseUrl": "https://api.supermemory.ai",
"repoContainerTag": "my-team-project",
"signalExtraction": true
}
| Option | Description |
|---|---|
apiKey |
Project-specific API key |
baseUrl |
Supermemory API URL |
personalContainerTag |
Legacy personal container retained for reads |
repoContainerTag |
Override unified project container tag |
Privacy
For information about how Supermemory collects, uses, and retains data, see the Supermemory Privacy Policy.
License
MIT