klotz: hooks*

0 bookmark(s) - Sort by: Date ↓ / Title / - Bookmarks from other users for this tag

  1. Anurag Singh writes about using a Stop hook in Claude Code to force the agent to review its work against a checklist of previously made mistakes before finishing, solving the problem of the model repeating the same errors across sessions despite CLAUDE.md instructions and prompt-level guidance.

    - The hook is a Bash script that uses jq to read a mistakes.md file and inject a "block" decision, sending Claude back for a second review pass.
    - The script checks the stop_hook_active flag to avoid an infinite review loop.
    - A TaskCompleted event hook is a more token-efficient alternative if you only want review on task completion rather than every response.
    - Hooks execute deterministically on trigger events, unlike textual instructions in CLAUDE.md which Claude may treat as optional.

Top of the page

First / Previous / Next / Last / Page 1 of 0 SemanticScuttle - klotz.me: Tags: hooks

About - Propulsed by SemanticScuttle