Skip to main content
Fine-tuning is in private preview. Only invited accounts can use it; any other account gets 403 fine_tuning_unavailable. The prices and rules on this page can change before it opens to every account.

Get a quote

POST /v1/fine_tuning/quote takes a job’s body and answers what that job would train and cost, before anything is held. It is free, and Platform’s Training page asks for one whenever a choice changes.
string
The robot the dataset was recorded on. See Robots.
boolean
Whether Abstract serves the fine-tune once it is ready. When false, the fine-tune is download only, for now.
object
The columns and cameras the job trains from: yours, or the proposal. See Mapping.
integer
The steps the job trains: the most it can run.
number
The most the job can cost: steps at usd_per_1000_steps. The job holds it.
number
The price per 1,000 steps, locked for the job.
integer
The time from queued to ready: preparation, start-up, training, export and evaluation.
number
How many times training goes over the dataset’s frames.
A dataset the model cannot train answers 422 dataset_not_trainable, with every finding in errors. An upload is quoted from the meta/ files sent with it.

Create a job

The command asks for a quote, shows it, then asks before it starts; --yes skips the question. --dataset takes a ds_ id or hf:owner/name[@revision]. See Datasets. Without --suffix, the model is named after the dataset. Over HTTP:
string
required
The base model: allenai/molmoact2 or physical-intelligence/pi0.5 (download only, including on bimanual YAM). New nvidia/dreamzero quotes and jobs answer 503 fine_tuning_unavailable: its fine-tunes cannot be served or downloaded yet. Unknown bases answer 400 model_not_tunable.
string | object
required
A ready upload’s ds_ id, or {"huggingface": "owner/name", "revision": "main"} for a public Hugging Face dataset. revision is optional: a branch, a tag or a commit.
string
required
1 to 40 lowercase letters, digits or dashes. The model is named ft/molmoact2-<suffix>-<last 8 characters of the job id>, or ft/pi05-..., ft/dreamzero-....
string
auto (the default), steps or budget. See Length.
object
Any of the knobs below. Each one left out takes its default. steps is for a length of steps only.
string | number
For a length of budget: the most to spend, in dollars to the cent.
boolean
true (the default) runs auto-clean; false trains on every frame as recorded.
object
Your own mapping. Without it, the proposal.
string | number
The quote you agreed to. The API quotes the job again; when that comes above quoted_usd it answers 409 quote_changed with the new quote, and nothing is held.
Send an Idempotency-Key: a create sent again with the same key answers the same job, so a lost answer never starts, or holds credit for, a second job. The CLI sends one, and sends the quote it showed as quoted_usd.

Length

A budget too small for the model’s fewest steps answers 400 invalid_request with the least it takes. The CLI takes --steps <n> or --max-usd <dollars>; neither is Auto.

Hyperparameters

Each base has its own knobs. None changes the price per step but steps, through the length. allenai/molmoact2: physical-intelligence/pi0.5, a full fine-tune: nvidia/dreamzero (historical jobs only; new training is unavailable): Every knob but eval_fraction and learning_rate is a whole number. A value out of range, or a knob the base does not have (learning_rate on MolmoAct2, rtc_max_delay anywhere but π0.5), answers 400 invalid_hyperparameters. The batch is each model’s own, the one its price was measured at. The CLI sets them with --lora-rank, --learning-rate and --rtc.

What the API checks

In this order, before anything runs:
  1. The base model can be fine-tuned, and the length and knobs are in range: 400 model_not_tunable, invalid_request or invalid_hyperparameters otherwise.
  2. The dataset is a ready upload or an owner/name Hugging Face repository, and the model trains it: 400 dataset_not_ready or 422 dataset_not_trainable otherwise.
  3. The quote is not above quoted_usd: 409 quote_changed otherwise.
  4. The account has no other live job: 409 job_limit otherwise.
  5. The account holds fewer than 200 fine-tuned models: 413 storage_full otherwise. Nothing is held.
  6. The quote fits the account’s credit and spend limit: 402 insufficient_credit, 429 spend_limit_exceeded or 429 spend_blocked otherwise. Nothing is held.
The job is then written as queued, holding its quote, and handed to the training service. If the service refuses it, the job fails with dispatch_failed, the hold is released in full, and the API answers 400 invalid_request (the spec) or 503 fine_tuning_unavailable. If the service’s answer is lost, the job stays queued with its hold while Abstract checks; one the service never took fails dispatch_failed within about 15 minutes, its hold released.

The job

The numbers above are an example. Read the rate from your own job’s estimate.
object
{"id": "ds_..."}, or {"huggingface", "revision", "commit"}. commit is the Hugging Face commit the job pinned, once it has.
string
The robot the quote found.
boolean
Whether Abstract serves the fine-tune once ready; false is download only.
object
Every knob of the base, defaults filled in; steps is the quote’s.
string
One of the statuses below.
object
step of steps, the training loss, and eval_loss on the held-out episodes. steps drops below the quote’s when Auto shortens the run after auto-clean. loss and eval_loss are null until training reports them.
string | null
The model id, ft/molmoact2-..., once the job has succeeded.
object
The quote the job holds: steps, length, usd_per_1000_steps, max_cost_usd (the hold) and eta_seconds (hours, the same in hours).
object
reserved_usd: the hold. steps and cost_usd: the steps charged so far, and their cost.
object | null
{"code", "message"} once the job has failed.
object | null
The scores once the job has succeeded. See Evaluation.
integer
Unix seconds. finished_at is set once the job ends.

Statuses

A job only moves forward, or out to failed or cancelled. A failed job’s error.code is one of the job error codes.

Follow a job

Platform’s Training page lists your runs, and each run’s page follows it every few seconds with its statuses, steps, loss and cost. Run get again to follow the job; --json prints the API’s answer as it came. GET /v1/fine_tuning/jobs?limit=20&after=ftjob_... lists jobs newest first, at most 100 a page. has_more says whether another page follows; pass the last id as after to read it. A job of another account answers 404 job_not_found.

Events

GET /v1/fine_tuning/jobs/{id}/events returns the last 200 events the training service reported, each {"at", "status", "message"}. The dataset check’s warnings appear here.

Evaluation

A succeeded job’s evaluation scores three things on samples from the held-out episodes: the fine-tune, its base, and holding the current state still. Each is compared with what the robot did next, over a chunk: MolmoAct2’s 30 actions, DreamZero’s 24. DreamZero is scored on an episode’s opening chunk, from one frame per camera; the model leans on its video history, so this measures it less well than MolmoAct2. A job with no held-out episodes (eval_fraction 0) has {"skipped": "<why>"}. A fine-tune that does not beat holding still has learned nothing useful about this data. The scores are open loop, on recorded data: they do not measure task success on a robot. With eval_fraction 0, or when it cannot run, evaluation is {"skipped": "<why>"}.

Cancel a job

POST /v1/fine_tuning/jobs/{id}/cancel stops the running stage and answers the job; a run’s page on Platform cancels it too, after asking. A cancelled job is charged for the steps it finished. A job that has already ended is answered as it is.

Charges

A job is priced per 1,000 steps: the compute it takes at measured speed, start-up, checkpoints and evaluation included, locked in its quote.
  1. Before the job starts, the API holds its quote, estimate.max_cost_usd: the most it can cost, wherever it runs and however long it takes.
  2. When the job ends, it is charged its steps at estimate.usd_per_1000_steps, to the cent, never more than the hold. The rest of the hold is released.
For example, a job quoted at $12.87 per 1,000 steps and cancelled at step 1,200 is charged $15.44. The hold needs prepaid credit, and counts against the monthly spend limit.

Error codes

Fine-tuning errors have the same shape as every other error: see Errors and limits. These codes come from /v1/datasets and /v1/fine_tuning/..., and model_loading from the robot routes when model is a fine-tune. A fine-tuning route answers 404 not_found while fine-tuning is switched off. Credit and spend-limit refusals use the codes under Every route.

A failed job

A job that fails carries one of these in its error.code: