Class: OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions

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

Defined Under Namespace

Modules: CompletionWindow

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(completion_window: nil, continuation_id: nil) ⇒ BackgroundOptions

Returns a new instance of BackgroundOptions.

Parameters:

  • completion_window (defaults to: nil) —

    The completion window for background execution. Defaults to soonest; 2h and 8h select discounted background execution.

  • continuation_id (defaults to: nil) —

    A customer-provided opaque identifier used to prioritize related background requests. It does not add prior history to the input.

  • completion_window: (OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window) (defaults to: nil)
  • continuation_id: (String) (defaults to: nil)


# File 'lib/openai/models/beta/response_create_params.rb', line 738

Instance Attribute Details

#completion_window ⇒ OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window?

The completion window for background execution. Defaults to soonest; 2h and 8h select discounted background execution.

Returns:

  • (OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window, nil)


726
727
728
729
# File 'lib/openai/models/beta/response_create_params.rb', line 726

optional(
  :completion_window,
  enum: -> { OpenAI::Beta::ResponseCreateParams::BackgroundOptions::CompletionWindow }
)

#continuation_id ⇒ String?

A customer-provided opaque identifier used to prioritize related background requests. It does not add prior history to the input.

Returns:

  • (String, nil)


736
# File 'lib/openai/models/beta/response_create_params.rb', line 736

optional :continuation_id, String

Instance Method Details

#to_hash ⇒ { ?completion_window: OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window, ?continuation_id: String }

Returns:

  • ({ ?completion_window: OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window, ?continuation_id: String })


820
821
822
823
# File 'sig/openai/models/beta/response_create_params.rbs', line 820

def to_hash: -> {
  ?completion_window: OpenAI::Models::Beta::ResponseCreateParams::BackgroundOptions::completion_window,
  ?continuation_id: String
}