Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Rules Index

The page to open at 11pm. Each rule states a general tool first and names the system it was derived on as its example, and each links back to the derivation that earned it. If you can rebuild the argument from the rule alone, you're done; if not, follow the link.

I. The Method

  • 1 · Ratio triage: sort your next questions by the spread between their possible answers. More than 10× apart: ask it now. Less than 2×: it's a detail.
  • 2 · The floor test: when a measurement beats your theoretical floor, the system is not fast. The work did not happen.
  • 3 · Match the instrument to the ratio: 1000× apart, a wall clock. 20× apart, a wall clock used carefully. 1.5× apart, counters and statistics.

II. Cost Has a Shape

III. The Scarce Thing

  • 7 · Every resource has a ceiling; the lowest one binds: before you call a limit a scheduling problem, compute the budget for every resource and see which runs out first. When a budget is full there are three moves: smaller items, shared items, less held space. Example: the KV cache caps the batch before compute does.
  • 8 · Release a resource when its work ends, not when its group ends: measure occupancy, what you used over what you bought, and schedule at the granularity at which work actually finishes. Example: continuous batching evicts a sequence on the step it ends.
  • 9 · You cannot buy your way out of a waste fraction: when a resource is mostly reserved and barely used, more of it buys the same waste. Allocate what grows unpredictably in fixed blocks behind an indirection. Example: paged attention, which is virtual memory from 1962.
  • 10 · An idle resource is a budget: idle capacity does not accrue. Spend the abundant resource freely to save the scarce one, even on work you expect to throw away. Example: speculative decoding below the ridge.

IV. Believing Your Evidence

V. When the Floor Is Wrong

VI. The Old Shape

  • 15 · Describe the problem in its own terms before its vocabulary: strip out the field's names and write what one unit of work costs, in symbols. If they match a problem you have solved, the old answer transfers, with its old assumptions; check each one. Example: group commit, the ridge point and the bandwidth-delay product are one fraction, a fixed trip over a per-item price.