This paper introduces Tiny Recursive Message Passing, a framework that combines the structural inductive bias of Graph Neural Networks (GNNs) with advanced training techniques from recursive transformers. The authors demonstrate that by using deep supervision, truncated recursion, and discrete deduction lattices, they can create extremely parameter-efficient models (as small as 16k parameters) that achieve state-of-the-art performance on complex reasoning tasks and generalize zero-shot to larger problem instances.
TL;DR
By applying training tricks from recursive transformers to message-passing networks, the authors achieve 99% accuracy on Sudoku-Extreme with just 16k parameters. These "tiny" models outperform much larger baselines and generalize zero-shot to larger problem sizes in N-Queens and Boolean Satisfiability.
What Problem Does This Paper Address?
Algorithmic and constraint reasoning tasks—such as solving Sudoku, finding paths in mazes, or satisfying Boolean formulas (SAT)—require deep, iterative computation. Traditionally, there has been a trade-off:
- Symbolic methods are exact and scale well but must be hand-designed.
- Standard GNNs can learn these procedures from data and encode problem structure (e.g., which cells in Sudoku constrain each other), but training them for many iterations is memory-intensive due to Backpropagation Through Time (BPTT).
- Recursive Transformers use "tricks" like truncated gradients to train very deep loops efficiently, but they lack structural bias, requiring millions of parameters to learn simple constraints.
This paper bridges the gap, showing that structural encoding (GNNs) and recursive training machinery are complementary.
Methods
The authors propose a recursive GNN architecture where weights are tied across iterations. The core components include:
- Modular Architecture: Two main types of neural modules are used: a Pooling module (invariant to neighbor order, used for variables) and a Deep Sets module (equivariant, used for constraints).
- Nested Looping: Computation is organized into three levels: an inner loop for message passing, an outer loop that updates a persistent "answer state," and a deep supervision loop for training.
- Truncated Gradients: To handle extremely deep recursions without running out of memory, the model only backpropagates through the last few iterations of the outer loop. The earlier iterations are run "detached" (no gradients stored).
- Adaptive Computation Time (ACT): A small "halting head" learns to predict when the model has reached a solution, allowing it to stop early on easy instances and spend more time on hard ones.
- Discrete Deduction Lattice: At test time, the model can be paired with a lattice that maintains a set of possible values for each variable, making discrete deductions to prune the search space.
Datasets
The models were evaluated on several challenging reasoning benchmarks:
- Sudoku-Extreme: The hardest 9x9 Sudoku puzzles, requiring complex logical deductions.
- Maze-Unique: 30x30 mazes with exactly one shortest path.
- N-Queens: A classic constraint problem. Models were trained on 10x10 boards and tested on sizes up to 16x16.
- Boolean Satisfiability (SAT): Evaluated on G4SATBench (random SR and 3-SAT formulas) and RandCSPBench (4-SAT formulas).
Key Insights and Ideas
- Structure + Recursion = Efficiency: The "aha moment" is that GNNs don't need millions of parameters if they use the right training recipe. A 16k parameter GNN outperforms a 27M parameter transformer because it doesn't have to "learn" the graph structure from scratch.
- The Truncation-Diameter Trade-off: The authors found that the effectiveness of truncated gradients depends heavily on the graph diameter. In "peer graphs" (where nodes are densely connected), information travels quickly, making them robust to truncation. In "factor graphs" (sparser, bipartite structures), information takes longer to propagate, requiring longer gradient windows to train effectively.
- Zero-Shot Scaling: Because the modules are independent of the total number of nodes, the models can be applied to larger problems than they saw during training. For example, a model trained on 10x10 N-Queens can solve 16x16 instances without any fine-tuning.
Key Results
- Sudoku-Extreme: Achieved ~99% accuracy with a 16k parameter model. For comparison, previous transformer-based models required 27M parameters to reach only 55% accuracy on the same benchmark.
- N-Queens Transfer: On 16x16 boards, the proposed model maintained 63% accuracy, while a standard Recurrent Relational Network (RRN) baseline dropped to 26%.
- SAT Solving: The lattice-based model solved over 99% of "Easy" G4SATBench formulas and outperformed specialized neural solvers like NeuroSAT and QuerySAT on harder benchmarks while being significantly smaller.
Limitations and Future Work
- Graph Diameter Sensitivity: The reliance on truncated gradients means the method may struggle with very "long" graphs where information must travel many hops to resolve a constraint.
- Hard SAT Instances: While the model performs well on random SAT formulas, it still lags behind state-of-the-art symbolic solvers on the most difficult "Hard" splits of G4SATBench.
- Future Directions: The authors suggest integrating these tiny recursive models as learned heuristics inside exact symbolic solvers, combining neural intuition with symbolic guarantees.
Summary updated