Overview
The Devin integration gives claude-mem persistent memory to agents running in Devin CLI, which Devin Desktop also uses. It handles four things:- Observation recording — Captures tool usage from Devin’s lifecycle hooks and sends it to the claude-mem worker for AI processing
- Context injection — Injects the observation timeline at session start through the
SessionStarthook’sadditionalContext, the same envelope Claude Code uses, and again after Devin compacts the conversation (PostCompaction) - Session summaries — Summarizes each session from the last assistant message Devin sends on
Stop - MCP search tools — Registers the claude-mem stdio server in
mcp_config.json, somcp__claude-mem__*memory search tools are available inside Devin
Devin reads user-level hooks from the
"hooks" key of ~/.config/devin/config.json (%APPDATA%\devin\config.json on Windows). The installer merges claude-mem’s hook rules into that key and leaves your other Devin settings and hooks alone. It also registers the claude-mem MCP server in ~/.config/devin/mcp_config.json (%APPDATA%\devin\mcp_config.json on Windows), the dedicated file Devin v3000.3+ reads MCP servers from (older versions stored them in config.json’s mcpServers key and migrate on upgrade).Installation
/hooks to confirm the claude-mem hooks loaded, and /mcp or devin mcp list to see the claude-mem server.
Event Mapping
PreToolUse is not registered: Devin’s PreToolUse output can rewrite tool input and approve calls, so claude-mem does not hook it.
Tool names
Devin names its tools in lowercase. The adapter maps the ones with a Claude Code counterpart, so capture, file tracking and theCLAUDE_MEM_SKIP_TOOLS defaults apply to them the same way:
Other tools, including MCP tools (
mcp__<server>__<tool>), are recorded under their Devin names.
Working directory
Devin’s hook payload carries nocwd. The adapter uses DEVIN_PROJECT_DIR, which Devin sets for every hook command, so observations land in the right project.
Claude Code hooks in Devin
Devin also loads hooks from~/.claude/settings.json and .claude/settings.json by default (read_config_from.claude). claude-mem’s Claude Code hooks ship as plugin hooks, not in those files, so Devin does not run them a second time.
