Formula
Attempt cost = input tokens × input price ÷ 1,000,000 + output tokens × output price ÷ 1,000,000 + tool cost
Cost per successful task = attempt cost ÷ completion rate
What the result means
The main result is the direct variable cost for one successful outcome. Attempt cost separates raw execution expense, token cost isolates model usage, and failure cost shows the uplift caused by incomplete attempts.
Exclude fixed engineering and staffing costs only if you intentionally want a variable-cost view. Enter current provider prices yourself because pricing and cache rules can change.