mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-15 19:37:47 +01:00
chore: format
This commit is contained in:
@@ -442,12 +442,10 @@ async def chat_completion_tools_handler(
|
||||
tool_function = tools[tool_function_name]["callable"]
|
||||
sig = inspect.signature(tool_function)
|
||||
tool_function_params = {
|
||||
k: v
|
||||
for k, v in tool_function_params.items()
|
||||
if k in sig.parameters
|
||||
k: v for k, v in tool_function_params.items() if k in sig.parameters
|
||||
}
|
||||
tool_output = await tool_function(**tool_function_params)
|
||||
|
||||
|
||||
except Exception as e:
|
||||
tool_output = str(e)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user