Humanoid Robotics Training Platform - Rust + Keycloak
  • Rust 78.2%
  • Smarty 10.3%
  • Dockerfile 6.6%
  • JavaScript 4.6%
  • CSS 0.3%
Find a file
Riley Seaburg b9759571aa
chore: Add workspace manifest
Add workspace Cargo.toml for building both humanoid and humanoid-platform together
2026-01-27 23:00:25 +00:00
charts/humanoid-platform Deploy to Kubernetes with Helm chart 2026-01-27 20:31:11 +00:00
config Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
k8s feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
marketing@b24705aaa6 feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
src feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
static Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
tests Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
.env.example Remove hardcoded credentials, add .env.example 2026-01-27 20:06:19 +00:00
.gitignore Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
Cargo.toml feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
Dockerfile feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
LEFTOFF.md feat: Integrate humanoid library and enable simulator 2026-01-27 23:00:18 +00:00
package.json Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
postcss.config.js Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
README.md Remove hardcoded credentials, add .env.example 2026-01-27 20:06:19 +00:00
rustyroad.toml Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
tailwind.config.js Initial commit: Humanoid Robotics Training Platform 2026-01-27 20:00:03 +00:00
workspace.Cargo.toml chore: Add workspace manifest 2026-01-27 23:00:25 +00:00

Humanoid Robotics Platform

A self-hosted training platform for humanoid robots, built with Rust.

Train, simulate, and deploy policies to Unitree G1/H1 humanoid robots.

Features

  • Robot Management: Connect and manage Unitree G1/H1 robots
  • Training Sessions: Reinforcement learning and imitation learning in simulation
  • User Management: Role-based access control via Keycloak (self-hosted)
  • Real-time Monitoring: WebSocket-based telemetry streaming
  • Model Deployment: Push trained policies to physical robots
  • Simulator Integration: Bevy + Rapier 3D physics simulation

Quick Start

1. Deploy Keycloak (Authentication)

# Docker Compose (recommended)
docker run -d --name keycloak \
  -p 8443:8443 \
  -e KEYCLOAK_ADMIN=admin \
  -e KEYCLOAK_ADMIN_PASSWORD=admin \
  quay.io/keycloak/keycloak:latest start-dev

Then configure your realm and client (see Keycloak Setup).

2. Configure Environment

cp .env.example .env

Edit .env:

# Your Keycloak instance
KEYCLOAK_URL=https://your-keycloak-server.com
KEYCLOAK_REALM=humanoid-platform
KEYCLOAK_CLIENT_ID=humanoid-web
KEYCLOAK_CLIENT_SECRET=your-client-secret

# Database
DATABASE_URL=postgres://user:pass@localhost:5432/humanoid_platform

# Application
APP_URL=http://localhost:8080
SECRET_KEY=your-secret-key-minimum-32-chars

3. Run Database Migrations

cargo run --bin migrate

4. Start the Server

cargo run --release

Platform available at http://localhost:8080

Project Structure

humanoid-platform/
├── src/
│   ├── controllers/     # HTTP request handlers
│   ├── middleware/      # Auth middleware
│   ├── models/          # Database models
│   ├── views/           # Tera templates
│   └── main.rs          # Application entry
├── config/
│   └── database/
│       └── migrations/  # SQL migrations
├── static/              # CSS, JS, images
└── Cargo.toml

Keycloak Setup

Required Realm Roles

Create these roles in your Keycloak realm:

  • super_admin: Full platform access
  • admin: Manage robots and training sessions
  • trainer: Create and run training sessions
  • viewer: View-only access

Client Configuration

Create a new client in Keycloak:

  1. Client ID: humanoid-web
  2. Client Protocol: openid-connect
  3. Access Type: confidential
  4. Valid Redirect URIs: http://your-domain/*
  5. Web Origins: http://your-domain

API Endpoints

Authentication

  • GET /login - Redirect to Keycloak
  • GET /logout - Logout and clear session
  • GET /auth/callback - OAuth callback
  • GET /auth/user - Get current user info

Robots

  • GET /api/robots - List user's robots
  • POST /api/robots - Register new robot
  • GET /api/robots/:id - Get robot details
  • POST /api/robots/:id/connect - Connect to robot

Training

  • GET /api/training - List training sessions
  • POST /api/training - Create new session
  • GET /api/training/:id - Get session details
  • POST /api/training/:id/start - Start training
  • POST /api/training/:id/stop - Stop training

Supported Robots

Model Price Range Support
Unitree G1 $16k-$70k Full
Unitree H1 $90k-$116k Full
Unitree R1 $9k-$31k Planned
Custom URDF - SDK

Development

Prerequisites

  • Rust 1.75+
  • PostgreSQL 14+
  • Docker (for Keycloak)
  • Node.js 18+ (for Tailwind CSS)

Running Locally

# Install dependencies
cargo build

# Start Tailwind watcher
npx tailwindcss -i ./src/tailwind.css -o ./static/css/output.css --watch

# Run server
cargo run

Running Tests

cargo test

Building for Production

cargo build --release

Deployment

Docker

docker build -t humanoid-platform .
docker run -p 8080:8080 --env-file .env humanoid-platform

Kubernetes

Helm chart coming soon.

License

MIT OR Apache-2.0

Support


Built by Evolving Software for the robotics community.