-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Complex datatypes like List, Dict or Pydantic Objects are not understood by Phidata while registering tools with Gemini. Works for OpenAI. #1759
Comments
If I make the
I feel the issue is in this function which is supposed to covert the params to Gemini compatible params. Its not doing that properly for all cases. Its not going recursively down, like params could be List of List of Dict of str to number. This method just look at top level, means it will work for simple cases like List[str] or List[int] et, not for complex data types. I think it should recursive approach. |
Hey @gauravdhiman, thank you for bringing this up! I’m currently working on a fix. Could you please share the debug logs when using your Custom Tool with OpenAI? I’d like to review the tool calls made by the model. |
Here is the complete run log, when the tool signature is this
|
@gauravdhiman can you please share the debug logs for the Agent with a pydantic class in the tool definition running with |
I have a tool with below interface:
In agent, if I use Gemini model like this, it fails but if I use OpenAI model, it works. No other change, just change in model.
I am using this Gemini provider class:
Gemini model fails while determining tool definition with below err:
For debugging, I printed this:
I printed this within this if condition, and this is what it prints:
The text was updated successfully, but these errors were encountered: