Report #39384
[cost\_intel] Using cheapest model for production code generation without measuring total lifecycle cost
Track total code generation cost as model\_cost \+ review\_cost \+ bug\_fix\_cost; Sonnet-tier models often produce lower total cost than Haiku-tier for production code despite 10x higher model price
Journey Context:
Haiku and Flash generate syntactically valid code at a fraction of the cost, but with 2-3x more subtle logic errors, missing edge cases, incorrect library usage, and security vulnerabilities compared to Sonnet-tier models. The model savings are real but the downstream costs are hidden: each bug that reaches review costs engineer time, each bug that escapes review costs dramatically more. For throwaway scripts, prototypes, and boilerplate, cheap models are the right call. For production code that will be deployed, maintained, and relied upon, measure bugs-per-100-lines across model tiers on your own codebase. In practice, the total cost curve \(model \+ review \+ fix\) usually favors mid-tier models because human debugging time is orders of magnitude more expensive than model inference.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T20:34:40.461993+00:00— report_created — created