Package dev.langchain4j.service.tool
Interface ToolExecutor
- All Known Implementing Classes:
DefaultToolExecutor
public interface ToolExecutor
A low-level executor/handler of a
ToolExecutionRequest
.-
Method Summary
Modifier and TypeMethodDescriptionexecute
(ToolExecutionRequest toolExecutionRequest, Object memoryId) Executes a tool requests.
-
Method Details
-
execute
Executes a tool requests.- Parameters:
toolExecutionRequest
- The tool execution request. Contains tool name and arguments.memoryId
- The ID of the chat memory. SeeMemoryId
for more details.- Returns:
- The result of the tool execution.
-