Egor Urvanov

Hooks

Harness · hooks

Scripts the harness runs automatically at set moments of the agent’s work: before an action, after a file edit, on finish. An agent treats a rule in the instructions as advice, while a hook always runs, so hooks close the blocks that allow no exceptions.

ruleagenthookalways firesactionbefore an action · after an edit · at the enda rule in instructions is advice✕rm -rf: blocked, no exceptions● model, people, systems, data  ● agent and harness  ● risk, stop, boundaryA rule is advice, a hook always fires

Source: Claude Code hooks reference

Where it appears · 4

Related terms

Whole glossary

© 2026 Egor Urvanov