Octoroom.Agent.TTS.AssemblyAI (octoroom_agents v0.1.0)

Copy Markdown View Source

AssemblyAI text-to-speech, over its streaming WebSocket.

connect/1 opens a session to share (the TTS processor opens one per agent), so replies after the first skip the connection setup; without it, a call opens its own and ends it after. The voice, model, language and sample rate are fixed for a session.

Reads ASSEMBLY_AI_API_KEY. :voice is a voice slug such as "aai-kyla" (the default) or a cloned voice's id, and :model is "assemblyai-tts-1". Besides Octoroom.Agent.TTS's options it takes :language ("english", "spanish", "german", "italian", "portuguese" or "french"; by default the voice's), :region (:us, the default, or :eu) and :receive_timeout (ms to wait for each message, default 60 s).

Summary

Functions

Opens a session for calls to share, closed when the calling process exits. Returns the options with it as :connection. Without an API key it opens nothing, and calls report the missing key.

Functions

connect(opts)

Opens a session for calls to share, closed when the calling process exits. Returns the options with it as :connection. Without an API key it opens nothing, and calls report the missing key.