Module: OpenAI::Models::Chat::ChatCompletionToolChoiceOption

Extended by:
Internal::Type::Union
Defined in:
lib/openai/models/chat/chat_completion_tool_choice_option.rb,
sig/openai/models/chat/chat_completion_tool_choice_option.rbs

Overview

Controls which (if any) tool is called by the model. none means the model will not call any tool and instead generates a message. auto means the model can pick between generating a message or calling one or more tools. required means the model must call one or more tools. Specifying a particular tool via {"type": "function", "function": {"name": "my_function"}} forces the model to call that tool.

none is the default when no tools are present. auto is the default if tools are present.

Defined Under Namespace

Modules: Auto

Class Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, derefed_variants, dump, hash, inspect, to_sorbet_type, variant_for_dump

Methods included from Internal::Util::SorbetRuntimeSupport

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

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

Class Method Details

.variants ⇒ ::Array[OpenAI::Models::Chat::chat_completion_tool_choice_option]

Returns:

  • (::Array[OpenAI::Models::Chat::chat_completion_tool_choice_option])


27
# File 'sig/openai/models/chat/chat_completion_tool_choice_option.rbs', line 27

def self?.variants: -> ::Array[OpenAI::Models::Chat::chat_completion_tool_choice_option]