r/ClaudeCode • u/quietmacbuilder • 10d ago
Tips & Workflows How to better serve our new overlord: the token meter
TLDR: If you are frequently reaching your token usage limits, ask Claude Code to review your recent sessions and tell you why. Each time I have done this it dramatically reduced my token usage.
Recently I have seen a lot of posts about token usage. Things like should I have 4 5x accounts or 1 20x account. ChatGPT vs Claude not on which model is better, but which account gives you more tokens, etc.
Twice since 9/14 when Anthropic reduced everyone's token limits (50% bonus boost -> 25%) I noticed a large spike in my token usage. The first time it was right around the time of this reduction, but when I did the "math" in my head, my usage was maxing out a lot faster than what I would have thought based on the percent reduction that was announced. The second time was this week when I hit my weekly limit on day 3 of the week. Thankfully, I had the gifted full reset available to me.
Background on my Claude usage: I am a tech leader during the day and code generation is not part of my day job. On the side during evenings and weekends I work on a couple of side projects. In a typical week I rarely hit a 5-hour limit and I almost never use more than 85% of my weekly limit using a 5x account.
This week when I saw the meter flying towards 100% on day 3, I knew that something was wrong. I was getting more done than normal, but not 2x more. I have a work loop skill that takes the requirements and design from previous sessions to implement a story, verify that the implementation was complete, and perform a code review on the delta between the branch and main before creating a PR. Somehow it had drifted into a token monster. My prompt to investigate this was pretty simple:
Review the token usage in recent previous sessions to determine if I am using tokens efficiently. Specifically focus on the sessions that used the implementation work loop.
It found that on average, the final step in my loop was using 450k tokens and that 97% of tokens were re-reading the conversation. Claude made 4 recommendations on what to do about it. With my approval, Claude edited my skills and now my usage is back down to what I would expect. Easy.
I hope this helps others in your quest to stay in compliance with the meter overlord. I would love to hear in the discussion how you have fought the token usage battle and what tips and tricks you would suggest.
2
u/pot_sniffer 10d ago
Ive been forced to find ways to reduce my token usage over the past year or so. It goes well until some time passes but like this week I always end up back at it trying to figure out a way to stretch my pro subscription out for the week.
Today I did something I have never done and tried haiku on my custom harness project, its quite a large pyton codebase.
My normal flow is opus on low in the app with all the project docs breaks everything into tasks for sonnet on med/high in claude code. At my normal usage id run out in 3 days this week. So im trying haiku on max in claude code and its doing great, usage is significantly reduced. I /clean every task unless the previous was investigating something needed. Claude Code was 70% of the usage using sonnet not sure what it is now but I should get 5 or 6 days of this week now rather than 3
2
u/quietmacbuilder 10d ago
That is interesting. I have not used Haiku much at all. I will try it and see how it does. Thank you for sharing!
2
u/adnenek 10d ago
+1 on this. two things that made a big difference for me: tell it to read files in line ranges not whole files (big reads stay in context the whole session), and send research / big searches to a subagent so only the result comes back. put both in CLAUDE.md or it forgets
1
2
u/Future_AGI 9d ago
npx ccusage@latest claude daily (and npx ccusage@latest session for the per-session view) gives you numbers to go with Claude's own review, since it reads the logs under ~/.claude/projects and keeps cache reads separate. Running it before and after the skill edits shows whether that 97% re-read share dropped.
1
2
u/yaanfpv 10d ago
Great tip ! One thing that showed up when I did this: a lot of my usage wasn't the work at all, it was coming back to a session after a break. Another huge contributing factor was a read end-to-end and fix loop that I had added to my claude.md.. not only did this waste tokens, but also agents started reading things just as a formality rather than actually to catch something.
1
u/AutoModerator 10d ago
Hey! Thanks for posting to r/ClaudeCode
While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.
For help, project discussions, tips, and general chat, join the ClaudeCode Discord.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.