Run the example
From a Claude-Mem source checkout with Bun and npm dependencies installed:CLAUDE_MEM_EXAMPLE_MODEL to choose another supported model. Explicit saves do not require the background observer to run.
The selected project is fixed by the command. The permission callback rejects alternate project names and server-project IDs, adds the selected project to ID-based reads, and authorizes only save, search, timeline and observation retrieval. It does not authorize raw tool-history reads, shell commands or file edits. Settings files and other MCP servers are not loaded.
This is explicit memory access, not automatic capture. It changes no IDE configuration and stores no SDK session transcript. The saved memory remains until you delete it through Claude-Mem. Disconnect by stopping the example and removing its MCP configuration from your own application.
Verification and failures
Verified with@anthropic-ai/claude-agent-sdk 0.3.322 on macOS. A repeatable test runs the actual SDK and rebuilt MCP server against a local fake model, without an account or paid calls:

