gemini-ai icon indicating copy to clipboard operation
gemini-ai copied to clipboard

Function calling support

Open XInTheDark opened this issue 1 year ago • 2 comments

Hi, is there any possibility of supporting function calling (beta)? For example, my use case is to add web search capability to the AI.

Some relevant docs & examples: https://ai.google.dev/gemini-api/docs/function-calling https://ai.google.dev/gemini-api/docs/function-calling#function-calling-curl-samples https://ai.google.dev/gemini-api/docs/function-calling#multi-turn-example-1

XInTheDark avatar Jun 01 '24 05:06 XInTheDark

This is on my roadmap. However, it may take some time to implement, as I am going out on a trip soon.

Here's a roadmap of what I am doing right now:

  • Safety Settings (Already on GitHub, not yet published)
  • System Prompt (Will be on GitHub soon)
  • JSON Schema Response (Haven't started)
  • Function Calling (Haven't started)

EvanZhouDev avatar Jun 01 '24 22:06 EvanZhouDev

Quick update! Safety Settings, System Prompt, and JSON Schema Response have all been deployed in v2.2.

I have not yet started Function Calling, and as I am going on vacation, I may be away for a while. The other reason I am reluctant to start implementing this is that it is quite a major change to the API, and given that the system is still in Beta, and potentially subject to changes, I will likely hold off until they get a stable release.

EvanZhouDev avatar Jun 02 '24 21:06 EvanZhouDev