In cost of revenue, split by feature. Training, evaluation, and experiments stay in operating expense.
The reason is visibility. A product team that never sees the serving bill can't make the trade-offs that move margin: which model a feature calls, how often, for whom, and what happens to price when the vendor's price drops. Anthropic's S-1 shows how much the classification matters at the top of the market, where the same half-year reads as an 85 percent or roughly 45 percent margin depending on one line.
The full argument, including the pass-through policy for vendor price cuts and the one-page monthly review with the CFO, is Anthropic's S-1 Has No Gross Margin Line. Your AI Product Needs One., part 5 of The CPO Transition. The unit to measure is in Gross Margin Is Your Job Now.