diff --git a/pom.xml b/pom.xml index 50a8543..bc35d51 100644 --- a/pom.xml +++ b/pom.xml @@ -1,4 +1,3 @@ - @@ -9,14 +8,50 @@ 1.0-SNAPSHOT pom - - 25 - 25 - UTF-8 - - tools/current-time - \ No newline at end of file + + 25 + 25 + UTF-8 + 3.3.7 + 1.0.2 + + + + org.springframework.boot + spring-boot-starter-parent + 3.3.7 + + + + + + + org.springframework.ai + spring-ai-bom + ${spring-ai.version} + pom + import + + + + + + + org.springframework.boot + spring-boot-starter-webflux + + + org.springframework.ai + spring-ai-starter-model-ollama + + + org.projectlombok + lombok + true + + + diff --git a/tools/current-time/src/main/java/ru/ldeloff/currenttime/tool/CurrentTimeTool.java b/tools/current-time/src/main/java/ru/ldeloff/currenttime/tool/CurrentTimeTool.java new file mode 100644 index 0000000..47e4536 --- /dev/null +++ b/tools/current-time/src/main/java/ru/ldeloff/currenttime/tool/CurrentTimeTool.java @@ -0,0 +1,16 @@ +package ru.ldeloff.currenttime.tool; + +import lombok.extern.slf4j.Slf4j; +import org.springframework.ai.tool.annotation.Tool; + +import java.time.LocalDate; + +@Slf4j +public class CurrentTimeTool { + + @Tool(description = "Get the current date in the ISO-8601 format yyyy-MM-dd") + String getCurrentDate() { + log.info("Getting current date"); + return LocalDate.now().toString(); + } +}