← What's New

AI Cost Engineering: The New FinOps Discipline

AI cost is the new FinOps frontier. A unit-economics framework and the seven cost levers that actually move the bill, in order of ROI

The teams winning at AI economics are not the ones with the cheapest models — they are the ones with the cleanest unit economics.

For most of the last two years, AI cost was someone else’s problem. Engineers shipped features, the OpenAI bill arrived, finance grumbled, life went on. That model is breaking down. The FinOps Foundation has formalized FinOps for AI as a dedicated technology category alongside public cloud, SaaS, and licensing, and the share of organizations actively managing AI spend as a discrete practice has gone from a curiosity to the norm in roughly two years.

The shift is overdue. AI workloads behave differently from anything FinOps has handled before, and the optimizations that worked for EC2 reserved instances do not translate. What does work is a specific discipline — call it AI cost engineering — that combines unit economics, deliberate model selection, and a small number of high-ROI technical levers. This post lays out what that discipline looks like, with a framework you can apply this week and an honest assessment of where the savings actually come from.

Why AI broke traditional FinOps

Traditional FinOps was built for compute that you provisioned, billed by the hour, and could scale up or down on a predictable curve. AI inference breaks several of those assumptions at once.

First, the cost unit is tokens, not hours. A single user query can range from a few hundred tokens to several hundred thousand depending on context size, retrieval payload, and reasoning depth. Two queries that look identical in your product analytics can differ in cost by two orders of magnitude. EC2-style optimization — right-sizing instances, buying reservations — has no real analog here.

Second, input and output tokens price differently. Across major API providers, output tokens cost roughly five times input tokens. A workload that generates long answers from short prompts has wildly different economics from one that summarizes long documents into short outputs. Most early dashboards do not separate the two.

Third, the same task can be served by models that differ in price by two orders of magnitude or more. Cheap, fast models handle most simple work. Frontier models are overkill for classification, extraction, and routing. Sending every call to the most expensive available model is the default for fast prototypes — and the single largest source of waste once those prototypes hit production.

Fourth, the discipline of unit economics has barely arrived. Cost-per-request, cost-per-conversation, cost-per-successful-task — these basic metrics are missing in most organizations. You cannot optimize what you cannot measure, and most teams are flying blind.

The cost-per-task worksheet

Before you reach for any optimization technique, you need numbers. The unit economics framework that has held up across most AI-heavy teams I have seen looks like this. For each user-facing AI feature, compute:

  • Cost per call. Input tokens × input rate + output tokens × output rate, averaged over a representative sample of real traffic. Sample at least a few hundred requests; the distribution has a long tail.
  • Calls per task. A “task” is the user-perceived unit — one question answered, one document summarized, one ticket resolved. Agents make multiple calls per task. RAG pipelines often do too: embedding, reranking, generation, sometimes a validator on top.
  • Cost per task. Cost per call × calls per task.
  • Quality-adjusted cost per task. Multiply by the inverse of your success rate. A fifty-percent success rate roughly doubles the effective cost, because half the work has to be redone or escalated to a human.
  • Cost per business outcome. The conversion to the number that finance actually cares about: cost per closed ticket, cost per qualified lead, cost per draft accepted, cost per onboarded user.

The worksheet is not novel. The discipline of actually filling it in for each feature, refreshing it monthly, and reviewing it as part of product planning is what changes outcomes. Teams that do this find an uncomfortable truth quickly: a small number of features usually account for the majority of spend, and most of that spend is on tasks a cheaper model would have handled identically.

The cost optimization levers, in order of ROI

Once you have unit economics, the optimization playbook becomes triage rather than guesswork. The levers below are roughly ordered by return on engineering effort — start at the top.

  1. Model routing. The single largest source of waste in most AI products is using a frontier model for tasks a small or mid-tier model handles equally well. Build a router that classifies requests by complexity and sends them to the cheapest model that meets a quality bar. The FrugalGPT paper by Chen, Zaharia, and Zou formalized this as the LLM cascade pattern — cheap model first, escalate only on low-confidence outputs — and reported cost reductions of up to ninety-eight percent on certain benchmarks. The exact savings depend on your workload, but a fifty-to-seventy-percent reduction is realistic for most enterprise tasks once you do the routing work seriously.

  2. Prompt caching. Both Anthropic and OpenAI now support caching the stable portions of a prompt — system instructions, tool definitions, long reference documents — and charging a small fraction of standard input price on cache hits. For RAG and agent applications with a large stable context, this is the cheapest production win available. Many teams who have not enabled it leave significant money on the table for no good reason.

  3. Batch processing. Both major providers offer roughly half-price tiers for asynchronous batch jobs that return results within twenty-four hours. Anything not user-facing — nightly enrichment, evaluation runs, document indexing, content-generation pipelines — has no business running at synchronous rates.

  4. Context discipline. Every token in your prompt costs money. Aggressive context pruning — tighter retrieval, deduplication, removing redundant tool outputs, summarizing conversation history — typically reduces input volume by a substantial fraction with no quality loss. This pairs naturally with the context-engineering work most production teams are already doing.

  5. Output controls. Output tokens are about five times more expensive than input. Constrain output formats (JSON schemas, max-token caps, structured templates) and the bill drops accordingly. “Verbose mode” should be an explicit user request, not the default.

  6. Distillation and fine-tuning. For high-volume, narrow tasks — classification, extraction, routing, structured-output generation — fine-tuning a small model on outputs from a large one (the classic distillation pattern) can produce a task-specific model that runs at a fraction of the cost of the original, with comparable or better quality on that specific task. The investment pays back at high volume; it does not pay back for low-volume or fast-changing tasks where the model has to be retrained every few weeks.

  7. Self-hosting. Treated as the last lever for a reason. See the next section.

The ordering matters. Teams that jump straight to fine-tuning or self-hosting before fixing routing and caching are doing high-effort, slow-feedback work in service of optimizing the wrong thing.

When self-hosting actually wins

Open-source models have caught up enough that “we should just self-host” is now a credible question rather than a hobbyist one. The honest answer is more conservative than the marketing suggests.

The break-even point for self-hosting against a major API provider is much higher than teams initially estimate. Recent cost-benefit analyses put the threshold somewhere in the tens to hundreds of millions of tokens per day, depending on which API you compare against and how rigorously you account for engineering overhead. Against budget APIs in the cheapest tiers, the break-even can move so far out that it is effectively unreachable on a single inference cluster. The gap between “free model weights” and “actually serving a model in production” is dominated by costs that are easy to overlook: GPU rental or purchase, electricity and cooling, observability, model versioning, on-call rotation, and the senior engineer who becomes the de facto inference-platform owner.

That said, self-hosting earns its place in four specific cases:

  • Sustained scale. When token volume is large enough that the per-token economics flip — typically in the hundreds of millions of tokens per day for frontier-class workloads — fixed infrastructure costs amortize cleanly and the savings become material.
  • Data residency. Regulated industries — healthcare, finance, defense — often cannot send data to a third-party API at any price.
  • Custom models. If you have fine-tuned a model on proprietary data and it materially outperforms general APIs on your specific task, you usually need to host it yourself.
  • Latency-critical paths. A small set of applications need sub-hundred-millisecond inference that cross-region API calls cannot meet reliably.

Outside these cases, hybrid is almost always the right answer: APIs for the long tail of varied requests, self-hosted for the high-volume narrow workloads where the math actually works.

Making cost engineering an organizational discipline

The technical levers above only compound if cost is treated as a first-class concern in how teams operate. A short list of organizational practices that consistently separate the teams who control AI spend from those who do not:

  • Cost dashboards by feature, not by API key. Showback at the product-feature level forces ownership. “OpenAI bill: forty-seven thousand dollars” is unactionable; “Support chatbot: thirty-one thousand, Document analyzer: fourteen thousand, Internal copilot: two thousand” is.
  • Cost in code review. Pull requests that change prompts, add tools, or modify retrieval should include the estimated unit-cost impact. This is the AI equivalent of treating database query plans as a code-review concern.
  • Quality gates with cost budgets. When evaluating model upgrades or feature changes, the evaluation harness should report cost-per-task alongside quality metrics. A two-percent quality lift that triples cost should require explicit justification, not implicit approval because the number went up.
  • Quarterly cost reviews tied to product OKRs. The conversation moves from “we spent X on AI” to “we spent X to deliver Y outcomes; what is the trajectory?” That is where FinOps starts feeling less like accounting and more like product engineering.

None of this is exotic. Most of it is the same discipline mature software teams already apply to cloud spend, database queries, and infrastructure provisioning. The novelty is recognizing that AI is now large enough, variable enough, and probabilistic enough that the same scrutiny applies — and that ignoring it for another year is no longer a viable strategy.

The teams that take AI cost seriously in the coming year will not be the ones with the smartest routing algorithm or the cheapest contracted model. They will be the ones who treat unit economics as a product discipline, not an infrastructure afterthought; who instrument every feature with cost-per-task from day one; and who can answer, to two decimal places, what each query in their product actually costs to serve, and why. Everyone else is going to spend the year explaining the bill.