openai 0.78.0 → 0.79.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +80 -0
- data/README.md +241 -8
- data/SECURITY.md +6 -22
- data/azure.md +110 -0
- data/bedrock.md +132 -0
- data/examples/mtls_custom_http_client.rb +61 -0
- data/lib/openai/auth/workload_identity.rb +13 -2
- data/lib/openai/auth/workload_identity_auth.rb +2 -1
- data/lib/openai/client.rb +29 -6
- data/lib/openai/errors.rb +11 -1
- data/lib/openai/helpers/streaming/chat_completion_stream.rb +3 -3
- data/lib/openai/helpers/streaming/response_stream.rb +5 -6
- data/lib/openai/helpers/structured_output/base_model.rb +20 -19
- data/lib/openai/helpers/structured_output/json_schema_converter.rb +12 -5
- data/lib/openai/http_client.rb +99 -7
- data/lib/openai/internal/conversation_cursor_page.rb +5 -6
- data/lib/openai/internal/cursor_page.rb +3 -3
- data/lib/openai/internal/logging.rb +419 -0
- data/lib/openai/internal/next_cursor_page.rb +5 -6
- data/lib/openai/internal/page.rb +2 -2
- data/lib/openai/internal/provider.rb +7 -1
- data/lib/openai/internal/read_io_adapter.rb +42 -18
- data/lib/openai/internal/stream.rb +2 -2
- data/lib/openai/internal/transport/base_client.rb +137 -37
- data/lib/openai/internal/type/array_of.rb +6 -4
- data/lib/openai/internal/type/base_model.rb +39 -1
- data/lib/openai/internal/type/base_page.rb +19 -2
- data/lib/openai/internal/type/base_stream.rb +39 -7
- data/lib/openai/internal/type/hash_of.rb +3 -3
- data/lib/openai/internal/util.rb +52 -27
- data/lib/openai/models/admin/organization/audit_log_list_params.rb +3 -1
- data/lib/openai/models/admin/organization/audit_log_list_response.rb +33 -11
- data/lib/openai/models/admin/organization/groups/role_list_response.rb +5 -1
- data/lib/openai/models/admin/organization/groups/role_retrieve_response.rb +5 -1
- data/lib/openai/models/admin/organization/projects/groups/role_list_response.rb +6 -1
- data/lib/openai/models/admin/organization/projects/groups/role_retrieve_response.rb +6 -1
- data/lib/openai/models/admin/organization/projects/service_account_create_response.rb +3 -1
- data/lib/openai/models/admin/organization/projects/users/role_list_response.rb +6 -1
- data/lib/openai/models/admin/organization/projects/users/role_retrieve_response.rb +6 -1
- data/lib/openai/models/admin/organization/users/role_list_response.rb +5 -1
- data/lib/openai/models/admin/organization/users/role_retrieve_response.rb +5 -1
- data/lib/openai/models/all_models.rb +3 -0
- data/lib/openai/models/audio/transcription_create_params.rb +7 -1
- data/lib/openai/models/audio/translation_create_params.rb +7 -1
- data/lib/openai/models/beta/beta_response.rb +9 -0
- data/lib/openai/models/beta/beta_response_stream_event.rb +1 -1
- data/lib/openai/models/beta/beta_responses_client_event.rb +28 -3
- data/lib/openai/models/beta/beta_responses_server_event.rb +1037 -61
- data/lib/openai/models/beta/response_compact_params.rb +9 -0
- data/lib/openai/models/beta/response_create_params.rb +9 -0
- data/lib/openai/models/containers/file_create_params.rb +4 -0
- data/lib/openai/models/content_provenance_check_create_params.rb +4 -0
- data/lib/openai/models/file_create_params.rb +4 -0
- data/lib/openai/models/image_create_variation_params.rb +4 -0
- data/lib/openai/models/image_edit_params.rb +8 -0
- data/lib/openai/models/responses/response_compact_params.rb +9 -0
- data/lib/openai/models/responses/response_stream_event.rb +1 -1
- data/lib/openai/models/responses/responses_client_event.rb +13 -1
- data/lib/openai/models/responses/responses_server_event.rb +1027 -54
- data/lib/openai/models/responses_model.rb +3 -0
- data/lib/openai/models/skill_create_params.rb +4 -0
- data/lib/openai/models/skills/version_create_params.rb +4 -0
- data/lib/openai/models/uploads/part_create_params.rb +4 -0
- data/lib/openai/models/vector_store_search_response.rb +3 -1
- data/lib/openai/models/video_create_character_params.rb +4 -0
- data/lib/openai/models/video_create_params.rb +4 -0
- data/lib/openai/models/video_edit_params.rb +4 -0
- data/lib/openai/models/video_extend_params.rb +4 -0
- data/lib/openai/models.rb +9 -1
- data/lib/openai/net_http_client.rb +20 -6
- data/lib/openai/providers/azure.rb +216 -0
- data/lib/openai/providers/bedrock.rb +3 -1
- data/lib/openai/resources/admin/organization/projects/groups/roles.rb +1 -1
- data/lib/openai/resources/admin/organization/projects/groups.rb +1 -1
- data/lib/openai/resources/admin/organization/projects/users/roles.rb +1 -1
- data/lib/openai/resources/admin/organization/projects.rb +4 -2
- data/lib/openai/resources/audio/transcriptions.rb +8 -0
- data/lib/openai/resources/audio/translations.rb +4 -0
- data/lib/openai/resources/beta/responses.rb +1 -1
- data/lib/openai/resources/beta/threads/runs/steps.rb +2 -2
- data/lib/openai/resources/containers/files.rb +4 -0
- data/lib/openai/resources/content_provenance_checks.rb +4 -0
- data/lib/openai/resources/conversations/items.rb +1 -1
- data/lib/openai/resources/evals/runs/output_items.rb +1 -1
- data/lib/openai/resources/files.rb +4 -0
- data/lib/openai/resources/images.rb +12 -0
- data/lib/openai/resources/responses.rb +3 -2
- data/lib/openai/resources/skills/versions.rb +4 -0
- data/lib/openai/resources/skills.rb +4 -0
- data/lib/openai/resources/uploads/parts.rb +4 -0
- data/lib/openai/resources/vector_stores/file_batches.rb +1 -1
- data/lib/openai/resources/videos.rb +38 -0
- data/lib/openai/resources/webhooks.rb +18 -6
- data/lib/openai/version.rb +1 -1
- data/lib/openai.rb +111 -107
- data/rbi/openai/auth.rbi +4 -4
- data/rbi/openai/client.rbi +13 -3
- data/rbi/openai/errors.rbi +7 -0
- data/rbi/openai/helpers/streaming/events.rbi +12 -0
- data/rbi/openai/http_client.rbi +62 -2
- data/rbi/openai/internal/logging.rbi +192 -0
- data/rbi/openai/internal/provider.rbi +3 -0
- data/rbi/openai/internal/read_io_adapter.rbi +6 -1
- data/rbi/openai/internal/transport/base_client.rbi +61 -7
- data/rbi/openai/internal/type/base_model.rbi +24 -1
- data/rbi/openai/internal/type/base_page.rbi +13 -2
- data/rbi/openai/internal/type/base_stream.rbi +15 -4
- data/rbi/openai/internal/util.rbi +26 -2
- data/rbi/openai/models/admin/organization/audit_log_list_params.rbi +5 -0
- data/rbi/openai/models/admin/organization/audit_log_list_response.rbi +5 -0
- data/rbi/openai/models/all_models.rbi +15 -0
- data/rbi/openai/models/audio/transcription_create_params.rbi +14 -2
- data/rbi/openai/models/audio/translation_create_params.rbi +14 -2
- data/rbi/openai/models/beta/beta_response.rbi +15 -0
- data/rbi/openai/models/beta/beta_response_stream_event.rbi +1 -1
- data/rbi/openai/models/beta/beta_responses_client_event.rbi +37 -1
- data/rbi/openai/models/beta/beta_responses_server_event.rbi +3791 -54
- data/rbi/openai/models/beta/response_compact_params.rbi +15 -0
- data/rbi/openai/models/beta/response_create_params.rbi +15 -0
- data/rbi/openai/models/containers/file_create_params.rbi +8 -0
- data/rbi/openai/models/content_provenance_check_create_params.rbi +8 -0
- data/rbi/openai/models/file_create_params.rbi +8 -0
- data/rbi/openai/models/image_create_variation_params.rbi +8 -0
- data/rbi/openai/models/image_edit_params.rbi +16 -0
- data/rbi/openai/models/responses/response_compact_params.rbi +15 -0
- data/rbi/openai/models/responses/response_stream_event.rbi +1 -1
- data/rbi/openai/models/responses/responses_client_event.rbi +19 -0
- data/rbi/openai/models/responses/responses_server_event.rbi +3282 -53
- data/rbi/openai/models/responses_model.rbi +15 -0
- data/rbi/openai/models/skill_create_params.rbi +8 -0
- data/rbi/openai/models/skills/version_create_params.rbi +8 -0
- data/rbi/openai/models/uploads/part_create_params.rbi +8 -0
- data/rbi/openai/models/video_create_character_params.rbi +8 -0
- data/rbi/openai/models/video_create_params.rbi +8 -0
- data/rbi/openai/models/video_edit_params.rbi +8 -0
- data/rbi/openai/models/video_extend_params.rbi +8 -0
- data/rbi/openai/net_http_client.rbi +2 -2
- data/rbi/openai/providers.rbi +9 -0
- data/rbi/openai/resources/audio/transcriptions.rbi +14 -2
- data/rbi/openai/resources/audio/translations.rbi +7 -1
- data/rbi/openai/resources/containers/files.rbi +4 -0
- data/rbi/openai/resources/content_provenance_checks.rbi +4 -0
- data/rbi/openai/resources/files.rbi +4 -0
- data/rbi/openai/resources/images.rbi +20 -0
- data/rbi/openai/resources/skills/versions.rbi +4 -0
- data/rbi/openai/resources/skills.rbi +4 -0
- data/rbi/openai/resources/uploads/parts.rbi +4 -0
- data/rbi/openai/resources/videos.rbi +16 -0
- data/sig/openai/client.rbs +6 -2
- data/sig/openai/errors.rbs +5 -0
- data/sig/openai/http_client.rbs +37 -2
- data/sig/openai/internal/logging.rbs +88 -0
- data/sig/openai/internal/provider.rbs +3 -1
- data/sig/openai/internal/read_io_adapter.rbs +3 -1
- data/sig/openai/internal/transport/base_client.rbs +33 -5
- data/sig/openai/internal/type/base_model.rbs +13 -0
- data/sig/openai/internal/type/base_page.rbs +8 -1
- data/sig/openai/internal/type/base_stream.rbs +8 -2
- data/sig/openai/internal/util.rbs +12 -0
- data/sig/openai/models/admin/organization/audit_log_list_params.rbs +2 -0
- data/sig/openai/models/admin/organization/audit_log_list_response.rbs +2 -0
- data/sig/openai/models/all_models.rbs +6 -0
- data/sig/openai/models/beta/beta_response.rbs +6 -0
- data/sig/openai/models/beta/beta_responses_client_event.rbs +13 -0
- data/sig/openai/models/beta/beta_responses_server_event.rbs +1946 -54
- data/sig/openai/models/beta/response_compact_params.rbs +6 -0
- data/sig/openai/models/beta/response_create_params.rbs +6 -0
- data/sig/openai/models/responses/response_compact_params.rbs +6 -0
- data/sig/openai/models/responses/responses_client_event.rbs +7 -0
- data/sig/openai/models/responses/responses_server_event.rbs +1786 -53
- data/sig/openai/models/responses_model.rbs +6 -0
- data/sig/openai/net_http_client.rbs +2 -2
- data/sig/openai/providers.rbs +6 -0
- metadata +24 -1
|
@@ -759,6 +759,21 @@ module OpenAI
|
|
|
759
759
|
:"gpt-5.1-codex-max",
|
|
760
760
|
OpenAI::Beta::ResponseCompactParams::Model::TaggedSymbol
|
|
761
761
|
)
|
|
762
|
+
GPT_DAYBREAK_BLUE_LATEST =
|
|
763
|
+
T.let(
|
|
764
|
+
:"gpt-daybreak-blue-latest",
|
|
765
|
+
OpenAI::Beta::ResponseCompactParams::Model::TaggedSymbol
|
|
766
|
+
)
|
|
767
|
+
GPT_DAYBREAK_RED_LATEST =
|
|
768
|
+
T.let(
|
|
769
|
+
:"gpt-daybreak-red-latest",
|
|
770
|
+
OpenAI::Beta::ResponseCompactParams::Model::TaggedSymbol
|
|
771
|
+
)
|
|
772
|
+
GPT_5_6_CYBER =
|
|
773
|
+
T.let(
|
|
774
|
+
:"gpt-5.6-cyber",
|
|
775
|
+
OpenAI::Beta::ResponseCompactParams::Model::TaggedSymbol
|
|
776
|
+
)
|
|
762
777
|
end
|
|
763
778
|
|
|
764
779
|
# Text, image, or file inputs to the model, used to generate a response
|
|
@@ -1522,6 +1522,21 @@ module OpenAI
|
|
|
1522
1522
|
:"gpt-5.1-codex-max",
|
|
1523
1523
|
OpenAI::Beta::ResponseCreateParams::Model::TaggedSymbol
|
|
1524
1524
|
)
|
|
1525
|
+
GPT_DAYBREAK_BLUE_LATEST =
|
|
1526
|
+
T.let(
|
|
1527
|
+
:"gpt-daybreak-blue-latest",
|
|
1528
|
+
OpenAI::Beta::ResponseCreateParams::Model::TaggedSymbol
|
|
1529
|
+
)
|
|
1530
|
+
GPT_DAYBREAK_RED_LATEST =
|
|
1531
|
+
T.let(
|
|
1532
|
+
:"gpt-daybreak-red-latest",
|
|
1533
|
+
OpenAI::Beta::ResponseCreateParams::Model::TaggedSymbol
|
|
1534
|
+
)
|
|
1535
|
+
GPT_5_6_CYBER =
|
|
1536
|
+
T.let(
|
|
1537
|
+
:"gpt-5.6-cyber",
|
|
1538
|
+
OpenAI::Beta::ResponseCreateParams::Model::TaggedSymbol
|
|
1539
|
+
)
|
|
1525
1540
|
end
|
|
1526
1541
|
|
|
1527
1542
|
class Moderation < OpenAI::Internal::Type::BaseModel
|
|
@@ -19,6 +19,10 @@ module OpenAI
|
|
|
19
19
|
attr_accessor :container_id
|
|
20
20
|
|
|
21
21
|
# The File object (not file name) to be uploaded.
|
|
22
|
+
#
|
|
23
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
24
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
25
|
+
# content type.
|
|
22
26
|
sig { returns(T.nilable(OpenAI::Internal::FileInput)) }
|
|
23
27
|
attr_reader :file
|
|
24
28
|
|
|
@@ -43,6 +47,10 @@ module OpenAI
|
|
|
43
47
|
def self.new(
|
|
44
48
|
container_id:,
|
|
45
49
|
# The File object (not file name) to be uploaded.
|
|
50
|
+
#
|
|
51
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
52
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
53
|
+
# content type.
|
|
46
54
|
file: nil,
|
|
47
55
|
# Name of the file to create.
|
|
48
56
|
file_id: nil,
|
|
@@ -15,6 +15,10 @@ module OpenAI
|
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
# The image or audio file to check for supported OpenAI provenance signals.
|
|
18
|
+
#
|
|
19
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
20
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
21
|
+
# content type.
|
|
18
22
|
sig { returns(OpenAI::Internal::FileInput) }
|
|
19
23
|
attr_accessor :file
|
|
20
24
|
|
|
@@ -26,6 +30,10 @@ module OpenAI
|
|
|
26
30
|
end
|
|
27
31
|
def self.new(
|
|
28
32
|
# The image or audio file to check for supported OpenAI provenance signals.
|
|
33
|
+
#
|
|
34
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
35
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
36
|
+
# content type.
|
|
29
37
|
file:,
|
|
30
38
|
request_options: {}
|
|
31
39
|
)
|
|
@@ -12,6 +12,10 @@ module OpenAI
|
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
# The File object (not file name) to be uploaded.
|
|
15
|
+
#
|
|
16
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
17
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
18
|
+
# content type.
|
|
15
19
|
sig { returns(OpenAI::Internal::FileInput) }
|
|
16
20
|
attr_accessor :file
|
|
17
21
|
|
|
@@ -48,6 +52,10 @@ module OpenAI
|
|
|
48
52
|
end
|
|
49
53
|
def self.new(
|
|
50
54
|
# The File object (not file name) to be uploaded.
|
|
55
|
+
#
|
|
56
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
57
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
58
|
+
# content type.
|
|
51
59
|
file:,
|
|
52
60
|
# The intended purpose of the uploaded file. One of:
|
|
53
61
|
#
|
|
@@ -13,6 +13,10 @@ module OpenAI
|
|
|
13
13
|
|
|
14
14
|
# The image to use as the basis for the variation(s). Must be a valid PNG file,
|
|
15
15
|
# less than 4MB, and square.
|
|
16
|
+
#
|
|
17
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
18
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
19
|
+
# content type.
|
|
16
20
|
sig { returns(OpenAI::Internal::FileInput) }
|
|
17
21
|
attr_accessor :image
|
|
18
22
|
|
|
@@ -70,6 +74,10 @@ module OpenAI
|
|
|
70
74
|
def self.new(
|
|
71
75
|
# The image to use as the basis for the variation(s). Must be a valid PNG file,
|
|
72
76
|
# less than 4MB, and square.
|
|
77
|
+
#
|
|
78
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
79
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
80
|
+
# content type.
|
|
73
81
|
image:,
|
|
74
82
|
# The model to use for image generation. Only `dall-e-2` is supported at this
|
|
75
83
|
# time.
|
|
@@ -20,6 +20,10 @@ module OpenAI
|
|
|
20
20
|
#
|
|
21
21
|
# For `dall-e-2`, you can only provide one image, and it should be a square `png`
|
|
22
22
|
# file less than 4MB.
|
|
23
|
+
#
|
|
24
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
25
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
26
|
+
# content type.
|
|
23
27
|
sig { returns(OpenAI::ImageEditParams::Image::Variants) }
|
|
24
28
|
attr_accessor :image
|
|
25
29
|
|
|
@@ -56,6 +60,10 @@ module OpenAI
|
|
|
56
60
|
# indicate where `image` should be edited. If there are multiple images provided,
|
|
57
61
|
# the mask will be applied on the first image. Must be a valid PNG file, less than
|
|
58
62
|
# 4MB, and have the same dimensions as `image`.
|
|
63
|
+
#
|
|
64
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
65
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
66
|
+
# content type.
|
|
59
67
|
sig { returns(T.nilable(OpenAI::Internal::FileInput)) }
|
|
60
68
|
attr_reader :mask
|
|
61
69
|
|
|
@@ -170,6 +178,10 @@ module OpenAI
|
|
|
170
178
|
#
|
|
171
179
|
# For `dall-e-2`, you can only provide one image, and it should be a square `png`
|
|
172
180
|
# file less than 4MB.
|
|
181
|
+
#
|
|
182
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
183
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
184
|
+
# content type.
|
|
173
185
|
image:,
|
|
174
186
|
# A text description of the desired image(s). The maximum length is 1000
|
|
175
187
|
# characters for `dall-e-2`, and 32000 characters for the GPT image models.
|
|
@@ -196,6 +208,10 @@ module OpenAI
|
|
|
196
208
|
# indicate where `image` should be edited. If there are multiple images provided,
|
|
197
209
|
# the mask will be applied on the first image. Must be a valid PNG file, less than
|
|
198
210
|
# 4MB, and have the same dimensions as `image`.
|
|
211
|
+
#
|
|
212
|
+
# `String`, `StringIO`, and pathless `IO` inputs are sent with generic upload
|
|
213
|
+
# metadata. Use `OpenAI::FilePart` when you need to override the filename or
|
|
214
|
+
# content type.
|
|
199
215
|
mask: nil,
|
|
200
216
|
# The model to use for image generation. One of `dall-e-2` or a GPT image model
|
|
201
217
|
# (`gpt-image-1`, `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
|
|
@@ -752,6 +752,21 @@ module OpenAI
|
|
|
752
752
|
:"gpt-5.1-codex-max",
|
|
753
753
|
OpenAI::Responses::ResponseCompactParams::Model::TaggedSymbol
|
|
754
754
|
)
|
|
755
|
+
GPT_DAYBREAK_BLUE_LATEST =
|
|
756
|
+
T.let(
|
|
757
|
+
:"gpt-daybreak-blue-latest",
|
|
758
|
+
OpenAI::Responses::ResponseCompactParams::Model::TaggedSymbol
|
|
759
|
+
)
|
|
760
|
+
GPT_DAYBREAK_RED_LATEST =
|
|
761
|
+
T.let(
|
|
762
|
+
:"gpt-daybreak-red-latest",
|
|
763
|
+
OpenAI::Responses::ResponseCompactParams::Model::TaggedSymbol
|
|
764
|
+
)
|
|
765
|
+
GPT_5_6_CYBER =
|
|
766
|
+
T.let(
|
|
767
|
+
:"gpt-5.6-cyber",
|
|
768
|
+
OpenAI::Responses::ResponseCompactParams::Model::TaggedSymbol
|
|
769
|
+
)
|
|
755
770
|
end
|
|
756
771
|
|
|
757
772
|
# Text, image, or file inputs to the model, used to generate a response
|
|
@@ -314,6 +314,17 @@ module OpenAI
|
|
|
314
314
|
sig { returns(T.nilable(T::Boolean)) }
|
|
315
315
|
attr_accessor :stream
|
|
316
316
|
|
|
317
|
+
# The WebSocket lane for this response. Requests with the same `stream_id` are
|
|
318
|
+
# processed FIFO, and events for the response echo the same `stream_id`.
|
|
319
|
+
#
|
|
320
|
+
# `stream_id` controls routing; `previous_response_id` controls conversation
|
|
321
|
+
# lineage, so a new lane can fork from a response created on another lane.
|
|
322
|
+
sig { returns(T.nilable(String)) }
|
|
323
|
+
attr_reader :stream_id
|
|
324
|
+
|
|
325
|
+
sig { params(stream_id: String).void }
|
|
326
|
+
attr_writer :stream_id
|
|
327
|
+
|
|
317
328
|
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
318
329
|
sig do
|
|
319
330
|
returns(
|
|
@@ -558,6 +569,7 @@ module OpenAI
|
|
|
558
569
|
),
|
|
559
570
|
store: T.nilable(T::Boolean),
|
|
560
571
|
stream: T.nilable(T::Boolean),
|
|
572
|
+
stream_id: String,
|
|
561
573
|
stream_options:
|
|
562
574
|
T.nilable(
|
|
563
575
|
OpenAI::Responses::ResponsesClientEvent::StreamOptions::OrHash
|
|
@@ -761,6 +773,12 @@ module OpenAI
|
|
|
761
773
|
# [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
|
|
762
774
|
# for more information.
|
|
763
775
|
stream: nil,
|
|
776
|
+
# The WebSocket lane for this response. Requests with the same `stream_id` are
|
|
777
|
+
# processed FIFO, and events for the response echo the same `stream_id`.
|
|
778
|
+
#
|
|
779
|
+
# `stream_id` controls routing; `previous_response_id` controls conversation
|
|
780
|
+
# lineage, so a new lane can fork from a response created on another lane.
|
|
781
|
+
stream_id: nil,
|
|
764
782
|
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
765
783
|
stream_options: nil,
|
|
766
784
|
# What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
|
|
@@ -877,6 +895,7 @@ module OpenAI
|
|
|
877
895
|
),
|
|
878
896
|
store: T.nilable(T::Boolean),
|
|
879
897
|
stream: T.nilable(T::Boolean),
|
|
898
|
+
stream_id: String,
|
|
880
899
|
stream_options:
|
|
881
900
|
T.nilable(
|
|
882
901
|
OpenAI::Responses::ResponsesClientEvent::StreamOptions
|