llm.model or llm.custom on the configuration.
Fallback decides what happens when that attempt produces no reply:
- The provider returns an error.
- The model takes too long.
- The response stream breaks off with nothing in it.
Modes
llm.fallback.mode picks the behavior:
With
manual you choose which models back up the agent, in what order, and with what timing.
Configure manual fallback
- Console
- API
On your agent’s Configuration page, open Fallback models in the Model section and pick Custom. Select Add fallback and choose a model for each one, then select Save.The agent’s own model appears as Primary model. Every model has a First token timeout (s) and a Total timeout (s), entered in seconds.
models
1 to 3 entries, tried in the order you list them. Each entry names one model:
Rules:
- An entry carries
modelorcustom, not both. Anything else is422. - No duplicates. The main model and every entry must be different models or endpoints. A duplicate is
422. - A custom main model can fall back to platform models.
- A platform main model can fall back to a custom endpoint.
api_keyis write-only. Reads and version snapshots returnnull.- Omit
api_keyon a later patch to keep the stored key for the samebase_urlandmodel.
Timeouts
Each entry inmodels can set two timeouts. primary sets the same two for the agent’s own model.
The defaults apply to every model in
manual mode. That includes the agent’s own model when you leave primary out.
Both timeouts count from the moment a request goes to the model. A reply that calls a tool and then answers is two requests, and each has its own count.
These numbers are starting points, not thresholds. A shorter ttft_timeout_ms reaches a fallback sooner. It also switches away from a model that was about to answer.
When a reply has started
ttft_timeout_ms stops counting at the first of these.
- The first text of the reply.
- A tool call whose name and arguments have arrived in full. The beginning of a streamed tool call does not stop the count.
What total_timeout_ms covers
total_timeout_ms measures the model’s generation, tool call arguments included.
- It does not measure playback. A reply can still be playing after the model has finished generating it.
- It does not include the time a tool takes to run.
- It keeps counting after the reply has started.
ttft_timeout_ms comes first.
- What the model generated so far is still spoken. The rest is lost.
- The reply counts as a failed reply. It does not move to the next model.
Run a fallback in parallel
The first fallback can run alongside the agent’s own model, so a slow start does not hold the reply.- Console
- API
In Fallback models, turn on Run with the primary model on Fallback 1, then set Switch after (ms).
Parallel trades cost for latency. Both requests bill their own tokens, whichever reply is used. The request that was not used is cancelled.
What triggers a switch
A reply moves to the next model on:- A provider error.
- A model that has not started its reply within
ttft_timeout_ms. Outsidemanual, within the platform’s own limit. total_timeout_msreached before the model started its reply.- A response stream that breaks off with no output.
What doesn’t switch
- The agent choosing silence. A model that finishes normally with an empty reply is the agent staying quiet on purpose. Nothing switches.
- A reply that has started. Once a model has started its reply, a problem finishing it counts as a failed reply.
When a reply fails
A reply fails when no model produced it, or when a problem cut it after it had started. What the caller hears depends on the agent’s own model.- A platform model. The agent generates the reply again. If that fails too, it asks the caller to repeat. After three failed replies in a row it apologizes and hangs up.
- A custom LLM. See Failure behavior.
Per-session override
A session can replace the agent’s fallback configuration for that conversation only. Seeoverrides.llm.fallback.
See which model answered
The session detail endpoint reports every switch and which model wrote each reply. See Conversation History. The console’s Conversations view shows the same: each switch in the timeline, and which model answered each turn.Billing
- Each reply is billed by the model that answered it, at that model’s rate.
- A request that a timeout cut is still billed for the tokens it used.
- A reply from a custom LLM endpoint has no LLM charge. Main model or fallback.
Going further
Custom LLM
Point the agent, or a fallback entry, at your own endpoint.
Configuration
Where
llm.fallback sits among the rest of the agent’s settings.Authenticated sessions
Override the fallback configuration for a single session.
Conversation history
Inspect every switch after the call.

