-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Open
Labels
Description
Describe the feature
In the @function_tool
is it possible to provide custom failure_error_function: ToolErrorFunction | None = default_tool_error_function
.
However, when trying to init FunctionTool via class FunctionTool
it is not possible to configure failure_error_function
and the default one is used.
Please, add support of ToolErrorFunction
configuration in class FunctionTool
Expected result:
function_tool = FunctionTool(
name=action.name,
description=action.description,
params_json_schema=schema,
on_invoke_tool=handle_tool_call_invoke,
failure_error_function=tool_error_function <---- new field
)