import { ... } from "@langchain/core/messages/tool";Marker parameter for objects that tools can return directly.
If a custom BaseTool is invoked with a ToolCall and the output of custom code is not an instance of DirectToolOutput, the output will automatically be coerced to a string and wrapped in a ToolMessage.
A chunk of a tool call (e.g., as part of a stream).
When merging ToolCallChunks (e.g., via AIMessageChunk.add),
all string attributes are concatenated. Chunks are only merged if their
values of index are equal and not None.