From 1fbce8c1158482b361ea48ff996b1998031679bf Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 17 Oct 2025 21:31:24 +0000 Subject: [PATCH 1/2] fix(api): internal openapi updates --- .stats.yml | 6 ++-- .../models/conversations/conversation_item.rb | 4 --- .../models/conversations/item_list_params.rb | 2 +- lib/openai/models/custom_tool_input_format.rb | 6 ---- lib/openai/models/image_edit_params.rb | 2 +- lib/openai/models/responses/custom_tool.rb | 6 ---- .../response_code_interpreter_tool_call.rb | 8 ++--- .../responses/response_computer_tool_call.rb | 31 ++++++++---------- ...response_computer_tool_call_output_item.rb | 14 ++++---- .../responses/response_create_params.rb | 2 +- .../models/responses/response_includable.rb | 8 +++-- .../models/responses/response_input_item.rb | 4 --- lib/openai/models/responses/response_item.rb | 4 --- .../models/responses/response_output_item.rb | 4 --- lib/openai/models/responses/tool.rb | 14 ++------ lib/openai/resources/conversations/items.rb | 2 +- lib/openai/resources/images.rb | 4 +-- lib/openai/resources/responses.rb | 4 +-- .../models/custom_tool_input_format.rbi | 2 -- rbi/openai/models/responses/custom_tool.rbi | 2 -- .../response_code_interpreter_tool_call.rbi | 8 ++--- .../responses/response_computer_tool_call.rbi | 32 +++++++++++-------- ...esponse_computer_tool_call_output_item.rbi | 24 +++++++++----- .../models/responses/response_includable.rbi | 26 ++++++++++----- rbi/openai/models/responses/tool.rbi | 1 - .../responses/response_computer_tool_call.rbs | 14 +++++--- ...esponse_computer_tool_call_output_item.rbs | 14 +++++--- .../models/responses/response_includable.rbs | 18 +++++++---- 28 files changed, 128 insertions(+), 138 deletions(-) diff --git a/.stats.yml b/.stats.yml index 3a558a91..6b1557c3 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 134 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-f59befea071ed7729cbb7bce219e7f837eccfdb57e01698514e6a0bd6052ff60.yml -openapi_spec_hash: 49da48619d37932b2e257c532078b2bb -config_hash: 1af83449a09a3b4f276444dbcdd3eb67 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-b062c33330de7e3bbf992fd4f0799afd868c30a66c39418dd2c62f4add3b45b6.yml +openapi_spec_hash: fe067f5b1c0e93799b5ea7fde3c4b1b3 +config_hash: 4b6f471b24d659514b86b736c90a0c0a diff --git a/lib/openai/models/conversations/conversation_item.rb b/lib/openai/models/conversations/conversation_item.rb index d73bcdd2..14ee48c8 100644 --- a/lib/openai/models/conversations/conversation_item.rb +++ b/lib/openai/models/conversations/conversation_item.rb @@ -215,10 +215,6 @@ class Action < OpenAI::Internal::Type::BaseModel optional :working_directory, String, nil?: true # @!method initialize(command:, env:, timeout_ms: nil, user: nil, working_directory: nil, type: :exec) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Conversations::ConversationItem::LocalShellCall::Action} for - # more details. - # # Execute a shell command on the server. # # @param command [Array] The command to run. diff --git a/lib/openai/models/conversations/item_list_params.rb b/lib/openai/models/conversations/item_list_params.rb index 3c23afba..47d6cd7a 100644 --- a/lib/openai/models/conversations/item_list_params.rb +++ b/lib/openai/models/conversations/item_list_params.rb @@ -59,7 +59,7 @@ class ItemListParams < OpenAI::Internal::Type::BaseModel # # @param after [String] An item ID to list items after, used in pagination. # - # @param include [Array] Specify additional output data to include in the model response. Currently + # @param include [Array] Specify additional output data to include in the model response. Currently suppo # # @param limit [Integer] A limit on the number of objects to be returned. Limit can range between # diff --git a/lib/openai/models/custom_tool_input_format.rb b/lib/openai/models/custom_tool_input_format.rb index e716a67d..6eacce5b 100644 --- a/lib/openai/models/custom_tool_input_format.rb +++ b/lib/openai/models/custom_tool_input_format.rb @@ -8,10 +8,8 @@ module CustomToolInputFormat discriminator :type - # Unconstrained free-form text. variant :text, -> { OpenAI::CustomToolInputFormat::Text } - # A grammar defined by the user. variant :grammar, -> { OpenAI::CustomToolInputFormat::Grammar } class Text < OpenAI::Internal::Type::BaseModel @@ -22,8 +20,6 @@ class Text < OpenAI::Internal::Type::BaseModel required :type, const: :text # @!method initialize(type: :text) - # Unconstrained free-form text. - # # @param type [Symbol, :text] Unconstrained text format. Always `text`. end @@ -47,8 +43,6 @@ class Grammar < OpenAI::Internal::Type::BaseModel required :type, const: :grammar # @!method initialize(definition:, syntax:, type: :grammar) - # A grammar defined by the user. - # # @param definition [String] The grammar definition. # # @param syntax [Symbol, OpenAI::Models::CustomToolInputFormat::Grammar::Syntax] The syntax of the grammar definition. One of `lark` or `regex`. diff --git a/lib/openai/models/image_edit_params.rb b/lib/openai/models/image_edit_params.rb index 18e520b0..dbd938de 100644 --- a/lib/openai/models/image_edit_params.rb +++ b/lib/openai/models/image_edit_params.rb @@ -142,7 +142,7 @@ class ImageEditParams < OpenAI::Internal::Type::BaseModel # # @param background [Symbol, OpenAI::Models::ImageEditParams::Background, nil] Allows to set transparency for the background of the generated image(s). # - # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] Control how much effort the model will exert to match the style and features, + # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] # # @param mask [Pathname, StringIO, IO, String, OpenAI::FilePart] An additional image whose fully transparent areas (e.g. where alpha is zero) ind # diff --git a/lib/openai/models/responses/custom_tool.rb b/lib/openai/models/responses/custom_tool.rb index 05c3665f..297335bc 100644 --- a/lib/openai/models/responses/custom_tool.rb +++ b/lib/openai/models/responses/custom_tool.rb @@ -29,12 +29,6 @@ class CustomTool < OpenAI::Internal::Type::BaseModel optional :format_, union: -> { OpenAI::CustomToolInputFormat }, api_name: :format # @!method initialize(name:, description: nil, format_: nil, type: :custom) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::CustomTool} for more details. - # - # A custom tool that processes input using a specified format. Learn more about - # [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools). - # # @param name [String] The name of the custom tool, used to identify it in tool calls. # # @param description [String] Optional description of the custom tool, used to provide more context. diff --git a/lib/openai/models/responses/response_code_interpreter_tool_call.rb b/lib/openai/models/responses/response_code_interpreter_tool_call.rb index dddf9e3b..389d3cd9 100644 --- a/lib/openai/models/responses/response_code_interpreter_tool_call.rb +++ b/lib/openai/models/responses/response_code_interpreter_tool_call.rb @@ -84,7 +84,7 @@ class Logs < OpenAI::Internal::Type::BaseModel required :logs, String # @!attribute type - # The type of the output. Always 'logs'. + # The type of the output. Always `logs`. # # @return [Symbol, :logs] required :type, const: :logs @@ -94,12 +94,12 @@ class Logs < OpenAI::Internal::Type::BaseModel # # @param logs [String] The logs output from the code interpreter. # - # @param type [Symbol, :logs] The type of the output. Always 'logs'. + # @param type [Symbol, :logs] The type of the output. Always `logs`. end class Image < OpenAI::Internal::Type::BaseModel # @!attribute type - # The type of the output. Always 'image'. + # The type of the output. Always `image`. # # @return [Symbol, :image] required :type, const: :image @@ -115,7 +115,7 @@ class Image < OpenAI::Internal::Type::BaseModel # # @param url [String] The URL of the image output from the code interpreter. # - # @param type [Symbol, :image] The type of the output. Always 'image'. + # @param type [Symbol, :image] The type of the output. Always `image`. end # @!method self.variants diff --git a/lib/openai/models/responses/response_computer_tool_call.rb b/lib/openai/models/responses/response_computer_tool_call.rb index 96bf3742..86b85acd 100644 --- a/lib/openai/models/responses/response_computer_tool_call.rb +++ b/lib/openai/models/responses/response_computer_tool_call.rb @@ -106,8 +106,7 @@ class Click < OpenAI::Internal::Type::BaseModel required :button, enum: -> { OpenAI::Responses::ResponseComputerToolCall::Action::Click::Button } # @!attribute type - # Specifies the event type. For a click action, this property is always set to - # `click`. + # Specifies the event type. For a click action, this property is always `click`. # # @return [Symbol, :click] required :type, const: :click @@ -137,7 +136,7 @@ class Click < OpenAI::Internal::Type::BaseModel # # @param y_ [Integer] The y-coordinate where the click occurred. # - # @param type [Symbol, :click] Specifies the event type. For a click action, this property is + # @param type [Symbol, :click] Specifies the event type. For a click action, this property is always `click`. # Indicates which mouse button was pressed during the click. One of `left`, # `right`, `wheel`, `back`, or `forward`. @@ -188,7 +187,7 @@ class DoubleClick < OpenAI::Internal::Type::BaseModel # # @param y_ [Integer] The y-coordinate where the double click occurred. # - # @param type [Symbol, :double_click] Specifies the event type. For a double click action, this property is + # @param type [Symbol, :double_click] Specifies the event type. For a double click action, this property is always set end class Drag < OpenAI::Internal::Type::BaseModel @@ -239,11 +238,7 @@ class Path < OpenAI::Internal::Type::BaseModel required :y_, Integer, api_name: :y # @!method initialize(x:, y_:) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::ResponseComputerToolCall::Action::Drag::Path} for - # more details. - # - # A series of x/y coordinate pairs in the drag path. + # An x/y coordinate pair, e.g. `{ x: 100, y: 200 }`. # # @param x [Integer] The x-coordinate. # @@ -273,9 +268,9 @@ class Keypress < OpenAI::Internal::Type::BaseModel # # A collection of keypresses the model would like to perform. # - # @param keys [Array] The combination of keys the model is requesting to be pressed. This is an + # @param keys [Array] The combination of keys the model is requesting to be pressed. This is an array # - # @param type [Symbol, :keypress] Specifies the event type. For a keypress action, this property is + # @param type [Symbol, :keypress] Specifies the event type. For a keypress action, this property is always set to end class Move < OpenAI::Internal::Type::BaseModel @@ -438,23 +433,23 @@ class PendingSafetyCheck < OpenAI::Internal::Type::BaseModel # @!attribute code # The type of the pending safety check. # - # @return [String] - required :code, String + # @return [String, nil] + optional :code, String, nil?: true # @!attribute message # Details about the pending safety check. # - # @return [String] - required :message, String + # @return [String, nil] + optional :message, String, nil?: true - # @!method initialize(id:, code:, message:) + # @!method initialize(id:, code: nil, message: nil) # A pending safety check for the computer call. # # @param id [String] The ID of the pending safety check. # - # @param code [String] The type of the pending safety check. + # @param code [String, nil] The type of the pending safety check. # - # @param message [String] Details about the pending safety check. + # @param message [String, nil] Details about the pending safety check. end # The status of the item. One of `in_progress`, `completed`, or `incomplete`. diff --git a/lib/openai/models/responses/response_computer_tool_call_output_item.rb b/lib/openai/models/responses/response_computer_tool_call_output_item.rb index 3e19423b..cca213d0 100644 --- a/lib/openai/models/responses/response_computer_tool_call_output_item.rb +++ b/lib/openai/models/responses/response_computer_tool_call_output_item.rb @@ -70,23 +70,23 @@ class AcknowledgedSafetyCheck < OpenAI::Internal::Type::BaseModel # @!attribute code # The type of the pending safety check. # - # @return [String] - required :code, String + # @return [String, nil] + optional :code, String, nil?: true # @!attribute message # Details about the pending safety check. # - # @return [String] - required :message, String + # @return [String, nil] + optional :message, String, nil?: true - # @!method initialize(id:, code:, message:) + # @!method initialize(id:, code: nil, message: nil) # A pending safety check for the computer call. # # @param id [String] The ID of the pending safety check. # - # @param code [String] The type of the pending safety check. + # @param code [String, nil] The type of the pending safety check. # - # @param message [String] Details about the pending safety check. + # @param message [String, nil] Details about the pending safety check. end # The status of the message input. One of `in_progress`, `completed`, or diff --git a/lib/openai/models/responses/response_create_params.rb b/lib/openai/models/responses/response_create_params.rb index 1d5036d8..a5a6ba45 100644 --- a/lib/openai/models/responses/response_create_params.rb +++ b/lib/openai/models/responses/response_create_params.rb @@ -305,7 +305,7 @@ class ResponseCreateParams < OpenAI::Internal::Type::BaseModel # # @param conversation [String, OpenAI::Models::Responses::ResponseConversationParam, nil] The conversation that this response belongs to. Items from this conversation are # - # @param include [Array, nil] Specify additional output data to include in the model response. Currently + # @param include [Array, nil] Specify additional output data to include in the model response. Currently suppo # # @param input [String, Array] Text, image, or file inputs to the model, used to generate a response. # diff --git a/lib/openai/models/responses/response_includable.rb b/lib/openai/models/responses/response_includable.rb index 08bb23ff..c4c1959b 100644 --- a/lib/openai/models/responses/response_includable.rb +++ b/lib/openai/models/responses/response_includable.rb @@ -24,12 +24,14 @@ module Responses module ResponseIncludable extend OpenAI::Internal::Type::Enum - CODE_INTERPRETER_CALL_OUTPUTS = :"code_interpreter_call.outputs" - COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL = :"computer_call_output.output.image_url" FILE_SEARCH_CALL_RESULTS = :"file_search_call.results" + WEB_SEARCH_CALL_RESULTS = :"web_search_call.results" + WEB_SEARCH_CALL_ACTION_SOURCES = :"web_search_call.action.sources" MESSAGE_INPUT_IMAGE_IMAGE_URL = :"message.input_image.image_url" - MESSAGE_OUTPUT_TEXT_LOGPROBS = :"message.output_text.logprobs" + COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL = :"computer_call_output.output.image_url" + CODE_INTERPRETER_CALL_OUTPUTS = :"code_interpreter_call.outputs" REASONING_ENCRYPTED_CONTENT = :"reasoning.encrypted_content" + MESSAGE_OUTPUT_TEXT_LOGPROBS = :"message.output_text.logprobs" # @!method self.values # @return [Array] diff --git a/lib/openai/models/responses/response_input_item.rb b/lib/openai/models/responses/response_input_item.rb index cc4c7bc9..af672d03 100644 --- a/lib/openai/models/responses/response_input_item.rb +++ b/lib/openai/models/responses/response_input_item.rb @@ -508,10 +508,6 @@ class Action < OpenAI::Internal::Type::BaseModel optional :working_directory, String, nil?: true # @!method initialize(command:, env:, timeout_ms: nil, user: nil, working_directory: nil, type: :exec) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::ResponseInputItem::LocalShellCall::Action} for more - # details. - # # Execute a shell command on the server. # # @param command [Array] The command to run. diff --git a/lib/openai/models/responses/response_item.rb b/lib/openai/models/responses/response_item.rb index fa7aca0e..47cbb16f 100644 --- a/lib/openai/models/responses/response_item.rb +++ b/lib/openai/models/responses/response_item.rb @@ -199,10 +199,6 @@ class Action < OpenAI::Internal::Type::BaseModel optional :working_directory, String, nil?: true # @!method initialize(command:, env:, timeout_ms: nil, user: nil, working_directory: nil, type: :exec) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::ResponseItem::LocalShellCall::Action} for more - # details. - # # Execute a shell command on the server. # # @param command [Array] The command to run. diff --git a/lib/openai/models/responses/response_output_item.rb b/lib/openai/models/responses/response_output_item.rb index 34c8c3c0..857b16da 100644 --- a/lib/openai/models/responses/response_output_item.rb +++ b/lib/openai/models/responses/response_output_item.rb @@ -198,10 +198,6 @@ class Action < OpenAI::Internal::Type::BaseModel optional :working_directory, String, nil?: true # @!method initialize(command:, env:, timeout_ms: nil, user: nil, working_directory: nil, type: :exec) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::ResponseOutputItem::LocalShellCall::Action} for more - # details. - # # Execute a shell command on the server. # # @param command [Array] The command to run. diff --git a/lib/openai/models/responses/tool.rb b/lib/openai/models/responses/tool.rb index bb466067..b1247db0 100644 --- a/lib/openai/models/responses/tool.rb +++ b/lib/openai/models/responses/tool.rb @@ -30,11 +30,8 @@ module Tool # A tool that generates images using a model like `gpt-image-1`. variant :image_generation, -> { OpenAI::Responses::Tool::ImageGeneration } - # A tool that allows the model to execute shell commands in a local environment. variant :local_shell, -> { OpenAI::Responses::Tool::LocalShell } - # A custom tool that processes input using a specified format. Learn more about - # [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools). variant :custom, -> { OpenAI::Responses::CustomTool } # Search the Internet for sources related to the prompt. Learn more about the @@ -375,8 +372,7 @@ module Container # The container ID. variant String - # Configuration for a code interpreter container. Optionally specify the IDs - # of the files to run the code on. + # Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on. variant -> { OpenAI::Responses::Tool::CodeInterpreter::Container::CodeInterpreterToolAuto } class CodeInterpreterToolAuto < OpenAI::Internal::Type::BaseModel @@ -393,10 +389,6 @@ class CodeInterpreterToolAuto < OpenAI::Internal::Type::BaseModel optional :file_ids, OpenAI::Internal::Type::ArrayOf[String] # @!method initialize(file_ids: nil, type: :auto) - # Some parameter documentations has been truncated, see - # {OpenAI::Models::Responses::Tool::CodeInterpreter::Container::CodeInterpreterToolAuto} - # for more details. - # # Configuration for a code interpreter container. Optionally specify the IDs of # the files to run the code on. # @@ -498,7 +490,7 @@ class ImageGeneration < OpenAI::Internal::Type::BaseModel # # @param background [Symbol, OpenAI::Models::Responses::Tool::ImageGeneration::Background] Background type for the generated image. One of `transparent`, # - # @param input_fidelity [Symbol, OpenAI::Models::Responses::Tool::ImageGeneration::InputFidelity, nil] Control how much effort the model will exert to match the style and features, + # @param input_fidelity [Symbol, OpenAI::Models::Responses::Tool::ImageGeneration::InputFidelity, nil] # # @param input_image_mask [OpenAI::Models::Responses::Tool::ImageGeneration::InputImageMask] Optional mask for inpainting. Contains `image_url` # @@ -658,8 +650,6 @@ class LocalShell < OpenAI::Internal::Type::BaseModel required :type, const: :local_shell # @!method initialize(type: :local_shell) - # A tool that allows the model to execute shell commands in a local environment. - # # @param type [Symbol, :local_shell] The type of the local shell tool. Always `local_shell`. end diff --git a/lib/openai/resources/conversations/items.rb b/lib/openai/resources/conversations/items.rb index 90bfac5a..aabf3cd7 100644 --- a/lib/openai/resources/conversations/items.rb +++ b/lib/openai/resources/conversations/items.rb @@ -79,7 +79,7 @@ def retrieve(item_id, params) # # @param after [String] An item ID to list items after, used in pagination. # - # @param include [Array] Specify additional output data to include in the model response. Currently + # @param include [Array] Specify additional output data to include in the model response. Currently suppo # # @param limit [Integer] A limit on the number of objects to be returned. Limit can range between # diff --git a/lib/openai/resources/images.rb b/lib/openai/resources/images.rb index f245cab7..b1c0164c 100644 --- a/lib/openai/resources/images.rb +++ b/lib/openai/resources/images.rb @@ -55,7 +55,7 @@ def create_variation(params) # # @param background [Symbol, OpenAI::Models::ImageEditParams::Background, nil] Allows to set transparency for the background of the generated image(s). # - # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] Control how much effort the model will exert to match the style and features, + # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] # # @param mask [Pathname, StringIO, IO, String, OpenAI::FilePart] An additional image whose fully transparent areas (e.g. where alpha is zero) ind # @@ -114,7 +114,7 @@ def edit(params) # # @param background [Symbol, OpenAI::Models::ImageEditParams::Background, nil] Allows to set transparency for the background of the generated image(s). # - # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] Control how much effort the model will exert to match the style and features, + # @param input_fidelity [Symbol, OpenAI::Models::ImageEditParams::InputFidelity, nil] # # @param mask [Pathname, StringIO, IO, String, OpenAI::FilePart] An additional image whose fully transparent areas (e.g. where alpha is zero) ind # diff --git a/lib/openai/resources/responses.rb b/lib/openai/resources/responses.rb index 0f516293..3f5f38fc 100644 --- a/lib/openai/resources/responses.rb +++ b/lib/openai/resources/responses.rb @@ -29,7 +29,7 @@ class Responses # # @param conversation [String, OpenAI::Models::Responses::ResponseConversationParam, nil] The conversation that this response belongs to. Items from this conversation are # - # @param include [Array, nil] Specify additional output data to include in the model response. Currently + # @param include [Array, nil] Specify additional output data to include in the model response. Currently suppo # # @param input [String, Array] Text, image, or file inputs to the model, used to generate a response. # @@ -128,7 +128,7 @@ def create(params = {}) # # @param conversation [String, OpenAI::Models::Responses::ResponseConversationParam, nil] The conversation that this response belongs to. Items from this conversation are # - # @param include [Array, nil] Specify additional output data to include in the model response. Currently + # @param include [Array, nil] Specify additional output data to include in the model response. Currently suppo # # @param input [String, Array] Text, image, or file inputs to the model, used to generate a response. # diff --git a/rbi/openai/models/custom_tool_input_format.rbi b/rbi/openai/models/custom_tool_input_format.rbi index d2f57068..079defcf 100644 --- a/rbi/openai/models/custom_tool_input_format.rbi +++ b/rbi/openai/models/custom_tool_input_format.rbi @@ -27,7 +27,6 @@ module OpenAI sig { returns(Symbol) } attr_accessor :type - # Unconstrained free-form text. sig { params(type: Symbol).returns(T.attached_class) } def self.new( # Unconstrained text format. Always `text`. @@ -63,7 +62,6 @@ module OpenAI sig { returns(Symbol) } attr_accessor :type - # A grammar defined by the user. sig do params( definition: String, diff --git a/rbi/openai/models/responses/custom_tool.rbi b/rbi/openai/models/responses/custom_tool.rbi index 066ca268..598ee419 100644 --- a/rbi/openai/models/responses/custom_tool.rbi +++ b/rbi/openai/models/responses/custom_tool.rbi @@ -48,8 +48,6 @@ module OpenAI end attr_writer :format_ - # A custom tool that processes input using a specified format. Learn more about - # [custom tools](https://platform.openai.com/docs/guides/function-calling#custom-tools). sig do params( name: String, diff --git a/rbi/openai/models/responses/response_code_interpreter_tool_call.rbi b/rbi/openai/models/responses/response_code_interpreter_tool_call.rbi index 1d3f422f..2b082f5e 100644 --- a/rbi/openai/models/responses/response_code_interpreter_tool_call.rbi +++ b/rbi/openai/models/responses/response_code_interpreter_tool_call.rbi @@ -140,7 +140,7 @@ module OpenAI sig { returns(String) } attr_accessor :logs - # The type of the output. Always 'logs'. + # The type of the output. Always `logs`. sig { returns(Symbol) } attr_accessor :type @@ -149,7 +149,7 @@ module OpenAI def self.new( # The logs output from the code interpreter. logs:, - # The type of the output. Always 'logs'. + # The type of the output. Always `logs`. type: :logs ) end @@ -168,7 +168,7 @@ module OpenAI ) end - # The type of the output. Always 'image'. + # The type of the output. Always `image`. sig { returns(Symbol) } attr_accessor :type @@ -181,7 +181,7 @@ module OpenAI def self.new( # The URL of the image output from the code interpreter. url:, - # The type of the output. Always 'image'. + # The type of the output. Always `image`. type: :image ) end diff --git a/rbi/openai/models/responses/response_computer_tool_call.rbi b/rbi/openai/models/responses/response_computer_tool_call.rbi index 8bdf6af6..1cc99e3b 100644 --- a/rbi/openai/models/responses/response_computer_tool_call.rbi +++ b/rbi/openai/models/responses/response_computer_tool_call.rbi @@ -173,8 +173,7 @@ module OpenAI end attr_accessor :button - # Specifies the event type. For a click action, this property is always set to - # `click`. + # Specifies the event type. For a click action, this property is always `click`. sig { returns(Symbol) } attr_accessor :type @@ -204,8 +203,7 @@ module OpenAI x:, # The y-coordinate where the click occurred. y_:, - # Specifies the event type. For a click action, this property is always set to - # `click`. + # Specifies the event type. For a click action, this property is always `click`. type: :click ) end @@ -410,7 +408,7 @@ module OpenAI sig { returns(Integer) } attr_accessor :y_ - # A series of x/y coordinate pairs in the drag path. + # An x/y coordinate pair, e.g. `{ x: 100, y: 200 }`. sig { params(x: Integer, y_: Integer).returns(T.attached_class) } def self.new( # The x-coordinate. @@ -695,31 +693,39 @@ module OpenAI attr_accessor :id # The type of the pending safety check. - sig { returns(String) } + sig { returns(T.nilable(String)) } attr_accessor :code # Details about the pending safety check. - sig { returns(String) } + sig { returns(T.nilable(String)) } attr_accessor :message # A pending safety check for the computer call. sig do - params(id: String, code: String, message: String).returns( - T.attached_class - ) + params( + id: String, + code: T.nilable(String), + message: T.nilable(String) + ).returns(T.attached_class) end def self.new( # The ID of the pending safety check. id:, # The type of the pending safety check. - code:, + code: nil, # Details about the pending safety check. - message: + message: nil ) end sig do - override.returns({ id: String, code: String, message: String }) + override.returns( + { + id: String, + code: T.nilable(String), + message: T.nilable(String) + } + ) end def to_hash end diff --git a/rbi/openai/models/responses/response_computer_tool_call_output_item.rbi b/rbi/openai/models/responses/response_computer_tool_call_output_item.rbi index c56f05d6..1730a06c 100644 --- a/rbi/openai/models/responses/response_computer_tool_call_output_item.rbi +++ b/rbi/openai/models/responses/response_computer_tool_call_output_item.rbi @@ -147,31 +147,39 @@ module OpenAI attr_accessor :id # The type of the pending safety check. - sig { returns(String) } + sig { returns(T.nilable(String)) } attr_accessor :code # Details about the pending safety check. - sig { returns(String) } + sig { returns(T.nilable(String)) } attr_accessor :message # A pending safety check for the computer call. sig do - params(id: String, code: String, message: String).returns( - T.attached_class - ) + params( + id: String, + code: T.nilable(String), + message: T.nilable(String) + ).returns(T.attached_class) end def self.new( # The ID of the pending safety check. id:, # The type of the pending safety check. - code:, + code: nil, # Details about the pending safety check. - message: + message: nil ) end sig do - override.returns({ id: String, code: String, message: String }) + override.returns( + { + id: String, + code: T.nilable(String), + message: T.nilable(String) + } + ) end def to_hash end diff --git a/rbi/openai/models/responses/response_includable.rbi b/rbi/openai/models/responses/response_includable.rbi index 3c6236a7..06c2ac37 100644 --- a/rbi/openai/models/responses/response_includable.rbi +++ b/rbi/openai/models/responses/response_includable.rbi @@ -28,19 +28,19 @@ module OpenAI T.type_alias { T.all(Symbol, OpenAI::Responses::ResponseIncludable) } OrSymbol = T.type_alias { T.any(Symbol, String) } - CODE_INTERPRETER_CALL_OUTPUTS = + FILE_SEARCH_CALL_RESULTS = T.let( - :"code_interpreter_call.outputs", + :"file_search_call.results", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) - COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL = + WEB_SEARCH_CALL_RESULTS = T.let( - :"computer_call_output.output.image_url", + :"web_search_call.results", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) - FILE_SEARCH_CALL_RESULTS = + WEB_SEARCH_CALL_ACTION_SOURCES = T.let( - :"file_search_call.results", + :"web_search_call.action.sources", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) MESSAGE_INPUT_IMAGE_IMAGE_URL = @@ -48,9 +48,14 @@ module OpenAI :"message.input_image.image_url", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) - MESSAGE_OUTPUT_TEXT_LOGPROBS = + COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL = T.let( - :"message.output_text.logprobs", + :"computer_call_output.output.image_url", + OpenAI::Responses::ResponseIncludable::TaggedSymbol + ) + CODE_INTERPRETER_CALL_OUTPUTS = + T.let( + :"code_interpreter_call.outputs", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) REASONING_ENCRYPTED_CONTENT = @@ -58,6 +63,11 @@ module OpenAI :"reasoning.encrypted_content", OpenAI::Responses::ResponseIncludable::TaggedSymbol ) + MESSAGE_OUTPUT_TEXT_LOGPROBS = + T.let( + :"message.output_text.logprobs", + OpenAI::Responses::ResponseIncludable::TaggedSymbol + ) sig do override.returns( diff --git a/rbi/openai/models/responses/tool.rbi b/rbi/openai/models/responses/tool.rbi index 206960fb..74fa7744 100644 --- a/rbi/openai/models/responses/tool.rbi +++ b/rbi/openai/models/responses/tool.rbi @@ -1335,7 +1335,6 @@ module OpenAI sig { returns(Symbol) } attr_accessor :type - # A tool that allows the model to execute shell commands in a local environment. sig { params(type: Symbol).returns(T.attached_class) } def self.new( # The type of the local shell tool. Always `local_shell`. diff --git a/sig/openai/models/responses/response_computer_tool_call.rbs b/sig/openai/models/responses/response_computer_tool_call.rbs index 094df5fd..91715705 100644 --- a/sig/openai/models/responses/response_computer_tool_call.rbs +++ b/sig/openai/models/responses/response_computer_tool_call.rbs @@ -253,18 +253,22 @@ module OpenAI end type pending_safety_check = - { id: String, code: String, message: String } + { id: String, code: String?, message: String? } class PendingSafetyCheck < OpenAI::Internal::Type::BaseModel attr_accessor id: String - attr_accessor code: String + attr_accessor code: String? - attr_accessor message: String + attr_accessor message: String? - def initialize: (id: String, code: String, message: String) -> void + def initialize: ( + id: String, + ?code: String?, + ?message: String? + ) -> void - def to_hash: -> { id: String, code: String, message: String } + def to_hash: -> { id: String, code: String?, message: String? } end type status = :in_progress | :completed | :incomplete diff --git a/sig/openai/models/responses/response_computer_tool_call_output_item.rbs b/sig/openai/models/responses/response_computer_tool_call_output_item.rbs index a21f2310..4be56508 100644 --- a/sig/openai/models/responses/response_computer_tool_call_output_item.rbs +++ b/sig/openai/models/responses/response_computer_tool_call_output_item.rbs @@ -51,18 +51,22 @@ module OpenAI } type acknowledged_safety_check = - { id: String, code: String, message: String } + { id: String, code: String?, message: String? } class AcknowledgedSafetyCheck < OpenAI::Internal::Type::BaseModel attr_accessor id: String - attr_accessor code: String + attr_accessor code: String? - attr_accessor message: String + attr_accessor message: String? - def initialize: (id: String, code: String, message: String) -> void + def initialize: ( + id: String, + ?code: String?, + ?message: String? + ) -> void - def to_hash: -> { id: String, code: String, message: String } + def to_hash: -> { id: String, code: String?, message: String? } end type status = :in_progress | :completed | :incomplete diff --git a/sig/openai/models/responses/response_includable.rbs b/sig/openai/models/responses/response_includable.rbs index 5d4fdc9c..9fdbba46 100644 --- a/sig/openai/models/responses/response_includable.rbs +++ b/sig/openai/models/responses/response_includable.rbs @@ -2,22 +2,26 @@ module OpenAI module Models module Responses type response_includable = - :"code_interpreter_call.outputs" - | :"computer_call_output.output.image_url" - | :"file_search_call.results" + :"file_search_call.results" + | :"web_search_call.results" + | :"web_search_call.action.sources" | :"message.input_image.image_url" - | :"message.output_text.logprobs" + | :"computer_call_output.output.image_url" + | :"code_interpreter_call.outputs" | :"reasoning.encrypted_content" + | :"message.output_text.logprobs" module ResponseIncludable extend OpenAI::Internal::Type::Enum - CODE_INTERPRETER_CALL_OUTPUTS: :"code_interpreter_call.outputs" - COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL: :"computer_call_output.output.image_url" FILE_SEARCH_CALL_RESULTS: :"file_search_call.results" + WEB_SEARCH_CALL_RESULTS: :"web_search_call.results" + WEB_SEARCH_CALL_ACTION_SOURCES: :"web_search_call.action.sources" MESSAGE_INPUT_IMAGE_IMAGE_URL: :"message.input_image.image_url" - MESSAGE_OUTPUT_TEXT_LOGPROBS: :"message.output_text.logprobs" + COMPUTER_CALL_OUTPUT_OUTPUT_IMAGE_URL: :"computer_call_output.output.image_url" + CODE_INTERPRETER_CALL_OUTPUTS: :"code_interpreter_call.outputs" REASONING_ENCRYPTED_CONTENT: :"reasoning.encrypted_content" + MESSAGE_OUTPUT_TEXT_LOGPROBS: :"message.output_text.logprobs" def self?.values: -> ::Array[OpenAI::Models::Responses::response_includable] end From 9ad8a3fdac7f672d2b36140fe8db1e434f5c05da Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sat, 18 Oct 2025 15:02:23 +0000 Subject: [PATCH 2/2] release: 0.33.1 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ Gemfile.lock | 2 +- README.md | 2 +- lib/openai/version.rb | 2 +- 5 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 57dc0c3d..bc3d0ace 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.33.0" + ".": "0.33.1" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b025468..f74fd0d9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 0.33.1 (2025-10-18) + +Full Changelog: [v0.33.0...v0.33.1](https://github.com/openai/openai-ruby/compare/v0.33.0...v0.33.1) + +### Bug Fixes + +* **api:** internal openapi updates ([1fbce8c](https://github.com/openai/openai-ruby/commit/1fbce8c1158482b361ea48ff996b1998031679bf)) + ## 0.33.0 (2025-10-17) Full Changelog: [v0.32.0...v0.33.0](https://github.com/openai/openai-ruby/compare/v0.32.0...v0.33.0) diff --git a/Gemfile.lock b/Gemfile.lock index e0f86a19..05fbb3ef 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - openai (0.33.0) + openai (0.33.1) connection_pool GEM diff --git a/README.md b/README.md index bb5b50f8..ceae67b8 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "openai", "~> 0.33.0" +gem "openai", "~> 0.33.1" ``` diff --git a/lib/openai/version.rb b/lib/openai/version.rb index a623bc18..d7eb790f 100644 --- a/lib/openai/version.rb +++ b/lib/openai/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module OpenAI - VERSION = "0.33.0" + VERSION = "0.33.1" end