Abstract: Can a machine learn Machine Learning? This work trains a machine learning model to solve machine learning problems from a University undergraduate level course. We generate a new training set of questions and answers, and develop a novel architecture that combines Transformers with Graph Neural Networks and expression tree decoders. Our system achieves up to 97% accuracy on MIT course materials, significantly outperforming both human students and general-purpose models like GPT-3.
Introduction
While Large Language Models (LLMs) have demonstrated remarkable proficiency in reading comprehension and general text generation, they frequently struggle with multi-step mathematical reasoning, particularly in STEM subjects like Linear Algebra and Calculus. This research addresses the "meta" challenge: can a machine be trained to solve the very problems used to teach machine learning to humans?
Specifically, the study focuses on the curriculum of MIT’s 6.036 Introduction to Machine Learning. These problems require more than just rote memorization; they necessitate extracting numerical values from text, understanding complex relationships (such as weights and offsets in a neural network), and applying precise mathematical operations to derive a solution.
Methodology
To move beyond the limitations of simple text-to-text generation, which is prone to numerical "hallucination," the authors proposed a structured representation for mathematical problems. The architecture is built upon three primary pillars:
- Hybrid Encoding: The system utilizes a Transformer to create a text embedding of the question while simultaneously building a Graph Representation. In this graph, nodes represent words and numerical values, while edges represent the logical relationships between them.
- Graph Neural Network (GNN): These embeddings are processed by a GNN to create a latent vector that captures the underlying logic of the problem.
- Expression Tree Decoder: Instead of predicting a final scalar value directly, the model predicts an expression tree. This tree represents the mathematical formula (using operators like
+,-,log,exp) required to solve the problem. The system then evaluates this tree to produce the final answer.
To address the challenge of limited data, the researchers employed a massive data-augmentation scheme. By using paraphrasing and value-plugging, they expanded 140 base questions into a robust training set of 14,000 examples.
Experimental Setup
The study utilized a curated dataset derived from the Fall 2020 iteration of MIT 6.036, spanning 12 core topics including Perceptrons, Logistic Regression, CNNs, MDPs, and Reinforcement Learning. The evaluation excluded questions requiring visual input (diagrams) or programming tasks, focusing purely on the mathematical and conceptual reasoning components.
Results and Discussion
The system demonstrated "super-human" performance, achieving an overall accuracy of 96% on open-response questions and 97% on multiple-choice questions. For comparison, the average MIT student score for the same course is approximately 93%. Notably, the model provides these solutions in milliseconds, whereas a human student might require several minutes for complex backpropagation problems.
Key insights from the evaluation include:
- The Failure of General LLMs: GPT-3, a state-of-the-art model at the time of the study, achieved only 7% accuracy. This highlights that while LLMs can discuss machine learning concepts, they lack the intrinsic ability to perform the underlying linear algebra or calculus.
- Structural Importance: Ablation studies revealed that the GNN was vital for success. Removing graph-based reasoning caused accuracy to drop from 94% to 83%, proving that understanding the structural relationships within a math problem is as critical as understanding the natural language.
- Explainability and Tutoring: Because the model generates expression trees, it can serve as a "Meta Tutor." By traversing the tree, the system can generate hints or partial solutions to assist students without revealing the final answer.
Conclusion and Future Work
While the system achieves high proficiency, it currently faces two main limitations: it cannot process visual diagrams directly and cannot yet generate the Python code required for many ML assignments. Future research aims to expand this framework into a multi-modal tutor capable of handling visual inputs and solving a broader range of discrete mathematics problems across computer science curricula.
Summary updated