Crescent Engine
Documentation

Run your first spatial experiment

Turn a saved World into a task, run it in the editor, and open the recording to see what happened.

World, task and recording

World
The scene you author with entities, materials, lights and cameras.
Task
The agent, target, physics settings and success or failure conditions captured for an experiment.
Seed
The initial random input for a run. Use the same seed when comparing behavior under the same conditions.
Recording
The saved initial state, actions and outcomes. A vision recording also stores camera evidence at model decision points.

Run the starter task

  1. In Project Hub, choose New Project → Spatial.
  2. Open Experiments. If a task is missing, use Task → Open Task and choose Tasks/ReachTarget.spatial.json.
  3. Choose Reference PD, keep seed 42, and press Run. This built-in controller drives the agent toward the goal without a model.
  4. Open the recording with Play Recording in Runs. Scrub the timeline to see the trajectory. The results list outcome, simulation ticks and reward.
What the view shows. Physics Preview and Physics Replay show colliders and target position. A World sensor camera uses the saved scene and can render its meshes, materials and lights. Model Camera in vision replay shows the archived input to a model decision.
Reference PD physics replay with the tick slider, selected agent and recorded position
Reference PD replay shows the trajectory, physics tick, reward and recorded entity state.

Capture your own task

  1. In World, make a floor with a static box collider and an agent with an enabled Rigidbody and a box collider. Add a separate target marker. Its world position sets the goal center.
  2. For vision runs, add an enabled perspective camera that frames the agent, target and obstacles. Use realtime scene lighting and save World.
  3. Go to Experiments → Task → Create Task from World. Pick the Agent and Goal marker. Set a radius such as 0.5 m and an episode limit such as 600. Check any supported box body that should end the run on contact.
  4. Click Create Task and run Reference PD to check the setup. Use Task → Save Task to reuse it.

When a World scene changes, save it and capture the task again before a vision run. The task is bound to the snapshot of the scene used to create it.

Create Spatial Task sheet with the red box selected as agent and green goal as target
Choose the agent and goal from named World entities, then set the goal radius, tick limit and forbidden contacts.

Choose a controller

Reference PD
A built-in physics controller. Use it to check whether the agent can move and reach the goal.
Project Policy
Your project's Python controller in Source/Agents/policy.py. Edit it in Source or your code editor.
Local Llama
A local text controller. Choose its server and text GGUF in Task → Local Llama Settings.
Vision model
Receives a rendered observation and an instruction. Use Task → Run Vision Model.

Run a vision model

  1. Set up a saved World task with a perspective camera. Use an episode limit between 61 and 720 ticks.
  2. Choose Task → Run Vision Model. Select Sensor camera and enter a task instruction, such as Move the red cargo to the green target without touching the blue barrier.
  3. Choose Local GGUF for a vision model and matching mmproj, with a compatible llama-server. Choose Model API for a provider or compatible Chat Completions endpoint, then enter the model ID and token as required.
  4. Click Run Model. In Replay, inspect Model Camera and the action at the selected decision. The simulator computes the outcome from the task rules.

Model API runs send the instruction and camera images to the selected provider. Local model runs keep these inputs on the Mac.

Run Vision Model sheet with sensor camera, model instruction, weights and vision projector fields
Run Vision Model binds the sensor camera and instruction to the chosen local model or API provider.

Inspect a run or fix setup

For a failed custom-task run, inspect the recorded camera input and test an alternate action. For package or model connectivity issues, run Spatial Doctor.

Run Vision Model is unavailable
Save the World, stop Play mode, and create a new task from the saved scene with an enabled perspective camera.
An entity is missing from the Agent picker
Check the Rigidbody and the enabled box collider in World. The goal marker is selected in its own picker.
The agent falls through the scene
Check the floor collider and placement. The preview grid provides a visual reference.
Two runs produce different actions
Use Compare → Compare Vision Runs with a common task, camera, instruction and seed. Open the first differing decision in replay.

For independent runs, report files and engine regression checks, see Spatial Bench workflows.