Four levers behind a claimed 70% cut in LLM API bills
A dev.to guide says caching, batching, blended pricing and host shopping can shrink AI API costs by 70% or more. Here is the logic, and what is still unproven.
The short version
- Output tokens usually cost 4x to 8x more than input tokens, so compare models on blended cost.
- Prompt caching cuts repeated input charges by 50% to 95% across several major providers.
- Moving non-urgent jobs to a Batch API gives a 50% discount at most major providers.
- Open-weight models like Llama 4 and DeepSeek vary widely in price and speed by host.
- The 70% total is the author's claim; our hosts have not reproduced it.
What the guide claims
As dev.to reported, one developer has published a guide with token arithmetic for shrinking the cost of calling large language models through an API. A token is a small chunk of text, often a word or part of one, and providers charge separately for the tokens you send in and the tokens the model writes back.
The author warns that choosing the wrong model, or skipping two discounts already built into most APIs, can leave a bill ten times higher than it needs to be. The guide offers four levers. The overall 70% figure is the author's own, and our newsletter hosts have not reproduced it.
Why it matters
If your product calls a paid AI model, the bill is built from small, measurable pieces, and several of them can be changed without hurting quality. The guide's levers are mostly settings and habits rather than rewrites. Because the total depends on your own traffic, measure before you trust anyone's headline percentage.
Price the mix, not the sticker
The first lever is about how models are compared. Price lists show input and output rates side by side, and it is tempting to pick the model with the lowest input rate. But the guide says generated text typically costs four to eight times as much per token as text you feed in.
So a model that looks cheap can turn expensive when a job produces lots of output, as chat and translation do. The author suggests working out a blended price using your real ratio of input to output. A retrieval-style app, where the model reads large amounts of pulled-in documents, leans roughly ten to one toward input. Translation is closer to one to one. The same model can be a bargain for the first and a poor deal for the second.
Caching and batching
The second lever is prompt caching. Many apps send the same opening material with every request, such as standing instructions, tool descriptions or a reference document. Providers can remember that repeated opening and charge less for it. The guide says the cut to repeated input charges runs from 50% to 95%, and that it is offered by Anthropic, OpenAI, Google, DeepSeek, Mistral, Qwen and AWS Bedrock.
To benefit, you structure each request so the unchanging material comes first and the part that varies, like the user's latest question, comes last. That ordering is the whole trick, and it costs nothing to try.
The third lever is the Batch API. Plenty of work does not need an instant answer: overnight data extraction, summaries, test runs of a model's quality, bulk translation. Sending those as asynchronous batches earns a 50% discount at most major providers, according to the guide.
Shopping for open-model hosts
The fourth lever applies if you use open-weight models, whose trained parameters are published so that many companies can run them. Llama 4 and DeepSeek are the examples given. The same model can be priced and performing very differently depending on who hosts it.
The author's rules of thumb: Cerebras and Groq for voice agents that need very fast replies, DeepInfra for the lowest bulk pricing, and Together AI or Fireworks for US enterprise service guarantees. These are one person's impressions, so test them against your own workload before committing.
How far to trust the 70%
The levers are not magic, and they do not stack neatly. Caching only helps if a large share of your input really repeats. Batching only helps if some of your work can wait. Blended pricing helps most if you were choosing on input price alone. A team already doing all three will see little, and a team doing none could see a lot.
The author also built a free calculator, which runs in the browser with no signup and offers CSV export and shareable links. It covers 50 models and 16 providers and lets you enter daily request volume, cache hit rate and a batch toggle. It is the author's own tool, so treat its numbers as a starting estimate and check them against real invoices.
This guide is relevant to anyone running a chatbot, summarizer or automation on a paid API. If you only use consumer chat apps on a flat subscription, none of it applies to you.
What to watch
- Whether independent teams can reproduce a 70% saving on real workloads.
- Whether provider caching and batch discounts stay at the levels the guide describes.
Try it
Pull last month's API invoice and list your biggest prompts. For each, note whether it repeats the same opening text and whether it could run as a delayed batch job.
More stories
ClaudeThomson Reuters builds Thomson 1.1 AI on Chinese and Google open-source models
ClaudeHush, a new tool, claims to let AI agents operate your apps in 178 milliseconds
Clauden8n releases Nod, a free open-source AI agent that chases invoices and cancels trials
ClaudeOpenAI hires Cravath litigator Gary Bornstein to face Musk's xAI in antitrust trial
Get The Daily
AI news, explained in 5 minutes a day. Free. The first issue is coming soon.
No password. Unsubscribe any time. Privacy
Say why
Liked it? Say why
Add a line for other readers.
No account needed. We never show your email. Comments with links, ads or abuse are held and not shown. Your comment shows after a quick check.
Sources
The reporting and documents this story is built from. Each link opens the original.
- ReportingDEV Community: the article we sourced dev.to
Written with AI by the SI Agent News Desk from the reporting above. Every number is checked against it.Spot a mistake? Corrections.
