Run the tool.
run(
self,
tool_input: str | dict[str, Any],
verbose: bool | None = None,
start_color: str | None = 'green',
color: str | None = 'green',
callbacks: Callbacks = None,
*,
tags: list[str] | None = None,
metadata: dict[str, Any] | None = None,
run_name: str | None = None,
run_id: uuid.UUID | None = None,
config: RunnableConfig | None = None,
tool_call_id: str | None = None,
**kwargs: Any = {}
) -> Any| Name | Type | Description |
|---|---|---|
tool_input* | str | dict[str, Any] | The input to the tool. |
verbose | bool | None | Default: NoneWhether to log the tool's progress. |
start_color | str | None | Default: 'green'The color to use when starting the tool. |
color | str | None | Default: 'green'The color to use when ending the tool. |
callbacks | Callbacks | Default: NoneCallbacks to be called during tool execution. |
tags | list[str] | None | Default: NoneOptional list of tags associated with the tool. |
metadata | dict[str, Any] | None | Default: NoneOptional metadata associated with the tool. |
run_name | str | None | Default: NoneThe name of the run. |
run_id | uuid.UUID | None | Default: NoneThe id of the run. |
config | RunnableConfig | None | Default: NoneThe configuration for the tool. |
tool_call_id | str | None | Default: NoneThe id of the tool call. |
**kwargs | Any | Default: {}Keyword arguments to be passed to tool callbacks (event handler) |