Skip to content

Commit c173e92

Browse files
committed
Fix max tokens
1 parent 9b69133 commit c173e92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sample-code/spring-app/src/main/java/com/sap/ai/sdk/app/services/OrchestrationService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public class OrchestrationService {
5757
public String queryPayments(final @Nonnull String msgUser) {
5858
final var msgSystem = "You are a helpful chat bot to answer questions on company payments.";
5959

60-
final var config = new OrchestrationModuleConfig().withLlmConfig(GPT_4O.withParam(TEMPERATURE, 0.5));
60+
final var config = new OrchestrationModuleConfig().withLlmConfig(GPT_4O.withParam(TEMPERATURE, 0.5).withParam(MAX_TOKENS, 150));
6161
final var prompt = new OrchestrationPrompt(Message.system(msgSystem), Message.user(msgUser));
6262
final var result = client.chatCompletion(prompt, config);
6363
return result.getContent();

0 commit comments

Comments
 (0)