Tiny Cube Solver
A small model that learned to solve the Rubik's Cube from nothing. It never saw a solution. It learned by working outward from the solved cube, one move at a time.
Each solve below was recorded on a rented GPU, on the same numbered cubes that every language model on RubiksBench faced.
Outlined numbers are solved cubes. Grey numbers are cubes it gave up on.
- Cube
- 1 of 25
- Result
- Solved
- Answer
- 19 moves
- Time
- 73.2s
- Positions scored
- 223,811
- Scramble
- Solve
- GPT-6 Astra (xhigh): solved in 85 moves
- GPT-5.6 Sol (xhigh): wrong answer
- GPT-6 Sol (max): no answer
The model does not write moves. It looks at one cube and guesses how many moves it is from solved. A plain search does the rest:
- Try all 18 moves from every position it is keeping.
- Ask the model to score each new position.
- Keep the best 1,024.
- Repeat until one of them is the solved cube.
Our code applies every move and checks the answer. The model only decides which positions are worth keeping. On a full scramble that means scoring hundreds of thousands of positions per cube.
25 cubes at each scramble length. It solves 75 of 75 cubes up to 10 moves, and 142 of 150 full scrambles.
| Scramble | Cubes | Solved | Moves | Shortest known | Time |
|---|---|---|---|---|---|
| 3 moves | 25/25 | 3.0 | 3.0 | 0.1s | |
| 6 moves | 25/25 | 6.0 | 6.0 | 10.6s | |
| 10 moves | 25/25 | 10.0 | 10.0 | 29.7s | |
| 15 moves | 25/25 | 20.4 | 15.0 | 80.0s | |
| 20 moves | 24/25 | 22.0 | 20.0 | 89.2s | |
| 25 moves | 24/25 | 21.9 | 21.8 | 88.4s | |
| 30 moves | 25/25 | 21.6 | 21.7 | 85.7s | |
| 40 moves | 23/25 | 23.0 | 21.9 | 94.4s | |
| 50 moves | 23/25 | 21.9 | 21.6 | 89.6s | |
| 100 moves | 23/25 | 21.5 | 21.7 | 87.7s |
solvedgave up (the search found no path)
Moves is the average length of the answers that solved. Shortest known is, for the same cubes, the shorter of the scramble played backwards and a standard solving program's answer. Up to 10 moves the model matches it exactly. At 15 moves it is about 5 moves longer, its weakest length. On full scrambles it is within about a move, and often shorter than the standard program. Time is per cube, on RTX A6000. Every cube can be solved in 20 moves or fewer, so 25, 50 or 100 moves are no harder than 20.
The same 10 cubes, next to the best results on RubiksBench. This is not the same test. A language model gets one reply and must write every move in it, with no tools. The small model gets a search loop that checks thousands of positions. The comparison shows what a purpose-built model at a tiny fraction of the size can do, not a head-to-head score.
| Model | Cubes 1–10 | Solved | Moves |
|---|---|---|---|
| Tiny Cube Solver | 10/10 | 20.7 | |
| GPT-6 Astraxhigh | 9/10 | 107.4 | |
| GPT-5.6 Solxhigh | 2/10 | 126.0 | |
| GPT-6 Solmax | 2/10 | 81.0 | |
| Claude Opus 5.5low | 1/10 | 110.0 |
solvedwrong answerno answer (thought until its budget ran out)
Moves is the average length of the answers that solved. Language model results from RubiksBench, 2026-09-24.
Three designs, in order, with the share of full scrambles each one solved. Only the last one works.
- 1 · 0%
- Write the moves. The model read the cube and wrote the whole answer, like a language model. It stopped working about 8 moves from solved. More layers, more width and training on its own mistakes all failed to move that limit.
- 2 · 16%
- Guess the distance, learn from a solver. A search, guided by a distance guess trained on a standard solver's answers. That solver finds good answers, not the shortest, and it labelled almost half of all random cubes "21". Above 15 moves there was nothing left to learn from.
- 3 · 95%
- Guess the distance, learn from itself. Same model, same search, new training answers. It starts from one free fact: the solved cube is 0 moves from solved. A cube one move away is 1, because one of its neighbours is the solved cube. Each round of training pushes correct answers one move further out.
The second and third designs are the same network with the same search. Only the training answers changed.
The model and a one-file solver are on Hugging Face: briscoooe/tiny-cube-solver.
pip install torch transformers safetensors huggingface_hub
python solve.py --scramble "R U F' D2 L B'"A laptop without a GPU handles short scrambles in seconds to a minute. Full scrambles need a GPU.
- Speed
- A standard solving program finds a full solution in milliseconds on any computer. This model is far slower. It exists to show that a small network can learn the task at all.
- Shortest
- Answers are not guaranteed to be the shortest. Full scrambles can be solved in 20 moves or fewer.
- Size
- The standard 3×3×3 cube only.
- Measured
- 2026-09-24, on RTX A6000.