You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// The required section should be in alphabetical order. This section is an exception,
16
-
// because we have existing callers that I don't want to break.
17
13
18
14
/// ID of the model to use. See the model endpoint compatibility table for details on which models work
19
15
/// with the Chat API:
@@ -23,7 +19,7 @@ public struct OpenAIChatCompletionRequestBody: Encodable {
23
19
/// A list of messages comprising the conversation so far
24
20
publicletmessages:[Message]
25
21
26
-
// Optional
22
+
// MARK: Optional properties
27
23
28
24
/// Number between -2.0 and 2.0. Positive values penalize new tokens based on their existing frequency in the text so far, decreasing the model's likelihood to repeat the same line verbatim.
29
25
/// See more information here: https://platform.openai.com/docs/guides/text-generation
@@ -115,11 +111,10 @@ public struct OpenAIChatCompletionRequestBody: Encodable {
115
111
publicletuser:String?
116
112
117
113
privateenumCodingKeys:String,CodingKey{
118
-
// required
119
-
case messages
120
114
case model
115
+
case messages
121
116
122
-
// optional
117
+
// Optional properties
123
118
case frequencyPenalty ="frequency_penalty"
124
119
case logitBias ="logit_bias"
125
120
case logprobs
@@ -194,7 +189,7 @@ public struct OpenAIChatCompletionRequestBody: Encodable {
0 commit comments