|
9 | 9 | import com.microsoft.semantickernel.aiservices.openai.chatcompletion.OpenAIChatCompletion; |
10 | 10 | import com.microsoft.semantickernel.orchestration.PromptExecutionSettings; |
11 | 11 | import com.microsoft.semantickernel.semanticfunctions.KernelFunction; |
| 12 | +import com.microsoft.semantickernel.semanticfunctions.KernelArguments; |
12 | 13 | import com.microsoft.semantickernel.semanticfunctions.KernelFunctionArguments; |
13 | 14 | import com.microsoft.semantickernel.semanticfunctions.KernelFunctionFromPrompt; |
14 | 15 | import com.microsoft.semantickernel.semanticfunctions.PromptTemplateConfig; |
@@ -73,7 +74,7 @@ public static void runByServiceIdAsync(Kernel kernel, String serviceId) { |
73 | 74 |
|
74 | 75 | var prompt = "Hello AI, what can you do for me?"; |
75 | 76 |
|
76 | | - KernelFunctionArguments arguments = KernelFunctionArguments.builder().build(); |
| 77 | + KernelArguments arguments = KernelArguments.builder().build(); |
77 | 78 |
|
78 | 79 | KernelFunction<?> func = KernelFunctionFromPrompt |
79 | 80 | .builder() |
@@ -104,7 +105,7 @@ public static void runByModelIdAsync(Kernel kernel, String modelId) { |
104 | 105 | .build()) |
105 | 106 | .withOutputVariable("result", "java.lang.String") |
106 | 107 | .build()) |
107 | | - .withArguments(KernelFunctionArguments.builder().build()) |
| 108 | + .withArguments(KernelArguments.builder().build()) |
108 | 109 | .block(); |
109 | 110 |
|
110 | 111 | System.out.println(result.getResult()); |
@@ -136,7 +137,7 @@ public static void runByFirstModelIdAsync(Kernel kernel, String... modelIds) { |
136 | 137 | .build(); |
137 | 138 |
|
138 | 139 | var result = kernel.invokeAsync(function) |
139 | | - .withArguments(KernelFunctionArguments.builder().build()) |
| 140 | + .withArguments(KernelArguments.builder().build()) |
140 | 141 | .block(); |
141 | 142 |
|
142 | 143 | System.out.println(result.getResult()); |
|
0 commit comments