File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed
src/main/java/com/sap/ai/sdk/app/controllers Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change 131131 <groupId >com.fasterxml.jackson.core</groupId >
132132 <artifactId >jackson-annotations</artifactId >
133133 </dependency >
134+ <dependency >
135+ <groupId >com.fasterxml.jackson.module</groupId >
136+ <artifactId >jackson-module-jsonSchema</artifactId >
137+ </dependency >
134138 <!-- scope "runtime" -->
135139 <dependency >
136140 <groupId >ch.qos.logback</groupId >
186190 <groupId >com.sap.cloud.sdk.cloudplatform</groupId >
187191 <artifactId >cloudplatform-connectivity</artifactId >
188192 </dependency >
189- <dependency >
190- <groupId >com.fasterxml.jackson.module</groupId >
191- <artifactId >jackson-module-jsonSchema</artifactId >
192- </dependency >
193193 </dependencies >
194194
195195 <build >
Original file line number Diff line number Diff line change @@ -123,8 +123,10 @@ Object chatCompletionImage(
123123 @ GetMapping ("/chatCompletionToolExecution" )
124124 @ Nonnull
125125 Object chatCompletionToolExecution (
126- @ Nullable @ RequestParam (value = "format" , required = false ) final String format ) {
127- final var response = service .chatCompletionToolExecution ("Dubai" , "°C" );
126+ @ Nullable @ RequestParam (value = "format" , required = false ) final String format ,
127+ @ Nonnull @ RequestParam (value = "location" , defaultValue = "Dubai" ) final String location ,
128+ @ Nonnull @ RequestParam (value = "unit" , defaultValue = "°C" ) final String unit ) {
129+ final var response = service .chatCompletionToolExecution (location , unit );
128130 if ("json" .equals (format )) {
129131 return response ;
130132 }
You can’t perform that action at this time.
0 commit comments