Reasoning

Score task progress

Send a clip of a robot (or a person) doing a task and get per-frame task progress and success probability from a reward model.

View as Markdown
POST/v1/reward

Reward models judge how far a clip has got with a task, frame by frame: dense rewards for reinforcement learning, success detection, and filtering or ranking demonstrations. Sample the video at a few frames per second; each model takes up to its own number of frames (Robometer: 8) and refuses more with a 400.

Authorization

Request body

JSON, with Content-Type: application/json.

  • modelstringrequired

    The reward model to run, e.g. usc/robometer. The live models for this endpoint are listed below.

  • instructionstringrequired

    The task the clip should be doing, e.g. "put the green stick in the brown bowl". 1–1,000 characters.

  • framesstring[]required

    The clip, oldest first: 1–32 frames, base64 JPEG or PNG, all the same size, under 4 MB of base64 together.

Response

  • idstring

    Unique id of this call, e.g. rwd_48213. It matches the call in your Activity dashboard.

  • modelstring

    The model that answered.

  • backendstring

    "http": the real model ran on a GPU. "simulated": stand-in output of the same shape, as test keys get.

  • sandboxboolean

    true when the call was made with a test key: the output is simulated, nothing ran on a GPU and nothing was charged. Absent otherwise.

  • progressnumber[]

    One per frame, oldest first: task progress from 0 (not started) to 1 (done).

  • successnumber[]

    One per frame: the probability that the task is complete at that frame. Only from models with a success head (Robometer has one).

  • usageobject

    What the call cost.

    Show 2 child attributes
    • cost_usdnumber

      Charged to your credits, in US dollars.

    • latency_msinteger

      Time the model took, in milliseconds.

Errors

400

More frames than the model takes, frames of different sizes, or no instruction.

Plus the errors every endpoint shares: invalid input, keys, credits and cold starts. See Errors.

Models

1 live model for /reward. Each page has a ready-made request.