message":"tool call validation failed: parameters for tool bash did not match schema: errors:,,,, #843

Open
opened 2026-02-16 17:28:31 -05:00 by yindo · 9 comments
Owner

Originally created by @fractalswift on GitHub (Jul 21, 2025).

Originally assigned to: @thdxr on GitHub.

seem to get this a bunch with Kimi instruct, but switching models to claude doesn't help (just get an api error after).

Image

This is what it changes to after switching to sonnet:

Image

Macbook with ghostty

Originally created by @fractalswift on GitHub (Jul 21, 2025). Originally assigned to: @thdxr on GitHub. seem to get this a bunch with Kimi instruct, but switching models to claude doesn't help (just get an api error after). <img width="1401" height="578" alt="Image" src="https://github.com/user-attachments/assets/301e4bdc-fa58-4820-8870-5aec85404a92" /> This is what it changes to after switching to sonnet: <img width="1401" height="312" alt="Image" src="https://github.com/user-attachments/assets/974ac574-ec0a-462a-8109-bca77e2f317b" /> Macbook with ghostty
Author
Owner

@thdxr commented on GitHub (Jul 21, 2025):

ah so reusing the same message history with different providers can fail because tool call id formats. interesting not sure how to resovle this

@thdxr commented on GitHub (Jul 21, 2025): ah so reusing the same message history with different providers can fail because tool call id formats. interesting not sure how to resovle this
Author
Owner

@fractalswift commented on GitHub (Jul 29, 2025):

sorry for the slow reply but this doesn't always happen with different providers. For example I've been using only Kimi for this one and only in Build Mode and it's just started giving me this. I deliberately have not changed models at all.

Image
@fractalswift commented on GitHub (Jul 29, 2025): sorry for the slow reply but this doesn't always happen with different providers. For example I've been using only Kimi for this one and only in Build Mode and it's just started giving me this. I deliberately have not changed models at all. <img width="1440" height="932" alt="Image" src="https://github.com/user-attachments/assets/56338714-2917-4f44-96be-87fb9ed0fb3f" />
Author
Owner

@mybuddymichael commented on GitHub (Aug 19, 2025):

I'm also seeing this, using qwen3-32b via Groq. Only one provider and model in the thread.

{"message":"tool call validation failed: parameters for tool bash did not match schema:
errors: [missing properties: 'description']","type":"invalid_request_error"}
@mybuddymichael commented on GitHub (Aug 19, 2025): I'm also seeing this, using qwen3-32b via Groq. Only one provider and model in the thread. ``` {"message":"tool call validation failed: parameters for tool bash did not match schema: errors: [missing properties: 'description']","type":"invalid_request_error"} ```
Author
Owner

@njbrake commented on GitHub (Oct 28, 2025):

FWIW, same problems for me:

opencode version 0.15.18, using Groq provider, and a new session (/clear)

Please implement support for batch completions in any_llm. @src/any_llm/api.py you'll need to add a new input fn to the api

 txt  src/any_llm/api.py

nbrake (08:31 AM)

Thinking...

We need to add support for batch completions in any_llm. The code already has batch_completion and abatch_completion functions defined at lines 44-70 and 33-62 etc. But the question likely indicates that
the API currently does not support batch completions; perhaps the provider classes need to implement batch_completion methods. Need to implement new input fn to the API: maybe adding new input function
"batch_completion" to expose via any_llm API, but it's already there. The user says "implement support for batch completions in any_llm. @src/any_llm/api.py you'll need to add a new input fn to the api
Called the Read tool with the following input: ..."

So maybe need to expose batch_completion and abatch_completion to the AnyLLM public API; currently any_llm/api.py has those functions but they are not part of AnyLLM class. Wait, the AnyLLM class
probably has methods completion, acompletion, etc. But maybe the provider implementations need batch_completion support.

We need to check src/any_llm/any_llm.py.
Build openai/gpt-oss-20b (08:32 AM)

{"message":"Tool call validation failed: tool call validation failed: parameters for tool read did not match schema: errors: [additionalProperties 'lineCount', 'lineNumber' not
allowed]","type":"invalid_request_error"}
Image

Trying to use opencode to implement https://github.com/mozilla-ai/any-llm/issues/54

@njbrake commented on GitHub (Oct 28, 2025): FWIW, same problems for me: opencode version 0.15.18, using Groq provider, and a new session (/clear) ``` Please implement support for batch completions in any_llm. @src/any_llm/api.py you'll need to add a new input fn to the api txt src/any_llm/api.py nbrake (08:31 AM) Thinking... We need to add support for batch completions in any_llm. The code already has batch_completion and abatch_completion functions defined at lines 44-70 and 33-62 etc. But the question likely indicates that the API currently does not support batch completions; perhaps the provider classes need to implement batch_completion methods. Need to implement new input fn to the API: maybe adding new input function "batch_completion" to expose via any_llm API, but it's already there. The user says "implement support for batch completions in any_llm. @src/any_llm/api.py you'll need to add a new input fn to the api Called the Read tool with the following input: ..." So maybe need to expose batch_completion and abatch_completion to the AnyLLM public API; currently any_llm/api.py has those functions but they are not part of AnyLLM class. Wait, the AnyLLM class probably has methods completion, acompletion, etc. But maybe the provider implementations need batch_completion support. We need to check src/any_llm/any_llm.py. Build openai/gpt-oss-20b (08:32 AM) {"message":"Tool call validation failed: tool call validation failed: parameters for tool read did not match schema: errors: [additionalProperties 'lineCount', 'lineNumber' not allowed]","type":"invalid_request_error"} ``` <img width="1236" height="732" alt="Image" src="https://github.com/user-attachments/assets/ea402dbb-43ab-4d51-bc1f-3e5f4f56624c" /> Trying to use opencode to implement https://github.com/mozilla-ai/any-llm/issues/54
Author
Owner

@rekram1-node commented on GitHub (Oct 28, 2025):

I believe this is the model failing to call the tool, you should be able to continue the session by sending follow up messages.

@rekram1-node commented on GitHub (Oct 28, 2025): I believe this is the model failing to call the tool, you should be able to continue the session by sending follow up messages.
Author
Owner

@njbrake commented on GitHub (Oct 28, 2025):

Thanks for the fast response! The part that confuses me here is that if I run gpt-oss-20b locally in LMStudio, everything works fine. So it leads me to believe that its not an issue with the model, but either with the interface between opencode and groq, or the way that groq is exposing gpt-oss-20b to be used.

I wouldn't have expected any quality degradation of the model in groq, since the model comparison spec in artificial analysis says gpt-oss-20b in Groq matches performance. https://artificialanalysis.ai/models/gpt-oss-20b/providers

(I should note that I tried a few different models in Groq (qwen and Kimi K2) and they exhibited the same failures)

@njbrake commented on GitHub (Oct 28, 2025): Thanks for the fast response! The part that confuses me here is that if I run gpt-oss-20b locally in LMStudio, everything works fine. So it leads me to believe that its not an issue with the model, but either with the interface between opencode and groq, or the way that groq is exposing gpt-oss-20b to be used. I wouldn't have expected any quality degradation of the model in groq, since the model comparison spec in artificial analysis says gpt-oss-20b in Groq matches performance. https://artificialanalysis.ai/models/gpt-oss-20b/providers (I should note that I tried a few different models in Groq (qwen and Kimi K2) and they exhibited the same failures)
Author
Owner

@rekram1-node commented on GitHub (Oct 28, 2025):

Some people on the team actually tested groq as a provider for Zen, but they found these tool calling failures to be more frequent. I think groq was working on some improvements tho.

Certain providers host the OSS models differently than others and they will fail tool calls more frequently

@rekram1-node commented on GitHub (Oct 28, 2025): Some people on the team actually tested groq as a provider for Zen, but they found these tool calling failures to be more frequent. I think groq was working on some improvements tho. Certain providers host the OSS models differently than others and they will fail tool calls more frequently
Author
Owner

@msTokens commented on GitHub (Nov 9, 2025):

easy 🗡️

['disable_tool_validation'] = True

on requests to groq bye.

@msTokens commented on GitHub (Nov 9, 2025): easy 🗡️ ['disable_tool_validation'] = True on requests to groq bye.
Author
Owner

@mangeshgosavi129 commented on GitHub (Jan 26, 2026):

Has anyone tried "easy 🗡️

['disable_tool_validation'] = True

on requests to groq bye.”
this?
any success?

@mangeshgosavi129 commented on GitHub (Jan 26, 2026): Has anyone tried "easy 🗡️ ['disable_tool_validation'] = True on requests to groq bye.” this? any success?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#843