Class: OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput

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

Defined Under Namespace

Modules: Caller, Output, Status

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_with_error, dump, #dump, #inspect, inspect, meta_info, 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(caller_id:, type: :program) ⇒ Object

Parameters:

  • output

    Text, image, or file output of the function tool call.

  • id

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

  • call_id

    The unique ID of the function tool call generated by the model.

  • caller_

    The execution context that produced this tool call.

  • name

    The name of the tool that produced the output.

  • namespace

    The namespace of the tool that produced the output.

  • status

    The status of the item. One of in_progress, completed, or incomplete. Populated when items are returned via API.

  • type (defaults to: :program)

    The type of the function tool call output. Always function_call_output.



# File 'lib/openai/models/responses/response_input_item.rb', line 394

Instance Attribute Details

#call_idString?

The unique ID of the function tool call generated by the model.

Returns:

  • (String, nil)


358
# File 'lib/openai/models/responses/response_input_item.rb', line 358

optional :call_id, String, nil?: true

#caller_OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::caller_?

The execution context that produced this tool call.

Returns:

  • (OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::caller_, nil)


364
365
366
367
368
369
# File 'lib/openai/models/responses/response_input_item.rb', line 364

optional(
  :caller_,
  union: -> { OpenAI::Responses::ResponseInputItem::FunctionCallOutput::Caller },
  api_name: :caller,
  nil?: true
)

#idString?

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

Returns:

  • (String, nil)


352
# File 'lib/openai/models/responses/response_input_item.rb', line 352

optional :id, String, nil?: true

#nameString?

The name of the tool that produced the output.

Returns:

  • (String, nil)


375
# File 'lib/openai/models/responses/response_input_item.rb', line 375

optional :name, String, nil?: true

#namespaceString?

The namespace of the tool that produced the output.

Returns:

  • (String, nil)


381
# File 'lib/openai/models/responses/response_input_item.rb', line 381

optional :namespace, String, nil?: true

#outputOpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::output

Text, image, or file output of the function tool call.

Returns:

  • (OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::output)


339
# File 'lib/openai/models/responses/response_input_item.rb', line 339

required :output, union: -> { OpenAI::Responses::ResponseInputItem::FunctionCallOutput::Output }

#statusOpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::status?

The status of the item. One of in_progress, completed, or incomplete. Populated when items are returned via API.

Returns:

  • (OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::status, nil)


388
389
390
391
392
# File 'lib/openai/models/responses/response_input_item.rb', line 388

optional(
  :status,
  enum: -> { OpenAI::Responses::ResponseInputItem::FunctionCallOutput::Status },
  nil?: true
)

#type:function_call_output

The type of the function tool call output. Always function_call_output.

Returns:

  • (:function_call_output)


345
# File 'lib/openai/models/responses/response_input_item.rb', line 345

required :type, const: :function_call_output

Class Method Details

.variantsArray(OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::Caller::Direct, OpenAI::Models::Responses::ResponseInputItem::FunctionCallOutput::Caller::Program)



# File 'lib/openai/models/responses/response_input_item.rb', line 435

Instance Method Details

#to_hash{

Returns:

  • ({)


307
# File 'sig/openai/models/responses/response_input_item.rbs', line 307

def to_hash: -> {