@@ -1057,7 +1057,8 @@ public record ChatCompletionRequest(// @formatter:off
1057
1057
@ JsonProperty ("parallel_tool_calls" ) Boolean parallelToolCalls ,
1058
1058
@ JsonProperty ("user" ) String user ,
1059
1059
@ JsonProperty ("reasoning_effort" ) String reasoningEffort ,
1060
- @ JsonProperty ("web_search_options" ) WebSearchOptions webSearchOptions ) {
1060
+ @ JsonProperty ("web_search_options" ) WebSearchOptions webSearchOptions ,
1061
+ @ JsonProperty ("chat_template_kwargs" ) Map <String ,Object > chatTemplateKwargs ) {
1061
1062
1062
1063
/**
1063
1064
* Shortcut constructor for a chat completion request with the given messages, model and temperature.
@@ -1069,7 +1070,7 @@ public record ChatCompletionRequest(// @formatter:off
1069
1070
public ChatCompletionRequest (List <ChatCompletionMessage > messages , String model , Double temperature ) {
1070
1071
this (messages , model , null , null , null , null , null , null , null , null , null , null , null , null , null ,
1071
1072
null , null , null , false , null , temperature , null ,
1072
- null , null , null , null , null , null );
1073
+ null , null , null , null , null , null , null );
1073
1074
}
1074
1075
1075
1076
/**
@@ -1083,7 +1084,7 @@ public ChatCompletionRequest(List<ChatCompletionMessage> messages, String model,
1083
1084
this (messages , model , null , null , null , null , null , null ,
1084
1085
null , null , null , List .of (OutputModality .AUDIO , OutputModality .TEXT ), audio , null , null ,
1085
1086
null , null , null , stream , null , null , null ,
1086
- null , null , null , null , null , null );
1087
+ null , null , null , null , null , null , null );
1087
1088
}
1088
1089
1089
1090
/**
@@ -1098,7 +1099,7 @@ public ChatCompletionRequest(List<ChatCompletionMessage> messages, String model,
1098
1099
public ChatCompletionRequest (List <ChatCompletionMessage > messages , String model , Double temperature , boolean stream ) {
1099
1100
this (messages , model , null , null , null , null , null , null , null , null , null ,
1100
1101
null , null , null , null , null , null , null , stream , null , temperature , null ,
1101
- null , null , null , null , null , null );
1102
+ null , null , null , null , null , null , null );
1102
1103
}
1103
1104
1104
1105
/**
@@ -1114,7 +1115,7 @@ public ChatCompletionRequest(List<ChatCompletionMessage> messages, String model,
1114
1115
List <FunctionTool > tools , Object toolChoice ) {
1115
1116
this (messages , model , null , null , null , null , null , null , null , null , null ,
1116
1117
null , null , null , null , null , null , null , false , null , 0.8 , null ,
1117
- tools , toolChoice , null , null , null , null );
1118
+ tools , toolChoice , null , null , null , null , null );
1118
1119
}
1119
1120
1120
1121
/**
@@ -1127,7 +1128,7 @@ public ChatCompletionRequest(List<ChatCompletionMessage> messages, String model,
1127
1128
public ChatCompletionRequest (List <ChatCompletionMessage > messages , Boolean stream ) {
1128
1129
this (messages , null , null , null , null , null , null , null , null , null , null ,
1129
1130
null , null , null , null , null , null , null , stream , null , null , null ,
1130
- null , null , null , null , null , null );
1131
+ null , null , null , null , null , null , null );
1131
1132
}
1132
1133
1133
1134
/**
@@ -1140,7 +1141,7 @@ public ChatCompletionRequest streamOptions(StreamOptions streamOptions) {
1140
1141
return new ChatCompletionRequest (this .messages , this .model , this .store , this .metadata , this .frequencyPenalty , this .logitBias , this .logprobs ,
1141
1142
this .topLogprobs , this .maxTokens , this .maxCompletionTokens , this .n , this .outputModalities , this .audioParameters , this .presencePenalty ,
1142
1143
this .responseFormat , this .seed , this .serviceTier , this .stop , this .stream , streamOptions , this .temperature , this .topP ,
1143
- this .tools , this .toolChoice , this .parallelToolCalls , this .user , this .reasoningEffort , this .webSearchOptions );
1144
+ this .tools , this .toolChoice , this .parallelToolCalls , this .user , this .reasoningEffort , this .webSearchOptions , this . chatTemplateKwargs );
1144
1145
}
1145
1146
1146
1147
/**
0 commit comments