client icon indicating copy to clipboard operation
client copied to clipboard

Fix: `$acceptedPredictionTokens must be of type int, null given` | #524 😇

Open 200-0K opened this issue 11 months ago • 2 comments

What:

  • [x] Bug Fix
  • [ ] New Feature

Description:

Fix $acceptedPredictionTokens must be of type int, null given error for deepseek-reasoner model

Related:

#524

200-0K avatar Feb 17 '25 16:02 200-0K

I request this change be merged.

chuoke avatar Feb 24 '25 06:02 chuoke

I fixed it on my end slightly differently. I only changed line 24 and 25 to "?? 0" instead of "?? null" and then changing the declaration on the top to be nullable.

I think your fix might be better. I too vote that this fix be merged.

+1 vote for me, as openrouter followed suit and also no longer send this attribute back in the response, as of yesterday.

nycomar avatar Mar 20 '25 08:03 nycomar

This was fixed already in this PR and released in v0.13 - https://github.com/openai-php/client/pull/560

Closing.

iBotPeaches avatar May 27 '25 11:05 iBotPeaches