openai 0.106.0 → 0.108.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 +74 -0
- data/README.md +49 -1
- data/examples/chat/tool_runner.rb +33 -0
- data/lib/openai/client.rb +2 -2
- data/lib/openai/helpers/chat/tool_runner.rb +259 -0
- data/lib/openai/helpers/live/websocket.rb +12 -141
- data/lib/openai/helpers/local_audio/process.rb +13 -3
- data/lib/openai/helpers/models/embedding.rb +42 -0
- data/lib/openai/helpers/realtime/connection.rb +22 -5
- data/lib/openai/helpers/realtime/recovery.rb +19 -7
- data/lib/openai/helpers/realtime/translation.rb +37 -169
- data/lib/openai/helpers/realtime/unknown_server_event.rb +5 -12
- data/lib/openai/helpers/responses_websocket/connection.rb +56 -35
- data/lib/openai/helpers/responses_websocket/incremental.rb +5 -1
- data/lib/openai/helpers/responses_websocket/session.rb +11 -4
- data/lib/openai/helpers/responses_websocket/unknown_server_event.rb +2 -14
- data/lib/openai/helpers/streaming/chat_completion_resource.rb +52 -0
- data/lib/openai/helpers/websocket/async_websocket_transport.rb +8 -6
- data/lib/openai/helpers/websocket/client_request.rb +1 -1
- data/lib/openai/helpers/websocket/connection.rb +21 -10
- data/lib/openai/helpers/websocket/connection_manager.rb +2 -1
- data/lib/openai/helpers/websocket/protocol.rb +160 -0
- data/lib/openai/helpers/websocket/typed_connection.rb +22 -16
- data/lib/openai/helpers/websocket/typed_resource.rb +15 -0
- data/lib/openai/internal/transport/base_client.rb +1 -1
- data/lib/openai/models/admin/organization/usage_audio_speeches_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_audio_transcriptions_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_code_interpreter_sessions_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_completions_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_costs_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_decisions_response.rb +14 -3
- data/lib/openai/models/admin/organization/usage_embeddings_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_file_search_calls_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_images_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_moderations_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_vector_stores_response.rb +16 -5
- data/lib/openai/models/admin/organization/usage_web_search_calls_response.rb +16 -5
- data/lib/openai/models/audio/voice_consent.rb +58 -0
- data/lib/openai/models/audio/voice_consent_create_params.rb +57 -0
- data/lib/openai/models/audio/voice_consent_delete_params.rb +22 -0
- data/lib/openai/models/audio/voice_consent_deleted.rb +34 -0
- data/lib/openai/models/audio/voice_consent_list_params.rb +42 -0
- data/lib/openai/models/audio/voice_consent_retrieve_params.rb +22 -0
- data/lib/openai/models/audio/voice_consent_update_params.rb +32 -0
- data/lib/openai/models/beta/beta_response_input_item.rb +10 -1
- data/lib/openai/models/responses/response_input_item.rb +10 -1
- data/lib/openai/resources/audio/voice_consents.rb +163 -0
- data/lib/openai/resources/audio.rb +5 -0
- data/lib/openai/version.rb +1 -1
- data/lib/openai.rb +9 -0
- data/rbi/openai/client.rbi +1 -8
- data/rbi/openai/helpers/chat/tool_runner.rbi +74 -0
- data/rbi/openai/helpers/realtime/translation.rbi +0 -5
- data/rbi/openai/helpers/realtime/unknown_server_event.rbi +6 -0
- data/rbi/openai/helpers/websocket.rbi +44 -6
- data/rbi/openai/internal/transport/base_client.rbi +2 -6
- data/rbi/openai/models/admin/organization/usage_audio_speeches_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_audio_transcriptions_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_code_interpreter_sessions_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_completions_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_costs_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_decisions_response.rbi +12 -0
- data/rbi/openai/models/admin/organization/usage_embeddings_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_file_search_calls_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_images_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_moderations_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_vector_stores_response.rbi +14 -2
- data/rbi/openai/models/admin/organization/usage_web_search_calls_response.rbi +14 -2
- data/rbi/openai/models/audio/voice_consent.rbi +86 -0
- data/rbi/openai/models/audio/voice_consent_create_params.rbi +92 -0
- data/rbi/openai/models/audio/voice_consent_delete_params.rbi +53 -0
- data/rbi/openai/models/audio/voice_consent_deleted.rbi +62 -0
- data/rbi/openai/models/audio/voice_consent_list_params.rbi +78 -0
- data/rbi/openai/models/audio/voice_consent_retrieve_params.rbi +53 -0
- data/rbi/openai/models/audio/voice_consent_update_params.rbi +62 -0
- data/rbi/openai/models/beta/beta_response_input_item.rbi +14 -1
- data/rbi/openai/models/response_format_json_schema.rbi +13 -11
- data/rbi/openai/models/responses/response_input_item.rbi +10 -1
- data/rbi/openai/resources/audio/voice_consents.rbi +108 -0
- data/rbi/openai/resources/audio.rbi +4 -0
- data/realtime.md +22 -3
- data/sig/openai/client.rbs +1 -1
- data/sig/openai/helpers/chat/tool_runner.rbs +48 -0
- data/sig/openai/helpers/realtime/translation.rbs +0 -2
- data/sig/openai/helpers/realtime/unknown_server_event.rbs +2 -0
- data/sig/openai/helpers/websocket.rbs +23 -6
- data/sig/openai/models/admin/organization/usage_audio_speeches_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_audio_transcriptions_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_code_interpreter_sessions_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_completions_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_costs_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_decisions_response.rbs +11 -1
- data/sig/openai/models/admin/organization/usage_embeddings_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_file_search_calls_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_images_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_moderations_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_vector_stores_response.rbs +15 -5
- data/sig/openai/models/admin/organization/usage_web_search_calls_response.rbs +15 -5
- data/sig/openai/models/audio/voice_consent.rbs +57 -0
- data/sig/openai/models/audio/voice_consent_create_params.rbs +61 -0
- data/sig/openai/models/audio/voice_consent_delete_params.rbs +25 -0
- data/sig/openai/models/audio/voice_consent_deleted.rbs +31 -0
- data/sig/openai/models/audio/voice_consent_list_params.rbs +57 -0
- data/sig/openai/models/audio/voice_consent_retrieve_params.rbs +25 -0
- data/sig/openai/models/audio/voice_consent_update_params.rbs +36 -0
- data/sig/openai/models/beta/beta_response_input_item.rbs +8 -0
- data/sig/openai/models/responses/response_input_item.rbs +8 -3
- data/sig/openai/resources/audio/voice_consents.rbs +38 -0
- data/sig/openai/resources/audio.rbs +2 -0
- metadata +31 -1
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -75,6 +75,7 @@ module OpenAI
|
|
|
75
75
|
?batch: bool?,
|
|
76
76
|
?input_audio_tokens: Integer?,
|
|
77
77
|
?:input_cache_write_12h_tokens => Integer?,
|
|
78
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
78
79
|
?input_cache_write_tokens: Integer?,
|
|
79
80
|
?input_cached_audio_tokens: Integer?,
|
|
80
81
|
?input_cached_image_tokens: Integer?,
|
|
@@ -131,6 +132,10 @@ module OpenAI
|
|
|
131
132
|
|
|
132
133
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
133
134
|
# retention period.
|
|
135
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
136
|
+
|
|
137
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
138
|
+
# 12-hour retention periods.
|
|
134
139
|
attr_accessor input_cache_write_tokens: Integer?
|
|
135
140
|
|
|
136
141
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -208,9 +213,12 @@ module OpenAI
|
|
|
208
213
|
# @param input_cache_write_12h_tokens
|
|
209
214
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
210
215
|
# retention period.
|
|
211
|
-
# @param
|
|
216
|
+
# @param input_cache_write_30m_tokens
|
|
212
217
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
213
218
|
# retention period.
|
|
219
|
+
# @param input_cache_write_tokens
|
|
220
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
221
|
+
# 12-hour retention periods.
|
|
214
222
|
# @param input_cached_audio_tokens
|
|
215
223
|
# The aggregated number of cached audio input tokens used.
|
|
216
224
|
# @param input_cached_image_tokens
|
|
@@ -255,6 +263,7 @@ module OpenAI
|
|
|
255
263
|
?batch: bool?,
|
|
256
264
|
?input_audio_tokens: Integer?,
|
|
257
265
|
?input_cache_write_12h_tokens: Integer?,
|
|
266
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
258
267
|
?input_cache_write_tokens: Integer?,
|
|
259
268
|
?input_cached_audio_tokens: Integer?,
|
|
260
269
|
?input_cached_image_tokens: Integer?,
|
|
@@ -283,6 +292,7 @@ module OpenAI
|
|
|
283
292
|
?batch: bool?,
|
|
284
293
|
?input_audio_tokens: Integer?,
|
|
285
294
|
?:input_cache_write_12h_tokens => Integer?,
|
|
295
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
286
296
|
?input_cache_write_tokens: Integer?,
|
|
287
297
|
?input_cached_audio_tokens: Integer?,
|
|
288
298
|
?input_cached_image_tokens: Integer?,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|
|
@@ -91,6 +91,7 @@ module OpenAI
|
|
|
91
91
|
?batch: bool?,
|
|
92
92
|
?input_audio_tokens: Integer,
|
|
93
93
|
?:input_cache_write_12h_tokens => Integer,
|
|
94
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
94
95
|
?input_cache_write_tokens: Integer,
|
|
95
96
|
?input_cached_audio_tokens: Integer,
|
|
96
97
|
?input_cached_image_tokens: Integer,
|
|
@@ -153,11 +154,15 @@ module OpenAI
|
|
|
153
154
|
def input_cache_write_12h_tokens=: (Integer) -> Integer
|
|
154
155
|
|
|
155
156
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
156
|
-
# retention period.
|
|
157
|
+
# retention period. May be absent or null for older responses.
|
|
158
|
+
attr_accessor input_cache_write_30m_tokens: Integer?
|
|
159
|
+
|
|
160
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
161
|
+
# 12-hour retention periods.
|
|
157
162
|
attr_reader input_cache_write_tokens: Integer?
|
|
158
163
|
|
|
159
|
-
# The aggregated number of input tokens written to the cache
|
|
160
|
-
# retention
|
|
164
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
165
|
+
# 12-hour retention periods.
|
|
161
166
|
def input_cache_write_tokens=: (Integer) -> Integer
|
|
162
167
|
|
|
163
168
|
# The aggregated number of cached audio input tokens used.
|
|
@@ -268,9 +273,12 @@ module OpenAI
|
|
|
268
273
|
# @param input_cache_write_12h_tokens
|
|
269
274
|
# The aggregated number of input tokens written to the cache with a 12-hour
|
|
270
275
|
# retention period.
|
|
271
|
-
# @param
|
|
276
|
+
# @param input_cache_write_30m_tokens
|
|
272
277
|
# The aggregated number of input tokens written to the cache with a 30-minute
|
|
273
|
-
# retention period.
|
|
278
|
+
# retention period. May be absent or null for older responses.
|
|
279
|
+
# @param input_cache_write_tokens
|
|
280
|
+
# The aggregated number of input tokens written to the cache across 30-minute and
|
|
281
|
+
# 12-hour retention periods.
|
|
274
282
|
# @param input_cached_audio_tokens
|
|
275
283
|
# The aggregated number of cached audio input tokens used.
|
|
276
284
|
# @param input_cached_image_tokens
|
|
@@ -315,6 +323,7 @@ module OpenAI
|
|
|
315
323
|
?batch: bool?,
|
|
316
324
|
?input_audio_tokens: Integer,
|
|
317
325
|
?input_cache_write_12h_tokens: Integer,
|
|
326
|
+
?input_cache_write_30m_tokens: Integer?,
|
|
318
327
|
?input_cache_write_tokens: Integer,
|
|
319
328
|
?input_cached_audio_tokens: Integer,
|
|
320
329
|
?input_cached_image_tokens: Integer,
|
|
@@ -343,6 +352,7 @@ module OpenAI
|
|
|
343
352
|
?batch: bool?,
|
|
344
353
|
?input_audio_tokens: Integer,
|
|
345
354
|
?:input_cache_write_12h_tokens => Integer,
|
|
355
|
+
?:input_cache_write_30m_tokens => Integer?,
|
|
346
356
|
?input_cache_write_tokens: Integer,
|
|
347
357
|
?input_cached_audio_tokens: Integer,
|
|
348
358
|
?input_cached_image_tokens: Integer,
|