Class: Zavudev::Models::AgentCreateParams::Voice
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Zavudev::Models::AgentCreateParams::Voice
- Defined in:
- lib/zavudev/models/agent_create_params.rb,
sig/zavudev/models/agent_create_params.rbs
Defined Under Namespace
Modules: VoicemailAction
Instance Attribute Summary collapse
-
#enabled ⇒ Boolean
Whether the agent handles voice calls.
-
#greeting ⇒ String?
Opening line the agent speaks when the call connects.
-
#greetings ⇒ Hash{Symbol=>String}?
Greeting per language, keyed by language code.
-
#interruptible ⇒ Boolean?
Whether the caller can interrupt the agent while it is speaking (barge-in).
-
#language ⇒ String?
BCP-47 language code used for both speech recognition and speech synthesis (e.g.
en,es,pt-BR). -
#max_call_duration_minutes ⇒ Integer?
Hard limit on call length in minutes.
-
#max_idle_seconds ⇒ Integer?
How long the agent waits during silence before ending the call.
-
#model ⇒ String?
Model that runs the conversation, co-located in the voice network for lowest latency.
-
#record_calls ⇒ Boolean?
Whether the call audio is recorded.
-
#stt_model ⇒ String?
Speech-recognition model.
-
#stt_provider ⇒ String?
Speech-recognition provider.
-
#transfer_phone_number ⇒ String?
E.164 phone number the agent can transfer the call to.
-
#tts_provider ⇒ String?
Speech-synthesis provider.
-
#tts_voice_id ⇒ String?
Identifier of the synthesized voice that speaks.
-
#voice_speed ⇒ Float?
Speech rate.
-
#voicemail_action ⇒ Symbol, ...
What the agent does when an answering machine or voicemail is detected on an outbound call.
-
#voicemail_message ⇒ String?
Message spoken when
voicemailActionisleave_message.
Instance Method Summary collapse
-
#initialize(enabled:, greeting: nil, greetings: nil, interruptible: nil, language: nil, max_call_duration_minutes: nil, max_idle_seconds: nil, model: nil, record_calls: nil, stt_model: nil, stt_provider: nil, transfer_phone_number: nil, tts_provider: nil, tts_voice_id: nil, voicemail_action: nil, voicemail_message: nil, voice_speed: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see Voice for more details.
- #to_hash ⇒ {
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(enabled:, greeting: nil, greetings: nil, interruptible: nil, language: nil, max_call_duration_minutes: nil, max_idle_seconds: nil, model: nil, record_calls: nil, stt_model: nil, stt_provider: nil, transfer_phone_number: nil, tts_provider: nil, tts_voice_id: nil, voicemail_action: nil, voicemail_message: nil, voice_speed: nil) ⇒ Object
Some parameter documentations has been truncated, see Zavudev::Models::AgentCreateParams::Voice for more details.
Voice Agent configuration on a sender's AI agent. Controls how the agent behaves on inbound and outbound phone calls through Zavu's managed voice pipeline (speech recognition, the agent's LLM, and speech synthesis, with real-time interruption handling). Requires the Voice Agents feature to be enabled for your team.
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 |
# File 'lib/zavudev/models/agent_create_params.rb', line 101 class Voice < Zavudev::Internal::Type::BaseModel # @!attribute enabled # Whether the agent handles voice calls. When false, the sender's number is not # answered by the voice agent and outbound calls are rejected. # # @return [Boolean] required :enabled, Zavudev::Internal::Type::Boolean # @!attribute greeting # Opening line the agent speaks when the call connects. If omitted, the agent # waits for the caller to speak first. # # @return [String, nil] optional :greeting, String # @!attribute greetings # Greeting per language, keyed by language code. Used when the caller's language # differs from the one `greeting` is written in. # # @return [Hash{Symbol=>String}, nil] optional :greetings, Zavudev::Internal::Type::HashOf[String] # @!attribute interruptible # Whether the caller can interrupt the agent while it is speaking (barge-in). When # true, the agent stops talking as soon as the caller starts. # # @return [Boolean, nil] optional :interruptible, Zavudev::Internal::Type::Boolean # @!attribute language # BCP-47 language code used for both speech recognition and speech synthesis (e.g. # `en`, `es`, `pt-BR`). Auto-detected from the recipient when omitted. # # @return [String, nil] optional :language, String # @!attribute max_call_duration_minutes # Hard limit on call length in minutes. The call ends automatically when reached. # # @return [Integer, nil] optional :max_call_duration_minutes, Integer, api_name: :maxCallDurationMinutes # @!attribute max_idle_seconds # How long the agent waits during silence before ending the call. # # @return [Integer, nil] optional :max_idle_seconds, Integer, api_name: :maxIdleSeconds # @!attribute model # Model that runs the conversation, co-located in the voice network for lowest # latency. Independent of the model used for text messaging. Derived from the # agent's text model when omitted. # # @return [String, nil] optional :model, String # @!attribute record_calls # Whether the call audio is recorded. # # @return [Boolean, nil] optional :record_calls, Zavudev::Internal::Type::Boolean, api_name: :recordCalls # @!attribute stt_model # Speech-recognition model. Uses the default when omitted. # # @return [String, nil] optional :stt_model, String, api_name: :sttModel # @!attribute stt_provider # Speech-recognition provider. Uses the default when omitted. # # @return [String, nil] optional :stt_provider, String, api_name: :sttProvider # @!attribute transfer_phone_number # E.164 phone number the agent can transfer the call to. When set, the agent is # given a transfer tool it can use to hand the call to a human. # # @return [String, nil] optional :transfer_phone_number, String, api_name: :transferPhoneNumber # @!attribute tts_provider # Speech-synthesis provider. Uses the default when omitted. # # @return [String, nil] optional :tts_provider, String, api_name: :ttsProvider # @!attribute tts_voice_id # Identifier of the synthesized voice that speaks. Choose from the voices # available in the dashboard. Uses a neutral default when omitted. # # @return [String, nil] optional :tts_voice_id, String, api_name: :ttsVoiceId # @!attribute voicemail_action # What the agent does when an answering machine or voicemail is detected on an # outbound call. # # @return [Symbol, Zavudev::Models::AgentCreateParams::Voice::VoicemailAction, nil] optional :voicemail_action, enum: -> { Zavudev::AgentCreateParams::Voice::VoicemailAction }, api_name: :voicemailAction # @!attribute voicemail_message # Message spoken when `voicemailAction` is `leave_message`. Falls back to # `greeting` when omitted. # # @return [String, nil] optional :voicemail_message, String, api_name: :voicemailMessage # @!attribute voice_speed # Speech rate. 1.0 is natural. Only honoured by voices that support rate control; # ignored by the others. # # @return [Float, nil] optional :voice_speed, Float, api_name: :voiceSpeed # @!method initialize(enabled:, greeting: nil, greetings: nil, interruptible: nil, language: nil, max_call_duration_minutes: nil, max_idle_seconds: nil, model: nil, record_calls: nil, stt_model: nil, stt_provider: nil, transfer_phone_number: nil, tts_provider: nil, tts_voice_id: nil, voicemail_action: nil, voicemail_message: nil, voice_speed: nil) # Some parameter documentations has been truncated, see # {Zavudev::Models::AgentCreateParams::Voice} for more details. # # Voice Agent configuration on a sender's AI agent. Controls how the agent behaves # on inbound and outbound phone calls through Zavu's managed voice pipeline # (speech recognition, the agent's LLM, and speech synthesis, with real-time # interruption handling). Requires the Voice Agents feature to be enabled for your # team. # # @param enabled [Boolean] Whether the agent handles voice calls. When false, the sender's number is not an # # @param greeting [String] Opening line the agent speaks when the call connects. If omitted, the agent wait # # @param greetings [Hash{Symbol=>String}] Greeting per language, keyed by language code. Used when the caller's language d # # @param interruptible [Boolean] Whether the caller can interrupt the agent while it is speaking (barge-in). When # # @param language [String] BCP-47 language code used for both speech recognition and speech synthesis (e.g. # # @param max_call_duration_minutes [Integer] Hard limit on call length in minutes. The call ends automatically when reached. # # @param max_idle_seconds [Integer] How long the agent waits during silence before ending the call. # # @param model [String] Model that runs the conversation, co-located in the voice network for lowest lat # # @param record_calls [Boolean] Whether the call audio is recorded. # # @param stt_model [String] Speech-recognition model. Uses the default when omitted. # # @param stt_provider [String] Speech-recognition provider. Uses the default when omitted. # # @param transfer_phone_number [String] E.164 phone number the agent can transfer the call to. When set, the agent is gi # # @param tts_provider [String] Speech-synthesis provider. Uses the default when omitted. # # @param tts_voice_id [String] Identifier of the synthesized voice that speaks. Choose from the voices availabl # # @param voicemail_action [Symbol, Zavudev::Models::AgentCreateParams::Voice::VoicemailAction] What the agent does when an answering machine or voicemail is detected on an out # # @param voicemail_message [String] Message spoken when `voicemailAction` is `leave_message`. Falls back to `greetin # # @param voice_speed [Float] Speech rate. 1.0 is natural. Only honoured by voices that support rate control; # What the agent does when an answering machine or voicemail is detected on an # outbound call. # # @see Zavudev::Models::AgentCreateParams::Voice#voicemail_action module VoicemailAction extend Zavudev::Internal::Type::Enum HANGUP = :hangup LEAVE_MESSAGE = :leave_message # @!method self.values # @return [Array<Symbol>] end end |
Instance Attribute Details
#enabled ⇒ Boolean
Whether the agent handles voice calls. When false, the sender's number is not answered by the voice agent and outbound calls are rejected.
107 |
# File 'lib/zavudev/models/agent_create_params.rb', line 107 required :enabled, Zavudev::Internal::Type::Boolean |
#greeting ⇒ String?
Opening line the agent speaks when the call connects. If omitted, the agent waits for the caller to speak first.
114 |
# File 'lib/zavudev/models/agent_create_params.rb', line 114 optional :greeting, String |
#greetings ⇒ Hash{Symbol=>String}?
Greeting per language, keyed by language code. Used when the caller's language
differs from the one greeting is written in.
121 |
# File 'lib/zavudev/models/agent_create_params.rb', line 121 optional :greetings, Zavudev::Internal::Type::HashOf[String] |
#interruptible ⇒ Boolean?
Whether the caller can interrupt the agent while it is speaking (barge-in). When true, the agent stops talking as soon as the caller starts.
128 |
# File 'lib/zavudev/models/agent_create_params.rb', line 128 optional :interruptible, Zavudev::Internal::Type::Boolean |
#language ⇒ String?
BCP-47 language code used for both speech recognition and speech synthesis (e.g.
en, es, pt-BR). Auto-detected from the recipient when omitted.
135 |
# File 'lib/zavudev/models/agent_create_params.rb', line 135 optional :language, String |
#max_call_duration_minutes ⇒ Integer?
Hard limit on call length in minutes. The call ends automatically when reached.
141 |
# File 'lib/zavudev/models/agent_create_params.rb', line 141 optional :max_call_duration_minutes, Integer, api_name: :maxCallDurationMinutes |
#max_idle_seconds ⇒ Integer?
How long the agent waits during silence before ending the call.
147 |
# File 'lib/zavudev/models/agent_create_params.rb', line 147 optional :max_idle_seconds, Integer, api_name: :maxIdleSeconds |
#model ⇒ String?
Model that runs the conversation, co-located in the voice network for lowest latency. Independent of the model used for text messaging. Derived from the agent's text model when omitted.
155 |
# File 'lib/zavudev/models/agent_create_params.rb', line 155 optional :model, String |
#record_calls ⇒ Boolean?
Whether the call audio is recorded.
161 |
# File 'lib/zavudev/models/agent_create_params.rb', line 161 optional :record_calls, Zavudev::Internal::Type::Boolean, api_name: :recordCalls |
#stt_model ⇒ String?
Speech-recognition model. Uses the default when omitted.
167 |
# File 'lib/zavudev/models/agent_create_params.rb', line 167 optional :stt_model, String, api_name: :sttModel |
#stt_provider ⇒ String?
Speech-recognition provider. Uses the default when omitted.
173 |
# File 'lib/zavudev/models/agent_create_params.rb', line 173 optional :stt_provider, String, api_name: :sttProvider |
#transfer_phone_number ⇒ String?
E.164 phone number the agent can transfer the call to. When set, the agent is given a transfer tool it can use to hand the call to a human.
180 |
# File 'lib/zavudev/models/agent_create_params.rb', line 180 optional :transfer_phone_number, String, api_name: :transferPhoneNumber |
#tts_provider ⇒ String?
Speech-synthesis provider. Uses the default when omitted.
186 |
# File 'lib/zavudev/models/agent_create_params.rb', line 186 optional :tts_provider, String, api_name: :ttsProvider |
#tts_voice_id ⇒ String?
Identifier of the synthesized voice that speaks. Choose from the voices available in the dashboard. Uses a neutral default when omitted.
193 |
# File 'lib/zavudev/models/agent_create_params.rb', line 193 optional :tts_voice_id, String, api_name: :ttsVoiceId |
#voice_speed ⇒ Float?
Speech rate. 1.0 is natural. Only honoured by voices that support rate control; ignored by the others.
216 |
# File 'lib/zavudev/models/agent_create_params.rb', line 216 optional :voice_speed, Float, api_name: :voiceSpeed |
#voicemail_action ⇒ Symbol, ...
What the agent does when an answering machine or voicemail is detected on an outbound call.
200 201 202 |
# File 'lib/zavudev/models/agent_create_params.rb', line 200 optional :voicemail_action, enum: -> { Zavudev::AgentCreateParams::Voice::VoicemailAction }, api_name: :voicemailAction |
#voicemail_message ⇒ String?
Message spoken when voicemailAction is leave_message. Falls back to
greeting when omitted.
209 |
# File 'lib/zavudev/models/agent_create_params.rb', line 209 optional :voicemail_message, String, api_name: :voicemailMessage |
Instance Method Details
#to_hash ⇒ {
201 |
# File 'sig/zavudev/models/agent_create_params.rbs', line 201
def to_hash: -> {
|