googleapis / googleapis/python-genai

Add the ability to disable parallel tool calls

Open
#1,831 13 comments 13 reactions 1 assignee Claimed by @Venkaiahbabuneelam View on GitHub
priority: p3 type: feature request
Dominant language
Python
Stars
4k
Forks
1k
Avg merge
2d 11h
Merged PRs (30d)
40

Description

Gemini models can parallelize function calls, I have a use case where tools must be executed sequentially, and the model frequently ignores system prompts to "run one at a time."

Please add a parameter that forces the model to generate only one tool call per turn at the API level.

This is already implemented by [OpenAI](https://platform.openai.com/docs/guides/function-calling#parallel-function-calling) and [Anthropic](https://platform.claude.com/docs/en/agents-and-tools/tool-use/implement-tool-use#parallel-tool-use)

Thanks!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.