Class PartialToolCall
java.lang.Object
dev.langchain4j.model.chat.response.PartialToolCall
Represents a partial tool call.
Includes the index, ID, name, and a portion of the arguments.
- Since:
- 1.2.0
- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic PartialToolCall.Builderbuilder()booleaninthashCode()id()The unique identifier for the tool call, generated by the LLM provider.intindex()The index of the tool call, starting from 0 and increasing by 1.name()The name of the tool being invoked.A portion of the arguments for the tool.toString()
-
Constructor Details
-
PartialToolCall
-
-
Method Details
-
index
public int index()The index of the tool call, starting from 0 and increasing by 1. When the LLM initiates multiple tool calls, this index helps correlate the differentPartialToolCalls with each other and with the finalCompleteToolCall. -
id
The unique identifier for the tool call, generated by the LLM provider. Please note that some LLM providers (e.g., Google, Ollama) may omit this ID. -
name
The name of the tool being invoked. -
partialArguments
A portion of the arguments for the tool. When combined, the arguments from allPartialToolCalls should form a complete and valid JSON string. -
equals
-
hashCode
-
toString
-
builder
-