The first exam for code agents in the physical world: frozen robot tasks from many benchmark suites, each answered with a program and verified in a separate sandbox. Runs on Harbor.
MuJoCo Playground · ALOHA single peg insertion — STANDARD MODE (robot as a service)
An ALOHA 2 bimanual robot (two ViperX 300s arms facing each other across a table) has a blue socket (a square
tube, open on one end, red wall at the back) and a red peg in front of it.
Task: pick up the socket with one arm and the peg with the other, lift both, and insert the peg's end into the
socket's open end. This is MuJoCo Playground's AlohaSinglePegInsertion, run here in plain MuJoCo; the peg and socket
positions are randomized as in Playground, with a fixed seed.
You control the robot as if it were real hardware: the simulator runs in a service you cannot open. You get one client and one episode.
Rules (real-robot rules)
- No reset. Knocked-over objects stay knocked over.
- No privileged state. You see what the cameras see (RGB, optional depth, with each camera's calibration) plus the robot's own joint positions, velocities and targets. No object poses, no success predicate.
- Your only budget is the time limit (
## Time limit).meta["time_left_s"]is the service's count of it, from your first request to the service: it never runs out before your time does, so plan by it. There is nothing to hand in: the service records the episode as the trajectory and grades it. Leave your script at/app/output/gen.pyfor the record. - Do not use pretrained manipulation policies or any published solution for this benchmark; write your own controller.
- Images come back as arrays in a Python object; what you look at and where you store it is up to your code.
Scoring
At the end of the trajectory the peg's tip (site peg_end2) is within 5 mm of the socket's axis (the line
through sites socket_rear and socket_entrance) and inside the socket, at least 12 mm from its open end: the
axial parameter t is in [-0.875, 0.75], where t = 0 at socket_rear (the middle of the tube), t = 1 at
socket_entrance (the open end; 48 mm per unit of t) and t = -0.833 at the inner face of the red rear wall (the cavity
is 88 mm deep; the lower bound leaves 2 mm for the contact's give). A peg pushed all the way in counts.
The service applies exactly this rule.
Client (/opt/tools/rcb_client.py, protocol eai-standard/2.1)
from rcb_client import Robot
r = Robot() # connects (waits while the service starts)
spec = r.spec() # control_dt, action layout + limits, cameras, proprio layout, budget
cams = list(spec["cameras"]) # camera names
obs = r.get_obs(cameras=cams, include_depth=True) # obs.last[cam] -> uint8 (240, 320, 3); obs.depth[cam] -> float16 metres
obs.meta["proprio"] # {"layout": [...], "now": [...]}: joint positions, velocities, current targets
obs.meta["cameras"] # per camera: intrinsic_cv, cam2world_gl (OpenGL: looks along -z)
obs.meta["task"] # see below
obs = r.get_obs(cameras=cams[:1], seconds=2.0, video="mp4") # hold the targets and watch for 2 s (max 30)
res = r.submit("joint_position", A, dt=spec["control_dt"], cameras=cams[:1], video="mp4") # A: (T, 14) rows dt apart
res.meta["done"], res.meta["reason"], res.meta["task"], res.meta["control_steps"]
res.video[cam]; res.frames[cam]; res.last[cam]; res.proprio; res.save("/app/runs/003")
- Actions
joint_position(14: per armwaist, shoulder, elbow, forearm_roll, wrist_angle, wrist_rotate, gripper); rows aredtapart (a multiple ofcontrol_dt), each held (interpolate="hold") or ramped from the previous row ("linear", default) over its control steps; clipped to the limits in the spec. A chunk covers at most 10 s. meta["task"]= the task's target (target_pos, andtarget_quat_wxyzwhere it has one). The episode runs until your time is up; the final state is graded (so end in the pose you want graded, and keep it).- Calibration:
meta["cameras"][cam]holdsintrinsic_cv(pinhole, pixels) andcam2world_gl(4x4 camera-to-world, OpenGL axes: x right, y up, the camera looks along -z; the viewpoint the image is rendered from), for the state at the end of that call (thelastimage and the last frame of every stack). Depth is the distance along the viewing axis, in metres. The overhead and teleoperator cameras are fixed. The two wrist cameras move with the arms (spec["cameras"][cam]["moving"]): for them a response with several frames also carries one pose per frame,res.raw["cam2world_gl/<cam>"]["data"], float64(n_frames, 4, 4).intrinsic_cvis[[fx, 0, cx], [0, fy, cy], [0, 0, 1]]for the 320 x 240 image; fx and fy differ for the overhead and wrist cameras (their sensor is wider than the image): use both.
One call returns at most 3000 images (max_frames_per_call, PROTOCOL §3 "Images per call").
External material
You may install packages you need (pip, apt), and you may read anything installed in your container, the simulator's and this benchmark's own source code included. Please solve the task yourself: do not search the web for, or download, a ready-made solution to it, such as published or reference solutions, recorded demonstrations, or policies trained for it. This is an honour rule; trials are reviewed. The network reaches your model's API and the package registries (PyPI, Debian / Ubuntu archives) only.
Resources
Your container: 4 CPUs, 16 GiB of memory, 8192 processes and threads and 20 GiB of disk (new files under /app, /tmp and /root). Your container has no GPU. The simulator runs in its own container and does not count against these. CPU only slows you down; a process that goes over any other cap can be killed. Usage and caps: /run/rcb-limits/usage.json.
Time limit
You have 1800 seconds to complete this task. Do not cheat by using online solutions or hints specific to this task.
This is wall-clock time from the start of your session; the time you wait for the simulator service counts. When it is up you are stopped without warning and the episode is graded as it stands at that moment. The service's time_left_s counts the same limit from your first request to the service, so it never runs out before your time does: your real time left is time_left_s minus the time you spent before that request. Plan by it. Your session started when you received this task. /run/rcb-limits/usage.json, rewritten every few seconds, gives the time left on this limit (time_left_s) and its end (deadline_utc), counted from a little before your session started, so it never gives you more time than you have: read it (or run date) before you decide that time is short, never guess. Waiting counts too: a tool call that sends input to a process that keeps running (an interactive interpreter, a simulator loop, a server) can wait for the whole wait or yield time you give it even when the answer is printed at once, so give such calls a short wait and poll again if the output is not complete, or run one-shot scripts that exit when they are done. Installing packages is not cheating (## External material above).