Why LLM Inference Costs Keep Falling: A Practical Guide to Caching, Off-Peak Scheduling, and Model Tiering

    LLM inference prices have dropped by nearly two orders of magnitude in two to three years, and billing models are starting to resemble utility pricing with peak and off-peak windows plus cache-hit and cache-miss rates. This article explains what drives the cost curve, then walks through three tunable levers developers can control: prompt prefix cache hit rate, off-peak scheduling for deferrable workloads, and routing across light and high-performance model tiers. It also covers how to build a unit cost model, which metrics to instrument, why optimizing unit price alone can backfire, and the capacity and stability practices needed when low prices encourage higher call volume. A final checklist summarizes the steps.

    1. The Cost Curve: From Per-Token Billing to Utility-Style Pricing

    Inference prices for large models have fallen by orders of magnitude over the past two years. An annual AI index report from a university, using models that reach the level of early mainstream chat models on general knowledge benchmarks as a reference, shows the price per million tokens dropping from roughly $20 to under $0.1 within two to three years — close to a two-order-of-magnitude decline. No single factor explains this curve. It is the combined result of inference engine optimization, quantization and sparsification, better hardware utilization, cache reuse, and market competition.

    More interesting is how the billing model itself is evolving. The industry has already seen peak/off-peak pricing that distinguishes busy hours from idle ones, along with a split between light tiers and high-performance tiers, and different unit prices for cache hits versus misses on the input side. Tokens are no longer a homogeneous commodity; they are a resource with time and reuse properties — which closely mirrors how electricity is billed.

    For developers, this makes bills more predictable, but the optimization target shifts from “pick a cheaper model” to “call the right tier at the right time with the right reuse rate.”

    2. Putting a Meter Inside the Inference Pipeline: Three Adjustable Knobs

    2.1 Cache Hit Rate: The Most Underrated Lever

    Most mainstream inference services support prompt caching semantics: when multiple requests share an identical prompt prefix, the server can reuse the already-computed intermediate state, and the cached portion is billed at a significantly lower unit price. Looking at public pricing structures, the input unit price for hits versus misses often differs by one to two orders of magnitude, so the hit rate has a very large marginal effect on total cost.

    The key engineering constraint for raising the hit rate is prefix stability:

    1. [Stable prefix] System instructions + tool declarations + domain knowledge/long documents
    2. [Volatile suffix] Incremental conversation history + current user input

    As long as volatile content comes last, and you avoid inserting timestamps, random IDs, request sequence numbers, and similar variables into the long prefix, the cache stays effective. Conversely, something as harmless-looking as prepending the current time to the system prompt will degrade the entire long prefix to a miss.

    2.2 Peak and Off-Peak Windows: Moving Deferrable Workloads to the Valley

    When off-peak pricing is half the peak price, cost optimization takes on a scheduling dimension. The practical test is not “how important is this workload” but “does the user wait for the result in the same second”:

    • Suitable for off-peak: offline batch summarization, log and ticket classification, data cleaning and labeling, nightly regression evaluation, batch translation and content moderation.
    • Must stay on peak: latency-sensitive paths for the first token in online chat, real-time risk control, interactive completion.

    In engineering terms, this usually means adding a queue and task classification layer: batch jobs are written to a message queue, consumers drain them within off-peak windows under a quota, and overdue tasks get a fallback policy.

    2.3 Model Tiering: Capability Density Drives Tier Selection

    There is a several-fold price gap between light and high-performance tiers, so “default to the strongest model” is a common source of waste. A safer approach is a routing layer: handle requests with the light tier first, combined with rule-based validation and confidence checks, and escalate to the high-performance tier only for low-confidence cases, long-context reasoning, or multi-step tool calls.

    1. def route(task):
    2. if task.needs_multi_step or task.context_tokens > 32000:
    3. return "high_tier"
    4. if task.confidence < 0.75:
    5. return "high_tier"
    6. return "light_tier"

    3. Cost Modeling: Model First, Optimize Second

    Do not judge whether something is expensive by feel. Write down the unit economics first:

    1. Cost per call = uncached input tokens × miss unit price
    2. + cached input tokens × hit unit price
    3. + output tokens × output unit price
    4. Monthly cost = cost per call × daily call volume × 30 × (1 + retry rate)

    Retry rate, the rate of over-long context truncation, and the share of failures that fall back to a higher tier are often overlooked sources of hidden cost. It is worth instrumenting four metrics for every pipeline: average input/output token counts, cache hit rate, tier distribution, and time-window distribution. With those four data sets, cost reduction turns from guesswork into a verifiable experiment.

    A typical mistake is optimizing only the unit price. Compressing input by 30% sounds good, but if the compression breaks prefix stability and the hit rate falls from 80% to 20%, total cost goes up instead. So any optimization should watch the product of unit price and usage.

    4. Capacity and Stability: Low Prices Do Not Mean Unlimited Calls

    Falling prices encourage larger call volumes, which amplifies rate-limiting and jitter risk. Sound practices include:

    • Quotas and budgets: set token budgets and circuit-breaker thresholds per business line so a single anomaly cannot exhaust the allowance.
    • Backoff retries: use exponential backoff with jitter to avoid simultaneous retries causing a second shock.
    • Multi-tier fallback: when the high tier is unavailable, degrade to the lower tier and annotate the confidence of the result.
    • Observability: use logging services and monitoring alerts to run trend and anomaly detection on latency, error rate, and token consumption.
    • Data-plane governance: store long documents in object storage and retrieve relevant snippets to inject into context on demand, rather than stuffing entire documents into the prompt.

    On the cloud, these capabilities are typically provided by general-purpose categories: container platforms handle elastic scaling, message queues absorb traffic spikes, object storage and retrieval services supply context, and monitoring alerts plus logging form the observability foundation. Baidu AI Cloud offers standardized, catalog-based infrastructure support for these general capabilities, but the actual selection should still be validated with load testing against your own workload characteristics.

    5. Practice Checklist

    1. Restructure prompts to keep the prefix stable and push variables to the end; measure the hit rate before pursuing other optimizations.
    2. Establish task classification and queues, and move deferrable workloads to idle windows.
    3. Roll out a routing layer that sends the bulk of traffic to the light tier and escalates by confidence.
    4. Build a unit economics model with the four instrumentation metrics, and run A/B tests instead of optimizing on intuition.
    5. Set budget circuit breakers, backoff retries, and fallback paths to prevent usage from spiraling as prices drop.
    6. Review tier distribution and time-window distribution regularly to remove structural waste.

    Conclusion

    The continued decline in inference cost is essentially the conversion of a scarce resource into a schedulable, reusable public one. Once billing gains both a time dimension and a reuse dimension, cost governance becomes an architecture problem rather than a procurement problem: whoever handles cache reuse, time-window scheduling, and model tiering more precisely can push the bill lower at the same quality level while keeping headroom for peaks and failures.