cd /news/robotics/robots-liquids-cloth-and-sand-in-one… · home › topics › robotics › article
[ARTICLE · art-170265] src=dev.to ↗ pub= topic=robotics verified=true sentiment=↑ positive

Robots, liquids, cloth and sand in one scene: an open-source engine for robot learning

The Alloy project released an open-source (Apache-2.0) physics engine for robot learning that simulates rigid bodies, cloth, granular materials and liquids in a single scene, built on MuJoCo Warp and Newton. Each object is routed to a solver by material — MuJoCo Warp for robots and rigid bodies, Newton's VBD for cloth, Newton's implicit MPM for sand and pastes, and Alloy's own DFSPH solver for liquids — with cross-solver contact in one world. The engine ships an MCP server so agents like Claude Code can build and run scenes, and is installable via pip for Python 3.11 or 3.12.

by read2 min views1 publishedNov 16, 2026

Many of the tasks we want robots to learn mix materials: pouring water into a glass, folding a towel, scooping sand, routing a cable. In simulation those materials usually live in different tools, so a policy that has to pour and grasp ends up stitched across engines, or the liquid gets left out.

Alloy is an open-source (Apache-2.0) physics engine for robot learning that puts them in one scene. The paper is on arXiv: Alloy: A Multi-Material Physics Engine for Robot Learning.

Alloy is built on MuJoCo Warp and Newton and picks a solver for each object from its material:

Object Solver
Robots and rigid bodies MuJoCo Warp (MuJoCo C on the CPU)
Cloth and soft bodies Newton's VBD solver
Sand, granular material and pastes Newton's implicit MPM solver
Liquids Alloy's own DFSPH solver

Objects from different solvers touch each other in the same scene. sim.routes() tells you which solver each object got. Here an MJCF arm sits beside a tub of water and a tray of sand:

import alloy

ARM = """<mujoco><compiler angle="radian"/><worldbody><body name="link1" pos="0 0 0.1">
  <joint name="shoulder" type="hinge" axis="0 1 0" range="-2 2" damping="2"/>
  <geom type="capsule" fromto="0 0 0 0.3 0 0" size="0.02" mass="1"/>
  </body></worldbody>
  <actuator><position joint="shoulder" kp="200" kv="10"/></actuator></mujoco>"""

scene = alloy.Scene(dt=0.01)
scene.add_ground()
scene.add_robot("arm", mjcf=ARM, pos=(0, 0, 0.1))
scene.add_open_box("tub", inner=(0.08, 0.08, 0.05), wall=0.01, pos=(0.5, 0, 0))
scene.add_liquid("water", size=(0.064, 0.064, 0.024), pos=(0.5, 0, 0.024))
scene.add_open_box("tray", inner=(0.1, 0.1, 0.05), wall=0.01, pos=(0.5, 0.4, 0))
scene.add_box("sand", size=(0.06, 0.06, 0.03), pos=(0.5, 0.4, 0.03), material="sand_silica_dry")
sim = alloy.build(scene, device="cpu")
print({n: sim.routes()[n]["solver"] for n in ("arm", "water", "sand")})
sim.run(0.3, targets={"shoulder": (0.0, 0.3)})
print(sim.state(world=0)["arm/shoulder.q"].round(2), sim.check()["ok"])
{'arm': 'mujoco', 'water': 'sph', 'sand': 'mpm'}
0.25 True

The MJCF string is the robot; a robot file such as a Franka loads the same way with add_robot. sim.check() grades the world, so you can catch a simulation that blew up instead of training on it.

Alloy ships an MCP server, so an agent such as Claude Code can build and run scenes itself:

pip install alloy-engine
claude mcp add alloy -- alloy mcp

pip install alloy-engine (Python 3.11 or 3.12)

── more in #robotics 4 stories · sorted by recency
── more on @alloy 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/robots-liquids-cloth…] indexed:0 read:2min 2026-11-16 · —