I Put My Agent's Model Routing Policy in Git. The Bill Dropped Before the Code Did. A developer reports that an unattended coding agent spent most of its budget on a frontier model for trivial tasks like docstring regeneration and version bumps, while a subtle bug received the same expensive treatment and was later reverted. To address this, the developer implemented a model routing policy stored in a JSON file in Git, with tiered model selection based on task complexity, a verification gate, and shadow-mode validation before enabling cheaper tiers. The approach aims to make routing decisions reviewable and cost-effective. Two weeks after I let a coding agent run unattended on backlog chores, the provider invoice told me something my logs hadn't: the agent had spent the majority of its budget on a frontier model doing work like regenerating docstrings, bumping pinned dependency versions, and normalizing import order. Meanwhile, the one genuinely subtle bug it touched — a time-ordering issue in a queue consumer — got the same model as the docstrings, with the same shallow retry behavior, and shipped a patch I reverted four days later. That inversion is the actual problem. Not "models are expensive," but: an unattended agent makes a spend decision on every single call, and the default decision is always the same. My previous post argued that agent permissions belong in version control. This is the same instinct applied to model selection: routing is policy, policy should be a file, and files should be reviewable in git. What follows is the setup I run now, with placeholders where model identifiers go — catalogs change too fast for any name I write today to survive your reading of it. Instead of burying tiers in code, the routing rules live in a JSON document that's diffable, reviewable, and rollbackable: { "tiers": { "name": "gratis", "models": "