The Dataset Viewer has been disabled on this dataset.

Causal GPT-RL — Unity ML-Agents trajectories

Recorded Unity ML-Agents trajectories packaged as Minari datasets — offline-RL datasets spanning continuous and discrete action spaces. Any offline-RL method can train on them; we built them to develop Causal GPT-RL, our new approach that works across both space types. All eight environments ship an expert tier and a full quality ladder (expert + calibrated medium/simple) synthesized by degrading the stock policy — Gaussian action-noise ranges for the continuous scenes, softmax-temperature ranges on the policy logits for the discrete goal games.

Tiers are keyed to Minari-normalized skill between a random-policy 0.0 anchor and the stock expert 1.0targets simple 0.60 / medium 0.80 / expert 1.0 (envs land at simple 0.58–0.62, medium 0.77–0.85). The degradation is not a single constant: it is drawn per episode from a calibrated range (the group/team scenes — DungeonEscape, SoccerTwos — draw per match instead), so each tier's mean hits its target while the episodes span a continuous band of skill instead of piling at one point.

한국어 카드 / Korean edition — this card in full: README.ko.md

Companion repos

Data-quality notice — action labels (resolved 2026-08-01)

Every dataset in this repo now carries the action Unity actually executed. ML-Agents agents decide only every k-th physics step and Unity repeats the last decision through the gap; the collector stored a placeholder 0 on those in-between steps instead of the action still being repeated, so the action column disagreed with the policy that produced the trajectory. Observations, rewards, terminations and the trajectories themselves were never affected, so every published return, step-reward and tier calibration held throughout.

The collector was fixed on 2026-07-30 — it now carries each agent's last real decision forward across a gap. All 21 affected datasets have been re-recorded and replaced: the twelve discrete-environment tiers on 2026-07-30, the nine continuous ones on 2026-08-01. Share of rows that carried a placeholder in the files they replaced (tier range: expertsimple):

env placeholder rows (replaced files) status
the four discrete envs — pushblock, dungeon-escape, soccer-twos, pyramids 3–72% all twelve tiers re-recorded 2026-07-30
crawler 0.57–1.03% all three tiers re-recorded 2026-08-01
walker 1.05–1.62% all three tiers re-recorded 2026-08-01
3dball-hard 0.02–1.46% all three tiers re-recorded 2026-08-01
worm 0% never affected — its agents never terminate

One cause, two very different rates. In the discrete goal games the gap steps are recorded like any other, so the placeholder simply follows the decision period and comes to dominate the column. In the continuous scenes a step on which no agent has either a decision or a terminal observation is dropped whole, so a pure gap step never enters the data at all — one survives only when another agent in the scene happened to terminate on that same step. The rate there tracks the scene's reset frequency and stays under 2%. worm is the limiting case of exactly that: its agents never terminate (every episode runs the full 1000 steps), so no gap step ever survives and its three tiers were clean as published.

Because a collection run is not bit-reproducible — agents finish episodes asynchronously, so the boundaries fall differently — each re-recorded tier has slightly different episode/transition counts and tier metrics than the file it replaced. Bands and noise seed were left untouched; this was a label repair, not a recalibration, and the metric movement is sampling noise rather than a change in the recorded policy. The tables below carry the new figures throughout.

Contents

Environment Observation Action Episodes (expert / medium / simple)
crawler Tuple(Box(126), Box(32)) Box(20, [-1, 1]) 1,043 / 1,120 / 1,325
pushblock Tuple(Box(105), Box(105)) Discrete(7) 53,039 / 39,033 / 26,666
soccer-twos ego Dict wrapping Tuple(Box(264), Box(72)) ego Dict wrapping MultiDiscrete([3, 3, 3]) 14,692 / 12,940 / 11,820
dungeon-escape ego Dict wrapping Tuple(Box(10), Box(360), Box(1)) ego Dict wrapping Discrete(7) 35,505 / 28,314 / 22,542
3dball-hard Tuple(Box(27), Box(18)) Box(2) 1,011 / 1,311 / 1,701
pyramids Tuple(Box(56), Box(56), Box(56), Box(4)) Discrete(5) 5,392 / 4,174 / 3,065
worm Box(64) Box(9, [-1, 1]) 1,000 / 1,000 / 1,000
walker Box(243) Box(39, [-1, 1]) 1,464 / 1,695 / 2,306

Dataset ids are unity/<environment>/<tier>-v0. Each holds about a million transitions (1,000,000–1,012,457).

All environments, datasets, and stock policies use ML-Agents release_23. Each dataset is stored at <name>/<tier>/data/main_data.hdf5 with a sibling metadata.json (minari_version 0.5.3). SoccerTwos and DungeonEscape use an ego-agent schema — observations["agents"]["agent_0"], actions["agents"]["agent_0"] — one ego episode per physical agent; split by match_id (see docs/reproduction.md).

Loading

from pathlib import Path
from huggingface_hub import snapshot_download
import minari

snapshot_download(
    repo_id="ccnets/causal-gpt-rl-unity-datasets",
    repo_type="dataset",
    allow_patterns="worm/**",                       # one env; all eight is 25 GB
    local_dir=Path.home() / ".minari" / "datasets" / "unity",
)
dataset = minari.load_dataset("unity/worm/expert-v0")
# calibrated tiers: minari.load_dataset("unity/worm/medium-v0" | ".../simple-v0")
print(dataset.observation_space, dataset.action_space)

One environment ranges from 0.6 GB (3dball-hard) to 6.5 GB (dungeon-escape), so allow_patterns is usually what you want.

Build your own in this format — the packager behind these datasets is source-agnostic: write five arrays per episode and it packages any source the same way, Unity or not. Input contract and how to check the result: collection/.

Quality ladders

Why these tiers look the way they do. In a normal RL pipeline, medium/simple data would come from early training checkpoints on the way to the expert. We don't have those checkpoints — only the final expert policy — so each tier is reduced backward from the expert: instead of one constant perturbation (a single degraded point), every episode draws its skill from a calibrated range, so the tier reproduces the distribution of skill a checkpoint spread would have.

Each ladder is a monotone skill sequence built from ONE stock policy: expert is the unmodified policy, medium/simple degrade it progressively. The degradation is calibrated so the tier mean hits its normalized target while episodes cover a continuous skill band (seed 2310000):

  • continuous scenes (crawler, worm, walker, 3dball-hard) add Gaussian action noise, noise_std sampled per episode from a calibrated range;
  • discrete goal games sample the policy's own action distribution via softmax(logits/T) on the exposed discrete logits — higher T picks plausible 2nd/3rd-best actions (smooth, in-distribution degradation, unlike epsilon-style uniform-random swaps which are bimodal and off-distribution). PushBlock and Pyramids each sample T per episode from a calibrated range (each episode its own skill level, like a spread of early-training checkpoints);
  • cooperative discrete DungeonEscape samples a softmax temperature T per group per match from a calibrated range — all three agents in a group share one T, so each match is one coherent skill level (like an early-training checkpoint); competitive self-play SoccerTwos samples a softmax temperature T per team per match from a (wider) calibrated range — the two teams draw independently, so each match pairs two skill levels (a random gap, like cross-checkpoint league play).

Normalization is (candidate − random) / (expert − random) on each env's tier metric.

env tier metric medium simple noise method
crawler episode return 0.83 0.62 per-episode noise_std range
worm episode return 0.80 0.60 per-episode noise_std range
walker episode return 0.85 0.59 per-episode noise_std range
3dball-hard episode return 0.77 0.58 per-episode noise_std range
pushblock step-reward 0.80 0.60 per-episode softmax temperature range
pyramids step-reward 0.79 0.60 per-episode softmax temperature range
dungeon-escape step-reward 0.80 0.61 per-group softmax temperature range
soccer-twos match score ≈0.80 ≈0.60 per-team softmax temperature range

soccer-twos figures are approximate: self-play stays balanced, so tier skill cannot be read off the shipped returns and comes from side-swapped calibration. Sparse-reward scenes (pyramids, pushblock, dungeon, soccer) have a physically bimodal per-episode outcome (solve vs. time-out), so the episode-return histogram barely separates the tiers. For the goal games (pushblock, pyramids, dungeon-escape) the tier metric is therefore mean step-reward = return / episode length, which grades how efficiently the goal is reached — a continuous skill signal — normalized expert = 1 / random = 0 against the shipped expert-v0 step-reward anchor (pushblock 0.3537, pyramids 0.01263, dungeon-escape 0.01936). simple targets 0.60 and the shipped tiers sit at 0.58–0.62 (SoccerTwos, scored by side-swapped match score rather than step-reward, is approximate); medium spans 0.77–0.85.

How precisely these are known. Every tier figure is a sample mean over the episodes of one recording, so it carries sampling error. The return-scored continuous scenes are the loosest, because a million transitions buys only one to two thousand episodes there: measured over the shipped files that is about ±0.01 normalized for 3DBallHard, ±0.015 for Crawler and ±0.03 for Walker, whose per-episode return has a standard deviation roughly as large as its mean.

Those are within-run errors. The run-to-run spread has also been measured directly: the 2026-07-30 label repair re-recorded the continuous scenes from identical bands and seed, so the two recordings differ only by the collection run itself. Across the six degraded tiers the normalized figure moved by 0.01–0.03, and both Walker medium and 3DBallHard medium moved a full 0.03 — three times the within-run figure quoted above for 3DBallHard. Treat 0.03 as the reproducibility of a continuous-scene tier number.

Read the second decimal as indicative rather than exact — a tier sitting at 0.83 instead of 0.80 is within what re-recording the same band moves, not evidence of a differently-calibrated band. The bands themselves are fixed constants of the recipe (listed per env below) and are the reproducible part.

"termination rate" below = fraction of episodes ending on the env's terminal condition — a fall for Crawler/Walker/3DBallHard, a solved push for PushBlock, maze solve ("reach") for Pyramids; Worm never terminates (truncated at 1000).

Per-environment ladder tables — exact ranges, anchors, mean returns, rates

Crawler — anchors: expert 2575.8405, random −0.88

tier norm. return noise_std range mean return term. rate mean ep length
expert-v0 1.00 -- 2575.8405 0.073 958.77
medium-v0 ≈0.83 0.15–0.23 2141.5175 0.193 892.86
simple-v0 ≈0.62 0.21–0.32 1605.4283 0.435 754.72

Worm — anchors: expert 1044.1063, random 0.80 (never terminates)

tier norm. return noise_std range mean return term. rate mean ep length
expert-v0 1.00 -- 1044.1063 0.000 1000.00
medium-v0 ≈0.80 0.09–0.15 839.4910 0.000 1000.00
simple-v0 ≈0.60 0.15–0.22 632.4776 0.000 1000.00

Walker — anchors: expert 1354.5654, random −0.49 (high intrinsic return variance)

tier norm. return noise_std range mean return term. rate mean ep length
expert-v0 1.00 -- 1354.5654 0.525 683.06
medium-v0 ≈0.85 0.05–0.11 1154.9421 0.651 589.97
simple-v0 ≈0.59 0.09–0.15 797.0197 0.827 433.65

3DBallHard — anchors: expert 98.9095, random 0.84 (capped balance: near-bimodal)

tier norm. return noise_std range mean return term. rate mean ep length
expert-v0 1.00 -- 98.9095 0.003 989.13
medium-v0 ≈0.77 0.28–0.38 75.8680 0.373 762.78
simple-v0 ≈0.58 0.31–0.44 58.0994 0.627 587.89

PushBlock — tier metric is mean step-reward (return / length); step-reward anchors: expert 0.353699 (shipped expert-v0, 53,039 ep), random ≈−0.0005 (soft). Each tier samples T per episode from a calibrated range (each episode its own skill level, like a spread of early-training checkpoints). Higher T still solves but wanders more, so the return stays high (≈4.9) while step-reward falls with efficiency. term. rate = solved.

tier norm. step-reward T (per episode) mean step-reward mean return solved rate mean ep length
expert-v0 1.00 -- 0.353699 4.972780 ≈1.00 18.85
medium-v0 0.80 U(2.1, 3.2) 0.282037 4.961591 0.997 25.88
simple-v0 0.60 U(3.25, 4.75) 0.213119 4.942463 0.996 37.88

Pyramids — tier metric is mean step-reward (return / length); step-reward anchors: expert 0.012633 (shipped expert-v0, 5,392 ep), random −0.001 (sparse: policy always times out at random). Each tier samples T per episode from a calibrated range (each episode its own skill level, like a spread of early-training checkpoints). Higher T reaches the goal less directly (longer episodes) so step-reward falls while return stays near expert. term. rate = mazes reached/solved.

tier norm. step-reward T (per episode) mean step-reward mean return reach rate mean ep length
expert-v0 1.00 -- 0.012633 1.797730 0.9911 185.46
medium-v0 0.79 U(2.7, 4.9) 0.009784 1.742249 0.990 239.58
simple-v0 0.60 U(4.8, 7.1) 0.007201 1.636223 0.981 326.26

DungeonEscape — cooperative goal game; tier metric is mean step-reward (return / length); step-reward anchors: expert 0.019355 (shipped expert-v0, 35,505 ego ep), random ≈0.00015. A softmax temperature T is sampled per cooperative group per match from a calibrated range and shared by all three agents (one coherent skill level per match, like an early-training checkpoint); higher T reaches the exit less efficiently so step-reward falls while the group still often succeeds. Group success any(agent_return > 0) (group_metadata.jsonl) therefore stays high across tiers and no longer separates them — step-reward does.

tier norm. step-reward T range (per group) mean step-reward group success mean ep length
expert-v0 1.00 stock (no noise) 0.019355 0.9604 28.37
medium-v0 0.80 U(1.5, 3.0) 0.015446 0.9183 35.76
simple-v0 0.61 U(3.0, 4.0) 0.011950 0.8585 44.43

SoccerTwos — tier metric is side-swapped match score vs the fixed stock policy (self-play, so mean shipped return ≈ −0.04 for both tiers and does not track skill; figures are calibration estimates). Each team draws a softmax temperature T independently per match from a (wide) calibrated range on the exposed MultiDiscrete logits, shared by its two agents — so each match pairs two independently-drawn skill levels (a random gap = cross-checkpoint league play). A tier is set by the ego team's own drawn T; the norm is that band's mean side-swapped match score vs the fixed expert. term. rate = matches always terminate.

tier approx. norm. skill T (per team/match) matches mean ep length
expert-v0 1.00 stock (no noise) 3,673 68.18
medium-v0 ≈0.80 U(1.3, 2.6) 3,235 77.46
simple-v0 ≈0.60 U(2.1, 3.4) 2,955 84.73

Episode lengths

Offline-RL and sequence models need the distribution of episode length, not just its mean: it sets the context window, how much padding is wasted, and whether length bucketing is worth it. Measured over the published files — cv is sd / mean, a quick read on how heavy the tail is.

The datasets fall into two regimes that behave very differently.

  • Locomotion scenes (Crawler, Worm, Walker, 3DBallHard) run until the agent falls and truncate at 1000 steps, so the stronger tiers pile up against that cap: Crawler expert and 3DBallHard expert/medium have a median of exactly 1000. Read their mean ± sd as a spike at the cap with a left tail, not a bell curve — Crawler expert still reaches down to a 2-step episode. Worm is the degenerate case: its agents never terminate, so all 3,000 of its episodes are exactly 1000 steps and its sd is exactly 0 in every tier.
  • Goal games (PushBlock, Pyramids, DungeonEscape, SoccerTwos) end when the goal is reached, so they are short and right-skewed. PushBlock is the extreme — mean 18.85, median 15, max 1000, cv near 2. Padding a PushBlock batch to the longest episode wastes roughly 50x; bucket by length instead.

Degradation moves the two regimes in opposite directions. Lower tiers fall sooner in the locomotion scenes (Crawler 958.77 → 892.86 → 754.72) but take longer to reach the goal in the goal games (PushBlock 18.85 → 25.88 → 37.88). If you use episode length as a feature or to size buffers, that sign flip matters.

DungeonEscape is the only environment that exceeds 1000 steps, and only barely: 3 of its 35,505 expert episodes run past the cap, the longest at 1,213 steps. Its other two tiers stay under. Everywhere else 1000 is a hard ceiling — the locomotion scenes, PushBlock and Pyramids all reach it exactly, while SoccerTwos matches end well short of it (longest 832). Size fixed buffers off this column, not off 1000.

Per-dataset episode-length distribution — episodes, mean, sd, cv, min/median/max
dataset episodes mean sd cv min median max
unity/crawler/expert-v0 1,043 958.77 157.56 0.16 2 1,000 1,000
unity/crawler/medium-v0 1,120 892.86 245.88 0.28 16 1,000 1,000
unity/crawler/simple-v0 1,325 754.72 332.53 0.44 7 1,000 1,000
unity/worm/expert-v0 1,000 1000.00 0.00 0.00 1,000 1,000 1,000
unity/worm/medium-v0 1,000 1000.00 0.00 0.00 1,000 1,000 1,000
unity/worm/simple-v0 1,000 1000.00 0.00 0.00 1,000 1,000 1,000
unity/walker/expert-v0 1,464 683.06 365.05 0.53 9 886 1,000
unity/walker/medium-v0 1,695 589.97 372.74 0.63 9 611 1,000
unity/walker/simple-v0 2,306 433.65 348.79 0.80 10 323 1,000
unity/3dball-hard/expert-v0 1,011 989.13 89.59 0.09 42 1,000 1,000
unity/3dball-hard/medium-v0 1,311 762.78 354.63 0.46 13 1,000 1,000
unity/3dball-hard/simple-v0 1,701 587.89 391.43 0.67 6 636 1,000
unity/pushblock/expert-v0 53,039 18.85 37.09 1.97 1 15 1,000
unity/pushblock/medium-v0 39,033 25.88 47.08 1.82 3 20 1,000
unity/pushblock/simple-v0 26,666 37.88 60.35 1.59 2 27 1,000
unity/pyramids/expert-v0 5,392 185.46 119.83 0.65 9 157 1,000
unity/pyramids/medium-v0 4,174 239.58 142.40 0.59 22 201 1,000
unity/pyramids/simple-v0 3,065 326.26 191.25 0.59 13 275 1,000
unity/dungeon-escape/expert-v0 35,505 28.37 26.31 0.93 1 25 1,213
unity/dungeon-escape/medium-v0 28,314 35.76 34.99 0.98 1 28 889
unity/dungeon-escape/simple-v0 22,542 44.43 48.03 1.08 1 31 969
unity/soccer-twos/expert-v0 14,692 68.18 63.14 0.93 6 48 574
unity/soccer-twos/medium-v0 12,940 77.46 71.27 0.92 7 55 479
unity/soccer-twos/simple-v0 11,820 84.73 83.51 0.99 7 59 832

Build & reproduction steps (per-env recording recipe): see docs/reproduction.md.

Provenance & attribution

  • Trajectories were generated by running Unity ML-Agents material (the builds and stock policies are Apache-2.0; see the envs repo for provenance and licenses).
  • The trajectory data in this repo is an original recording licensed CC-BY-4.0. Please attribute ccnets — Causal GPT-RL and note the Unity ML-Agents source environment.

License

Creative Commons Attribution 4.0 International (CC-BY-4.0). See LICENSE.

Downloads last month
336