openai 0.111.0 → 0.112.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.
Files changed (230) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +8 -0
  3. data/README.md +1 -1
  4. data/lib/openai/models/beta/agent.rb +2 -2
  5. data/lib/openai/models/beta/agent_create_params.rb +2 -2
  6. data/lib/openai/models/beta/agent_session.rb +2 -2
  7. data/lib/openai/models/beta/agent_tool.rb +18 -1
  8. data/lib/openai/models/beta/agent_tool_param.rb +18 -1
  9. data/lib/openai/models/beta/agent_update_params.rb +2 -2
  10. data/lib/openai/models/beta/agents/session_create_params.rb +2 -2
  11. data/lib/openai/models/beta/beta_response_input_file.rb +23 -1
  12. data/lib/openai/models/beta/beta_response_input_file_content.rb +23 -1
  13. data/lib/openai/models/beta/beta_response_input_image.rb +23 -1
  14. data/lib/openai/models/beta/beta_response_input_image_content.rb +23 -1
  15. data/lib/openai/models/beta/beta_response_input_text.rb +23 -1
  16. data/lib/openai/models/beta/beta_response_input_text_content.rb +23 -1
  17. data/lib/openai/models/beta/beta_response_item.rb +28 -1
  18. data/lib/openai/models/beta/beta_response_output_item.rb +28 -1
  19. data/lib/openai/models/beta/beta_response_tool_search_output_item_param.rb +26 -15
  20. data/lib/openai/models/beta/beta_tool.rb +26 -15
  21. data/lib/openai/models/beta/persisted_agent_tool.rb +18 -1
  22. data/lib/openai/models/beta/persisted_agent_tool_param.rb +18 -1
  23. data/lib/openai/models/chat/chat_completion_content_part.rb +23 -1
  24. data/lib/openai/models/chat/chat_completion_content_part_image.rb +23 -1
  25. data/lib/openai/models/chat/chat_completion_content_part_input_audio.rb +23 -1
  26. data/lib/openai/models/chat/chat_completion_content_part_text.rb +23 -1
  27. data/lib/openai/models/conversations/computer_screenshot_content.rb +23 -1
  28. data/lib/openai/models/decision_create_params.rb +8 -4
  29. data/lib/openai/models/image_edit_params.rb +20 -4
  30. data/lib/openai/models/image_generate_params.rb +23 -7
  31. data/lib/openai/models/image_model.rb +2 -0
  32. data/lib/openai/models/live/client_delegation.rb +20 -1
  33. data/lib/openai/models/live/client_event.rb +4 -4
  34. data/lib/openai/models/live/commentary_append_event.rb +1 -1
  35. data/lib/openai/models/live/decision_assistant_message.rb +154 -0
  36. data/lib/openai/models/live/decision_choice_option.rb +35 -0
  37. data/lib/openai/models/live/decision_developer_message.rb +70 -0
  38. data/lib/openai/models/live/decision_input_text.rb +26 -0
  39. data/lib/openai/models/live/decision_item_create_event.rb +490 -131
  40. data/lib/openai/models/live/decision_item_created_event.rb +486 -131
  41. data/lib/openai/models/live/decision_json_object.rb +10 -0
  42. data/lib/openai/models/live/decision_question.rb +172 -0
  43. data/lib/openai/models/live/decision_stored_assistant_message.rb +152 -0
  44. data/lib/openai/models/live/decision_stored_developer_message.rb +68 -0
  45. data/lib/openai/models/live/decision_stored_system_message.rb +68 -0
  46. data/lib/openai/models/live/decision_stored_user_message.rb +195 -0
  47. data/lib/openai/models/live/decision_system_message.rb +70 -0
  48. data/lib/openai/models/live/decision_trigger.rb +6 -258
  49. data/lib/openai/models/live/decision_user_message.rb +193 -0
  50. data/lib/openai/models/live/decisions_delegation_config.rb +5 -250
  51. data/lib/openai/models/live/decisions_delegation_update_config.rb +5 -257
  52. data/lib/openai/models/live/fork_client_event.rb +4 -4
  53. data/lib/openai/models/live/fork_server_event.rb +2 -2
  54. data/lib/openai/models/live/fork_session_config.rb +20 -1
  55. data/lib/openai/models/live/input_audio_muted_event.rb +3 -2
  56. data/lib/openai/models/live/input_audio_unmute_event.rb +2 -1
  57. data/lib/openai/models/live/input_audio_unmuted_event.rb +3 -2
  58. data/lib/openai/models/live/instructions_append_event.rb +5 -2
  59. data/lib/openai/models/live/media_session_config.rb +39 -2
  60. data/lib/openai/models/live/media_session_fork_config.rb +20 -1
  61. data/lib/openai/models/live/server_event.rb +2 -2
  62. data/lib/openai/models/live/session_accept_params.rb +39 -2
  63. data/lib/openai/models/live/session_config.rb +39 -2
  64. data/lib/openai/models/live/session_resource.rb +39 -2
  65. data/lib/openai/models/live/session_update_config.rb +41 -2
  66. data/lib/openai/models/live/sideband_client_event.rb +4 -4
  67. data/lib/openai/models/live/sideband_server_event.rb +2 -2
  68. data/lib/openai/models/live/thinking_append_event.rb +1 -1
  69. data/lib/openai/models/realtime/conversation_item_input_audio_transcription_delta_event.rb +10 -12
  70. data/lib/openai/models/realtime/realtime_error_event.rb +1 -1
  71. data/lib/openai/models/realtime/realtime_server_event.rb +1 -1
  72. data/lib/openai/models/realtime/realtime_translation_server_event.rb +1 -1
  73. data/lib/openai/models/responses/response_input_file.rb +23 -1
  74. data/lib/openai/models/responses/response_input_file_content.rb +23 -1
  75. data/lib/openai/models/responses/response_input_image.rb +23 -1
  76. data/lib/openai/models/responses/response_input_image_content.rb +23 -1
  77. data/lib/openai/models/responses/response_input_text.rb +23 -1
  78. data/lib/openai/models/responses/response_input_text_content.rb +23 -1
  79. data/lib/openai/models/responses/response_tool_search_output_item_param.rb +26 -15
  80. data/lib/openai/models/responses/tool.rb +26 -15
  81. data/lib/openai/resources/beta/agents.rb +2 -2
  82. data/lib/openai/resources/beta/responses.rb +2 -2
  83. data/lib/openai/resources/images.rb +18 -6
  84. data/lib/openai/resources/live/forks.rb +2 -2
  85. data/lib/openai/resources/live/sideband.rb +2 -2
  86. data/lib/openai/resources/live.rb +2 -2
  87. data/lib/openai/resources/realtime/translations.rb +2 -2
  88. data/lib/openai/resources/realtime.rb +2 -2
  89. data/lib/openai/resources/responses.rb +2 -2
  90. data/lib/openai/version.rb +1 -1
  91. data/lib/openai.rb +12 -0
  92. data/rbi/openai/models/beta/agent.rbi +2 -1
  93. data/rbi/openai/models/beta/agent_create_params.rbi +6 -3
  94. data/rbi/openai/models/beta/agent_session.rbi +2 -1
  95. data/rbi/openai/models/beta/agent_tool.rbi +40 -1
  96. data/rbi/openai/models/beta/agent_tool_param.rbi +40 -1
  97. data/rbi/openai/models/beta/agent_update_params.rbi +6 -3
  98. data/rbi/openai/models/beta/agents/session_create_params.rbi +6 -3
  99. data/rbi/openai/models/beta/beta_response_input_file.rbi +31 -1
  100. data/rbi/openai/models/beta/beta_response_input_file_content.rbi +39 -1
  101. data/rbi/openai/models/beta/beta_response_input_image.rbi +31 -1
  102. data/rbi/openai/models/beta/beta_response_input_image_content.rbi +39 -1
  103. data/rbi/openai/models/beta/beta_response_input_text.rbi +31 -1
  104. data/rbi/openai/models/beta/beta_response_input_text_content.rbi +39 -1
  105. data/rbi/openai/models/beta/beta_response_item.rbi +58 -1
  106. data/rbi/openai/models/beta/beta_response_output_item.rbi +58 -1
  107. data/rbi/openai/models/beta/beta_response_tool_search_output_item_param.rbi +24 -15
  108. data/rbi/openai/models/beta/beta_tool.rbi +24 -15
  109. data/rbi/openai/models/beta/persisted_agent_tool.rbi +40 -1
  110. data/rbi/openai/models/beta/persisted_agent_tool_param.rbi +40 -1
  111. data/rbi/openai/models/chat/chat_completion_content_part.rbi +43 -1
  112. data/rbi/openai/models/chat/chat_completion_content_part_image.rbi +41 -1
  113. data/rbi/openai/models/chat/chat_completion_content_part_input_audio.rbi +46 -1
  114. data/rbi/openai/models/chat/chat_completion_content_part_text.rbi +39 -1
  115. data/rbi/openai/models/conversations/computer_screenshot_content.rbi +48 -1
  116. data/rbi/openai/models/image_edit_params.rbi +12 -3
  117. data/rbi/openai/models/image_generate_params.rbi +15 -6
  118. data/rbi/openai/models/live/client_delegation.rbi +23 -1
  119. data/rbi/openai/models/live/commentary_append_event.rbi +1 -1
  120. data/rbi/openai/models/live/decision_assistant_message.rbi +247 -0
  121. data/rbi/openai/models/live/decision_choice_option.rbi +67 -0
  122. data/rbi/openai/models/live/decision_developer_message.rbi +109 -0
  123. data/rbi/openai/models/live/decision_input_text.rbi +55 -0
  124. data/rbi/openai/models/live/decision_item_create_event.rbi +765 -184
  125. data/rbi/openai/models/live/decision_item_created_event.rbi +737 -184
  126. data/rbi/openai/models/live/decision_json_object.rbi +16 -0
  127. data/rbi/openai/models/live/decision_question.rbi +300 -0
  128. data/rbi/openai/models/live/decision_stored_assistant_message.rbi +245 -0
  129. data/rbi/openai/models/live/decision_stored_developer_message.rbi +107 -0
  130. data/rbi/openai/models/live/decision_stored_system_message.rbi +107 -0
  131. data/rbi/openai/models/live/decision_stored_user_message.rbi +333 -0
  132. data/rbi/openai/models/live/decision_system_message.rbi +109 -0
  133. data/rbi/openai/models/live/decision_trigger.rbi +11 -383
  134. data/rbi/openai/models/live/decision_user_message.rbi +320 -0
  135. data/rbi/openai/models/live/decisions_delegation_config.rbi +10 -384
  136. data/rbi/openai/models/live/decisions_delegation_update_config.rbi +13 -387
  137. data/rbi/openai/models/live/fork_session_config.rbi +27 -1
  138. data/rbi/openai/models/live/input_audio_muted_event.rbi +3 -2
  139. data/rbi/openai/models/live/input_audio_unmute_event.rbi +2 -1
  140. data/rbi/openai/models/live/input_audio_unmuted_event.rbi +3 -2
  141. data/rbi/openai/models/live/instructions_append_event.rbi +5 -2
  142. data/rbi/openai/models/live/media_session_config.rbi +44 -2
  143. data/rbi/openai/models/live/media_session_fork_config.rbi +27 -1
  144. data/rbi/openai/models/live/session_accept_params.rbi +44 -2
  145. data/rbi/openai/models/live/session_config.rbi +44 -2
  146. data/rbi/openai/models/live/session_resource.rbi +44 -2
  147. data/rbi/openai/models/live/session_update_config.rbi +54 -2
  148. data/rbi/openai/models/live/thinking_append_event.rbi +1 -1
  149. data/rbi/openai/models/realtime/conversation_item_input_audio_transcription_delta_event.rbi +10 -12
  150. data/rbi/openai/models/realtime/realtime_error_event.rbi +1 -1
  151. data/rbi/openai/models/responses/response_input_file.rbi +31 -1
  152. data/rbi/openai/models/responses/response_input_file_content.rbi +39 -1
  153. data/rbi/openai/models/responses/response_input_image.rbi +33 -1
  154. data/rbi/openai/models/responses/response_input_image_content.rbi +41 -1
  155. data/rbi/openai/models/responses/response_input_text.rbi +31 -1
  156. data/rbi/openai/models/responses/response_input_text_content.rbi +39 -1
  157. data/rbi/openai/models/responses/response_tool_search_output_item_param.rbi +24 -15
  158. data/rbi/openai/models/responses/tool.rbi +24 -15
  159. data/rbi/openai/resources/beta/agents.rbi +4 -2
  160. data/rbi/openai/resources/beta/responses.rbi +8 -1
  161. data/rbi/openai/resources/images.rbi +18 -6
  162. data/rbi/openai/resources/live/forks.rbi +8 -1
  163. data/rbi/openai/resources/live/sideband.rbi +8 -1
  164. data/rbi/openai/resources/live.rbi +8 -1
  165. data/rbi/openai/resources/realtime/translations.rbi +8 -1
  166. data/rbi/openai/resources/realtime.rbi +8 -1
  167. data/rbi/openai/resources/responses.rbi +8 -1
  168. data/sig/openai/models/beta/agent_tool.rbs +14 -0
  169. data/sig/openai/models/beta/agent_tool_param.rbs +14 -0
  170. data/sig/openai/models/beta/beta_response_input_file.rbs +34 -3
  171. data/sig/openai/models/beta/beta_response_input_file_content.rbs +34 -3
  172. data/sig/openai/models/beta/beta_response_input_image.rbs +34 -3
  173. data/sig/openai/models/beta/beta_response_input_image_content.rbs +34 -3
  174. data/sig/openai/models/beta/beta_response_input_text.rbs +34 -3
  175. data/sig/openai/models/beta/beta_response_input_text_content.rbs +34 -3
  176. data/sig/openai/models/beta/beta_response_item.rbs +34 -3
  177. data/sig/openai/models/beta/beta_response_output_item.rbs +34 -3
  178. data/sig/openai/models/beta/beta_response_tool_search_output_item_param.rbs +24 -15
  179. data/sig/openai/models/beta/beta_tool.rbs +24 -15
  180. data/sig/openai/models/beta/persisted_agent_tool.rbs +14 -0
  181. data/sig/openai/models/beta/persisted_agent_tool_param.rbs +14 -0
  182. data/sig/openai/models/chat/chat_completion_content_part.rbs +34 -3
  183. data/sig/openai/models/chat/chat_completion_content_part_image.rbs +34 -3
  184. data/sig/openai/models/chat/chat_completion_content_part_input_audio.rbs +34 -3
  185. data/sig/openai/models/chat/chat_completion_content_part_text.rbs +34 -3
  186. data/sig/openai/models/conversations/computer_screenshot_content.rbs +34 -3
  187. data/sig/openai/models/image_edit_params.rbs +8 -2
  188. data/sig/openai/models/image_generate_params.rbs +10 -4
  189. data/sig/openai/models/live/client_delegation.rbs +30 -3
  190. data/sig/openai/models/live/decision_assistant_message.rbs +134 -0
  191. data/sig/openai/models/live/decision_choice_option.rbs +37 -0
  192. data/sig/openai/models/live/decision_developer_message.rbs +67 -0
  193. data/sig/openai/models/live/decision_input_text.rbs +20 -0
  194. data/sig/openai/models/live/decision_item_create_event.rbs +413 -131
  195. data/sig/openai/models/live/decision_item_created_event.rbs +401 -131
  196. data/sig/openai/models/live/decision_json_object.rbs +9 -0
  197. data/sig/openai/models/live/decision_question.rbs +164 -0
  198. data/sig/openai/models/live/decision_stored_assistant_message.rbs +131 -0
  199. data/sig/openai/models/live/decision_stored_developer_message.rbs +64 -0
  200. data/sig/openai/models/live/decision_stored_system_message.rbs +64 -0
  201. data/sig/openai/models/live/decision_stored_user_message.rbs +177 -0
  202. data/sig/openai/models/live/decision_system_message.rbs +67 -0
  203. data/sig/openai/models/live/decision_trigger.rbs +8 -208
  204. data/sig/openai/models/live/decision_user_message.rbs +180 -0
  205. data/sig/openai/models/live/decisions_delegation_config.rbs +6 -204
  206. data/sig/openai/models/live/decisions_delegation_update_config.rbs +8 -206
  207. data/sig/openai/models/live/fork_session_config.rbs +26 -0
  208. data/sig/openai/models/live/media_session_config.rbs +53 -4
  209. data/sig/openai/models/live/media_session_fork_config.rbs +26 -0
  210. data/sig/openai/models/live/session_accept_params.rbs +53 -4
  211. data/sig/openai/models/live/session_config.rbs +53 -4
  212. data/sig/openai/models/live/session_resource.rbs +53 -4
  213. data/sig/openai/models/live/session_update_config.rbs +52 -0
  214. data/sig/openai/models/realtime/conversation_item_input_audio_transcription_delta_event.rbs +10 -12
  215. data/sig/openai/models/responses/response_input_file.rbs +34 -3
  216. data/sig/openai/models/responses/response_input_file_content.rbs +34 -3
  217. data/sig/openai/models/responses/response_input_image.rbs +34 -3
  218. data/sig/openai/models/responses/response_input_image_content.rbs +34 -3
  219. data/sig/openai/models/responses/response_input_text.rbs +34 -3
  220. data/sig/openai/models/responses/response_input_text_content.rbs +34 -3
  221. data/sig/openai/models/responses/response_tool_search_output_item_param.rbs +24 -15
  222. data/sig/openai/models/responses/tool.rbs +24 -15
  223. data/sig/openai/resources/beta/responses.rbs +2 -1
  224. data/sig/openai/resources/live/forks.rbs +2 -1
  225. data/sig/openai/resources/live/sideband.rbs +2 -1
  226. data/sig/openai/resources/live.rbs +2 -1
  227. data/sig/openai/resources/realtime/translations.rbs +2 -1
  228. data/sig/openai/resources/realtime.rbs +2 -1
  229. data/sig/openai/resources/responses.rbs +2 -1
  230. metadata +37 -1
@@ -436,12 +436,26 @@ module OpenAI
436
436
  sig { returns(Symbol) }
437
437
  attr_accessor :type
438
438
 
439
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
440
+ # delegation. The model may still speak before this delay. Any commentary or
441
+ # thinking appended to the session cancels all pending acknowledgements, including
442
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
443
+ # (request immediately) for other sessions. Omission in a session update preserves
444
+ # the current value. Updates apply to subsequent delegations.
445
+ sig { returns(T.nilable(Integer)) }
446
+ attr_reader :acknowledgement_delay_ms
447
+
448
+ sig { params(acknowledgement_delay_ms: Integer).void }
449
+ attr_writer :acknowledgement_delay_ms
450
+
439
451
  # Delegate tasks to a Responses model managed by the Live session.
440
452
  sig do
441
453
  params(
442
454
 
443
455
  responses: OpenAI::Live::ResponsesDelegationConfig::OrHash,
444
456
 
457
+ acknowledgement_delay_ms: Integer,
458
+
445
459
  type: Symbol
446
460
  )
447
461
  .returns(T.attached_class)
@@ -452,6 +466,14 @@ module OpenAI
452
466
  # Responses.
453
467
  responses:,
454
468
 
469
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
470
+ # delegation. The model may still speak before this delay. Any commentary or
471
+ # thinking appended to the session cancels all pending acknowledgements, including
472
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
473
+ # (request immediately) for other sessions. Omission in a session update preserves
474
+ # the current value. Updates apply to subsequent delegations.
475
+ acknowledgement_delay_ms: nil,
476
+
455
477
  # The delegation owner. Always `responses` for tasks handled by the Responses API.
456
478
 
457
479
  type: :responses
@@ -460,7 +482,7 @@ module OpenAI
460
482
 
461
483
  sig do
462
484
  override.returns(
463
- {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol}
485
+ {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
464
486
  )
465
487
  end
466
488
  def to_hash
@@ -485,11 +507,24 @@ module OpenAI
485
507
  sig { returns(Symbol) }
486
508
  attr_accessor :type
487
509
 
510
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
511
+ # delegation. The model may still speak before this delay. Any commentary or
512
+ # thinking appended to the session cancels all pending acknowledgements, including
513
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
514
+ # delegations.
515
+ sig { returns(T.nilable(Integer)) }
516
+ attr_reader :acknowledgement_delay_ms
517
+
518
+ sig { params(acknowledgement_delay_ms: Integer).void }
519
+ attr_writer :acknowledgement_delay_ms
520
+
488
521
  sig do
489
522
  params(
490
523
 
491
524
  decisions: OpenAI::Live::DecisionsDelegationConfig::OrHash,
492
525
 
526
+ acknowledgement_delay_ms: Integer,
527
+
493
528
  type: Symbol
494
529
  )
495
530
  .returns(T.attached_class)
@@ -498,13 +533,20 @@ module OpenAI
498
533
 
499
534
  decisions:,
500
535
 
536
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
537
+ # delegation. The model may still speak before this delay. Any commentary or
538
+ # thinking appended to the session cancels all pending acknowledgements, including
539
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
540
+ # delegations.
541
+ acknowledgement_delay_ms: nil,
542
+
501
543
  type: :decisions
502
544
  )
503
545
  end
504
546
 
505
547
  sig do
506
548
  override.returns(
507
- {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol}
549
+ {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
508
550
  )
509
551
  end
510
552
  def to_hash
@@ -423,12 +423,26 @@ module OpenAI
423
423
  sig { returns(Symbol) }
424
424
  attr_accessor :type
425
425
 
426
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
427
+ # delegation. The model may still speak before this delay. Any commentary or
428
+ # thinking appended to the session cancels all pending acknowledgements, including
429
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
430
+ # (request immediately) for other sessions. Omission in a session update preserves
431
+ # the current value. Updates apply to subsequent delegations.
432
+ sig { returns(T.nilable(Integer)) }
433
+ attr_reader :acknowledgement_delay_ms
434
+
435
+ sig { params(acknowledgement_delay_ms: Integer).void }
436
+ attr_writer :acknowledgement_delay_ms
437
+
426
438
  # Delegate tasks to a Responses model managed by the Live session.
427
439
  sig do
428
440
  params(
429
441
 
430
442
  responses: OpenAI::Live::ResponsesDelegationConfig::OrHash,
431
443
 
444
+ acknowledgement_delay_ms: Integer,
445
+
432
446
  type: Symbol
433
447
  )
434
448
  .returns(T.attached_class)
@@ -439,6 +453,14 @@ module OpenAI
439
453
  # Responses.
440
454
  responses:,
441
455
 
456
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
457
+ # delegation. The model may still speak before this delay. Any commentary or
458
+ # thinking appended to the session cancels all pending acknowledgements, including
459
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
460
+ # (request immediately) for other sessions. Omission in a session update preserves
461
+ # the current value. Updates apply to subsequent delegations.
462
+ acknowledgement_delay_ms: nil,
463
+
442
464
  # The delegation owner. Always `responses` for tasks handled by the Responses API.
443
465
 
444
466
  type: :responses
@@ -447,7 +469,7 @@ module OpenAI
447
469
 
448
470
  sig do
449
471
  override.returns(
450
- {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol}
472
+ {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
451
473
  )
452
474
  end
453
475
  def to_hash
@@ -472,11 +494,24 @@ module OpenAI
472
494
  sig { returns(Symbol) }
473
495
  attr_accessor :type
474
496
 
497
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
498
+ # delegation. The model may still speak before this delay. Any commentary or
499
+ # thinking appended to the session cancels all pending acknowledgements, including
500
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
501
+ # delegations.
502
+ sig { returns(T.nilable(Integer)) }
503
+ attr_reader :acknowledgement_delay_ms
504
+
505
+ sig { params(acknowledgement_delay_ms: Integer).void }
506
+ attr_writer :acknowledgement_delay_ms
507
+
475
508
  sig do
476
509
  params(
477
510
 
478
511
  decisions: OpenAI::Live::DecisionsDelegationConfig::OrHash,
479
512
 
513
+ acknowledgement_delay_ms: Integer,
514
+
480
515
  type: Symbol
481
516
  )
482
517
  .returns(T.attached_class)
@@ -485,13 +520,20 @@ module OpenAI
485
520
 
486
521
  decisions:,
487
522
 
523
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
524
+ # delegation. The model may still speak before this delay. Any commentary or
525
+ # thinking appended to the session cancels all pending acknowledgements, including
526
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
527
+ # delegations.
528
+ acknowledgement_delay_ms: nil,
529
+
488
530
  type: :decisions
489
531
  )
490
532
  end
491
533
 
492
534
  sig do
493
535
  override.returns(
494
- {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol}
536
+ {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
495
537
  )
496
538
  end
497
539
  def to_hash
@@ -442,12 +442,26 @@ module OpenAI
442
442
  sig { returns(Symbol) }
443
443
  attr_accessor :type
444
444
 
445
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
446
+ # delegation. The model may still speak before this delay. Any commentary or
447
+ # thinking appended to the session cancels all pending acknowledgements, including
448
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
449
+ # (request immediately) for other sessions. Omission in a session update preserves
450
+ # the current value. Updates apply to subsequent delegations.
451
+ sig { returns(T.nilable(Integer)) }
452
+ attr_reader :acknowledgement_delay_ms
453
+
454
+ sig { params(acknowledgement_delay_ms: Integer).void }
455
+ attr_writer :acknowledgement_delay_ms
456
+
445
457
  # Delegate tasks to a Responses model managed by the Live session.
446
458
  sig do
447
459
  params(
448
460
 
449
461
  responses: OpenAI::Live::ResponsesDelegationConfig::OrHash,
450
462
 
463
+ acknowledgement_delay_ms: Integer,
464
+
451
465
  type: Symbol
452
466
  )
453
467
  .returns(T.attached_class)
@@ -458,6 +472,14 @@ module OpenAI
458
472
  # Responses.
459
473
  responses:,
460
474
 
475
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
476
+ # delegation. The model may still speak before this delay. Any commentary or
477
+ # thinking appended to the session cancels all pending acknowledgements, including
478
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
479
+ # (request immediately) for other sessions. Omission in a session update preserves
480
+ # the current value. Updates apply to subsequent delegations.
481
+ acknowledgement_delay_ms: nil,
482
+
461
483
  # The delegation owner. Always `responses` for tasks handled by the Responses API.
462
484
 
463
485
  type: :responses
@@ -466,7 +488,7 @@ module OpenAI
466
488
 
467
489
  sig do
468
490
  override.returns(
469
- {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol}
491
+ {responses: OpenAI::Live::ResponsesDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
470
492
  )
471
493
  end
472
494
  def to_hash
@@ -491,11 +513,24 @@ module OpenAI
491
513
  sig { returns(Symbol) }
492
514
  attr_accessor :type
493
515
 
516
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
517
+ # delegation. The model may still speak before this delay. Any commentary or
518
+ # thinking appended to the session cancels all pending acknowledgements, including
519
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
520
+ # delegations.
521
+ sig { returns(T.nilable(Integer)) }
522
+ attr_reader :acknowledgement_delay_ms
523
+
524
+ sig { params(acknowledgement_delay_ms: Integer).void }
525
+ attr_writer :acknowledgement_delay_ms
526
+
494
527
  sig do
495
528
  params(
496
529
 
497
530
  decisions: OpenAI::Live::DecisionsDelegationConfig::OrHash,
498
531
 
532
+ acknowledgement_delay_ms: Integer,
533
+
499
534
  type: Symbol
500
535
  )
501
536
  .returns(T.attached_class)
@@ -504,13 +539,20 @@ module OpenAI
504
539
 
505
540
  decisions:,
506
541
 
542
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
543
+ # delegation. The model may still speak before this delay. Any commentary or
544
+ # thinking appended to the session cancels all pending acknowledgements, including
545
+ # those for other delegations. Defaults to 400. Updates apply to subsequent
546
+ # delegations.
547
+ acknowledgement_delay_ms: nil,
548
+
507
549
  type: :decisions
508
550
  )
509
551
  end
510
552
 
511
553
  sig do
512
554
  override.returns(
513
- {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol}
555
+ {decisions: OpenAI::Live::DecisionsDelegationConfig, type: Symbol, acknowledgement_delay_ms: Integer}
514
556
  )
515
557
  end
516
558
  def to_hash
@@ -112,6 +112,18 @@ module OpenAI
112
112
  sig { returns(Symbol) }
113
113
  attr_accessor :type
114
114
 
115
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
116
+ # delegation. The model may still speak before this delay. Any commentary or
117
+ # thinking appended to the session cancels all pending acknowledgements, including
118
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
119
+ # (request immediately) for other sessions. Omission in a session update preserves
120
+ # the current value. Updates apply to subsequent delegations.
121
+ sig { returns(T.nilable(Integer)) }
122
+ attr_reader :acknowledgement_delay_ms
123
+
124
+ sig { params(acknowledgement_delay_ms: Integer).void }
125
+ attr_writer :acknowledgement_delay_ms
126
+
115
127
  # Responses backend settings to update. Omitted settings keep their existing
116
128
  # values.
117
129
  sig { returns(T.nilable(OpenAI::Live::ResponsesDelegationUpdateConfig)) }
@@ -125,6 +137,8 @@ module OpenAI
125
137
  sig do
126
138
  params(
127
139
 
140
+ acknowledgement_delay_ms: Integer,
141
+
128
142
  responses: OpenAI::Live::ResponsesDelegationUpdateConfig::OrHash,
129
143
 
130
144
  type: Symbol
@@ -133,6 +147,14 @@ module OpenAI
133
147
  end
134
148
  def self.new(
135
149
 
150
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
151
+ # delegation. The model may still speak before this delay. Any commentary or
152
+ # thinking appended to the session cancels all pending acknowledgements, including
153
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
154
+ # (request immediately) for other sessions. Omission in a session update preserves
155
+ # the current value. Updates apply to subsequent delegations.
156
+ acknowledgement_delay_ms: nil,
157
+
136
158
  # Responses backend settings to update. Omitted settings keep their existing
137
159
  # values.
138
160
  responses: nil,
@@ -145,7 +167,11 @@ module OpenAI
145
167
 
146
168
  sig do
147
169
  override.returns(
148
- {type: Symbol, responses: OpenAI::Live::ResponsesDelegationUpdateConfig}
170
+ {
171
+ type: Symbol,
172
+ acknowledgement_delay_ms: Integer,
173
+ responses: OpenAI::Live::ResponsesDelegationUpdateConfig
174
+ }
149
175
  )
150
176
  end
151
177
  def to_hash
@@ -164,6 +190,18 @@ module OpenAI
164
190
  sig { returns(Symbol) }
165
191
  attr_accessor :type
166
192
 
193
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
194
+ # delegation. The model may still speak before this delay. Any commentary or
195
+ # thinking appended to the session cancels all pending acknowledgements, including
196
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
197
+ # (request immediately) for other sessions. Omission in a session update preserves
198
+ # the current value. Updates apply to subsequent delegations.
199
+ sig { returns(T.nilable(Integer)) }
200
+ attr_reader :acknowledgement_delay_ms
201
+
202
+ sig { params(acknowledgement_delay_ms: Integer).void }
203
+ attr_writer :acknowledgement_delay_ms
204
+
167
205
  sig { returns(T.nilable(OpenAI::Live::DecisionsDelegationUpdateConfig)) }
168
206
  attr_reader :decisions
169
207
 
@@ -173,6 +211,8 @@ module OpenAI
173
211
  sig do
174
212
  params(
175
213
 
214
+ acknowledgement_delay_ms: Integer,
215
+
176
216
  decisions: OpenAI::Live::DecisionsDelegationUpdateConfig::OrHash,
177
217
 
178
218
  type: Symbol
@@ -181,6 +221,14 @@ module OpenAI
181
221
  end
182
222
  def self.new(
183
223
 
224
+ # Milliseconds to wait before requesting an automatic spoken acknowledgement for a
225
+ # delegation. The model may still speak before this delay. Any commentary or
226
+ # thinking appended to the session cancels all pending acknowledgements, including
227
+ # those for other delegations. Defaults to 400 for Decisions sessions and 0
228
+ # (request immediately) for other sessions. Omission in a session update preserves
229
+ # the current value. Updates apply to subsequent delegations.
230
+ acknowledgement_delay_ms: nil,
231
+
184
232
  decisions: nil,
185
233
 
186
234
  type: :decisions
@@ -189,7 +237,11 @@ module OpenAI
189
237
 
190
238
  sig do
191
239
  override.returns(
192
- {type: Symbol, decisions: OpenAI::Live::DecisionsDelegationUpdateConfig}
240
+ {
241
+ type: Symbol,
242
+ acknowledgement_delay_ms: Integer,
243
+ decisions: OpenAI::Live::DecisionsDelegationUpdateConfig
244
+ }
193
245
  )
194
246
  end
195
247
  def to_hash
@@ -36,7 +36,7 @@ module OpenAI
36
36
  attr_accessor :event_id
37
37
 
38
38
  # Provide silent reasoning or progress context to the Live model, optionally for
39
- # an existing client delegation.
39
+ # an existing client delegation. Rejected while an audio fixture is active.
40
40
  sig do
41
41
  params(
42
42
 
@@ -40,12 +40,11 @@ module OpenAI
40
40
  sig { params(delta: String).void }
41
41
  attr_writer :delta
42
42
 
43
- # The log probabilities of the transcription. These can be enabled by
44
- # configurating the session with
45
- # `"include": ["item.input_audio_transcription.logprobs"]`. Each entry in the
46
- # array corresponds a log probability of which token would be selected for this
47
- # chunk of transcription. This can help to identify if it was possible there were
48
- # multiple valid options for a given chunk of transcription.
43
+ # The log probabilities of the transcription. These can be enabled by configuring
44
+ # the session with `"include": ["item.input_audio_transcription.logprobs"]`. Each
45
+ # entry in the array corresponds a log probability of which token would be
46
+ # selected for this chunk of transcription. This can help to identify if it was
47
+ # possible there were multiple valid options for a given chunk of transcription.
49
48
  sig { returns(T.nilable(T::Array[OpenAI::Realtime::LogProbProperties])) }
50
49
  attr_accessor :logprobs
51
50
 
@@ -82,12 +81,11 @@ module OpenAI
82
81
  # The text delta.
83
82
  delta: nil,
84
83
 
85
- # The log probabilities of the transcription. These can be enabled by
86
- # configurating the session with
87
- # `"include": ["item.input_audio_transcription.logprobs"]`. Each entry in the
88
- # array corresponds a log probability of which token would be selected for this
89
- # chunk of transcription. This can help to identify if it was possible there were
90
- # multiple valid options for a given chunk of transcription.
84
+ # The log probabilities of the transcription. These can be enabled by configuring
85
+ # the session with `"include": ["item.input_audio_transcription.logprobs"]`. Each
86
+ # entry in the array corresponds a log probability of which token would be
87
+ # selected for this chunk of transcription. This can help to identify if it was
88
+ # possible there were multiple valid options for a given chunk of transcription.
91
89
  logprobs: nil,
92
90
 
93
91
  # The event type, must be `conversation.item.input_audio_transcription.delta`.
@@ -31,7 +31,7 @@ module OpenAI
31
31
 
32
32
  # Returned when an error occurs, which could be a client problem or a server
33
33
  # problem. Most errors are recoverable and the session will stay open, we
34
- # recommend to implementors to monitor and log error messages by default.
34
+ # recommend to implementers to monitor and log error messages by default.
35
35
  sig do
36
36
  params(
37
37
 
@@ -165,18 +165,30 @@ module OpenAI
165
165
  sig { returns(Symbol) }
166
166
  attr_accessor :mode
167
167
 
168
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
169
+ sig { returns(T.nilable(OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::OrSymbol)) }
170
+ attr_reader :ttl
171
+
172
+ sig { params(ttl: OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::OrSymbol).void }
173
+ attr_writer :ttl
174
+
168
175
  # Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
169
176
  # from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
170
177
  # token block.
171
178
  sig do
172
179
  params(
173
180
 
181
+ ttl: OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::OrSymbol,
182
+
174
183
  mode: Symbol
175
184
  )
176
185
  .returns(T.attached_class)
177
186
  end
178
187
  def self.new(
179
188
 
189
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
190
+ ttl: nil,
191
+
180
192
  # The breakpoint mode. Always `explicit`.
181
193
 
182
194
  mode: :explicit
@@ -185,12 +197,30 @@ module OpenAI
185
197
 
186
198
  sig do
187
199
  override.returns(
188
- {mode: Symbol}
200
+ {mode: Symbol, ttl: OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::OrSymbol}
189
201
  )
190
202
  end
191
203
  def to_hash
192
204
  end
193
205
 
206
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
207
+ module Ttl
208
+ extend OpenAI::Internal::Type::Enum
209
+
210
+ TaggedSymbol = T.type_alias {
211
+ T.all(Symbol, OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl)
212
+ }
213
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
214
+
215
+ TTL_30M = T.let(:"30m", OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::TaggedSymbol)
216
+ TTL_12H = T.let(:"12h", OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::TaggedSymbol)
217
+
218
+ sig {
219
+ override.returns(T::Array[OpenAI::Responses::ResponseInputFile::PromptCacheBreakpoint::Ttl::TaggedSymbol])
220
+ }
221
+ def self.values
222
+ end
223
+ end
194
224
  end
195
225
 
196
226
  end
@@ -163,18 +163,30 @@ module OpenAI
163
163
  sig { returns(Symbol) }
164
164
  attr_accessor :mode
165
165
 
166
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
167
+ sig { returns(T.nilable(OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::OrSymbol)) }
168
+ attr_reader :ttl
169
+
170
+ sig { params(ttl: OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::OrSymbol).void }
171
+ attr_writer :ttl
172
+
166
173
  # Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
167
174
  # from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
168
175
  # token block.
169
176
  sig do
170
177
  params(
171
178
 
179
+ ttl: OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::OrSymbol,
180
+
172
181
  mode: Symbol
173
182
  )
174
183
  .returns(T.attached_class)
175
184
  end
176
185
  def self.new(
177
186
 
187
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
188
+ ttl: nil,
189
+
178
190
  # The breakpoint mode. Always `explicit`.
179
191
 
180
192
  mode: :explicit
@@ -183,12 +195,38 @@ module OpenAI
183
195
 
184
196
  sig do
185
197
  override.returns(
186
- {mode: Symbol}
198
+ {mode: Symbol, ttl: OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::OrSymbol}
187
199
  )
188
200
  end
189
201
  def to_hash
190
202
  end
191
203
 
204
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
205
+ module Ttl
206
+ extend OpenAI::Internal::Type::Enum
207
+
208
+ TaggedSymbol = T.type_alias {
209
+ T.all(Symbol, OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl)
210
+ }
211
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
212
+
213
+ TTL_30M = T.let(
214
+ :"30m",
215
+ OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::TaggedSymbol
216
+ )
217
+ TTL_12H = T.let(
218
+ :"12h",
219
+ OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::TaggedSymbol
220
+ )
221
+
222
+ sig {
223
+ override.returns(
224
+ T::Array[OpenAI::Responses::ResponseInputFileContent::PromptCacheBreakpoint::Ttl::TaggedSymbol]
225
+ )
226
+ }
227
+ def self.values
228
+ end
229
+ end
192
230
  end
193
231
 
194
232
  end
@@ -128,18 +128,30 @@ module OpenAI
128
128
  sig { returns(Symbol) }
129
129
  attr_accessor :mode
130
130
 
131
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
132
+ sig { returns(T.nilable(OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::OrSymbol)) }
133
+ attr_reader :ttl
134
+
135
+ sig { params(ttl: OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::OrSymbol).void }
136
+ attr_writer :ttl
137
+
131
138
  # Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL
132
139
  # from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a
133
140
  # token block.
134
141
  sig do
135
142
  params(
136
143
 
144
+ ttl: OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::OrSymbol,
145
+
137
146
  mode: Symbol
138
147
  )
139
148
  .returns(T.attached_class)
140
149
  end
141
150
  def self.new(
142
151
 
152
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
153
+ ttl: nil,
154
+
143
155
  # The breakpoint mode. Always `explicit`.
144
156
 
145
157
  mode: :explicit
@@ -148,12 +160,32 @@ module OpenAI
148
160
 
149
161
  sig do
150
162
  override.returns(
151
- {mode: Symbol}
163
+ {mode: Symbol, ttl: OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::OrSymbol}
152
164
  )
153
165
  end
154
166
  def to_hash
155
167
  end
156
168
 
169
+ # The minimum lifetime of this cache breakpoint. Defaults to the request TTL.
170
+ module Ttl
171
+ extend OpenAI::Internal::Type::Enum
172
+
173
+ TaggedSymbol = T.type_alias {
174
+ T.all(Symbol, OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl)
175
+ }
176
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
177
+
178
+ TTL_30M = T.let(:"30m", OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::TaggedSymbol)
179
+ TTL_12H = T.let(:"12h", OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::TaggedSymbol)
180
+
181
+ sig {
182
+ override.returns(
183
+ T::Array[OpenAI::Responses::ResponseInputImage::PromptCacheBreakpoint::Ttl::TaggedSymbol]
184
+ )
185
+ }
186
+ def self.values
187
+ end
188
+ end
157
189
  end
158
190
 
159
191
  end