formatting

This commit is contained in:
Ahmed Tammaa 2025-07-13 02:13:41 +03:00
parent d75d2d43e9
commit 758c59fc31

View File

@ -1870,11 +1870,12 @@ class BaseChatOpenAI(BaseChatModel):
"schema must be specified when method is not 'json_mode'. "
"Received None."
)
tool_name = convert_to_openai_tool(schema)["function"]["name"]
base_url = (
getattr(self, "openai_api_base", "")
or getattr(self, "api_base", "") or ""
or getattr(self, "api_base", "")
or ""
).lower()
# The Azure-Hosted Models routes to this function
# so we need to set the tool_choice to required