LLM API Pricing Logic and Technical Analysis: How to Evaluate the Real Cost per Task

    As LLM API prices keep falling, a lower per-token rate does not always mean a better deal. This article breaks down the two main pricing models—cost-based pricing and market-positioning pricing—and explains the four technical variables behind inference cost: GPU memory capacity and bandwidth, batching and scheduling, cache reuse, and input/output asymmetry. It also covers off-peak pricing and cache discounts as scheduling tools, and shows how teams can build a three-layer framework to measure cost per completed task instead of chasing the lowest unit price.

    1. The Trend: Token Prices Are Falling Fast, but Cheap Is Not the Same as Cost-Effective

    Over the past year, LLM service pricing has changed more and more frequently. One smart-device vendor announced long-term price cuts across its model service lineup, a cloud platform reduced the prices of its hosted model services, and one model team introduced time-of-day pricing during a version update, followed by another round of cuts after the new release. The messaging is strikingly similar: percentage reductions, the lowest price per million tokens, and multiples relative to competitors.

    These numbers spread easily, but they obscure a key fact: tokens standardize the billing unit, not the cost structure, and certainly not the intelligence delivered per unit. The same token can cost several times more or less depending on the architecture, GPU memory configuration, and batching strategy. Likewise, the same 1,000 output tokens can solve tasks of vastly different difficulty.

    The right way to evaluate model service pricing is therefore not the absolute unit price, but the total cost of completing a unit of work.

    2. Two Pricing Methods: Cost-Based Pricing and Market-Positioning Pricing

    Based on public information and industry practice, mainstream pricing approaches fall into two categories.

    2.1 Cost-Based Pricing

    The basic formula can be abstracted as:

    1. Price = (Inference compute + Network + Storage + Operations) / Sellable tokens + Target profit

    Three boundaries are worth noting:

    • Only ongoing service costs are included; upfront model R&D amortization is typically excluded;
    • Selling expenses, salaries, and other operating costs are not included;
    • The denominator is “sellable tokens,” not “theoretical peak tokens,” so utilization directly determines the unit price.

    One model team has publicly stated that it targets recovering its hardware investment in about ten months through its API business, corresponding to a depreciation period of roughly five years and an implied gross margin of over 80%. This is a typical cost-oriented signal: the price is anchored to “sustainable service plus reasonable profit” rather than revenue maximization.

    2.2 Market-Positioning Pricing

    Most vendors lean toward this approach: first define the target customer segment and competitive position, then work backward to the price. Common tactics include:

    • Benchmarking the price per million tokens against competitors to create a perception of price advantage;
    • Using free quotas and tiered discounts to lock in developers and small and medium-sized customers;
    • Maintaining a premium for high-value scenarios such as long context, complex reasoning, and multimodal capabilities;
    • Exchanging enterprise-grade SLAs and dedicated capacity for higher average revenue per customer.

    The advantage of market-positioning pricing is fast customer acquisition. The risk is that once price decouples from cost, insufficient utilization can quickly erode gross margin.

    3. Where the Cost Comes From: Four Technical Variables of Inference Cost

    To judge whether a price is reasonable, you need to understand the cost structure.

    1. GPU memory capacity and bandwidth: The KV Cache grows linearly with context length and concurrency, making it the main consumer of GPU memory. If a new architecture can reduce the KV Cache’s demand for high-bandwidth memory to one quarter of the previous generation and its demand for solid-state storage to one eighth, the cost per token drops significantly. This is also the technical prerequisite for price cuts.
    2. Batching and scheduling: Continuous batching, request merging, and priority queues improve GPU utilization. Raising utilization from 30% to 60% nearly halves the effective unit price.
    3. Cache reuse: A prefix cache hit can skip repeated prefill and directly reduce compute consumption, which is why the “cache hit price” is usually significantly lower than the input price.
    4. Input/output asymmetry: Output is generated autoregressively token by token and costs more than input, so the output unit price is generally higher.

    4. Peak/Off-Peak Pricing and Cache Discounts: Using Price as a Scheduling Tool

    Introducing time-of-day pricing essentially turns price into a compute scheduling signal: lower prices during off-peak hours encourage deferrable tasks (batch summarization, offline evaluation, data cleaning) to run off-peak, smoothing load and improving overall utilization.

    The engineering response is straightforward: build a queue for deferrable tasks and schedule them according to price windows.

    1. # Example: schedule deferrable tasks by price window
    2. def schedule(task, price_window):
    3. if task.deferrable and price_window.is_off_peak():
    4. return price_window.next_slot()
    5. return "now"

    Cache discounts require callers to proactively stabilize prefixes: place invariant content such as system prompts, tool definitions, and long documents at the front, avoiding per-request changes that invalidate the cache.

    5. How to Evaluate Real Cost-Effectiveness: Build Your Own Accounting System

    Enterprises are advised to establish three layers of metrics:

    • Unit price layer: input price, output price, cache hit price, storage and network fees;
    • Efficiency layer: task success rate, retry rate, average token consumption per retry;
    • Business layer: cost per task = total bill / number of completed tasks.

    Example:

    1. Cost per task = (Input tokens × Input price + Output tokens × Output price
    2. + Cache hit tokens × Cache price + Storage and network fees) / Successful tasks

    Combined with general-purpose logging services and monitoring alerts, tracking token consumption, latency, and failure rates on dashboards is the only way to find the root cause of “the unit price dropped but the bill did not”—usually retries and overly long contexts.

    6. Selection Advice for Different Teams

    • Cost-sensitive batch workloads: prioritize vendors using cost-based pricing + off-peak scheduling + cache reuse;
    • High-value interactive workloads: prioritize performance and stability, accept a premium, and rely on SLAs and dedicated capacity as a safety net;
    • Startups and prototype validation: use free quotas for capability evaluation, but design a portable abstraction layer in advance to avoid being locked into a single interface.

    7. Conclusion

    LLM services are shifting from a “parameter race” to a “cost per unit of intelligence race.” Price is the result, not the cause; what truly determines long-term competitiveness is architectural efficiency, scheduling capability, and the depth of scenario validation. For users, building an accounting and monitoring system centered on “cost per task” matters more than chasing the lowest unit price. In related practice, Baidu AI Cloud also emphasizes using general-purpose cloud monitoring, logging, and containerized scheduling capabilities to help enterprises turn token bills into optimizable engineering metrics.