Class: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall

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

Defined Under Namespace

Modules: Caller, Operation, Status Classes: Agent

Instance Attribute Summary collapse

Attributes inherited from Internal::Type::BaseModel

#last_response

Class Method Summary collapse

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(agent_name:) ⇒ ApplyPatchCall

Returns a new instance of ApplyPatchCall.

Parameters:

  • call_id —

    The unique ID of the apply patch tool call generated by the model.

  • operation —

    The specific create, delete, or update instruction for the apply_patch tool call.

  • status —

    The status of the apply patch tool call. One of in_progress or completed.

  • id —

    The unique ID of the apply patch tool call. Populated when this item is returned via API.

  • agent —

    The agent that produced this item.

  • caller_ —

    The execution context that produced this tool call.

  • type —

    The type of the item. Always apply_patch_call.

  • call_id: (String)
  • operation: (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation)
  • status: (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status)
  • id: (String, nil)
  • agent: (OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent, nil)
  • caller_: (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_, nil)
  • type: (:apply_patch_call)


# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2355

Instance Attribute Details

#agent ⇒ OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent?

The agent that produced this item.

Returns:

  • (OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent, nil)


2342
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2342

optional :agent, -> { OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent }, nil?: true

#call_id ⇒ String

The unique ID of the apply patch tool call generated by the model.

Returns:

  • (String)


2310
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2310

required :call_id, String

#caller_ ⇒ OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_?

The execution context that produced this tool call.

Returns:

  • (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_, nil)


2348
2349
2350
2351
2352
2353
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2348

optional(
  :caller_,
  union: -> { OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Caller },
  api_name: :caller,
  nil?: true
)

#id ⇒ String?

The unique ID of the apply patch tool call. Populated when this item is returned via API.

Returns:

  • (String, nil)


2336
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2336

optional :id, String, nil?: true

#operation ⇒ OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation

The specific create, delete, or update instruction for the apply_patch tool call.

Returns:

  • (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation)


2317
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2317

required :operation, union: -> { OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Operation }

#status ⇒ OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status

The status of the apply patch tool call. One of in_progress or completed.

Returns:

  • (OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status)


2323
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2323

required :status, enum: -> { OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Status }

#type ⇒ :apply_patch_call

The type of the item. Always apply_patch_call.

Returns:

  • (:apply_patch_call)


2329
# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2329

required :type, const: :apply_patch_call

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2500

.variants ⇒ Array(OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::Operation::CreateFile, OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::Operation::DeleteFile, OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::Operation::UpdateFile)



# File 'lib/openai/models/beta/beta_response_input_item.rb', line 2487

Instance Method Details

#to_hash ⇒ { call_id: String, operation: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation, status: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status, ?type: :apply_patch_call, ?id: String?, ?agent: OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent?, ?caller_: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_? }

Returns:

  • ({ call_id: String, operation: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation, status: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status, ?type: :apply_patch_call, ?id: String?, ?agent: OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent?, ?caller_: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_? })


2103
2104
2105
2106
2107
2108
2109
2110
2111
# File 'sig/openai/models/beta/beta_response_input_item.rbs', line 2103

def to_hash: -> {
  call_id: String,
  operation: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::operation,
  status: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::status,
  ?type: :apply_patch_call,
  ?id: String?,
  ?agent: OpenAI::Beta::BetaResponseInputItem::ApplyPatchCall::Agent?,
  ?caller_: OpenAI::Models::Beta::BetaResponseInputItem::ApplyPatchCall::caller_?
}