@effect/ai-openai 0.13.0 → 0.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/cjs/Generated.js +170 -227
- package/dist/cjs/Generated.js.map +1 -1
- package/dist/cjs/OpenAiConfig.js.map +1 -1
- package/dist/dts/Generated.d.ts +262 -334
- package/dist/dts/Generated.d.ts.map +1 -1
- package/dist/dts/OpenAiCompletions.d.ts +1 -1
- package/dist/dts/OpenAiCompletions.d.ts.map +1 -1
- package/dist/dts/OpenAiConfig.d.ts +12 -1
- package/dist/dts/OpenAiConfig.d.ts.map +1 -1
- package/dist/dts/OpenAiEmbeddings.d.ts +1 -1
- package/dist/dts/OpenAiEmbeddings.d.ts.map +1 -1
- package/dist/esm/Generated.js +136 -157
- package/dist/esm/Generated.js.map +1 -1
- package/dist/esm/OpenAiConfig.js.map +1 -1
- package/package.json +5 -5
- package/src/Generated.ts +161 -237
- package/src/OpenAiCompletions.ts +1 -1
- package/src/OpenAiConfig.ts +15 -1
- package/src/OpenAiEmbeddings.ts +1 -1
package/dist/esm/Generated.js
CHANGED
|
@@ -72,6 +72,7 @@ export class Metadata extends /*#__PURE__*/S.Record({
|
|
|
72
72
|
key: S.String,
|
|
73
73
|
value: S.Unknown
|
|
74
74
|
}) {}
|
|
75
|
+
export class AssistantsApiResponseFormatOptionEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
75
76
|
export class ResponseFormatTextType extends /*#__PURE__*/S.Literal("text") {}
|
|
76
77
|
export class ResponseFormatText extends /*#__PURE__*/S.Struct({
|
|
77
78
|
"type": ResponseFormatTextType
|
|
@@ -101,7 +102,7 @@ export class ResponseFormatJsonSchema extends /*#__PURE__*/S.Struct({
|
|
|
101
102
|
})
|
|
102
103
|
})
|
|
103
104
|
}) {}
|
|
104
|
-
export class AssistantsApiResponseFormatOption extends /*#__PURE__*/S.Union(
|
|
105
|
+
export class AssistantsApiResponseFormatOption extends /*#__PURE__*/S.Union(AssistantsApiResponseFormatOptionEnum, ResponseFormatText, ResponseFormatJsonObject, ResponseFormatJsonSchema) {}
|
|
105
106
|
export class AssistantObject extends /*#__PURE__*/S.Struct({
|
|
106
107
|
"id": S.String,
|
|
107
108
|
"object": AssistantObjectObject,
|
|
@@ -150,10 +151,10 @@ export class ListAssistantsResponse extends /*#__PURE__*/S.Class("ListAssistants
|
|
|
150
151
|
"last_id": S.String,
|
|
151
152
|
"has_more": S.Boolean
|
|
152
153
|
}) {}
|
|
153
|
-
export class
|
|
154
|
-
export class
|
|
154
|
+
export class AssistantSupportedModels extends /*#__PURE__*/S.Literal("o3-mini", "o3-mini-2025-01-31", "o1", "o1-2024-12-17", "gpt-4o", "gpt-4o-2024-11-20", "gpt-4o-2024-08-06", "gpt-4o-2024-05-13", "gpt-4o-mini", "gpt-4o-mini-2024-07-18", "gpt-4-turbo", "gpt-4-turbo-2024-04-09", "gpt-4-0125-preview", "gpt-4-turbo-preview", "gpt-4-1106-preview", "gpt-4-vision-preview", "gpt-4", "gpt-4-0314", "gpt-4-0613", "gpt-4-32k", "gpt-4-32k-0314", "gpt-4-32k-0613", "gpt-3.5-turbo", "gpt-3.5-turbo-16k", "gpt-3.5-turbo-0613", "gpt-3.5-turbo-1106", "gpt-3.5-turbo-0125", "gpt-3.5-turbo-16k-0613") {}
|
|
155
|
+
export class ReasoningEffort extends /*#__PURE__*/S.Literal("low", "medium", "high") {}
|
|
155
156
|
export class CreateAssistantRequest extends /*#__PURE__*/S.Class("CreateAssistantRequest")({
|
|
156
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
157
|
+
"model": /*#__PURE__*/S.Union(S.String, AssistantSupportedModels),
|
|
157
158
|
"name": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.maxLength(256)), {
|
|
158
159
|
nullable: true
|
|
159
160
|
}),
|
|
@@ -163,6 +164,10 @@ export class CreateAssistantRequest extends /*#__PURE__*/S.Class("CreateAssistan
|
|
|
163
164
|
"instructions": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.maxLength(256000)), {
|
|
164
165
|
nullable: true
|
|
165
166
|
}),
|
|
167
|
+
"reasoning_effort": /*#__PURE__*/S.optionalWith(ReasoningEffort, {
|
|
168
|
+
nullable: true,
|
|
169
|
+
default: () => "medium"
|
|
170
|
+
}),
|
|
166
171
|
"tools": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.Union(AssistantToolsCode, AssistantToolsFileSearch, AssistantToolsFunction)).pipe( /*#__PURE__*/S.maxItems(128)), {
|
|
167
172
|
nullable: true,
|
|
168
173
|
default: () => []
|
|
@@ -218,9 +223,13 @@ export class CreateAssistantRequest extends /*#__PURE__*/S.Class("CreateAssistan
|
|
|
218
223
|
})
|
|
219
224
|
}) {}
|
|
220
225
|
export class ModifyAssistantRequest extends /*#__PURE__*/S.Class("ModifyAssistantRequest")({
|
|
221
|
-
"model": /*#__PURE__*/S.optionalWith(S.String, {
|
|
226
|
+
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, AssistantSupportedModels), {
|
|
222
227
|
nullable: true
|
|
223
228
|
}),
|
|
229
|
+
"reasoning_effort": /*#__PURE__*/S.optionalWith(ReasoningEffort, {
|
|
230
|
+
nullable: true,
|
|
231
|
+
default: () => "medium"
|
|
232
|
+
}),
|
|
224
233
|
"name": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.maxLength(256)), {
|
|
225
234
|
nullable: true
|
|
226
235
|
}),
|
|
@@ -274,11 +283,11 @@ export class DeleteAssistantResponse extends /*#__PURE__*/S.Class("DeleteAssista
|
|
|
274
283
|
"deleted": S.Boolean,
|
|
275
284
|
"object": DeleteAssistantResponseObject
|
|
276
285
|
}) {}
|
|
277
|
-
export class
|
|
286
|
+
export class CreateSpeechRequestModelEnum extends /*#__PURE__*/S.Literal("tts-1", "tts-1-hd") {}
|
|
278
287
|
export class CreateSpeechRequestVoice extends /*#__PURE__*/S.Literal("alloy", "ash", "coral", "echo", "fable", "onyx", "nova", "sage", "shimmer") {}
|
|
279
288
|
export class CreateSpeechRequestResponseFormat extends /*#__PURE__*/S.Literal("mp3", "opus", "aac", "flac", "wav", "pcm") {}
|
|
280
289
|
export class CreateSpeechRequest extends /*#__PURE__*/S.Class("CreateSpeechRequest")({
|
|
281
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
290
|
+
"model": /*#__PURE__*/S.Union(S.String, CreateSpeechRequestModelEnum),
|
|
282
291
|
"input": /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.maxLength(4096)),
|
|
283
292
|
"voice": CreateSpeechRequestVoice,
|
|
284
293
|
"response_format": /*#__PURE__*/S.optionalWith(CreateSpeechRequestResponseFormat, {
|
|
@@ -548,8 +557,7 @@ export class ChatCompletionRequestFunctionMessage extends /*#__PURE__*/S.Struct(
|
|
|
548
557
|
"name": S.String
|
|
549
558
|
}) {}
|
|
550
559
|
export class ChatCompletionRequestMessage extends /*#__PURE__*/S.Union(ChatCompletionRequestDeveloperMessage, ChatCompletionRequestSystemMessage, ChatCompletionRequestUserMessage, ChatCompletionRequestAssistantMessage, ChatCompletionRequestToolMessage, ChatCompletionRequestFunctionMessage) {}
|
|
551
|
-
export class
|
|
552
|
-
export class CreateChatCompletionRequestReasoningEffort extends /*#__PURE__*/S.Literal("low", "medium", "high") {}
|
|
560
|
+
export class CreateChatCompletionRequestModelEnum extends /*#__PURE__*/S.Literal("o3-mini", "o3-mini-2025-01-31", "o1", "o1-2024-12-17", "o1-preview", "o1-preview-2024-09-12", "o1-mini", "o1-mini-2024-09-12", "gpt-4o", "gpt-4o-2024-11-20", "gpt-4o-2024-08-06", "gpt-4o-2024-05-13", "gpt-4o-audio-preview", "gpt-4o-audio-preview-2024-10-01", "gpt-4o-audio-preview-2024-12-17", "gpt-4o-mini-audio-preview", "gpt-4o-mini-audio-preview-2024-12-17", "chatgpt-4o-latest", "gpt-4o-mini", "gpt-4o-mini-2024-07-18", "gpt-4-turbo", "gpt-4-turbo-2024-04-09", "gpt-4-0125-preview", "gpt-4-turbo-preview", "gpt-4-1106-preview", "gpt-4-vision-preview", "gpt-4", "gpt-4-0314", "gpt-4-0613", "gpt-4-32k", "gpt-4-32k-0314", "gpt-4-32k-0613", "gpt-3.5-turbo", "gpt-3.5-turbo-16k", "gpt-3.5-turbo-0301", "gpt-3.5-turbo-0613", "gpt-3.5-turbo-1106", "gpt-3.5-turbo-0125", "gpt-3.5-turbo-16k-0613") {}
|
|
553
561
|
export class ChatCompletionModalities extends /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "audio")) {}
|
|
554
562
|
export class PredictionContentType extends /*#__PURE__*/S.Literal("content") {}
|
|
555
563
|
export class PredictionContent extends /*#__PURE__*/S.Struct({
|
|
@@ -569,6 +577,7 @@ export class ChatCompletionTool extends /*#__PURE__*/S.Struct({
|
|
|
569
577
|
"type": ChatCompletionToolType,
|
|
570
578
|
"function": FunctionObject
|
|
571
579
|
}) {}
|
|
580
|
+
export class ChatCompletionToolChoiceOptionEnum extends /*#__PURE__*/S.Literal("none", "auto", "required") {}
|
|
572
581
|
export class ChatCompletionNamedToolChoiceType extends /*#__PURE__*/S.Literal("function") {}
|
|
573
582
|
export class ChatCompletionNamedToolChoice extends /*#__PURE__*/S.Struct({
|
|
574
583
|
"type": ChatCompletionNamedToolChoiceType,
|
|
@@ -576,9 +585,9 @@ export class ChatCompletionNamedToolChoice extends /*#__PURE__*/S.Struct({
|
|
|
576
585
|
"name": S.String
|
|
577
586
|
})
|
|
578
587
|
}) {}
|
|
579
|
-
export class ChatCompletionToolChoiceOption extends /*#__PURE__*/S.Union(
|
|
588
|
+
export class ChatCompletionToolChoiceOption extends /*#__PURE__*/S.Union(ChatCompletionToolChoiceOptionEnum, ChatCompletionNamedToolChoice) {}
|
|
580
589
|
export class ParallelToolCalls extends S.Boolean {}
|
|
581
|
-
export class
|
|
590
|
+
export class CreateChatCompletionRequestFunctionCallEnum extends /*#__PURE__*/S.Literal("none", "auto") {}
|
|
582
591
|
export class ChatCompletionFunctionCallOption extends /*#__PURE__*/S.Struct({
|
|
583
592
|
"name": S.String
|
|
584
593
|
}) {}
|
|
@@ -593,12 +602,12 @@ export class ChatCompletionFunctions extends /*#__PURE__*/S.Struct({
|
|
|
593
602
|
}) {}
|
|
594
603
|
export class CreateChatCompletionRequest extends /*#__PURE__*/S.Class("CreateChatCompletionRequest")({
|
|
595
604
|
"messages": /*#__PURE__*/S.NonEmptyArray(ChatCompletionRequestMessage),
|
|
596
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
605
|
+
"model": /*#__PURE__*/S.Union(S.String, CreateChatCompletionRequestModelEnum),
|
|
597
606
|
"store": /*#__PURE__*/S.optionalWith(S.Boolean, {
|
|
598
607
|
nullable: true,
|
|
599
608
|
default: () => false
|
|
600
609
|
}),
|
|
601
|
-
"reasoning_effort": /*#__PURE__*/S.optionalWith(
|
|
610
|
+
"reasoning_effort": /*#__PURE__*/S.optionalWith(ReasoningEffort, {
|
|
602
611
|
nullable: true,
|
|
603
612
|
default: () => "medium"
|
|
604
613
|
}),
|
|
@@ -609,11 +618,11 @@ export class CreateChatCompletionRequest extends /*#__PURE__*/S.Class("CreateCha
|
|
|
609
618
|
nullable: true,
|
|
610
619
|
default: () => 0
|
|
611
620
|
}),
|
|
612
|
-
"logit_bias": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Record({
|
|
621
|
+
"logit_bias": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Record({
|
|
613
622
|
key: S.String,
|
|
614
623
|
value: S.Unknown
|
|
615
|
-
}), {
|
|
616
|
-
|
|
624
|
+
})), {
|
|
625
|
+
default: () => null
|
|
617
626
|
}),
|
|
618
627
|
"logprobs": /*#__PURE__*/S.optionalWith(S.Boolean, {
|
|
619
628
|
nullable: true,
|
|
@@ -658,15 +667,15 @@ export class CreateChatCompletionRequest extends /*#__PURE__*/S.Class("CreateCha
|
|
|
658
667
|
nullable: true,
|
|
659
668
|
default: () => "auto"
|
|
660
669
|
}),
|
|
661
|
-
"stop": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(4))), {
|
|
662
|
-
|
|
670
|
+
"stop": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(4)))), {
|
|
671
|
+
default: () => null
|
|
663
672
|
}),
|
|
664
673
|
"stream": /*#__PURE__*/S.optionalWith(S.Boolean, {
|
|
665
674
|
nullable: true,
|
|
666
675
|
default: () => false
|
|
667
676
|
}),
|
|
668
|
-
"stream_options": /*#__PURE__*/S.optionalWith(ChatCompletionStreamOptions, {
|
|
669
|
-
|
|
677
|
+
"stream_options": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr(ChatCompletionStreamOptions), {
|
|
678
|
+
default: () => null
|
|
670
679
|
}),
|
|
671
680
|
"temperature": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(2)), {
|
|
672
681
|
nullable: true,
|
|
@@ -689,14 +698,13 @@ export class CreateChatCompletionRequest extends /*#__PURE__*/S.Class("CreateCha
|
|
|
689
698
|
"user": /*#__PURE__*/S.optionalWith(S.String, {
|
|
690
699
|
nullable: true
|
|
691
700
|
}),
|
|
692
|
-
"function_call": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
701
|
+
"function_call": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(CreateChatCompletionRequestFunctionCallEnum, ChatCompletionFunctionCallOption), {
|
|
693
702
|
nullable: true
|
|
694
703
|
}),
|
|
695
704
|
"functions": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(ChatCompletionFunctions).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(128)), {
|
|
696
705
|
nullable: true
|
|
697
706
|
})
|
|
698
707
|
}) {}
|
|
699
|
-
export class CreateChatCompletionResponseChoicesFinishReason extends /*#__PURE__*/S.Literal("stop", "length", "tool_calls", "content_filter", "function_call") {}
|
|
700
708
|
export class ChatCompletionResponseMessageRole extends /*#__PURE__*/S.Literal("assistant") {}
|
|
701
709
|
export class ChatCompletionResponseMessage extends /*#__PURE__*/S.Struct({
|
|
702
710
|
"content": /*#__PURE__*/S.NullOr(S.String),
|
|
@@ -772,7 +780,7 @@ export class CompletionUsage extends /*#__PURE__*/S.Struct({
|
|
|
772
780
|
export class CreateChatCompletionResponse extends /*#__PURE__*/S.Class("CreateChatCompletionResponse")({
|
|
773
781
|
"id": S.String,
|
|
774
782
|
"choices": /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
775
|
-
"finish_reason":
|
|
783
|
+
"finish_reason": /*#__PURE__*/S.Literal("stop", "length", "tool_calls", "content_filter", "function_call"),
|
|
776
784
|
"index": S.Int,
|
|
777
785
|
"message": ChatCompletionResponseMessage,
|
|
778
786
|
"logprobs": /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Struct({
|
|
@@ -793,9 +801,9 @@ export class CreateChatCompletionResponse extends /*#__PURE__*/S.Class("CreateCh
|
|
|
793
801
|
nullable: true
|
|
794
802
|
})
|
|
795
803
|
}) {}
|
|
796
|
-
export class
|
|
804
|
+
export class CreateCompletionRequestModelEnum extends /*#__PURE__*/S.Literal("gpt-3.5-turbo-instruct", "davinci-002", "babbage-002") {}
|
|
797
805
|
export class CreateCompletionRequest extends /*#__PURE__*/S.Class("CreateCompletionRequest")({
|
|
798
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
806
|
+
"model": /*#__PURE__*/S.Union(S.String, CreateCompletionRequestModelEnum),
|
|
799
807
|
"prompt": /*#__PURE__*/S.NullOr(S.Union(S.String, S.Array(S.String), S.NonEmptyArray(S.Int), S.NonEmptyArray(S.NonEmptyArray(S.Int)))).pipe(S.propertySignature, /*#__PURE__*/S.withConstructorDefault(() => "<|endoftext|>")),
|
|
800
808
|
"best_of": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(20)), {
|
|
801
809
|
nullable: true,
|
|
@@ -809,14 +817,14 @@ export class CreateCompletionRequest extends /*#__PURE__*/S.Class("CreateComplet
|
|
|
809
817
|
nullable: true,
|
|
810
818
|
default: () => 0
|
|
811
819
|
}),
|
|
812
|
-
"logit_bias": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Record({
|
|
820
|
+
"logit_bias": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Record({
|
|
813
821
|
key: S.String,
|
|
814
822
|
value: S.Unknown
|
|
815
|
-
}), {
|
|
816
|
-
|
|
823
|
+
})), {
|
|
824
|
+
default: () => null
|
|
817
825
|
}),
|
|
818
|
-
"logprobs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(5)), {
|
|
819
|
-
|
|
826
|
+
"logprobs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(5))), {
|
|
827
|
+
default: () => null
|
|
820
828
|
}),
|
|
821
829
|
"max_tokens": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0)), {
|
|
822
830
|
nullable: true,
|
|
@@ -833,18 +841,18 @@ export class CreateCompletionRequest extends /*#__PURE__*/S.Class("CreateComplet
|
|
|
833
841
|
"seed": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
834
842
|
nullable: true
|
|
835
843
|
}),
|
|
836
|
-
"stop": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(4))), {
|
|
837
|
-
|
|
844
|
+
"stop": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(4)))), {
|
|
845
|
+
default: () => null
|
|
838
846
|
}),
|
|
839
847
|
"stream": /*#__PURE__*/S.optionalWith(S.Boolean, {
|
|
840
848
|
nullable: true,
|
|
841
849
|
default: () => false
|
|
842
850
|
}),
|
|
843
|
-
"stream_options": /*#__PURE__*/S.optionalWith(ChatCompletionStreamOptions, {
|
|
844
|
-
|
|
851
|
+
"stream_options": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr(ChatCompletionStreamOptions), {
|
|
852
|
+
default: () => null
|
|
845
853
|
}),
|
|
846
|
-
"suffix": /*#__PURE__*/S.optionalWith(S.String, {
|
|
847
|
-
|
|
854
|
+
"suffix": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr(S.String), {
|
|
855
|
+
default: () => null
|
|
848
856
|
}),
|
|
849
857
|
"temperature": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(2)), {
|
|
850
858
|
nullable: true,
|
|
@@ -858,12 +866,11 @@ export class CreateCompletionRequest extends /*#__PURE__*/S.Class("CreateComplet
|
|
|
858
866
|
nullable: true
|
|
859
867
|
})
|
|
860
868
|
}) {}
|
|
861
|
-
export class CreateCompletionResponseChoicesFinishReason extends /*#__PURE__*/S.Literal("stop", "length", "content_filter") {}
|
|
862
869
|
export class CreateCompletionResponseObject extends /*#__PURE__*/S.Literal("text_completion") {}
|
|
863
870
|
export class CreateCompletionResponse extends /*#__PURE__*/S.Class("CreateCompletionResponse")({
|
|
864
871
|
"id": S.String,
|
|
865
872
|
"choices": /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
866
|
-
"finish_reason":
|
|
873
|
+
"finish_reason": /*#__PURE__*/S.Literal("stop", "length", "content_filter"),
|
|
867
874
|
"index": S.Int,
|
|
868
875
|
"logprobs": /*#__PURE__*/S.NullOr( /*#__PURE__*/S.Struct({
|
|
869
876
|
"text_offset": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.Int), {
|
|
@@ -894,11 +901,11 @@ export class CreateCompletionResponse extends /*#__PURE__*/S.Class("CreateComple
|
|
|
894
901
|
nullable: true
|
|
895
902
|
})
|
|
896
903
|
}) {}
|
|
897
|
-
export class
|
|
904
|
+
export class CreateEmbeddingRequestModelEnum extends /*#__PURE__*/S.Literal("text-embedding-ada-002", "text-embedding-3-small", "text-embedding-3-large") {}
|
|
898
905
|
export class CreateEmbeddingRequestEncodingFormat extends /*#__PURE__*/S.Literal("float", "base64") {}
|
|
899
906
|
export class CreateEmbeddingRequest extends /*#__PURE__*/S.Class("CreateEmbeddingRequest")({
|
|
900
907
|
"input": /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(2048)), /*#__PURE__*/S.Array(S.Int).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(2048)), /*#__PURE__*/S.Array(S.NonEmptyArray(S.Int)).pipe( /*#__PURE__*/S.minItems(1), /*#__PURE__*/S.maxItems(2048))),
|
|
901
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
908
|
+
"model": /*#__PURE__*/S.Union(S.String, CreateEmbeddingRequestModelEnum),
|
|
902
909
|
"encoding_format": /*#__PURE__*/S.optionalWith(CreateEmbeddingRequestEncodingFormat, {
|
|
903
910
|
nullable: true,
|
|
904
911
|
default: () => "float"
|
|
@@ -981,9 +988,9 @@ export class ListPaginatedFineTuningJobsParams extends /*#__PURE__*/S.Struct({
|
|
|
981
988
|
default: () => 20
|
|
982
989
|
})
|
|
983
990
|
}) {}
|
|
984
|
-
export class
|
|
985
|
-
export class
|
|
986
|
-
export class
|
|
991
|
+
export class FineTuningJobHyperparametersBatchSizeEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
992
|
+
export class FineTuningJobHyperparametersLearningRateMultiplierEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
993
|
+
export class FineTuningJobHyperparametersNEpochsEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
987
994
|
export class FineTuningJobObject extends /*#__PURE__*/S.Literal("fine_tuning.job") {}
|
|
988
995
|
export class FineTuningJobStatus extends /*#__PURE__*/S.Literal("validating_files", "queued", "running", "succeeded", "failed", "cancelled") {}
|
|
989
996
|
export class FineTuningIntegrationType extends /*#__PURE__*/S.Literal("wandb") {}
|
|
@@ -1003,20 +1010,20 @@ export class FineTuningIntegration extends /*#__PURE__*/S.Struct({
|
|
|
1003
1010
|
})
|
|
1004
1011
|
}) {}
|
|
1005
1012
|
export class FineTuneMethodType extends /*#__PURE__*/S.Literal("supervised", "dpo") {}
|
|
1006
|
-
export class
|
|
1007
|
-
export class
|
|
1008
|
-
export class
|
|
1013
|
+
export class FineTuneSupervisedMethodHyperparametersBatchSizeEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1014
|
+
export class FineTuneSupervisedMethodHyperparametersLearningRateMultiplierEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1015
|
+
export class FineTuneSupervisedMethodHyperparametersNEpochsEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1009
1016
|
export class FineTuneSupervisedMethod extends /*#__PURE__*/S.Struct({
|
|
1010
1017
|
"hyperparameters": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Struct({
|
|
1011
|
-
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1018
|
+
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneSupervisedMethodHyperparametersBatchSizeEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(256))), {
|
|
1012
1019
|
nullable: true,
|
|
1013
1020
|
default: () => "auto"
|
|
1014
1021
|
}),
|
|
1015
|
-
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1022
|
+
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneSupervisedMethodHyperparametersLearningRateMultiplierEnum, /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThan(0))), {
|
|
1016
1023
|
nullable: true,
|
|
1017
1024
|
default: () => "auto"
|
|
1018
1025
|
}),
|
|
1019
|
-
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1026
|
+
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneSupervisedMethodHyperparametersNEpochsEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(50))), {
|
|
1020
1027
|
nullable: true,
|
|
1021
1028
|
default: () => "auto"
|
|
1022
1029
|
})
|
|
@@ -1024,25 +1031,25 @@ export class FineTuneSupervisedMethod extends /*#__PURE__*/S.Struct({
|
|
|
1024
1031
|
nullable: true
|
|
1025
1032
|
})
|
|
1026
1033
|
}) {}
|
|
1027
|
-
export class
|
|
1028
|
-
export class
|
|
1029
|
-
export class
|
|
1030
|
-
export class
|
|
1034
|
+
export class FineTuneDPOMethodHyperparametersBetaEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1035
|
+
export class FineTuneDPOMethodHyperparametersBatchSizeEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1036
|
+
export class FineTuneDPOMethodHyperparametersLearningRateMultiplierEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1037
|
+
export class FineTuneDPOMethodHyperparametersNEpochsEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1031
1038
|
export class FineTuneDPOMethod extends /*#__PURE__*/S.Struct({
|
|
1032
1039
|
"hyperparameters": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Struct({
|
|
1033
|
-
"beta": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1040
|
+
"beta": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneDPOMethodHyperparametersBetaEnum, /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThan(0), /*#__PURE__*/S.lessThanOrEqualTo(2))), {
|
|
1034
1041
|
nullable: true,
|
|
1035
1042
|
default: () => "auto"
|
|
1036
1043
|
}),
|
|
1037
|
-
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1044
|
+
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneDPOMethodHyperparametersBatchSizeEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(256))), {
|
|
1038
1045
|
nullable: true,
|
|
1039
1046
|
default: () => "auto"
|
|
1040
1047
|
}),
|
|
1041
|
-
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1048
|
+
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneDPOMethodHyperparametersLearningRateMultiplierEnum, /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThan(0))), {
|
|
1042
1049
|
nullable: true,
|
|
1043
1050
|
default: () => "auto"
|
|
1044
1051
|
}),
|
|
1045
|
-
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1052
|
+
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuneDPOMethodHyperparametersNEpochsEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(50))), {
|
|
1046
1053
|
nullable: true,
|
|
1047
1054
|
default: () => "auto"
|
|
1048
1055
|
})
|
|
@@ -1072,15 +1079,15 @@ export class FineTuningJob extends /*#__PURE__*/S.Struct({
|
|
|
1072
1079
|
"fine_tuned_model": /*#__PURE__*/S.NullOr(S.String),
|
|
1073
1080
|
"finished_at": /*#__PURE__*/S.NullOr(S.Int),
|
|
1074
1081
|
"hyperparameters": /*#__PURE__*/S.Struct({
|
|
1075
|
-
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1082
|
+
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuningJobHyperparametersBatchSizeEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(256))), {
|
|
1076
1083
|
nullable: true,
|
|
1077
1084
|
default: () => "auto"
|
|
1078
1085
|
}),
|
|
1079
|
-
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1086
|
+
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuningJobHyperparametersLearningRateMultiplierEnum, /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThan(0))), {
|
|
1080
1087
|
nullable: true,
|
|
1081
1088
|
default: () => "auto"
|
|
1082
1089
|
}),
|
|
1083
|
-
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1090
|
+
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(FineTuningJobHyperparametersNEpochsEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(50))), {
|
|
1084
1091
|
nullable: true,
|
|
1085
1092
|
default: () => "auto"
|
|
1086
1093
|
})
|
|
@@ -1110,38 +1117,37 @@ export class ListPaginatedFineTuningJobsResponse extends /*#__PURE__*/S.Class("L
|
|
|
1110
1117
|
"has_more": S.Boolean,
|
|
1111
1118
|
"object": ListPaginatedFineTuningJobsResponseObject
|
|
1112
1119
|
}) {}
|
|
1113
|
-
export class
|
|
1114
|
-
export class
|
|
1115
|
-
export class
|
|
1116
|
-
export class
|
|
1117
|
-
export class CreateFineTuningJobRequestIntegrationsType extends /*#__PURE__*/S.Literal("wandb") {}
|
|
1120
|
+
export class CreateFineTuningJobRequestModelEnum extends /*#__PURE__*/S.Literal("babbage-002", "davinci-002", "gpt-3.5-turbo", "gpt-4o-mini") {}
|
|
1121
|
+
export class CreateFineTuningJobRequestHyperparametersBatchSizeEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1122
|
+
export class CreateFineTuningJobRequestHyperparametersLearningRateMultiplierEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1123
|
+
export class CreateFineTuningJobRequestHyperparametersNEpochsEnum extends /*#__PURE__*/S.Literal("auto") {}
|
|
1118
1124
|
export class CreateFineTuningJobRequest extends /*#__PURE__*/S.Class("CreateFineTuningJobRequest")({
|
|
1119
|
-
"model": /*#__PURE__*/S.Union(S.String,
|
|
1125
|
+
"model": /*#__PURE__*/S.Union(S.String, CreateFineTuningJobRequestModelEnum),
|
|
1120
1126
|
"training_file": S.String,
|
|
1121
1127
|
"hyperparameters": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Struct({
|
|
1122
|
-
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1128
|
+
"batch_size": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(CreateFineTuningJobRequestHyperparametersBatchSizeEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(256))), {
|
|
1123
1129
|
nullable: true,
|
|
1124
1130
|
default: () => "auto"
|
|
1125
1131
|
}),
|
|
1126
|
-
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1132
|
+
"learning_rate_multiplier": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(CreateFineTuningJobRequestHyperparametersLearningRateMultiplierEnum, /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThan(0))), {
|
|
1127
1133
|
nullable: true,
|
|
1128
1134
|
default: () => "auto"
|
|
1129
1135
|
}),
|
|
1130
|
-
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(
|
|
1136
|
+
"n_epochs": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(CreateFineTuningJobRequestHyperparametersNEpochsEnum, /*#__PURE__*/S.Int.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(1), /*#__PURE__*/S.lessThanOrEqualTo(50))), {
|
|
1131
1137
|
nullable: true,
|
|
1132
1138
|
default: () => "auto"
|
|
1133
1139
|
})
|
|
1134
1140
|
}), {
|
|
1135
1141
|
nullable: true
|
|
1136
1142
|
}),
|
|
1137
|
-
"suffix": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.minLength(1), /*#__PURE__*/S.maxLength(64)), {
|
|
1138
|
-
|
|
1143
|
+
"suffix": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.NullOr( /*#__PURE__*/S.String.pipe( /*#__PURE__*/S.minLength(1), /*#__PURE__*/S.maxLength(64))), {
|
|
1144
|
+
default: () => null
|
|
1139
1145
|
}),
|
|
1140
1146
|
"validation_file": /*#__PURE__*/S.optionalWith(S.String, {
|
|
1141
1147
|
nullable: true
|
|
1142
1148
|
}),
|
|
1143
1149
|
"integrations": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
1144
|
-
"type":
|
|
1150
|
+
"type": /*#__PURE__*/S.Literal("wandb"),
|
|
1145
1151
|
"wandb": /*#__PURE__*/S.Struct({
|
|
1146
1152
|
"project": S.String,
|
|
1147
1153
|
"name": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -1248,7 +1254,8 @@ export class FineTuningJobEvent extends /*#__PURE__*/S.Struct({
|
|
|
1248
1254
|
export class ListFineTuningJobEventsResponseObject extends /*#__PURE__*/S.Literal("list") {}
|
|
1249
1255
|
export class ListFineTuningJobEventsResponse extends /*#__PURE__*/S.Class("ListFineTuningJobEventsResponse")({
|
|
1250
1256
|
"data": /*#__PURE__*/S.Array(FineTuningJobEvent),
|
|
1251
|
-
"object": ListFineTuningJobEventsResponseObject
|
|
1257
|
+
"object": ListFineTuningJobEventsResponseObject,
|
|
1258
|
+
"has_more": S.Boolean
|
|
1252
1259
|
}) {}
|
|
1253
1260
|
export class Image extends /*#__PURE__*/S.Struct({
|
|
1254
1261
|
"b64_json": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -1265,14 +1272,14 @@ export class ImagesResponse extends /*#__PURE__*/S.Class("ImagesResponse")({
|
|
|
1265
1272
|
"created": S.Int,
|
|
1266
1273
|
"data": /*#__PURE__*/S.Array(Image)
|
|
1267
1274
|
}) {}
|
|
1268
|
-
export class
|
|
1275
|
+
export class CreateImageRequestModelEnum extends /*#__PURE__*/S.Literal("dall-e-2", "dall-e-3") {}
|
|
1269
1276
|
export class CreateImageRequestQuality extends /*#__PURE__*/S.Literal("standard", "hd") {}
|
|
1270
1277
|
export class CreateImageRequestResponseFormat extends /*#__PURE__*/S.Literal("url", "b64_json") {}
|
|
1271
1278
|
export class CreateImageRequestSize extends /*#__PURE__*/S.Literal("256x256", "512x512", "1024x1024", "1792x1024", "1024x1792") {}
|
|
1272
1279
|
export class CreateImageRequestStyle extends /*#__PURE__*/S.Literal("vivid", "natural") {}
|
|
1273
1280
|
export class CreateImageRequest extends /*#__PURE__*/S.Class("CreateImageRequest")({
|
|
1274
1281
|
"prompt": S.String,
|
|
1275
|
-
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String,
|
|
1282
|
+
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, CreateImageRequestModelEnum), {
|
|
1276
1283
|
nullable: true,
|
|
1277
1284
|
default: () => "dall-e-2"
|
|
1278
1285
|
}),
|
|
@@ -1317,36 +1324,22 @@ export class DeleteModelResponse extends /*#__PURE__*/S.Class("DeleteModelRespon
|
|
|
1317
1324
|
"deleted": S.Boolean,
|
|
1318
1325
|
"object": S.String
|
|
1319
1326
|
}) {}
|
|
1320
|
-
export class
|
|
1321
|
-
export class CreateModerationRequestModel extends /*#__PURE__*/S.Literal("omni-moderation-latest", "omni-moderation-2024-09-26", "text-moderation-latest", "text-moderation-stable") {}
|
|
1327
|
+
export class CreateModerationRequestModelEnum extends /*#__PURE__*/S.Literal("omni-moderation-latest", "omni-moderation-2024-09-26", "text-moderation-latest", "text-moderation-stable") {}
|
|
1322
1328
|
export class CreateModerationRequest extends /*#__PURE__*/S.Class("CreateModerationRequest")({
|
|
1323
1329
|
"input": /*#__PURE__*/S.Union(S.String, /*#__PURE__*/S.Array(S.String), /*#__PURE__*/S.Array( /*#__PURE__*/S.Union( /*#__PURE__*/S.Struct({
|
|
1324
|
-
"type":
|
|
1330
|
+
"type": /*#__PURE__*/S.Literal("image_url"),
|
|
1325
1331
|
"image_url": /*#__PURE__*/S.Struct({
|
|
1326
1332
|
"url": S.String
|
|
1327
1333
|
})
|
|
1328
1334
|
}), /*#__PURE__*/S.Struct({
|
|
1329
|
-
"type":
|
|
1335
|
+
"type": /*#__PURE__*/S.Literal("text"),
|
|
1330
1336
|
"text": S.String
|
|
1331
1337
|
})))),
|
|
1332
|
-
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String,
|
|
1338
|
+
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, CreateModerationRequestModelEnum), {
|
|
1333
1339
|
nullable: true,
|
|
1334
1340
|
default: () => "omni-moderation-latest"
|
|
1335
1341
|
})
|
|
1336
1342
|
}) {}
|
|
1337
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesHate extends /*#__PURE__*/S.Literal("text") {}
|
|
1338
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesHateThreatening extends /*#__PURE__*/S.Literal("text") {}
|
|
1339
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesHarassment extends /*#__PURE__*/S.Literal("text") {}
|
|
1340
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesHarassmentThreatening extends /*#__PURE__*/S.Literal("text") {}
|
|
1341
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesIllicit extends /*#__PURE__*/S.Literal("text") {}
|
|
1342
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesIllicitViolent extends /*#__PURE__*/S.Literal("text") {}
|
|
1343
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesSelfHarm extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1344
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesSelfHarmIntent extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1345
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesSelfHarmInstructions extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1346
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesSexual extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1347
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesSexualMinors extends /*#__PURE__*/S.Literal("text") {}
|
|
1348
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesViolence extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1349
|
-
export class CreateModerationResponseResultsCategoryAppliedInputTypesViolenceGraphic extends /*#__PURE__*/S.Literal("text", "image") {}
|
|
1350
1343
|
export class CreateModerationResponse extends /*#__PURE__*/S.Class("CreateModerationResponse")({
|
|
1351
1344
|
"id": S.String,
|
|
1352
1345
|
"model": S.String,
|
|
@@ -1357,8 +1350,8 @@ export class CreateModerationResponse extends /*#__PURE__*/S.Class("CreateModera
|
|
|
1357
1350
|
"hate/threatening": S.Boolean,
|
|
1358
1351
|
"harassment": S.Boolean,
|
|
1359
1352
|
"harassment/threatening": S.Boolean,
|
|
1360
|
-
"illicit": S.Boolean,
|
|
1361
|
-
"illicit/violent": S.Boolean,
|
|
1353
|
+
"illicit": /*#__PURE__*/S.NullOr(S.Boolean),
|
|
1354
|
+
"illicit/violent": /*#__PURE__*/S.NullOr(S.Boolean),
|
|
1362
1355
|
"self-harm": S.Boolean,
|
|
1363
1356
|
"self-harm/intent": S.Boolean,
|
|
1364
1357
|
"self-harm/instructions": S.Boolean,
|
|
@@ -1383,19 +1376,19 @@ export class CreateModerationResponse extends /*#__PURE__*/S.Class("CreateModera
|
|
|
1383
1376
|
"violence/graphic": S.Number
|
|
1384
1377
|
}),
|
|
1385
1378
|
"category_applied_input_types": /*#__PURE__*/S.Struct({
|
|
1386
|
-
"hate": /*#__PURE__*/S.Array(
|
|
1387
|
-
"hate/threatening": /*#__PURE__*/S.Array(
|
|
1388
|
-
"harassment": /*#__PURE__*/S.Array(
|
|
1389
|
-
"harassment/threatening": /*#__PURE__*/S.Array(
|
|
1390
|
-
"illicit": /*#__PURE__*/S.Array(
|
|
1391
|
-
"illicit/violent": /*#__PURE__*/S.Array(
|
|
1392
|
-
"self-harm": /*#__PURE__*/S.Array(
|
|
1393
|
-
"self-harm/intent": /*#__PURE__*/S.Array(
|
|
1394
|
-
"self-harm/instructions": /*#__PURE__*/S.Array(
|
|
1395
|
-
"sexual": /*#__PURE__*/S.Array(
|
|
1396
|
-
"sexual/minors": /*#__PURE__*/S.Array(
|
|
1397
|
-
"violence": /*#__PURE__*/S.Array(
|
|
1398
|
-
"violence/graphic": /*#__PURE__*/S.Array(
|
|
1379
|
+
"hate": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1380
|
+
"hate/threatening": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1381
|
+
"harassment": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1382
|
+
"harassment/threatening": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1383
|
+
"illicit": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1384
|
+
"illicit/violent": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1385
|
+
"self-harm": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image")),
|
|
1386
|
+
"self-harm/intent": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image")),
|
|
1387
|
+
"self-harm/instructions": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image")),
|
|
1388
|
+
"sexual": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image")),
|
|
1389
|
+
"sexual/minors": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text")),
|
|
1390
|
+
"violence": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image")),
|
|
1391
|
+
"violence/graphic": /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("text", "image"))
|
|
1399
1392
|
})
|
|
1400
1393
|
}))
|
|
1401
1394
|
}) {}
|
|
@@ -1856,7 +1849,6 @@ export class ListAuditLogsResponse extends /*#__PURE__*/S.Class("ListAuditLogsRe
|
|
|
1856
1849
|
"has_more": S.Boolean
|
|
1857
1850
|
}) {}
|
|
1858
1851
|
export class UsageCostsParamsBucketWidth extends /*#__PURE__*/S.Literal("1d") {}
|
|
1859
|
-
export class UsageCostsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "line_item") {}
|
|
1860
1852
|
export class UsageCostsParams extends /*#__PURE__*/S.Struct({
|
|
1861
1853
|
"start_time": S.Int,
|
|
1862
1854
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -1869,7 +1861,7 @@ export class UsageCostsParams extends /*#__PURE__*/S.Struct({
|
|
|
1869
1861
|
"project_ids": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
1870
1862
|
nullable: true
|
|
1871
1863
|
}),
|
|
1872
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
1864
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "line_item")), {
|
|
1873
1865
|
nullable: true
|
|
1874
1866
|
}),
|
|
1875
1867
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2020,7 +2012,9 @@ export class UsageVectorStoresResult extends /*#__PURE__*/S.Struct({
|
|
|
2020
2012
|
export class UsageCodeInterpreterSessionsResultObject extends /*#__PURE__*/S.Literal("organization.usage.code_interpreter_sessions.result") {}
|
|
2021
2013
|
export class UsageCodeInterpreterSessionsResult extends /*#__PURE__*/S.Struct({
|
|
2022
2014
|
"object": UsageCodeInterpreterSessionsResultObject,
|
|
2023
|
-
"
|
|
2015
|
+
"num_sessions": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
2016
|
+
nullable: true
|
|
2017
|
+
}),
|
|
2024
2018
|
"project_id": /*#__PURE__*/S.optionalWith(S.String, {
|
|
2025
2019
|
nullable: true
|
|
2026
2020
|
})
|
|
@@ -2070,7 +2064,6 @@ export class InviteListResponseObject extends /*#__PURE__*/S.Literal("list") {}
|
|
|
2070
2064
|
export class InviteObject extends /*#__PURE__*/S.Literal("organization.invite") {}
|
|
2071
2065
|
export class InviteRole extends /*#__PURE__*/S.Literal("owner", "reader") {}
|
|
2072
2066
|
export class InviteStatus extends /*#__PURE__*/S.Literal("accepted", "expired", "pending") {}
|
|
2073
|
-
export class InviteProjectsRole extends /*#__PURE__*/S.Literal("member", "owner") {}
|
|
2074
2067
|
export class Invite extends /*#__PURE__*/S.Struct({
|
|
2075
2068
|
"object": InviteObject,
|
|
2076
2069
|
"id": S.String,
|
|
@@ -2086,7 +2079,7 @@ export class Invite extends /*#__PURE__*/S.Struct({
|
|
|
2086
2079
|
"id": /*#__PURE__*/S.optionalWith(S.String, {
|
|
2087
2080
|
nullable: true
|
|
2088
2081
|
}),
|
|
2089
|
-
"role": /*#__PURE__*/S.optionalWith(
|
|
2082
|
+
"role": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Literal("member", "owner"), {
|
|
2090
2083
|
nullable: true
|
|
2091
2084
|
})
|
|
2092
2085
|
})), {
|
|
@@ -2107,13 +2100,12 @@ export class InviteListResponse extends /*#__PURE__*/S.Class("InviteListResponse
|
|
|
2107
2100
|
})
|
|
2108
2101
|
}) {}
|
|
2109
2102
|
export class InviteRequestRole extends /*#__PURE__*/S.Literal("reader", "owner") {}
|
|
2110
|
-
export class InviteRequestProjectsRole extends /*#__PURE__*/S.Literal("member", "owner") {}
|
|
2111
2103
|
export class InviteRequest extends /*#__PURE__*/S.Class("InviteRequest")({
|
|
2112
2104
|
"email": S.String,
|
|
2113
2105
|
"role": InviteRequestRole,
|
|
2114
2106
|
"projects": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
2115
2107
|
"id": S.String,
|
|
2116
|
-
"role":
|
|
2108
|
+
"role": /*#__PURE__*/S.Literal("member", "owner")
|
|
2117
2109
|
})), {
|
|
2118
2110
|
nullable: true
|
|
2119
2111
|
})
|
|
@@ -2370,7 +2362,6 @@ export class ProjectUserDeleteResponse extends /*#__PURE__*/S.Class("ProjectUser
|
|
|
2370
2362
|
"deleted": S.Boolean
|
|
2371
2363
|
}) {}
|
|
2372
2364
|
export class UsageAudioSpeechesParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2373
|
-
export class UsageAudioSpeechesParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model") {}
|
|
2374
2365
|
export class UsageAudioSpeechesParams extends /*#__PURE__*/S.Struct({
|
|
2375
2366
|
"start_time": S.Int,
|
|
2376
2367
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2392,7 +2383,7 @@ export class UsageAudioSpeechesParams extends /*#__PURE__*/S.Struct({
|
|
|
2392
2383
|
"models": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2393
2384
|
nullable: true
|
|
2394
2385
|
}),
|
|
2395
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2386
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model")), {
|
|
2396
2387
|
nullable: true
|
|
2397
2388
|
}),
|
|
2398
2389
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2403,7 +2394,6 @@ export class UsageAudioSpeechesParams extends /*#__PURE__*/S.Struct({
|
|
|
2403
2394
|
})
|
|
2404
2395
|
}) {}
|
|
2405
2396
|
export class UsageAudioTranscriptionsParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2406
|
-
export class UsageAudioTranscriptionsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model") {}
|
|
2407
2397
|
export class UsageAudioTranscriptionsParams extends /*#__PURE__*/S.Struct({
|
|
2408
2398
|
"start_time": S.Int,
|
|
2409
2399
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2425,7 +2415,7 @@ export class UsageAudioTranscriptionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2425
2415
|
"models": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2426
2416
|
nullable: true
|
|
2427
2417
|
}),
|
|
2428
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2418
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model")), {
|
|
2429
2419
|
nullable: true
|
|
2430
2420
|
}),
|
|
2431
2421
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2436,7 +2426,6 @@ export class UsageAudioTranscriptionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2436
2426
|
})
|
|
2437
2427
|
}) {}
|
|
2438
2428
|
export class UsageCodeInterpreterSessionsParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2439
|
-
export class UsageCodeInterpreterSessionsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id") {}
|
|
2440
2429
|
export class UsageCodeInterpreterSessionsParams extends /*#__PURE__*/S.Struct({
|
|
2441
2430
|
"start_time": S.Int,
|
|
2442
2431
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2449,7 +2438,7 @@ export class UsageCodeInterpreterSessionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2449
2438
|
"project_ids": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2450
2439
|
nullable: true
|
|
2451
2440
|
}),
|
|
2452
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2441
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id")), {
|
|
2453
2442
|
nullable: true
|
|
2454
2443
|
}),
|
|
2455
2444
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2460,7 +2449,6 @@ export class UsageCodeInterpreterSessionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2460
2449
|
})
|
|
2461
2450
|
}) {}
|
|
2462
2451
|
export class UsageCompletionsParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2463
|
-
export class UsageCompletionsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model", "batch") {}
|
|
2464
2452
|
export class UsageCompletionsParams extends /*#__PURE__*/S.Struct({
|
|
2465
2453
|
"start_time": S.Int,
|
|
2466
2454
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2485,7 +2473,7 @@ export class UsageCompletionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2485
2473
|
"batch": /*#__PURE__*/S.optionalWith(S.Boolean, {
|
|
2486
2474
|
nullable: true
|
|
2487
2475
|
}),
|
|
2488
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2476
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model", "batch")), {
|
|
2489
2477
|
nullable: true
|
|
2490
2478
|
}),
|
|
2491
2479
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2496,7 +2484,6 @@ export class UsageCompletionsParams extends /*#__PURE__*/S.Struct({
|
|
|
2496
2484
|
})
|
|
2497
2485
|
}) {}
|
|
2498
2486
|
export class UsageEmbeddingsParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2499
|
-
export class UsageEmbeddingsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model") {}
|
|
2500
2487
|
export class UsageEmbeddingsParams extends /*#__PURE__*/S.Struct({
|
|
2501
2488
|
"start_time": S.Int,
|
|
2502
2489
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2518,7 +2505,7 @@ export class UsageEmbeddingsParams extends /*#__PURE__*/S.Struct({
|
|
|
2518
2505
|
"models": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2519
2506
|
nullable: true
|
|
2520
2507
|
}),
|
|
2521
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2508
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model")), {
|
|
2522
2509
|
nullable: true
|
|
2523
2510
|
}),
|
|
2524
2511
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2529,9 +2516,6 @@ export class UsageEmbeddingsParams extends /*#__PURE__*/S.Struct({
|
|
|
2529
2516
|
})
|
|
2530
2517
|
}) {}
|
|
2531
2518
|
export class UsageImagesParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2532
|
-
export class UsageImagesParamsSources extends /*#__PURE__*/S.Literal("image.generation", "image.edit", "image.variation") {}
|
|
2533
|
-
export class UsageImagesParamsSizes extends /*#__PURE__*/S.Literal("256x256", "512x512", "1024x1024", "1792x1792", "1024x1792") {}
|
|
2534
|
-
export class UsageImagesParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model", "size", "source") {}
|
|
2535
2519
|
export class UsageImagesParams extends /*#__PURE__*/S.Struct({
|
|
2536
2520
|
"start_time": S.Int,
|
|
2537
2521
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2541,10 +2525,10 @@ export class UsageImagesParams extends /*#__PURE__*/S.Struct({
|
|
|
2541
2525
|
nullable: true,
|
|
2542
2526
|
default: () => "1d"
|
|
2543
2527
|
}),
|
|
2544
|
-
"sources": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2528
|
+
"sources": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("image.generation", "image.edit", "image.variation")), {
|
|
2545
2529
|
nullable: true
|
|
2546
2530
|
}),
|
|
2547
|
-
"sizes": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2531
|
+
"sizes": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("256x256", "512x512", "1024x1024", "1792x1792", "1024x1792")), {
|
|
2548
2532
|
nullable: true
|
|
2549
2533
|
}),
|
|
2550
2534
|
"project_ids": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
@@ -2559,7 +2543,7 @@ export class UsageImagesParams extends /*#__PURE__*/S.Struct({
|
|
|
2559
2543
|
"models": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2560
2544
|
nullable: true
|
|
2561
2545
|
}),
|
|
2562
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2546
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model", "size", "source")), {
|
|
2563
2547
|
nullable: true
|
|
2564
2548
|
}),
|
|
2565
2549
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2570,7 +2554,6 @@ export class UsageImagesParams extends /*#__PURE__*/S.Struct({
|
|
|
2570
2554
|
})
|
|
2571
2555
|
}) {}
|
|
2572
2556
|
export class UsageModerationsParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2573
|
-
export class UsageModerationsParamsGroupBy extends /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model") {}
|
|
2574
2557
|
export class UsageModerationsParams extends /*#__PURE__*/S.Struct({
|
|
2575
2558
|
"start_time": S.Int,
|
|
2576
2559
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2592,7 +2575,7 @@ export class UsageModerationsParams extends /*#__PURE__*/S.Struct({
|
|
|
2592
2575
|
"models": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2593
2576
|
nullable: true
|
|
2594
2577
|
}),
|
|
2595
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2578
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id", "user_id", "api_key_id", "model")), {
|
|
2596
2579
|
nullable: true
|
|
2597
2580
|
}),
|
|
2598
2581
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2603,7 +2586,6 @@ export class UsageModerationsParams extends /*#__PURE__*/S.Struct({
|
|
|
2603
2586
|
})
|
|
2604
2587
|
}) {}
|
|
2605
2588
|
export class UsageVectorStoresParamsBucketWidth extends /*#__PURE__*/S.Literal("1m", "1h", "1d") {}
|
|
2606
|
-
export class UsageVectorStoresParamsGroupBy extends /*#__PURE__*/S.Literal("project_id") {}
|
|
2607
2589
|
export class UsageVectorStoresParams extends /*#__PURE__*/S.Struct({
|
|
2608
2590
|
"start_time": S.Int,
|
|
2609
2591
|
"end_time": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2616,7 +2598,7 @@ export class UsageVectorStoresParams extends /*#__PURE__*/S.Struct({
|
|
|
2616
2598
|
"project_ids": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(S.String), {
|
|
2617
2599
|
nullable: true
|
|
2618
2600
|
}),
|
|
2619
|
-
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
2601
|
+
"group_by": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("project_id")), {
|
|
2620
2602
|
nullable: true
|
|
2621
2603
|
}),
|
|
2622
2604
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
@@ -2670,8 +2652,7 @@ export class RealtimeSessionCreateRequestModel extends /*#__PURE__*/S.Literal("g
|
|
|
2670
2652
|
export class RealtimeSessionCreateRequestVoice extends /*#__PURE__*/S.Literal("alloy", "ash", "ballad", "coral", "echo", "sage", "shimmer", "verse") {}
|
|
2671
2653
|
export class RealtimeSessionCreateRequestInputAudioFormat extends /*#__PURE__*/S.Literal("pcm16", "g711_ulaw", "g711_alaw") {}
|
|
2672
2654
|
export class RealtimeSessionCreateRequestOutputAudioFormat extends /*#__PURE__*/S.Literal("pcm16", "g711_ulaw", "g711_alaw") {}
|
|
2673
|
-
export class
|
|
2674
|
-
export class RealtimeSessionCreateRequestMaxResponseOutputTokens extends /*#__PURE__*/S.Literal("inf") {}
|
|
2655
|
+
export class RealtimeSessionCreateRequestMaxResponseOutputTokensEnum extends /*#__PURE__*/S.Literal("inf") {}
|
|
2675
2656
|
export class RealtimeSessionCreateRequest extends /*#__PURE__*/S.Class("RealtimeSessionCreateRequest")({
|
|
2676
2657
|
"model": /*#__PURE__*/S.optionalWith(RealtimeSessionCreateRequestModel, {
|
|
2677
2658
|
nullable: true
|
|
@@ -2722,7 +2703,7 @@ export class RealtimeSessionCreateRequest extends /*#__PURE__*/S.Class("Realtime
|
|
|
2722
2703
|
nullable: true
|
|
2723
2704
|
}),
|
|
2724
2705
|
"tools": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
2725
|
-
"type": /*#__PURE__*/S.optionalWith(
|
|
2706
|
+
"type": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Literal("function"), {
|
|
2726
2707
|
nullable: true
|
|
2727
2708
|
}),
|
|
2728
2709
|
"name": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -2746,13 +2727,12 @@ export class RealtimeSessionCreateRequest extends /*#__PURE__*/S.Class("Realtime
|
|
|
2746
2727
|
"temperature": /*#__PURE__*/S.optionalWith(S.Number, {
|
|
2747
2728
|
nullable: true
|
|
2748
2729
|
}),
|
|
2749
|
-
"max_response_output_tokens": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.Int,
|
|
2730
|
+
"max_response_output_tokens": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.Int, RealtimeSessionCreateRequestMaxResponseOutputTokensEnum), {
|
|
2750
2731
|
nullable: true
|
|
2751
2732
|
})
|
|
2752
2733
|
}) {}
|
|
2753
2734
|
export class RealtimeSessionCreateResponseVoice extends /*#__PURE__*/S.Literal("alloy", "ash", "ballad", "coral", "echo", "sage", "shimmer", "verse") {}
|
|
2754
|
-
export class
|
|
2755
|
-
export class RealtimeSessionCreateResponseMaxResponseOutputTokens extends /*#__PURE__*/S.Literal("inf") {}
|
|
2735
|
+
export class RealtimeSessionCreateResponseMaxResponseOutputTokensEnum extends /*#__PURE__*/S.Literal("inf") {}
|
|
2756
2736
|
export class RealtimeSessionCreateResponse extends /*#__PURE__*/S.Class("RealtimeSessionCreateResponse")({
|
|
2757
2737
|
"client_secret": /*#__PURE__*/S.Struct({
|
|
2758
2738
|
"value": S.String,
|
|
@@ -2794,7 +2774,7 @@ export class RealtimeSessionCreateResponse extends /*#__PURE__*/S.Class("Realtim
|
|
|
2794
2774
|
nullable: true
|
|
2795
2775
|
}),
|
|
2796
2776
|
"tools": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
2797
|
-
"type": /*#__PURE__*/S.optionalWith(
|
|
2777
|
+
"type": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Literal("function"), {
|
|
2798
2778
|
nullable: true
|
|
2799
2779
|
}),
|
|
2800
2780
|
"name": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -2818,7 +2798,7 @@ export class RealtimeSessionCreateResponse extends /*#__PURE__*/S.Class("Realtim
|
|
|
2818
2798
|
"temperature": /*#__PURE__*/S.optionalWith(S.Number, {
|
|
2819
2799
|
nullable: true
|
|
2820
2800
|
}),
|
|
2821
|
-
"max_response_output_tokens": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.Int,
|
|
2801
|
+
"max_response_output_tokens": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.Int, RealtimeSessionCreateResponseMaxResponseOutputTokensEnum), {
|
|
2822
2802
|
nullable: true
|
|
2823
2803
|
})
|
|
2824
2804
|
}) {}
|
|
@@ -2873,7 +2853,6 @@ export class CreateMessageRequest extends /*#__PURE__*/S.Struct({
|
|
|
2873
2853
|
nullable: true
|
|
2874
2854
|
})
|
|
2875
2855
|
}) {}
|
|
2876
|
-
export class CreateThreadRequestToolResourcesFileSearchVectorStoresChunkingStrategyType extends /*#__PURE__*/S.Literal("static") {}
|
|
2877
2856
|
export class CreateThreadRequest extends /*#__PURE__*/S.Class("CreateThreadRequest")({
|
|
2878
2857
|
"messages": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(CreateMessageRequest), {
|
|
2879
2858
|
nullable: true
|
|
@@ -2941,7 +2920,7 @@ export class ThreadObject extends /*#__PURE__*/S.Class("ThreadObject")({
|
|
|
2941
2920
|
})),
|
|
2942
2921
|
"metadata": /*#__PURE__*/S.NullOr(Metadata)
|
|
2943
2922
|
}) {}
|
|
2944
|
-
export class
|
|
2923
|
+
export class CreateThreadAndRunRequestModelEnum extends /*#__PURE__*/S.Literal("gpt-4o", "gpt-4o-2024-11-20", "gpt-4o-2024-08-06", "gpt-4o-2024-05-13", "gpt-4o-mini", "gpt-4o-mini-2024-07-18", "gpt-4-turbo", "gpt-4-turbo-2024-04-09", "gpt-4-0125-preview", "gpt-4-turbo-preview", "gpt-4-1106-preview", "gpt-4-vision-preview", "gpt-4", "gpt-4-0314", "gpt-4-0613", "gpt-4-32k", "gpt-4-32k-0314", "gpt-4-32k-0613", "gpt-3.5-turbo", "gpt-3.5-turbo-16k", "gpt-3.5-turbo-0613", "gpt-3.5-turbo-1106", "gpt-3.5-turbo-0125", "gpt-3.5-turbo-16k-0613") {}
|
|
2945
2924
|
export class TruncationObjectType extends /*#__PURE__*/S.Literal("auto", "last_messages") {}
|
|
2946
2925
|
export class TruncationObject extends /*#__PURE__*/S.Struct({
|
|
2947
2926
|
"type": TruncationObjectType,
|
|
@@ -2949,6 +2928,7 @@ export class TruncationObject extends /*#__PURE__*/S.Struct({
|
|
|
2949
2928
|
nullable: true
|
|
2950
2929
|
})
|
|
2951
2930
|
}) {}
|
|
2931
|
+
export class AssistantsApiToolChoiceOptionEnum extends /*#__PURE__*/S.Literal("none", "auto", "required") {}
|
|
2952
2932
|
export class AssistantsNamedToolChoiceType extends /*#__PURE__*/S.Literal("function", "code_interpreter", "file_search") {}
|
|
2953
2933
|
export class AssistantsNamedToolChoice extends /*#__PURE__*/S.Struct({
|
|
2954
2934
|
"type": AssistantsNamedToolChoiceType,
|
|
@@ -2958,13 +2938,13 @@ export class AssistantsNamedToolChoice extends /*#__PURE__*/S.Struct({
|
|
|
2958
2938
|
nullable: true
|
|
2959
2939
|
})
|
|
2960
2940
|
}) {}
|
|
2961
|
-
export class AssistantsApiToolChoiceOption extends /*#__PURE__*/S.Union(
|
|
2941
|
+
export class AssistantsApiToolChoiceOption extends /*#__PURE__*/S.Union(AssistantsApiToolChoiceOptionEnum, AssistantsNamedToolChoice) {}
|
|
2962
2942
|
export class CreateThreadAndRunRequest extends /*#__PURE__*/S.Class("CreateThreadAndRunRequest")({
|
|
2963
2943
|
"assistant_id": S.String,
|
|
2964
2944
|
"thread": /*#__PURE__*/S.optionalWith(CreateThreadRequest, {
|
|
2965
2945
|
nullable: true
|
|
2966
2946
|
}),
|
|
2967
|
-
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String,
|
|
2947
|
+
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, CreateThreadAndRunRequestModelEnum), {
|
|
2968
2948
|
nullable: true
|
|
2969
2949
|
}),
|
|
2970
2950
|
"instructions": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -3244,18 +3224,20 @@ export class ListRunsResponse extends /*#__PURE__*/S.Class("ListRunsResponse")({
|
|
|
3244
3224
|
"last_id": S.String,
|
|
3245
3225
|
"has_more": S.Boolean
|
|
3246
3226
|
}) {}
|
|
3247
|
-
export class CreateRunParamsInclude extends /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content") {}
|
|
3248
3227
|
export class CreateRunParams extends /*#__PURE__*/S.Struct({
|
|
3249
|
-
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
3228
|
+
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content")), {
|
|
3250
3229
|
nullable: true
|
|
3251
3230
|
})
|
|
3252
3231
|
}) {}
|
|
3253
|
-
export class CreateRunRequestModel extends /*#__PURE__*/S.Literal("gpt-4o", "gpt-4o-2024-11-20", "gpt-4o-2024-08-06", "gpt-4o-2024-05-13", "gpt-4o-mini", "gpt-4o-mini-2024-07-18", "gpt-4-turbo", "gpt-4-turbo-2024-04-09", "gpt-4-0125-preview", "gpt-4-turbo-preview", "gpt-4-1106-preview", "gpt-4-vision-preview", "gpt-4", "gpt-4-0314", "gpt-4-0613", "gpt-4-32k", "gpt-4-32k-0314", "gpt-4-32k-0613", "gpt-3.5-turbo", "gpt-3.5-turbo-16k", "gpt-3.5-turbo-0613", "gpt-3.5-turbo-1106", "gpt-3.5-turbo-0125", "gpt-3.5-turbo-16k-0613") {}
|
|
3254
3232
|
export class CreateRunRequest extends /*#__PURE__*/S.Class("CreateRunRequest")({
|
|
3255
3233
|
"assistant_id": S.String,
|
|
3256
|
-
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String,
|
|
3234
|
+
"model": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Union(S.String, AssistantSupportedModels), {
|
|
3257
3235
|
nullable: true
|
|
3258
3236
|
}),
|
|
3237
|
+
"reasoning_effort": /*#__PURE__*/S.optionalWith(ReasoningEffort, {
|
|
3238
|
+
nullable: true,
|
|
3239
|
+
default: () => "medium"
|
|
3240
|
+
}),
|
|
3259
3241
|
"instructions": /*#__PURE__*/S.optionalWith(S.String, {
|
|
3260
3242
|
nullable: true
|
|
3261
3243
|
}),
|
|
@@ -3308,7 +3290,6 @@ export class ModifyRunRequest extends /*#__PURE__*/S.Class("ModifyRunRequest")({
|
|
|
3308
3290
|
})
|
|
3309
3291
|
}) {}
|
|
3310
3292
|
export class ListRunStepsParamsOrder extends /*#__PURE__*/S.Literal("asc", "desc") {}
|
|
3311
|
-
export class ListRunStepsParamsInclude extends /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content") {}
|
|
3312
3293
|
export class ListRunStepsParams extends /*#__PURE__*/S.Struct({
|
|
3313
3294
|
"limit": /*#__PURE__*/S.optionalWith(S.Int, {
|
|
3314
3295
|
nullable: true,
|
|
@@ -3324,7 +3305,7 @@ export class ListRunStepsParams extends /*#__PURE__*/S.Struct({
|
|
|
3324
3305
|
"before": /*#__PURE__*/S.optionalWith(S.String, {
|
|
3325
3306
|
nullable: true
|
|
3326
3307
|
}),
|
|
3327
|
-
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
3308
|
+
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content")), {
|
|
3328
3309
|
nullable: true
|
|
3329
3310
|
})
|
|
3330
3311
|
}) {}
|
|
@@ -3369,13 +3350,12 @@ export class RunStepDetailsToolCallsFileSearchRankingOptionsObject extends /*#__
|
|
|
3369
3350
|
"ranker": RunStepDetailsToolCallsFileSearchRankingOptionsObjectRanker,
|
|
3370
3351
|
"score_threshold": /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(1))
|
|
3371
3352
|
}) {}
|
|
3372
|
-
export class RunStepDetailsToolCallsFileSearchResultObjectContentType extends /*#__PURE__*/S.Literal("text") {}
|
|
3373
3353
|
export class RunStepDetailsToolCallsFileSearchResultObject extends /*#__PURE__*/S.Struct({
|
|
3374
3354
|
"file_id": S.String,
|
|
3375
3355
|
"file_name": S.String,
|
|
3376
3356
|
"score": /*#__PURE__*/S.Number.pipe( /*#__PURE__*/S.greaterThanOrEqualTo(0), /*#__PURE__*/S.lessThanOrEqualTo(1)),
|
|
3377
3357
|
"content": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Struct({
|
|
3378
|
-
"type": /*#__PURE__*/S.optionalWith(
|
|
3358
|
+
"type": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Literal("text"), {
|
|
3379
3359
|
nullable: true
|
|
3380
3360
|
}),
|
|
3381
3361
|
"text": /*#__PURE__*/S.optionalWith(S.String, {
|
|
@@ -3448,9 +3428,8 @@ export class ListRunStepsResponse extends /*#__PURE__*/S.Class("ListRunStepsResp
|
|
|
3448
3428
|
"last_id": S.String,
|
|
3449
3429
|
"has_more": S.Boolean
|
|
3450
3430
|
}) {}
|
|
3451
|
-
export class GetRunStepParamsInclude extends /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content") {}
|
|
3452
3431
|
export class GetRunStepParams extends /*#__PURE__*/S.Struct({
|
|
3453
|
-
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array(
|
|
3432
|
+
"include[]": /*#__PURE__*/S.optionalWith( /*#__PURE__*/S.Array( /*#__PURE__*/S.Literal("step_details.tool_calls[*].file_search.results[*].content")), {
|
|
3454
3433
|
nullable: true
|
|
3455
3434
|
})
|
|
3456
3435
|
}) {}
|