Module: OpenAI::Models::Beta::Threads::RunCreateParams::AdditionalMessage::Attachment::Tool

Extended by:
Internal::Type::Union
Defined in:
lib/openai/models/beta/threads/run_create_params.rb

Defined Under Namespace

Classes: FileSearch

Instance Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, dump, hash, inspect, to_sorbet_type, variants

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, #dump, dump, #inspect, inspect, type_info

Instance Method Details

#initialize(file_id: nil, tools: nil) ⇒ Object

Parameters:



349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
# File 'lib/openai/models/beta/threads/run_create_params.rb', line 349

module Tool
  extend OpenAI::Internal::Type::Union

  discriminator :type

  variant :code_interpreter, -> { OpenAI::Beta::CodeInterpreterTool }

  variant :file_search,
          -> {
            OpenAI::Beta::Threads::RunCreateParams::AdditionalMessage::Attachment::Tool::FileSearch
          }

  class FileSearch < OpenAI::Internal::Type::BaseModel
    # @!attribute type
    #   The type of tool being defined: `file_search`
    #
    #   @return [Symbol, :file_search]
    required :type, const: :file_search

    # @!method initialize(type: :file_search)
    #   @param type [Symbol, :file_search] The type of tool being defined: `file_search`
  end

  # @!method self.variants
  #   @return [Array(OpenAI::Models::Beta::CodeInterpreterTool, OpenAI::Models::Beta::Threads::RunCreateParams::AdditionalMessage::Attachment::Tool::FileSearch)]
end