Class: Telnyx::Models::SpeechToTextListProvidersResponse::Data

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/telnyx/models/speech_to_text_list_providers_response.rb,
sig/telnyx/models/speech_to_text_list_providers_response.rbs

Defined Under Namespace

Classes: ServiceType

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, 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, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, 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(data:, meta:) ⇒ Object

List of supported STT providers and models.



24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
# File 'lib/telnyx/models/speech_to_text_list_providers_response.rb', line 24

class Data < Telnyx::Internal::Type::BaseModel
  # @!attribute hosted
  #   Whether this model runs on Telnyx-hosted infrastructure (`true`) or is provided
  #   by a third-party vendor (`false`).
  #
  #   @return [Boolean]
  required :hosted, Telnyx::Internal::Type::Boolean

  # @!attribute model
  #   Provider-scoped model name.
  #
  #   @return [String]
  required :model, String

  # @!attribute provider
  #   STT provider name.
  #
  #   @return [String]
  required :provider, String

  # @!attribute service_types
  #   Service surfaces this (provider, model) supports. When the request filters by
  #   `service_type`, only the matching nested entry is returned for each matching
  #   model.
  #
  #   @return [Array<Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType>]
  required :service_types,
           -> { Telnyx::Internal::Type::ArrayOf[Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType] }

  # @!method initialize(hosted:, model:, provider:, service_types:)
  #   Some parameter documentations has been truncated, see
  #   {Telnyx::Models::SpeechToTextListProvidersResponse::Data} for more details.
  #
  #   A (provider, model) tuple along with the service surfaces it supports. Each
  #   entry in `service_types` describes one surface and the languages accepted on it.
  #
  #   @param hosted [Boolean] Whether this model runs on Telnyx-hosted infrastructure (`true`) or is provided
  #
  #   @param model [String] Provider-scoped model name.
  #
  #   @param provider [String] STT provider name.
  #
  #   @param service_types [Array<Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType>] Service surfaces this (provider, model) supports. When the request filters by `s

  class ServiceType < Telnyx::Internal::Type::BaseModel
    # @!attribute languages
    #   Languages accepted on this service surface, in the provider's native code
    #   format. `auto` indicates the provider performs language detection.
    #
    #   @return [Array<String>]
    required :languages, Telnyx::Internal::Type::ArrayOf[String]

    # @!attribute type
    #   Service surface a model is available on. `ai_assistant` is the STT surface
    #   configured via Call Control voice-assistant transcription; it covers both
    #   live-streaming and non-streaming/batch models (matching the
    #   `TranscriptionConfig.model` enum on `call-control` voice assistants).
    #
    #   @return [Symbol, Telnyx::Models::SttServiceType]
    required :type, enum: -> { Telnyx::SttServiceType }

    # @!method initialize(languages:, type:)
    #   Some parameter documentations has been truncated, see
    #   {Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType} for more
    #   details.
    #
    #   A supported service surface for a given (provider, model), along with the
    #   language codes accepted on that surface. Language support can differ per surface
    #   — for example, a model may accept a narrower language set for streaming than for
    #   file transcription.
    #
    #   @param languages [Array<String>] Languages accepted on this service surface, in the provider's native code format
    #
    #   @param type [Symbol, Telnyx::Models::SttServiceType] Service surface a model is available on. `ai_assistant` is the STT surface confi
  end
end

Instance Attribute Details

#hostedBoolean

Whether this model runs on Telnyx-hosted infrastructure (true) or is provided by a third-party vendor (false).

Parameters:

  • value (Boolean)

Returns:

  • (Boolean)


30
# File 'lib/telnyx/models/speech_to_text_list_providers_response.rb', line 30

required :hosted, Telnyx::Internal::Type::Boolean

#modelString

Provider-scoped model name.

Parameters:

  • value (String)

Returns:

  • (String)


36
# File 'lib/telnyx/models/speech_to_text_list_providers_response.rb', line 36

required :model, String

#providerString

STT provider name.

Parameters:

  • value (String)

Returns:

  • (String)


42
# File 'lib/telnyx/models/speech_to_text_list_providers_response.rb', line 42

required :provider, String

#service_typesArray<Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType>

Service surfaces this (provider, model) supports. When the request filters by service_type, only the matching nested entry is returned for each matching model.



50
51
# File 'lib/telnyx/models/speech_to_text_list_providers_response.rb', line 50

required :service_types,
-> { Telnyx::Internal::Type::ArrayOf[Telnyx::Models::SpeechToTextListProvidersResponse::Data::ServiceType] }

Instance Method Details

#to_hash{

Returns:

  • ({)


48
# File 'sig/telnyx/models/speech_to_text_list_providers_response.rbs', line 48

def to_hash: -> {