Fix Google provider tool formatting - pass function declarations directly...

Fix Google provider tool formatting - pass function declarations directly instead of wrapping in dict
parent 8d6b8de7
...@@ -312,8 +312,8 @@ class GoogleProviderHandler(BaseProviderHandler): ...@@ -312,8 +312,8 @@ class GoogleProviderHandler(BaseProviderHandler):
logging.info(f"GoogleProviderHandler: Converted tool to Google format: {function_declaration}") logging.info(f"GoogleProviderHandler: Converted tool to Google format: {function_declaration}")
if function_declarations: if function_declarations:
google_tools = {"function_declarations": function_declarations} # Google API expects tools to be a list of tool declarations directly
config["tools"] = [google_tools] config["tools"] = function_declarations
logging.info(f"GoogleProviderHandler: Added {len(function_declarations)} tools to config") logging.info(f"GoogleProviderHandler: Added {len(function_declarations)} tools to config")
# Handle streaming request # Handle streaming request
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment