openai 0.84.0 → 0.86.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 +110 -0
- data/README.md +95 -13
- data/SECURITY.md +10 -0
- data/docs/architecture/security-model.md +293 -0
- data/lib/openai/auth/workload_identity_auth.rb +2 -2
- data/lib/openai/auth/x509_token_exchange.rb +7 -1
- data/lib/openai/auth/x509_transport.rb +21 -3
- data/lib/openai/client.rb +8 -2
- data/lib/openai/errors.rb +28 -9
- data/lib/openai/file_part.rb +35 -2
- data/lib/openai/helpers/realtime/client_extension.rb +37 -121
- data/lib/openai/helpers/realtime/connection.rb +13 -90
- data/lib/openai/helpers/realtime/connection_manager.rb +22 -77
- data/lib/openai/helpers/realtime/connection_resources.rb +3 -1
- data/lib/openai/helpers/realtime/errors.rb +3 -27
- data/lib/openai/helpers/realtime/transports/async_websocket.rb +25 -368
- data/lib/openai/helpers/responses_websocket/client_extension.rb +62 -0
- data/lib/openai/helpers/responses_websocket/connection.rb +288 -0
- data/lib/openai/helpers/responses_websocket/connection_manager.rb +34 -0
- data/lib/openai/helpers/responses_websocket/connection_resources.rb +22 -0
- data/lib/openai/helpers/responses_websocket/errors.rb +56 -0
- data/lib/openai/helpers/responses_websocket/resources/responses_extension.rb +31 -0
- data/lib/openai/helpers/responses_websocket/transports/async_websocket.rb +29 -0
- data/lib/openai/helpers/responses_websocket/unknown_server_event.rb +54 -0
- data/lib/openai/helpers/responses_websocket.rb +12 -0
- data/lib/openai/helpers/sorbet.rb +7 -1
- data/lib/openai/helpers/streaming/chat_completion_stream.rb +65 -15
- data/lib/openai/helpers/streaming/chat_events.rb +9 -7
- data/lib/openai/helpers/streaming/response_stream.rb +79 -68
- data/lib/openai/helpers/structured_output/array_of.rb +2 -2
- data/lib/openai/helpers/structured_output/base_model.rb +19 -5
- data/lib/openai/helpers/structured_output/chat_completion_parser.rb +6 -3
- data/lib/openai/helpers/structured_output/json_schema_converter.rb +35 -12
- data/lib/openai/helpers/structured_output/response_parser.rb +125 -2
- data/lib/openai/helpers/websocket/async_websocket_transport.rb +422 -0
- data/lib/openai/helpers/websocket/client_request.rb +131 -0
- data/lib/openai/helpers/websocket/connection.rb +104 -0
- data/lib/openai/helpers/websocket/connection_manager.rb +104 -0
- data/lib/openai/helpers/websocket/errors.rb +32 -0
- data/lib/openai/helpers/websocket/protocol.rb +26 -0
- data/lib/openai/helpers/websocket.rb +10 -0
- data/lib/openai/internal/conversation_cursor_page.rb +1 -1
- data/lib/openai/internal/cursor_page.rb +1 -1
- data/lib/openai/internal/next_cursor_page.rb +1 -1
- data/lib/openai/internal/page.rb +1 -1
- data/lib/openai/internal/transport/base_client.rb +45 -8
- data/lib/openai/internal/transport/request_body_merge.rb +71 -0
- data/lib/openai/internal/type/base_page.rb +2 -2
- data/lib/openai/internal/type/base_stream.rb +8 -0
- data/lib/openai/internal/type/converter.rb +10 -2
- data/lib/openai/internal/type/duplicable_response_carrier.rb +23 -0
- data/lib/openai/internal/type/file_input.rb +3 -3
- data/lib/openai/internal/type/union.rb +24 -4
- data/lib/openai/internal/util.rb +139 -20
- data/lib/openai/internal/vector_store_file_uploader.rb +1 -1
- data/lib/openai/models/admin/organization/projects/service_accounts/api_key_create_params.rb +9 -1
- data/lib/openai/models/admin/organization/projects/service_accounts/api_key_create_response.rb +14 -1
- data/lib/openai/models/admin/organization/usage_costs_params.rb +1 -1
- data/lib/openai/models/audio/transcription_create_response.rb +5 -5
- data/lib/openai/models/batch.rb +2 -2
- data/lib/openai/models/beta/beta_custom_tool.rb +13 -1
- data/lib/openai/models/beta/beta_function_tool.rb +8 -1
- data/lib/openai/models/beta/beta_namespace_tool.rb +10 -1
- data/lib/openai/models/beta/beta_response.rb +150 -11
- data/lib/openai/models/beta/beta_response_configuration_update_item.rb +103 -0
- data/lib/openai/models/beta/beta_response_configuration_update_item_param.rb +104 -0
- data/lib/openai/models/beta/beta_response_custom_tool_call.rb +9 -1
- data/lib/openai/models/beta/beta_response_custom_tool_call_item.rb +3 -1
- data/lib/openai/models/beta/beta_response_error.rb +96 -1
- data/lib/openai/models/beta/beta_response_function_call_arguments_done_event.rb +1 -9
- data/lib/openai/models/beta/beta_response_function_tool_call.rb +9 -1
- data/lib/openai/models/beta/beta_response_function_tool_call_item.rb +3 -1
- data/lib/openai/models/beta/beta_response_function_web_search.rb +1 -0
- data/lib/openai/models/beta/beta_response_incomplete_event.rb +4 -0
- data/lib/openai/models/beta/beta_response_inject_event.rb +2 -2
- data/lib/openai/models/beta/beta_response_inject_failed_event.rb +2 -2
- data/lib/openai/models/beta/beta_response_input_item.rb +6 -1
- data/lib/openai/models/beta/beta_response_item.rb +5 -1
- data/lib/openai/models/beta/beta_response_steer_accepted_event.rb +81 -0
- data/lib/openai/models/beta/beta_response_steer_error_code.rb +61 -0
- data/lib/openai/models/beta/beta_response_steer_event.rb +75 -0
- data/lib/openai/models/beta/beta_response_steer_failed_event.rb +151 -0
- data/lib/openai/models/beta/beta_response_steer_input.rb +360 -0
- data/lib/openai/models/beta/beta_response_steer_input_content.rb +28 -0
- data/lib/openai/models/beta/beta_response_steer_pending_event.rb +113 -0
- data/lib/openai/models/beta/beta_response_steer_pending_reason.rb +26 -0
- data/lib/openai/models/beta/beta_response_steer_required_input.rb +215 -0
- data/lib/openai/models/beta/beta_response_stream_event.rb +4 -0
- data/lib/openai/models/beta/beta_responses_client_event.rb +50 -8
- data/lib/openai/models/beta/beta_responses_server_event.rb +165 -5
- data/lib/openai/models/beta/response_compact_params.rb +23 -18
- data/lib/openai/models/beta/response_create_params.rb +19 -7
- data/lib/openai/models/beta/responses/beta_response_item_list.rb +2 -2
- data/lib/openai/models/beta/responses/input_token_count_params.rb +3 -3
- data/lib/openai/models/chat/completion_create_params.rb +4 -4
- data/lib/openai/models/chat_model.rb +1 -0
- data/lib/openai/models/conversations/conversation_create_params.rb +2 -2
- data/lib/openai/models/conversations/conversation_item.rb +5 -1
- data/lib/openai/models/conversations/conversation_item_list.rb +2 -2
- data/lib/openai/models/conversations/item_create_params.rb +2 -2
- data/lib/openai/models/error_object.rb +90 -1
- data/lib/openai/models/eval_create_response.rb +1 -1
- data/lib/openai/models/eval_list_response.rb +1 -1
- data/lib/openai/models/eval_retrieve_response.rb +1 -1
- data/lib/openai/models/eval_update_response.rb +1 -1
- data/lib/openai/models/evals/create_eval_completions_run_data_source.rb +2 -2
- data/lib/openai/models/responses/custom_tool.rb +13 -1
- data/lib/openai/models/responses/function_tool.rb +8 -1
- data/lib/openai/models/responses/input_token_count_params.rb +3 -3
- data/lib/openai/models/responses/namespace_tool.rb +10 -1
- data/lib/openai/models/responses/response.rb +151 -14
- data/lib/openai/models/responses/response_compact_params.rb +23 -18
- data/lib/openai/models/responses/response_configuration_update_item.rb +56 -0
- data/lib/openai/models/responses/response_configuration_update_item_param.rb +57 -0
- data/lib/openai/models/responses/response_create_params.rb +15 -6
- data/lib/openai/models/responses/response_custom_tool_call.rb +9 -1
- data/lib/openai/models/responses/response_custom_tool_call_item.rb +3 -1
- data/lib/openai/models/responses/response_error.rb +96 -1
- data/lib/openai/models/responses/response_function_call_arguments_done_event.rb +1 -9
- data/lib/openai/models/responses/response_function_tool_call.rb +9 -1
- data/lib/openai/models/responses/response_function_tool_call_item.rb +3 -1
- data/lib/openai/models/responses/response_function_web_search.rb +1 -0
- data/lib/openai/models/responses/response_incomplete_event.rb +4 -0
- data/lib/openai/models/responses/response_input_item.rb +6 -1
- data/lib/openai/models/responses/response_item.rb +5 -1
- data/lib/openai/models/responses/response_item_list.rb +2 -2
- data/lib/openai/models/responses/response_steer_accepted_event.rb +79 -0
- data/lib/openai/models/responses/response_steer_error_code.rb +59 -0
- data/lib/openai/models/responses/response_steer_event.rb +73 -0
- data/lib/openai/models/responses/response_steer_failed_event.rb +149 -0
- data/lib/openai/models/responses/response_steer_input.rb +304 -0
- data/lib/openai/models/responses/response_steer_input_content.rb +26 -0
- data/lib/openai/models/responses/response_steer_pending_event.rb +111 -0
- data/lib/openai/models/responses/response_steer_pending_reason.rb +24 -0
- data/lib/openai/models/responses/response_steer_required_input.rb +213 -0
- data/lib/openai/models/responses/response_stream_event.rb +4 -0
- data/lib/openai/models/responses/responses_client_event.rb +881 -769
- data/lib/openai/models/responses/responses_server_event.rb +163 -5
- data/lib/openai/models/safety/alert_retrieve_params.rb +24 -0
- data/lib/openai/models/safety/safety_alert.rb +96 -0
- data/lib/openai/models/video_create_error.rb +93 -1
- data/lib/openai/models/webhooks/safety_alert_created_webhook_event.rb +63 -0
- data/lib/openai/models/webhooks/safety_org_alert_created_webhook_event.rb +63 -0
- data/lib/openai/models/webhooks/unwrap_webhook_event.rb +7 -1
- data/lib/openai/models.rb +2 -0
- data/lib/openai/net_http_client.rb +17 -3
- data/lib/openai/providers/bedrock.rb +22 -13
- data/lib/openai/request_options.rb +18 -4
- data/lib/openai/resources/admin/organization/projects/service_accounts/api_keys.rb +3 -1
- data/lib/openai/resources/beta/responses/input_items.rb +1 -1
- data/lib/openai/resources/beta/responses/input_tokens.rb +1 -1
- data/lib/openai/resources/beta/responses.rb +6 -6
- data/lib/openai/resources/chat/completions.rb +2 -2
- data/lib/openai/resources/containers/files.rb +1 -0
- data/lib/openai/resources/conversations/items.rb +3 -3
- data/lib/openai/resources/conversations.rb +1 -1
- data/lib/openai/resources/responses/input_items.rb +1 -1
- data/lib/openai/resources/responses/input_tokens.rb +1 -1
- data/lib/openai/resources/responses.rb +42 -10
- data/lib/openai/resources/safety/alerts.rb +37 -0
- data/lib/openai/resources/safety.rb +18 -0
- data/lib/openai/resources/webhooks.rb +1 -1
- data/lib/openai/response_carrier.rb +42 -0
- data/lib/openai/version.rb +1 -1
- data/lib/openai.rb +32 -0
- data/rbi/openai/auth/subject_token_providers.rbi +72 -0
- data/rbi/openai/client.rbi +3 -0
- data/rbi/openai/errors.rbi +53 -4
- data/rbi/openai/file_part.rbi +5 -0
- data/rbi/openai/helpers/realtime/extensions.rbi +3 -3
- data/rbi/openai/helpers/responses_websocket/connection.rbi +82 -0
- data/rbi/openai/helpers/responses_websocket/connection_manager.rbi +39 -0
- data/rbi/openai/helpers/responses_websocket/connection_resources.rbi +17 -0
- data/rbi/openai/helpers/responses_websocket/extensions.rbi +108 -0
- data/rbi/openai/helpers/responses_websocket/transports/async_websocket.rbi +28 -0
- data/rbi/openai/helpers/responses_websocket/unknown_server_event.rbi +29 -0
- data/rbi/openai/helpers/streaming/chat_completion_stream.rbi +214 -0
- data/rbi/openai/helpers/streaming/events.rbi +61 -4
- data/rbi/openai/helpers/streaming/exceptions.rbi +30 -0
- data/rbi/openai/helpers/streaming/response_stream.rbi +7 -3
- data/rbi/openai/helpers/structured_output/response_parser.rbi +23 -0
- data/rbi/openai/helpers/websocket.rbi +33 -0
- data/rbi/openai/internal/transport/base_client.rbi +11 -0
- data/rbi/openai/internal/type/base_stream.rbi +4 -0
- data/rbi/openai/internal/util.rbi +1 -0
- data/rbi/openai/models/admin/organization/projects/service_accounts/api_key_create_params.rbi +10 -0
- data/rbi/openai/models/admin/organization/projects/service_accounts/api_key_create_response.rbi +19 -1
- data/rbi/openai/models/admin/organization/usage_costs_params.rbi +2 -2
- data/rbi/openai/models/batch.rbi +2 -2
- data/rbi/openai/models/beta/beta_custom_tool.rbi +15 -0
- data/rbi/openai/models/beta/beta_function_tool.rbi +11 -0
- data/rbi/openai/models/beta/beta_namespace_tool.rbi +15 -0
- data/rbi/openai/models/beta/beta_response.rbi +301 -9
- data/rbi/openai/models/beta/beta_response_configuration_update_item.rbi +200 -0
- data/rbi/openai/models/beta/beta_response_configuration_update_item_param.rbi +207 -0
- data/rbi/openai/models/beta/beta_response_custom_tool_call.rbi +13 -0
- data/rbi/openai/models/beta/beta_response_custom_tool_call_item.rbi +6 -0
- data/rbi/openai/models/beta/beta_response_error.rbi +161 -3
- data/rbi/openai/models/beta/beta_response_function_call_arguments_done_event.rbi +0 -10
- data/rbi/openai/models/beta/beta_response_function_tool_call.rbi +13 -0
- data/rbi/openai/models/beta/beta_response_function_tool_call_item.rbi +6 -0
- data/rbi/openai/models/beta/beta_response_function_web_search.rbi +1 -0
- data/rbi/openai/models/beta/beta_response_incomplete_event.rbi +4 -0
- data/rbi/openai/models/beta/beta_response_inject_created_event.rbi +1 -1
- data/rbi/openai/models/beta/beta_response_inject_event.rbi +3 -0
- data/rbi/openai/models/beta/beta_response_inject_failed_event.rbi +4 -1
- data/rbi/openai/models/beta/beta_response_input_item.rbi +1 -0
- data/rbi/openai/models/beta/beta_response_item.rbi +1 -0
- data/rbi/openai/models/beta/beta_response_steer_accepted_event.rbi +148 -0
- data/rbi/openai/models/beta/beta_response_steer_error_code.rbi +65 -0
- data/rbi/openai/models/beta/beta_response_steer_event.rbi +118 -0
- data/rbi/openai/models/beta/beta_response_steer_failed_event.rbi +271 -0
- data/rbi/openai/models/beta/beta_response_steer_input.rbi +602 -0
- data/rbi/openai/models/beta/beta_response_steer_input_content.rbi +31 -0
- data/rbi/openai/models/beta/beta_response_steer_pending_event.rbi +222 -0
- data/rbi/openai/models/beta/beta_response_steer_pending_reason.rbi +35 -0
- data/rbi/openai/models/beta/beta_response_steer_required_input.rbi +379 -0
- data/rbi/openai/models/beta/beta_responses_client_event.rbi +72 -43
- data/rbi/openai/models/beta/beta_responses_server_event.rbi +283 -80
- data/rbi/openai/models/beta/response_compact_params.rbi +25 -21
- data/rbi/openai/models/beta/response_create_params.rbi +16 -3
- data/rbi/openai/models/beta/responses/beta_response_item_list.rbi +1 -0
- data/rbi/openai/models/chat/completion_create_params.rbi +3 -3
- data/rbi/openai/models/chat_model.rbi +1 -0
- data/rbi/openai/models/conversations/conversation_create_params.rbi +3 -0
- data/rbi/openai/models/conversations/conversation_item.rbi +1 -0
- data/rbi/openai/models/conversations/conversation_item_list.rbi +1 -0
- data/rbi/openai/models/conversations/item_create_params.rbi +3 -0
- data/rbi/openai/models/error_object.rbi +156 -3
- data/rbi/openai/models/eval_create_response.rbi +1 -1
- data/rbi/openai/models/eval_list_response.rbi +1 -1
- data/rbi/openai/models/eval_retrieve_response.rbi +1 -1
- data/rbi/openai/models/eval_update_response.rbi +1 -1
- data/rbi/openai/models/evals/create_eval_completions_run_data_source.rbi +2 -2
- data/rbi/openai/models/realtime/conversation_created_event.rbi +4 -1
- data/rbi/openai/models/realtime/conversation_item_create_event.rbi +2 -2
- data/rbi/openai/models/realtime/conversation_item_delete_event.rbi +1 -1
- data/rbi/openai/models/realtime/conversation_item_input_audio_transcription_completed_event.rbi +5 -3
- data/rbi/openai/models/realtime/conversation_item_input_audio_transcription_delta_event.rbi +2 -2
- data/rbi/openai/models/realtime/conversation_item_input_audio_transcription_failed_event.rbi +1 -1
- data/rbi/openai/models/realtime/conversation_item_retrieve_event.rbi +1 -1
- data/rbi/openai/models/realtime/conversation_item_truncate_event.rbi +1 -1
- data/rbi/openai/models/realtime/input_audio_buffer_append_event.rbi +1 -1
- data/rbi/openai/models/realtime/input_audio_buffer_clear_event.rbi +1 -1
- data/rbi/openai/models/realtime/input_audio_buffer_commit_event.rbi +1 -1
- data/rbi/openai/models/realtime/output_audio_buffer_clear_event.rbi +1 -1
- data/rbi/openai/models/realtime/rate_limits_updated_event.rbi +4 -4
- data/rbi/openai/models/realtime/response_cancel_event.rbi +1 -1
- data/rbi/openai/models/realtime/response_content_part_added_event.rbi +4 -4
- data/rbi/openai/models/realtime/response_content_part_done_event.rbi +4 -4
- data/rbi/openai/models/realtime/response_create_event.rbi +5 -1
- data/rbi/openai/models/realtime/session_update_event.rbi +1 -1
- data/rbi/openai/models/responses/custom_tool.rbi +15 -0
- data/rbi/openai/models/responses/function_tool.rbi +11 -0
- data/rbi/openai/models/responses/namespace_tool.rbi +15 -0
- data/rbi/openai/models/responses/response.rbi +299 -8
- data/rbi/openai/models/responses/response_compact_params.rbi +25 -21
- data/rbi/openai/models/responses/response_configuration_update_item.rbi +112 -0
- data/rbi/openai/models/responses/response_configuration_update_item_param.rbi +117 -0
- data/rbi/openai/models/responses/response_create_params.rbi +14 -2
- data/rbi/openai/models/responses/response_custom_tool_call.rbi +13 -0
- data/rbi/openai/models/responses/response_custom_tool_call_item.rbi +6 -0
- data/rbi/openai/models/responses/response_error.rbi +161 -3
- data/rbi/openai/models/responses/response_function_call_arguments_done_event.rbi +1 -17
- data/rbi/openai/models/responses/response_function_tool_call.rbi +13 -0
- data/rbi/openai/models/responses/response_function_tool_call_item.rbi +6 -0
- data/rbi/openai/models/responses/response_function_web_search.rbi +1 -0
- data/rbi/openai/models/responses/response_incomplete_event.rbi +4 -0
- data/rbi/openai/models/responses/response_input_item.rbi +1 -0
- data/rbi/openai/models/responses/response_item.rbi +1 -0
- data/rbi/openai/models/responses/response_item_list.rbi +1 -0
- data/rbi/openai/models/responses/response_steer_accepted_event.rbi +146 -0
- data/rbi/openai/models/responses/response_steer_error_code.rbi +63 -0
- data/rbi/openai/models/responses/response_steer_event.rbi +119 -0
- data/rbi/openai/models/responses/response_steer_failed_event.rbi +272 -0
- data/rbi/openai/models/responses/response_steer_input.rbi +474 -0
- data/rbi/openai/models/responses/response_steer_input_content.rbi +29 -0
- data/rbi/openai/models/responses/response_steer_pending_event.rbi +220 -0
- data/rbi/openai/models/responses/response_steer_pending_reason.rbi +33 -0
- data/rbi/openai/models/responses/response_steer_required_input.rbi +377 -0
- data/rbi/openai/models/responses/responses_client_event.rbi +1228 -1036
- data/rbi/openai/models/responses/responses_server_event.rbi +410 -75
- data/rbi/openai/models/safety/alert_retrieve_params.rbi +55 -0
- data/rbi/openai/models/safety/safety_alert.rbi +147 -0
- data/rbi/openai/models/video_create_error.rbi +149 -3
- data/rbi/openai/models/webhooks/safety_alert_created_webhook_event.rbi +130 -0
- data/rbi/openai/models/webhooks/safety_org_alert_created_webhook_event.rbi +130 -0
- data/rbi/openai/models/webhooks/unwrap_webhook_event.rbi +3 -1
- data/rbi/openai/models.rbi +2 -0
- data/rbi/openai/resources/admin/organization/projects/service_accounts/api_keys.rbi +3 -0
- data/rbi/openai/resources/admin/organization/usage.rbi +1 -1
- data/rbi/openai/resources/audio/speech.rbi +1 -1
- data/rbi/openai/resources/beta/responses.rbi +10 -9
- data/rbi/openai/resources/chat/completions.rbi +2 -2
- data/rbi/openai/resources/containers/files/content.rbi +1 -1
- data/rbi/openai/resources/conversations/items.rbi +1 -0
- data/rbi/openai/resources/conversations.rbi +1 -0
- data/rbi/openai/resources/files.rbi +5 -1
- data/rbi/openai/resources/responses.rbi +155 -9
- data/rbi/openai/resources/safety/alerts.rbi +30 -0
- data/rbi/openai/resources/safety.rbi +18 -0
- data/rbi/openai/resources/skills/content.rbi +5 -1
- data/rbi/openai/resources/skills/versions/content.rbi +3 -1
- data/rbi/openai/resources/videos.rbi +1 -1
- data/rbi/openai/resources/webhooks.rbi +3 -1
- data/rbi/openai/response_carrier.rbi +25 -0
- data/sig/openai/auth/subject_token_providers.rbs +42 -0
- data/sig/openai/client.rbs +2 -0
- data/sig/openai/errors.rbs +36 -2
- data/sig/openai/file_part.rbs +3 -0
- data/sig/openai/helpers/realtime/extensions.rbs +2 -2
- data/sig/openai/helpers/responses_websocket/connection.rbs +48 -0
- data/sig/openai/helpers/responses_websocket/connection_manager.rbs +19 -0
- data/sig/openai/helpers/responses_websocket/connection_resources.rbs +12 -0
- data/sig/openai/helpers/responses_websocket/extensions.rbs +55 -0
- data/sig/openai/helpers/responses_websocket/transports/async_websocket.rbs +19 -0
- data/sig/openai/helpers/responses_websocket/unknown_server_event.rbs +15 -0
- data/sig/openai/helpers/streaming/exceptions.rbs +24 -0
- data/sig/openai/helpers/streaming/response_stream.rbs +103 -0
- data/sig/openai/helpers/structured_output/response_parser.rbs +10 -0
- data/sig/openai/helpers/websocket.rbs +18 -0
- data/sig/openai/internal/transport/base_client.rbs +5 -0
- data/sig/openai/internal/type/base_stream.rbs +2 -0
- data/sig/openai/internal/type/request_parameters.rbs +1 -1
- data/sig/openai/internal/util.rbs +1 -0
- data/sig/openai/models/admin/organization/admin_api_key.rbs +18 -18
- data/sig/openai/models/admin/organization/admin_api_key_create_params.rbs +7 -4
- data/sig/openai/models/admin/organization/admin_api_key_create_response.rbs +6 -6
- data/sig/openai/models/admin/organization/admin_api_key_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/admin_api_key_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/admin_api_key_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/admin_api_key_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/audit_log_list_params.rbs +27 -27
- data/sig/openai/models/admin/organization/audit_log_list_response.rbs +428 -423
- data/sig/openai/models/admin/organization/certificate.rbs +6 -6
- data/sig/openai/models/admin/organization/certificate_activate_params.rbs +5 -3
- data/sig/openai/models/admin/organization/certificate_activate_response.rbs +5 -4
- data/sig/openai/models/admin/organization/certificate_create_params.rbs +7 -4
- data/sig/openai/models/admin/organization/certificate_deactivate_params.rbs +5 -3
- data/sig/openai/models/admin/organization/certificate_deactivate_response.rbs +5 -4
- data/sig/openai/models/admin/organization/certificate_delete_params.rbs +2 -3
- data/sig/openai/models/admin/organization/certificate_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/certificate_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/certificate_list_response.rbs +5 -4
- data/sig/openai/models/admin/organization/certificate_retrieve_params.rbs +4 -4
- data/sig/openai/models/admin/organization/certificate_update_params.rbs +7 -4
- data/sig/openai/models/admin/organization/data_retention_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/data_retention_update_params.rbs +3 -3
- data/sig/openai/models/admin/organization/group_create_params.rbs +2 -2
- data/sig/openai/models/admin/organization/group_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/group_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/group_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/group_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/group_update_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/role_create_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/role_create_response.rbs +4 -4
- data/sig/openai/models/admin/organization/groups/role_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/groups/role_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/user_create_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/user_create_response.rbs +2 -2
- data/sig/openai/models/admin/organization/groups/user_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/groups/user_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/groups/user_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/groups/user_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/invite.rbs +6 -6
- data/sig/openai/models/admin/organization/invite_create_params.rbs +4 -4
- data/sig/openai/models/admin/organization/invite_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/invite_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/invite_list_params.rbs +8 -5
- data/sig/openai/models/admin/organization/invite_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/organization_data_retention.rbs +2 -2
- data/sig/openai/models/admin/organization/organization_spend_alert.rbs +6 -6
- data/sig/openai/models/admin/organization/organization_spend_alert_deleted.rbs +2 -2
- data/sig/openai/models/admin/organization/organization_spend_limit.rbs +2 -2
- data/sig/openai/models/admin/organization/organization_spend_limit_deleted.rbs +2 -2
- data/sig/openai/models/admin/organization/organization_user.rbs +46 -46
- data/sig/openai/models/admin/organization/project.rbs +12 -12
- data/sig/openai/models/admin/organization/project_archive_params.rbs +2 -2
- data/sig/openai/models/admin/organization/project_create_params.rbs +8 -8
- data/sig/openai/models/admin/organization/project_list_params.rbs +10 -6
- data/sig/openai/models/admin/organization/project_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/project_update_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/api_key_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/api_key_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/api_key_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/api_key_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/certificate_activate_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/certificate_activate_response.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/certificate_deactivate_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/certificate_deactivate_response.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/certificate_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/certificate_list_response.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/data_retention_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/data_retention_update_params.rbs +3 -3
- data/sig/openai/models/admin/organization/projects/group_create_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/group_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/group_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/group_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/group_retrieve_params.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/groups/role_create_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/groups/role_create_response.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/groups/role_delete_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/groups/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/groups/role_retrieve_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/hosted_tool_permission_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/hosted_tool_permission_update_params.rbs +12 -12
- data/sig/openai/models/admin/organization/projects/model_permission_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/model_permission_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/model_permission_update_params.rbs +3 -3
- data/sig/openai/models/admin/organization/projects/project_api_key.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/project_data_retention.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_group.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_model_permissions.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_model_permissions_deleted.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_rate_limit.rbs +10 -10
- data/sig/openai/models/admin/organization/projects/project_service_account.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_spend_alert.rbs +6 -6
- data/sig/openai/models/admin/organization/projects/project_spend_alert_deleted.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_spend_limit.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_spend_limit_deleted.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/project_user.rbs +6 -6
- data/sig/openai/models/admin/organization/projects/rate_limit_list_rate_limits_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/rate_limit_update_rate_limit_params.rbs +14 -14
- data/sig/openai/models/admin/organization/projects/role_create_params.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/role_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/role_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/role_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/role_update_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/service_account_create_params.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/service_account_create_response.rbs +4 -4
- data/sig/openai/models/admin/organization/projects/service_account_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/service_account_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/service_account_list_params.rbs +9 -5
- data/sig/openai/models/admin/organization/projects/service_account_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/service_account_update_params.rbs +6 -6
- data/sig/openai/models/admin/organization/projects/service_accounts/api_key_create_params.rbs +11 -6
- data/sig/openai/models/admin/organization/projects/service_accounts/api_key_create_response.rbs +9 -4
- data/sig/openai/models/admin/organization/projects/spend_alert_create_params.rbs +7 -7
- data/sig/openai/models/admin/organization/projects/spend_alert_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/spend_alert_list_params.rbs +10 -10
- data/sig/openai/models/admin/organization/projects/spend_alert_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/spend_alert_update_params.rbs +7 -7
- data/sig/openai/models/admin/organization/projects/spend_limit_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/spend_limit_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/spend_limit_update_params.rbs +3 -3
- data/sig/openai/models/admin/organization/projects/user_create_params.rbs +6 -6
- data/sig/openai/models/admin/organization/projects/user_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/user_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/user_list_params.rbs +9 -5
- data/sig/openai/models/admin/organization/projects/user_retrieve_params.rbs +6 -3
- data/sig/openai/models/admin/organization/projects/user_update_params.rbs +8 -4
- data/sig/openai/models/admin/organization/projects/users/role_create_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/users/role_create_response.rbs +2 -2
- data/sig/openai/models/admin/organization/projects/users/role_delete_params.rbs +7 -3
- data/sig/openai/models/admin/organization/projects/users/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/projects/users/role_retrieve_params.rbs +7 -3
- data/sig/openai/models/admin/organization/role.rbs +2 -2
- data/sig/openai/models/admin/organization/role_create_params.rbs +4 -4
- data/sig/openai/models/admin/organization/role_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/role_delete_response.rbs +6 -2
- data/sig/openai/models/admin/organization/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/role_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/role_update_params.rbs +8 -8
- data/sig/openai/models/admin/organization/spend_alert_create_params.rbs +7 -7
- data/sig/openai/models/admin/organization/spend_alert_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/spend_alert_list_params.rbs +10 -10
- data/sig/openai/models/admin/organization/spend_alert_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/spend_alert_update_params.rbs +7 -7
- data/sig/openai/models/admin/organization/spend_limit_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/spend_limit_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/spend_limit_update_params.rbs +3 -3
- data/sig/openai/models/admin/organization/usage_audio_speeches_params.rbs +20 -20
- data/sig/openai/models/admin/organization/usage_audio_speeches_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_audio_transcriptions_params.rbs +20 -20
- data/sig/openai/models/admin/organization/usage_audio_transcriptions_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_code_interpreter_sessions_params.rbs +14 -14
- data/sig/openai/models/admin/organization/usage_code_interpreter_sessions_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_completions_params.rbs +22 -22
- data/sig/openai/models/admin/organization/usage_completions_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_costs_params.rbs +18 -18
- data/sig/openai/models/admin/organization/usage_costs_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_embeddings_params.rbs +20 -20
- data/sig/openai/models/admin/organization/usage_embeddings_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_file_search_calls_params.rbs +20 -20
- data/sig/openai/models/admin/organization/usage_file_search_calls_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_images_params.rbs +24 -24
- data/sig/openai/models/admin/organization/usage_images_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_moderations_params.rbs +20 -20
- data/sig/openai/models/admin/organization/usage_moderations_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_vector_stores_params.rbs +14 -14
- data/sig/openai/models/admin/organization/usage_vector_stores_response.rbs +142 -142
- data/sig/openai/models/admin/organization/usage_web_search_calls_params.rbs +22 -22
- data/sig/openai/models/admin/organization/usage_web_search_calls_response.rbs +142 -142
- data/sig/openai/models/admin/organization/user_delete_params.rbs +2 -2
- data/sig/openai/models/admin/organization/user_delete_response.rbs +2 -2
- data/sig/openai/models/admin/organization/user_list_params.rbs +10 -6
- data/sig/openai/models/admin/organization/user_retrieve_params.rbs +2 -2
- data/sig/openai/models/admin/organization/user_update_params.rbs +10 -10
- data/sig/openai/models/admin/organization/users/role_create_params.rbs +6 -3
- data/sig/openai/models/admin/organization/users/role_create_response.rbs +2 -2
- data/sig/openai/models/admin/organization/users/role_delete_params.rbs +6 -3
- data/sig/openai/models/admin/organization/users/role_list_params.rbs +8 -8
- data/sig/openai/models/admin/organization/users/role_retrieve_params.rbs +6 -3
- data/sig/openai/models/audio/speech_create_params.rbs +10 -10
- data/sig/openai/models/audio/transcription.rbs +19 -18
- data/sig/openai/models/audio/transcription_create_params.rbs +30 -30
- data/sig/openai/models/audio/transcription_diarized.rbs +12 -12
- data/sig/openai/models/audio/transcription_diarized_segment.rbs +2 -2
- data/sig/openai/models/audio/transcription_text_delta_event.rbs +10 -10
- data/sig/openai/models/audio/transcription_text_done_event.rbs +18 -18
- data/sig/openai/models/audio/transcription_text_segment_event.rbs +2 -2
- data/sig/openai/models/audio/transcription_verbose.rbs +8 -8
- data/sig/openai/models/audio/translation_create_params.rbs +8 -8
- data/sig/openai/models/audio/translation_verbose.rbs +2 -2
- data/sig/openai/models/auto_file_chunking_strategy_param.rbs +2 -2
- data/sig/openai/models/batch.rbs +34 -34
- data/sig/openai/models/batch_cancel_params.rbs +2 -2
- data/sig/openai/models/batch_create_params.rbs +8 -8
- data/sig/openai/models/batch_error.rbs +5 -5
- data/sig/openai/models/batch_list_params.rbs +8 -5
- data/sig/openai/models/batch_retrieve_params.rbs +2 -2
- data/sig/openai/models/beta/assistant.rbs +18 -18
- data/sig/openai/models/beta/assistant_create_params.rbs +42 -42
- data/sig/openai/models/beta/assistant_delete_params.rbs +2 -2
- data/sig/openai/models/beta/assistant_deleted.rbs +2 -2
- data/sig/openai/models/beta/assistant_list_params.rbs +10 -10
- data/sig/openai/models/beta/assistant_retrieve_params.rbs +2 -2
- data/sig/openai/models/beta/assistant_stream_event.rbs +53 -50
- data/sig/openai/models/beta/assistant_tool_choice.rbs +2 -2
- data/sig/openai/models/beta/assistant_update_params.rbs +32 -32
- data/sig/openai/models/beta/beta_apply_patch_tool.rbs +4 -4
- data/sig/openai/models/beta/beta_compacted_response.rbs +2 -2
- data/sig/openai/models/beta/beta_computer_action.rbs +25 -25
- data/sig/openai/models/beta/beta_computer_tool.rbs +2 -2
- data/sig/openai/models/beta/beta_computer_use_preview_tool.rbs +2 -2
- data/sig/openai/models/beta/beta_container_auto.rbs +10 -10
- data/sig/openai/models/beta/beta_container_network_policy_allowlist.rbs +4 -4
- data/sig/openai/models/beta/beta_container_network_policy_disabled.rbs +2 -2
- data/sig/openai/models/beta/beta_container_reference.rbs +2 -2
- data/sig/openai/models/beta/beta_custom_tool.rbs +21 -14
- data/sig/openai/models/beta/beta_easy_input_message.rbs +4 -4
- data/sig/openai/models/beta/beta_file_search_tool.rbs +14 -14
- data/sig/openai/models/beta/beta_function_shell_tool.rbs +6 -6
- data/sig/openai/models/beta/beta_function_tool.rbs +17 -10
- data/sig/openai/models/beta/beta_inline_skill.rbs +2 -2
- data/sig/openai/models/beta/beta_inline_skill_source.rbs +3 -3
- data/sig/openai/models/beta/beta_local_environment.rbs +3 -3
- data/sig/openai/models/beta/beta_mcp_tool_call_error.rbs +6 -6
- data/sig/openai/models/beta/beta_namespace_tool.rbs +23 -16
- data/sig/openai/models/beta/beta_response.rbs +191 -69
- data/sig/openai/models/beta/beta_response_apply_patch_tool_call.rbs +18 -18
- data/sig/openai/models/beta/beta_response_apply_patch_tool_call_output.rbs +14 -14
- data/sig/openai/models/beta/beta_response_audio_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_audio_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_audio_transcript_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_audio_transcript_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_call_code_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_call_code_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_call_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_call_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_call_interpreting_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_code_interpreter_tool_call.rbs +8 -8
- data/sig/openai/models/beta/beta_response_compaction_item.rbs +6 -6
- data/sig/openai/models/beta/beta_response_compaction_item_param.rbs +6 -6
- data/sig/openai/models/beta/beta_response_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_computer_tool_call.rbs +8 -8
- data/sig/openai/models/beta/beta_response_computer_tool_call_output_item.rbs +10 -10
- data/sig/openai/models/beta/beta_response_computer_tool_call_output_screenshot.rbs +4 -4
- data/sig/openai/models/beta/beta_response_configuration_update_item.rbs +91 -0
- data/sig/openai/models/beta/beta_response_configuration_update_item_param.rbs +87 -0
- data/sig/openai/models/beta/beta_response_container_reference.rbs +2 -2
- data/sig/openai/models/beta/beta_response_content.rbs +2 -2
- data/sig/openai/models/beta/beta_response_content_part_added_event.rbs +6 -6
- data/sig/openai/models/beta/beta_response_content_part_done_event.rbs +6 -6
- data/sig/openai/models/beta/beta_response_created_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_custom_tool_call.rbs +21 -14
- data/sig/openai/models/beta/beta_response_custom_tool_call_input_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_custom_tool_call_input_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_custom_tool_call_item.rbs +13 -10
- data/sig/openai/models/beta/beta_response_custom_tool_call_output.rbs +12 -12
- data/sig/openai/models/beta/beta_response_custom_tool_call_output_item.rbs +8 -8
- data/sig/openai/models/beta/beta_response_error.rbs +82 -3
- data/sig/openai/models/beta/beta_response_error_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_failed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_file_search_call_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_file_search_call_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_file_search_call_searching_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_file_search_tool_call.rbs +16 -16
- data/sig/openai/models/beta/beta_response_format_text_config.rbs +4 -4
- data/sig/openai/models/beta/beta_response_format_text_json_schema_config.rbs +6 -6
- data/sig/openai/models/beta/beta_response_function_call_arguments_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_function_call_arguments_done_event.rbs +4 -9
- data/sig/openai/models/beta/beta_response_function_shell_call_output_content.rbs +4 -4
- data/sig/openai/models/beta/beta_response_function_shell_tool_call.rbs +12 -12
- data/sig/openai/models/beta/beta_response_function_shell_tool_call_output.rbs +18 -18
- data/sig/openai/models/beta/beta_response_function_tool_call.rbs +23 -16
- data/sig/openai/models/beta/beta_response_function_tool_call_item.rbs +13 -10
- data/sig/openai/models/beta/beta_response_function_tool_call_output_item.rbs +18 -18
- data/sig/openai/models/beta/beta_response_function_web_search.rbs +21 -19
- data/sig/openai/models/beta/beta_response_image_gen_call_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_image_gen_call_generating_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_image_gen_call_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_image_gen_call_partial_image_event.rbs +12 -12
- data/sig/openai/models/beta/beta_response_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_incomplete_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_inject_created_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_inject_event.rbs +2 -2
- data/sig/openai/models/beta/beta_response_inject_failed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_input_audio.rbs +2 -2
- data/sig/openai/models/beta/beta_response_input_file.rbs +16 -16
- data/sig/openai/models/beta/beta_response_input_file_content.rbs +16 -16
- data/sig/openai/models/beta/beta_response_input_image.rbs +10 -10
- data/sig/openai/models/beta/beta_response_input_image_content.rbs +12 -12
- data/sig/openai/models/beta/beta_response_input_item.rbs +237 -228
- data/sig/openai/models/beta/beta_response_input_message_item.rbs +6 -6
- data/sig/openai/models/beta/beta_response_input_text.rbs +6 -6
- data/sig/openai/models/beta/beta_response_input_text_content.rbs +6 -6
- data/sig/openai/models/beta/beta_response_item.rbs +93 -92
- data/sig/openai/models/beta/beta_response_local_environment.rbs +2 -2
- data/sig/openai/models/beta/beta_response_mcp_call_arguments_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_call_arguments_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_call_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_call_failed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_call_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_list_tools_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_list_tools_failed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_mcp_list_tools_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_output_audio.rbs +2 -2
- data/sig/openai/models/beta/beta_response_output_item.rbs +92 -92
- data/sig/openai/models/beta/beta_response_output_item_added_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_output_item_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_output_message.rbs +8 -8
- data/sig/openai/models/beta/beta_response_output_refusal.rbs +2 -2
- data/sig/openai/models/beta/beta_response_output_text.rbs +13 -12
- data/sig/openai/models/beta/beta_response_output_text_annotation_added_event.rbs +13 -12
- data/sig/openai/models/beta/beta_response_prompt.rbs +4 -4
- data/sig/openai/models/beta/beta_response_queued_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_reasoning_item.rbs +14 -14
- data/sig/openai/models/beta/beta_response_reasoning_summary_part_added_event.rbs +6 -6
- data/sig/openai/models/beta/beta_response_reasoning_summary_part_done_event.rbs +8 -8
- data/sig/openai/models/beta/beta_response_reasoning_summary_text_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_reasoning_summary_text_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_reasoning_text_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_reasoning_text_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_refusal_delta_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_refusal_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_shell_call_command_added_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_shell_call_command_delta_event.rbs +6 -6
- data/sig/openai/models/beta/beta_response_shell_call_command_done_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_shell_call_output_content_delta_event.rbs +6 -6
- data/sig/openai/models/beta/beta_response_shell_call_output_content_done_event.rbs +10 -10
- data/sig/openai/models/beta/beta_response_steer_accepted_event.rbs +53 -0
- data/sig/openai/models/beta/beta_response_steer_error_code.rbs +31 -0
- data/sig/openai/models/beta/beta_response_steer_event.rbs +34 -0
- data/sig/openai/models/beta/beta_response_steer_failed_event.rbs +102 -0
- data/sig/openai/models/beta/beta_response_steer_input.rbs +214 -0
- data/sig/openai/models/beta/beta_response_steer_input_content.rbs +18 -0
- data/sig/openai/models/beta/beta_response_steer_pending_event.rbs +63 -0
- data/sig/openai/models/beta/beta_response_steer_pending_reason.rbs +16 -0
- data/sig/openai/models/beta/beta_response_steer_required_input.rbs +161 -0
- data/sig/openai/models/beta/beta_response_text_config.rbs +4 -4
- data/sig/openai/models/beta/beta_response_text_delta_event.rbs +8 -8
- data/sig/openai/models/beta/beta_response_text_done_event.rbs +8 -8
- data/sig/openai/models/beta/beta_response_tool_search_call.rbs +6 -6
- data/sig/openai/models/beta/beta_response_tool_search_output_item.rbs +6 -6
- data/sig/openai/models/beta/beta_response_tool_search_output_item_param.rbs +12 -12
- data/sig/openai/models/beta/beta_response_web_search_call_completed_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_web_search_call_in_progress_event.rbs +4 -4
- data/sig/openai/models/beta/beta_response_web_search_call_searching_event.rbs +4 -4
- data/sig/openai/models/beta/beta_responses_client_event.rbs +108 -97
- data/sig/openai/models/beta/beta_responses_server_event.rbs +444 -370
- data/sig/openai/models/beta/beta_skill_reference.rbs +3 -3
- data/sig/openai/models/beta/beta_tool.rbs +80 -74
- data/sig/openai/models/beta/beta_tool_choice_allowed.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_choice_apply_patch.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_choice_custom.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_choice_function.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_choice_mcp.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_choice_shell.rbs +2 -2
- data/sig/openai/models/beta/beta_tool_search_tool.rbs +8 -8
- data/sig/openai/models/beta/beta_web_search_preview_tool.rbs +16 -16
- data/sig/openai/models/beta/beta_web_search_tool.rbs +20 -20
- data/sig/openai/models/beta/chatkit/chat_session.rbs +2 -2
- data/sig/openai/models/beta/chatkit/chat_session_chatkit_configuration_param.rbs +14 -14
- data/sig/openai/models/beta/chatkit/chat_session_expires_after_param.rbs +2 -2
- data/sig/openai/models/beta/chatkit/chat_session_rate_limits_param.rbs +2 -2
- data/sig/openai/models/beta/chatkit/chat_session_workflow_param.rbs +8 -8
- data/sig/openai/models/beta/chatkit/chatkit_response_output_text.rbs +10 -10
- data/sig/openai/models/beta/chatkit/chatkit_thread.rbs +8 -8
- data/sig/openai/models/beta/chatkit/chatkit_thread_assistant_message_item.rbs +4 -4
- data/sig/openai/models/beta/chatkit/chatkit_thread_item_list.rbs +14 -14
- data/sig/openai/models/beta/chatkit/chatkit_thread_user_message_item.rbs +8 -8
- data/sig/openai/models/beta/chatkit/chatkit_widget_item.rbs +4 -4
- data/sig/openai/models/beta/chatkit/session_cancel_params.rbs +2 -2
- data/sig/openai/models/beta/chatkit/session_create_params.rbs +8 -8
- data/sig/openai/models/beta/chatkit/thread_delete_params.rbs +2 -2
- data/sig/openai/models/beta/chatkit/thread_delete_response.rbs +2 -2
- data/sig/openai/models/beta/chatkit/thread_list_items_params.rbs +10 -10
- data/sig/openai/models/beta/chatkit/thread_list_params.rbs +12 -12
- data/sig/openai/models/beta/chatkit/thread_retrieve_params.rbs +2 -2
- data/sig/openai/models/beta/code_interpreter_tool.rbs +2 -2
- data/sig/openai/models/beta/file_search_tool.rbs +10 -10
- data/sig/openai/models/beta/function_tool.rbs +2 -2
- data/sig/openai/models/beta/message_stream_event.rbs +10 -10
- data/sig/openai/models/beta/response_cancel_params.rbs +4 -4
- data/sig/openai/models/beta/response_compact_params.rbs +25 -23
- data/sig/openai/models/beta/response_create_params.rbs +102 -95
- data/sig/openai/models/beta/response_delete_params.rbs +4 -4
- data/sig/openai/models/beta/response_retrieve_params.rbs +10 -10
- data/sig/openai/models/beta/responses/beta_response_item_list.rbs +2 -2
- data/sig/openai/models/beta/responses/input_item_list_params.rbs +12 -12
- data/sig/openai/models/beta/responses/input_token_count_params.rbs +44 -44
- data/sig/openai/models/beta/responses/input_token_count_response.rbs +2 -2
- data/sig/openai/models/beta/run_step_stream_event.rbs +14 -14
- data/sig/openai/models/beta/run_stream_event.rbs +23 -20
- data/sig/openai/models/beta/thread.rbs +10 -10
- data/sig/openai/models/beta/thread_create_and_run_params.rbs +76 -76
- data/sig/openai/models/beta/thread_create_params.rbs +38 -38
- data/sig/openai/models/beta/thread_delete_params.rbs +2 -2
- data/sig/openai/models/beta/thread_deleted.rbs +6 -2
- data/sig/openai/models/beta/thread_retrieve_params.rbs +2 -2
- data/sig/openai/models/beta/thread_stream_event.rbs +7 -3
- data/sig/openai/models/beta/thread_update_params.rbs +14 -14
- data/sig/openai/models/beta/threads/file_citation_annotation.rbs +2 -2
- data/sig/openai/models/beta/threads/file_citation_delta_annotation.rbs +12 -12
- data/sig/openai/models/beta/threads/file_path_annotation.rbs +2 -2
- data/sig/openai/models/beta/threads/file_path_delta_annotation.rbs +12 -12
- data/sig/openai/models/beta/threads/image_file.rbs +2 -2
- data/sig/openai/models/beta/threads/image_file_content_block.rbs +2 -2
- data/sig/openai/models/beta/threads/image_file_delta.rbs +4 -4
- data/sig/openai/models/beta/threads/image_file_delta_block.rbs +4 -4
- data/sig/openai/models/beta/threads/image_url.rbs +2 -2
- data/sig/openai/models/beta/threads/image_url_content_block.rbs +2 -2
- data/sig/openai/models/beta/threads/image_url_delta.rbs +4 -4
- data/sig/openai/models/beta/threads/image_url_delta_block.rbs +4 -4
- data/sig/openai/models/beta/threads/message.rbs +8 -8
- data/sig/openai/models/beta/threads/message_create_params.rbs +12 -12
- data/sig/openai/models/beta/threads/message_delete_params.rbs +6 -3
- data/sig/openai/models/beta/threads/message_deleted.rbs +2 -2
- data/sig/openai/models/beta/threads/message_delta.rbs +4 -4
- data/sig/openai/models/beta/threads/message_delta_event.rbs +2 -2
- data/sig/openai/models/beta/threads/message_list_params.rbs +12 -12
- data/sig/openai/models/beta/threads/message_retrieve_params.rbs +6 -3
- data/sig/openai/models/beta/threads/message_update_params.rbs +4 -4
- data/sig/openai/models/beta/threads/refusal_content_block.rbs +2 -2
- data/sig/openai/models/beta/threads/refusal_delta_block.rbs +2 -2
- data/sig/openai/models/beta/threads/required_action_function_tool_call.rbs +2 -2
- data/sig/openai/models/beta/threads/run.rbs +12 -12
- data/sig/openai/models/beta/threads/run_cancel_params.rbs +6 -3
- data/sig/openai/models/beta/threads/run_create_params.rbs +46 -46
- data/sig/openai/models/beta/threads/run_list_params.rbs +10 -10
- data/sig/openai/models/beta/threads/run_retrieve_params.rbs +6 -3
- data/sig/openai/models/beta/threads/run_submit_tool_outputs_params.rbs +5 -5
- data/sig/openai/models/beta/threads/run_update_params.rbs +4 -4
- data/sig/openai/models/beta/threads/runs/code_interpreter_logs.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/code_interpreter_output_image.rbs +6 -6
- data/sig/openai/models/beta/threads/runs/code_interpreter_tool_call.rbs +6 -6
- data/sig/openai/models/beta/threads/runs/code_interpreter_tool_call_delta.rbs +10 -10
- data/sig/openai/models/beta/threads/runs/file_search_tool_call.rbs +12 -12
- data/sig/openai/models/beta/threads/runs/file_search_tool_call_delta.rbs +8 -3
- data/sig/openai/models/beta/threads/runs/function_tool_call.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/function_tool_call_delta.rbs +11 -10
- data/sig/openai/models/beta/threads/runs/message_creation_step_details.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/run_step.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/run_step_delta.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/run_step_delta_event.rbs +2 -2
- data/sig/openai/models/beta/threads/runs/run_step_delta_message_delta.rbs +6 -6
- data/sig/openai/models/beta/threads/runs/step_list_params.rbs +12 -12
- data/sig/openai/models/beta/threads/runs/step_retrieve_params.rbs +4 -4
- data/sig/openai/models/beta/threads/runs/tool_call_delta_object.rbs +4 -4
- data/sig/openai/models/beta/threads/runs/tool_calls_step_details.rbs +2 -2
- data/sig/openai/models/beta/threads/text_content_block.rbs +2 -2
- data/sig/openai/models/beta/threads/text_content_block_param.rbs +2 -2
- data/sig/openai/models/beta/threads/text_delta.rbs +4 -4
- data/sig/openai/models/beta/threads/text_delta_block.rbs +4 -4
- data/sig/openai/models/chat/chat_completion.rbs +24 -24
- data/sig/openai/models/chat/chat_completion_allowed_tool_choice.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_assistant_message_param.rbs +14 -14
- data/sig/openai/models/chat/chat_completion_chunk.rbs +46 -46
- data/sig/openai/models/chat/chat_completion_content_part.rbs +11 -10
- data/sig/openai/models/chat/chat_completion_content_part_image.rbs +8 -8
- data/sig/openai/models/chat/chat_completion_content_part_input_audio.rbs +6 -6
- data/sig/openai/models/chat/chat_completion_content_part_refusal.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_content_part_text.rbs +6 -6
- data/sig/openai/models/chat/chat_completion_custom_tool.rbs +10 -10
- data/sig/openai/models/chat/chat_completion_deleted.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_developer_message_param.rbs +4 -4
- data/sig/openai/models/chat/chat_completion_function_message_param.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_function_tool.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_message.rbs +12 -12
- data/sig/openai/models/chat/chat_completion_message_custom_tool_call.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_message_function_tool_call.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_named_tool_choice.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_named_tool_choice_custom.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_prediction_content.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_store_message.rbs +12 -12
- data/sig/openai/models/chat/chat_completion_stream_options.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_system_message_param.rbs +4 -4
- data/sig/openai/models/chat/chat_completion_tool_message_param.rbs +2 -2
- data/sig/openai/models/chat/chat_completion_user_message_param.rbs +4 -4
- data/sig/openai/models/chat/completion_create_params.rbs +98 -98
- data/sig/openai/models/chat/completion_delete_params.rbs +2 -2
- data/sig/openai/models/chat/completion_list_params.rbs +12 -12
- data/sig/openai/models/chat/completion_retrieve_params.rbs +2 -2
- data/sig/openai/models/chat/completion_update_params.rbs +6 -3
- data/sig/openai/models/chat/completions/message_list_params.rbs +8 -8
- data/sig/openai/models/chat_model.rbs +3 -1
- data/sig/openai/models/completion.rbs +6 -6
- data/sig/openai/models/completion_choice.rbs +8 -8
- data/sig/openai/models/completion_create_params.rbs +32 -32
- data/sig/openai/models/completion_usage.rbs +24 -24
- data/sig/openai/models/container_create_params.rbs +12 -12
- data/sig/openai/models/container_create_response.rbs +14 -14
- data/sig/openai/models/container_delete_params.rbs +2 -2
- data/sig/openai/models/container_list_params.rbs +10 -10
- data/sig/openai/models/container_list_response.rbs +14 -14
- data/sig/openai/models/container_retrieve_params.rbs +2 -2
- data/sig/openai/models/container_retrieve_response.rbs +14 -14
- data/sig/openai/models/containers/file_create_params.rbs +6 -6
- data/sig/openai/models/containers/file_create_response.rbs +2 -2
- data/sig/openai/models/containers/file_delete_params.rbs +6 -3
- data/sig/openai/models/containers/file_list_params.rbs +8 -8
- data/sig/openai/models/containers/file_list_response.rbs +2 -2
- data/sig/openai/models/containers/file_retrieve_params.rbs +6 -3
- data/sig/openai/models/containers/file_retrieve_response.rbs +2 -2
- data/sig/openai/models/containers/files/content_retrieve_params.rbs +6 -3
- data/sig/openai/models/content_provenance_check.rbs +4 -4
- data/sig/openai/models/content_provenance_check_create_params.rbs +5 -3
- data/sig/openai/models/conversations/computer_screenshot_content.rbs +6 -6
- data/sig/openai/models/conversations/conversation.rbs +2 -2
- data/sig/openai/models/conversations/conversation_create_params.rbs +6 -6
- data/sig/openai/models/conversations/conversation_delete_params.rbs +2 -2
- data/sig/openai/models/conversations/conversation_deleted.rbs +2 -2
- data/sig/openai/models/conversations/conversation_deleted_resource.rbs +2 -2
- data/sig/openai/models/conversations/conversation_item.rbs +47 -46
- data/sig/openai/models/conversations/conversation_item_list.rbs +2 -2
- data/sig/openai/models/conversations/conversation_retrieve_params.rbs +2 -2
- data/sig/openai/models/conversations/conversation_update_params.rbs +6 -3
- data/sig/openai/models/conversations/item_create_params.rbs +4 -4
- data/sig/openai/models/conversations/item_delete_params.rbs +6 -3
- data/sig/openai/models/conversations/item_list_params.rbs +10 -10
- data/sig/openai/models/conversations/item_retrieve_params.rbs +4 -4
- data/sig/openai/models/conversations/message.rbs +6 -6
- data/sig/openai/models/conversations/summary_text_content.rbs +2 -2
- data/sig/openai/models/conversations/text_content.rbs +2 -2
- data/sig/openai/models/create_embedding_response.rbs +2 -2
- data/sig/openai/models/custom_tool_input_format.rbs +4 -4
- data/sig/openai/models/deleted_skill.rbs +3 -2
- data/sig/openai/models/embedding.rbs +2 -2
- data/sig/openai/models/embedding_create_params.rbs +8 -8
- data/sig/openai/models/error_object.rbs +82 -3
- data/sig/openai/models/eval_create_params.rbs +40 -40
- data/sig/openai/models/eval_create_response.rbs +22 -22
- data/sig/openai/models/eval_custom_data_source_config.rbs +2 -2
- data/sig/openai/models/eval_delete_params.rbs +2 -2
- data/sig/openai/models/eval_list_params.rbs +10 -10
- data/sig/openai/models/eval_list_response.rbs +22 -22
- data/sig/openai/models/eval_retrieve_params.rbs +2 -2
- data/sig/openai/models/eval_retrieve_response.rbs +22 -22
- data/sig/openai/models/eval_stored_completions_data_source_config.rbs +4 -4
- data/sig/openai/models/eval_update_params.rbs +9 -5
- data/sig/openai/models/eval_update_response.rbs +22 -22
- data/sig/openai/models/evals/create_eval_completions_run_data_source.rbs +49 -49
- data/sig/openai/models/evals/create_eval_jsonl_run_data_source.rbs +8 -8
- data/sig/openai/models/evals/run_cancel_params.rbs +6 -3
- data/sig/openai/models/evals/run_cancel_response.rbs +66 -66
- data/sig/openai/models/evals/run_create_params.rbs +68 -68
- data/sig/openai/models/evals/run_create_response.rbs +66 -66
- data/sig/openai/models/evals/run_delete_params.rbs +6 -3
- data/sig/openai/models/evals/run_delete_response.rbs +2 -2
- data/sig/openai/models/evals/run_list_params.rbs +10 -10
- data/sig/openai/models/evals/run_list_response.rbs +66 -66
- data/sig/openai/models/evals/run_retrieve_params.rbs +6 -3
- data/sig/openai/models/evals/run_retrieve_response.rbs +66 -66
- data/sig/openai/models/evals/runs/output_item_list_params.rbs +10 -10
- data/sig/openai/models/evals/runs/output_item_list_response.rbs +8 -8
- data/sig/openai/models/evals/runs/output_item_retrieve_params.rbs +7 -3
- data/sig/openai/models/evals/runs/output_item_retrieve_response.rbs +8 -8
- data/sig/openai/models/file_content_params.rbs +2 -2
- data/sig/openai/models/file_create_params.rbs +6 -6
- data/sig/openai/models/file_delete_params.rbs +2 -2
- data/sig/openai/models/file_deleted.rbs +2 -2
- data/sig/openai/models/file_list_params.rbs +10 -10
- data/sig/openai/models/file_object.rbs +6 -6
- data/sig/openai/models/file_retrieve_params.rbs +2 -2
- data/sig/openai/models/fine_tuning/alpha/grader_run_params.rbs +4 -4
- data/sig/openai/models/fine_tuning/alpha/grader_validate_params.rbs +3 -3
- data/sig/openai/models/fine_tuning/alpha/grader_validate_response.rbs +2 -2
- data/sig/openai/models/fine_tuning/checkpoints/permission_create_params.rbs +6 -3
- data/sig/openai/models/fine_tuning/checkpoints/permission_create_response.rbs +2 -2
- data/sig/openai/models/fine_tuning/checkpoints/permission_delete_params.rbs +6 -3
- data/sig/openai/models/fine_tuning/checkpoints/permission_delete_response.rbs +2 -2
- data/sig/openai/models/fine_tuning/checkpoints/permission_list_params.rbs +10 -10
- data/sig/openai/models/fine_tuning/checkpoints/permission_list_response.rbs +2 -2
- data/sig/openai/models/fine_tuning/checkpoints/permission_retrieve_params.rbs +10 -10
- data/sig/openai/models/fine_tuning/checkpoints/permission_retrieve_response.rbs +8 -8
- data/sig/openai/models/fine_tuning/dpo_hyperparameters.rbs +8 -8
- data/sig/openai/models/fine_tuning/dpo_method.rbs +2 -2
- data/sig/openai/models/fine_tuning/fine_tuning_job.rbs +22 -22
- data/sig/openai/models/fine_tuning/fine_tuning_job_event.rbs +6 -6
- data/sig/openai/models/fine_tuning/fine_tuning_job_wandb_integration.rbs +6 -6
- data/sig/openai/models/fine_tuning/fine_tuning_job_wandb_integration_object.rbs +2 -2
- data/sig/openai/models/fine_tuning/job_cancel_params.rbs +2 -3
- data/sig/openai/models/fine_tuning/job_create_params.rbs +36 -36
- data/sig/openai/models/fine_tuning/job_list_events_params.rbs +9 -5
- data/sig/openai/models/fine_tuning/job_list_params.rbs +10 -6
- data/sig/openai/models/fine_tuning/job_pause_params.rbs +2 -3
- data/sig/openai/models/fine_tuning/job_resume_params.rbs +2 -3
- data/sig/openai/models/fine_tuning/job_retrieve_params.rbs +2 -3
- data/sig/openai/models/fine_tuning/jobs/checkpoint_list_params.rbs +9 -5
- data/sig/openai/models/fine_tuning/jobs/fine_tuning_job_checkpoint.rbs +16 -16
- data/sig/openai/models/fine_tuning/reinforcement_hyperparameters.rbs +14 -14
- data/sig/openai/models/fine_tuning/reinforcement_method.rbs +2 -2
- data/sig/openai/models/fine_tuning/supervised_hyperparameters.rbs +6 -6
- data/sig/openai/models/fine_tuning/supervised_method.rbs +2 -2
- data/sig/openai/models/function_definition.rbs +6 -6
- data/sig/openai/models/graders/grader_input_item.rbs +5 -5
- data/sig/openai/models/graders/label_model_grader.rbs +9 -9
- data/sig/openai/models/graders/multi_grader.rbs +2 -2
- data/sig/openai/models/graders/python_grader.rbs +3 -3
- data/sig/openai/models/graders/score_model_grader.rbs +23 -23
- data/sig/openai/models/graders/string_check_grader.rbs +2 -2
- data/sig/openai/models/graders/text_similarity_grader.rbs +2 -2
- data/sig/openai/models/image.rbs +4 -4
- data/sig/openai/models/image_create_variation_params.rbs +12 -12
- data/sig/openai/models/image_edit_completed_event.rbs +2 -2
- data/sig/openai/models/image_edit_params.rbs +26 -26
- data/sig/openai/models/image_edit_partial_image_event.rbs +2 -2
- data/sig/openai/models/image_gen_completed_event.rbs +2 -2
- data/sig/openai/models/image_gen_partial_image_event.rbs +2 -2
- data/sig/openai/models/image_generate_params.rbs +26 -26
- data/sig/openai/models/image_input_reference_param.rbs +2 -2
- data/sig/openai/models/images_response.rbs +14 -14
- data/sig/openai/models/model.rbs +4 -4
- data/sig/openai/models/model_delete_params.rbs +5 -2
- data/sig/openai/models/model_list_params.rbs +2 -2
- data/sig/openai/models/model_retrieve_params.rbs +5 -2
- data/sig/openai/models/moderation_create_params.rbs +4 -4
- data/sig/openai/models/moderation_image_url_input.rbs +5 -2
- data/sig/openai/models/moderation_text_input.rbs +2 -2
- data/sig/openai/models/other_file_chunking_strategy_object.rbs +2 -2
- data/sig/openai/models/realtime/audio_transcription.rbs +12 -12
- data/sig/openai/models/realtime/call_accept_params.rbs +30 -30
- data/sig/openai/models/realtime/call_create_params.rbs +7 -4
- data/sig/openai/models/realtime/call_hangup_params.rbs +2 -2
- data/sig/openai/models/realtime/call_refer_params.rbs +6 -3
- data/sig/openai/models/realtime/call_reject_params.rbs +7 -4
- data/sig/openai/models/realtime/client_secret_create_params.rbs +10 -10
- data/sig/openai/models/realtime/conversation_created_event.rbs +6 -6
- data/sig/openai/models/realtime/conversation_item_added.rbs +4 -4
- data/sig/openai/models/realtime/conversation_item_create_event.rbs +6 -6
- data/sig/openai/models/realtime/conversation_item_created_event.rbs +4 -4
- data/sig/openai/models/realtime/conversation_item_delete_event.rbs +7 -3
- data/sig/openai/models/realtime/conversation_item_deleted_event.rbs +2 -2
- data/sig/openai/models/realtime/conversation_item_done.rbs +4 -4
- data/sig/openai/models/realtime/conversation_item_input_audio_transcription_completed_event.rbs +14 -14
- data/sig/openai/models/realtime/conversation_item_input_audio_transcription_delta_event.rbs +8 -8
- data/sig/openai/models/realtime/conversation_item_input_audio_transcription_failed_event.rbs +7 -7
- data/sig/openai/models/realtime/conversation_item_input_audio_transcription_segment.rbs +2 -2
- data/sig/openai/models/realtime/conversation_item_retrieve_event.rbs +4 -4
- data/sig/openai/models/realtime/conversation_item_truncate_event.rbs +4 -4
- data/sig/openai/models/realtime/conversation_item_truncated_event.rbs +2 -2
- data/sig/openai/models/realtime/conversation_item_with_reference.rbs +30 -30
- data/sig/openai/models/realtime/input_audio_buffer_append_event.rbs +7 -3
- data/sig/openai/models/realtime/input_audio_buffer_clear_event.rbs +5 -2
- data/sig/openai/models/realtime/input_audio_buffer_cleared_event.rbs +2 -2
- data/sig/openai/models/realtime/input_audio_buffer_commit_event.rbs +5 -2
- data/sig/openai/models/realtime/input_audio_buffer_committed_event.rbs +4 -4
- data/sig/openai/models/realtime/input_audio_buffer_dtmf_event_received_event.rbs +2 -2
- data/sig/openai/models/realtime/input_audio_buffer_speech_started_event.rbs +2 -2
- data/sig/openai/models/realtime/input_audio_buffer_speech_stopped_event.rbs +2 -2
- data/sig/openai/models/realtime/input_audio_buffer_timeout_triggered.rbs +2 -2
- data/sig/openai/models/realtime/mcp_list_tools_completed.rbs +6 -2
- data/sig/openai/models/realtime/mcp_list_tools_failed.rbs +2 -2
- data/sig/openai/models/realtime/mcp_list_tools_in_progress.rbs +2 -2
- data/sig/openai/models/realtime/output_audio_buffer_clear_event.rbs +5 -2
- data/sig/openai/models/realtime/rate_limits_updated_event.rbs +10 -10
- data/sig/openai/models/realtime/realtime_audio_config.rbs +4 -4
- data/sig/openai/models/realtime/realtime_audio_config_input.rbs +10 -10
- data/sig/openai/models/realtime/realtime_audio_config_output.rbs +6 -6
- data/sig/openai/models/realtime/realtime_audio_formats.rbs +8 -8
- data/sig/openai/models/realtime/realtime_audio_input_turn_detection.rbs +22 -22
- data/sig/openai/models/realtime/realtime_conversation_item_assistant_message.rbs +18 -18
- data/sig/openai/models/realtime/realtime_conversation_item_function_call.rbs +10 -10
- data/sig/openai/models/realtime/realtime_conversation_item_function_call_output.rbs +8 -8
- data/sig/openai/models/realtime/realtime_conversation_item_system_message.rbs +14 -14
- data/sig/openai/models/realtime/realtime_conversation_item_user_message.rbs +22 -22
- data/sig/openai/models/realtime/realtime_error.rbs +6 -6
- data/sig/openai/models/realtime/realtime_error_event.rbs +2 -2
- data/sig/openai/models/realtime/realtime_function_tool.rbs +8 -8
- data/sig/openai/models/realtime/realtime_mcp_approval_request.rbs +2 -2
- data/sig/openai/models/realtime/realtime_mcp_approval_response.rbs +4 -4
- data/sig/openai/models/realtime/realtime_mcp_list_tools.rbs +8 -8
- data/sig/openai/models/realtime/realtime_mcp_protocol_error.rbs +2 -2
- data/sig/openai/models/realtime/realtime_mcp_tool_call.rbs +8 -8
- data/sig/openai/models/realtime/realtime_mcp_tool_execution_error.rbs +2 -2
- data/sig/openai/models/realtime/realtime_mcphttp_error.rbs +2 -2
- data/sig/openai/models/realtime/realtime_reasoning.rbs +2 -2
- data/sig/openai/models/realtime/realtime_response.rbs +28 -28
- data/sig/openai/models/realtime/realtime_response_create_audio_output.rbs +6 -6
- data/sig/openai/models/realtime/realtime_response_create_mcp_tool.rbs +32 -32
- data/sig/openai/models/realtime/realtime_response_create_params.rbs +24 -24
- data/sig/openai/models/realtime/realtime_response_status.rbs +8 -8
- data/sig/openai/models/realtime/realtime_response_usage.rbs +10 -10
- data/sig/openai/models/realtime/realtime_response_usage_input_token_details.rbs +18 -14
- data/sig/openai/models/realtime/realtime_response_usage_output_token_details.rbs +2 -2
- data/sig/openai/models/realtime/realtime_server_event.rbs +8 -8
- data/sig/openai/models/realtime/realtime_session.rbs +68 -68
- data/sig/openai/models/realtime/realtime_session_create_request.rbs +28 -28
- data/sig/openai/models/realtime/realtime_session_create_response.rbs +113 -110
- data/sig/openai/models/realtime/realtime_tools_config_union.rbs +38 -32
- data/sig/openai/models/realtime/realtime_tracing_config.rbs +4 -4
- data/sig/openai/models/realtime/realtime_transcription_session_audio.rbs +2 -2
- data/sig/openai/models/realtime/realtime_transcription_session_audio_input.rbs +10 -10
- data/sig/openai/models/realtime/realtime_transcription_session_audio_input_turn_detection.rbs +22 -22
- data/sig/openai/models/realtime/realtime_transcription_session_create_request.rbs +6 -6
- data/sig/openai/models/realtime/realtime_transcription_session_create_response.rbs +20 -20
- data/sig/openai/models/realtime/realtime_transcription_session_turn_detection.rbs +8 -8
- data/sig/openai/models/realtime/realtime_translation_client_secret_create_request.rbs +6 -6
- data/sig/openai/models/realtime/realtime_translation_input_audio_buffer_append_event.rbs +4 -4
- data/sig/openai/models/realtime/realtime_translation_input_transcript_delta_event.rbs +4 -4
- data/sig/openai/models/realtime/realtime_translation_output_audio_delta_event.rbs +10 -10
- data/sig/openai/models/realtime/realtime_translation_output_transcript_delta_event.rbs +4 -4
- data/sig/openai/models/realtime/realtime_translation_session.rbs +12 -12
- data/sig/openai/models/realtime/realtime_translation_session_close_event.rbs +2 -2
- data/sig/openai/models/realtime/realtime_translation_session_closed_event.rbs +2 -2
- data/sig/openai/models/realtime/realtime_translation_session_create_request.rbs +12 -12
- data/sig/openai/models/realtime/realtime_translation_session_created_event.rbs +2 -2
- data/sig/openai/models/realtime/realtime_translation_session_update_event.rbs +4 -4
- data/sig/openai/models/realtime/realtime_translation_session_update_request.rbs +12 -12
- data/sig/openai/models/realtime/realtime_translation_session_updated_event.rbs +2 -2
- data/sig/openai/models/realtime/realtime_truncation_retention_ratio.rbs +6 -6
- data/sig/openai/models/realtime/response_audio_delta_event.rbs +2 -2
- data/sig/openai/models/realtime/response_audio_done_event.rbs +2 -2
- data/sig/openai/models/realtime/response_audio_transcript_delta_event.rbs +2 -2
- data/sig/openai/models/realtime/response_audio_transcript_done_event.rbs +2 -2
- data/sig/openai/models/realtime/response_cancel_event.rbs +4 -4
- data/sig/openai/models/realtime/response_content_part_added_event.rbs +10 -10
- data/sig/openai/models/realtime/response_content_part_done_event.rbs +10 -10
- data/sig/openai/models/realtime/response_create_event.rbs +6 -6
- data/sig/openai/models/realtime/response_created_event.rbs +2 -2
- data/sig/openai/models/realtime/response_done_event.rbs +2 -2
- data/sig/openai/models/realtime/response_function_call_arguments_delta_event.rbs +2 -2
- data/sig/openai/models/realtime/response_function_call_arguments_done_event.rbs +2 -2
- data/sig/openai/models/realtime/response_mcp_call_arguments_delta.rbs +4 -4
- data/sig/openai/models/realtime/response_mcp_call_arguments_done.rbs +2 -2
- data/sig/openai/models/realtime/response_mcp_call_completed.rbs +2 -2
- data/sig/openai/models/realtime/response_mcp_call_failed.rbs +2 -2
- data/sig/openai/models/realtime/response_mcp_call_in_progress.rbs +2 -2
- data/sig/openai/models/realtime/response_output_item_added_event.rbs +2 -2
- data/sig/openai/models/realtime/response_output_item_done_event.rbs +2 -2
- data/sig/openai/models/realtime/response_text_delta_event.rbs +2 -2
- data/sig/openai/models/realtime/response_text_done_event.rbs +2 -2
- data/sig/openai/models/realtime/session_created_event.rbs +2 -2
- data/sig/openai/models/realtime/session_update_event.rbs +4 -4
- data/sig/openai/models/realtime/session_updated_event.rbs +2 -2
- data/sig/openai/models/realtime/transcription_session_update.rbs +24 -24
- data/sig/openai/models/realtime/transcription_session_updated_event.rbs +18 -18
- data/sig/openai/models/reasoning.rbs +10 -10
- data/sig/openai/models/response_format_json_object.rbs +2 -2
- data/sig/openai/models/response_format_json_schema.rbs +8 -8
- data/sig/openai/models/response_format_text.rbs +2 -2
- data/sig/openai/models/response_format_text_grammar.rbs +2 -2
- data/sig/openai/models/response_format_text_python.rbs +2 -2
- data/sig/openai/models/responses/apply_patch_tool.rbs +4 -4
- data/sig/openai/models/responses/compacted_response.rbs +2 -2
- data/sig/openai/models/responses/computer_action.rbs +25 -25
- data/sig/openai/models/responses/computer_tool.rbs +2 -2
- data/sig/openai/models/responses/computer_use_preview_tool.rbs +2 -2
- data/sig/openai/models/responses/container_auto.rbs +10 -10
- data/sig/openai/models/responses/container_network_policy_allowlist.rbs +4 -4
- data/sig/openai/models/responses/container_network_policy_disabled.rbs +2 -2
- data/sig/openai/models/responses/container_reference.rbs +2 -2
- data/sig/openai/models/responses/custom_tool.rbs +17 -10
- data/sig/openai/models/responses/easy_input_message.rbs +4 -4
- data/sig/openai/models/responses/file_search_tool.rbs +14 -14
- data/sig/openai/models/responses/function_shell_tool.rbs +6 -6
- data/sig/openai/models/responses/function_tool.rbs +17 -10
- data/sig/openai/models/responses/inline_skill.rbs +2 -2
- data/sig/openai/models/responses/inline_skill_source.rbs +3 -3
- data/sig/openai/models/responses/input_item_list_params.rbs +10 -10
- data/sig/openai/models/responses/input_token_count_params.rbs +32 -32
- data/sig/openai/models/responses/input_token_count_response.rbs +2 -2
- data/sig/openai/models/responses/local_environment.rbs +3 -3
- data/sig/openai/models/responses/mcp_tool_call_error.rbs +6 -6
- data/sig/openai/models/responses/namespace_tool.rbs +23 -16
- data/sig/openai/models/responses/response.rbs +178 -58
- data/sig/openai/models/responses/response_apply_patch_tool_call.rbs +16 -16
- data/sig/openai/models/responses/response_apply_patch_tool_call_output.rbs +12 -12
- data/sig/openai/models/responses/response_audio_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_audio_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_audio_transcript_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_audio_transcript_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_cancel_params.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_call_code_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_call_code_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_call_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_call_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_call_interpreting_event.rbs +2 -2
- data/sig/openai/models/responses/response_code_interpreter_tool_call.rbs +6 -6
- data/sig/openai/models/responses/response_compact_params.rbs +23 -21
- data/sig/openai/models/responses/response_compaction_item.rbs +4 -4
- data/sig/openai/models/responses/response_compaction_item_param.rbs +3 -3
- data/sig/openai/models/responses/response_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_computer_tool_call.rbs +31 -31
- data/sig/openai/models/responses/response_computer_tool_call_output_item.rbs +8 -8
- data/sig/openai/models/responses/response_computer_tool_call_output_screenshot.rbs +4 -4
- data/sig/openai/models/responses/response_configuration_update_item.rbs +46 -0
- data/sig/openai/models/responses/response_configuration_update_item_param.rbs +46 -0
- data/sig/openai/models/responses/response_container_reference.rbs +2 -2
- data/sig/openai/models/responses/response_content.rbs +2 -2
- data/sig/openai/models/responses/response_content_part_added_event.rbs +4 -4
- data/sig/openai/models/responses/response_content_part_done_event.rbs +4 -4
- data/sig/openai/models/responses/response_create_params.rbs +83 -78
- data/sig/openai/models/responses/response_created_event.rbs +2 -2
- data/sig/openai/models/responses/response_custom_tool_call.rbs +19 -12
- data/sig/openai/models/responses/response_custom_tool_call_input_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_custom_tool_call_input_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_custom_tool_call_item.rbs +11 -8
- data/sig/openai/models/responses/response_custom_tool_call_output.rbs +10 -10
- data/sig/openai/models/responses/response_custom_tool_call_output_item.rbs +6 -6
- data/sig/openai/models/responses/response_delete_params.rbs +2 -2
- data/sig/openai/models/responses/response_error.rbs +79 -3
- data/sig/openai/models/responses/response_error_event.rbs +2 -2
- data/sig/openai/models/responses/response_failed_event.rbs +2 -2
- data/sig/openai/models/responses/response_file_search_call_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_file_search_call_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_file_search_call_searching_event.rbs +2 -2
- data/sig/openai/models/responses/response_file_search_tool_call.rbs +14 -14
- data/sig/openai/models/responses/response_format_text_json_schema_config.rbs +6 -6
- data/sig/openai/models/responses/response_function_call_arguments_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_function_call_arguments_done_event.rbs +2 -7
- data/sig/openai/models/responses/response_function_shell_call_output_content.rbs +4 -4
- data/sig/openai/models/responses/response_function_shell_tool_call.rbs +10 -10
- data/sig/openai/models/responses/response_function_shell_tool_call_output.rbs +16 -16
- data/sig/openai/models/responses/response_function_tool_call.rbs +21 -14
- data/sig/openai/models/responses/response_function_tool_call_item.rbs +11 -8
- data/sig/openai/models/responses/response_function_tool_call_output_item.rbs +16 -16
- data/sig/openai/models/responses/response_function_web_search.rbs +19 -17
- data/sig/openai/models/responses/response_image_gen_call_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_image_gen_call_generating_event.rbs +2 -2
- data/sig/openai/models/responses/response_image_gen_call_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_image_gen_call_partial_image_event.rbs +10 -10
- data/sig/openai/models/responses/response_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_incomplete_event.rbs +2 -2
- data/sig/openai/models/responses/response_input_audio.rbs +2 -2
- data/sig/openai/models/responses/response_input_file.rbs +16 -16
- data/sig/openai/models/responses/response_input_file_content.rbs +16 -16
- data/sig/openai/models/responses/response_input_image.rbs +10 -10
- data/sig/openai/models/responses/response_input_image_content.rbs +12 -12
- data/sig/openai/models/responses/response_input_item.rbs +167 -158
- data/sig/openai/models/responses/response_input_message_item.rbs +4 -4
- data/sig/openai/models/responses/response_input_text.rbs +6 -6
- data/sig/openai/models/responses/response_input_text_content.rbs +6 -6
- data/sig/openai/models/responses/response_item.rbs +47 -46
- data/sig/openai/models/responses/response_item_list.rbs +2 -2
- data/sig/openai/models/responses/response_local_environment.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_call_arguments_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_call_arguments_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_call_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_call_failed_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_call_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_list_tools_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_list_tools_failed_event.rbs +2 -2
- data/sig/openai/models/responses/response_mcp_list_tools_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_output_audio.rbs +2 -2
- data/sig/openai/models/responses/response_output_item.rbs +46 -46
- data/sig/openai/models/responses/response_output_item_added_event.rbs +2 -2
- data/sig/openai/models/responses/response_output_item_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_output_message.rbs +6 -6
- data/sig/openai/models/responses/response_output_refusal.rbs +2 -2
- data/sig/openai/models/responses/response_output_text.rbs +13 -12
- data/sig/openai/models/responses/response_output_text_annotation_added_event.rbs +11 -10
- data/sig/openai/models/responses/response_prompt.rbs +4 -4
- data/sig/openai/models/responses/response_queued_event.rbs +2 -2
- data/sig/openai/models/responses/response_reasoning_item.rbs +12 -12
- data/sig/openai/models/responses/response_reasoning_summary_part_added_event.rbs +4 -4
- data/sig/openai/models/responses/response_reasoning_summary_part_done_event.rbs +6 -6
- data/sig/openai/models/responses/response_reasoning_summary_text_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_reasoning_summary_text_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_reasoning_text_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_reasoning_text_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_refusal_delta_event.rbs +2 -2
- data/sig/openai/models/responses/response_refusal_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_retrieve_params.rbs +8 -8
- data/sig/openai/models/responses/response_shell_call_command_added_event.rbs +2 -2
- data/sig/openai/models/responses/response_shell_call_command_delta_event.rbs +4 -4
- data/sig/openai/models/responses/response_shell_call_command_done_event.rbs +2 -2
- data/sig/openai/models/responses/response_shell_call_output_content_delta_event.rbs +4 -4
- data/sig/openai/models/responses/response_shell_call_output_content_done_event.rbs +8 -8
- data/sig/openai/models/responses/response_steer_accepted_event.rbs +51 -0
- data/sig/openai/models/responses/response_steer_error_code.rbs +29 -0
- data/sig/openai/models/responses/response_steer_event.rbs +32 -0
- data/sig/openai/models/responses/response_steer_failed_event.rbs +100 -0
- data/sig/openai/models/responses/response_steer_input.rbs +182 -0
- data/sig/openai/models/responses/response_steer_input_content.rbs +16 -0
- data/sig/openai/models/responses/response_steer_pending_event.rbs +61 -0
- data/sig/openai/models/responses/response_steer_pending_reason.rbs +13 -0
- data/sig/openai/models/responses/response_steer_required_input.rbs +159 -0
- data/sig/openai/models/responses/response_text_config.rbs +4 -4
- data/sig/openai/models/responses/response_text_delta_event.rbs +6 -6
- data/sig/openai/models/responses/response_text_done_event.rbs +6 -6
- data/sig/openai/models/responses/response_tool_search_call.rbs +4 -4
- data/sig/openai/models/responses/response_tool_search_output_item.rbs +4 -4
- data/sig/openai/models/responses/response_tool_search_output_item_param.rbs +10 -10
- data/sig/openai/models/responses/response_web_search_call_completed_event.rbs +2 -2
- data/sig/openai/models/responses/response_web_search_call_in_progress_event.rbs +2 -2
- data/sig/openai/models/responses/response_web_search_call_searching_event.rbs +2 -2
- data/sig/openai/models/responses/responses_client_event.rbs +360 -344
- data/sig/openai/models/responses/responses_server_event.rbs +328 -254
- data/sig/openai/models/responses/skill_reference.rbs +3 -3
- data/sig/openai/models/responses/tool.rbs +80 -74
- data/sig/openai/models/responses/tool_choice_allowed.rbs +2 -2
- data/sig/openai/models/responses/tool_choice_apply_patch.rbs +2 -2
- data/sig/openai/models/responses/tool_choice_custom.rbs +2 -2
- data/sig/openai/models/responses/tool_choice_function.rbs +2 -2
- data/sig/openai/models/responses/tool_choice_mcp.rbs +3 -2
- data/sig/openai/models/responses/tool_choice_shell.rbs +2 -2
- data/sig/openai/models/responses/tool_search_tool.rbs +8 -8
- data/sig/openai/models/responses/web_search_preview_tool.rbs +16 -16
- data/sig/openai/models/responses/web_search_tool.rbs +20 -20
- data/sig/openai/models/safety/alert_retrieve_params.rbs +22 -0
- data/sig/openai/models/safety/safety_alert.rbs +81 -0
- data/sig/openai/models/skill.rbs +2 -2
- data/sig/openai/models/skill_create_params.rbs +6 -4
- data/sig/openai/models/skill_delete_params.rbs +2 -2
- data/sig/openai/models/skill_list.rbs +2 -2
- data/sig/openai/models/skill_list_params.rbs +8 -8
- data/sig/openai/models/skill_retrieve_params.rbs +2 -2
- data/sig/openai/models/skill_update_params.rbs +6 -3
- data/sig/openai/models/skills/content_retrieve_params.rbs +2 -2
- data/sig/openai/models/skills/deleted_skill_version.rbs +2 -2
- data/sig/openai/models/skills/skill_version.rbs +2 -2
- data/sig/openai/models/skills/skill_version_list.rbs +2 -2
- data/sig/openai/models/skills/version_create_params.rbs +6 -6
- data/sig/openai/models/skills/version_delete_params.rbs +6 -3
- data/sig/openai/models/skills/version_list_params.rbs +8 -8
- data/sig/openai/models/skills/version_retrieve_params.rbs +6 -3
- data/sig/openai/models/skills/versions/content_retrieve_params.rbs +6 -3
- data/sig/openai/models/static_file_chunking_strategy_object.rbs +2 -2
- data/sig/openai/models/static_file_chunking_strategy_object_param.rbs +2 -2
- data/sig/openai/models/upload.rbs +4 -4
- data/sig/openai/models/upload_cancel_params.rbs +2 -2
- data/sig/openai/models/upload_complete_params.rbs +8 -4
- data/sig/openai/models/upload_create_params.rbs +6 -6
- data/sig/openai/models/uploads/part_create_params.rbs +6 -3
- data/sig/openai/models/uploads/upload_part.rbs +2 -2
- data/sig/openai/models/vector_store.rbs +8 -8
- data/sig/openai/models/vector_store_create_params.rbs +16 -16
- data/sig/openai/models/vector_store_delete_params.rbs +2 -2
- data/sig/openai/models/vector_store_deleted.rbs +2 -2
- data/sig/openai/models/vector_store_list_params.rbs +10 -10
- data/sig/openai/models/vector_store_retrieve_params.rbs +2 -2
- data/sig/openai/models/vector_store_search_params.rbs +14 -14
- data/sig/openai/models/vector_store_update_params.rbs +10 -10
- data/sig/openai/models/vector_stores/file_batch_cancel_params.rbs +6 -3
- data/sig/openai/models/vector_stores/file_batch_create_params.rbs +14 -14
- data/sig/openai/models/vector_stores/file_batch_list_files_params.rbs +12 -12
- data/sig/openai/models/vector_stores/file_batch_retrieve_params.rbs +6 -3
- data/sig/openai/models/vector_stores/file_content_params.rbs +6 -3
- data/sig/openai/models/vector_stores/file_content_response.rbs +2 -2
- data/sig/openai/models/vector_stores/file_create_params.rbs +6 -6
- data/sig/openai/models/vector_stores/file_delete_params.rbs +6 -3
- data/sig/openai/models/vector_stores/file_list_params.rbs +12 -12
- data/sig/openai/models/vector_stores/file_retrieve_params.rbs +6 -3
- data/sig/openai/models/vector_stores/file_update_params.rbs +3 -3
- data/sig/openai/models/vector_stores/vector_store_file.rbs +6 -6
- data/sig/openai/models/vector_stores/vector_store_file_batch.rbs +2 -2
- data/sig/openai/models/vector_stores/vector_store_file_deleted.rbs +2 -2
- data/sig/openai/models/video.rbs +2 -2
- data/sig/openai/models/video_create_character_params.rbs +6 -3
- data/sig/openai/models/video_create_error.rbs +87 -3
- data/sig/openai/models/video_create_params.rbs +10 -10
- data/sig/openai/models/video_delete_params.rbs +2 -2
- data/sig/openai/models/video_delete_response.rbs +2 -2
- data/sig/openai/models/video_download_content_params.rbs +4 -4
- data/sig/openai/models/video_edit_params.rbs +6 -3
- data/sig/openai/models/video_extend_params.rbs +3 -3
- data/sig/openai/models/video_get_character_params.rbs +2 -2
- data/sig/openai/models/video_list_params.rbs +8 -8
- data/sig/openai/models/video_remix_params.rbs +6 -3
- data/sig/openai/models/video_retrieve_params.rbs +2 -2
- data/sig/openai/models/webhooks/batch_cancelled_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/batch_completed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/batch_expired_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/batch_failed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/eval_run_canceled_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/eval_run_failed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/eval_run_succeeded_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/fine_tuning_job_cancelled_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/fine_tuning_job_failed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/fine_tuning_job_succeeded_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/live_call_incoming_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/realtime_call_incoming_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/response_cancelled_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/response_completed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/response_failed_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/response_incomplete_webhook_event.rbs +4 -4
- data/sig/openai/models/webhooks/safety_alert_created_webhook_event.rbs +52 -0
- data/sig/openai/models/webhooks/safety_org_alert_created_webhook_event.rbs +52 -0
- data/sig/openai/models/webhooks/unwrap_webhook_event.rbs +2 -0
- data/sig/openai/models/webhooks/webhook_unwrap_params.rbs +2 -3
- data/sig/openai/models.rbs +2 -0
- data/sig/openai/request_options.rbs +7 -7
- data/sig/openai/resources/admin/organization/projects/service_accounts/api_keys.rbs +1 -0
- data/sig/openai/resources/audio/speech.rbs +1 -1
- data/sig/openai/resources/containers/files/content.rbs +1 -1
- data/sig/openai/resources/files.rbs +1 -1
- data/sig/openai/resources/responses.rbs +51 -2
- data/sig/openai/resources/safety/alerts.rbs +14 -0
- data/sig/openai/resources/safety.rbs +9 -0
- data/sig/openai/resources/skills/content.rbs +1 -1
- data/sig/openai/resources/skills/versions/content.rbs +1 -1
- data/sig/openai/resources/videos.rbs +1 -1
- data/sig/openai/resources/webhooks.rbs +3 -1
- data/sig/openai/response_carrier.rbs +13 -0
- data/sig/openai/streaming.rbs +10 -0
- metadata +127 -1
|
@@ -5,544 +5,46 @@ module OpenAI
|
|
|
5
5
|
|
|
6
6
|
module Responses
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
# Client events accepted by the Responses WebSocket server.
|
|
9
|
+
module ResponsesClientEvent
|
|
10
|
+
extend OpenAI::Internal::Type::Union
|
|
9
11
|
|
|
10
|
-
|
|
12
|
+
Variants = T.type_alias do
|
|
11
13
|
T.any(
|
|
12
|
-
OpenAI::Responses::ResponsesClientEvent,
|
|
13
|
-
OpenAI::
|
|
14
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate,
|
|
15
|
+
OpenAI::Responses::ResponseSteerEvent
|
|
14
16
|
)
|
|
15
17
|
end
|
|
16
18
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
# [Learn more](https://platform.openai.com/docs/guides/background).
|
|
23
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
24
|
-
attr_accessor :background
|
|
25
|
-
|
|
26
|
-
# Context management configuration for this request.
|
|
27
|
-
sig { returns(T.nilable(T::Array[OpenAI::Responses::ResponsesClientEvent::ContextManagement])) }
|
|
28
|
-
attr_accessor :context_management
|
|
29
|
-
|
|
30
|
-
# The conversation that this response belongs to. Items from this conversation are
|
|
31
|
-
# prepended to `input_items` for this response request. Input items and output
|
|
32
|
-
# items from this response are automatically added to this conversation after this
|
|
33
|
-
# response completes.
|
|
34
|
-
sig { returns(T.nilable(T.any(String, OpenAI::Responses::ResponseConversationParam))) }
|
|
35
|
-
attr_accessor :conversation
|
|
36
|
-
|
|
37
|
-
# Specify additional output data to include in the model response. Currently
|
|
38
|
-
# supported values are:
|
|
39
|
-
#
|
|
40
|
-
# - `web_search_call.action.sources`: Include the sources of the web search tool
|
|
41
|
-
# call.
|
|
42
|
-
# - `code_interpreter_call.outputs`: Includes the outputs of python code execution
|
|
43
|
-
# in code interpreter tool call items.
|
|
44
|
-
# - `computer_call_output.output.image_url`: Include image urls from the computer
|
|
45
|
-
# call output.
|
|
46
|
-
# - `file_search_call.results`: Include the search results of the file search tool
|
|
47
|
-
# call.
|
|
48
|
-
# - `message.input_image.image_url`: Include image urls from the input message.
|
|
49
|
-
# - `message.output_text.logprobs`: Include logprobs with assistant messages.
|
|
50
|
-
# - `reasoning.encrypted_content`: Includes an encrypted version of reasoning
|
|
51
|
-
# tokens in reasoning item outputs. This enables reasoning items to be used in
|
|
52
|
-
# multi-turn conversations when using the Responses API statelessly (like when
|
|
53
|
-
# the `store` parameter is set to `false`, or when an organization is enrolled
|
|
54
|
-
# in the zero data retention program).
|
|
55
|
-
sig { returns(T.nilable(T::Array[OpenAI::Responses::ResponseIncludable::OrSymbol])) }
|
|
56
|
-
attr_accessor :include
|
|
57
|
-
|
|
58
|
-
# Text, image, or file inputs to the model, used to generate a response.
|
|
59
|
-
#
|
|
60
|
-
# Learn more:
|
|
61
|
-
#
|
|
62
|
-
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
63
|
-
# - [Image inputs](https://platform.openai.com/docs/guides/images)
|
|
64
|
-
# - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
|
|
65
|
-
# - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
|
|
66
|
-
# - [Function calling](https://platform.openai.com/docs/guides/function-calling)
|
|
67
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::Input::Variants)) }
|
|
68
|
-
attr_reader :input
|
|
69
|
-
|
|
70
|
-
sig { params(input: OpenAI::Responses::ResponsesClientEvent::Input::Variants).void }
|
|
71
|
-
attr_writer :input
|
|
72
|
-
|
|
73
|
-
# A system (or developer) message inserted into the model's context.
|
|
74
|
-
#
|
|
75
|
-
# When using along with `previous_response_id`, the instructions from a previous
|
|
76
|
-
# response will not be carried over to the next response. This makes it simple to
|
|
77
|
-
# swap out system (or developer) messages in new responses.
|
|
78
|
-
sig { returns(T.nilable(String)) }
|
|
79
|
-
attr_accessor :instructions
|
|
80
|
-
|
|
81
|
-
# An upper bound for the number of tokens that can be generated for a response,
|
|
82
|
-
# including visible output tokens and
|
|
83
|
-
# [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
|
|
84
|
-
sig { returns(T.nilable(Integer)) }
|
|
85
|
-
attr_accessor :max_output_tokens
|
|
86
|
-
|
|
87
|
-
# The maximum number of total calls to built-in tools that can be processed in a
|
|
88
|
-
# response. This maximum number applies across all built-in tool calls, not per
|
|
89
|
-
# individual tool. Any further attempts to call a tool by the model will be
|
|
90
|
-
# ignored.
|
|
91
|
-
sig { returns(T.nilable(Integer)) }
|
|
92
|
-
attr_accessor :max_tool_calls
|
|
93
|
-
|
|
94
|
-
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
95
|
-
# for storing additional information about the object in a structured format, and
|
|
96
|
-
# querying for objects via API or the dashboard.
|
|
97
|
-
#
|
|
98
|
-
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
99
|
-
# a maximum length of 512 characters.
|
|
100
|
-
sig { returns(T.nilable(T::Hash[Symbol, String])) }
|
|
101
|
-
attr_accessor :metadata
|
|
102
|
-
|
|
103
|
-
# Model ID used to generate the response, like `gpt-5.6-sol`. OpenAI offers a wide
|
|
104
|
-
# range of models with different capabilities, performance characteristics, and
|
|
105
|
-
# price points. Refer to the
|
|
106
|
-
# [model guide](https://platform.openai.com/docs/models) to browse and compare
|
|
107
|
-
# available models.
|
|
108
|
-
sig {
|
|
109
|
-
returns(
|
|
110
|
-
T.nilable(T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol))
|
|
111
|
-
)
|
|
112
|
-
}
|
|
113
|
-
attr_reader :model
|
|
114
|
-
|
|
115
|
-
sig {
|
|
116
|
-
params(
|
|
117
|
-
model: T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol)
|
|
118
|
-
)
|
|
119
|
-
.void
|
|
120
|
-
}
|
|
121
|
-
attr_writer :model
|
|
122
|
-
|
|
123
|
-
# Configuration for running moderation on the input and output of this response.
|
|
124
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation)) }
|
|
125
|
-
attr_reader :moderation
|
|
126
|
-
|
|
127
|
-
sig { params(moderation: T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::OrHash)).void }
|
|
128
|
-
attr_writer :moderation
|
|
129
|
-
|
|
130
|
-
# Whether to allow the model to run tool calls in parallel.
|
|
131
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
132
|
-
attr_accessor :parallel_tool_calls
|
|
133
|
-
|
|
134
|
-
# The unique ID of the previous response to the model. Use this to create
|
|
135
|
-
# multi-turn conversations. Learn more about
|
|
136
|
-
# [conversation state](https://platform.openai.com/docs/guides/conversation-state).
|
|
137
|
-
# Cannot be used in conjunction with `conversation`.
|
|
138
|
-
sig { returns(T.nilable(String)) }
|
|
139
|
-
attr_accessor :previous_response_id
|
|
140
|
-
|
|
141
|
-
# Reference to a prompt template and its variables.
|
|
142
|
-
# [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
|
|
143
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsePrompt)) }
|
|
144
|
-
attr_reader :prompt
|
|
145
|
-
|
|
146
|
-
sig { params(prompt: T.nilable(OpenAI::Responses::ResponsePrompt::OrHash)).void }
|
|
147
|
-
attr_writer :prompt
|
|
148
|
-
|
|
149
|
-
# Used by OpenAI to cache responses for similar requests to optimize your cache
|
|
150
|
-
# hit rates. Replaces the `user` field.
|
|
151
|
-
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
|
|
152
|
-
sig { returns(T.nilable(String)) }
|
|
153
|
-
attr_accessor :prompt_cache_key
|
|
154
|
-
|
|
155
|
-
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
156
|
-
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
157
|
-
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
158
|
-
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
159
|
-
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
160
|
-
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
161
|
-
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
162
|
-
# [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
|
|
163
|
-
# for current details.
|
|
164
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::PromptCacheOptions)) }
|
|
165
|
-
attr_reader :prompt_cache_options
|
|
166
|
-
|
|
167
|
-
sig { params(prompt_cache_options: OpenAI::Responses::ResponsesClientEvent::PromptCacheOptions::OrHash).void }
|
|
168
|
-
attr_writer :prompt_cache_options
|
|
169
|
-
|
|
170
|
-
# Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
171
|
-
#
|
|
172
|
-
# The retention policy for the prompt cache. Set to `24h` to enable extended
|
|
173
|
-
# prompt caching, which keeps cached prefixes active for longer, up to a maximum
|
|
174
|
-
# of 24 hours.
|
|
175
|
-
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
|
|
176
|
-
# This field expresses a maximum retention policy, while
|
|
177
|
-
# `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
|
|
178
|
-
# are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
|
|
179
|
-
# models, only `24h` is supported.
|
|
180
|
-
#
|
|
181
|
-
# For older models that support both `in_memory` and `24h`, the default depends on
|
|
182
|
-
# your organization's data retention policy:
|
|
183
|
-
#
|
|
184
|
-
# - Organizations without ZDR enabled default to `24h`.
|
|
185
|
-
# - Organizations with ZDR enabled default to `in_memory` when
|
|
186
|
-
# `prompt_cache_retention` is not specified.
|
|
187
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention::OrSymbol)) }
|
|
188
|
-
attr_accessor :prompt_cache_retention
|
|
189
|
-
|
|
190
|
-
# Configuration options for
|
|
191
|
-
# [reasoning models](https://platform.openai.com/docs/guides/reasoning).
|
|
192
|
-
sig { returns(T.nilable(OpenAI::Reasoning)) }
|
|
193
|
-
attr_reader :reasoning
|
|
194
|
-
|
|
195
|
-
sig { params(reasoning: T.nilable(OpenAI::Reasoning::OrHash)).void }
|
|
196
|
-
attr_writer :reasoning
|
|
197
|
-
|
|
198
|
-
# A stable identifier used to help detect users of your application that may be
|
|
199
|
-
# violating OpenAI's usage policies. The IDs should be a string that uniquely
|
|
200
|
-
# identifies each user, with a maximum length of 64 characters. We recommend
|
|
201
|
-
# hashing their username or email address, in order to avoid sending us any
|
|
202
|
-
# identifying information.
|
|
203
|
-
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
204
|
-
sig { returns(T.nilable(String)) }
|
|
205
|
-
attr_accessor :safety_identifier
|
|
206
|
-
|
|
207
|
-
# Specifies the processing type used for serving the request.
|
|
208
|
-
#
|
|
209
|
-
# - If set to 'auto', then the request will be processed with the service tier
|
|
210
|
-
# configured in the Project settings. Unless otherwise configured, the Project
|
|
211
|
-
# will use 'default'.
|
|
212
|
-
# - If set to 'default', then the request will be processed with the standard
|
|
213
|
-
# pricing and performance for the selected model.
|
|
214
|
-
# - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
|
|
215
|
-
# then the request will be processed with the Flex Processing service tier.
|
|
216
|
-
# - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
|
|
217
|
-
# include the `service_tier=fast` or `service_tier=priority` parameter for
|
|
218
|
-
# Responses or Chat Completions. The response will show `service_tier=priority`
|
|
219
|
-
# regardless of if you specify `service_tier=fast` or `priority` in your
|
|
220
|
-
# request.
|
|
221
|
-
# - If set to 'ultrafast', then the request will be processed with the
|
|
222
|
-
# access-controlled Ultrafast Processing service tier. This tier is currently
|
|
223
|
-
# available for `gpt-5.6-sol`; a response served through it will show
|
|
224
|
-
# `service_tier=ultrafast`.
|
|
225
|
-
# - When not set, the default behavior is 'auto'.
|
|
226
|
-
#
|
|
227
|
-
# When the `service_tier` parameter is set, the response body will include the
|
|
228
|
-
# `service_tier` value based on the processing mode actually used to serve the
|
|
229
|
-
# request. This response value may be different from the value set in the
|
|
230
|
-
# parameter.
|
|
231
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ServiceTier::OrSymbol)) }
|
|
232
|
-
attr_accessor :service_tier
|
|
233
|
-
|
|
234
|
-
# Whether to store the generated model response for later retrieval via API.
|
|
235
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
236
|
-
attr_accessor :store
|
|
237
|
-
|
|
238
|
-
# If set to true, the model response data will be streamed to the client as it is
|
|
239
|
-
# generated using
|
|
240
|
-
# [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
|
|
241
|
-
# See the
|
|
242
|
-
# [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
|
|
243
|
-
# for more information.
|
|
244
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
245
|
-
attr_accessor :stream
|
|
246
|
-
|
|
247
|
-
# The WebSocket lane for this response. Requests with the same `stream_id` are
|
|
248
|
-
# processed FIFO, and events for the response echo the same `stream_id`.
|
|
249
|
-
#
|
|
250
|
-
# `stream_id` controls routing; `previous_response_id` controls conversation
|
|
251
|
-
# lineage, so a new lane can fork from a response created on another lane.
|
|
252
|
-
sig { returns(T.nilable(String)) }
|
|
253
|
-
attr_reader :stream_id
|
|
254
|
-
|
|
255
|
-
sig { params(stream_id: String).void }
|
|
256
|
-
attr_writer :stream_id
|
|
257
|
-
|
|
258
|
-
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
259
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::StreamOptions)) }
|
|
260
|
-
attr_reader :stream_options
|
|
261
|
-
|
|
262
|
-
sig { params(stream_options: T.nilable(OpenAI::Responses::ResponsesClientEvent::StreamOptions::OrHash)).void }
|
|
263
|
-
attr_writer :stream_options
|
|
264
|
-
|
|
265
|
-
# What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
|
|
266
|
-
# make the output more random, while lower values like 0.2 will make it more
|
|
267
|
-
# focused and deterministic. We generally recommend altering this or `top_p` but
|
|
268
|
-
# not both.
|
|
269
|
-
sig { returns(T.nilable(Float)) }
|
|
270
|
-
attr_accessor :temperature
|
|
271
|
-
|
|
272
|
-
# Configuration options for a text response from the model. Can be plain text or
|
|
273
|
-
# structured JSON data. Learn more:
|
|
274
|
-
#
|
|
275
|
-
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
276
|
-
# - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
|
|
277
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponseTextConfig)) }
|
|
278
|
-
attr_reader :text
|
|
279
|
-
|
|
280
|
-
sig { params(text: OpenAI::Responses::ResponseTextConfig::OrHash).void }
|
|
281
|
-
attr_writer :text
|
|
282
|
-
|
|
283
|
-
# How the model should select which tool (or tools) to use when generating a
|
|
284
|
-
# response. See the `tools` parameter to see how to specify which tools the model
|
|
285
|
-
# can call.
|
|
286
|
-
sig {
|
|
287
|
-
returns(
|
|
288
|
-
T.nilable(
|
|
289
|
-
T.any(
|
|
290
|
-
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
291
|
-
OpenAI::Responses::ToolChoiceAllowed,
|
|
292
|
-
OpenAI::Responses::ToolChoiceTypes,
|
|
293
|
-
OpenAI::Responses::ToolChoiceFunction,
|
|
294
|
-
OpenAI::Responses::ToolChoiceMcp,
|
|
295
|
-
OpenAI::Responses::ToolChoiceCustom,
|
|
296
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
297
|
-
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
298
|
-
OpenAI::Responses::ToolChoiceShell
|
|
299
|
-
)
|
|
300
|
-
)
|
|
301
|
-
)
|
|
302
|
-
}
|
|
303
|
-
attr_reader :tool_choice
|
|
304
|
-
|
|
305
|
-
sig {
|
|
306
|
-
params(
|
|
307
|
-
tool_choice: T.any(
|
|
308
|
-
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
309
|
-
OpenAI::Responses::ToolChoiceAllowed::OrHash,
|
|
310
|
-
OpenAI::Responses::ToolChoiceTypes::OrHash,
|
|
311
|
-
OpenAI::Responses::ToolChoiceFunction::OrHash,
|
|
312
|
-
OpenAI::Responses::ToolChoiceMcp::OrHash,
|
|
313
|
-
OpenAI::Responses::ToolChoiceCustom::OrHash,
|
|
314
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam::OrHash,
|
|
315
|
-
OpenAI::Responses::ToolChoiceApplyPatch::OrHash,
|
|
316
|
-
OpenAI::Responses::ToolChoiceShell::OrHash
|
|
317
|
-
)
|
|
318
|
-
)
|
|
319
|
-
.void
|
|
320
|
-
}
|
|
321
|
-
attr_writer :tool_choice
|
|
322
|
-
|
|
323
|
-
# An array of tools the model may call while generating a response. You can
|
|
324
|
-
# specify which tool to use by setting the `tool_choice` parameter.
|
|
325
|
-
#
|
|
326
|
-
# We support the following categories of tools:
|
|
327
|
-
#
|
|
328
|
-
# - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
|
|
329
|
-
# capabilities, like
|
|
330
|
-
# [web search](https://platform.openai.com/docs/guides/tools-web-search) or
|
|
331
|
-
# [file search](https://platform.openai.com/docs/guides/tools-file-search).
|
|
332
|
-
# Learn more about
|
|
333
|
-
# [built-in tools](https://platform.openai.com/docs/guides/tools).
|
|
334
|
-
# - **MCP Tools**: Integrations with third-party systems via custom MCP servers or
|
|
335
|
-
# predefined connectors such as Google Drive and SharePoint. Learn more about
|
|
336
|
-
# [MCP Tools](https://platform.openai.com/docs/guides/tools-connectors-mcp).
|
|
337
|
-
# - **Function calls (custom tools)**: Functions that are defined by you, enabling
|
|
338
|
-
# the model to call your own code with strongly typed arguments and outputs.
|
|
339
|
-
# Learn more about
|
|
340
|
-
# [function calling](https://platform.openai.com/docs/guides/function-calling).
|
|
341
|
-
# You can also use custom tools to call your own code.
|
|
342
|
-
sig {
|
|
343
|
-
returns(
|
|
344
|
-
T.nilable(
|
|
345
|
-
T::Array[
|
|
346
|
-
T.any(
|
|
347
|
-
OpenAI::Responses::FunctionTool,
|
|
348
|
-
OpenAI::Responses::FileSearchTool,
|
|
349
|
-
OpenAI::Responses::ComputerTool,
|
|
350
|
-
OpenAI::Responses::ComputerUsePreviewTool,
|
|
351
|
-
OpenAI::Responses::Tool::Mcp,
|
|
352
|
-
OpenAI::Responses::Tool::CodeInterpreter,
|
|
353
|
-
OpenAI::Responses::Tool::ProgrammaticToolCalling,
|
|
354
|
-
OpenAI::Responses::Tool::ImageGeneration,
|
|
355
|
-
OpenAI::Responses::Tool::LocalShell,
|
|
356
|
-
OpenAI::Responses::FunctionShellTool,
|
|
357
|
-
OpenAI::Responses::CustomTool,
|
|
358
|
-
OpenAI::Responses::NamespaceTool,
|
|
359
|
-
OpenAI::Responses::ToolSearchTool,
|
|
360
|
-
OpenAI::Responses::ApplyPatchTool,
|
|
361
|
-
OpenAI::Responses::WebSearchTool,
|
|
362
|
-
OpenAI::Responses::WebSearchPreviewTool
|
|
363
|
-
)
|
|
364
|
-
]
|
|
19
|
+
class ResponseCreate < OpenAI::Internal::Type::BaseModel
|
|
20
|
+
OrHash = T.type_alias do
|
|
21
|
+
T.any(
|
|
22
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate,
|
|
23
|
+
OpenAI::Internal::AnyHash
|
|
365
24
|
)
|
|
366
|
-
|
|
367
|
-
}
|
|
368
|
-
attr_reader :tools
|
|
369
|
-
|
|
370
|
-
sig {
|
|
371
|
-
params(
|
|
372
|
-
tools: T::Array[
|
|
373
|
-
T.any(
|
|
374
|
-
OpenAI::Responses::FunctionTool::OrHash,
|
|
375
|
-
OpenAI::Responses::FileSearchTool::OrHash,
|
|
376
|
-
OpenAI::Responses::ComputerTool::OrHash,
|
|
377
|
-
OpenAI::Responses::ComputerUsePreviewTool::OrHash,
|
|
378
|
-
OpenAI::Responses::Tool::Mcp::OrHash,
|
|
379
|
-
OpenAI::Responses::Tool::CodeInterpreter::OrHash,
|
|
380
|
-
OpenAI::Responses::Tool::ProgrammaticToolCalling::OrHash,
|
|
381
|
-
OpenAI::Responses::Tool::ImageGeneration::OrHash,
|
|
382
|
-
OpenAI::Responses::Tool::LocalShell::OrHash,
|
|
383
|
-
OpenAI::Responses::FunctionShellTool::OrHash,
|
|
384
|
-
OpenAI::Responses::CustomTool::OrHash,
|
|
385
|
-
OpenAI::Responses::NamespaceTool::OrHash,
|
|
386
|
-
OpenAI::Responses::ToolSearchTool::OrHash,
|
|
387
|
-
OpenAI::Responses::ApplyPatchTool::OrHash,
|
|
388
|
-
OpenAI::Responses::WebSearchTool::OrHash,
|
|
389
|
-
OpenAI::Responses::WebSearchPreviewTool::OrHash
|
|
390
|
-
)
|
|
391
|
-
]
|
|
392
|
-
)
|
|
393
|
-
.void
|
|
394
|
-
}
|
|
395
|
-
attr_writer :tools
|
|
396
|
-
|
|
397
|
-
# An integer between 0 and 20 specifying the maximum number of most likely tokens
|
|
398
|
-
# to return at each token position, each with an associated log probability. In
|
|
399
|
-
# some cases, the number of returned tokens may be fewer than requested.
|
|
400
|
-
sig { returns(T.nilable(Integer)) }
|
|
401
|
-
attr_accessor :top_logprobs
|
|
402
|
-
|
|
403
|
-
# An alternative to sampling with temperature, called nucleus sampling, where the
|
|
404
|
-
# model considers the results of the tokens with top_p probability mass. So 0.1
|
|
405
|
-
# means only the tokens comprising the top 10% probability mass are considered.
|
|
406
|
-
#
|
|
407
|
-
# We generally recommend altering this or `temperature` but not both.
|
|
408
|
-
sig { returns(T.nilable(Float)) }
|
|
409
|
-
attr_accessor :top_p
|
|
410
|
-
|
|
411
|
-
# The truncation strategy to use for the model response.
|
|
412
|
-
#
|
|
413
|
-
# - `auto`: If the input to this Response exceeds the model's context window size,
|
|
414
|
-
# the model will truncate the response to fit the context window by dropping
|
|
415
|
-
# items from the beginning of the conversation.
|
|
416
|
-
# - `disabled` (default): If the input size will exceed the context window size
|
|
417
|
-
# for a model, the request will fail with a 400 error.
|
|
418
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::Truncation::OrSymbol)) }
|
|
419
|
-
attr_accessor :truncation
|
|
420
|
-
|
|
421
|
-
# This field is being replaced by `safety_identifier` and `prompt_cache_key`. Use
|
|
422
|
-
# `prompt_cache_key` instead to maintain caching optimizations. A stable
|
|
423
|
-
# identifier for your end-users. Used to boost cache hit rates by better bucketing
|
|
424
|
-
# similar requests and to help OpenAI detect and prevent abuse.
|
|
425
|
-
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
426
|
-
sig { returns(T.nilable(String)) }
|
|
427
|
-
attr_reader :user
|
|
428
|
-
|
|
429
|
-
sig { params(user: String).void }
|
|
430
|
-
attr_writer :user
|
|
431
|
-
|
|
432
|
-
sig do
|
|
433
|
-
params(
|
|
434
|
-
|
|
435
|
-
background: T.nilable(T::Boolean),
|
|
436
|
-
|
|
437
|
-
context_management: T.nilable(T::Array[OpenAI::Responses::ResponsesClientEvent::ContextManagement::OrHash]),
|
|
438
|
-
|
|
439
|
-
conversation: T.nilable(T.any(String, OpenAI::Responses::ResponseConversationParam::OrHash)),
|
|
440
|
-
|
|
441
|
-
include: T.nilable(T::Array[OpenAI::Responses::ResponseIncludable::OrSymbol]),
|
|
442
|
-
|
|
443
|
-
input: OpenAI::Responses::ResponsesClientEvent::Input::Variants,
|
|
444
|
-
|
|
445
|
-
instructions: T.nilable(String),
|
|
446
|
-
|
|
447
|
-
max_output_tokens: T.nilable(Integer),
|
|
448
|
-
|
|
449
|
-
max_tool_calls: T.nilable(Integer),
|
|
450
|
-
|
|
451
|
-
metadata: T.nilable(T::Hash[Symbol, String]),
|
|
452
|
-
|
|
453
|
-
model: T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol),
|
|
454
|
-
|
|
455
|
-
moderation: T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::OrHash),
|
|
456
|
-
|
|
457
|
-
parallel_tool_calls: T.nilable(T::Boolean),
|
|
458
|
-
|
|
459
|
-
previous_response_id: T.nilable(String),
|
|
460
|
-
|
|
461
|
-
prompt: T.nilable(OpenAI::Responses::ResponsePrompt::OrHash),
|
|
462
|
-
|
|
463
|
-
prompt_cache_key: T.nilable(String),
|
|
464
|
-
|
|
465
|
-
prompt_cache_options: OpenAI::Responses::ResponsesClientEvent::PromptCacheOptions::OrHash,
|
|
466
|
-
|
|
467
|
-
prompt_cache_retention: T.nilable(OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention::OrSymbol),
|
|
468
|
-
|
|
469
|
-
reasoning: T.nilable(OpenAI::Reasoning::OrHash),
|
|
470
|
-
|
|
471
|
-
safety_identifier: T.nilable(String),
|
|
472
|
-
|
|
473
|
-
service_tier: T.nilable(OpenAI::Responses::ResponsesClientEvent::ServiceTier::OrSymbol),
|
|
474
|
-
|
|
475
|
-
store: T.nilable(T::Boolean),
|
|
476
|
-
|
|
477
|
-
stream: T.nilable(T::Boolean),
|
|
478
|
-
|
|
479
|
-
stream_id: String,
|
|
480
|
-
|
|
481
|
-
stream_options: T.nilable(OpenAI::Responses::ResponsesClientEvent::StreamOptions::OrHash),
|
|
482
|
-
|
|
483
|
-
temperature: T.nilable(Float),
|
|
484
|
-
|
|
485
|
-
text: OpenAI::Responses::ResponseTextConfig::OrHash,
|
|
486
|
-
|
|
487
|
-
tool_choice: T.any(
|
|
488
|
-
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
489
|
-
OpenAI::Responses::ToolChoiceAllowed::OrHash,
|
|
490
|
-
OpenAI::Responses::ToolChoiceTypes::OrHash,
|
|
491
|
-
OpenAI::Responses::ToolChoiceFunction::OrHash,
|
|
492
|
-
OpenAI::Responses::ToolChoiceMcp::OrHash,
|
|
493
|
-
OpenAI::Responses::ToolChoiceCustom::OrHash,
|
|
494
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam::OrHash,
|
|
495
|
-
OpenAI::Responses::ToolChoiceApplyPatch::OrHash,
|
|
496
|
-
OpenAI::Responses::ToolChoiceShell::OrHash
|
|
497
|
-
),
|
|
498
|
-
|
|
499
|
-
tools: T::Array[
|
|
500
|
-
T.any(
|
|
501
|
-
OpenAI::Responses::FunctionTool::OrHash,
|
|
502
|
-
OpenAI::Responses::FileSearchTool::OrHash,
|
|
503
|
-
OpenAI::Responses::ComputerTool::OrHash,
|
|
504
|
-
OpenAI::Responses::ComputerUsePreviewTool::OrHash,
|
|
505
|
-
OpenAI::Responses::Tool::Mcp::OrHash,
|
|
506
|
-
OpenAI::Responses::Tool::CodeInterpreter::OrHash,
|
|
507
|
-
OpenAI::Responses::Tool::ProgrammaticToolCalling::OrHash,
|
|
508
|
-
OpenAI::Responses::Tool::ImageGeneration::OrHash,
|
|
509
|
-
OpenAI::Responses::Tool::LocalShell::OrHash,
|
|
510
|
-
OpenAI::Responses::FunctionShellTool::OrHash,
|
|
511
|
-
OpenAI::Responses::CustomTool::OrHash,
|
|
512
|
-
OpenAI::Responses::NamespaceTool::OrHash,
|
|
513
|
-
OpenAI::Responses::ToolSearchTool::OrHash,
|
|
514
|
-
OpenAI::Responses::ApplyPatchTool::OrHash,
|
|
515
|
-
OpenAI::Responses::WebSearchTool::OrHash,
|
|
516
|
-
OpenAI::Responses::WebSearchPreviewTool::OrHash
|
|
517
|
-
)
|
|
518
|
-
],
|
|
519
|
-
|
|
520
|
-
top_logprobs: T.nilable(Integer),
|
|
521
|
-
|
|
522
|
-
top_p: T.nilable(Float),
|
|
523
|
-
|
|
524
|
-
truncation: T.nilable(OpenAI::Responses::ResponsesClientEvent::Truncation::OrSymbol),
|
|
525
|
-
|
|
526
|
-
user: String,
|
|
25
|
+
end
|
|
527
26
|
|
|
528
|
-
|
|
529
|
-
)
|
|
530
|
-
|
|
531
|
-
end
|
|
532
|
-
def self.new(
|
|
27
|
+
# The type of the client event. Always `response.create`.
|
|
28
|
+
sig { returns(Symbol) }
|
|
29
|
+
attr_accessor :type
|
|
533
30
|
|
|
534
31
|
# Whether to run the model response in the background.
|
|
535
32
|
# [Learn more](https://platform.openai.com/docs/guides/background).
|
|
536
|
-
|
|
33
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
34
|
+
attr_accessor :background
|
|
537
35
|
|
|
538
36
|
# Context management configuration for this request.
|
|
539
|
-
|
|
37
|
+
sig {
|
|
38
|
+
returns(T.nilable(T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ContextManagement]))
|
|
39
|
+
}
|
|
40
|
+
attr_accessor :context_management
|
|
540
41
|
|
|
541
42
|
# The conversation that this response belongs to. Items from this conversation are
|
|
542
43
|
# prepended to `input_items` for this response request. Input items and output
|
|
543
44
|
# items from this response are automatically added to this conversation after this
|
|
544
45
|
# response completes.
|
|
545
|
-
|
|
46
|
+
sig { returns(T.nilable(T.any(String, OpenAI::Responses::ResponseConversationParam))) }
|
|
47
|
+
attr_accessor :conversation
|
|
546
48
|
|
|
547
49
|
# Specify additional output data to include in the model response. Currently
|
|
548
50
|
# supported values are:
|
|
@@ -562,7 +64,8 @@ module OpenAI
|
|
|
562
64
|
# multi-turn conversations when using the Responses API statelessly (like when
|
|
563
65
|
# the `store` parameter is set to `false`, or when an organization is enrolled
|
|
564
66
|
# in the zero data retention program).
|
|
565
|
-
|
|
67
|
+
sig { returns(T.nilable(T::Array[OpenAI::Responses::ResponseIncludable::OrSymbol])) }
|
|
68
|
+
attr_accessor :include
|
|
566
69
|
|
|
567
70
|
# Text, image, or file inputs to the model, used to generate a response.
|
|
568
71
|
#
|
|
@@ -573,25 +76,32 @@ module OpenAI
|
|
|
573
76
|
# - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
|
|
574
77
|
# - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
|
|
575
78
|
# - [Function calling](https://platform.openai.com/docs/guides/function-calling)
|
|
576
|
-
|
|
79
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Input::Variants)) }
|
|
80
|
+
attr_reader :input
|
|
81
|
+
|
|
82
|
+
sig { params(input: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Input::Variants).void }
|
|
83
|
+
attr_writer :input
|
|
577
84
|
|
|
578
85
|
# A system (or developer) message inserted into the model's context.
|
|
579
86
|
#
|
|
580
87
|
# When using along with `previous_response_id`, the instructions from a previous
|
|
581
88
|
# response will not be carried over to the next response. This makes it simple to
|
|
582
89
|
# swap out system (or developer) messages in new responses.
|
|
583
|
-
|
|
90
|
+
sig { returns(T.nilable(String)) }
|
|
91
|
+
attr_accessor :instructions
|
|
584
92
|
|
|
585
93
|
# An upper bound for the number of tokens that can be generated for a response,
|
|
586
94
|
# including visible output tokens and
|
|
587
95
|
# [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
|
|
588
|
-
|
|
96
|
+
sig { returns(T.nilable(Integer)) }
|
|
97
|
+
attr_accessor :max_output_tokens
|
|
589
98
|
|
|
590
99
|
# The maximum number of total calls to built-in tools that can be processed in a
|
|
591
100
|
# response. This maximum number applies across all built-in tool calls, not per
|
|
592
101
|
# individual tool. Any further attempts to call a tool by the model will be
|
|
593
102
|
# ignored.
|
|
594
|
-
|
|
103
|
+
sig { returns(T.nilable(Integer)) }
|
|
104
|
+
attr_accessor :max_tool_calls
|
|
595
105
|
|
|
596
106
|
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
597
107
|
# for storing additional information about the object in a structured format, and
|
|
@@ -599,35 +109,65 @@ module OpenAI
|
|
|
599
109
|
#
|
|
600
110
|
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
601
111
|
# a maximum length of 512 characters.
|
|
602
|
-
|
|
112
|
+
sig { returns(T.nilable(T::Hash[Symbol, String])) }
|
|
113
|
+
attr_accessor :metadata
|
|
603
114
|
|
|
604
|
-
# Model ID used to generate the response, like `gpt-
|
|
115
|
+
# Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
|
|
605
116
|
# range of models with different capabilities, performance characteristics, and
|
|
606
117
|
# price points. Refer to the
|
|
607
118
|
# [model guide](https://platform.openai.com/docs/models) to browse and compare
|
|
608
119
|
# available models.
|
|
609
|
-
|
|
120
|
+
sig {
|
|
121
|
+
returns(
|
|
122
|
+
T.nilable(
|
|
123
|
+
T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol)
|
|
124
|
+
)
|
|
125
|
+
)
|
|
126
|
+
}
|
|
127
|
+
attr_reader :model
|
|
128
|
+
|
|
129
|
+
sig {
|
|
130
|
+
params(
|
|
131
|
+
model: T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol)
|
|
132
|
+
)
|
|
133
|
+
.void
|
|
134
|
+
}
|
|
135
|
+
attr_writer :model
|
|
610
136
|
|
|
611
137
|
# Configuration for running moderation on the input and output of this response.
|
|
612
|
-
|
|
138
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation)) }
|
|
139
|
+
attr_reader :moderation
|
|
140
|
+
|
|
141
|
+
sig {
|
|
142
|
+
params(moderation: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::OrHash))
|
|
143
|
+
.void
|
|
144
|
+
}
|
|
145
|
+
attr_writer :moderation
|
|
613
146
|
|
|
614
147
|
# Whether to allow the model to run tool calls in parallel.
|
|
615
|
-
|
|
148
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
149
|
+
attr_accessor :parallel_tool_calls
|
|
616
150
|
|
|
617
151
|
# The unique ID of the previous response to the model. Use this to create
|
|
618
152
|
# multi-turn conversations. Learn more about
|
|
619
153
|
# [conversation state](https://platform.openai.com/docs/guides/conversation-state).
|
|
620
154
|
# Cannot be used in conjunction with `conversation`.
|
|
621
|
-
|
|
155
|
+
sig { returns(T.nilable(String)) }
|
|
156
|
+
attr_accessor :previous_response_id
|
|
622
157
|
|
|
623
158
|
# Reference to a prompt template and its variables.
|
|
624
159
|
# [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
|
|
625
|
-
|
|
160
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsePrompt)) }
|
|
161
|
+
attr_reader :prompt
|
|
162
|
+
|
|
163
|
+
sig { params(prompt: T.nilable(OpenAI::Responses::ResponsePrompt::OrHash)).void }
|
|
164
|
+
attr_writer :prompt
|
|
626
165
|
|
|
627
166
|
# Used by OpenAI to cache responses for similar requests to optimize your cache
|
|
628
167
|
# hit rates. Replaces the `user` field.
|
|
629
168
|
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
|
|
630
|
-
|
|
169
|
+
sig { returns(T.nilable(String)) }
|
|
170
|
+
attr_accessor :prompt_cache_key
|
|
631
171
|
|
|
632
172
|
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
633
173
|
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
@@ -638,7 +178,16 @@ module OpenAI
|
|
|
638
178
|
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
639
179
|
# [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
|
|
640
180
|
# for current details.
|
|
641
|
-
|
|
181
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions)) }
|
|
182
|
+
attr_reader :prompt_cache_options
|
|
183
|
+
|
|
184
|
+
sig {
|
|
185
|
+
params(
|
|
186
|
+
prompt_cache_options: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::OrHash
|
|
187
|
+
)
|
|
188
|
+
.void
|
|
189
|
+
}
|
|
190
|
+
attr_writer :prompt_cache_options
|
|
642
191
|
|
|
643
192
|
# Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
644
193
|
#
|
|
@@ -657,11 +206,18 @@ module OpenAI
|
|
|
657
206
|
# - Organizations without ZDR enabled default to `24h`.
|
|
658
207
|
# - Organizations with ZDR enabled default to `in_memory` when
|
|
659
208
|
# `prompt_cache_retention` is not specified.
|
|
660
|
-
|
|
209
|
+
sig {
|
|
210
|
+
returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::OrSymbol))
|
|
211
|
+
}
|
|
212
|
+
attr_accessor :prompt_cache_retention
|
|
661
213
|
|
|
662
214
|
# Configuration options for
|
|
663
215
|
# [reasoning models](https://platform.openai.com/docs/guides/reasoning).
|
|
664
|
-
|
|
216
|
+
sig { returns(T.nilable(OpenAI::Reasoning)) }
|
|
217
|
+
attr_reader :reasoning
|
|
218
|
+
|
|
219
|
+
sig { params(reasoning: T.nilable(OpenAI::Reasoning::OrHash)).void }
|
|
220
|
+
attr_writer :reasoning
|
|
665
221
|
|
|
666
222
|
# A stable identifier used to help detect users of your application that may be
|
|
667
223
|
# violating OpenAI's usage policies. The IDs should be a string that uniquely
|
|
@@ -669,7 +225,8 @@ module OpenAI
|
|
|
669
225
|
# hashing their username or email address, in order to avoid sending us any
|
|
670
226
|
# identifying information.
|
|
671
227
|
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
672
|
-
|
|
228
|
+
sig { returns(T.nilable(String)) }
|
|
229
|
+
attr_accessor :safety_identifier
|
|
673
230
|
|
|
674
231
|
# Specifies the processing type used for serving the request.
|
|
675
232
|
#
|
|
@@ -695,10 +252,12 @@ module OpenAI
|
|
|
695
252
|
# `service_tier` value based on the processing mode actually used to serve the
|
|
696
253
|
# request. This response value may be different from the value set in the
|
|
697
254
|
# parameter.
|
|
698
|
-
|
|
255
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::OrSymbol)) }
|
|
256
|
+
attr_accessor :service_tier
|
|
699
257
|
|
|
700
258
|
# Whether to store the generated model response for later retrieval via API.
|
|
701
|
-
|
|
259
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
260
|
+
attr_accessor :store
|
|
702
261
|
|
|
703
262
|
# If set to true, the model response data will be streamed to the client as it is
|
|
704
263
|
# generated using
|
|
@@ -706,35 +265,89 @@ module OpenAI
|
|
|
706
265
|
# See the
|
|
707
266
|
# [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
|
|
708
267
|
# for more information.
|
|
709
|
-
|
|
268
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
269
|
+
attr_accessor :stream
|
|
710
270
|
|
|
711
271
|
# The WebSocket lane for this response. Requests with the same `stream_id` are
|
|
712
272
|
# processed FIFO, and events for the response echo the same `stream_id`.
|
|
713
273
|
#
|
|
714
274
|
# `stream_id` controls routing; `previous_response_id` controls conversation
|
|
715
275
|
# lineage, so a new lane can fork from a response created on another lane.
|
|
716
|
-
|
|
276
|
+
sig { returns(T.nilable(String)) }
|
|
277
|
+
attr_reader :stream_id
|
|
278
|
+
|
|
279
|
+
sig { params(stream_id: String).void }
|
|
280
|
+
attr_writer :stream_id
|
|
717
281
|
|
|
718
282
|
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
719
|
-
|
|
283
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::StreamOptions)) }
|
|
284
|
+
attr_reader :stream_options
|
|
285
|
+
|
|
286
|
+
sig {
|
|
287
|
+
params(
|
|
288
|
+
stream_options: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::StreamOptions::OrHash)
|
|
289
|
+
)
|
|
290
|
+
.void
|
|
291
|
+
}
|
|
292
|
+
attr_writer :stream_options
|
|
720
293
|
|
|
721
294
|
# What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
|
|
722
295
|
# make the output more random, while lower values like 0.2 will make it more
|
|
723
296
|
# focused and deterministic. We generally recommend altering this or `top_p` but
|
|
724
297
|
# not both.
|
|
725
|
-
|
|
298
|
+
sig { returns(T.nilable(Float)) }
|
|
299
|
+
attr_accessor :temperature
|
|
726
300
|
|
|
727
301
|
# Configuration options for a text response from the model. Can be plain text or
|
|
728
302
|
# structured JSON data. Learn more:
|
|
729
303
|
#
|
|
730
304
|
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
731
305
|
# - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
|
|
732
|
-
|
|
306
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponseTextConfig)) }
|
|
307
|
+
attr_reader :text
|
|
308
|
+
|
|
309
|
+
sig { params(text: OpenAI::Responses::ResponseTextConfig::OrHash).void }
|
|
310
|
+
attr_writer :text
|
|
733
311
|
|
|
734
312
|
# How the model should select which tool (or tools) to use when generating a
|
|
735
313
|
# response. See the `tools` parameter to see how to specify which tools the model
|
|
736
314
|
# can call.
|
|
737
|
-
|
|
315
|
+
sig {
|
|
316
|
+
returns(
|
|
317
|
+
T.nilable(
|
|
318
|
+
T.any(
|
|
319
|
+
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
320
|
+
OpenAI::Responses::ToolChoiceAllowed,
|
|
321
|
+
OpenAI::Responses::ToolChoiceTypes,
|
|
322
|
+
OpenAI::Responses::ToolChoiceFunction,
|
|
323
|
+
OpenAI::Responses::ToolChoiceMcp,
|
|
324
|
+
OpenAI::Responses::ToolChoiceCustom,
|
|
325
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
326
|
+
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
327
|
+
OpenAI::Responses::ToolChoiceShell
|
|
328
|
+
)
|
|
329
|
+
)
|
|
330
|
+
)
|
|
331
|
+
}
|
|
332
|
+
attr_reader :tool_choice
|
|
333
|
+
|
|
334
|
+
sig {
|
|
335
|
+
params(
|
|
336
|
+
tool_choice: T.any(
|
|
337
|
+
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
338
|
+
OpenAI::Responses::ToolChoiceAllowed::OrHash,
|
|
339
|
+
OpenAI::Responses::ToolChoiceTypes::OrHash,
|
|
340
|
+
OpenAI::Responses::ToolChoiceFunction::OrHash,
|
|
341
|
+
OpenAI::Responses::ToolChoiceMcp::OrHash,
|
|
342
|
+
OpenAI::Responses::ToolChoiceCustom::OrHash,
|
|
343
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam::OrHash,
|
|
344
|
+
OpenAI::Responses::ToolChoiceApplyPatch::OrHash,
|
|
345
|
+
OpenAI::Responses::ToolChoiceShell::OrHash
|
|
346
|
+
)
|
|
347
|
+
)
|
|
348
|
+
.void
|
|
349
|
+
}
|
|
350
|
+
attr_writer :tool_choice
|
|
738
351
|
|
|
739
352
|
# An array of tools the model may call while generating a response. You can
|
|
740
353
|
# specify which tool to use by setting the `tool_choice` parameter.
|
|
@@ -755,19 +368,74 @@ module OpenAI
|
|
|
755
368
|
# Learn more about
|
|
756
369
|
# [function calling](https://platform.openai.com/docs/guides/function-calling).
|
|
757
370
|
# You can also use custom tools to call your own code.
|
|
758
|
-
|
|
371
|
+
sig {
|
|
372
|
+
returns(
|
|
373
|
+
T.nilable(
|
|
374
|
+
T::Array[
|
|
375
|
+
T.any(
|
|
376
|
+
OpenAI::Responses::FunctionTool,
|
|
377
|
+
OpenAI::Responses::FileSearchTool,
|
|
378
|
+
OpenAI::Responses::ComputerTool,
|
|
379
|
+
OpenAI::Responses::ComputerUsePreviewTool,
|
|
380
|
+
OpenAI::Responses::Tool::Mcp,
|
|
381
|
+
OpenAI::Responses::Tool::CodeInterpreter,
|
|
382
|
+
OpenAI::Responses::Tool::ProgrammaticToolCalling,
|
|
383
|
+
OpenAI::Responses::Tool::ImageGeneration,
|
|
384
|
+
OpenAI::Responses::Tool::LocalShell,
|
|
385
|
+
OpenAI::Responses::FunctionShellTool,
|
|
386
|
+
OpenAI::Responses::CustomTool,
|
|
387
|
+
OpenAI::Responses::NamespaceTool,
|
|
388
|
+
OpenAI::Responses::ToolSearchTool,
|
|
389
|
+
OpenAI::Responses::ApplyPatchTool,
|
|
390
|
+
OpenAI::Responses::WebSearchTool,
|
|
391
|
+
OpenAI::Responses::WebSearchPreviewTool
|
|
392
|
+
)
|
|
393
|
+
]
|
|
394
|
+
)
|
|
395
|
+
)
|
|
396
|
+
}
|
|
397
|
+
attr_reader :tools
|
|
398
|
+
|
|
399
|
+
sig {
|
|
400
|
+
params(
|
|
401
|
+
tools: T::Array[
|
|
402
|
+
T.any(
|
|
403
|
+
OpenAI::Responses::FunctionTool::OrHash,
|
|
404
|
+
OpenAI::Responses::FileSearchTool::OrHash,
|
|
405
|
+
OpenAI::Responses::ComputerTool::OrHash,
|
|
406
|
+
OpenAI::Responses::ComputerUsePreviewTool::OrHash,
|
|
407
|
+
OpenAI::Responses::Tool::Mcp::OrHash,
|
|
408
|
+
OpenAI::Responses::Tool::CodeInterpreter::OrHash,
|
|
409
|
+
OpenAI::Responses::Tool::ProgrammaticToolCalling::OrHash,
|
|
410
|
+
OpenAI::Responses::Tool::ImageGeneration::OrHash,
|
|
411
|
+
OpenAI::Responses::Tool::LocalShell::OrHash,
|
|
412
|
+
OpenAI::Responses::FunctionShellTool::OrHash,
|
|
413
|
+
OpenAI::Responses::CustomTool::OrHash,
|
|
414
|
+
OpenAI::Responses::NamespaceTool::OrHash,
|
|
415
|
+
OpenAI::Responses::ToolSearchTool::OrHash,
|
|
416
|
+
OpenAI::Responses::ApplyPatchTool::OrHash,
|
|
417
|
+
OpenAI::Responses::WebSearchTool::OrHash,
|
|
418
|
+
OpenAI::Responses::WebSearchPreviewTool::OrHash
|
|
419
|
+
)
|
|
420
|
+
]
|
|
421
|
+
)
|
|
422
|
+
.void
|
|
423
|
+
}
|
|
424
|
+
attr_writer :tools
|
|
759
425
|
|
|
760
426
|
# An integer between 0 and 20 specifying the maximum number of most likely tokens
|
|
761
427
|
# to return at each token position, each with an associated log probability. In
|
|
762
428
|
# some cases, the number of returned tokens may be fewer than requested.
|
|
763
|
-
|
|
429
|
+
sig { returns(T.nilable(Integer)) }
|
|
430
|
+
attr_accessor :top_logprobs
|
|
764
431
|
|
|
765
432
|
# An alternative to sampling with temperature, called nucleus sampling, where the
|
|
766
433
|
# model considers the results of the tokens with top_p probability mass. So 0.1
|
|
767
434
|
# means only the tokens comprising the top 10% probability mass are considered.
|
|
768
435
|
#
|
|
769
436
|
# We generally recommend altering this or `temperature` but not both.
|
|
770
|
-
|
|
437
|
+
sig { returns(T.nilable(Float)) }
|
|
438
|
+
attr_accessor :top_p
|
|
771
439
|
|
|
772
440
|
# The truncation strategy to use for the model response.
|
|
773
441
|
#
|
|
@@ -776,452 +444,950 @@ module OpenAI
|
|
|
776
444
|
# items from the beginning of the conversation.
|
|
777
445
|
# - `disabled` (default): If the input size will exceed the context window size
|
|
778
446
|
# for a model, the request will fail with a 400 error.
|
|
779
|
-
|
|
447
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::OrSymbol)) }
|
|
448
|
+
attr_accessor :truncation
|
|
780
449
|
|
|
781
450
|
# This field is being replaced by `safety_identifier` and `prompt_cache_key`. Use
|
|
782
451
|
# `prompt_cache_key` instead to maintain caching optimizations. A stable
|
|
783
452
|
# identifier for your end-users. Used to boost cache hit rates by better bucketing
|
|
784
453
|
# similar requests and to help OpenAI detect and prevent abuse.
|
|
785
454
|
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
786
|
-
|
|
455
|
+
sig { returns(T.nilable(String)) }
|
|
456
|
+
attr_reader :user
|
|
787
457
|
|
|
788
|
-
|
|
458
|
+
sig { params(user: String).void }
|
|
459
|
+
attr_writer :user
|
|
789
460
|
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
461
|
+
# Client event for creating a response over a persistent WebSocket connection.
|
|
462
|
+
# This payload uses the same top-level fields as `POST /v1/responses`, plus
|
|
463
|
+
# WebSocket-only envelope metadata.
|
|
464
|
+
#
|
|
465
|
+
# Notes:
|
|
466
|
+
#
|
|
467
|
+
# - `stream` is implicit over WebSocket and should not be sent.
|
|
468
|
+
# - `background` is not supported over WebSocket.
|
|
469
|
+
# - `stream_id` is WebSocket-only and is not part of `POST /v1/responses`.
|
|
470
|
+
sig do
|
|
471
|
+
params(
|
|
793
472
|
|
|
794
|
-
sig do
|
|
795
|
-
override.returns(
|
|
796
|
-
{
|
|
797
|
-
type: Symbol,
|
|
798
473
|
background: T.nilable(T::Boolean),
|
|
799
|
-
|
|
800
|
-
|
|
474
|
+
|
|
475
|
+
context_management: T.nilable(
|
|
476
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ContextManagement::OrHash]
|
|
477
|
+
),
|
|
478
|
+
|
|
479
|
+
conversation: T.nilable(T.any(String, OpenAI::Responses::ResponseConversationParam::OrHash)),
|
|
480
|
+
|
|
801
481
|
include: T.nilable(T::Array[OpenAI::Responses::ResponseIncludable::OrSymbol]),
|
|
802
|
-
|
|
482
|
+
|
|
483
|
+
input: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Input::Variants,
|
|
484
|
+
|
|
803
485
|
instructions: T.nilable(String),
|
|
486
|
+
|
|
804
487
|
max_output_tokens: T.nilable(Integer),
|
|
488
|
+
|
|
805
489
|
max_tool_calls: T.nilable(Integer),
|
|
490
|
+
|
|
806
491
|
metadata: T.nilable(T::Hash[Symbol, String]),
|
|
492
|
+
|
|
807
493
|
model: T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol),
|
|
808
|
-
|
|
494
|
+
|
|
495
|
+
moderation: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::OrHash),
|
|
496
|
+
|
|
809
497
|
parallel_tool_calls: T.nilable(T::Boolean),
|
|
498
|
+
|
|
810
499
|
previous_response_id: T.nilable(String),
|
|
811
|
-
|
|
500
|
+
|
|
501
|
+
prompt: T.nilable(OpenAI::Responses::ResponsePrompt::OrHash),
|
|
502
|
+
|
|
812
503
|
prompt_cache_key: T.nilable(String),
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
504
|
+
|
|
505
|
+
prompt_cache_options: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::OrHash,
|
|
506
|
+
|
|
507
|
+
prompt_cache_retention: T.nilable(
|
|
508
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::OrSymbol
|
|
509
|
+
),
|
|
510
|
+
|
|
511
|
+
reasoning: T.nilable(OpenAI::Reasoning::OrHash),
|
|
512
|
+
|
|
816
513
|
safety_identifier: T.nilable(String),
|
|
817
|
-
|
|
514
|
+
|
|
515
|
+
service_tier: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::OrSymbol),
|
|
516
|
+
|
|
818
517
|
store: T.nilable(T::Boolean),
|
|
518
|
+
|
|
819
519
|
stream: T.nilable(T::Boolean),
|
|
520
|
+
|
|
820
521
|
stream_id: String,
|
|
821
|
-
|
|
522
|
+
|
|
523
|
+
stream_options: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::StreamOptions::OrHash),
|
|
524
|
+
|
|
822
525
|
temperature: T.nilable(Float),
|
|
823
|
-
|
|
526
|
+
|
|
527
|
+
text: OpenAI::Responses::ResponseTextConfig::OrHash,
|
|
528
|
+
|
|
824
529
|
tool_choice: T.any(
|
|
825
530
|
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
826
|
-
OpenAI::Responses::ToolChoiceAllowed,
|
|
827
|
-
OpenAI::Responses::ToolChoiceTypes,
|
|
828
|
-
OpenAI::Responses::ToolChoiceFunction,
|
|
829
|
-
OpenAI::Responses::ToolChoiceMcp,
|
|
830
|
-
OpenAI::Responses::ToolChoiceCustom,
|
|
831
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
832
|
-
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
833
|
-
OpenAI::Responses::ToolChoiceShell
|
|
531
|
+
OpenAI::Responses::ToolChoiceAllowed::OrHash,
|
|
532
|
+
OpenAI::Responses::ToolChoiceTypes::OrHash,
|
|
533
|
+
OpenAI::Responses::ToolChoiceFunction::OrHash,
|
|
534
|
+
OpenAI::Responses::ToolChoiceMcp::OrHash,
|
|
535
|
+
OpenAI::Responses::ToolChoiceCustom::OrHash,
|
|
536
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam::OrHash,
|
|
537
|
+
OpenAI::Responses::ToolChoiceApplyPatch::OrHash,
|
|
538
|
+
OpenAI::Responses::ToolChoiceShell::OrHash
|
|
834
539
|
),
|
|
540
|
+
|
|
835
541
|
tools: T::Array[
|
|
836
542
|
T.any(
|
|
837
|
-
OpenAI::Responses::FunctionTool,
|
|
838
|
-
OpenAI::Responses::FileSearchTool,
|
|
839
|
-
OpenAI::Responses::ComputerTool,
|
|
840
|
-
OpenAI::Responses::ComputerUsePreviewTool,
|
|
841
|
-
OpenAI::Responses::Tool::Mcp,
|
|
842
|
-
OpenAI::Responses::Tool::CodeInterpreter,
|
|
843
|
-
OpenAI::Responses::Tool::ProgrammaticToolCalling,
|
|
844
|
-
OpenAI::Responses::Tool::ImageGeneration,
|
|
845
|
-
OpenAI::Responses::Tool::LocalShell,
|
|
846
|
-
OpenAI::Responses::FunctionShellTool,
|
|
847
|
-
OpenAI::Responses::CustomTool,
|
|
848
|
-
OpenAI::Responses::NamespaceTool,
|
|
849
|
-
OpenAI::Responses::ToolSearchTool,
|
|
850
|
-
OpenAI::Responses::ApplyPatchTool,
|
|
851
|
-
OpenAI::Responses::WebSearchTool,
|
|
852
|
-
OpenAI::Responses::WebSearchPreviewTool
|
|
543
|
+
OpenAI::Responses::FunctionTool::OrHash,
|
|
544
|
+
OpenAI::Responses::FileSearchTool::OrHash,
|
|
545
|
+
OpenAI::Responses::ComputerTool::OrHash,
|
|
546
|
+
OpenAI::Responses::ComputerUsePreviewTool::OrHash,
|
|
547
|
+
OpenAI::Responses::Tool::Mcp::OrHash,
|
|
548
|
+
OpenAI::Responses::Tool::CodeInterpreter::OrHash,
|
|
549
|
+
OpenAI::Responses::Tool::ProgrammaticToolCalling::OrHash,
|
|
550
|
+
OpenAI::Responses::Tool::ImageGeneration::OrHash,
|
|
551
|
+
OpenAI::Responses::Tool::LocalShell::OrHash,
|
|
552
|
+
OpenAI::Responses::FunctionShellTool::OrHash,
|
|
553
|
+
OpenAI::Responses::CustomTool::OrHash,
|
|
554
|
+
OpenAI::Responses::NamespaceTool::OrHash,
|
|
555
|
+
OpenAI::Responses::ToolSearchTool::OrHash,
|
|
556
|
+
OpenAI::Responses::ApplyPatchTool::OrHash,
|
|
557
|
+
OpenAI::Responses::WebSearchTool::OrHash,
|
|
558
|
+
OpenAI::Responses::WebSearchPreviewTool::OrHash
|
|
853
559
|
)
|
|
854
560
|
],
|
|
855
|
-
top_logprobs: T.nilable(Integer),
|
|
856
|
-
top_p: T.nilable(Float),
|
|
857
|
-
truncation: T.nilable(OpenAI::Responses::ResponsesClientEvent::Truncation::OrSymbol),
|
|
858
|
-
user: String
|
|
859
|
-
}
|
|
860
|
-
)
|
|
861
|
-
end
|
|
862
|
-
def to_hash
|
|
863
|
-
end
|
|
864
|
-
|
|
865
|
-
class ContextManagement < OpenAI::Internal::Type::BaseModel
|
|
866
|
-
OrHash = T.type_alias do
|
|
867
|
-
T.any(
|
|
868
|
-
OpenAI::Responses::ResponsesClientEvent::ContextManagement,
|
|
869
|
-
OpenAI::Internal::AnyHash
|
|
870
|
-
)
|
|
871
|
-
end
|
|
872
561
|
|
|
873
|
-
|
|
874
|
-
sig { returns(String) }
|
|
875
|
-
attr_accessor :type
|
|
562
|
+
top_logprobs: T.nilable(Integer),
|
|
876
563
|
|
|
877
|
-
|
|
878
|
-
sig { returns(T.nilable(Integer)) }
|
|
879
|
-
attr_accessor :compact_threshold
|
|
564
|
+
top_p: T.nilable(Float),
|
|
880
565
|
|
|
881
|
-
|
|
882
|
-
params(
|
|
566
|
+
truncation: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::OrSymbol),
|
|
883
567
|
|
|
884
|
-
|
|
568
|
+
user: String,
|
|
885
569
|
|
|
886
|
-
|
|
570
|
+
type: Symbol
|
|
887
571
|
)
|
|
888
572
|
.returns(T.attached_class)
|
|
889
573
|
end
|
|
890
574
|
def self.new(
|
|
891
575
|
|
|
892
|
-
#
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
576
|
+
# Whether to run the model response in the background.
|
|
577
|
+
# [Learn more](https://platform.openai.com/docs/guides/background).
|
|
578
|
+
background: nil,
|
|
579
|
+
|
|
580
|
+
# Context management configuration for this request.
|
|
581
|
+
context_management: nil,
|
|
582
|
+
|
|
583
|
+
# The conversation that this response belongs to. Items from this conversation are
|
|
584
|
+
# prepended to `input_items` for this response request. Input items and output
|
|
585
|
+
# items from this response are automatically added to this conversation after this
|
|
586
|
+
# response completes.
|
|
587
|
+
conversation: nil,
|
|
588
|
+
|
|
589
|
+
# Specify additional output data to include in the model response. Currently
|
|
590
|
+
# supported values are:
|
|
591
|
+
#
|
|
592
|
+
# - `web_search_call.action.sources`: Include the sources of the web search tool
|
|
593
|
+
# call.
|
|
594
|
+
# - `code_interpreter_call.outputs`: Includes the outputs of python code execution
|
|
595
|
+
# in code interpreter tool call items.
|
|
596
|
+
# - `computer_call_output.output.image_url`: Include image urls from the computer
|
|
597
|
+
# call output.
|
|
598
|
+
# - `file_search_call.results`: Include the search results of the file search tool
|
|
599
|
+
# call.
|
|
600
|
+
# - `message.input_image.image_url`: Include image urls from the input message.
|
|
601
|
+
# - `message.output_text.logprobs`: Include logprobs with assistant messages.
|
|
602
|
+
# - `reasoning.encrypted_content`: Includes an encrypted version of reasoning
|
|
603
|
+
# tokens in reasoning item outputs. This enables reasoning items to be used in
|
|
604
|
+
# multi-turn conversations when using the Responses API statelessly (like when
|
|
605
|
+
# the `store` parameter is set to `false`, or when an organization is enrolled
|
|
606
|
+
# in the zero data retention program).
|
|
607
|
+
include: nil,
|
|
608
|
+
|
|
609
|
+
# Text, image, or file inputs to the model, used to generate a response.
|
|
610
|
+
#
|
|
611
|
+
# Learn more:
|
|
612
|
+
#
|
|
613
|
+
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
614
|
+
# - [Image inputs](https://platform.openai.com/docs/guides/images)
|
|
615
|
+
# - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
|
|
616
|
+
# - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
|
|
617
|
+
# - [Function calling](https://platform.openai.com/docs/guides/function-calling)
|
|
618
|
+
input: nil,
|
|
619
|
+
|
|
620
|
+
# A system (or developer) message inserted into the model's context.
|
|
621
|
+
#
|
|
622
|
+
# When using along with `previous_response_id`, the instructions from a previous
|
|
623
|
+
# response will not be carried over to the next response. This makes it simple to
|
|
624
|
+
# swap out system (or developer) messages in new responses.
|
|
625
|
+
instructions: nil,
|
|
626
|
+
|
|
627
|
+
# An upper bound for the number of tokens that can be generated for a response,
|
|
628
|
+
# including visible output tokens and
|
|
629
|
+
# [reasoning tokens](https://platform.openai.com/docs/guides/reasoning).
|
|
630
|
+
max_output_tokens: nil,
|
|
631
|
+
|
|
632
|
+
# The maximum number of total calls to built-in tools that can be processed in a
|
|
633
|
+
# response. This maximum number applies across all built-in tool calls, not per
|
|
634
|
+
# individual tool. Any further attempts to call a tool by the model will be
|
|
635
|
+
# ignored.
|
|
636
|
+
max_tool_calls: nil,
|
|
637
|
+
|
|
638
|
+
# Set of 16 key-value pairs that can be attached to an object. This can be useful
|
|
639
|
+
# for storing additional information about the object in a structured format, and
|
|
640
|
+
# querying for objects via API or the dashboard.
|
|
641
|
+
#
|
|
642
|
+
# Keys are strings with a maximum length of 64 characters. Values are strings with
|
|
643
|
+
# a maximum length of 512 characters.
|
|
644
|
+
metadata: nil,
|
|
645
|
+
|
|
646
|
+
# Model ID used to generate the response, like `gpt-6-astra`. OpenAI offers a wide
|
|
647
|
+
# range of models with different capabilities, performance characteristics, and
|
|
648
|
+
# price points. Refer to the
|
|
649
|
+
# [model guide](https://platform.openai.com/docs/models) to browse and compare
|
|
650
|
+
# available models.
|
|
651
|
+
model: nil,
|
|
652
|
+
|
|
653
|
+
# Configuration for running moderation on the input and output of this response.
|
|
654
|
+
moderation: nil,
|
|
655
|
+
|
|
656
|
+
# Whether to allow the model to run tool calls in parallel.
|
|
657
|
+
parallel_tool_calls: nil,
|
|
658
|
+
|
|
659
|
+
# The unique ID of the previous response to the model. Use this to create
|
|
660
|
+
# multi-turn conversations. Learn more about
|
|
661
|
+
# [conversation state](https://platform.openai.com/docs/guides/conversation-state).
|
|
662
|
+
# Cannot be used in conjunction with `conversation`.
|
|
663
|
+
previous_response_id: nil,
|
|
664
|
+
|
|
665
|
+
# Reference to a prompt template and its variables.
|
|
666
|
+
# [Learn more](https://platform.openai.com/docs/guides/text?api-mode=responses#reusable-prompts).
|
|
667
|
+
prompt: nil,
|
|
668
|
+
|
|
669
|
+
# Used by OpenAI to cache responses for similar requests to optimize your cache
|
|
670
|
+
# hit rates. Replaces the `user` field.
|
|
671
|
+
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching).
|
|
672
|
+
prompt_cache_key: nil,
|
|
673
|
+
|
|
674
|
+
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
675
|
+
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
676
|
+
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
677
|
+
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
678
|
+
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
679
|
+
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
680
|
+
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
681
|
+
# [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
|
|
682
|
+
# for current details.
|
|
683
|
+
prompt_cache_options: nil,
|
|
684
|
+
|
|
685
|
+
# Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
686
|
+
#
|
|
687
|
+
# The retention policy for the prompt cache. Set to `24h` to enable extended
|
|
688
|
+
# prompt caching, which keeps cached prefixes active for longer, up to a maximum
|
|
689
|
+
# of 24 hours.
|
|
690
|
+
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
|
|
691
|
+
# This field expresses a maximum retention policy, while
|
|
692
|
+
# `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
|
|
693
|
+
# are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
|
|
694
|
+
# models, only `24h` is supported.
|
|
695
|
+
#
|
|
696
|
+
# For older models that support both `in_memory` and `24h`, the default depends on
|
|
697
|
+
# your organization's data retention policy:
|
|
698
|
+
#
|
|
699
|
+
# - Organizations without ZDR enabled default to `24h`.
|
|
700
|
+
# - Organizations with ZDR enabled default to `in_memory` when
|
|
701
|
+
# `prompt_cache_retention` is not specified.
|
|
702
|
+
prompt_cache_retention: nil,
|
|
703
|
+
|
|
704
|
+
# Configuration options for
|
|
705
|
+
# [reasoning models](https://platform.openai.com/docs/guides/reasoning).
|
|
706
|
+
reasoning: nil,
|
|
707
|
+
|
|
708
|
+
# A stable identifier used to help detect users of your application that may be
|
|
709
|
+
# violating OpenAI's usage policies. The IDs should be a string that uniquely
|
|
710
|
+
# identifies each user, with a maximum length of 64 characters. We recommend
|
|
711
|
+
# hashing their username or email address, in order to avoid sending us any
|
|
712
|
+
# identifying information.
|
|
713
|
+
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
714
|
+
safety_identifier: nil,
|
|
715
|
+
|
|
716
|
+
# Specifies the processing type used for serving the request.
|
|
717
|
+
#
|
|
718
|
+
# - If set to 'auto', then the request will be processed with the service tier
|
|
719
|
+
# configured in the Project settings. Unless otherwise configured, the Project
|
|
720
|
+
# will use 'default'.
|
|
721
|
+
# - If set to 'default', then the request will be processed with the standard
|
|
722
|
+
# pricing and performance for the selected model.
|
|
723
|
+
# - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
|
|
724
|
+
# then the request will be processed with the Flex Processing service tier.
|
|
725
|
+
# - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
|
|
726
|
+
# include the `service_tier=fast` or `service_tier=priority` parameter for
|
|
727
|
+
# Responses or Chat Completions. The response will show `service_tier=priority`
|
|
728
|
+
# regardless of if you specify `service_tier=fast` or `priority` in your
|
|
729
|
+
# request.
|
|
730
|
+
# - If set to 'ultrafast', then the request will be processed with the
|
|
731
|
+
# access-controlled Ultrafast Processing service tier. This tier is currently
|
|
732
|
+
# available for `gpt-5.6-sol`; a response served through it will show
|
|
733
|
+
# `service_tier=ultrafast`.
|
|
734
|
+
# - When not set, the default behavior is 'auto'.
|
|
735
|
+
#
|
|
736
|
+
# When the `service_tier` parameter is set, the response body will include the
|
|
737
|
+
# `service_tier` value based on the processing mode actually used to serve the
|
|
738
|
+
# request. This response value may be different from the value set in the
|
|
739
|
+
# parameter.
|
|
740
|
+
service_tier: nil,
|
|
741
|
+
|
|
742
|
+
# Whether to store the generated model response for later retrieval via API.
|
|
743
|
+
store: nil,
|
|
744
|
+
|
|
745
|
+
# If set to true, the model response data will be streamed to the client as it is
|
|
746
|
+
# generated using
|
|
747
|
+
# [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
|
|
748
|
+
# See the
|
|
749
|
+
# [Streaming section below](https://platform.openai.com/docs/api-reference/responses-streaming)
|
|
750
|
+
# for more information.
|
|
751
|
+
stream: nil,
|
|
752
|
+
|
|
753
|
+
# The WebSocket lane for this response. Requests with the same `stream_id` are
|
|
754
|
+
# processed FIFO, and events for the response echo the same `stream_id`.
|
|
755
|
+
#
|
|
756
|
+
# `stream_id` controls routing; `previous_response_id` controls conversation
|
|
757
|
+
# lineage, so a new lane can fork from a response created on another lane.
|
|
758
|
+
stream_id: nil,
|
|
759
|
+
|
|
760
|
+
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
761
|
+
stream_options: nil,
|
|
762
|
+
|
|
763
|
+
# What sampling temperature to use, between 0 and 2. Higher values like 0.8 will
|
|
764
|
+
# make the output more random, while lower values like 0.2 will make it more
|
|
765
|
+
# focused and deterministic. We generally recommend altering this or `top_p` but
|
|
766
|
+
# not both.
|
|
767
|
+
temperature: nil,
|
|
768
|
+
|
|
769
|
+
# Configuration options for a text response from the model. Can be plain text or
|
|
770
|
+
# structured JSON data. Learn more:
|
|
771
|
+
#
|
|
772
|
+
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
773
|
+
# - [Structured Outputs](https://platform.openai.com/docs/guides/structured-outputs)
|
|
774
|
+
text: nil,
|
|
775
|
+
|
|
776
|
+
# How the model should select which tool (or tools) to use when generating a
|
|
777
|
+
# response. See the `tools` parameter to see how to specify which tools the model
|
|
778
|
+
# can call.
|
|
779
|
+
tool_choice: nil,
|
|
780
|
+
|
|
781
|
+
# An array of tools the model may call while generating a response. You can
|
|
782
|
+
# specify which tool to use by setting the `tool_choice` parameter.
|
|
783
|
+
#
|
|
784
|
+
# We support the following categories of tools:
|
|
785
|
+
#
|
|
786
|
+
# - **Built-in tools**: Tools that are provided by OpenAI that extend the model's
|
|
787
|
+
# capabilities, like
|
|
788
|
+
# [web search](https://platform.openai.com/docs/guides/tools-web-search) or
|
|
789
|
+
# [file search](https://platform.openai.com/docs/guides/tools-file-search).
|
|
790
|
+
# Learn more about
|
|
791
|
+
# [built-in tools](https://platform.openai.com/docs/guides/tools).
|
|
792
|
+
# - **MCP Tools**: Integrations with third-party systems via custom MCP servers or
|
|
793
|
+
# predefined connectors such as Google Drive and SharePoint. Learn more about
|
|
794
|
+
# [MCP Tools](https://platform.openai.com/docs/guides/tools-connectors-mcp).
|
|
795
|
+
# - **Function calls (custom tools)**: Functions that are defined by you, enabling
|
|
796
|
+
# the model to call your own code with strongly typed arguments and outputs.
|
|
797
|
+
# Learn more about
|
|
798
|
+
# [function calling](https://platform.openai.com/docs/guides/function-calling).
|
|
799
|
+
# You can also use custom tools to call your own code.
|
|
800
|
+
tools: nil,
|
|
801
|
+
|
|
802
|
+
# An integer between 0 and 20 specifying the maximum number of most likely tokens
|
|
803
|
+
# to return at each token position, each with an associated log probability. In
|
|
804
|
+
# some cases, the number of returned tokens may be fewer than requested.
|
|
805
|
+
top_logprobs: nil,
|
|
806
|
+
|
|
807
|
+
# An alternative to sampling with temperature, called nucleus sampling, where the
|
|
808
|
+
# model considers the results of the tokens with top_p probability mass. So 0.1
|
|
809
|
+
# means only the tokens comprising the top 10% probability mass are considered.
|
|
810
|
+
#
|
|
811
|
+
# We generally recommend altering this or `temperature` but not both.
|
|
812
|
+
top_p: nil,
|
|
813
|
+
|
|
814
|
+
# The truncation strategy to use for the model response.
|
|
815
|
+
#
|
|
816
|
+
# - `auto`: If the input to this Response exceeds the model's context window size,
|
|
817
|
+
# the model will truncate the response to fit the context window by dropping
|
|
818
|
+
# items from the beginning of the conversation.
|
|
819
|
+
# - `disabled` (default): If the input size will exceed the context window size
|
|
820
|
+
# for a model, the request will fail with a 400 error.
|
|
821
|
+
truncation: nil,
|
|
822
|
+
|
|
823
|
+
# This field is being replaced by `safety_identifier` and `prompt_cache_key`. Use
|
|
824
|
+
# `prompt_cache_key` instead to maintain caching optimizations. A stable
|
|
825
|
+
# identifier for your end-users. Used to boost cache hit rates by better bucketing
|
|
826
|
+
# similar requests and to help OpenAI detect and prevent abuse.
|
|
827
|
+
# [Learn more](https://platform.openai.com/docs/guides/safety-best-practices#safety-identifiers).
|
|
828
|
+
user: nil,
|
|
829
|
+
|
|
830
|
+
# The type of the client event. Always `response.create`.
|
|
831
|
+
|
|
832
|
+
type: :"response.create"
|
|
898
833
|
)
|
|
899
834
|
end
|
|
900
835
|
|
|
901
836
|
sig do
|
|
902
837
|
override.returns(
|
|
903
|
-
{
|
|
838
|
+
{
|
|
839
|
+
type: Symbol,
|
|
840
|
+
background: T.nilable(T::Boolean),
|
|
841
|
+
context_management: T.nilable(
|
|
842
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ContextManagement]
|
|
843
|
+
),
|
|
844
|
+
conversation: T.nilable(T.any(String, OpenAI::Responses::ResponseConversationParam)),
|
|
845
|
+
include: T.nilable(T::Array[OpenAI::Responses::ResponseIncludable::OrSymbol]),
|
|
846
|
+
input: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Input::Variants),
|
|
847
|
+
instructions: T.nilable(String),
|
|
848
|
+
max_output_tokens: T.nilable(Integer),
|
|
849
|
+
max_tool_calls: T.nilable(Integer),
|
|
850
|
+
metadata: T.nilable(T::Hash[Symbol, String]),
|
|
851
|
+
model: T.nilable(
|
|
852
|
+
T.any(String, OpenAI::ChatModel::OrSymbol, OpenAI::ResponsesModel::ResponsesOnlyModel::OrSymbol)
|
|
853
|
+
),
|
|
854
|
+
moderation: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation),
|
|
855
|
+
parallel_tool_calls: T.nilable(T::Boolean),
|
|
856
|
+
previous_response_id: T.nilable(String),
|
|
857
|
+
prompt: T.nilable(OpenAI::Responses::ResponsePrompt),
|
|
858
|
+
prompt_cache_key: T.nilable(String),
|
|
859
|
+
prompt_cache_options: T.nilable(
|
|
860
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions
|
|
861
|
+
),
|
|
862
|
+
prompt_cache_retention: T.nilable(
|
|
863
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::OrSymbol
|
|
864
|
+
),
|
|
865
|
+
reasoning: T.nilable(OpenAI::Reasoning),
|
|
866
|
+
safety_identifier: T.nilable(String),
|
|
867
|
+
service_tier: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::OrSymbol),
|
|
868
|
+
store: T.nilable(T::Boolean),
|
|
869
|
+
stream: T.nilable(T::Boolean),
|
|
870
|
+
stream_id: T.nilable(String),
|
|
871
|
+
stream_options: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::StreamOptions),
|
|
872
|
+
temperature: T.nilable(Float),
|
|
873
|
+
text: T.nilable(OpenAI::Responses::ResponseTextConfig),
|
|
874
|
+
tool_choice: T.nilable(
|
|
875
|
+
T.any(
|
|
876
|
+
OpenAI::Responses::ToolChoiceOptions::OrSymbol,
|
|
877
|
+
OpenAI::Responses::ToolChoiceAllowed,
|
|
878
|
+
OpenAI::Responses::ToolChoiceTypes,
|
|
879
|
+
OpenAI::Responses::ToolChoiceFunction,
|
|
880
|
+
OpenAI::Responses::ToolChoiceMcp,
|
|
881
|
+
OpenAI::Responses::ToolChoiceCustom,
|
|
882
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
883
|
+
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
884
|
+
OpenAI::Responses::ToolChoiceShell
|
|
885
|
+
)
|
|
886
|
+
),
|
|
887
|
+
tools: T.nilable(
|
|
888
|
+
T::Array[
|
|
889
|
+
T.any(
|
|
890
|
+
OpenAI::Responses::FunctionTool,
|
|
891
|
+
OpenAI::Responses::FileSearchTool,
|
|
892
|
+
OpenAI::Responses::ComputerTool,
|
|
893
|
+
OpenAI::Responses::ComputerUsePreviewTool,
|
|
894
|
+
OpenAI::Responses::Tool::Mcp,
|
|
895
|
+
OpenAI::Responses::Tool::CodeInterpreter,
|
|
896
|
+
OpenAI::Responses::Tool::ProgrammaticToolCalling,
|
|
897
|
+
OpenAI::Responses::Tool::ImageGeneration,
|
|
898
|
+
OpenAI::Responses::Tool::LocalShell,
|
|
899
|
+
OpenAI::Responses::FunctionShellTool,
|
|
900
|
+
OpenAI::Responses::CustomTool,
|
|
901
|
+
OpenAI::Responses::NamespaceTool,
|
|
902
|
+
OpenAI::Responses::ToolSearchTool,
|
|
903
|
+
OpenAI::Responses::ApplyPatchTool,
|
|
904
|
+
OpenAI::Responses::WebSearchTool,
|
|
905
|
+
OpenAI::Responses::WebSearchPreviewTool
|
|
906
|
+
)
|
|
907
|
+
]
|
|
908
|
+
),
|
|
909
|
+
top_logprobs: T.nilable(Integer),
|
|
910
|
+
top_p: T.nilable(Float),
|
|
911
|
+
truncation: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::OrSymbol),
|
|
912
|
+
user: T.nilable(String)
|
|
913
|
+
}
|
|
904
914
|
)
|
|
905
915
|
end
|
|
906
916
|
def to_hash
|
|
907
917
|
end
|
|
908
918
|
|
|
909
|
-
|
|
919
|
+
class ContextManagement < OpenAI::Internal::Type::BaseModel
|
|
920
|
+
OrHash = T.type_alias do
|
|
921
|
+
T.any(
|
|
922
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ContextManagement,
|
|
923
|
+
OpenAI::Internal::AnyHash
|
|
924
|
+
)
|
|
925
|
+
end
|
|
910
926
|
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
# response completes.
|
|
915
|
-
module Conversation
|
|
916
|
-
extend OpenAI::Internal::Type::Union
|
|
927
|
+
# The context management entry type. Currently only 'compaction' is supported.
|
|
928
|
+
sig { returns(String) }
|
|
929
|
+
attr_accessor :type
|
|
917
930
|
|
|
918
|
-
|
|
931
|
+
# Token threshold at which compaction should be triggered for this entry.
|
|
932
|
+
sig { returns(T.nilable(Integer)) }
|
|
933
|
+
attr_accessor :compact_threshold
|
|
919
934
|
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
end
|
|
935
|
+
sig do
|
|
936
|
+
params(
|
|
923
937
|
|
|
924
|
-
|
|
938
|
+
type: String,
|
|
925
939
|
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
# - [Image inputs](https://platform.openai.com/docs/guides/images)
|
|
932
|
-
# - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
|
|
933
|
-
# - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
|
|
934
|
-
# - [Function calling](https://platform.openai.com/docs/guides/function-calling)
|
|
935
|
-
module Input
|
|
936
|
-
extend OpenAI::Internal::Type::Union
|
|
937
|
-
|
|
938
|
-
Variants = T.type_alias { T.any(String, T::Array[OpenAI::Responses::ResponseInputItem::Variants]) }
|
|
939
|
-
|
|
940
|
-
sig { override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::Input::Variants]) }
|
|
941
|
-
def self.variants
|
|
942
|
-
end
|
|
940
|
+
compact_threshold: T.nilable(Integer)
|
|
941
|
+
)
|
|
942
|
+
.returns(T.attached_class)
|
|
943
|
+
end
|
|
944
|
+
def self.new(
|
|
943
945
|
|
|
944
|
-
|
|
946
|
+
# The context management entry type. Currently only 'compaction' is supported.
|
|
947
|
+
type:,
|
|
945
948
|
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
OpenAI::Responses::ResponsesClientEvent::Moderation,
|
|
950
|
-
OpenAI::Internal::AnyHash
|
|
949
|
+
# Token threshold at which compaction should be triggered for this entry.
|
|
950
|
+
|
|
951
|
+
compact_threshold: nil
|
|
951
952
|
)
|
|
952
|
-
|
|
953
|
+
end
|
|
953
954
|
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
955
|
+
sig do
|
|
956
|
+
override.returns(
|
|
957
|
+
{type: String, compact_threshold: T.nilable(Integer)}
|
|
958
|
+
)
|
|
959
|
+
end
|
|
960
|
+
def to_hash
|
|
961
|
+
end
|
|
958
962
|
|
|
959
|
-
|
|
960
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy)) }
|
|
961
|
-
attr_reader :policy
|
|
963
|
+
end
|
|
962
964
|
|
|
963
|
-
|
|
964
|
-
|
|
965
|
+
# The conversation that this response belongs to. Items from this conversation are
|
|
966
|
+
# prepended to `input_items` for this response request. Input items and output
|
|
967
|
+
# items from this response are automatically added to this conversation after this
|
|
968
|
+
# response completes.
|
|
969
|
+
module Conversation
|
|
970
|
+
extend OpenAI::Internal::Type::Union
|
|
965
971
|
|
|
966
|
-
|
|
967
|
-
sig do
|
|
968
|
-
params(
|
|
972
|
+
Variants = T.type_alias { T.any(String, OpenAI::Responses::ResponseConversationParam) }
|
|
969
973
|
|
|
970
|
-
|
|
974
|
+
sig {
|
|
975
|
+
override.returns(
|
|
976
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Conversation::Variants]
|
|
977
|
+
)
|
|
978
|
+
}
|
|
979
|
+
def self.variants
|
|
980
|
+
end
|
|
971
981
|
|
|
972
|
-
policy: T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::OrHash)
|
|
973
|
-
)
|
|
974
|
-
.returns(T.attached_class)
|
|
975
982
|
end
|
|
976
|
-
def self.new(
|
|
977
|
-
|
|
978
|
-
# The moderation model to use for moderated completions, e.g.
|
|
979
|
-
# 'omni-moderation-latest'.
|
|
980
|
-
model:,
|
|
981
983
|
|
|
982
|
-
|
|
984
|
+
# Text, image, or file inputs to the model, used to generate a response.
|
|
985
|
+
#
|
|
986
|
+
# Learn more:
|
|
987
|
+
#
|
|
988
|
+
# - [Text inputs and outputs](https://platform.openai.com/docs/guides/text)
|
|
989
|
+
# - [Image inputs](https://platform.openai.com/docs/guides/images)
|
|
990
|
+
# - [File inputs](https://platform.openai.com/docs/guides/pdf-files)
|
|
991
|
+
# - [Conversation state](https://platform.openai.com/docs/guides/conversation-state)
|
|
992
|
+
# - [Function calling](https://platform.openai.com/docs/guides/function-calling)
|
|
993
|
+
module Input
|
|
994
|
+
extend OpenAI::Internal::Type::Union
|
|
983
995
|
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
996
|
+
Variants = T.type_alias { T.any(String, T::Array[OpenAI::Responses::ResponseInputItem::Variants]) }
|
|
997
|
+
|
|
998
|
+
sig {
|
|
999
|
+
override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Input::Variants])
|
|
1000
|
+
}
|
|
1001
|
+
def self.variants
|
|
1002
|
+
end
|
|
987
1003
|
|
|
988
|
-
sig do
|
|
989
|
-
override.returns(
|
|
990
|
-
{model: String, policy: T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy)}
|
|
991
|
-
)
|
|
992
|
-
end
|
|
993
|
-
def to_hash
|
|
994
1004
|
end
|
|
995
1005
|
|
|
996
|
-
class
|
|
1006
|
+
class Moderation < OpenAI::Internal::Type::BaseModel
|
|
997
1007
|
OrHash = T.type_alias do
|
|
998
1008
|
T.any(
|
|
999
|
-
OpenAI::Responses::ResponsesClientEvent::Moderation
|
|
1009
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation,
|
|
1000
1010
|
OpenAI::Internal::AnyHash
|
|
1001
1011
|
)
|
|
1002
1012
|
end
|
|
1003
1013
|
|
|
1004
|
-
# The moderation
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
sig {
|
|
1009
|
-
params(input: T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::Input::OrHash)).void
|
|
1010
|
-
}
|
|
1011
|
-
attr_writer :input
|
|
1014
|
+
# The moderation model to use for moderated completions, e.g.
|
|
1015
|
+
# 'omni-moderation-latest'.
|
|
1016
|
+
sig { returns(String) }
|
|
1017
|
+
attr_accessor :model
|
|
1012
1018
|
|
|
1013
|
-
# The
|
|
1014
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy
|
|
1015
|
-
attr_reader :
|
|
1019
|
+
# The policy to apply to moderated response input and output.
|
|
1020
|
+
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy)) }
|
|
1021
|
+
attr_reader :policy
|
|
1016
1022
|
|
|
1017
1023
|
sig {
|
|
1018
|
-
params(
|
|
1024
|
+
params(
|
|
1025
|
+
policy: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::OrHash)
|
|
1026
|
+
)
|
|
1019
1027
|
.void
|
|
1020
1028
|
}
|
|
1021
|
-
attr_writer :
|
|
1029
|
+
attr_writer :policy
|
|
1022
1030
|
|
|
1023
|
-
#
|
|
1031
|
+
# Configuration for running moderation on the input and output of this response.
|
|
1024
1032
|
sig do
|
|
1025
1033
|
params(
|
|
1026
1034
|
|
|
1027
|
-
|
|
1035
|
+
model: String,
|
|
1028
1036
|
|
|
1029
|
-
|
|
1037
|
+
policy: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::OrHash)
|
|
1030
1038
|
)
|
|
1031
1039
|
.returns(T.attached_class)
|
|
1032
1040
|
end
|
|
1033
1041
|
def self.new(
|
|
1034
1042
|
|
|
1035
|
-
# The moderation
|
|
1036
|
-
|
|
1043
|
+
# The moderation model to use for moderated completions, e.g.
|
|
1044
|
+
# 'omni-moderation-latest'.
|
|
1045
|
+
model:,
|
|
1037
1046
|
|
|
1038
|
-
# The
|
|
1047
|
+
# The policy to apply to moderated response input and output.
|
|
1039
1048
|
|
|
1040
|
-
|
|
1049
|
+
policy: nil
|
|
1041
1050
|
)
|
|
1042
1051
|
end
|
|
1043
1052
|
|
|
1044
1053
|
sig do
|
|
1045
1054
|
override.returns(
|
|
1046
1055
|
{
|
|
1047
|
-
|
|
1048
|
-
|
|
1056
|
+
model: String,
|
|
1057
|
+
policy: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy)
|
|
1049
1058
|
}
|
|
1050
1059
|
)
|
|
1051
1060
|
end
|
|
1052
1061
|
def to_hash
|
|
1053
1062
|
end
|
|
1054
1063
|
|
|
1055
|
-
class
|
|
1064
|
+
class Policy < OpenAI::Internal::Type::BaseModel
|
|
1056
1065
|
OrHash = T.type_alias do
|
|
1057
1066
|
T.any(
|
|
1058
|
-
OpenAI::Responses::ResponsesClientEvent::Moderation::Policy
|
|
1067
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy,
|
|
1059
1068
|
OpenAI::Internal::AnyHash
|
|
1060
1069
|
)
|
|
1061
1070
|
end
|
|
1062
1071
|
|
|
1063
|
-
sig { returns(OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::Input::Mode::OrSymbol) }
|
|
1064
|
-
attr_accessor :mode
|
|
1065
|
-
|
|
1066
1072
|
# The moderation policy for the response input.
|
|
1073
|
+
sig {
|
|
1074
|
+
returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input))
|
|
1075
|
+
}
|
|
1076
|
+
attr_reader :input
|
|
1077
|
+
|
|
1078
|
+
sig {
|
|
1079
|
+
params(
|
|
1080
|
+
input: T.nilable(
|
|
1081
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::OrHash
|
|
1082
|
+
)
|
|
1083
|
+
)
|
|
1084
|
+
.void
|
|
1085
|
+
}
|
|
1086
|
+
attr_writer :input
|
|
1087
|
+
|
|
1088
|
+
# The moderation policy for the response output.
|
|
1089
|
+
sig {
|
|
1090
|
+
returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output))
|
|
1091
|
+
}
|
|
1092
|
+
attr_reader :output
|
|
1093
|
+
|
|
1094
|
+
sig {
|
|
1095
|
+
params(
|
|
1096
|
+
output: T.nilable(
|
|
1097
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::OrHash
|
|
1098
|
+
)
|
|
1099
|
+
)
|
|
1100
|
+
.void
|
|
1101
|
+
}
|
|
1102
|
+
attr_writer :output
|
|
1103
|
+
|
|
1104
|
+
# The policy to apply to moderated response input and output.
|
|
1067
1105
|
sig do
|
|
1068
1106
|
params(
|
|
1069
1107
|
|
|
1070
|
-
|
|
1108
|
+
input: T.nilable(
|
|
1109
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::OrHash
|
|
1110
|
+
),
|
|
1111
|
+
|
|
1112
|
+
output: T.nilable(
|
|
1113
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::OrHash
|
|
1114
|
+
)
|
|
1071
1115
|
)
|
|
1072
1116
|
.returns(T.attached_class)
|
|
1073
1117
|
end
|
|
1074
1118
|
def self.new(
|
|
1075
1119
|
|
|
1076
|
-
|
|
1120
|
+
# The moderation policy for the response input.
|
|
1121
|
+
input: nil,
|
|
1122
|
+
|
|
1123
|
+
# The moderation policy for the response output.
|
|
1124
|
+
|
|
1125
|
+
output: nil
|
|
1077
1126
|
)
|
|
1078
1127
|
end
|
|
1079
1128
|
|
|
1080
1129
|
sig do
|
|
1081
1130
|
override.returns(
|
|
1082
|
-
{
|
|
1131
|
+
{
|
|
1132
|
+
input: T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input),
|
|
1133
|
+
output: T.nilable(
|
|
1134
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output
|
|
1135
|
+
)
|
|
1136
|
+
}
|
|
1083
1137
|
)
|
|
1084
1138
|
end
|
|
1085
1139
|
def to_hash
|
|
1086
1140
|
end
|
|
1087
1141
|
|
|
1088
|
-
|
|
1089
|
-
|
|
1142
|
+
class Input < OpenAI::Internal::Type::BaseModel
|
|
1143
|
+
OrHash = T.type_alias do
|
|
1144
|
+
T.any(
|
|
1145
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input,
|
|
1146
|
+
OpenAI::Internal::AnyHash
|
|
1147
|
+
)
|
|
1148
|
+
end
|
|
1090
1149
|
|
|
1091
|
-
|
|
1092
|
-
|
|
1150
|
+
sig {
|
|
1151
|
+
returns(
|
|
1152
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::OrSymbol
|
|
1153
|
+
)
|
|
1093
1154
|
}
|
|
1094
|
-
|
|
1155
|
+
attr_accessor :mode
|
|
1095
1156
|
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
)
|
|
1100
|
-
BLOCK = T.let(
|
|
1101
|
-
:block,
|
|
1102
|
-
OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::Input::Mode::TaggedSymbol
|
|
1103
|
-
)
|
|
1157
|
+
# The moderation policy for the response input.
|
|
1158
|
+
sig do
|
|
1159
|
+
params(
|
|
1104
1160
|
|
|
1105
|
-
|
|
1106
|
-
override.returns(
|
|
1107
|
-
T::Array[OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::Input::Mode::TaggedSymbol]
|
|
1161
|
+
mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::OrSymbol
|
|
1108
1162
|
)
|
|
1109
|
-
|
|
1110
|
-
def self.values
|
|
1163
|
+
.returns(T.attached_class)
|
|
1111
1164
|
end
|
|
1112
|
-
|
|
1113
|
-
end
|
|
1165
|
+
def self.new(
|
|
1114
1166
|
|
|
1115
|
-
|
|
1116
|
-
OrHash = T.type_alias do
|
|
1117
|
-
T.any(
|
|
1118
|
-
OpenAI::Responses::ResponsesClientEvent::Moderation::Policy::Output,
|
|
1119
|
-
OpenAI::Internal::AnyHash
|
|
1167
|
+
mode:
|
|
1120
1168
|
)
|
|
1121
|
-
|
|
1169
|
+
end
|
|
1122
1170
|
|
|
1123
|
-
|
|
1124
|
-
|
|
1171
|
+
sig do
|
|
1172
|
+
override.returns(
|
|
1173
|
+
{
|
|
1174
|
+
mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::OrSymbol
|
|
1175
|
+
}
|
|
1176
|
+
)
|
|
1177
|
+
end
|
|
1178
|
+
def to_hash
|
|
1179
|
+
end
|
|
1125
1180
|
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
params(
|
|
1181
|
+
module Mode
|
|
1182
|
+
extend OpenAI::Internal::Type::Enum
|
|
1129
1183
|
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1184
|
+
TaggedSymbol = T.type_alias {
|
|
1185
|
+
T.all(
|
|
1186
|
+
Symbol,
|
|
1187
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode
|
|
1188
|
+
)
|
|
1189
|
+
}
|
|
1190
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1135
1191
|
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1192
|
+
SCORE = T.let(
|
|
1193
|
+
:score,
|
|
1194
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::TaggedSymbol
|
|
1195
|
+
)
|
|
1196
|
+
BLOCK = T.let(
|
|
1197
|
+
:block,
|
|
1198
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::TaggedSymbol
|
|
1199
|
+
)
|
|
1139
1200
|
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1201
|
+
sig {
|
|
1202
|
+
override.returns(
|
|
1203
|
+
T::Array[
|
|
1204
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Input::Mode::TaggedSymbol
|
|
1205
|
+
]
|
|
1206
|
+
)
|
|
1207
|
+
}
|
|
1208
|
+
def self.values
|
|
1209
|
+
end
|
|
1210
|
+
end
|
|
1146
1211
|
end
|
|
1147
1212
|
|
|
1148
|
-
|
|
1149
|
-
|
|
1213
|
+
class Output < OpenAI::Internal::Type::BaseModel
|
|
1214
|
+
OrHash = T.type_alias do
|
|
1215
|
+
T.any(
|
|
1216
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output,
|
|
1217
|
+
OpenAI::Internal::AnyHash
|
|
1218
|
+
)
|
|
1219
|
+
end
|
|
1150
1220
|
|
|
1151
|
-
|
|
1152
|
-
|
|
1221
|
+
sig {
|
|
1222
|
+
returns(
|
|
1223
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::OrSymbol
|
|
1224
|
+
)
|
|
1153
1225
|
}
|
|
1154
|
-
|
|
1226
|
+
attr_accessor :mode
|
|
1155
1227
|
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1228
|
+
# The moderation policy for the response output.
|
|
1229
|
+
sig do
|
|
1230
|
+
params(
|
|
1231
|
+
|
|
1232
|
+
mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::OrSymbol
|
|
1233
|
+
)
|
|
1234
|
+
.returns(T.attached_class)
|
|
1235
|
+
end
|
|
1236
|
+
def self.new(
|
|
1237
|
+
|
|
1238
|
+
mode:
|
|
1163
1239
|
)
|
|
1240
|
+
end
|
|
1164
1241
|
|
|
1165
|
-
sig
|
|
1242
|
+
sig do
|
|
1166
1243
|
override.returns(
|
|
1167
|
-
|
|
1244
|
+
{
|
|
1245
|
+
mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::OrSymbol
|
|
1246
|
+
}
|
|
1168
1247
|
)
|
|
1169
|
-
|
|
1170
|
-
def
|
|
1248
|
+
end
|
|
1249
|
+
def to_hash
|
|
1250
|
+
end
|
|
1251
|
+
|
|
1252
|
+
module Mode
|
|
1253
|
+
extend OpenAI::Internal::Type::Enum
|
|
1254
|
+
|
|
1255
|
+
TaggedSymbol = T.type_alias {
|
|
1256
|
+
T.all(
|
|
1257
|
+
Symbol,
|
|
1258
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode
|
|
1259
|
+
)
|
|
1260
|
+
}
|
|
1261
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1262
|
+
|
|
1263
|
+
SCORE = T.let(
|
|
1264
|
+
:score,
|
|
1265
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::TaggedSymbol
|
|
1266
|
+
)
|
|
1267
|
+
BLOCK = T.let(
|
|
1268
|
+
:block,
|
|
1269
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::TaggedSymbol
|
|
1270
|
+
)
|
|
1271
|
+
|
|
1272
|
+
sig {
|
|
1273
|
+
override.returns(
|
|
1274
|
+
T::Array[
|
|
1275
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Moderation::Policy::Output::Mode::TaggedSymbol
|
|
1276
|
+
]
|
|
1277
|
+
)
|
|
1278
|
+
}
|
|
1279
|
+
def self.values
|
|
1280
|
+
end
|
|
1171
1281
|
end
|
|
1172
1282
|
end
|
|
1173
1283
|
end
|
|
1174
1284
|
end
|
|
1175
|
-
end
|
|
1176
1285
|
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1286
|
+
class PromptCacheOptions < OpenAI::Internal::Type::BaseModel
|
|
1287
|
+
OrHash = T.type_alias do
|
|
1288
|
+
T.any(
|
|
1289
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions,
|
|
1290
|
+
OpenAI::Internal::AnyHash
|
|
1291
|
+
)
|
|
1292
|
+
end
|
|
1184
1293
|
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
1190
|
-
# request does not use prompt caching.
|
|
1191
|
-
sig { returns(T.nilable(OpenAI::Responses::ResponsesClientEvent::PromptCacheOptions::Mode::OrSymbol)) }
|
|
1192
|
-
attr_reader :mode
|
|
1294
|
+
# The ID of a response to compare when diagnosing prompt cache reuse. Supplying
|
|
1295
|
+
# this field requests prompt cache diagnostics when the feature is enabled.
|
|
1296
|
+
sig { returns(T.nilable(String)) }
|
|
1297
|
+
attr_accessor :comparison_response_id
|
|
1193
1298
|
|
|
1194
|
-
|
|
1195
|
-
|
|
1299
|
+
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
1300
|
+
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
1301
|
+
# and writes up to the latest three explicit breakpoints in the request. With
|
|
1302
|
+
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
1303
|
+
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
1304
|
+
# request does not use prompt caching.
|
|
1305
|
+
sig {
|
|
1306
|
+
returns(
|
|
1307
|
+
T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::OrSymbol)
|
|
1308
|
+
)
|
|
1309
|
+
}
|
|
1310
|
+
attr_reader :mode
|
|
1196
1311
|
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1312
|
+
sig {
|
|
1313
|
+
params(mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::OrSymbol)
|
|
1314
|
+
.void
|
|
1315
|
+
}
|
|
1316
|
+
attr_writer :mode
|
|
1202
1317
|
|
|
1203
|
-
|
|
1204
|
-
|
|
1318
|
+
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
1319
|
+
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
1320
|
+
# value. The backend may retain cache entries for longer.
|
|
1321
|
+
sig {
|
|
1322
|
+
returns(
|
|
1323
|
+
T.nilable(OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::OrSymbol)
|
|
1324
|
+
)
|
|
1325
|
+
}
|
|
1326
|
+
attr_reader :ttl
|
|
1205
1327
|
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1328
|
+
sig {
|
|
1329
|
+
params(ttl: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::OrSymbol)
|
|
1330
|
+
.void
|
|
1331
|
+
}
|
|
1332
|
+
attr_writer :ttl
|
|
1333
|
+
|
|
1334
|
+
# Options for prompt caching. Supported for `gpt-5.6` and later models. By
|
|
1335
|
+
# default, OpenAI automatically chooses one implicit cache breakpoint. You can add
|
|
1336
|
+
# explicit breakpoints to content blocks with `prompt_cache_breakpoint`. Each
|
|
1337
|
+
# request can write up to four breakpoints. For cache matching, OpenAI considers
|
|
1338
|
+
# up to the latest 80 breakpoints in the conversation, without a content-block
|
|
1339
|
+
# lookback limit. Set `mode` to `explicit` to disable the implicit breakpoint. The
|
|
1340
|
+
# `ttl` defaults to `30m`, which is currently the only supported value. See the
|
|
1341
|
+
# [prompt caching guide](https://platform.openai.com/docs/guides/prompt-caching)
|
|
1342
|
+
# for current details.
|
|
1343
|
+
sig do
|
|
1344
|
+
params(
|
|
1345
|
+
|
|
1346
|
+
comparison_response_id: T.nilable(String),
|
|
1217
1347
|
|
|
1218
|
-
|
|
1348
|
+
mode: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::OrSymbol,
|
|
1219
1349
|
|
|
1220
|
-
|
|
1350
|
+
ttl: OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::OrSymbol
|
|
1351
|
+
)
|
|
1352
|
+
.returns(T.attached_class)
|
|
1353
|
+
end
|
|
1354
|
+
def self.new(
|
|
1355
|
+
|
|
1356
|
+
# The ID of a response to compare when diagnosing prompt cache reuse. Supplying
|
|
1357
|
+
# this field requests prompt cache diagnostics when the feature is enabled.
|
|
1358
|
+
comparison_response_id: nil,
|
|
1359
|
+
|
|
1360
|
+
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
1361
|
+
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
1362
|
+
# and writes up to the latest three explicit breakpoints in the request. With
|
|
1363
|
+
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
1364
|
+
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
1365
|
+
# request does not use prompt caching.
|
|
1366
|
+
mode: nil,
|
|
1367
|
+
|
|
1368
|
+
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
1369
|
+
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
1370
|
+
# value. The backend may retain cache entries for longer.
|
|
1371
|
+
|
|
1372
|
+
ttl: nil
|
|
1221
1373
|
)
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1374
|
+
end
|
|
1375
|
+
|
|
1376
|
+
sig do
|
|
1377
|
+
override.returns(
|
|
1378
|
+
{
|
|
1379
|
+
comparison_response_id: T.nilable(String),
|
|
1380
|
+
mode: T.nilable(
|
|
1381
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::OrSymbol
|
|
1382
|
+
),
|
|
1383
|
+
ttl: T.nilable(
|
|
1384
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::OrSymbol
|
|
1385
|
+
)
|
|
1386
|
+
}
|
|
1387
|
+
)
|
|
1388
|
+
end
|
|
1389
|
+
def to_hash
|
|
1390
|
+
end
|
|
1225
1391
|
|
|
1226
1392
|
# Controls whether OpenAI automatically creates an implicit cache breakpoint.
|
|
1227
1393
|
# Defaults to `implicit`. With `implicit`, OpenAI creates one implicit breakpoint
|
|
@@ -1229,182 +1395,170 @@ module OpenAI
|
|
|
1229
1395
|
# `explicit`, OpenAI does not create an implicit breakpoint and writes up to the
|
|
1230
1396
|
# latest four explicit breakpoints. If there are no explicit breakpoints, the
|
|
1231
1397
|
# request does not use prompt caching.
|
|
1232
|
-
|
|
1398
|
+
module Mode
|
|
1399
|
+
extend OpenAI::Internal::Type::Enum
|
|
1400
|
+
|
|
1401
|
+
TaggedSymbol = T.type_alias {
|
|
1402
|
+
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode)
|
|
1403
|
+
}
|
|
1404
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1405
|
+
|
|
1406
|
+
IMPLICIT = T.let(
|
|
1407
|
+
:implicit,
|
|
1408
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::TaggedSymbol
|
|
1409
|
+
)
|
|
1410
|
+
EXPLICIT = T.let(
|
|
1411
|
+
:explicit,
|
|
1412
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::TaggedSymbol
|
|
1413
|
+
)
|
|
1414
|
+
|
|
1415
|
+
sig {
|
|
1416
|
+
override.returns(
|
|
1417
|
+
T::Array[
|
|
1418
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Mode::TaggedSymbol
|
|
1419
|
+
]
|
|
1420
|
+
)
|
|
1421
|
+
}
|
|
1422
|
+
def self.values
|
|
1423
|
+
end
|
|
1424
|
+
end
|
|
1233
1425
|
|
|
1234
1426
|
# The minimum lifetime applied to every implicit and explicit cache breakpoint
|
|
1235
1427
|
# written by the request. Defaults to `30m`, which is currently the only supported
|
|
1236
1428
|
# value. The backend may retain cache entries for longer.
|
|
1429
|
+
module Ttl
|
|
1430
|
+
extend OpenAI::Internal::Type::Enum
|
|
1237
1431
|
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1432
|
+
TaggedSymbol = T.type_alias {
|
|
1433
|
+
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl)
|
|
1434
|
+
}
|
|
1435
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1241
1436
|
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1437
|
+
TTL_30M = T.let(
|
|
1438
|
+
:"30m",
|
|
1439
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::TaggedSymbol
|
|
1440
|
+
)
|
|
1441
|
+
|
|
1442
|
+
sig {
|
|
1443
|
+
override.returns(
|
|
1444
|
+
T::Array[
|
|
1445
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheOptions::Ttl::TaggedSymbol
|
|
1446
|
+
]
|
|
1447
|
+
)
|
|
1247
1448
|
}
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1449
|
+
def self.values
|
|
1450
|
+
end
|
|
1451
|
+
end
|
|
1251
1452
|
end
|
|
1252
1453
|
|
|
1253
|
-
#
|
|
1254
|
-
#
|
|
1255
|
-
#
|
|
1256
|
-
#
|
|
1257
|
-
#
|
|
1258
|
-
#
|
|
1259
|
-
|
|
1454
|
+
# Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
1455
|
+
#
|
|
1456
|
+
# The retention policy for the prompt cache. Set to `24h` to enable extended
|
|
1457
|
+
# prompt caching, which keeps cached prefixes active for longer, up to a maximum
|
|
1458
|
+
# of 24 hours.
|
|
1459
|
+
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
|
|
1460
|
+
# This field expresses a maximum retention policy, while
|
|
1461
|
+
# `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
|
|
1462
|
+
# are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
|
|
1463
|
+
# models, only `24h` is supported.
|
|
1464
|
+
#
|
|
1465
|
+
# For older models that support both `in_memory` and `24h`, the default depends on
|
|
1466
|
+
# your organization's data retention policy:
|
|
1467
|
+
#
|
|
1468
|
+
# - Organizations without ZDR enabled default to `24h`.
|
|
1469
|
+
# - Organizations with ZDR enabled default to `in_memory` when
|
|
1470
|
+
# `prompt_cache_retention` is not specified.
|
|
1471
|
+
module PromptCacheRetention
|
|
1260
1472
|
extend OpenAI::Internal::Type::Enum
|
|
1261
1473
|
|
|
1262
1474
|
TaggedSymbol = T.type_alias {
|
|
1263
|
-
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::
|
|
1475
|
+
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention)
|
|
1264
1476
|
}
|
|
1265
1477
|
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1266
1478
|
|
|
1267
|
-
|
|
1268
|
-
|
|
1479
|
+
IN_MEMORY = T.let(
|
|
1480
|
+
:in_memory,
|
|
1481
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::TaggedSymbol
|
|
1482
|
+
)
|
|
1483
|
+
PROMPT_CACHE_RETENTION_24H = T.let(
|
|
1484
|
+
:"24h",
|
|
1485
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::TaggedSymbol
|
|
1486
|
+
)
|
|
1269
1487
|
|
|
1270
1488
|
sig {
|
|
1271
1489
|
override.returns(
|
|
1272
|
-
T::Array[OpenAI::Responses::ResponsesClientEvent::
|
|
1490
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::PromptCacheRetention::TaggedSymbol]
|
|
1273
1491
|
)
|
|
1274
1492
|
}
|
|
1275
1493
|
def self.values
|
|
1276
1494
|
end
|
|
1277
1495
|
end
|
|
1278
1496
|
|
|
1279
|
-
#
|
|
1280
|
-
#
|
|
1281
|
-
#
|
|
1282
|
-
|
|
1497
|
+
# Specifies the processing type used for serving the request.
|
|
1498
|
+
#
|
|
1499
|
+
# - If set to 'auto', then the request will be processed with the service tier
|
|
1500
|
+
# configured in the Project settings. Unless otherwise configured, the Project
|
|
1501
|
+
# will use 'default'.
|
|
1502
|
+
# - If set to 'default', then the request will be processed with the standard
|
|
1503
|
+
# pricing and performance for the selected model.
|
|
1504
|
+
# - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
|
|
1505
|
+
# then the request will be processed with the Flex Processing service tier.
|
|
1506
|
+
# - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
|
|
1507
|
+
# include the `service_tier=fast` or `service_tier=priority` parameter for
|
|
1508
|
+
# Responses or Chat Completions. The response will show `service_tier=priority`
|
|
1509
|
+
# regardless of if you specify `service_tier=fast` or `priority` in your
|
|
1510
|
+
# request.
|
|
1511
|
+
# - If set to 'ultrafast', then the request will be processed with the
|
|
1512
|
+
# access-controlled Ultrafast Processing service tier. This tier is currently
|
|
1513
|
+
# available for `gpt-5.6-sol`; a response served through it will show
|
|
1514
|
+
# `service_tier=ultrafast`.
|
|
1515
|
+
# - When not set, the default behavior is 'auto'.
|
|
1516
|
+
#
|
|
1517
|
+
# When the `service_tier` parameter is set, the response body will include the
|
|
1518
|
+
# `service_tier` value based on the processing mode actually used to serve the
|
|
1519
|
+
# request. This response value may be different from the value set in the
|
|
1520
|
+
# parameter.
|
|
1521
|
+
module ServiceTier
|
|
1283
1522
|
extend OpenAI::Internal::Type::Enum
|
|
1284
1523
|
|
|
1285
1524
|
TaggedSymbol = T.type_alias {
|
|
1286
|
-
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::
|
|
1525
|
+
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier)
|
|
1287
1526
|
}
|
|
1288
1527
|
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1289
1528
|
|
|
1290
|
-
|
|
1529
|
+
AUTO = T.let(:auto, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol)
|
|
1530
|
+
DEFAULT = T.let(
|
|
1531
|
+
:default,
|
|
1532
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol
|
|
1533
|
+
)
|
|
1534
|
+
FLEX = T.let(:flex, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol)
|
|
1535
|
+
SCALE = T.let(:scale, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol)
|
|
1536
|
+
PRIORITY = T.let(
|
|
1537
|
+
:priority,
|
|
1538
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol
|
|
1539
|
+
)
|
|
1540
|
+
FAST = T.let(:fast, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol)
|
|
1541
|
+
ULTRAFAST = T.let(
|
|
1542
|
+
:ultrafast,
|
|
1543
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol
|
|
1544
|
+
)
|
|
1291
1545
|
|
|
1292
1546
|
sig {
|
|
1293
|
-
override.returns(
|
|
1547
|
+
override.returns(
|
|
1548
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ServiceTier::TaggedSymbol]
|
|
1549
|
+
)
|
|
1294
1550
|
}
|
|
1295
1551
|
def self.values
|
|
1296
1552
|
end
|
|
1297
1553
|
end
|
|
1298
|
-
end
|
|
1299
|
-
|
|
1300
|
-
# Deprecated. Use `prompt_cache_options.ttl` instead.
|
|
1301
|
-
#
|
|
1302
|
-
# The retention policy for the prompt cache. Set to `24h` to enable extended
|
|
1303
|
-
# prompt caching, which keeps cached prefixes active for longer, up to a maximum
|
|
1304
|
-
# of 24 hours.
|
|
1305
|
-
# [Learn more](https://platform.openai.com/docs/guides/prompt-caching#prompt-cache-retention).
|
|
1306
|
-
# This field expresses a maximum retention policy, while
|
|
1307
|
-
# `prompt_cache_options.ttl` expresses a minimum cache lifetime. The two fields
|
|
1308
|
-
# are independent and do not interact. For `gpt-5.5`, `gpt-5.5-pro`, and future
|
|
1309
|
-
# models, only `24h` is supported.
|
|
1310
|
-
#
|
|
1311
|
-
# For older models that support both `in_memory` and `24h`, the default depends on
|
|
1312
|
-
# your organization's data retention policy:
|
|
1313
|
-
#
|
|
1314
|
-
# - Organizations without ZDR enabled default to `24h`.
|
|
1315
|
-
# - Organizations with ZDR enabled default to `in_memory` when
|
|
1316
|
-
# `prompt_cache_retention` is not specified.
|
|
1317
|
-
module PromptCacheRetention
|
|
1318
|
-
extend OpenAI::Internal::Type::Enum
|
|
1319
|
-
|
|
1320
|
-
TaggedSymbol = T.type_alias { T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention) }
|
|
1321
|
-
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1322
|
-
|
|
1323
|
-
IN_MEMORY = T.let(:in_memory, OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention::TaggedSymbol)
|
|
1324
|
-
PROMPT_CACHE_RETENTION_24H = T.let(
|
|
1325
|
-
:"24h",
|
|
1326
|
-
OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention::TaggedSymbol
|
|
1327
|
-
)
|
|
1328
|
-
|
|
1329
|
-
sig {
|
|
1330
|
-
override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::PromptCacheRetention::TaggedSymbol])
|
|
1331
|
-
}
|
|
1332
|
-
def self.values
|
|
1333
|
-
end
|
|
1334
|
-
end
|
|
1335
|
-
|
|
1336
|
-
# Specifies the processing type used for serving the request.
|
|
1337
|
-
#
|
|
1338
|
-
# - If set to 'auto', then the request will be processed with the service tier
|
|
1339
|
-
# configured in the Project settings. Unless otherwise configured, the Project
|
|
1340
|
-
# will use 'default'.
|
|
1341
|
-
# - If set to 'default', then the request will be processed with the standard
|
|
1342
|
-
# pricing and performance for the selected model.
|
|
1343
|
-
# - If set to '[flex](https://platform.openai.com/docs/guides/flex-processing)',
|
|
1344
|
-
# then the request will be processed with the Flex Processing service tier.
|
|
1345
|
-
# - To opt-in to [Fast mode](/api/docs/guides/fast-mode) at the request level,
|
|
1346
|
-
# include the `service_tier=fast` or `service_tier=priority` parameter for
|
|
1347
|
-
# Responses or Chat Completions. The response will show `service_tier=priority`
|
|
1348
|
-
# regardless of if you specify `service_tier=fast` or `priority` in your
|
|
1349
|
-
# request.
|
|
1350
|
-
# - If set to 'ultrafast', then the request will be processed with the
|
|
1351
|
-
# access-controlled Ultrafast Processing service tier. This tier is currently
|
|
1352
|
-
# available for `gpt-5.6-sol`; a response served through it will show
|
|
1353
|
-
# `service_tier=ultrafast`.
|
|
1354
|
-
# - When not set, the default behavior is 'auto'.
|
|
1355
|
-
#
|
|
1356
|
-
# When the `service_tier` parameter is set, the response body will include the
|
|
1357
|
-
# `service_tier` value based on the processing mode actually used to serve the
|
|
1358
|
-
# request. This response value may be different from the value set in the
|
|
1359
|
-
# parameter.
|
|
1360
|
-
module ServiceTier
|
|
1361
|
-
extend OpenAI::Internal::Type::Enum
|
|
1362
|
-
|
|
1363
|
-
TaggedSymbol = T.type_alias { T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ServiceTier) }
|
|
1364
|
-
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1365
|
-
|
|
1366
|
-
AUTO = T.let(:auto, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1367
|
-
DEFAULT = T.let(:default, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1368
|
-
FLEX = T.let(:flex, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1369
|
-
SCALE = T.let(:scale, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1370
|
-
PRIORITY = T.let(:priority, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1371
|
-
FAST = T.let(:fast, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1372
|
-
ULTRAFAST = T.let(:ultrafast, OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol)
|
|
1373
|
-
|
|
1374
|
-
sig { override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::ServiceTier::TaggedSymbol]) }
|
|
1375
|
-
def self.values
|
|
1376
|
-
end
|
|
1377
|
-
end
|
|
1378
1554
|
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
# When true, stream obfuscation will be enabled. Stream obfuscation adds random
|
|
1388
|
-
# characters to an `obfuscation` field on streaming delta events to normalize
|
|
1389
|
-
# payload sizes as a mitigation to certain side-channel attacks. These obfuscation
|
|
1390
|
-
# fields are included by default, but add a small amount of overhead to the data
|
|
1391
|
-
# stream. You can set `include_obfuscation` to false to optimize for bandwidth if
|
|
1392
|
-
# you trust the network links between your application and the OpenAI API.
|
|
1393
|
-
sig { returns(T.nilable(T::Boolean)) }
|
|
1394
|
-
attr_reader :include_obfuscation
|
|
1395
|
-
|
|
1396
|
-
sig { params(include_obfuscation: T::Boolean).void }
|
|
1397
|
-
attr_writer :include_obfuscation
|
|
1398
|
-
|
|
1399
|
-
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
1400
|
-
sig do
|
|
1401
|
-
params(
|
|
1402
|
-
|
|
1403
|
-
include_obfuscation: T::Boolean
|
|
1404
|
-
)
|
|
1405
|
-
.returns(T.attached_class)
|
|
1406
|
-
end
|
|
1407
|
-
def self.new(
|
|
1555
|
+
class StreamOptions < OpenAI::Internal::Type::BaseModel
|
|
1556
|
+
OrHash = T.type_alias do
|
|
1557
|
+
T.any(
|
|
1558
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::StreamOptions,
|
|
1559
|
+
OpenAI::Internal::AnyHash
|
|
1560
|
+
)
|
|
1561
|
+
end
|
|
1408
1562
|
|
|
1409
1563
|
# When true, stream obfuscation will be enabled. Stream obfuscation adds random
|
|
1410
1564
|
# characters to an `obfuscation` field on streaming delta events to normalize
|
|
@@ -1412,71 +1566,36 @@ module OpenAI
|
|
|
1412
1566
|
# fields are included by default, but add a small amount of overhead to the data
|
|
1413
1567
|
# stream. You can set `include_obfuscation` to false to optimize for bandwidth if
|
|
1414
1568
|
# you trust the network links between your application and the OpenAI API.
|
|
1569
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
1570
|
+
attr_reader :include_obfuscation
|
|
1415
1571
|
|
|
1416
|
-
include_obfuscation:
|
|
1417
|
-
|
|
1418
|
-
end
|
|
1419
|
-
|
|
1420
|
-
sig do
|
|
1421
|
-
override.returns(
|
|
1422
|
-
{include_obfuscation: T::Boolean}
|
|
1423
|
-
)
|
|
1424
|
-
end
|
|
1425
|
-
def to_hash
|
|
1426
|
-
end
|
|
1427
|
-
|
|
1428
|
-
end
|
|
1429
|
-
|
|
1430
|
-
# How the model should select which tool (or tools) to use when generating a
|
|
1431
|
-
# response. See the `tools` parameter to see how to specify which tools the model
|
|
1432
|
-
# can call.
|
|
1433
|
-
module ToolChoice
|
|
1434
|
-
extend OpenAI::Internal::Type::Union
|
|
1435
|
-
|
|
1436
|
-
Variants = T.type_alias {
|
|
1437
|
-
T.any(
|
|
1438
|
-
OpenAI::Responses::ToolChoiceOptions::TaggedSymbol,
|
|
1439
|
-
OpenAI::Responses::ToolChoiceAllowed,
|
|
1440
|
-
OpenAI::Responses::ToolChoiceTypes,
|
|
1441
|
-
OpenAI::Responses::ToolChoiceFunction,
|
|
1442
|
-
OpenAI::Responses::ToolChoiceMcp,
|
|
1443
|
-
OpenAI::Responses::ToolChoiceCustom,
|
|
1444
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
1445
|
-
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
1446
|
-
OpenAI::Responses::ToolChoiceShell
|
|
1447
|
-
)
|
|
1448
|
-
}
|
|
1449
|
-
|
|
1450
|
-
class SpecificProgrammaticToolCallingParam < OpenAI::Internal::Type::BaseModel
|
|
1451
|
-
OrHash = T.type_alias do
|
|
1452
|
-
T.any(
|
|
1453
|
-
OpenAI::Responses::ResponsesClientEvent::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
1454
|
-
OpenAI::Internal::AnyHash
|
|
1455
|
-
)
|
|
1456
|
-
end
|
|
1457
|
-
|
|
1458
|
-
# The tool to call. Always `programmatic_tool_calling`.
|
|
1459
|
-
sig { returns(Symbol) }
|
|
1460
|
-
attr_accessor :type
|
|
1572
|
+
sig { params(include_obfuscation: T::Boolean).void }
|
|
1573
|
+
attr_writer :include_obfuscation
|
|
1461
1574
|
|
|
1575
|
+
# Options for streaming responses. Only set this when you set `stream: true`.
|
|
1462
1576
|
sig do
|
|
1463
1577
|
params(
|
|
1464
1578
|
|
|
1465
|
-
|
|
1579
|
+
include_obfuscation: T::Boolean
|
|
1466
1580
|
)
|
|
1467
1581
|
.returns(T.attached_class)
|
|
1468
1582
|
end
|
|
1469
1583
|
def self.new(
|
|
1470
1584
|
|
|
1471
|
-
#
|
|
1585
|
+
# When true, stream obfuscation will be enabled. Stream obfuscation adds random
|
|
1586
|
+
# characters to an `obfuscation` field on streaming delta events to normalize
|
|
1587
|
+
# payload sizes as a mitigation to certain side-channel attacks. These obfuscation
|
|
1588
|
+
# fields are included by default, but add a small amount of overhead to the data
|
|
1589
|
+
# stream. You can set `include_obfuscation` to false to optimize for bandwidth if
|
|
1590
|
+
# you trust the network links between your application and the OpenAI API.
|
|
1472
1591
|
|
|
1473
|
-
|
|
1592
|
+
include_obfuscation: nil
|
|
1474
1593
|
)
|
|
1475
1594
|
end
|
|
1476
1595
|
|
|
1477
1596
|
sig do
|
|
1478
1597
|
override.returns(
|
|
1479
|
-
{
|
|
1598
|
+
{include_obfuscation: T.nilable(T::Boolean)}
|
|
1480
1599
|
)
|
|
1481
1600
|
end
|
|
1482
1601
|
def to_hash
|
|
@@ -1484,31 +1603,104 @@ module OpenAI
|
|
|
1484
1603
|
|
|
1485
1604
|
end
|
|
1486
1605
|
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1606
|
+
# How the model should select which tool (or tools) to use when generating a
|
|
1607
|
+
# response. See the `tools` parameter to see how to specify which tools the model
|
|
1608
|
+
# can call.
|
|
1609
|
+
module ToolChoice
|
|
1610
|
+
extend OpenAI::Internal::Type::Union
|
|
1490
1611
|
|
|
1491
|
-
|
|
1612
|
+
Variants = T.type_alias {
|
|
1613
|
+
T.any(
|
|
1614
|
+
OpenAI::Responses::ToolChoiceOptions::TaggedSymbol,
|
|
1615
|
+
OpenAI::Responses::ToolChoiceAllowed,
|
|
1616
|
+
OpenAI::Responses::ToolChoiceTypes,
|
|
1617
|
+
OpenAI::Responses::ToolChoiceFunction,
|
|
1618
|
+
OpenAI::Responses::ToolChoiceMcp,
|
|
1619
|
+
OpenAI::Responses::ToolChoiceCustom,
|
|
1620
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
1621
|
+
OpenAI::Responses::ToolChoiceApplyPatch,
|
|
1622
|
+
OpenAI::Responses::ToolChoiceShell
|
|
1623
|
+
)
|
|
1624
|
+
}
|
|
1625
|
+
|
|
1626
|
+
class SpecificProgrammaticToolCallingParam < OpenAI::Internal::Type::BaseModel
|
|
1627
|
+
OrHash = T.type_alias do
|
|
1628
|
+
T.any(
|
|
1629
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::SpecificProgrammaticToolCallingParam,
|
|
1630
|
+
OpenAI::Internal::AnyHash
|
|
1631
|
+
)
|
|
1632
|
+
end
|
|
1633
|
+
|
|
1634
|
+
# The tool to call. Always `programmatic_tool_calling`.
|
|
1635
|
+
sig { returns(Symbol) }
|
|
1636
|
+
attr_accessor :type
|
|
1492
1637
|
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1638
|
+
sig do
|
|
1639
|
+
params(
|
|
1640
|
+
|
|
1641
|
+
type: Symbol
|
|
1642
|
+
)
|
|
1643
|
+
.returns(T.attached_class)
|
|
1644
|
+
end
|
|
1645
|
+
def self.new(
|
|
1646
|
+
|
|
1647
|
+
# The tool to call. Always `programmatic_tool_calling`.
|
|
1648
|
+
|
|
1649
|
+
type: :programmatic_tool_calling
|
|
1650
|
+
)
|
|
1651
|
+
end
|
|
1652
|
+
|
|
1653
|
+
sig do
|
|
1654
|
+
override.returns(
|
|
1655
|
+
{type: Symbol}
|
|
1656
|
+
)
|
|
1657
|
+
end
|
|
1658
|
+
def to_hash
|
|
1659
|
+
end
|
|
1502
1660
|
|
|
1503
|
-
|
|
1504
|
-
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1661
|
+
end
|
|
1505
1662
|
|
|
1506
|
-
|
|
1507
|
-
|
|
1663
|
+
sig {
|
|
1664
|
+
override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::ToolChoice::Variants])
|
|
1665
|
+
}
|
|
1666
|
+
def self.variants
|
|
1667
|
+
end
|
|
1508
1668
|
|
|
1509
|
-
sig { override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::Truncation::TaggedSymbol]) }
|
|
1510
|
-
def self.values
|
|
1511
1669
|
end
|
|
1670
|
+
|
|
1671
|
+
# The truncation strategy to use for the model response.
|
|
1672
|
+
#
|
|
1673
|
+
# - `auto`: If the input to this Response exceeds the model's context window size,
|
|
1674
|
+
# the model will truncate the response to fit the context window by dropping
|
|
1675
|
+
# items from the beginning of the conversation.
|
|
1676
|
+
# - `disabled` (default): If the input size will exceed the context window size
|
|
1677
|
+
# for a model, the request will fail with a 400 error.
|
|
1678
|
+
module Truncation
|
|
1679
|
+
extend OpenAI::Internal::Type::Enum
|
|
1680
|
+
|
|
1681
|
+
TaggedSymbol = T.type_alias {
|
|
1682
|
+
T.all(Symbol, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation)
|
|
1683
|
+
}
|
|
1684
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1685
|
+
|
|
1686
|
+
AUTO = T.let(:auto, OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::TaggedSymbol)
|
|
1687
|
+
DISABLED = T.let(
|
|
1688
|
+
:disabled,
|
|
1689
|
+
OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::TaggedSymbol
|
|
1690
|
+
)
|
|
1691
|
+
|
|
1692
|
+
sig {
|
|
1693
|
+
override.returns(
|
|
1694
|
+
T::Array[OpenAI::Responses::ResponsesClientEvent::ResponseCreate::Truncation::TaggedSymbol]
|
|
1695
|
+
)
|
|
1696
|
+
}
|
|
1697
|
+
def self.values
|
|
1698
|
+
end
|
|
1699
|
+
end
|
|
1700
|
+
end
|
|
1701
|
+
|
|
1702
|
+
sig { override.returns(T::Array[OpenAI::Responses::ResponsesClientEvent::Variants]) }
|
|
1703
|
+
def self.variants
|
|
1512
1704
|
end
|
|
1513
1705
|
|
|
1514
1706
|
end
|