Codeuteronomy

Software

II

Rules and hooks

Corrections graduate into rules files and hooks the machine cannot ignore.

Requires The Harness I

The fourth law says a repeated instruction is a missing rule; Claude Code gives the rule three places to live, in ascending strength. CLAUDE.md and rules files are read every session: house law, written once. Path-scoped rules load only in their territory, so the machine's context carries what applies and nothing else. And hooks are rules with teeth: code that runs on every action and blocks the forbidden ones outright, whatever the model thinks.

Choose the strength to match the failure. A style preference is a rules line. A workflow convention is a rules file with the incident that earned it. A thing that must never happen, an unauthorized commit, a secret in a command, gets a hook, because the difference between discouraged and impossible is the whole point of the fourth law's graduation.

How to practice it

Deep scripture: Codeuteronomy V — A repeated instruction is a missing constraint