Readonly maxNumber of retries per TTS instance before falling back to the next one.
Readonly recoveryDelay in milliseconds before attempting to recover a failed TTS instance.
Readonly ttsThe list of TTS instances used for fallback (in priority order).
Returns this TTS's capabilities
The model of the instance that serves next (see nextInstance). Spans and metrics read
this, so a failover shows the model expected to answer rather than the adapter; the instance
that actually served is stamped per request by the stream.
Returns the channel count of audio frames returned by this TTS
The provider of the instance that serves next (see model).
Returns the sample rate of audio frames returned by this TTS
Returns the current status of all TTS instances, including availability and recovery state.
Returns a SynthesizeStream that can be used to push text and receive audio data
Optional options: { Optional configuration including connection options
Optional connReceives text and returns synthesis in the form of a ChunkedStream
Optional connOptions: APIConnectOptionsOptional abortSignal: AbortSignal
Agent Fallback Adapter for TTS. Manages multiple TTS instances, providing automatic fallback between providers.
When the primary TTS fails, it automatically switches to the next available provider in the list. Failed providers are monitored in the background and restored when they recover.
Features:
Example