mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-12-03 01:48:05 +00:00
Document behavior of parallel_tool_calls parameter
Added clarification on the behavior of the `parallel_tool_calls` parameter and its impact on function calling workflows.
This commit is contained in:
parent
01836e7926
commit
b866ecddbf
1 changed files with 16 additions and 0 deletions
|
|
@ -289,3 +289,19 @@ The `require_approval` parameter for MCP tools in the Responses API now works co
|
|||
**Fixed in:** [#3003](https://github.com/llamastack/llama-stack/pull/3003) (Agent API), [#3602](https://github.com/llamastack/llama-stack/pull/3602) (Responses API)
|
||||
|
||||
MCP tools now correctly handle array-type arguments in both the Agent API and Responses API.
|
||||
|
||||
---
|
||||
|
||||
### Parallel tool calls
|
||||
|
||||
**Status:** ✅ Resolved
|
||||
|
||||
The [`parallel_tool_calls` parameter](https://platform.openai.com/docs/api-reference/responses/create#responses_create-parallel_tool_calls) controls turn-based function calling workflows, _not_ parallelism or concurrency. See the [related function calling documentation](https://platform.openai.com/docs/guides/function-calling#parallel-function-calling).
|
||||
|
||||
If `parallel_tool_calls=false`, the intended behavior is that multiple generated functional calls will be executed once per turn until done; the client is responsible for executing them one at a time and returning the result, in the expected format, in order to proceed.
|
||||
|
||||
For example, with a custom tool generation request with a `get_weather` function definition, the input of "What is the weather in Tokyo and New York?" will, by default, cause two function calls to be generated - a `get_weather` function call definition for each of `Paris` and `New York`. With `parallel_tool_calls = false`, however, only one of these will be generated initially; the client is then responsible for executing that function call and appending the results to the message history, after which the conversation will proceed with the model-generated second function tool call definition.
|
||||
|
||||
| parallel_tool_calls=true | parallel_tool_calls=false |
|
||||
|------|-------|
|
||||
| <img width="1134" height="1330" alt="Image" src="https://github.com/user-attachments/assets/68b5d6f0-0407-4926-9634-228512aa420d" /> | <img width="1236" height="1868" alt="Image" src="https://github.com/user-attachments/assets/42a1243c-4268-40d0-abcf-ad1bf9abc9c0" /> |
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue