You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Live usage token count does not include cached tokens #179
For example, here is the live usage tracker (freshly re-run, so it is up to date):
And here is the report with a breakdown:
You can see that the usage reported by the live tracker only contains the sum of the input and output tokens, not cache create and cache read. But this doesn't make sense; while the cost of cache read tokens is minimal, cache create actually costs more than input:
So surely the live usage should at the very least show the cache create count in addition to input + output?
Sorry, I don't have the bandwidth for contributing to this project at the moment, unfortunately.
Hmm, everybody has different opinion. so please give us a brief proposal here!
Not sure what you mean here. What opinion is differing? We know for sure that cached tokens count in some way towards usage, with the max plan at least.
Activity
ryoppippi commentedon Jun 23, 2025
oh really, thanks.
I think you can fix it! send us a PR
ryoppippi commentedon Jun 23, 2025
but it is difficult to estimate the max token if we consider cached token
I think @a-c-m knows about it
ashleyww93 commentedon Jun 23, 2025
Difficult or not, it is taken into account on anthropic's side.
I would rather usage be correct, and projection be off, rather than it be totally wrong.
ryoppippi commentedon Jun 23, 2025
Hmm, everybody has different opinion. so please give us a brief proposal here!
TreeOfLearning commentedon Jun 24, 2025
Sorry, I don't have the bandwidth for contributing to this project at the moment, unfortunately.
Not sure what you mean here. What opinion is differing? We know for sure that cached tokens count in some way towards usage, with the max plan at least.
fix: Include cache tokens in live usage token count calculations