How to Evaluate LLM Cost-Effectiveness Across Multiple Pricing Channels

    Bills for AI agents and coding assistants can't be reduced simply by picking the cheapest model name. In a single task, system prompts, repository context, tool outputs, and multi-round revisions repeatedly enter the context, and outputs are often longer than casual chat. When input, output, and cache prices across channels use inconsistent bases, side-by-side comparisons become distorted. This article explains how to align comparison targets, use weighted unit prices instead of list prices, interpret price gaps between channels, fold stability into effective cost, check capability floors before ranking by price, and maintain a fixed verification checklist so conclusions remain reproducible when prices change.

    Bills for AI agents and coding assistants rarely shrink just by “picking the cheapest model name.” In a single task, system prompts, repository context, tool returns, and multi-round revisions repeatedly enter the context, and outputs are often longer than casual chat. If the input, output, and cache prices on a channel’s pricing page use inconsistent bases, horizontal comparisons get distorted. After prices change, the right order of operations is to standardize the measurement method first, then talk about cost-effectiveness.

    First, Align What You Are Comparing

    The minimum unit of a cost-effectiveness comparison should be “same generation, same capability tier, same billing dimensions,” not the series name on a marketing page. There are three common sources of distortion.

    First, version mismatch. When a new flagship model launches, some channels only offer a coding-specialized variant, a lightweight version, or the previous generation’s API. Putting different generations in the same row to compare unit prices makes the resulting “cheap” meaningless. Before comparing, verify context length, tool-calling support, structured output support, whether thinking and the final answer are billed separately, and whether cache hits are billed as a separate line item. If any key capability is missing, mark it as non-comparable rather than filling in a near-equivalent model.

    Second, currency and units. Some price lists are per million tokens, some per thousand tokens; some in US dollars, some in other currencies. Before comparing, fix an exchange-rate assumption and state the date it was taken in your write-up. The exchange rate is only for horizontal alignment, not the actual settlement rate.

    Third, workload weights. Chat demos tend to have short inputs and short outputs; agent-based coding typically means long inputs and repeated outputs. Ranking purely by output unit price overestimates plans that are “cheap on output but expensive on input,” and underestimates the savings from cache hits.

    Rank by Weighted Unit Price, Not List Price

    Break a typical task into input, output, and optionally cache hits. For agent-based coding, an explainable starting point is: input roughly 30%, output roughly 70%. This is not a universal constant—it’s an empirical approximation for loops like “read a lot, write a bit, then read the diff.” Teams should replace this ratio with their own gateway logs.

    Let the input unit price be Pi, the output unit price Po, the cached-read unit price Pc, and h (between 0 and 1) the fraction of input that is a cache hit. Misses are still billed at Pi. The expected price per million tokens can be written as:

    Unit cost = 0.30 × [(1 − h) × Pi + h × Pc] + 0.70 × Po

    If a channel offers no cache pricing, set h = 0—don’t apply another vendor’s cache discount. If caching only applies to prefixes that are byte-for-byte stable, h should come from real traffic, not the theoretical optimum on the pricing page.

    The sample calculation can live in your access layer to avoid manual spreadsheet errors:

    1. def unit_cost(pi, po, pc=None, in_ratio=0.30, hit=0.0):
    2. out_ratio = 1.0 - in_ratio
    3. if pc is None:
    4. hit = 0.0
    5. pc = pi
    6. input_part = (1.0 - hit) * pi + hit * pc
    7. return in_ratio * input_part + out_ratio * po

    When comparing, present three scenarios: h = 0 (cold start or frequently changing prompts), h at your online median, and h at the upper bound achievable with stable prefixes. Showing only the upper bound risks treating a lab environment’s cache hit rate as a production bill.

    What a Channel Price Gap Actually Tells You

    For the same model weight, reseller or aggregator access prices may be either above or below the source. A price gap doesn’t prove who “should” be cheaper—it only shows that the quotes include different things. Common components include: how inference capacity is reserved, concurrency and rate limits, invoicing and contracts, data residency, log retention, retry allowances during failures, and the channel’s own subsidy period. When the subsidy ends or the model raises prices, low prices can rebound—so decisions should look at price-lock duration, not the lowest sticker price captured on a given day.

    Direct access to the source is not automatically the most expensive, and aggregator access is not automatically cheaper. If a relay price is significantly above the source, the extra cost should translate into measurable capabilities: more stable quotas, unified authentication and auditing, multi-model fallback, intranet access, or simpler financial settlement. If you don’t need those capabilities, keeping direct source access is more reasonable. If a low-price channel throttles frequently at peak times, agents will add retries and duplicated context—the nominal unit price drops while the effective cost rises.

    Fold Stability into Effective Cost

    Effective cost should include at least four components, not just the token unit price.

    Failed retries. Timeouts, empty outputs, and invalid tool parameters all make you pay for the same context again. Use “tokens spent per successful task / number of successes” instead of the list price. Timeout thresholds and retry counts should be fixed in your evaluation scripts.

    Latency’s effect on human-in-the-loop work. If a coding agent takes tens of extra seconds per step, developers open more parallel sessions, context gets duplicated, and total tokens rise. Latency doesn’t appear on the price sheet, but it changes h and output length.

    Context strategy. When retrieval snippets can replace pasting an entire repository, no input unit price can save more than simply “sending fewer tokens.” Do truncation, summarization, and diff patches first, then compare channels—this is usually more effective than switching to a cheaper access provider.

    Whether cache actually hits. System prompts, tool specifications, and unchanging repository conventions should sit in the stable prefix; user questions and the latest diff go in the suffix. If the prefix changes daily, even the lowest cache price yields near-zero savings.

    Check Capability Floors During Selection

    Price comparison presupposes that tasks can actually be completed. Validate with the same set of internal test cases rather than marketing benchmarks. Cases should cover: multi-file edits, tool-call round trips, locating issues in long logs, refusing uncertain changes, and whether outputs follow your team’s patch format. Only when pass rates are close should you rank by the weighted unit price above. Access options with clearly lower pass rates should be excluded or kept only as fallback, even if their unit price is lowest.

    Fallback strategy can be tiered by task: planning and cross-file reasoning on more capable tiers; format conversion, comments, and simple completions on low-price tiers. Tiering itself is cost-effectiveness—you don’t need every step to use the same price point.

    A Checklist Worth Fixing in Place

    Collection date, currency, exchange-rate assumption, and the pricing source page (internal archive is fine—don’t rely on external links that may change). Model generation and context limits. Whether input, output, and cache prices are all published; treat missing items as “no cache.” Your agents’ real input-output ratio, calibrated with at least two weeks of logs to replace the 30/70 starting point. Successful-task cost under your throttling, timeout, and retry policies. Whether data retention, geography, and compliance requirements permit a given access option. Price validity period, and switching cost if prices rise.

    Writing these items into a single table holds up better under review than remembering “who raised prices recently, who is temporarily cheapest.” Prices will change—but once the methodology is fixed, next time you only need to swap in new unit prices and hit rates and recompute the conclusion, rather than re-trusting someone else’s one-off comparison screenshot.