Class: OpenAI::Models::Beta::AgentOutputItem::ComputerUseCall

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/openai/models/beta/agent_output_item.rb,
sig/openai/models/beta/agent_output_item.rbs

Defined Under Namespace

Classes: Output

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], #_request_id, #_set_last_response, coerce, #deconstruct_keys, #deep_to_h, dump, #encode_with, 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, coerce_cached, coerce_with_error, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, resolve_type, 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(id:, output:, status:, title:, turn_id:, type: :computer_use_call) ⇒ ComputerUseCall

Returns a new instance of ComputerUseCall.

Parameters:

  • id —

    The ID of the activity item.

  • output —

    The last screenshot emitted by the model. Null when screenshot inclusion is disabled or the call emitted no screenshot.

  • status —

    The execution status of the activity.

  • title —

    A model-generated description of the activity, when available.

  • turn_id —

    The ID of the turn that contains this item.

  • type (defaults to: :computer_use_call) —

    The item type. Always computer_use_call.

  • id: (String)
  • output: (OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output, nil)
  • status: (OpenAI::Models::Beta::agent_function_call_status)
  • title: (String, nil)
  • turn_id: (String)
  • type: (:computer_use_call) (defaults to: :computer_use_call)


# File 'lib/openai/models/beta/agent_output_item.rb', line 92

Instance Attribute Details

#id ⇒ String

The ID of the activity item.

Returns:

  • (String)


59
# File 'lib/openai/models/beta/agent_output_item.rb', line 59

required :id, String

#output ⇒ OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output?

The last screenshot emitted by the model. Null when screenshot inclusion is disabled or the call emitted no screenshot.

Returns:

  • (OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output, nil)


66
# File 'lib/openai/models/beta/agent_output_item.rb', line 66

required :output, -> { OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output }, nil?: true

#status ⇒ OpenAI::Models::Beta::agent_function_call_status

The execution status of the activity.

Returns:

  • (OpenAI::Models::Beta::agent_function_call_status)


72
# File 'lib/openai/models/beta/agent_output_item.rb', line 72

required :status, enum: -> { OpenAI::Beta::AgentFunctionCallStatus }

#title ⇒ String?

A model-generated description of the activity, when available.

Returns:

  • (String, nil)


78
# File 'lib/openai/models/beta/agent_output_item.rb', line 78

required :title, String, nil?: true

#turn_id ⇒ String

The ID of the turn that contains this item.

Returns:

  • (String)


84
# File 'lib/openai/models/beta/agent_output_item.rb', line 84

required :turn_id, String

#type ⇒ :computer_use_call

The item type. Always computer_use_call.

Returns:

  • (:computer_use_call)


90
# File 'lib/openai/models/beta/agent_output_item.rb', line 90

required :type, const: :computer_use_call

Instance Method Details

#to_hash ⇒ { id: String, output: OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output?, status: OpenAI::Models::Beta::agent_function_call_status, title: String?, turn_id: String, ?type: :computer_use_call }

Returns:

  • ({ id: String, output: OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output?, status: OpenAI::Models::Beta::agent_function_call_status, title: String?, turn_id: String, ?type: :computer_use_call })


75
76
77
78
79
80
81
82
# File 'sig/openai/models/beta/agent_output_item.rbs', line 75

def to_hash: -> {
  id: String,
  output: OpenAI::Beta::AgentOutputItem::ComputerUseCall::Output?,
  status: OpenAI::Models::Beta::agent_function_call_status,
  title: String?,
  turn_id: String,
  ?type: :computer_use_call
}