Create a ToolCall.
create_tool_call(
name: str,
args: dict[str, Any],
*,
id: str | None = None,
index: int | str | None = None,
**kwargs: Any = {}
) -> ToolCallThe id is generated automatically if not provided, using a UUID4 format
prefixed with 'lc_' to indicate it is a LangChain-generated ID.
| Name | Type | Description |
|---|---|---|
name* | str | The name of the tool to be called. |
args* | dict[str, Any] | The arguments to the tool call. |
id | str | None | Default: NoneAn identifier for the tool call. Generated automatically if not provided. |
index | int | str | None | Default: NoneIndex of block in aggregate response. Used during streaming. |