Skip to content

Commit 4027b90

Browse files
committed
Fix incorrect example code in documentation
Signed-off-by: huidong.yin <[email protected]>
1 parent 1256eaf commit 4027b90

File tree

1 file changed

+1
-1
lines changed
  • spring-ai-docs/src/main/antora/modules/ROOT/pages/api

1 file changed

+1
-1
lines changed

spring-ai-docs/src/main/antora/modules/ROOT/pages/api/tools.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -789,7 +789,7 @@ When building tools from a method, the `ToolDefinition` is automatically generat
789789
[source,java]
790790
----
791791
Method method = ReflectionUtils.findMethod(DateTimeTools.class, "getCurrentDateTime");
792-
ToolDefinition toolDefinition = ToolDefinition.from(method);
792+
ToolDefinition toolDefinition = ToolDefinitions.from(method);
793793
----
794794

795795
The `ToolDefinition` generated from a method includes the method name as the tool name, the method name as the tool description, and the JSON schema of the method input parameters. If the method is annotated with `@Tool`, the tool name and description will be taken from the annotation, if set.

0 commit comments

Comments
 (0)