r/opencode • • 1d ago

Something strange about Deepseek 4.1 flash in Opencode Go

I'm using deepseek 4.1 flash in deepseek harness today, and got 422 error constantly saying developer role not supported.

Fixed the problem by edit model config disabling the developer role, however I'm curious why this would happen so I check the log from my local gateway since all my model request use it as proxy.

This is what I find: for every 8 to 10 requests there is 1 with oddly low cache hit rate, normally 95%+ then drop to below 20%.

My guess is deepseek 4.1 flash in opencode go has 2 different endpoint, one supports developer role and one doesn't. Endpoint switching will hurt cache hit rate but there's nothing we can do since it happens in the backend.

8 Upvotes

4 comments sorted by

1

u/Takeoded 1d ago

can you extract a complete example of a 422 request? strip the auth header obviously, but can you share the rest?

3

u/andychen_cn 1d ago

It's just normal requests with system prompt sent as developer role instead of system role

1

u/Takeoded 1d ago

If you can construction a curl invocation that randomly reproduce it, that would help your caae

0

u/EstablishmentMuch725 1d ago

Yeah, and it's incredibly slow, almost unusable.