Key points
- What FunSearch is: A Google DeepMind method that treats hard mathematical and computer-science problems as a search for *functions*. A pre-trained LLM proposes solutions as computer programs, while an automated evaluator verifies correctness and quality — countering the hallucination problem that normally limits LLM use in science.
- How it works (evolutionary search in function space):
- Best-shot prompting: The LLM is fed the best programs found so far as context, encouraging it to improve the most promising ideas rather than starting from scratch.
- Skeleton programs: A basic program framework is provided; the LLM evolves only the critical problem-solving logic (e.g., a heuristic function inside a greedy algorithm loop).
- Island-based evolution: Multiple sub-populations evolve in parallel and periodically share best solutions, maintaining diversity and avoiding local optima.
- Automated evaluation: Each generated function is executed on test cases and scored automatically, enabling rapid iteration over thousands of candidates without human intervention.
- Discovery 1 — Cap set problem (mathematics): The cap set problem asks for the largest subset of points in a high-dimensional grid such that no three points lie on a line — a problem Fields Medalist Terence Tao once called his favorite open question. FunSearch discovered constructions yielding the largest cap sets ever found, the biggest improvement in over 20 years, outperforming both human-made constructions and state-of-the-art computer search, especially at higher dimensions.
- Discovery 2 — Online bin packing (computer science): Items arrive one at a time and must be placed immediately into bins. FunSearch autonomously evolved a new heuristic that packs the same items into significantly fewer bins than the best previously known heuristics, despite not being specifically trained on the task.
- Interpretability as a core advantage: FunSearch outputs human-readable programs rather than black-box solutions. Mathematicians can study the discovered cap set constructions for structural insights; computer scientists can analyze and refine the bin packing heuristic. This creates a collaborative discovery loop between AI and human experts.
- Broader impact and follow-up work: Any problem expressible as searching for a function with measurable outcomes is a candidate for FunSearch-style discovery — including cryptography, optimization, and simulation. DeepMind's AlphaEvolve (2025) builds directly on this approach, using Gemini 2.0 LLMs to evolve entire codebases, improving data-center job scheduling at Google and finding faster matrix multiplication algorithms.
Conclusion
FunSearch demonstrates that LLMs can contribute verified new knowledge to mathematical sciences when their creative generation is paired with rigorous automated evaluation in an evolutionary framework. By breaking a decades-old combinatorial record and surpassing expert-designed algorithms, it established a blueprint for AI-assisted discovery: AI proposes, evaluates, and refines, while humans interpret, verify, and build upon the results — amplifying rather than replacing human ingenuity.