openai 0.104.0 → 0.106.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 +33 -0
- data/README.md +1 -1
- data/lib/openai/models/admin/organization/external_storage_configuration.rb +1 -0
- data/lib/openai/models/beta/agent_create_params.rb +3 -0
- data/lib/openai/models/beta/agent_update_params.rb +3 -0
- data/lib/openai/models/beta/agents/session_create_params.rb +3 -0
- data/lib/openai/models/beta/agents/session_update_params.rb +3 -0
- data/lib/openai/models/beta/assistant_update_params.rb +12 -0
- data/lib/openai/models/beta/beta_response.rb +12 -0
- data/lib/openai/models/beta/beta_responses_client_event.rb +12 -0
- data/lib/openai/models/beta/response_compact_params.rb +12 -0
- data/lib/openai/models/beta/response_create_params.rb +12 -0
- data/lib/openai/models/chat_model.rb +12 -0
- data/lib/openai/models/decision_create_params.rb +112 -1
- data/lib/openai/models/decision_input_image.rb +14 -1
- data/lib/openai/models/decision_input_text.rb +15 -1
- data/lib/openai/models/decision_prompt_cache_breakpoint.rb +21 -0
- data/lib/openai/models/image_edit_completed_event.rb +14 -1
- data/lib/openai/models/image_edit_params.rb +28 -5
- data/lib/openai/models/image_gen_completed_event.rb +14 -1
- data/lib/openai/models/image_generate_params.rb +28 -5
- data/lib/openai/models/images_response.rb +14 -1
- data/lib/openai/models/live/sideband_server_event.rb +243 -3
- data/lib/openai/models/responses/response_compact_params.rb +12 -0
- data/lib/openai/models.rb +2 -0
- data/lib/openai/resources/beta/responses.rb +19 -0
- data/lib/openai/resources/decisions.rb +15 -1
- data/lib/openai/resources/images.rb +50 -12
- data/lib/openai/version.rb +1 -1
- data/lib/openai.rb +1 -0
- data/rbi/openai/models/admin/organization/external_storage_configuration.rbi +1 -0
- data/rbi/openai/models/beta/agent_create_params.rbi +3 -0
- data/rbi/openai/models/beta/agent_update_params.rbi +3 -0
- data/rbi/openai/models/beta/agents/session_create_params.rbi +3 -0
- data/rbi/openai/models/beta/agents/session_update_params.rbi +3 -0
- data/rbi/openai/models/decision_create_params.rbi +146 -0
- data/rbi/openai/models/decision_input_image.rbi +22 -1
- data/rbi/openai/models/decision_input_text.rbi +21 -1
- data/rbi/openai/models/decision_prompt_cache_breakpoint.rbi +48 -0
- data/rbi/openai/models/image_edit_completed_event.rbi +15 -1
- data/rbi/openai/models/image_edit_params.rbi +26 -4
- data/rbi/openai/models/image_gen_completed_event.rbi +15 -1
- data/rbi/openai/models/image_generate_params.rbi +26 -4
- data/rbi/openai/models/images_response.rbi +14 -0
- data/rbi/openai/models/live/output_audio_delta_event.rbi +1 -1
- data/rbi/openai/models/live/sideband_server_event.rbi +406 -3
- data/rbi/openai/models.rbi +2 -0
- data/rbi/openai/resources/beta/responses.rbi +17 -0
- data/rbi/openai/resources/decisions.rbi +14 -0
- data/rbi/openai/resources/images.rbi +44 -8
- data/sig/openai/models/admin/organization/external_storage_configuration.rbs +2 -1
- data/sig/openai/models/beta/agent_create_params.rbs +5 -1
- data/sig/openai/models/beta/agent_update_params.rbs +5 -1
- data/sig/openai/models/beta/agents/session_create_params.rbs +5 -1
- data/sig/openai/models/beta/agents/session_update_params.rbs +5 -1
- data/sig/openai/models/decision_create_params.rbs +106 -0
- data/sig/openai/models/decision_input_image.rbs +18 -2
- data/sig/openai/models/decision_input_text.rbs +29 -3
- data/sig/openai/models/decision_prompt_cache_breakpoint.rbs +16 -0
- data/sig/openai/models/image_edit_completed_event.rbs +14 -2
- data/sig/openai/models/image_edit_params.rbs +27 -6
- data/sig/openai/models/image_gen_completed_event.rbs +14 -2
- data/sig/openai/models/image_generate_params.rbs +27 -6
- data/sig/openai/models/images_response.rbs +12 -0
- data/sig/openai/models/live/sideband_server_event.rbs +225 -0
- data/sig/openai/models.rbs +2 -0
- data/sig/openai/resources/beta/responses.rbs +7 -0
- data/sig/openai/resources/decisions.rbs +3 -0
- data/sig/openai/resources/images.rbs +4 -0
- metadata +4 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c24e00e4168b6f3661b2eb29d8de97727d4bcd6a80e40f68512ab21c3c025b46
|
|
4
|
+
data.tar.gz: 16f33bff54375b5f3fb5174af63026f95e79ab2ca1cdfe6dd07cedfacac31568
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 0fe9484b436e02d3b50981251596b57195cef1a604207b7b496049a2214b44eb3953447568b3dcfb3e1e0827279785587e66dfc1d2427c1fa858b7bcb87c54c1
|
|
7
|
+
data.tar.gz: 2cabbb26e7382803fbc4aa5ddcc47e3be1bad88c2d05510fb0a44f537653761a0c888157d407764ebeaab8de174cf5f8a44338ae868b16c016914b31cdd1978c
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,38 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.106.0](https://github.com/openai/openai-ruby/compare/v0.105.0...v0.106.0) (2026-10-17)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **api:** add Decisions prompt caching options ([#892](https://github.com/openai/openai-ruby/issues/892)) ([7b4dc7a](https://github.com/openai/openai-ruby/commit/7b4dc7adda7e1f7613aedd3efc29dba880e89dd2))
|
|
9
|
+
* **api:** add degraded external storage status ([#901](https://github.com/openai/openai-ruby/issues/901)) ([e7207d2](https://github.com/openai/openai-ruby/commit/e7207d2b7b9de32649d98d6b6d2a24cdc1bd680b))
|
|
10
|
+
* **api:** add typed Live sideband events and beta connections ([#903](https://github.com/openai/openai-ruby/issues/903)) ([90e6540](https://github.com/openai/openai-ruby/commit/90e654028d3c63146b7090040ed5c49961606c59))
|
|
11
|
+
* **api:** add ultrafast service tier for Agents ([#904](https://github.com/openai/openai-ruby/issues/904)) ([65d8015](https://github.com/openai/openai-ruby/commit/65d80153f634243f62579bd21ca89d777b56b889))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Chores
|
|
15
|
+
|
|
16
|
+
* **api:** add Assistants model shutdown notices ([#900](https://github.com/openai/openai-ruby/issues/900)) ([41a6400](https://github.com/openai/openai-ruby/commit/41a6400762bea831604d19200724a481c0f5ac94))
|
|
17
|
+
* **api:** add shutdown notices for GPT-4 model aliases ([#898](https://github.com/openai/openai-ruby/issues/898)) ([2162219](https://github.com/openai/openai-ruby/commit/216221935f3d4a4d7e6649582556049a401dcc08))
|
|
18
|
+
|
|
19
|
+
## [0.105.0](https://github.com/openai/openai-ruby/compare/v0.104.0...v0.105.0) (2026-10-16)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
### Features
|
|
23
|
+
|
|
24
|
+
* **api:** add safety identifiers to image requests and responses ([#894](https://github.com/openai/openai-ruby/issues/894)) ([d74e0d5](https://github.com/openai/openai-ruby/commit/d74e0d5737c34a2201780ceb961ac0f7302621cc))
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
### Bug Fixes
|
|
28
|
+
|
|
29
|
+
* **api:** omit nil safety identifiers from image edits ([#896](https://github.com/openai/openai-ruby/issues/896)) ([a4dbd91](https://github.com/openai/openai-ruby/commit/a4dbd91cbc38ae66a641353c9cc042956cd46bdf))
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
### Chores
|
|
33
|
+
|
|
34
|
+
* **api:** maintain webhook verification compatibility ([#893](https://github.com/openai/openai-ruby/issues/893)) ([adbde58](https://github.com/openai/openai-ruby/commit/adbde58c45c1241a49a89c03bdb1e350c0ea0ddb))
|
|
35
|
+
|
|
3
36
|
## [0.104.0](https://github.com/openai/openai-ruby/compare/v0.103.0...v0.104.0) (2026-10-16)
|
|
4
37
|
|
|
5
38
|
|
data/README.md
CHANGED
|
@@ -316,7 +316,13 @@ module OpenAI
|
|
|
316
316
|
GPT_5_2025_08_07 = :"gpt-5-2025-08-07"
|
|
317
317
|
GPT_5_MINI_2025_08_07 = :"gpt-5-mini-2025-08-07"
|
|
318
318
|
GPT_5_NANO_2025_08_07 = :"gpt-5-nano-2025-08-07"
|
|
319
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
320
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
321
|
+
# replacements.
|
|
319
322
|
GPT_4_1 = :"gpt-4.1"
|
|
323
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
324
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
325
|
+
# replacements.
|
|
320
326
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
321
327
|
GPT_4_1_NANO = :"gpt-4.1-nano"
|
|
322
328
|
GPT_4_1_2025_04_14 = :"gpt-4.1-2025-04-14"
|
|
@@ -326,10 +332,16 @@ module OpenAI
|
|
|
326
332
|
O3_MINI_2025_01_31 = :"o3-mini-2025-01-31"
|
|
327
333
|
O1 = :o1
|
|
328
334
|
O1_2024_12_17 = :"o1-2024-12-17"
|
|
335
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
336
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
337
|
+
# replacements.
|
|
329
338
|
GPT_4O = :"gpt-4o"
|
|
330
339
|
GPT_4O_2024_11_20 = :"gpt-4o-2024-11-20"
|
|
331
340
|
GPT_4O_2024_08_06 = :"gpt-4o-2024-08-06"
|
|
332
341
|
GPT_4O_2024_05_13 = :"gpt-4o-2024-05-13"
|
|
342
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
343
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
344
|
+
# replacements.
|
|
333
345
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
334
346
|
GPT_4O_MINI_2024_07_18 = :"gpt-4o-mini-2024-07-18"
|
|
335
347
|
GPT_4_5_PREVIEW = :"gpt-4.5-preview"
|
|
@@ -995,7 +995,13 @@ module OpenAI
|
|
|
995
995
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
996
996
|
# replacements.
|
|
997
997
|
GPT_5_CHAT_LATEST = :"gpt-5-chat-latest"
|
|
998
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
999
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1000
|
+
# replacements.
|
|
998
1001
|
GPT_4_1 = :"gpt-4.1"
|
|
1002
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1003
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1004
|
+
# replacements.
|
|
999
1005
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
1000
1006
|
# @deprecated Announced shutdown date: 2026-10-23. See
|
|
1001
1007
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1061,6 +1067,9 @@ module OpenAI
|
|
|
1061
1067
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1062
1068
|
# replacements.
|
|
1063
1069
|
O1_MINI_2024_09_12 = :"o1-mini-2024-09-12"
|
|
1070
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1071
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1072
|
+
# replacements.
|
|
1064
1073
|
GPT_4O = :"gpt-4o"
|
|
1065
1074
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1066
1075
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1130,6 +1139,9 @@ module OpenAI
|
|
|
1130
1139
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1131
1140
|
# replacements.
|
|
1132
1141
|
CODEX_MINI_LATEST = :"codex-mini-latest"
|
|
1142
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1143
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1144
|
+
# replacements.
|
|
1133
1145
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
1134
1146
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1135
1147
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1382,7 +1382,13 @@ module OpenAI
|
|
|
1382
1382
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1383
1383
|
# replacements.
|
|
1384
1384
|
GPT_5_CHAT_LATEST = :"gpt-5-chat-latest"
|
|
1385
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1386
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1387
|
+
# replacements.
|
|
1385
1388
|
GPT_4_1 = :"gpt-4.1"
|
|
1389
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1390
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1391
|
+
# replacements.
|
|
1386
1392
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
1387
1393
|
# @deprecated Announced shutdown date: 2026-10-23. See
|
|
1388
1394
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1448,6 +1454,9 @@ module OpenAI
|
|
|
1448
1454
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1449
1455
|
# replacements.
|
|
1450
1456
|
O1_MINI_2024_09_12 = :"o1-mini-2024-09-12"
|
|
1457
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1458
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1459
|
+
# replacements.
|
|
1451
1460
|
GPT_4O = :"gpt-4o"
|
|
1452
1461
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1453
1462
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1517,6 +1526,9 @@ module OpenAI
|
|
|
1517
1526
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1518
1527
|
# replacements.
|
|
1519
1528
|
CODEX_MINI_LATEST = :"codex-mini-latest"
|
|
1529
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1530
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1531
|
+
# replacements.
|
|
1520
1532
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
1521
1533
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1522
1534
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -481,7 +481,13 @@ module OpenAI
|
|
|
481
481
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
482
482
|
# replacements.
|
|
483
483
|
GPT_5_CHAT_LATEST = :"gpt-5-chat-latest"
|
|
484
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
485
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
486
|
+
# replacements.
|
|
484
487
|
GPT_4_1 = :"gpt-4.1"
|
|
488
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
489
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
490
|
+
# replacements.
|
|
485
491
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
486
492
|
# @deprecated Announced shutdown date: 2026-10-23. See
|
|
487
493
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -547,6 +553,9 @@ module OpenAI
|
|
|
547
553
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
548
554
|
# replacements.
|
|
549
555
|
O1_MINI_2024_09_12 = :"o1-mini-2024-09-12"
|
|
556
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
557
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
558
|
+
# replacements.
|
|
550
559
|
GPT_4O = :"gpt-4o"
|
|
551
560
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
552
561
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -616,6 +625,9 @@ module OpenAI
|
|
|
616
625
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
617
626
|
# replacements.
|
|
618
627
|
CODEX_MINI_LATEST = :"codex-mini-latest"
|
|
628
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
629
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
630
|
+
# replacements.
|
|
619
631
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
620
632
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
621
633
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1066,7 +1066,13 @@ module OpenAI
|
|
|
1066
1066
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1067
1067
|
# replacements.
|
|
1068
1068
|
GPT_5_CHAT_LATEST = :"gpt-5-chat-latest"
|
|
1069
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1070
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1071
|
+
# replacements.
|
|
1069
1072
|
GPT_4_1 = :"gpt-4.1"
|
|
1073
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1074
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1075
|
+
# replacements.
|
|
1070
1076
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
1071
1077
|
# @deprecated Announced shutdown date: 2026-10-23. See
|
|
1072
1078
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1132,6 +1138,9 @@ module OpenAI
|
|
|
1132
1138
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1133
1139
|
# replacements.
|
|
1134
1140
|
O1_MINI_2024_09_12 = :"o1-mini-2024-09-12"
|
|
1141
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1142
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1143
|
+
# replacements.
|
|
1135
1144
|
GPT_4O = :"gpt-4o"
|
|
1136
1145
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1137
1146
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -1201,6 +1210,9 @@ module OpenAI
|
|
|
1201
1210
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1202
1211
|
# replacements.
|
|
1203
1212
|
CODEX_MINI_LATEST = :"codex-mini-latest"
|
|
1213
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1214
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
1215
|
+
# replacements.
|
|
1204
1216
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
1205
1217
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
1206
1218
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -77,7 +77,13 @@ module OpenAI
|
|
|
77
77
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
78
78
|
# replacements.
|
|
79
79
|
GPT_5_CHAT_LATEST = :"gpt-5-chat-latest"
|
|
80
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
81
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
82
|
+
# replacements.
|
|
80
83
|
GPT_4_1 = :"gpt-4.1"
|
|
84
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
85
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
86
|
+
# replacements.
|
|
81
87
|
GPT_4_1_MINI = :"gpt-4.1-mini"
|
|
82
88
|
# @deprecated Announced shutdown date: 2026-10-23. See
|
|
83
89
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -143,6 +149,9 @@ module OpenAI
|
|
|
143
149
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
144
150
|
# replacements.
|
|
145
151
|
O1_MINI_2024_09_12 = :"o1-mini-2024-09-12"
|
|
152
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
153
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
154
|
+
# replacements.
|
|
146
155
|
GPT_4O = :"gpt-4o"
|
|
147
156
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
148
157
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -212,6 +221,9 @@ module OpenAI
|
|
|
212
221
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
213
222
|
# replacements.
|
|
214
223
|
CODEX_MINI_LATEST = :"codex-mini-latest"
|
|
224
|
+
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
225
|
+
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
226
|
+
# replacements.
|
|
215
227
|
GPT_4O_MINI = :"gpt-4o-mini"
|
|
216
228
|
# @deprecated Announced shutdown date: 2027-01-14. See
|
|
217
229
|
# https://developers.openai.com/api/docs/deprecations for details and recommended
|
|
@@ -29,6 +29,26 @@ module OpenAI
|
|
|
29
29
|
# @return [Array<OpenAI::Models::DecisionCreateParams::Question::Predicate, OpenAI::Models::DecisionCreateParams::Question::Choice, OpenAI::Models::DecisionCreateParams::Question::Score>]
|
|
30
30
|
required :questions, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::DecisionCreateParams::Question] }
|
|
31
31
|
|
|
32
|
+
# @!attribute prompt_cache_key
|
|
33
|
+
# Partition prompt cache reuse by caller-provided key.
|
|
34
|
+
#
|
|
35
|
+
# @return [String, nil]
|
|
36
|
+
optional :prompt_cache_key, String, nil?: true
|
|
37
|
+
|
|
38
|
+
# @!attribute prompt_cache_options
|
|
39
|
+
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
40
|
+
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
41
|
+
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
42
|
+
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
43
|
+
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
44
|
+
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
45
|
+
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
46
|
+
# [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
|
|
47
|
+
# for current details.
|
|
48
|
+
#
|
|
49
|
+
# @return [OpenAI::Models::DecisionCreateParams::PromptCacheOptions, nil]
|
|
50
|
+
optional :prompt_cache_options, -> { OpenAI::DecisionCreateParams::PromptCacheOptions }, nil?: true
|
|
51
|
+
|
|
32
52
|
# @!attribute safety_identifier
|
|
33
53
|
# Opaque caller-provided end-user identifier, scoped by the verified org. Match
|
|
34
54
|
# Responses' limit; this is never the authenticated user identity.
|
|
@@ -36,7 +56,7 @@ module OpenAI
|
|
|
36
56
|
# @return [String, nil]
|
|
37
57
|
optional :safety_identifier, String, nil?: true
|
|
38
58
|
|
|
39
|
-
# @!method initialize(input:, model:, questions:, safety_identifier: nil, request_options: {})
|
|
59
|
+
# @!method initialize(input:, model:, questions:, prompt_cache_key: nil, prompt_cache_options: nil, safety_identifier: nil, request_options: {})
|
|
40
60
|
# @param input [String, Array<OpenAI::Models::DecisionInputMessage>]
|
|
41
61
|
# The text or images to evaluate for every question. Provide a text string or user
|
|
42
62
|
# messages containing text and images. Images can be base64 data URLs or publicly
|
|
@@ -50,6 +70,20 @@ module OpenAI
|
|
|
50
70
|
# Ask 1–200 questions about the input. Each question can be a predicate, choice,
|
|
51
71
|
# or score. Answers come back in the same order.
|
|
52
72
|
#
|
|
73
|
+
# @param prompt_cache_key [String, nil]
|
|
74
|
+
# Partition prompt cache reuse by caller-provided key.
|
|
75
|
+
#
|
|
76
|
+
# @param prompt_cache_options [OpenAI::Models::DecisionCreateParams::PromptCacheOptions, nil]
|
|
77
|
+
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
78
|
+
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
79
|
+
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
80
|
+
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
81
|
+
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
82
|
+
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
83
|
+
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
84
|
+
# [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
|
|
85
|
+
# for current details.
|
|
86
|
+
#
|
|
53
87
|
# @param safety_identifier [String, nil]
|
|
54
88
|
# Opaque caller-provided end-user identifier, scoped by the verified org. Match
|
|
55
89
|
# Responses' limit; this is never the authenticated user identity.
|
|
@@ -245,6 +279,83 @@ module OpenAI
|
|
|
245
279
|
# @!method self.variants
|
|
246
280
|
# @return [Array(OpenAI::Models::DecisionCreateParams::Question::Predicate, OpenAI::Models::DecisionCreateParams::Question::Choice, OpenAI::Models::DecisionCreateParams::Question::Score)]
|
|
247
281
|
end
|
|
282
|
+
|
|
283
|
+
class PromptCacheOptions < OpenAI::Internal::Type::BaseModel
|
|
284
|
+
# @!attribute mode
|
|
285
|
+
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
286
|
+
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
287
|
+
# and writes up to the latest three explicit breakpoints in the request. With
|
|
288
|
+
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
289
|
+
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
290
|
+
# request does not use prompt caching.
|
|
291
|
+
#
|
|
292
|
+
# @return [Symbol, OpenAI::Models::DecisionCreateParams::PromptCacheOptions::Mode, nil]
|
|
293
|
+
optional :mode, enum: -> { OpenAI::DecisionCreateParams::PromptCacheOptions::Mode }, nil?: true
|
|
294
|
+
|
|
295
|
+
# @!attribute ttl
|
|
296
|
+
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
297
|
+
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
298
|
+
# value. The backend may retain cache entries for longer.
|
|
299
|
+
#
|
|
300
|
+
# @return [Symbol, OpenAI::Models::DecisionCreateParams::PromptCacheOptions::Ttl, nil]
|
|
301
|
+
optional :ttl, enum: -> { OpenAI::DecisionCreateParams::PromptCacheOptions::Ttl }
|
|
302
|
+
|
|
303
|
+
# @!method initialize(mode: nil, ttl: nil)
|
|
304
|
+
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
305
|
+
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
306
|
+
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
307
|
+
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
308
|
+
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
309
|
+
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
310
|
+
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
311
|
+
# [prompt caching guide](https://developers.openai.com/api/docs/guides/prompt-caching)
|
|
312
|
+
# for current details.
|
|
313
|
+
#
|
|
314
|
+
# @param mode [Symbol, OpenAI::Models::DecisionCreateParams::PromptCacheOptions::Mode, nil]
|
|
315
|
+
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
316
|
+
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
317
|
+
# and writes up to the latest three explicit breakpoints in the request. With
|
|
318
|
+
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
319
|
+
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
320
|
+
# request does not use prompt caching.
|
|
321
|
+
#
|
|
322
|
+
# @param ttl [Symbol, OpenAI::Models::DecisionCreateParams::PromptCacheOptions::Ttl]
|
|
323
|
+
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
324
|
+
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
325
|
+
# value. The backend may retain cache entries for longer.
|
|
326
|
+
|
|
327
|
+
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
328
|
+
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
329
|
+
# and writes up to the latest three explicit breakpoints in the request. With
|
|
330
|
+
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
331
|
+
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
332
|
+
# request does not use prompt caching.
|
|
333
|
+
#
|
|
334
|
+
# @see OpenAI::Models::DecisionCreateParams::PromptCacheOptions#mode
|
|
335
|
+
module Mode
|
|
336
|
+
extend OpenAI::Internal::Type::Enum
|
|
337
|
+
|
|
338
|
+
IMPLICIT = :implicit
|
|
339
|
+
EXPLICIT = :explicit
|
|
340
|
+
|
|
341
|
+
# @!method self.values
|
|
342
|
+
# @return [Array<Symbol>]
|
|
343
|
+
end
|
|
344
|
+
|
|
345
|
+
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
346
|
+
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
347
|
+
# value. The backend may retain cache entries for longer.
|
|
348
|
+
#
|
|
349
|
+
# @see OpenAI::Models::DecisionCreateParams::PromptCacheOptions#ttl
|
|
350
|
+
module Ttl
|
|
351
|
+
extend OpenAI::Internal::Type::Enum
|
|
352
|
+
|
|
353
|
+
TTL_30M = :"30m"
|
|
354
|
+
|
|
355
|
+
# @!method self.values
|
|
356
|
+
# @return [Array<Symbol>]
|
|
357
|
+
end
|
|
358
|
+
end
|
|
248
359
|
end
|
|
249
360
|
end
|
|
250
361
|
end
|
|
@@ -21,7 +21,15 @@ module OpenAI
|
|
|
21
21
|
# @return [Symbol, OpenAI::Models::DecisionInputImage::Detail, nil]
|
|
22
22
|
optional :detail, enum: -> { OpenAI::DecisionInputImage::Detail }, nil?: true
|
|
23
23
|
|
|
24
|
-
# @!
|
|
24
|
+
# @!attribute prompt_cache_breakpoint
|
|
25
|
+
# Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
26
|
+
# from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
27
|
+
# token block.
|
|
28
|
+
#
|
|
29
|
+
# @return [OpenAI::Models::DecisionPromptCacheBreakpoint, nil]
|
|
30
|
+
optional :prompt_cache_breakpoint, -> { OpenAI::DecisionPromptCacheBreakpoint }, nil?: true
|
|
31
|
+
|
|
32
|
+
# @!method initialize(image_url:, detail: nil, prompt_cache_breakpoint: nil, type: :input_image)
|
|
25
33
|
# An image provided as a base64 data URL or a publicly accessible HTTP(S) URL.
|
|
26
34
|
# File IDs are not supported.
|
|
27
35
|
#
|
|
@@ -32,6 +40,11 @@ module OpenAI
|
|
|
32
40
|
# The image detail level, using the selected model's image profile. Defaults to
|
|
33
41
|
# auto.
|
|
34
42
|
#
|
|
43
|
+
# @param prompt_cache_breakpoint [OpenAI::Models::DecisionPromptCacheBreakpoint, nil]
|
|
44
|
+
# Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
45
|
+
# from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
46
|
+
# token block.
|
|
47
|
+
#
|
|
35
48
|
# @param type [Symbol, :input_image]
|
|
36
49
|
|
|
37
50
|
# The image detail level, using the selected model's image profile. Defaults to
|
|
@@ -13,8 +13,22 @@ module OpenAI
|
|
|
13
13
|
# @return [Symbol, :input_text]
|
|
14
14
|
required :type, const: :input_text
|
|
15
15
|
|
|
16
|
-
# @!
|
|
16
|
+
# @!attribute prompt_cache_breakpoint
|
|
17
|
+
# Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
18
|
+
# from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
19
|
+
# token block.
|
|
20
|
+
#
|
|
21
|
+
# @return [OpenAI::Models::DecisionPromptCacheBreakpoint, nil]
|
|
22
|
+
optional :prompt_cache_breakpoint, -> { OpenAI::DecisionPromptCacheBreakpoint }, nil?: true
|
|
23
|
+
|
|
24
|
+
# @!method initialize(text:, prompt_cache_breakpoint: nil, type: :input_text)
|
|
17
25
|
# @param text [String]
|
|
26
|
+
#
|
|
27
|
+
# @param prompt_cache_breakpoint [OpenAI::Models::DecisionPromptCacheBreakpoint, nil]
|
|
28
|
+
# Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
29
|
+
# from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
30
|
+
# token block.
|
|
31
|
+
#
|
|
18
32
|
# @param type [Symbol, :input_text]
|
|
19
33
|
end
|
|
20
34
|
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module OpenAI
|
|
4
|
+
module Models
|
|
5
|
+
class DecisionPromptCacheBreakpoint < OpenAI::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute mode
|
|
7
|
+
# The breakpoint mode. Always `explicit`.
|
|
8
|
+
#
|
|
9
|
+
# @return [Symbol, :explicit]
|
|
10
|
+
required :mode, const: :explicit
|
|
11
|
+
|
|
12
|
+
# @!method initialize(mode: :explicit)
|
|
13
|
+
# Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
|
|
14
|
+
# from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
|
|
15
|
+
# token block.
|
|
16
|
+
#
|
|
17
|
+
# @param mode [Symbol, :explicit]
|
|
18
|
+
# The breakpoint mode. Always `explicit`.
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -52,7 +52,15 @@ module OpenAI
|
|
|
52
52
|
# @return [OpenAI::Models::ImageEditCompletedEvent::Usage]
|
|
53
53
|
required :usage, -> { OpenAI::ImageEditCompletedEvent::Usage }
|
|
54
54
|
|
|
55
|
-
# @!
|
|
55
|
+
# @!attribute safety_identifier
|
|
56
|
+
# The effective safety identifier used for safety monitoring and abuse detection.
|
|
57
|
+
# This is the non-empty `safety_identifier` from the request, or the deprecated
|
|
58
|
+
# `user` value when `safety_identifier` is omitted, null, or empty.
|
|
59
|
+
#
|
|
60
|
+
# @return [String, nil]
|
|
61
|
+
optional :safety_identifier, String, nil?: true
|
|
62
|
+
|
|
63
|
+
# @!method initialize(b64_json:, background:, created_at:, output_format:, quality:, size:, usage:, safety_identifier: nil, type: :"image_edit.completed")
|
|
56
64
|
# Emitted when image editing has completed and the final image is available.
|
|
57
65
|
#
|
|
58
66
|
# @param b64_json [String]
|
|
@@ -77,6 +85,11 @@ module OpenAI
|
|
|
77
85
|
# For the GPT image models only, the token usage information for the image
|
|
78
86
|
# generation.
|
|
79
87
|
#
|
|
88
|
+
# @param safety_identifier [String, nil]
|
|
89
|
+
# The effective safety identifier used for safety monitoring and abuse detection.
|
|
90
|
+
# This is the non-empty `safety_identifier` from the request, or the deprecated
|
|
91
|
+
# `user` value when `safety_identifier` is omitted, null, or empty.
|
|
92
|
+
#
|
|
80
93
|
# @param type [Symbol, :"image_edit.completed"]
|
|
81
94
|
# The type of the event. Always `image_edit.completed`.
|
|
82
95
|
|
|
@@ -130,6 +130,17 @@ module OpenAI
|
|
|
130
130
|
# @return [Symbol, OpenAI::Models::ImageEditParams::ResponseFormat, nil]
|
|
131
131
|
optional :response_format, enum: -> { OpenAI::ImageEditParams::ResponseFormat }, nil?: true
|
|
132
132
|
|
|
133
|
+
# @!attribute safety_identifier
|
|
134
|
+
# A stable identifier for an end user in your organization, used for safety
|
|
135
|
+
# monitoring and abuse detection. Hash a username or email address to avoid
|
|
136
|
+
# sending identifying information. A non-empty value takes precedence over the
|
|
137
|
+
# deprecated `user` parameter. If omitted, null, or empty, the API uses `user`
|
|
138
|
+
# when available.
|
|
139
|
+
# [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
140
|
+
#
|
|
141
|
+
# @return [String, nil]
|
|
142
|
+
optional :safety_identifier, String, nil?: true
|
|
143
|
+
|
|
133
144
|
# @!attribute size
|
|
134
145
|
# The size of the generated images. Defaults to `auto`. For `gpt-image-2`,
|
|
135
146
|
# `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,
|
|
@@ -147,14 +158,17 @@ module OpenAI
|
|
|
147
158
|
optional :size, union: -> { OpenAI::ImageEditParams::Size }, nil?: true
|
|
148
159
|
|
|
149
160
|
# @!attribute user
|
|
150
|
-
#
|
|
151
|
-
#
|
|
161
|
+
# @deprecated
|
|
162
|
+
#
|
|
163
|
+
# Deprecated: use `safety_identifier` instead. This parameter remains accepted for
|
|
164
|
+
# backward compatibility and is used when `safety_identifier` is omitted, null, or
|
|
165
|
+
# empty.
|
|
152
166
|
# [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
153
167
|
#
|
|
154
168
|
# @return [String, nil]
|
|
155
169
|
optional :user, String
|
|
156
170
|
|
|
157
|
-
# @!method initialize(image:, prompt:, background: nil, input_fidelity: nil, mask: nil, model: nil, n: nil, output_compression: nil, output_format: nil, partial_images: nil, quality: nil, response_format: nil, size: nil, user: nil, request_options: {})
|
|
171
|
+
# @!method initialize(image:, prompt:, background: nil, input_fidelity: nil, mask: nil, model: nil, n: nil, output_compression: nil, output_format: nil, partial_images: nil, quality: nil, response_format: nil, safety_identifier: nil, size: nil, user: nil, request_options: {})
|
|
158
172
|
# @param image [Pathname, StringIO, IO, String, OpenAI::FilePart, Array<Pathname, StringIO, IO, String, OpenAI::FilePart>]
|
|
159
173
|
# The image(s) to edit. Must be a supported image file or an array of images.
|
|
160
174
|
#
|
|
@@ -238,6 +252,14 @@ module OpenAI
|
|
|
238
252
|
# Legacy response format parameter for retired image models. Unsupported for GPT
|
|
239
253
|
# image models, which always return base64-encoded images.
|
|
240
254
|
#
|
|
255
|
+
# @param safety_identifier [String, nil]
|
|
256
|
+
# A stable identifier for an end user in your organization, used for safety
|
|
257
|
+
# monitoring and abuse detection. Hash a username or email address to avoid
|
|
258
|
+
# sending identifying information. A non-empty value takes precedence over the
|
|
259
|
+
# deprecated `user` parameter. If omitted, null, or empty, the API uses `user`
|
|
260
|
+
# when available.
|
|
261
|
+
# [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
262
|
+
#
|
|
241
263
|
# @param size [String, Symbol, OpenAI::Models::ImageEditParams::Size, nil]
|
|
242
264
|
# The size of the generated images. Defaults to `auto`. For `gpt-image-2`,
|
|
243
265
|
# `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,
|
|
@@ -252,8 +274,9 @@ module OpenAI
|
|
|
252
274
|
# models that allow automatic sizing.
|
|
253
275
|
#
|
|
254
276
|
# @param user [String]
|
|
255
|
-
#
|
|
256
|
-
# and
|
|
277
|
+
# Deprecated: use `safety_identifier` instead. This parameter remains accepted for
|
|
278
|
+
# backward compatibility and is used when `safety_identifier` is omitted, null, or
|
|
279
|
+
# empty.
|
|
257
280
|
# [Learn more](https://developers.openai.com/api/docs/guides/safety-best-practices#implement-safety-identifiers).
|
|
258
281
|
#
|
|
259
282
|
# @param request_options [OpenAI::RequestOptions, Hash{Symbol=>Object}]
|