Hooks11
Hooks
Shared policy checks composed by runtime lifecycle adapters. Native activation and enforcement are qualified separately.
session SessionStart SessionStart hook: report harness drift, per-session HARNESS_* overrides, and the handoff, and check declared framework integrations without modifying repository… brief-guard PreToolUse PreToolUse on `Agent`: append a return bound, and the posture's soft budget, to a brief that states neither. filter-output PreToolUse PreToolUse hook: pipe verbose test, build and type-check runs through `filter-lines.py`, so only failures, the summary and the tail of a run enter the transcript. grade-bash PreToolUse PreToolUse hook: grade every Bash command 0-3 and gate the grades the autonomy stance forbids. plan-webfetch PreToolUse PreToolUse hook: approve WebFetch while in plan mode, so gathering context for a plan does not prompt for every documentation or reference URL. readonly-bash PreToolUse PreToolUse hook: approve read-only Bash commands that Claude Code's built-in read-only set misses, so plan mode and Manual mode stop prompting for them. tier-spawns PreToolUse PreToolUse hook: apply the delegation stance to every subagent spawn, whoever wrote the brief. neutralize PostToolUse PostToolUse scanner: flag instruction-shaped text arriving in tool output. plan-card PostToolUse PostToolUse validator: enforce the Review Card contract on plan files. stop-gate Stop Stop hook: run the repository's own gate and refuse to finish while it is red. usage-log SessionEnd SessionEnd hook: record a session's token usage in ~/.local/state/agent-harness/usage.jsonl.