File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed
foundation-models/openai/src/main/java/com/sap/ai/sdk/foundationmodels/openai Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change @@ -82,13 +82,14 @@ ChatCompletionTool createChatCompletionTool() {
8282 OpenAiUtils .getOpenAiObjectMapper ()
8383 .convertValue (schema , new TypeReference <Map <String , Object >>() {});
8484
85- final var function =
86- new FunctionObject ()
87- .name (getName ())
88- .description (getDescription ())
89- .parameters (schemaMap )
90- .strict (getStrict ());
91- return new ChatCompletionTool ().type (FUNCTION ).function (function );
85+ return new ChatCompletionTool ()
86+ .type (FUNCTION )
87+ .function (
88+ new FunctionObject ()
89+ .name (getName ())
90+ .description (getDescription ())
91+ .parameters (schemaMap )
92+ .strict (getStrict ()));
9293 }
9394
9495 private static SchemaGenerator createSchemaGenerator () {
You can’t perform that action at this time.
0 commit comments