Skip to main content
Glama
Lecoeurdelest

mujoco-mcp

mujoco_get_state

Read-onlyIdempotent

Retrieve the current MuJoCo simulation state from a session without advancing physics, including positions, velocities, controls, sensors, body poses, and contacts as JSON.

Instructions

Read the current state of a session without advancing physics.

Returns JSON with the requested blocks: qpos/qvel/ctrl (vectors in model order),
sensors ({name: value}), bodies ({name: {pos, quat}} world-frame), contacts
({ncon, listed, contacts: [{geom1, geom2, pos, dist, normal_force}]}, capped at 20).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
includeNoState blocks to return, any of: qpos, qvel, ctrl, sensors, sensors_raw, bodies, contacts (default: qpos, qvel, ctrl, sensors)
precisionNoDecimal places for returned floats
session_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint false. The description adds substantial behavioral context beyond these: it specifies the return format (JSON blocks), the cap of 20 contacts, world-frame coordinates for bodies, and the exact shape of sensor/body/contact data. This goes well beyond what annotations provide.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, dense sentence that front-loads the core purpose and then enumerates output blocks. Every clause carries useful information—no filler, no repetition of schema content. It is concise yet comprehensive.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the read-only, idempotent nature (covered by annotations) and the detailed description of all possible return blocks, limits, and coordinate frames, the description covers everything an agent needs to call the tool correctly. It also notes the contact cap, addressing potential data volume concerns. No critical information is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema covers 67% of parameters with descriptions (include and precision). The description indirectly clarifies the 'include' parameter by detailing what each block (qpos, qvel, ctrl, sensors, bodies, contacts) returns, helping the agent choose values. However, it does not add explicit syntax or format details for the parameters themselves, so it does not fully exceed the baseline for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states a specific action ('Read the current state of a session') and explicitly notes it does not advance physics, distinguishing it from step or set_state tools. It also lists the exact data blocks returned, leaving no ambiguity about the tool's function.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase 'without advancing physics' provides clear context for when to use this tool (inspection rather than simulation advancement) but does not explicitly name alternatives or state when not to use it. The guidance is implicit rather than explicit, so it falls just short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.