Cost is dropping dramatically when opencode is finishing up. #351

Closed
opened 2026-02-16 17:26:23 -05:00 by yindo · 5 comments
Owner

Originally created by @AsocPro on GitHub (Jun 27, 2025).

I am seeing weird things with the cost counter. I am using the Anthropic API token with CLaude Sonnet 3.7 on opencode v0.1.157. I was watching the cost in the lower left on a request and it was slowly going up to about 72 cents. Then all of a sudden right as opencode was done and it was giving me a summary of what it did the cost went down to 22 cents. The Anthropic console seemed to line up right with the 72ish cents used but I wasn't paying full attention. I took notes of my balance and then I kicked off another smaller request and it did the same thing although this time it went up to 12 cents then when it was summarizing it went down to 4 cents and the anthropic console said 15 cents had been used.

If there is any other data that would be helpful to diagnose let me know and I can get you more information.

Originally created by @AsocPro on GitHub (Jun 27, 2025). I am seeing weird things with the cost counter. I am using the Anthropic API token with CLaude Sonnet 3.7 on opencode v0.1.157. I was watching the cost in the lower left on a request and it was slowly going up to about 72 cents. Then all of a sudden right as opencode was done and it was giving me a summary of what it did the cost went down to 22 cents. The Anthropic console seemed to line up right with the 72ish cents used but I wasn't paying full attention. I took notes of my balance and then I kicked off another smaller request and it did the same thing although this time it went up to 12 cents then when it was summarizing it went down to 4 cents and the anthropic console said 15 cents had been used. If there is any other data that would be helpful to diagnose let me know and I can get you more information.
yindo closed this issue 2026-02-16 17:26:23 -05:00
Author
Owner

@aspiers commented on GitHub (Jun 29, 2025):

I see this too, and it's even visible in this very public YouTube video:

https://youtu.be/ftGPty-dQR8?si=l_fF6j8BTYgcT_Fy&t=1849

You can see it climbs from $0.13 to $0.15 and then suddenly drops to $0.05 at 30:53, resulting in Theo praising it for being so cheap (although to be far even if it was $0.15 this still beat Claude Code and Gemini CLI).

@aspiers commented on GitHub (Jun 29, 2025): I see this too, and it's even visible in this very public YouTube video: https://youtu.be/ftGPty-dQR8?si=l_fF6j8BTYgcT_Fy&t=1849 You can see it climbs from $0.13 to $0.15 and then suddenly drops to $0.05 at 30:53, resulting in [Theo praising it for being so cheap](https://youtu.be/ftGPty-dQR8?si=WZPxvpECEU1c6XMh&t=1909) (although to be far even if it was $0.15 this still beat Claude Code and Gemini CLI).
Author
Owner

@aspiers commented on GitHub (Jun 29, 2025):

See also #454.

@aspiers commented on GitHub (Jun 29, 2025): See also #454.
Author
Owner

@aspiers commented on GitHub (Jun 29, 2025):

Just a wild guess, but I wonder if this is perhaps related to #534?

@aspiers commented on GitHub (Jun 29, 2025): Just a wild guess, but I wonder if this is perhaps related to #534?
Author
Owner

@thdxr commented on GitHub (Jun 29, 2025):

this should be fixed now

@thdxr commented on GitHub (Jun 29, 2025): this should be fixed now
Author
Owner

@tymscar commented on GitHub (Aug 3, 2025):

I can confirm this is still an issue on v0.3.126.

It said I have used $5.25, and in reality I used closer to $1.25

@tymscar commented on GitHub (Aug 3, 2025): I can confirm this is still an issue on v0.3.126. It said I have used $5.25, and in reality I used closer to $1.25
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#351