Class: OpenAI::Models::Responses::ResponseCodeInterpreterToolCall

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/responses/response_code_interpreter_tool_call.rb

Defined Under Namespace

Modules: Output, Status

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(url: , type: :image) ⇒ void

The image output from the code interpreter.

Parameters:

  • url (String) (defaults to: )

    The URL of the image output from the code interpreter.

  • type (Symbol, :image) (defaults to: :image)

    The type of the output. Always 'image'.



# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 49

Instance Attribute Details

#codeString?

The code to run, or null if not available.

Returns:

  • (String, nil)


17
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 17

required :code, String, nil?: true

#container_idString

The ID of the container used to run the code.

Returns:

  • (String)


23
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 23

required :container_id, String

#idString

The unique ID of the code interpreter tool call.

Returns:

  • (String)


11
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 11

required :id, String

#outputsArray<OpenAI::Models::Responses::ResponseCodeInterpreterToolCall::Output::Logs, OpenAI::Models::Responses::ResponseCodeInterpreterToolCall::Output::Image>?

The outputs generated by the code interpreter, such as logs or images. Can be null if no outputs are available.



30
31
32
33
34
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 30

required :outputs,
-> {
  OpenAI::Internal::Type::ArrayOf[union: OpenAI::Responses::ResponseCodeInterpreterToolCall::Output]
},
nil?: true

#statusSymbol, OpenAI::Models::Responses::ResponseCodeInterpreterToolCall::Status

The status of the code interpreter tool call. Valid values are in_progress, completed, incomplete, interpreting, and failed.



41
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 41

required :status, enum: -> { OpenAI::Responses::ResponseCodeInterpreterToolCall::Status }

#typeSymbol, :code_interpreter_call

The type of the code interpreter tool call. Always code_interpreter_call.

Returns:

  • (Symbol, :code_interpreter_call)


47
# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 47

required :type, const: :code_interpreter_call

Class Method Details

.variantsArray(OpenAI::Models::Responses::ResponseCodeInterpreterToolCall::Output::Logs, OpenAI::Models::Responses::ResponseCodeInterpreterToolCall::Output::Image)



# File 'lib/openai/models/responses/response_code_interpreter_tool_call.rb', line 121