Measure before changing behavior

Build a request ledger with owner, route, model, tokens, cache state, latency, retries, and outcome. Find the largest cost pools and the routes with avoidable output length, repeated context, duplicate calls, or test traffic in production accounts.

A broad downgrade before this analysis can create rework while leaving the real waste untouched.

Take low-risk savings first

Remove duplicated system context, limit outputs to what the product consumes, reuse stable prefixes through provider caching, and use batch APIs for work without interactive latency requirements when provider terms fit.

Add exact response caching to stable idempotent routes and fix retry multiplication. These steps often require less quality risk than model substitution.

  • Stop unnecessary and duplicate calls
  • Trim unused prompt and retrieval context
  • Bound output length
  • Use provider prompt caches
  • Use exact response caches
  • Move eligible work to batch
  • Review embedding and judge frequency

Route with evidence

Classify workload families and define success checks. Shadow a lower-cost route, compare quality and effective cost, then enforce one cohort at a time. Include escalations, retries, and evaluator calls in the savings calculation.

Published cascade and routing research shows the potential, but the approved operating point must come from your traffic.

Add financial guardrails

Set team budgets, forecasts, and progressive actions. Track cost per outcome so teams can distinguish valuable growth from inefficient usage. Revisit the plan after model price or prompt changes.

Frequently asked questions

What is the fastest way to lower LLM cost?

First identify the top routes and eliminate duplicate calls, excessive context, and unnecessary output. The fastest safe action depends on the actual cost distribution.

Should every request use a cheaper model?

No. Pin workloads that lack evaluation or have strict quality, security, modality, or contractual requirements.

How should savings be reported?

Report realized cost against a documented baseline, net of routing, cache, judge, retry, and infrastructure costs. Keep shadow opportunity separate.

Sources and further reading

  1. OpenAI API pricing
  2. FrugalGPT paper
  3. RouteLLM paper
  4. Anthropic prompt caching

FrugalAI uses primary documentation and published research where possible. Product capabilities and prices can change; verify vendor details before procurement or production changes.