AMPS
AMPS (Auxiliary Mathematics Problems and Solutions) was released by Dan Hendrycks and collaborators as the pretraining companion to the MATH benchmark. It pairs two very different kinds of content. The first is more than 100,000 problems drawn from Khan Academy, each with a worked, step-by-step solution written in LaTeX, the typesetting language maths is normally published in. The second is over 5 million problems generated programmatically with Mathematica scripts, spanning topics from algebra and geometry to calculus and number theory. Together they come to roughly 23 GB.
You get it from the MATH repository on GitHub (hendrycks/math), where AMPS ships as a downloadable archive of files organised by subject and problem type. There is no API or streaming layer: you clone or download, unpack, and parse the LaTeX and JSON yourself. A practical tip is to keep the LaTeX intact when you chunk, because the notation is the content; stripping it to plain text destroys the maths. Render or tokenise it in a way your embedding model can handle rather than flattening equations into plain ASCII.
AMPS is best when your RAG system needs to retrieve worked examples rather than bare answers: a tutoring assistant that shows its reasoning, a step-by-step solver, or a corpus for grounding a maths model's explanations. The human-written Khan Academy portion gives natural, teaching-style prose, while the Mathematica portion supplies scale and breadth of problem types.
The main caveat is uneven quality between the two halves. Machine-generated problems are consistent but can feel templated and repetitive, and some carry little explanatory text, so a relevance or quality filter helps before indexing. On licensing you are in good shape: AMPS is MIT-licensed, which permits commercial use with no share-alike obligation, so any derivative retrieval index is yours to ship. Alongside quality-scored corpora like AutoMathText or the larger MegaMath, AMPS stands out for its clean, explicitly worked solutions rather than sheer token count.
Related sources
AutoMathText
Around 200 GB of mathematical text compiled from websites, arXiv, and GitHub, drawing on OpenWebMath, RedPajama, and AlgebraicStack. Every piece of content carries a score from 0 to 1 for relevance, quality, and educational value, labelled automatically by the Qwen-72B model.
Awesome AI Math Datasets
A community-curated list of open-source mathematics datasets for training and evaluating maths-capable language models. A useful index for finding newer additions in this space.
Big-Math-RL-Verified
A verified maths bank of 251,122 problems, each filtered to a single checkable answer and tagged with a model solve-rate as an empirical difficulty signal. Built by SynthLabs and released under Apache 2.0.
Bridge (Remediating Math Mistakes)
700 real grade 2 to 8 maths tutoring snippets, each pairing a novice tutor turn with an expert's revised response plus annotated error, strategy and intention. Models expert remediation decisions. Non-commercial (CC BY-NC 4.0).