Fix parallel_tool_calls when False#333
Merged
rm-openai merged 1 commit intoopenai:mainfrom Mar 25, 2025
Merged
Conversation
rm-openai
approved these changes
Mar 25, 2025
Collaborator
|
Thanks for fixing! |
rm-openai
pushed a commit
that referenced
this pull request
Apr 15, 2025
The current ChatCompletion API supports only `parallel_tool_calls=True` or `parallel_tool_calls=NOT_GIVEN` This PR is to support setting `parallel_tool_calls=False`, a common requirement in controlling agent tool use patterns (e.g. ensuring one tool call at the time, to facilitate desired tool calling sequence). I followed the merged [PR#333](#333) for consistency.
gold-crow-997
added a commit
to gold-crow-997/open-ai-agent
that referenced
this pull request
Sep 11, 2025
The current ChatCompletion API supports only `parallel_tool_calls=True` or `parallel_tool_calls=NOT_GIVEN` This PR is to support setting `parallel_tool_calls=False`, a common requirement in controlling agent tool use patterns (e.g. ensuring one tool call at the time, to facilitate desired tool calling sequence). I followed the merged [PR#333](openai/openai-agents-python#333) for consistency.
JwCwn
added a commit
to JwCwn/open-ai-agents-python
that referenced
this pull request
Dec 23, 2025
The current ChatCompletion API supports only `parallel_tool_calls=True` or `parallel_tool_calls=NOT_GIVEN` This PR is to support setting `parallel_tool_calls=False`, a common requirement in controlling agent tool use patterns (e.g. ensuring one tool call at the time, to facilitate desired tool calling sequence). I followed the merged [PR#333](openai/openai-agents-python#333) for consistency.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, when we set
parallel_tool_calls=Falsein themodel_settings, the responses API is called withparallel_tool_calls == NotGiven, which defaults to true on the Response API side (https://platform.openai.com/docs/api-reference/responses/create#responses-create-parallel_tool_calls).This PR attempts to fix that.