Introduction
In the realm of symbolic reasoning—such as solving complex equations or proving mathematical theorems—artificial intelligence agents frequently encounter the "curse of dimensionality." A single problem may require dozens of low-level axiomatic steps, creating an exponentially large search space where billions of incorrect paths exist for every valid solution.
Humans avoid this pitfall by using high-level abstractions. We do not solve $3x + 5 = 11$ by consciously applying the fundamental axioms of real numbers at every step; instead, we utilize "tactics" like "moving terms to the other side" or "simplifying the expression." LEMMA (Learning Mathematical Abstractions) is a novel algorithm designed to bridge this gap by allowing reinforcement learning agents to autonomously discover and name these high-level shortcuts from their own successful solutions.
Methodology: Learning to Chunk Actions
LEMMA builds upon the Expert Iteration (ExIt) framework, where an agent alternates between searching for solutions and training a neural network to mimic successful searches. To this, LEMMA adds a critical third step: Abstraction Learning.
The process involves three main phases:
- Discovery: After solving a batch of problems, LEMMA identifies common patterns in the sequences of actions used. It employs a Bayesian criterion to select new high-level actions that maximize the conciseness and likelihood of the observed solutions.
- Projection Functions: To identify generalizable patterns, the agent uses "projection functions" to filter out irrelevant details. Two types are proposed:
- SeqAbs (Sequential Abstraction): Captures only the sequence of axioms (e.g., "subtract, then simplify").
- RelAbs (Relative Abstraction): Captures both the axioms and their relative positions within the mathematical expression tree (e.g., "apply subtraction to the root, then simplify the right child").
- Bootstrapping: These discovered abstractions are added to the agent's action space. The agent then undergoes a round of imitation learning, re-solving previous problems using these shorter "macro-actions" to prepare for more complex challenges.
Experimental Results
The researchers evaluated LEMMA on two domains from the Common Core mathematical environments: Equation Solving and Fraction Simplification. To test the system's robustness, they introduced "Hard" variants featuring longer equation templates and more complex prime factors, specifically designed to be out of reach for agents limited to step-by-step reasoning.
The results demonstrate that LEMMA significantly outperforms the base RL agent (ConPoLe) across all domains. Notably, on the equations-hard task, the success rate of the vanilla agent plummeted to 45.5%, while the LEMMA-augmented agent (RelAbs) maintained a success rate of 60% without additional training on the harder distribution. This indicates superior zero-shot generalization.
Discussion and Key Insights
A central finding of the paper is that problem difficulty is relative to the available action space. By inventing more powerful actions, "hard" problems effectively become "easy."
The success of the RelAbs method highlights that mathematical reasoning is deeply tied to structural information. Tracking where an action occurs in an expression tree is more effective than simply tracking the sequence of operations. Furthermore, the abstractions LEMMA discovers are often highly interpretable, effectively "rediscovering" standard algebraic moves like dividing both sides of an equation by a constant.
Conclusion and Future Work
LEMMA provides a path toward AI that can autonomously build its own libraries of mathematical strategies, similar to the "tactics" used in formal proof assistants like Lean or Coq.
However, limitations remain. The current projection functions are specific to symbolic expression trees, and the discovered abstractions are currently limited to linear sequences rather than complex logic involving loops or conditionals. Future research will focus on scaling these "abstraction mining" techniques to industrial-grade theorem provers and more diverse reasoning domains.
Summary updated