Import a character, inspect its physical body, then train a controller. The visible character and the physical body have different jobs: the original mesh, materials and skin weights define its appearance; collision shapes and joints determine how it moves.
| Your file | What happens |
|---|---|
| MJCF or URDF | RLsim uses the authored physical structure. Inferred humanoid settings do not replace your joints or masses. Import options can add a floor, floating base, or missing actuators. |
| Rigged GLB, glTF or FBX | RLsim derives a physical body from the existing skeleton and mesh. Auto recognizes supported humanoid structures; Generic skeleton follows the source hierarchy. |
| Mesh with no skeleton | It can be imported as a rigid body. To articulate it, add a skeleton in your modeling tool or use optional AI rigging below. |
| RLsim body JSON | Restores the saved physical body, source assets and edits. It does not rerun the converter. |
Saved controllers keep the physical body they were trained on. Changing a body clears the current model selection and needs new training. To upgrade an older import, reimport the original character file. Loading an old checkpoint restores its old body.
To lock a single joint, select its body part in Advanced physics, choose Joint: Fixed, and apply. It stays attached to its parent in the rig's rest pose. A torque of zero only disables the motor; it does not lock the joint. The original visible mesh remains.
The helper scales motor strength using the chosen mass, gravity, leg length and joint role. It preserves pivots, colliders, joint limits and existing mass proportions. Unclear anatomy needs manual review. A ball joint's torque setting applies separately to each motor axis. Damping resists movement; it does not actively hold the body upright.
These are engineering starting values, not measured human strength or an optimized walking setup. Choosing realistic mass and geometry comes before tuning controller performance.
For practical tuning, keep mass, task, speed, network, PPO settings and sample budget fixed while comparing strength multipliers such as 0.75, 1 and 1.25. Try at least three training seeds and several separate evaluation seeds. Compare falls, time upright, speed error and distance as well as reward. Locking joints changes action-based effort penalties, so reward alone can be misleading. Short training runs check compatibility; longer controlled trials are needed to choose a reliable setup.
First inspect a short Simulate without control run for disconnected limbs, implausible contacts or explosive motion. An unpowered character may fall; this check does not establish that it can learn to balance.
For a humanoid, use Train → Task → Balance to test balance learning, then evaluate Velocity with a longer training run. Selecting a different task starts a new run; RLsim does not automatically transfer a Balance controller into Velocity training. A small default run is an experiment, not proof of a usable gait. More training cannot compensate for a broken physical body, and importing a valid rig does not guarantee learned walking.
Animations embedded in a character file are not currently imitation-training demonstrations. The physics controller generates the movement you see.
For template bodies, select Train → Task → Coordinated walking (templates). This new-run option rewards alternating foot contacts, foot clearance and a level body while discouraging foot drift, bouncing and abrupt actions. Use Gradual speed for curriculum. Ground drift penalty adjusts how strongly foot movement along the floor is discouraged; new UI runs start at 1. Excessive penalties can hinder learning. Imported rigs keep their existing Velocity/Balance objectives.
The network chooses joint-position targets. Simulate rest targets holds the neutral targets with active servos; it is not a zero-torque baseline. A feedback controller turns those targets into bounded torque. A phase clock specifies which legs should support the body; the network learns the motion. This supplies a gait prior, not an animation or unrestricted discovery of every gait. Existing controllers retain their original controls and cannot be continued into this different objective.
Count knee or torso contact as a fall checks actual collision contacts at every physics step. It helps prevent a policy from using its knees or torso as extra feet. New walking runs enable this; older models keep their original setting. Turning off termination on fall still records and penalizes these contacts.
Motor work penalty is optional (0–2, initially 0). It discourages simulated motor work, scaled by body weight and requested speed. Too much can discourage stepping. Inference reports motor work in joules and work divided by weight and distance; a lower value is only useful when walking and speed also succeed. This measures mechanical work, not battery use.
Steps by leg counts completed swings with at least 0.12 s in the air, 4% of leg length in clearance, and 6% in horizontal travel. The gait check also requires six steps per leg, 15–85% grounded time per leg, less than 0.35 m/s foot-center drift and 0.25 rad RMS torso tilt, along with surviving 20 seconds and matching speed within 0.35 m/s average error. Ground contact is estimated from a 12 mm foot-to-floor gap. Foot drift includes rolling of the spherical feet; it is not a contact-force measurement.
The earlier demos and proportion tables measured speed and survival, which can reward stumbling or dragging. Inspect leg use as well as those scores. Increasing exploration alone does not fix a reward that accepts poor gaits. See Legged Gym for related control and reward ideas.
The adviser uses controls, observation dimensions, articulation and body structure to choose a starting network and sample budget. The tested CPU/GPU backend affects environment and minibatch sizes. Physics remains on CPU. Available physical metadata helps identify missing actuation, unusual scale or mass distribution, and other issues that larger networks cannot fix.
The suggestions preserve your body, selected objective, reward and seed. For Velocity, a reliable leg length can produce a modest starting speed; that change appears in the review table. Custom rewards and bodies with unknown leg dimensions retain the current speed. The adviser initially disables physics randomization to simplify the first trial; re-enable it in later trials when testing robustness.
These are heuristic starting settings, not a measured optimum or a guarantee of walking. The numerical rules have not been benchmarked as improving success rates across bodies. Complex humanoids may need more than the app's two-million-step limit. A separate Balance run does not transfer its controller into Velocity training.
Changing the body, objective, environment or training controls clears the old recommendation. Generate a new one when the preview is ready. Saved controllers retain their own settings. Selecting a model initializes its inference speed to the trained value; edit it to test other commands.
For the principles behind tuning and evaluation, see SB3's RL guidance and its PPO documentation. RLsim's numerical thresholds are engineering choices.
Explore contains pretrained gallery demos and experiment comparisons. Watch runs a saved controller in live physics. The published comparison includes every planned trial; Compare your models evaluates selected controllers on shared test seeds and flags differences in their tasks and training budgets. The downloadable JSON retains the raw results.
Model → Continue training creates a new run from the latest checkpoint with an additional step budget. New checkpoints retain optimizer, normalization, random-generator and curriculum state. Episodes restart, so this is continued learning rather than exact trajectory restoration. The saved body and training settings stay fixed, and the original run is preserved. Use Stop and save before closing. Older, gallery and ONNX controllers without complete training state remain inference-only.
Train → Advanced → Keep best evaluated checkpoint keeps both the latest controller and the one with the highest mean validation return. By default, three deterministic episodes run every 16,384 training steps and at completion, at the original task and full requested speed. Validation uses nominal physics, adds time outside the training budget, and never updates weights or normalization.
Model → Checkpoint chooses Best evaluated or Latest. Each stores its matching normalizer; downloads include both. Older models and runs stopped before their first evaluation use latest weights. “Best” is relative to the validation episodes and reward: inspect survival, speed error and motion on new seeds too.
Target KL defaults to 0.03. It stops further updates on the current rollout when the policy changes too much; training continues with new experience. Zero disables this safeguard.
Browser inference automatically caches one prepared controller and physics model. Repeated inference resets the requested seed and episode state. Changing the checkpoint, world or speed replaces the cache, and starting training clears it. First loads still require preparation.
Stop inference beneath the viewer cancels prediction generation, including during loading, in both This device and Server modes. Pause only pauses playback. Stop retains generated frames as a partial episode for Play or timeline review, releases the browser inference cache, and leaves saved models unchanged. The same button reads Stop simulation for a body baseline. An in-flight load or prediction may finish before stopping; the button reads Stopping… until generation exits.
For a Velocity task, enable Use curriculum and select Balance → walking. Stages are balance at zero speed, then 25%, 60% and 100% of your requested speed. If physics randomization is enabled, its range grows from zero to 25%, 60% and 100%.
Advancement requires 12 completed training episodes with at least 80% survival and average speed error no greater than max(0.15 m/s, 35% of stage speed). Stages change between rollouts. Training can finish at an early stage if the body has not met the gate; validation always measures the final task at full speed. The UI shows the current stage. Gradual speed keeps the original time-based ramp, and unchecking Use curriculum disables the curriculum.
For an editable imported rig, choose Body → Advanced physics → Joint targets (PD) and Apply physics. Train a new controller after switching: old models retain their own control mode. The original mesh and rest transforms are preserved.
The policy requests target angles. MuJoCo position servos control hinges, and orientation servos control ball joints using quaternion error. Zero action holds the rest angle or the nearest allowed hinge angle. Defaults are 30° excursion, stiffness scale 1 and damping ratio 0.7. Joint limits constrain targets; the torque field caps hinge torque and the total torque-vector magnitude for a ball servo. Passive joint damping still applies. These are starting values to test, not guaranteed optimal settings.
Fixed joints stay fixed and unpowered joints stay passive. Free-root motors are unsupported in this mode. Body JSON and XML retain the servos; external training must use the action mapping from Export interface. In this mode actions represent normalized targets, and underlying MuJoCo controls are radians. Ball targets use bounded exponential-map vectors. Keep the exported action_schema in ONNX manifests. Orientation servos require a compatible MuJoCo runtime, such as the bundled version.
Simulate rest targets sends zero target actions with the servos active. It is not a zero-torque baseline.
Open Explore → One policy, different proportions in This device mode. Move the torso, upper-leg or lower-leg sliders and release to run a fresh episode. You can disable automatic replay and use Apply proportions & replay. The same controller weights and observation normalization are used for every shape. The checkpoint identifier stays fixed. Use Stop inference to cancel generation.
Coordinated · wider range adds a walking-speed slider and trains across 60–140% proportions and 0.5–1.5 m/s commands, still excluding the marked upper/lower-leg corner. It checks that every leg takes repeated steps and counts knee or torso support as a fall. The same weights control every shape and speed. Extreme combinations can still fail; read the separate native, CPU and GPU results under How well does it generalize?.
The broader controller comes from a separate refinement study with one warm-started seed and two motor-work penalty settings. Condition choice uses a validation audit; final testing uses 24 fresh random shapes plus five nominal speed commands and three fresh episode seeds. This is not the original three-seed comparison below, nor evidence of a globally optimal gait.
The original varied controller trained on symmetric planar quadrupeds with each length sampled from 80–120% of its original value, widening over the first 131,072 steps. The corner with upper legs at least 110% and lower legs at most 90% was excluded at every training reset. Withheld shape tests that corner. Outside range tests extrapolation beyond the sampled limits. Failure is a valid result; remaining upright without matching the speed target is reported separately from walking.
All shapes retain the same eight joints, total nominal mass, segment thicknesses and nominal motor torque. MuJoCo recomputes inertia, joint positions and standing height from the changed geometry. Both training conditions also randomize mass, torque and floor friction. Arbitrary imported meshes and different skeletons are outside this experiment.
Switch to Trained on one body for the original matched baseline. Both conditions use the same PPO settings, training budgets, training seeds and checkpoint-selection suite. Three validation shapes select checkpoints; the twelve final test bodies and their episode seeds are separate. The table averages success across bodies and episodes within each training run, then reports variation across three independent training seeds. Download the report for every trial, body, seed, failure and source hash. The demo uses one checkpoint per condition selected by validation, so its replay is not the aggregate result.
Success means surviving the full 20 seconds with mean absolute speed error no greater than 0.35 m/s at a 1 m/s target. Tests use nominal physics; this experiment does not establish robustness to all dynamics, new joint layouts or real hardware. The browser uses portable weights and its own MuJoCo runtime; numerical differences can change a trajectory.
Training across proportions is currently a native feature. Configure morphology: {"enabled": true, "width": 0.2, "ramp_steps": 131072} in a native training configuration. Native continuation preserves the body sampler's RNG and uses cumulative steps for its variation schedule. The bundled browser controllers support inference only.
SkinTokens / TokenRig generates skeletons and skin weights. It is useful when a model has no usable rig. It does not generate a trained walking controller or validated physical properties. A good existing rig can go straight through the ordinary importer.
The official generator requires an NVIDIA GPU with at least 14 GB VRAM, its separate software environment and model weights. This is a local preparation step, not a browser feature. There is no CPU fallback for this generator. RLsim’s browser physics and GPU/CPU training remain available without installing it.
The helper accepts one self-contained GLB up to 64 MB with embedded textures and buffers. The output must also fit the 64 MB browser import limit. Convert other formats to GLB in a modeling tool first.
Prepared examples includes a humanoid, giraffe and six-legged crawler generated by the real pretrained model. These examples also work on static hosting. They have no walking policies. Already-rigged models should go through ordinary Rig: Auto import to retain their existing skinning.
For persistent local configuration, save rigging.local.json in the RLsim project with {"checkout":"/absolute/path/to/SkinTokens","python":"/absolute/path/to/its/python"}, then restart with ./run.sh. Environment variables take precedence. The command-line workflow remains available:
rlsim rig-prepare --doctor --check-runtime \
--checkout /path/to/SkinTokens \
--python /path/to/skintokens-env/bin/python
rlsim rig-prepare /path/to/character.glb \
--output /path/to/character-rigged.glb --preserve-mesh \
--checkout /path/to/SkinTokens \
--python /path/to/skintokens-env/bin/python
Use --dry-run with the preparation command to inspect the planned invocation. You can set RLSIM_SKINTOKENS_HOME and RLSIM_SKINTOKENS_PYTHON instead of passing the two paths each time. The helper uses the original-texture/scale transfer option by default. --use-skeleton reuses an existing GLB skeleton while generating skin weights and requires an input with a skin and skeleton.
--doctor checks installation files without loading ML libraries. Adding --check-runtime probes dependencies and CUDA in the external environment. Neither check loads the pretrained networks or guarantees that a particular asset can be rigged successfully.
AI-generated rigs require review. Shape, topology and unusual anatomy can confuse automatic skeleton generation; keep the original file and compare the result. This helper runs on your own machine. A deployed static site does not upload files to a GPU service or run a remote generator.
The guided workflow retains original geometry, textures, materials and mesh transforms. It adds predicted bones and normalized skin weights. A rest-surface mismatch larger than 0.01% of the source bounding-box diagonal (minimum one microunit) rejects the result. Morph targets, sparse geometry and compressed meshes need a compatible GLB export first. Preserved appearance at rest does not guarantee correct deformation.
Checks validate the physical graph, mass distribution, floor penetration, non-neighbor collider overlaps, motor response to small positive/negative commands, and two seconds of finite simulation without resets. Falling without a controller is informational. Generic unnamed bones receive a joint-limit review note. Mass, motor strength and collision shapes remain estimates; self-contact is disabled. Passing checks does not establish standing or walking.
A source-symmetry heuristic can flag missing joint counterparts. It does not understand intended anatomy or count every limb. Inspect unfamiliar shapes and regenerate if needed. Errors block new training for prepared bodies; review notes explain assumptions without requiring a confirmation dialog.
| Body | Joints / controls | Generation | Outcome |
|---|---|---|---|
| Giraffe | 47 / 138 | 75 s | Review joint limits and overlaps |
| Humanoid | 28 / 81 | 60 s | Review joint limits and overlaps |
| Six-legged crawler | 14 / 39 | 37 s, second attempt | Review joint limits |
Measured on an RTX 5080 using actual SkinTokens inference. All selected results retained original geometry and materials and responded to every motor probe without simulation resets. The crawler's first prediction missed a rear leg branch; the symmetry heuristic flagged it, and a second prediction supplied six leg chains. This is a documented retry, not a universal success claim. No walking policies were trained for these examples.
Download the validation report · SkinTokens and giraffe source license