Module: Anthropic::Models::Beta::BetaCacheMissReason
- Extended by:
- Internal::Type::Union
- Defined in:
- lib/anthropic/models/beta/beta_cache_miss_reason.rb,
sig/anthropic/models/beta/beta_cache_miss_reason.rbs
Defined Under Namespace
Modules: Type
Class Method Summary collapse
-
.new(type:, **args) ⇒ Anthropic::Models::Beta::BetaCacheMissModelChanged, ...
Creates a new instance of the variant class whose
typematches the given value, passing the remaining arguments to its constructor. - .values ⇒ Array<Symbol>
- .variants ⇒ Array(Anthropic::Models::Beta::BetaCacheMissModelChanged, Anthropic::Models::Beta::BetaCacheMissSystemChanged, Anthropic::Models::Beta::BetaCacheMissToolsChanged, Anthropic::Models::Beta::BetaCacheMissMessagesChanged, Anthropic::Models::Beta::BetaCacheMissPreviousMessageNotFound, Anthropic::Models::Beta::BetaCacheMissUnavailable)
Methods included from Internal::Type::Union
==, ===, coerce, derefed_variants, dump, hash, inspect, to_sorbet_type
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, meta_info, new_coerce_state, type_info
Class Method Details
.new(type:, cache_missed_input_tokens:) ⇒ Anthropic::Beta::BetaCacheMissModelChanged .new(type:, cache_missed_input_tokens:) ⇒ Anthropic::Beta::BetaCacheMissSystemChanged .new(type:, cache_missed_input_tokens:) ⇒ Anthropic::Beta::BetaCacheMissToolsChanged .new(type:, cache_missed_input_tokens:) ⇒ Anthropic::Beta::BetaCacheMissMessagesChanged .new(type:) ⇒ Anthropic::Beta::BetaCacheMissPreviousMessageNotFound .new(type:) ⇒ Anthropic::Beta::BetaCacheMissUnavailable .new(type:, cache_missed_input_tokens:) ⇒ Anthropic::Models::Beta::beta_cache_miss_reason
Creates a new instance of the variant class whose type matches the given
value, passing the remaining arguments to its constructor.
Some parameter documentations has been truncated, see Anthropic::Models::Beta::BetaCacheMissReason for more details.
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
# File 'lib/anthropic/models/beta/beta_cache_miss_reason.rb', line 76 def self.new(type:, **args) case type.to_sym when :model_changed Anthropic::Beta::BetaCacheMissModelChanged.new(**args) when :system_changed Anthropic::Beta::BetaCacheMissSystemChanged.new(**args) when :tools_changed Anthropic::Beta::BetaCacheMissToolsChanged.new(**args) when :messages_changed Anthropic::Beta::BetaCacheMissMessagesChanged.new(**args) when :previous_message_not_found Anthropic::Beta::BetaCacheMissPreviousMessageNotFound.new(**args) when :unavailable Anthropic::Beta::BetaCacheMissUnavailable.new(**args) else raise ArgumentError, "unknown type: #{type}" end end |
.values ⇒ Array<Symbol>
|
|
# File 'lib/anthropic/models/beta/beta_cache_miss_reason.rb', line 55
|
.variants ⇒ Array(Anthropic::Models::Beta::BetaCacheMissModelChanged, Anthropic::Models::Beta::BetaCacheMissSystemChanged, Anthropic::Models::Beta::BetaCacheMissToolsChanged, Anthropic::Models::Beta::BetaCacheMissMessagesChanged, Anthropic::Models::Beta::BetaCacheMissPreviousMessageNotFound, Anthropic::Models::Beta::BetaCacheMissUnavailable)
|
|
# File 'lib/anthropic/models/beta/beta_cache_miss_reason.rb', line 59
|