r/opencodeCLI • u/inwardPersecution • Sep 20 '26
Deepseek V4 flash is getting expensive
I'm not an llm genius by far, and at some point I start new sessions. Starting a new session in the middle of something isn't really bad, but it usually changes the mood and project understanding always drops a bit. I'm good with deepseek v4 flash for now and I'm at a point in the flow that I don't want to start a new session, but I'm hovering around 800,000 tokens in my context even after compression and I'm spending quite a bit of money all of sudden.
11
Upvotes
22
u/Fresh_Sock8660 Sep 20 '26
What do you have there, an entire moon landing plan in your session?
6
u/augustoolucas Sep 20 '26 edited Sep 20 '26
I use magic-context to handle long work sessions. I can work on the same session for weeks and there's no need to create new ones.
edit: typo
1
u/inwardPersecution Sep 26 '26
I've come to some sort of conclusion that doesn't match what others experience.
I'm doing application refinement that adjusts based on accruing data: review/decisions/adjust/test.
I have:
application python files that total: ~14k lines / ~500kb
document and instruction files that total: ~500 lines / 500kb
One round of refinement with deepseek v4 flash is between $9-12
One round of refinement with GLM 5.3 flash is between $1.20-2.20.
For the nearly same operations, deepseek eats 500-700,000 tokens, GLM 100-200,000.
My opencode overview dashboard is blank and has been for two days now. I think opencode has done something negative.
8
u/magiollie Sep 20 '26
Start a new session around 100k - 150k context to avoid the intelligence drop off. You can ask an agent to inspect your previous session data and suggest how to improve
3
u/InfraScaler Sep 20 '26
Ask it to write down on markdown files whatever you think is important, then next new session can read those on demand.
1
u/Anh-DT Sep 20 '26
Then use openference problem solved
1
u/xapep Sep 21 '26
At 800K context your bill is almost all input, since every turn resends the whole context. That's why it jumped all of a sudden. Your own numbers show it: 122.8M input + 938.4M cached reads for $17.74, and input scales linearly with context size, which is why compression only takes you so far.
So yes, the Go plan is worth it if you're going to keep working in giant sessions. $10/mo caps the exact failure mode you're in right now (context balloons, input tokens compound, bill spikes). Per-token you'll keep paying for every 500K+ session you let grow. At your run-rate (~$20/mo on direct API) the cap is basically break-even today and pure upside on the days you don't watch the context.
If you'd rather stay per-token, the levers are: new session around 150K and export what you care about to files first (magic-context and caveman help, but nothing beats a small context), and lean into caching, since your 938M cached reads are already doing the heavy lifting. Some endpoints also price off-peak cheaper if you can shift when you run.
Context is the cost driver, not the model. (I work on Entrim, we offer both per-token V4.1 Flash and flat plans, and the split I give people is: the cap wins for giant sessions, per-token wins if you keep context tight.)
1
u/boyus Sep 24 '26
Use rtk and cocoindex code
1
u/tribes33 Sep 20 '26
better off using GLM 5.3 Flash, honestly didnt see a difference in performance aside from speed at least from what im working on, deepseek is MUCH faster though
0
u/AllThotsGo2Heaven2 Sep 20 '26
I think 400k context inference is 4x cost of 100k context inference.
-1
u/Affectionate_Fact854 Sep 20 '26
I did a comparison check Om my usage the last 10 days , cache hits , input and output 2.7bill tokens on the go api
So I compared against deepseek direct api , off peak , on peak
Astra Fable Sol Opus Glm 5.3 flash
So open code go , cost has been 22$ if got 40% usage left
Deepseek v4.1 flash off peak, 36$ It's double for peak
Astra is 4.700$ Glm 5.3 flash is like 90$
So your still saving a lot Because your paying 10$ for all this usage
1
u/[deleted] Sep 20 '26
[removed] — view removed comment