Files
ECC/hooks/hooks.metadata.json
T

157 lines
5.8 KiB
JSON

{
"$schema": "../schemas/hooks-metadata.schema.json",
"entries": {
"PreToolUse": [
{
"id": "pre:bash:dispatcher",
"description": "Consolidated Bash preflight dispatcher for quality, tmux, push, and GateGuard checks",
"fingerprint": "b6368cea225b"
},
{
"id": "pre:powershell:gateguard-fact-force",
"description": "PowerShell fact-forcing gate: inspect destructive commands without running unrelated Bash-only preflight hooks",
"fingerprint": "8c6999f6e983"
},
{
"id": "pre:write:doc-file-warning",
"description": "Doc file warning: warn about non-standard documentation files (exit code 0; warns only)",
"fingerprint": "194dbda0da31"
},
{
"id": "pre:edit-write:suggest-compact",
"description": "Suggest manual compaction at logical intervals",
"fingerprint": "d80a2230f694"
},
{
"id": "pre:observe:continuous-learning",
"description": "Capture tool use observations for continuous learning",
"fingerprint": "b150973de09e"
},
{
"id": "pre:governance-capture",
"description": "Capture governance events (secrets, policy violations, approval requests). Enable with ECC_GOVERNANCE_CAPTURE=1",
"fingerprint": "27b2fb3d8225"
},
{
"id": "pre:config-protection",
"description": "Block modifications to linter/formatter config files. Steers agent to fix code instead of weakening configs.",
"fingerprint": "6108a8493a01"
},
{
"id": "pre:mcp-health-check",
"description": "Check MCP server health before MCP tool execution and block unhealthy MCP calls",
"fingerprint": "8076a659fbb3"
},
{
"id": "pre:edit-write:gateguard-fact-force",
"description": "Fact-forcing gate: deny the first Edit/Write/MultiEdit/NotebookEdit of each file with questions chosen by target class and by what the change touches; a completed search naming the file in the current turn, a comment or whitespace-only edit, or a same-turn sibling of a new file already gated passes with a note instead; sensitive targets (secrets, keys, auth/payment code, migrations, CI workflows) and hard-linked files are always gated, also in subagents",
"fingerprint": "03ca6dfa522d"
},
{
"id": "pre:hookify-runtime",
"description": "Evaluate project-local Hookify rules before Bash, PowerShell, and file tools run",
"fingerprint": "0df5946ac5b0"
}
],
"UserPromptSubmit": [
{
"id": "prompt:hookify-runtime",
"description": "Evaluate project-local Hookify prompt rules before a user prompt is processed",
"fingerprint": "1059420a1d36"
}
],
"PreCompact": [
{
"id": "pre:compact",
"description": "Save state before context compaction",
"fingerprint": "a1568796f30f"
}
],
"SessionStart": [
{
"id": "session:start",
"description": "Load previous context and detect package manager on new session",
"fingerprint": "249fc73365e2"
},
{
"id": "session-start:plan-canvas-sessions",
"description": "Surface open Plan Canvas review sessions so a fresh session can resume the loop",
"fingerprint": "c3260e680244"
}
],
"PostToolUse": [
{
"id": "post:dispatcher:sync",
"description": "Run synchronous PostToolUse hooks in one process while preserving per-hook controls",
"fingerprint": "422d1277aa36"
},
{
"id": "post:dispatcher:async",
"description": "Run background PostToolUse hooks in one process while preserving per-hook controls",
"fingerprint": "8dab5597fa2f"
}
],
"PostToolUseFailure": [
{
"id": "post:mcp-health-check",
"description": "Track failed MCP tool calls, mark unhealthy servers, and attempt reconnect",
"fingerprint": "40f16b9d09f6"
},
{
"id": "post:skill:track",
"description": "Record hard Skill tool failures for skill-health telemetry",
"fingerprint": "878ad575ec45"
}
],
"Stop": [
{
"id": "stop:hookify-runtime",
"description": "Evaluate project-local Hookify completion rules before Claude stops",
"fingerprint": "50e9403aa352"
},
{
"id": "stop:plan-canvas-pending",
"description": "Deliver undelivered Plan Canvas browser feedback before the agent stops",
"fingerprint": "7097ba3f3df2"
},
{
"id": "stop:format-typecheck",
"description": "Batch format (Biome/Prettier) and typecheck (tsc) all JS/TS files edited this response — runs once at Stop instead of after every Edit",
"fingerprint": "67b09035d412"
},
{
"id": "stop:check-console-log",
"description": "Check for console.log in modified files after each response",
"fingerprint": "8de9989439b8"
},
{
"id": "stop:session-end",
"description": "Persist session state after each response (Stop carries transcript_path)",
"fingerprint": "234505b5cc35"
},
{
"id": "stop:evaluate-session",
"description": "Evaluate session for extractable patterns",
"fingerprint": "6ffe19bc00d5"
},
{
"id": "stop:cost-tracker",
"description": "Track token and cost metrics per session",
"fingerprint": "fc6f95300201"
},
{
"id": "stop:desktop-notify",
"description": "Send desktop notification (macOS/WSL) with task summary when Claude responds",
"fingerprint": "5dc860898f78"
}
],
"SessionEnd": [
{
"id": "session:end:marker",
"description": "Session end lifecycle marker (non-blocking)",
"fingerprint": "d4070a31d501"
}
]
}
}