Class: OpenAI::Models::DecisionCreateParams
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::DecisionCreateParams
- Extended by:
- Internal::Type::RequestParameters::Converter
- Includes:
- Internal::Type::RequestParameters
- Defined in:
- lib/openai/models/decision_create_params.rb,
sig/openai/models/decision_create_params.rbs
Overview
Defined Under Namespace
Modules: Input, Question Classes: PromptCacheOptions
Instance Attribute Summary collapse
-
#input ⇒ OpenAI::Models::DecisionCreateParams::input
The input to evaluate for every question.
-
#model ⇒ String
The model to use.
-
#prompt_cache_key ⇒ String?
Partition prompt cache reuse by caller-provided key.
-
#prompt_cache_options ⇒ (OpenAI::DecisionCreateParams::PromptCacheOptions
Options for prompt caching.
-
#questions ⇒ ::Array[OpenAI::Models::DecisionCreateParams::question]
Ask 1–400 questions about the input.
-
#safety_identifier ⇒ String?
Opaque caller-provided end-user identifier, scoped by the verified org.
Attributes included from Internal::Type::RequestParameters
Attributes inherited from Internal::Type::BaseModel
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(label:, description: nil) ⇒ DecisionCreateParams
constructor
A new instance of DecisionCreateParams.
- #to_hash ⇒ { input: OpenAI::Models::DecisionCreateParams::input, model: String, questions: ::Array[OpenAI::Models::DecisionCreateParams::question], ?prompt_cache_key: String?, ?prompt_cache_options: (OpenAI::DecisionCreateParams::PromptCacheOptions | OpenAI::Models::DecisionCreateParams::prompt_cache_options)?, ?safety_identifier: String?, ?request_options: OpenAI::RequestOptions }
Methods included from Internal::Type::RequestParameters::Converter
Methods included from Internal::Type::RequestParameters
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(label:, description: nil) ⇒ DecisionCreateParams
Returns a new instance of DecisionCreateParams.
|
|
# File 'lib/openai/models/decision_create_params.rb', line 58
|
Instance Attribute Details
#input ⇒ OpenAI::Models::DecisionCreateParams::input
The input to evaluate for every question. Provide a text string or an ordered array of messages, function calls and outputs, or custom tool calls and outputs. Each tool output must identify a matching call by call ID.
16 |
# File 'lib/openai/models/decision_create_params.rb', line 16 required :input, union: -> { OpenAI::DecisionCreateParams::Input } |
#model ⇒ String
The model to use. Only gpt-6-luna is supported.
22 |
# File 'lib/openai/models/decision_create_params.rb', line 22 required :model, String |
#prompt_cache_key ⇒ String?
Partition prompt cache reuse by caller-provided key.
35 |
# File 'lib/openai/models/decision_create_params.rb', line 35 optional :prompt_cache_key, String, nil?: true |
#prompt_cache_options ⇒ (OpenAI::DecisionCreateParams::PromptCacheOptions
Options for prompt caching. Supported for gpt-5.6 and later models. By
default, OpenAI automatically chooses one implicit cache breakpoint. You can add
explicit breakpoints to content blocks with prompt_cache_breakpoint. Each
request can write up to four breakpoints. For cache matching, OpenAI considers
up to the latest 80 breakpoints in the conversation, without a content-block
lookback limit. Set mode to explicit to disable the implicit breakpoint. The
ttl defaults to 30m, which is currently the only supported value. See the
prompt caching guide
for current details.
49 |
# File 'lib/openai/models/decision_create_params.rb', line 49 optional :prompt_cache_options, -> { OpenAI::DecisionCreateParams::PromptCacheOptions }, nil?: true |
#questions ⇒ ::Array[OpenAI::Models::DecisionCreateParams::question]
Ask 1–400 questions about the input. Each question can be a predicate, choice, or score. Answers come back in the same order.
29 |
# File 'lib/openai/models/decision_create_params.rb', line 29 required :questions, -> { OpenAI::Internal::Type::ArrayOf[union: OpenAI::DecisionCreateParams::Question] } |
#safety_identifier ⇒ String?
Opaque caller-provided end-user identifier, scoped by the verified org. Match Responses' limit; this is never the authenticated user identity.
56 |
# File 'lib/openai/models/decision_create_params.rb', line 56 optional :safety_identifier, String, nil?: true |
Class Method Details
.variants ⇒ Array(OpenAI::Models::DecisionCreateParams::Question::Predicate, OpenAI::Models::DecisionCreateParams::Question::Choice, OpenAI::Models::DecisionCreateParams::Question::Score)
|
|
# File 'lib/openai/models/decision_create_params.rb', line 1053
|
Instance Method Details
#to_hash ⇒ { input: OpenAI::Models::DecisionCreateParams::input, model: String, questions: ::Array[OpenAI::Models::DecisionCreateParams::question], ?prompt_cache_key: String?, ?prompt_cache_options: (OpenAI::DecisionCreateParams::PromptCacheOptions | OpenAI::Models::DecisionCreateParams::prompt_cache_options)?, ?safety_identifier: String?, ?request_options: OpenAI::RequestOptions }
151 152 153 154 155 156 157 158 159 160 |
# File 'sig/openai/models/decision_create_params.rbs', line 151
def to_hash: -> {
input: OpenAI::Models::DecisionCreateParams::input,
model: String,
questions: ::Array[OpenAI::Models::DecisionCreateParams::question],
?prompt_cache_key: String?,
?prompt_cache_options: (OpenAI::DecisionCreateParams::PromptCacheOptions
| OpenAI::Models::DecisionCreateParams::prompt_cache_options)?,
?safety_identifier: String?,
?request_options: OpenAI::RequestOptions
}
|