Skip to main content
Any of Listen, Think, and Speak can fail on a single turn: a provider returns an error, or a response arrives too late for a real-time call. The agent’s models object carries three controls that handle this, and they work the same way for all three steps. The API sets them together in the models block; the dashboard exposes them on each section (Listen, Think, Speak), with failure audio under Agent behavior.

Prerequisites

Before you begin:
  • An agent already exists. If not, see Create an agent.
  • These controls live in the models object. A PATCH replaces it as a unit rather than merging fields, so send the whole block; see Update an agent.

Fallbacks

models.fallbacks lists the models to try, in order, when the primary model for a step fails. Each step has its own list: stt, llm, and tts. A list can mix slng/ and BYOK routes, so a hosted model can fall back to your own provider or the other way around.
Open a section (Listen, Think, or Speak) and find Fallback routing. Click Add to append a backup model. The rows are an ordered list, tried top to bottom, and each row has controls to reorder or remove it. On Speak, each row also picks a voice for the fallback model.
The Fallback routing card on the Speak section with a fallback row: a model picker, a voice picker, and reorder and remove controls

Fallback routing on the Speak section: an ordered list of backup models, each with its own voice.

For how a route resolves to a hosted or BYOK model, see Choose a model route.

Per-turn timeouts

Each step has a timeout that bounds how long the agent waits before it gives up on the primary model and moves to a fallback:
  • models.stt_final_timeout_s: the wait for a final transcript.
  • models.llm_first_token_timeout_s: the wait for the model’s first token.
  • models.tts_first_audio_timeout_s: the wait for the first audio chunk.
A null value uses the provider default. Set a number to fail faster on a slow step.
Each section’s Advanced settings card has a timeout field (“STT timeout (seconds)” on Listen, “LLM timeout (seconds)” on Think, “TTS timeout (seconds)” on Speak). Leave it empty to use the provider default.
The Advanced settings card on the Listen section with the STT timeout field highlighted

The per-turn timeout in a section's Advanced settings.

Failure audio

models.failure_audio_enabled is true by default. When a turn cannot be completed, even after fallbacks, the agent plays a short clip instead of going silent, so the caller hears that something went wrong. In the dashboard this toggle lives under Agent behavior, not the Listen, Think, or Speak sections.
The Failure audio toggle under Agent behavior, set to Enabled

The Failure audio toggle under Agent behavior.

Next steps