mujoco_load_model
Load a MuJoCo model into a new simulation session using a sample, file path, or raw MJCF XML. Get a session ID plus joint, actuator, and sensor names for stepping and controlling the simulation.
Instructions
Load a MuJoCo model into a new simulation session. Provide exactly ONE of sample | file_path | xml_string.
Returns JSON: {session_id, source, nq, nv, nu, nsensor, nkey, timestep,
joints: [names], actuators: [names], sensors: [names], keyframes: [names]}.
The name arrays define the element order of qpos/qvel/ctrl vectors used by every other tool.
Next: mujoco_step to advance physics, mujoco_get_state to read, mujoco_model_info for ranges/types.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sample | No | Bundled sample scene: pendulum, cartpole, arm2, box_drop | |
| file_path | No | Path to an MJCF .xml (or compiled .mjb) on the machine running this server, e.g. a mujoco_menagerie scene.xml | |
| session_id | No | Explicit session id (letters, digits, '_', '-', '.'); auto-generated when omitted | |
| xml_string | No | Raw MJCF XML document |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |