Skip to main content
Runs LeRobot’s async-inference PolicyServer in the foreground, so run-policy can offload inference to a more powerful machine (e.g. a desktop with a discrete GPU) on the same network as the robot. The robot streams joint positions + camera frames to it over gRPC and receives action chunks back. The policy itself (--policy_path / --policy_type / --device) is selected by the client (run-policy), not the server — so one server can serve different policies across sessions without restarting. The server downloads the policy itself, so the path must be reachable from it (e.g. a HuggingFace Hub repo ID, or a local path that exists on the server machine).
This is a trusted-network-only service. Axol replaces LeRobot 0.6’s pickle transport with bounded, versioned setup/observation/action formats, but the gRPC connection still has no TLS or client authentication. Any reachable client can request a supported policy checkpoint/path to be downloaded and loaded, consuming server resources; a peer or machine-in-the-middle can impersonate the server and return arbitrary robot actions. Put the inference machine and robot on an isolated network (or authenticated VPN), firewall the port so only the intended peer IP can connect, and never expose it to shared Wi-Fi or the public internet. Treat every policy checkpoint itself as trusted input.
Then, on the robot:
Requires the lerobot extra and, for GPU inference, a CUDA-capable PyTorch install on the server machine. Without --server_host, run-policy spawns its own local PolicyServer child process — this command is only needed when inference runs on a different machine.