-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
Based on this list of tool-calling models, only the Hermes-2-Pro-Mistral-7B-q4f16_1-MLC
model actually outputs proper JSON.
The other models always just output an empty array: []
. This is also happening in your function calling example.
However, the "working" model ALWAYS outputs structured JSON (tries to call a tool) even if the user message doesn't explicitly prompts it to.
It also always disregards the tool_choice
set. Also even if it is set to none
, it will always output structured data.
To replicate this, you can run the function-calling-openai
example. The specified model will always output []
. Change it to Hermes-2-Pro-Mistral-7B-q4f16_1-MLC
and it will always output structured data, even if the user message is changed to something like Hey
and the tool_choice
is set to none
.
Maybe we could remove the manual checks and just allow tool calling for all models?
For instance reasoning models (such as Qwen3) are particularly good at executing tool calls, and it's a shame that we don't allow using those models for it.