BroadRouter
Get started

Parallel tool calls

Updated

Parallel tool calls are when a model returns more than one tool call in a single response, for example three file reads at once. In the OpenAI format they arrive as several entries in tool_calls, and parallel_tool_calls set to false limits the model to zero or one call per turn.

Also called: parallel tool calling, parallel function calling, parallel_tool_calls, multiple tool calls

An agent that needs three files does not have to ask for them one round trip at a time. With parallel tool calls the model asks for all three at once.

How it works

In a tool calling response, message.tool_calls is a list. With parallel calls it has more than one entry, each with its own id, function name and JSON arguments.

"tool_calls": [
  {"id": "call_1", "type": "function", "function": {"name": "read_file", "arguments": "{\"path\": \"a.py\"}"}},
  {"id": "call_2", "type": "function", "function": {"name": "read_file", "arguments": "{\"path\": \"b.py\"}"}}
]

Your code runs the calls and appends one tool message per call, each with the matching tool_call_id, then calls the model again.

  • OpenAI: parallel_tool_calls defaults to true. Setting it to false “ensures exactly zero or one tool is called.” The guide warns that one model snapshot sometimes repeated calls to the same tool and recommends turning the feature off there.
  • Anthropic: parallel use is on by default. Turn it off with disable_parallel_tool_use: true inside the tool_choice object. Anthropic says the API “doesn’t prescribe an execution order”, and that all tool results should come back in a single user message to keep parallelism working.

Why it matters

  • Latency. Fewer model round trips. Independent, read-only tools can run at the same time on your side.
  • Ordering. Calls with side effects, such as write then read, may depend on each other. Anthropic suggests running those sequentially. Or turn the feature off.
  • Bookkeeping. Every call needs a result with the right ID. A missing result is a common cause of the next request failing.

On BroadNet Inference

BroadNet’s API reference documents tool calling for GLM 5.3 and Qwen3.8 27B and does not document parallel_tool_calls. Test whether your prompt gets several calls back and whether false is honoured. Parallel calls arrive in one response, so they do not add to your request count. Running the tools is on your side. Note that a BroadNet unlimited plan session allows one request at a time, and is for DeepSeek V4.1 Flash only; on pay-as-you-go keys the concurrency limit is 4 requests in flight. The open-model tool calling post has a working loop.

Common mistakes

  • Returning results in a different message format for each call, or dropping one.
  • Running dependent tools concurrently because the model listed them together.

Questions

Do parallel tool calls mean parallel API requests?

No. The model returns several calls in one response. Your code runs them, concurrently or one by one, and sends all the results back in the next request.

How do I turn parallel tool calls off?

In the OpenAI format set parallel_tool_calls to false; OpenAI says this "ensures exactly zero or one tool is called." In Anthropic's API set disable_parallel_tool_use to true inside tool_choice.

Does BroadNet Inference support parallel_tool_calls?

BroadNet's API reference does not document parallel_tool_calls. Tool calling is documented for GLM 5.3 and Qwen3.8 27B; test whether they return several calls and whether the flag is honoured.

Read as MarkdownAsk ChatGPTAsk ClaudeAsk Perplexity