Hooks are extension points around the main loop. They let readers add behavior without rewriting the loop itself. # TOOL_HOOK_EXECUTION_TIMEOUT_MS = 600000 (10 minutes for tool hooks) # ...