Skip to main content
The robot capability is in beta - see the Robots reference.
This cookbook runs pi0.5 against LIBERO (a Franka Panda manipulation benchmark) packaged as a Docker image: three episodes, each in a fresh container, graded by the sim’s own success check. The split of work is the thing to notice - the policy runs in your process on your GPU, while the container is CPU-only and publishes exactly one port.

The environment

The env module only declares; it runs no policy of its own. It wires three things together: a bridge that drives the simulator, a RobotEndpoint that exposes the bridge as a capability, and two-yield task templates. This is demos/inventory/envs/libero/env.py, abbreviated:
env.py
The image’s CMD serves it with the standard entry point (hud serve env.py --host 0.0.0.0 --port 8765). This env lives in HUD’s demos/ examples tree, a sibling of the hud-python SDK; build it from the parent directory that holds both demos/ and hud-python/ so the image can install the SDK from local source:

The agent

A stock LeRobot checkpoint needs no custom Model or Adapter:
run_libero.py

Run it

Here DockerRuntime sets the placement, and each rollout is self-contained:
  • The container is created fresh with docker run, publishes its control port, is connected to, and is removed when the episode ends.
  • The agent reads the env’s contract from the manifest at connect time and wires cameras, state, and actions itself - there is no shared config between this script and the image.
  • The robot WebSocket binds to container-loopback and rides that single control port through capability tunneling.
For heavy sims (or sweeps), skip the per-episode boot with one long-lived container:

Read the trace

With HUD_API_KEY set, every episode streams to the platform automatically: the trace viewer plays the camera frames back under a scrubber, with diamond markers at each step where the policy predicted a fresh action chunk - scrub between markers to watch a chunk execute, click one to jump to the decision point.

See also

Robots reference

Contracts, bridges, sim threading, and the harness API.

Package & deploy