AI Tokenomics in a Minute
Cost Per Task
How to estimate what a coding-agent task costs in tokens and dollars—with assumptions visible.
In one sentence
Cost per task is the fully attributed model (and related) spend required to attempt a defined unit of work.
Why it matters
Sticker price per million tokens hides retries, tool loops, and context growth. Task-level cost connects spend to engineering work.
How it works
- Define the task boundary (ticket, PR, agent session).
- Sum input, output, cached, and other billed token classes for that boundary.
- Apply the prices that applied when the usage occurred.
- Optionally add human review time as a separate cost line—do not silently mix units.
- Report assumptions: model, caching, what counted as “done.”
Example
Session used 800k input tokens ($X), 40k output tokens ($Y), 2M cached reads ($Z). Task cost ≈ X+Y+Z. If three retries repeated most of the work, say so—amortize or show retries as waste.
What this proves
A careful cost-per-task figure proves billed usage attributed to a stated task boundary under stated prices.
What this does not prove
It does not prove the task was valuable, correctly implemented, or cheaper than a human-only path without a comparative study.
Last reviewed 2026-09-06. Title for citation: AI Tokenomics in a Minute: Cost Per Task.