From the course: Gemini API: Tool and Function Calling

Unlock this course with a free trial

Join today to access over 25,500 courses taught by industry experts.

Multi-turn function call

Multi-turn function call

- [Instructor] So we have looked at single-turn function calling. And one thing that was mentioned in that lesson is that in single-turn function calling one function is enough to fulfill the user's request. But what if the user's query requires more than one function? And this functions need to work hand-in-hand to fulfill the user's request. In comes multi-turn function calling. A multi-turn function call is a more advanced and powerful workflow that enables the model and your application to have an extended back and forth conversation to complete a complex task. This is essential for building sophisticated conversational agents that can undo multi-step requests. Let's take a look at how it works. The process starts with a user's request that is too complex or lacks necessary information for a single function call. For example, a user might say, "Plan a trip for me." The model can't fulfill this request with a…

Contents