# Qwen model speaking tool call JSON out loud instead of executing

**URL:** <https://community.livekit.io/t/qwen-model-speaking-tool-call-json-out-loud-instead-of-executing/146>\
**Category:** Agents\
**Tags:** llm, groq\
**Created:** [January 21, 2026, 1:34pm UTC](https://community.livekit.io/t/qwen-model-speaking-tool-call-json-out-loud-instead-of-executing/146 "2026-01-21T13:34:29Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![LiveKit-Community](https://sea1.discourse-cdn.com/flex001/user_avatar/community.livekit.io/livekit-community/32/67_2.png) [@LiveKit-Community](https://community.livekit.io/u/LiveKit-Community)\
**Post date:** [January 21, 2026, 1:34pm UTC](https://community.livekit.io/t/qwen-model-speaking-tool-call-json-out-loud-instead-of-executing/146/1 "2026-01-21T13:34:29Z")

</div>

_This question originally came up in our Slack community and the thread has been consolidated here for long-term reference._

I’m using qwen3-32B LLM via the Groq plugin, but tool calling is broken. The agent speaks the tool call JSON out loud:

```auto
<tool_call>
{"name": "end_call", "arguments": {}}
</tool_call>

```

It was working fine with Gemini model.

---

<div class="post-metadata">

**Author:** ![LiveKit-Community](https://sea1.discourse-cdn.com/flex001/user_avatar/community.livekit.io/livekit-community/32/67_2.png) [@LiveKit-Community](https://community.livekit.io/u/LiveKit-Community)\
**Post date:** [January 21, 2026, 1:34pm UTC](https://community.livekit.io/t/qwen-model-speaking-tool-call-json-out-loud-instead-of-executing/146/2 "2026-01-21T13:34:32Z")

</div>

Two suggestions for fixing Qwen tool calling:

1. **Set `tool_choice` to `required`** : Instead of `auto`, this forces the model to use tools properly.  
[Groq LLM plugin guide | LiveKit Documentation](https://docs.livekit.io/agents/models/llm/plugins/groq/#parameters)

2. **Pass the `raw_schema` parameter** : Ensure your function schema matches Qwen’s expectations by passing `raw_schema` to the `@function_tool` decorator.  
[Function Calling - Qwen](https://qwen.readthedocs.io/en/latest/framework/function_call.html#the-example-case)
