agentmemory-hooks

Captures agent session observations automatically through Claude Code lifecycle hooks.

3|Updated Oct 25, 2025
One-click install
npx skills add https://github.com/Prismaibrowser/prismspace-web --skill agentmemory-hooks-prismaibrowser
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: agentmemory-hooks
Source: https://github.com/Prismaibrowser/prismspace-web/tree/main/.agents/skills/agentmemory-hooks
Command: npx skills add https://github.com/Prismaibrowser/prismspace-web --skill agentmemory-hooks-prismaibrowser

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Manually saving memory during agent sessions is error-prone and easy to forget, leading to lost context and missing observations. This Skill explains how the agentmemory plugin's lifecycle hooks capture observations automatically across the entire session without manual saves. ## Core Features & Use Cases - Automatic Observation Capture: Hooks registered on 12 lifecycle events (SessionStart, PostToolUse, UserPromptSubmit, PreCompact, and more) record tool use, prompts, and session boundaries with zero LLM cost. - Session Continuity: Session start and end hooks frame each unit of work so the handoff skill can resume it, and a post-commit hook links commits to sessions for commit-context and commit-history. - Debugging Missing Observations: Use it to diagnose why observations are not being recorded by verifying the plugin is enabled and the server is running. - Use Case: After installing the agentmemory plugin, watch observations land live at http://localhost:3113 and tune capture behavior with the AGENTMEMORY_AUTO_COMPRESS and AGENTMEMORY_INJECT_CONTEXT opt-in flags. ## Quick Start Install the agentmemory plugin from the marketplace and confirm that observations appear live at http://localhost:3113 during your next session.

Frequently Asked Questions about agentmemory-hooks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I capture agent session memory automatically in Claude Code?▼

Install the agentmemory plugin, which registers lifecycle hooks on 12 events including SessionStart, PostToolUse, and UserPromptSubmit. These hooks write observations automatically, so you do not need to call memory_save for routine work.

What lifecycle events do agentmemory hooks listen to?▼

The plugin registers hooks on 12 events: Notification, PostToolUse, PostToolUseFailure, PreCompact, PreToolUse, SessionEnd, SessionStart, Stop, SubagentStart, SubagentStop, TaskCompleted, and UserPromptSubmit.

Why are agentmemory observations missing from my session?▼

Missing observations usually mean the plugin is disabled or the agentmemory server is not running. Confirm the plugin is enabled, check the server status, and consult the shared troubleshooting guide referenced by the skill.

Does automatic memory capture consume LLM tokens?▼

Observation capture is zero-LLM by default. Token-spending features like automatic compression (AGENTMEMORY_AUTO_COMPRESS) and context injection (AGENTMEMORY_INJECT_CONTEXT) are separate opt-in flags.

How are git commits linked to agent sessions?▼

A post-commit hook links commits to the active session automatically. This powers the commit-context and commit-history skills, letting you recall why changes were made.