Model API

One robot, zero-shot. Pull a trained policy and run it inside your own physics loop. Nothing to train on your side.

Host  https://ryanrana04--hazard-intelligence-api-api.modal.run

Usage

The client downloads the policy once and runs it locally, so nothing touches the network inside your control loop. Download hi_client.py

# pip install numpy onnxruntime
from hi_client import pull

policy = pull(HOST, "g1-ski")
actions = policy.infer(obs)

Reference

pull(host, policy="g1-ski") → Policy

Fetches the policy's spec and ONNX file once, caches them under ~/.cache/hi, and returns a Policy that runs on your CPU.

Policy.infer(obs) → actions

One flat observation in, 31 actions out, every 20 ms. Takes a single vector or a batch. Actions 0 and 1 set the body's lean; 2 to 30 nudge the 29 joints. Both feed NVIDIA's SONIC controller, which drives the motors.

Policy.meta → dict

Everything needed to wire it up: the architecture, the name and position of every input, the action layout and scales, the control rate, and where the checkpoint came from.

Policies

NameInputs → outputsBenchmark
g1-ski141 → 3119 of 24 test slopes without a fall
g1-ski-trees156 → 31adds tree avoidance; not scored yet

Both are a small network (four layers, 241k parameters) trained in simulation for the Unitree G1.

HTTP

For languages without the client, or to call the policy remotely.

GET /v1/policiesList of policies
GET /v1/policies/{id}The full spec, same as Policy.meta
GET /v1/policies/{id}/onnxThe runtime file
POST /v1/policies/{id}/infer{"obs": [...]} in, {"actions": [...]} out
WS /v1/policies/{id}/wsStreaming inference over a websocket
← Back