Where we start
Foundations session 3 drew two marginal cost curves: a physical good, where the next unit costs about what the last one did, and an information good, where the next copy costs nothing. Inference sits in neither picture. The next prediction costs a fixed number of tokens times a fixed price per token, every time, forever. That makes the choice between renting a model by the request and owning one by the month a textbook fixed-versus-variable problem, and textbook problems have textbook answers: find the volume where the two lines cross, then ask which side of it you are on. Tonight builds that crossing from list prices and a constructed workload, and keeps the one number nobody can publish, the cost of owning, as a variable you move.
★ What you walk out with tonight. A cost function that turns a request into dollars from a dated price list, the monthly bill for a constructed workload on three models, a break-even volume you can defend as F divided by c, and the habit of writing the price list's date next to every number that came from it.
A prediction has a marginal cost, and it is on a price list
5 min liveA fixed cost is paid whether or not a request arrives: a server, a licence, a team. A marginal cost is paid per request and only per request. Per-token API pricing has no fixed part: send nothing, pay nothing; send twice as much, pay twice as much. The list prices as published on 25 September 2026 are 5 dollars per million input tokens and 25 per million output tokens for Claude Opus 5, 2 and 10 for Claude Sonnet 5, 1 and 5 for Claude Haiku 4.5, with cache reads at about a tenth of the input price. The list carries more models than these three; the page names only these, and you re-check the list before you decide anything.
LivePer-token pricing is a pure marginal cost3 min▶
The shape of the bill. Cost equals requests times cost per request, and cost per request equals input tokens times the input price plus output tokens times the output price, both per million. Nothing in that expression is paid when no request arrives. Economists call a cost with that property purely variable, and a cost per additional unit a marginal cost; here the two are the same number, c, and c does not change with volume until a volume discount is negotiated, which the public list does not carry.
Why the output price matters more than it looks. Output tokens are priced five times the input tokens on every one of the three models named tonight: 25 against 5, 10 against 2, 5 against 1. A request that reads 1,200 tokens and writes 300 pays more for the 300 than for the 1,200. A feature that writes long answers is a dear feature even if it reads almost nothing, and that is visible only if you split the request into its two token counts before pricing it.
The date on the list. The prices above are list prices as published on 25 September 2026. They have moved before and will move again; the map that feeds these pages records that Claude Sonnet 5's price was introductory earlier in the year and is now standard. Every cost you compute from a list carries the list's date, and a break-even computed on a stale list is a stale break-even.
Self-studyThe zero-marginal-cost story, and why inference breaks it2 min▶
Shapiro and Varian 1998, Information Rules, is the reported source of the modern version: an information good is expensive to produce and cheap to reproduce, so its cost structure is almost all fixed, competition drives the price toward the near-zero marginal cost, and the only defence is to differentiate, version, and lock in. Software companies built their margins on that sentence for three decades: the thousandth user of a spreadsheet costs the vendor a few cents of bandwidth.
Inference breaks the sentence at the word reproduce. A prediction is not reproduced; it is produced, every time, from tokens through a model on hardware that draws power. The thousandth request costs as much as the first. The fixed cost of training is still enormous, so the story is half right, but the half that is wrong is the half a finance team lives in: a cost of goods sold line that rises with usage, and a gross margin that can fall as the product succeeds. Software margins assumed volume was free. Inference margins have to be earned per request.
The summariser that got cheaper by writing less (constructed). A team ships a document summariser and prices it in their head by the size of the documents: long inputs, so a dear feature. The bill says otherwise. At the list prices above a request reading 1,200 tokens on Claude Opus 5 costs 0.006 dollars for the reading and 0.0075 for a 300-token summary; the summary is more than half the cost. Cutting the summary from 300 tokens to 150 saves more than trimming the input by a third would. The story is invented; the arithmetic is the list price times the token counts, and it is the reason to price the two halves of a request separately.
One request, priced token by token, times two million
5 min liveThe workload is constructed: 2,000,000 requests a month, 1,200 input tokens and 300 output tokens each. It is a plausible shape for a customer-facing assistant and it is invented, so the bills below are arithmetic, not evidence. The arithmetic: 2,000,000 requests times 1,200 tokens is 2,400 million input tokens; times 300 is 600 million output tokens. At Claude Opus 5's list prices that is 2,400 times 5 plus 600 times 25, or 12,000 plus 15,000, which is 27,000 dollars a month. Claude Sonnet 5 comes to 4,800 plus 6,000, 10,800 dollars. Claude Haiku 4.5 comes to 2,400 plus 3,000, 5,400 dollars.
LiveThe monthly bill, and what it is a bill for3 min▶
The three bills. 27,000, 10,800 and 5,400 dollars a month for the same constructed 2,000,000 requests, a factor of five between the dearest and the cheapest. That factor is the reason model choice is a cost decision before it is a quality decision: if the cheaper model does the job as well on your evaluation set, the difference is margin. If it does not, the difference is the price of quality, and it is now a number rather than a feeling.
What the bill is not. It is not the cost of the feature. It is the marginal cost of the feature's requests. The engineers who built it, the evaluation harness, the on-call, the retrieval index the requests read from: all of those are fixed costs that the API bill does not carry and that an honest cost per request has to be spread over the volume, which is the utilisation question of Part 3.
Where the workload came from. It is invented. Real workloads have a distribution of input and output lengths, not a point, and the mean of a distribution is what the bill charges; a tail of long conversations can dominate. The first thing to do with a real product is to pull the token counts from the logs and replace the two constants with two means and two 95th percentiles.
Self-studyCaching as a marginal-cost cut, and latency as a cost2 min▶
Caching. Cache reads are listed at about a tenth of the input price. If 1,000 of the 1,200 input tokens are a system prompt and a shared context that every request repeats, a constructed share and a plausible one, the input cost of a Claude Opus 5 request falls from 0.006 to 0.001 for the 200 fresh tokens plus 0.0005 for the 1,000 cached, 0.0015 in total, and the request from 0.0135 to 0.009. Over the constructed month that is 18,000 instead of 27,000. The list also prices cache writes; add that line from the list before you count the saving. Caching is the rare cost lever that cuts c itself rather than N.
Latency. A request that takes four seconds instead of one is not dearer on the bill, and it is dearer to the business: a user who waits leaves, an agent that waits blocks the request behind it, a batch that waits ties up the machine. Latency is a cost with no line on the invoice, which is why it needs its own number, measured, next to c. The two trade against each other: a smaller model is cheaper and faster, a cached prefix is cheaper and faster, a longer output is dearer and slower. When a lever moves both the same way it is not a trade-off, and those are the levers to pull first.
The month the bill doubled and the traffic did not (constructed). A team's API bill rises 90 percent in a month on 5 percent more requests. The logs explain it: a prompt change added a worked example to the system prompt, and the mean input length went from 1,200 tokens to 2,300. Nothing about the product changed; c changed. The story is invented; the lesson is that c is a function of the prompt, and a prompt is a cost decision that engineers make without a finance review.
Utilisation, and the volume where owning wins
5 min liveOwning a model means paying a fixed monthly cost F, for hardware, hosting and the people who keep it up, whether or not a request arrives. No public list prices that, and no figure is asserted here: F is a variable the page moves. What owning does is turn a marginal cost into a fixed one, and a fixed cost has a utilisation problem: F spread over N requests is F over N per request, which falls as N rises. Rent costs c per request at every N. Owning wins when F over N drops below c, which is the same as N rising above F over c. That quotient is the break-even volume, and it is the only sentence the decision needs.
LiveBreak-even is one division, and F is a slider3 min▶
The division. Rent costs c times N a month; own costs F. Set them equal and N star is F over c. With c at 0.0135 for Claude Opus 5 at the list prices and an invented F of 40,000 dollars a month, N star is 40,000 over 0.0135, about 2,962,963 requests a month. The constructed workload is 2,000,000, under N star, so on those numbers renting Opus 5 at 27,000 a month beats owning at 40,000. Raise the volume past 2.96 million and the flat line wins; halve F to 20,000 and N star halves to about 1,481,481, which the workload clears.
Why F is a slider and not a number. The fixed cost of owning depends on hardware you have not priced, a hosting contract you have not signed, an on-call rota you have not staffed, and a utilisation you have not measured. Any single figure would be a guess dressed as a fact. So the page carries none. It varies F across a range and shows the break-even as a function of it, and the honest output is a table, not a point: at F of 20,000, 40,000 and 80,000, N star for Opus 5 is about 1.48, 2.96 and 5.93 million requests a month. Your F comes from your quotes, and the division is the same.
The cheaper model moves the break-even the other way. Renting Claude Haiku 4.5 costs 0.0027 a request, so N star at F of 40,000 is about 14.8 million requests a month. The cheaper the rented model, the more volume owning needs to justify itself. If a smaller model passes your evaluation, owning is usually not the next question; it is the answer to a question you no longer have.
Self-studyWhat the flat line hides2 min▶
Capacity. A flat F is flat until the box is full. Past its capacity a second box is needed and F steps up, so the own line is a staircase, not a line, and the break-even arithmetic holds only on the first step. If your volume sits just past N star, the first extra step can put you back on the rent side.
Peak against mean. Owning has to be sized for the busiest hour, not the average one; renting charges the average. A workload with a sharp daily peak needs a bigger box than its monthly mean suggests, which raises F and moves N star out. The quantity that decides this is the ratio of peak to mean load, and it is measurable from a week of logs.
The people. Hardware is the visible part of F. The team that patches, upgrades, monitors and answers the pager at three in the morning is the part that is left out of a quote and turns up in the salary line. Put it in F before the division, or the break-even is a marketing number.
Move the fixed cost and watch the break-even move. The cost per request is fixed by the list prices and the constructed 1,200 in and 300 out; F is invented, so it is yours to drag. The constructed workload is 2,000,000 requests a month.
The box that ran at a fifth of capacity (constructed). A platform team takes on a model to stop paying by the request. Six months later the box is busy one hour in five, the on-call rota has three names on it, and the per-request cost, F over the requests that actually came, is above the list price they left. Nobody did the division with a measured N; they did it with the N from the business case. The story is invented; the failure is the general one: a fixed cost is a bet on volume, and the bet is only as good as the forecast.
A cost function, a monthly bill, and a break-even table
★ 22 min · everyone buildsSix steps in plain Python, no data download. The prices are the list prices as published on 25 September 2026 and the code carries that date in a constant; the workload and every F are invented and the code says so. Nothing in the file prices a GPU, and the last step checks that it does not.
The price list, dated. Three models, input and output prices per million tokens, and the cache-read share. The date is a constant so that every number downstream can say where it came from.
The constructed workload and the monthly bill. Two million requests, 1,200 in and 300 out. The three bills are arithmetic on the list; the workload is invented and the comment says so.
Split the bill into its two halves. Input and output separately, because output is priced five times input and the short half is the dear half. This is the check that catches a long-answer feature before the invoice does.
Utilisation: one F, three volumes. F is invented. Spread it over more or fewer requests and compare the result with c; the crossing is visible before any formula.
The break-even table. N star is F over c, for three invented values of F and the three models. The output is a table because F is not known; the reader finds their row.
The cached variant, the sentence, and the assertion. A constructed 1,000 of the 1,200 input tokens served from cache cuts c; the sentence carries the date and the word invented; the assertion proves no hardware price crept into the model.
Keep the date next to the prices and the word invented next to F. When the list changes, one constant changes and every number downstream follows. When someone asks where 40,000 came from, the comment answers before you have to. A cost model that cannot say the date of its prices is a cost model nobody should sign.
Before deep-dive session 5
30 min- Replace the two constants with two measurements. Pull the mean and the 95th percentile of input and output tokens for one real feature from its logs and re-run steps 2 and 3. Write one sentence on which half of the request is the dear half.
- Re-check the list. Open the current price page, compare it with the constants in step 1, and change the date constant if anything moved. Note how far the break-even moved.
- Price your own F. Write every monthly line owning would carry, with the people included, and put the total through step 5. Say which side of N star your measured volume sits on, and by how much.
- Find the cache share. Count how many of your input tokens are the same on every request. Re-run step 6 with that number, and add the cache-write line from the list.
Three questions
Clear all three and deep-dive session 4 gets stamped in your passport.
1 · Why is per-token API pricing described as a pure marginal cost, and why does that matter for the old software story?
The vendor's fixed cost of training is enormous, but the buyer sees only c. Shapiro and Varian's reported story is half right: expensive to produce, but not cheap to reproduce, because a prediction is not reproduced.
2 · The constructed month on Claude Opus 5 costs 27,000 dollars: 12,000 for input and 15,000 for output. The input is four times longer than the output. Why is the output the dear half?
The same ratio holds on all three models named, 10 against 2 and 5 against 1, so the output share of the bill is 56 percent on each at this token mix. The check is step 3: split the bill before the invoice does it for you.
3 · With c at 0.0135 a request and an invented F of 40,000 dollars a month, which is cheaper for the constructed 2,000,000 requests, and what is the honest way to publish the answer?
At F of 20,000 the break-even halves to about 1,481,481 and the workload clears it. No GPU price is asserted anywhere, because none is known; the division is the same for whatever F your quotes produce.
What this session teaches, and where it came from
Every fact on this page, and its verification tier, is recorded in the course's source map.
Deep-dive session 4 cheat sheet · pin this
You now have a cost per prediction and a volume where owning starts to pay. Deep-dive session 5 asks what happens to value, not cost, as volume grows: network effects, direct and indirect, Metcalfe's n squared as a claim and the n log n rebuttal from Briscoe, Odlyzko and Tilly 2006, and the data version of the story, where more data compounds until the learning curve flattens and then it does not. The build-along fits a learning curve to constructed data and reads off where the flattening starts, which is the point at which "we have the data" stops being a moat.