claude-mem preserves AI agent context across sessions by automatically capturing tool usage, generating semantic summaries, and injecting relevant context into future sessions. It is installed via a single npx command and integrates with Claude Code, with an optional cloud sync feature.
Project overview
Addresses the problem of session-scoped context loss in AI coding agents by compressing captured session data into semantic summaries and automatically injecting that context back into subsequent sessions.
Project type
MCP · AI Agent
Use cases
Coding & Development · Automation
Deployment
Refer to project documentation
License
Apache-2.0
Best for
Developers seeking to maintain automated context continuity across isolated AI agent sessions.
Key capabilities
Compresses and generates semantic summaries from captured session data.
Makes relevant past summaries available and injects them into future sessions.
Limitations and risks
Cloud sync to cmem.ai is available as an optional external service, which permits external access to data; the documented data boundary is external_optional.
Getting started
Run 'npx claude-mem install' and restart Claude Code. Installation difficulty is rated as easy and does not require coding.
Evidence and sources
README: Claude-Mem seamlessly preserves context across sessions by automatically capturing tool usage observations, generating semantic summaries, and making them available to future sess…
README: Persistent memory compression system built for <a href="https://claude.com/claude-code" target="_blank">Claude Code</a>.
README: Stable releases ship from `main` and are published to npm.
README: Mentioned in Awesome Claude Code
README: Persistent Memory** - Context survives across sessions