Kalso42/WorldModelForMazeWithX
WorldModelForMazeWithX Maze pathfinding sequences for training/probing sequence models (Transformer, Mamba, GRU, Gated-DeltaNet, ...). Task C1: relative-turn navigation on a fixed 10×10 directed grid. Includes a special x terminator marking wall-hit (illegal) paths, used to study a model's ability to recognize its own errors. Maze 10×10 grid, 100 nodes (0–99). Directed edges (down/right, both directions added), edge probability 0.6. Graph:… See the full description on the dataset page: https://huggingface.co/datasets/Kalso42/WorldModelForMazeWithX.
WorldModelForMazeWithX
Maze pathfinding sequences for training/probing sequence models (Transformer, Mamba, GRU, Gated-DeltaNet, ...). Task C1: relative-turn navigation on a fixed 10×10 directed grid. Includes a special `x` terminator marking wall-hit (illegal) paths, used to study a model's ability to recognize its own errors.
Maze
- 10×10 grid, 100 nodes (
0–99). Directed edges (down/right, both directions added), edge probability 0.6. - Graph:
maze_graph_C1_RWs.graphml(node ids are strings'0'..'99').
Sequence format (Task C1)
C <src> <tgt> : <turn tokens...>- Agent starts facing East. Each turn token both rotates and advances one cell:
Fforward,Lleft,Rright,Tturn-around.- Nodes
0–99are single tokens;:separates the prompt from the path. - `x`: wall-hit terminator. A "wrong" path is a correct path with one turn corrupted into a wall direction, then
xappended. Only the finalxis supervised during training.
Files (under data/)
.txt: human-readable sequences..bin:uint16token stream (read withnumpy.memmap)..bincan be regenerated from.txtviaprepare_multitask_minigpt.py.- Only the 10M set contains wrong paths; 5M / 8M never expose
x(models trained on them never emitx).
Loading
import pickle, numpy as np
meta = pickle.load(open("data/meta_C1_RWs.pkl", "rb"))
itos = meta["itos"] # x token id = 131
ids = np.memmap("data/train_C1_RWs_10M.bin", dtype=np.uint16, mode="r")
print(" ".join(itos[i] for i in ids[:60]))Citation
Generated with data/maze/create_multitask_maze.py (--tasks C1 --path_type RWs, --wrong_ratio 0.2 for 10M, 0.0 for 5M/8M).
