Mandatory discipline for monitor (probe) hot paths in internal_medicine. Hooks can enqueue CUDA/NCCL work that contends with EP a2a / DDP / TP communication, so they must not D2H-sync (.item/.cpu/.tolist/.numpy/python-compare on tensors), should avoid hook-time collectives unless correctness requires them, and must declare their full metric schema at registration before allocate_buffers. Use when adding or modifying any monitor, touching any _make_*_hook / register_hooks / _compute_* function, reviewing a PR that changes hot-path code or adds a metric, or diagnosing a perf regression that appears after enabling internal_medicine_monitors.
Run before every git commit in llm-internal-medicine. Gates a commit on: (1) the full pre-commit / ruff suite passing, (2) the unit tests passing, and (3) a check of whether README.md needs updating. Use whenever you are about to commit, are asked to commit/stage changes, or are wrapping up a change set and preparing it for review.