telnyx 5.176.0 → 5.177.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/README.md +1 -1
- data/lib/telnyx/models/ai/chat_completion_request.rb +10 -4
- data/lib/telnyx/models/ai/inference_embedding_voice_settings.rb +67 -64
- data/lib/telnyx/models/ai/memory/namespaces/profile_ingest_params.rb +7 -16
- data/lib/telnyx/models/ai/memory/namespaces/profiles/source_retrieve_response.rb +7 -16
- data/lib/telnyx/models/ai/privacy_settings.rb +16 -14
- data/lib/telnyx/models/ai/readiness_probe.rb +8 -8
- data/lib/telnyx/models/ai/telephony_settings.rb +25 -1
- data/lib/telnyx/models/ai/typesafe/v1_systemone_params.rb +8 -8
- data/lib/telnyx/models/browser_sessions/wait_for_action.rb +11 -11
- data/lib/telnyx/models/calls/deepgram_flux_config.rb +91 -0
- data/lib/telnyx/models/calls/deepgram_flux_multi_config.rb +103 -0
- data/lib/telnyx/models/calls/deepgram_nova2_specialty_config.rb +113 -0
- data/lib/telnyx/models/calls/deepgram_nova3_medical_config.rb +110 -0
- data/lib/telnyx/models/calls/transcription_engine_community_config.rb +57 -0
- data/lib/telnyx/models/calls/transcription_engine_deepgram_config.rb +5 -372
- data/lib/telnyx/models/calls/transcription_start_request.rb +8 -459
- data/lib/telnyx/models/email_event_list_response.rb +11 -12
- data/lib/telnyx/models/iam/guardrail/iam_guardrail_statement.rb +94 -0
- data/lib/telnyx/models/iam/guardrail/iam_guardrail_statement_response.rb +20 -0
- data/lib/telnyx/models/iam/guardrail/statement_create_params.rb +50 -0
- data/lib/telnyx/models/iam/guardrail/statement_delete_params.rb +24 -0
- data/lib/telnyx/models/iam/guardrail/statement_list_params.rb +34 -0
- data/lib/telnyx/models/iam/guardrail/statement_update_params.rb +57 -0
- data/lib/telnyx/models/iam/guardrail_delete_all_params.rb +16 -0
- data/lib/telnyx/models/iam/iam_action.rb +4 -4
- data/lib/telnyx/models/iam/iam_settings.rb +60 -0
- data/lib/telnyx/models/iam/iam_settings_response.rb +3 -55
- data/lib/telnyx/models/iam/roles/iam_role_statement.rb +13 -1
- data/lib/telnyx/models/iam/roles/iam_role_statement_conditions.rb +27 -0
- data/lib/telnyx/models/iam/roles/statement_create_params.rb +9 -1
- data/lib/telnyx/models/iam/roles/statement_update_params.rb +9 -1
- data/lib/telnyx/models/iam_decision.rb +5 -3
- data/lib/telnyx/models/iam_explain_params.rb +13 -1
- data/lib/telnyx/models/iam_retrieve_access_logs_response.rb +6 -5
- data/lib/telnyx/models/iam_simulate_params.rb +13 -1
- data/lib/telnyx/models/messaging_inbound_message_payload.rb +15 -15
- data/lib/telnyx/models/mobile_phone_number.rb +25 -4
- data/lib/telnyx/models/mobile_phone_number_update_params.rb +38 -4
- data/lib/telnyx/models/model_metadata.rb +28 -1
- data/lib/telnyx/models/phone_numbers/emergency_settings.rb +56 -0
- data/lib/telnyx/models/phone_numbers/numbers_cnam_listing.rb +36 -0
- data/lib/telnyx/models/phone_numbers/numbers_phone_number_with_voice_settings.rb +9 -59
- data/lib/telnyx/models/phone_numbers/numbers_update_phone_number_voice_settings_request.rb +6 -4
- data/lib/telnyx/models/phone_numbers/phone_number_with_voice_settings.rb +3 -55
- data/lib/telnyx/models/sim_cards/action_bulk_enable_voice_params.rb +2 -2
- data/lib/telnyx/models/sim_cards/action_enable_voice_params.rb +2 -2
- data/lib/telnyx/models/texml/accounts/call_calls_params.rb +15 -15
- data/lib/telnyx/models/texml_application_list_params.rb +6 -6
- data/lib/telnyx/models/user_profile.rb +11 -1
- data/lib/telnyx/models/user_profile_patch_all_params.rb +1 -9
- data/lib/telnyx/models/whatsapp/business_accounts/phone_number_list_response.rb +223 -0
- data/lib/telnyx/models/whatsapp/phone_number_list_response.rb +220 -0
- data/lib/telnyx/models/whatsapp/whatsapp_phone_response.rb +0 -1
- data/lib/telnyx/resources/calls/actions.rb +1 -1
- data/lib/telnyx/resources/customer_service_records.rb +4 -4
- data/lib/telnyx/resources/iam/guardrail/statements.rb +158 -0
- data/lib/telnyx/resources/iam/guardrail.rb +45 -0
- data/lib/telnyx/resources/iam/roles/statements.rb +13 -6
- data/lib/telnyx/resources/iam.rb +21 -8
- data/lib/telnyx/resources/mobile_phone_numbers.rb +4 -1
- data/lib/telnyx/resources/phone_numbers/voice.rb +1 -1
- data/lib/telnyx/resources/user_profile.rb +1 -3
- data/lib/telnyx/resources/whatsapp/business_accounts/phone_numbers.rb +2 -2
- data/lib/telnyx/resources/whatsapp/phone_numbers.rb +2 -2
- data/lib/telnyx/version.rb +1 -1
- data/lib/telnyx.rb +20 -0
- data/rbi/telnyx/models/ai/chat_completion_request.rbi +15 -6
- data/rbi/telnyx/models/ai/inference_embedding_voice_settings.rbi +114 -97
- data/rbi/telnyx/models/ai/memory/namespaces/profile_ingest_params.rbi +12 -28
- data/rbi/telnyx/models/ai/memory/namespaces/profiles/source_retrieve_response.rbi +12 -28
- data/rbi/telnyx/models/ai/privacy_settings.rbi +24 -21
- data/rbi/telnyx/models/ai/readiness_probe.rbi +14 -8
- data/rbi/telnyx/models/ai/telephony_settings.rbi +79 -0
- data/rbi/telnyx/models/ai/typesafe/v1_systemone_params.rbi +4 -4
- data/rbi/telnyx/models/browser_sessions/wait_for_action.rbi +24 -24
- data/rbi/telnyx/models/calls/deepgram_flux_config.rbi +192 -0
- data/rbi/telnyx/models/calls/deepgram_flux_multi_config.rbi +251 -0
- data/rbi/telnyx/models/calls/deepgram_nova2_specialty_config.rbi +226 -0
- data/rbi/telnyx/models/calls/deepgram_nova3_medical_config.rbi +220 -0
- data/rbi/telnyx/models/calls/transcription_engine_community_config.rbi +94 -0
- data/rbi/telnyx/models/calls/transcription_engine_deepgram_config.rbi +4 -776
- data/rbi/telnyx/models/calls/transcription_start_request.rbi +25 -989
- data/rbi/telnyx/models/email_event_list_response.rbi +32 -18
- data/rbi/telnyx/models/iam/guardrail/iam_guardrail_statement.rbi +169 -0
- data/rbi/telnyx/models/iam/guardrail/iam_guardrail_statement_response.rbi +45 -0
- data/rbi/telnyx/models/iam/guardrail/statement_create_params.rbi +113 -0
- data/rbi/telnyx/models/iam/guardrail/statement_delete_params.rbi +42 -0
- data/rbi/telnyx/models/iam/guardrail/statement_list_params.rbi +64 -0
- data/rbi/telnyx/models/iam/guardrail/statement_update_params.rbi +109 -0
- data/rbi/telnyx/models/iam/guardrail_delete_all_params.rbi +32 -0
- data/rbi/telnyx/models/iam/iam_action.rbi +6 -4
- data/rbi/telnyx/models/iam/iam_settings.rbi +90 -0
- data/rbi/telnyx/models/iam/iam_settings_response.rbi +4 -105
- data/rbi/telnyx/models/iam/roles/iam_role_statement.rbi +18 -0
- data/rbi/telnyx/models/iam/roles/iam_role_statement_conditions.rbi +41 -0
- data/rbi/telnyx/models/iam/roles/statement_create_params.rbi +18 -0
- data/rbi/telnyx/models/iam/roles/statement_update_params.rbi +18 -0
- data/rbi/telnyx/models/iam_decision.rbi +10 -6
- data/rbi/telnyx/models/iam_explain_params.rbi +10 -0
- data/rbi/telnyx/models/iam_retrieve_access_logs_response.rbi +8 -6
- data/rbi/telnyx/models/iam_simulate_params.rbi +15 -3
- data/rbi/telnyx/models/messaging_inbound_message_payload.rbi +31 -31
- data/rbi/telnyx/models/mobile_phone_number.rbi +19 -0
- data/rbi/telnyx/models/mobile_phone_number_update_params.rbi +19 -0
- data/rbi/telnyx/models/model_metadata.rbi +90 -0
- data/rbi/telnyx/models/phone_numbers/emergency_settings.rbi +133 -0
- data/rbi/telnyx/models/phone_numbers/numbers_cnam_listing.rbi +62 -0
- data/rbi/telnyx/models/phone_numbers/numbers_phone_number_with_voice_settings.rbi +16 -145
- data/rbi/telnyx/models/phone_numbers/numbers_update_phone_number_voice_settings_request.rbi +12 -6
- data/rbi/telnyx/models/phone_numbers/phone_number_with_voice_settings.rbi +4 -139
- data/rbi/telnyx/models/sim_cards/action_bulk_enable_voice_params.rbi +4 -4
- data/rbi/telnyx/models/sim_cards/action_enable_voice_params.rbi +4 -4
- data/rbi/telnyx/models/texml/accounts/call_calls_params.rbi +15 -15
- data/rbi/telnyx/models/texml_application_list_params.rbi +7 -7
- data/rbi/telnyx/models/user_profile.rbi +11 -0
- data/rbi/telnyx/models/user_profile_patch_all_params.rbi +0 -11
- data/rbi/telnyx/models/whatsapp/business_accounts/phone_number_list_response.rbi +393 -0
- data/rbi/telnyx/models/whatsapp/phone_number_list_response.rbi +391 -0
- data/rbi/telnyx/resources/ai/openai/chat.rbi +5 -2
- data/rbi/telnyx/resources/calls/actions.rbi +5 -5
- data/rbi/telnyx/resources/iam/guardrail/statements.rbi +132 -0
- data/rbi/telnyx/resources/iam/guardrail.rbi +29 -0
- data/rbi/telnyx/resources/iam/roles/statements.rbi +16 -4
- data/rbi/telnyx/resources/iam.rbi +18 -7
- data/rbi/telnyx/resources/mobile_phone_numbers.rbi +2 -0
- data/rbi/telnyx/resources/phone_numbers/voice.rbi +4 -2
- data/rbi/telnyx/resources/sim_cards/actions.rbi +4 -4
- data/rbi/telnyx/resources/user_profile.rbi +0 -3
- data/rbi/telnyx/resources/whatsapp/business_accounts/phone_numbers.rbi +1 -1
- data/rbi/telnyx/resources/whatsapp/phone_numbers.rbi +1 -1
- data/sig/telnyx/models/ai/inference_embedding_voice_settings.rbs +50 -57
- data/sig/telnyx/models/ai/memory/namespaces/profile_ingest_params.rbs +3 -12
- data/sig/telnyx/models/ai/memory/namespaces/profiles/source_retrieve_response.rbs +3 -12
- data/sig/telnyx/models/ai/readiness_probe.rbs +11 -8
- data/sig/telnyx/models/ai/telephony_settings.rbs +21 -0
- data/sig/telnyx/models/ai/typesafe/v1_systemone_params.rbs +4 -4
- data/sig/telnyx/models/browser_sessions/wait_for_action.rbs +12 -13
- data/sig/telnyx/models/calls/deepgram_flux_config.rbs +80 -0
- data/sig/telnyx/models/calls/deepgram_flux_multi_config.rbs +91 -0
- data/sig/telnyx/models/calls/deepgram_nova2_specialty_config.rbs +93 -0
- data/sig/telnyx/models/calls/deepgram_nova3_medical_config.rbs +91 -0
- data/sig/telnyx/models/calls/transcription_engine_community_config.rbs +43 -0
- data/sig/telnyx/models/calls/transcription_engine_deepgram_config.rbs +4 -313
- data/sig/telnyx/models/calls/transcription_start_request.rbs +5 -382
- data/sig/telnyx/models/email_event_list_response.rbs +13 -3
- data/sig/telnyx/models/iam/guardrail/iam_guardrail_statement.rbs +75 -0
- data/sig/telnyx/models/iam/guardrail/iam_guardrail_statement_response.rbs +22 -0
- data/sig/telnyx/models/iam/guardrail/statement_create_params.rbs +50 -0
- data/sig/telnyx/models/iam/guardrail/statement_delete_params.rbs +27 -0
- data/sig/telnyx/models/iam/guardrail/statement_list_params.rbs +36 -0
- data/sig/telnyx/models/iam/guardrail/statement_update_params.rbs +51 -0
- data/sig/telnyx/models/iam/guardrail_delete_all_params.rbs +17 -0
- data/sig/telnyx/models/iam/iam_action.rbs +4 -4
- data/sig/telnyx/models/iam/iam_settings.rbs +49 -0
- data/sig/telnyx/models/iam/iam_settings_response.rbs +4 -47
- data/sig/telnyx/models/iam/roles/iam_role_statement.rbs +5 -0
- data/sig/telnyx/models/iam/roles/iam_role_statement_conditions.rbs +17 -0
- data/sig/telnyx/models/iam/roles/statement_create_params.rbs +9 -0
- data/sig/telnyx/models/iam/roles/statement_update_params.rbs +10 -1
- data/sig/telnyx/models/iam_explain_params.rbs +6 -1
- data/sig/telnyx/models/iam_retrieve_access_logs_response.rbs +4 -4
- data/sig/telnyx/models/iam_simulate_params.rbs +5 -3
- data/sig/telnyx/models/messaging_inbound_message_payload.rbs +18 -18
- data/sig/telnyx/models/model_metadata.rbs +26 -0
- data/sig/telnyx/models/phone_numbers/emergency_settings.rbs +59 -0
- data/sig/telnyx/models/phone_numbers/numbers_cnam_listing.rbs +28 -0
- data/sig/telnyx/models/phone_numbers/numbers_phone_number_with_voice_settings.rbs +12 -66
- data/sig/telnyx/models/phone_numbers/numbers_update_phone_number_voice_settings_request.rbs +6 -6
- data/sig/telnyx/models/phone_numbers/phone_number_with_voice_settings.rbs +6 -60
- data/sig/telnyx/models/texml/accounts/call_calls_params.rbs +15 -15
- data/sig/telnyx/models/texml_application_list_params.rbs +3 -3
- data/sig/telnyx/models/user_profile.rbs +7 -0
- data/sig/telnyx/models/user_profile_patch_all_params.rbs +0 -7
- data/sig/telnyx/models/whatsapp/business_accounts/phone_number_list_response.rbs +207 -0
- data/sig/telnyx/models/whatsapp/phone_number_list_response.rbs +205 -0
- data/sig/telnyx/resources/iam/guardrail/statements.rbs +35 -0
- data/sig/telnyx/resources/iam/guardrail.rbs +13 -0
- data/sig/telnyx/resources/iam/roles/statements.rbs +2 -0
- data/sig/telnyx/resources/iam.rbs +3 -0
- data/sig/telnyx/resources/phone_numbers/voice.rbs +1 -1
- data/sig/telnyx/resources/user_profile.rbs +0 -1
- data/sig/telnyx/resources/whatsapp/business_accounts/phone_numbers.rbs +1 -1
- data/sig/telnyx/resources/whatsapp/phone_numbers.rbs +1 -1
- metadata +62 -2
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Telnyx
|
|
4
|
+
module Models
|
|
5
|
+
module Calls
|
|
6
|
+
class DeepgramNova3MedicalConfig < Telnyx::Internal::Type::BaseModel
|
|
7
|
+
OrHash =
|
|
8
|
+
T.type_alias do
|
|
9
|
+
T.any(
|
|
10
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig,
|
|
11
|
+
Telnyx::Internal::AnyHash
|
|
12
|
+
)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
sig do
|
|
16
|
+
returns(
|
|
17
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine::OrSymbol
|
|
18
|
+
)
|
|
19
|
+
end
|
|
20
|
+
attr_accessor :transcription_engine
|
|
21
|
+
|
|
22
|
+
sig do
|
|
23
|
+
returns(
|
|
24
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel::OrSymbol
|
|
25
|
+
)
|
|
26
|
+
end
|
|
27
|
+
attr_accessor :transcription_model
|
|
28
|
+
|
|
29
|
+
# Whether to send also interim results. If set to false, only final results will
|
|
30
|
+
# be sent.
|
|
31
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
32
|
+
attr_reader :interim_results
|
|
33
|
+
|
|
34
|
+
sig { params(interim_results: T::Boolean).void }
|
|
35
|
+
attr_writer :interim_results
|
|
36
|
+
|
|
37
|
+
# Keyterm prompting. Up to 100 domain-specific terms or brand names to bias
|
|
38
|
+
# recognition toward. Supported on Nova-3 and Flux models (`deepgram/nova-3`,
|
|
39
|
+
# `deepgram/nova-3-medical`, `deepgram/flux`, `deepgram/flux-multi`); use `hints`
|
|
40
|
+
# on Nova-2.
|
|
41
|
+
sig { returns(T.nilable(T::Array[String])) }
|
|
42
|
+
attr_reader :keyterms
|
|
43
|
+
|
|
44
|
+
sig { params(keyterms: T::Array[String]).void }
|
|
45
|
+
attr_writer :keyterms
|
|
46
|
+
|
|
47
|
+
# Keywords and their respective intensifiers (boosting values) to improve
|
|
48
|
+
# transcription accuracy for specific words or phrases. The intensifier should be
|
|
49
|
+
# a numeric value. Example: `{"snuffleupagus": 5, "systrom": 2, "krieger": 1}`.
|
|
50
|
+
sig { returns(T.nilable(T::Hash[Symbol, Float])) }
|
|
51
|
+
attr_reader :keywords_boosting
|
|
52
|
+
|
|
53
|
+
sig { params(keywords_boosting: T::Hash[Symbol, Float]).void }
|
|
54
|
+
attr_writer :keywords_boosting
|
|
55
|
+
|
|
56
|
+
# Language to transcribe. Deepgram's medical and phonecall models support English
|
|
57
|
+
# only.
|
|
58
|
+
sig do
|
|
59
|
+
returns(
|
|
60
|
+
T.nilable(
|
|
61
|
+
Telnyx::Calls::DeepgramEnglishTranscriptionLanguage::OrSymbol
|
|
62
|
+
)
|
|
63
|
+
)
|
|
64
|
+
end
|
|
65
|
+
attr_reader :language
|
|
66
|
+
|
|
67
|
+
sig do
|
|
68
|
+
params(
|
|
69
|
+
language:
|
|
70
|
+
Telnyx::Calls::DeepgramEnglishTranscriptionLanguage::OrSymbol
|
|
71
|
+
).void
|
|
72
|
+
end
|
|
73
|
+
attr_writer :language
|
|
74
|
+
|
|
75
|
+
# Enable Deepgram's smart formatting (capitalization, punctuation, and digit
|
|
76
|
+
# normalization). Note: Telnyx defaults this to `true`, overriding Deepgram's
|
|
77
|
+
# underlying default of `false` — omit the field to get a smart-formatted
|
|
78
|
+
# transcript, or set it to `false` to receive the raw lowercase transcript without
|
|
79
|
+
# punctuation.
|
|
80
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
81
|
+
attr_reader :smart_format
|
|
82
|
+
|
|
83
|
+
sig { params(smart_format: T::Boolean).void }
|
|
84
|
+
attr_writer :smart_format
|
|
85
|
+
|
|
86
|
+
# Number of milliseconds of silence to consider an utterance ended. Ranges from 0
|
|
87
|
+
# to 5000 ms.
|
|
88
|
+
sig { returns(T.nilable(Integer)) }
|
|
89
|
+
attr_reader :utterance_end_ms
|
|
90
|
+
|
|
91
|
+
sig { params(utterance_end_ms: Integer).void }
|
|
92
|
+
attr_writer :utterance_end_ms
|
|
93
|
+
|
|
94
|
+
# Deepgram Nova-3 medical model, tuned for medical vocabulary. English only.
|
|
95
|
+
sig do
|
|
96
|
+
params(
|
|
97
|
+
transcription_engine:
|
|
98
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine::OrSymbol,
|
|
99
|
+
transcription_model:
|
|
100
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel::OrSymbol,
|
|
101
|
+
interim_results: T::Boolean,
|
|
102
|
+
keyterms: T::Array[String],
|
|
103
|
+
keywords_boosting: T::Hash[Symbol, Float],
|
|
104
|
+
language:
|
|
105
|
+
Telnyx::Calls::DeepgramEnglishTranscriptionLanguage::OrSymbol,
|
|
106
|
+
smart_format: T::Boolean,
|
|
107
|
+
utterance_end_ms: Integer
|
|
108
|
+
).returns(T.attached_class)
|
|
109
|
+
end
|
|
110
|
+
def self.new(
|
|
111
|
+
transcription_engine:,
|
|
112
|
+
transcription_model:,
|
|
113
|
+
# Whether to send also interim results. If set to false, only final results will
|
|
114
|
+
# be sent.
|
|
115
|
+
interim_results: nil,
|
|
116
|
+
# Keyterm prompting. Up to 100 domain-specific terms or brand names to bias
|
|
117
|
+
# recognition toward. Supported on Nova-3 and Flux models (`deepgram/nova-3`,
|
|
118
|
+
# `deepgram/nova-3-medical`, `deepgram/flux`, `deepgram/flux-multi`); use `hints`
|
|
119
|
+
# on Nova-2.
|
|
120
|
+
keyterms: nil,
|
|
121
|
+
# Keywords and their respective intensifiers (boosting values) to improve
|
|
122
|
+
# transcription accuracy for specific words or phrases. The intensifier should be
|
|
123
|
+
# a numeric value. Example: `{"snuffleupagus": 5, "systrom": 2, "krieger": 1}`.
|
|
124
|
+
keywords_boosting: nil,
|
|
125
|
+
# Language to transcribe. Deepgram's medical and phonecall models support English
|
|
126
|
+
# only.
|
|
127
|
+
language: nil,
|
|
128
|
+
# Enable Deepgram's smart formatting (capitalization, punctuation, and digit
|
|
129
|
+
# normalization). Note: Telnyx defaults this to `true`, overriding Deepgram's
|
|
130
|
+
# underlying default of `false` — omit the field to get a smart-formatted
|
|
131
|
+
# transcript, or set it to `false` to receive the raw lowercase transcript without
|
|
132
|
+
# punctuation.
|
|
133
|
+
smart_format: nil,
|
|
134
|
+
# Number of milliseconds of silence to consider an utterance ended. Ranges from 0
|
|
135
|
+
# to 5000 ms.
|
|
136
|
+
utterance_end_ms: nil
|
|
137
|
+
)
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
sig do
|
|
141
|
+
override.returns(
|
|
142
|
+
{
|
|
143
|
+
transcription_engine:
|
|
144
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine::OrSymbol,
|
|
145
|
+
transcription_model:
|
|
146
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel::OrSymbol,
|
|
147
|
+
interim_results: T::Boolean,
|
|
148
|
+
keyterms: T::Array[String],
|
|
149
|
+
keywords_boosting: T::Hash[Symbol, Float],
|
|
150
|
+
language:
|
|
151
|
+
Telnyx::Calls::DeepgramEnglishTranscriptionLanguage::OrSymbol,
|
|
152
|
+
smart_format: T::Boolean,
|
|
153
|
+
utterance_end_ms: Integer
|
|
154
|
+
}
|
|
155
|
+
)
|
|
156
|
+
end
|
|
157
|
+
def to_hash
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
module TranscriptionEngine
|
|
161
|
+
extend Telnyx::Internal::Type::Enum
|
|
162
|
+
|
|
163
|
+
TaggedSymbol =
|
|
164
|
+
T.type_alias do
|
|
165
|
+
T.all(
|
|
166
|
+
Symbol,
|
|
167
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine
|
|
168
|
+
)
|
|
169
|
+
end
|
|
170
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
171
|
+
|
|
172
|
+
DEEPGRAM =
|
|
173
|
+
T.let(
|
|
174
|
+
:Deepgram,
|
|
175
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine::TaggedSymbol
|
|
176
|
+
)
|
|
177
|
+
|
|
178
|
+
sig do
|
|
179
|
+
override.returns(
|
|
180
|
+
T::Array[
|
|
181
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionEngine::TaggedSymbol
|
|
182
|
+
]
|
|
183
|
+
)
|
|
184
|
+
end
|
|
185
|
+
def self.values
|
|
186
|
+
end
|
|
187
|
+
end
|
|
188
|
+
|
|
189
|
+
module TranscriptionModel
|
|
190
|
+
extend Telnyx::Internal::Type::Enum
|
|
191
|
+
|
|
192
|
+
TaggedSymbol =
|
|
193
|
+
T.type_alias do
|
|
194
|
+
T.all(
|
|
195
|
+
Symbol,
|
|
196
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel
|
|
197
|
+
)
|
|
198
|
+
end
|
|
199
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
200
|
+
|
|
201
|
+
DEEPGRAM_NOVA_3_MEDICAL =
|
|
202
|
+
T.let(
|
|
203
|
+
:"deepgram/nova-3-medical",
|
|
204
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel::TaggedSymbol
|
|
205
|
+
)
|
|
206
|
+
|
|
207
|
+
sig do
|
|
208
|
+
override.returns(
|
|
209
|
+
T::Array[
|
|
210
|
+
Telnyx::Calls::DeepgramNova3MedicalConfig::TranscriptionModel::TaggedSymbol
|
|
211
|
+
]
|
|
212
|
+
)
|
|
213
|
+
end
|
|
214
|
+
def self.values
|
|
215
|
+
end
|
|
216
|
+
end
|
|
217
|
+
end
|
|
218
|
+
end
|
|
219
|
+
end
|
|
220
|
+
end
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Telnyx
|
|
4
|
+
module Models
|
|
5
|
+
module Calls
|
|
6
|
+
class TranscriptionEngineCommunityConfig < Telnyx::Internal::Type::BaseModel
|
|
7
|
+
OrHash =
|
|
8
|
+
T.type_alias do
|
|
9
|
+
T.any(
|
|
10
|
+
Telnyx::Calls::TranscriptionEngineCommunityConfig,
|
|
11
|
+
Telnyx::Internal::AnyHash
|
|
12
|
+
)
|
|
13
|
+
end
|
|
14
|
+
|
|
15
|
+
# The identifier of the
|
|
16
|
+
# [integration secret](/api-reference/integration-secrets/create-a-secret) in your
|
|
17
|
+
# organization that holds the key the engine expects. The engine is called with
|
|
18
|
+
# your own key: Telnyx holds none for it.
|
|
19
|
+
sig { returns(String) }
|
|
20
|
+
attr_accessor :api_key_ref
|
|
21
|
+
|
|
22
|
+
# Whether to send interim (non-final) transcription results in addition to final
|
|
23
|
+
# ones.
|
|
24
|
+
sig { returns(T.nilable(T::Boolean)) }
|
|
25
|
+
attr_reader :interim_results
|
|
26
|
+
|
|
27
|
+
sig { params(interim_results: T::Boolean).void }
|
|
28
|
+
attr_writer :interim_results
|
|
29
|
+
|
|
30
|
+
# The language of the audio to be transcribed. Unlike the built-in engines, this
|
|
31
|
+
# isn't checked against a fixed list: it is passed through to the registered
|
|
32
|
+
# engine, which accepts the languages its selected model lists. `auto` resolves to
|
|
33
|
+
# that model's language when it lists only one.
|
|
34
|
+
sig { returns(T.nilable(String)) }
|
|
35
|
+
attr_reader :language
|
|
36
|
+
|
|
37
|
+
sig { params(language: String).void }
|
|
38
|
+
attr_writer :language
|
|
39
|
+
|
|
40
|
+
# One of the community engine's own models, as listed in its `models`. Without it,
|
|
41
|
+
# the engine's default model is used.
|
|
42
|
+
sig { returns(T.nilable(String)) }
|
|
43
|
+
attr_reader :transcription_model
|
|
44
|
+
|
|
45
|
+
sig { params(transcription_model: String).void }
|
|
46
|
+
attr_writer :transcription_model
|
|
47
|
+
|
|
48
|
+
# Settings for a community STT engine, used with the engine's name in
|
|
49
|
+
# `transcription_engine` (any name that is not a built-in engine). See
|
|
50
|
+
# [Community STT engines](/docs/voice/stt/community-engines).
|
|
51
|
+
sig do
|
|
52
|
+
params(
|
|
53
|
+
api_key_ref: String,
|
|
54
|
+
interim_results: T::Boolean,
|
|
55
|
+
language: String,
|
|
56
|
+
transcription_model: String
|
|
57
|
+
).returns(T.attached_class)
|
|
58
|
+
end
|
|
59
|
+
def self.new(
|
|
60
|
+
# The identifier of the
|
|
61
|
+
# [integration secret](/api-reference/integration-secrets/create-a-secret) in your
|
|
62
|
+
# organization that holds the key the engine expects. The engine is called with
|
|
63
|
+
# your own key: Telnyx holds none for it.
|
|
64
|
+
api_key_ref:,
|
|
65
|
+
# Whether to send interim (non-final) transcription results in addition to final
|
|
66
|
+
# ones.
|
|
67
|
+
interim_results: nil,
|
|
68
|
+
# The language of the audio to be transcribed. Unlike the built-in engines, this
|
|
69
|
+
# isn't checked against a fixed list: it is passed through to the registered
|
|
70
|
+
# engine, which accepts the languages its selected model lists. `auto` resolves to
|
|
71
|
+
# that model's language when it lists only one.
|
|
72
|
+
language: nil,
|
|
73
|
+
# One of the community engine's own models, as listed in its `models`. Without it,
|
|
74
|
+
# the engine's default model is used.
|
|
75
|
+
transcription_model: nil
|
|
76
|
+
)
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
sig do
|
|
80
|
+
override.returns(
|
|
81
|
+
{
|
|
82
|
+
api_key_ref: String,
|
|
83
|
+
interim_results: T::Boolean,
|
|
84
|
+
language: String,
|
|
85
|
+
transcription_model: String
|
|
86
|
+
}
|
|
87
|
+
)
|
|
88
|
+
end
|
|
89
|
+
def to_hash
|
|
90
|
+
end
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
end
|