Skip to main content
A rollout deployment loads new weights without redeploying. You request a snapshot you’ve published, and each replica prepares the update while it keeps serving, then pauses briefly to swap weights.

Prerequisites

The curl examples authenticate with BASETEN_API_KEY. Export your API key first:

Request a snapshot

To load a delta: Send a POST request with the snapshot’s identity and the delta’s formats. Replace <model_id> and <deployment_id> with your deployment’s IDs:
To load an anchor, send only its identity, such as {"identity": "step000003"}. The response is {"revision": N}: Baseten stored the request, and every replica loads it. revision increases with each request, and the newest request wins, so you can request snapshots faster than replicas apply them. The API doesn’t check the snapshot. Each replica checks it and reports a bad one as rejected while it keeps serving its current snapshot. For more information, see Set the target snapshot.

Check that every replica loaded it

To check each replica’s state: Send a GET request to the same URL:
The response lists every replica of the deployment, in every cluster it runs in. Repeat the request until every entry in replicas reports:
  • replica_status: "ready"
  • loading_state.current_snapshot_identity set to the snapshot you requested
  • loading_state.hotload_stage: "done"
  • loading_state.revision equal to the top-level revision
A replica that’s done at an older revision hasn’t loaded your request yet. loading_state is null for a replica that hasn’t reported a state. Replicas update independently, so rollouts can briefly come from different policies. To record which policy produced each rollout, request engine_data and save its policy_version and replica with each sample; see the RL request and response fields. For more information, see Get snapshot loading status.

Recover from a rejected or failed load

When a replica’s hotload_stage is rejected or error, loading_state.reason says why. A replica that rejects a snapshot keeps serving its current one. Fix the cause, then send the request again, or request an anchor. If the snapshot itself was bad, such as a delta built against the wrong parent, publish it again under a new identity, because published snapshots can’t change.

Clean up

The deployment bills for its GPUs until you deactivate it. To stop serving and stop the charges:
The command prompts for confirmation. Add --yes to skip the prompt when you script it.

Next steps