EquivaMap: Leveraging LLMs for Automatic Equivalence Checking of Optimization Formulations
Haotian Zhai, Connor Lawless, Ellen Vitercik, Liu Leqi
Abstract
A fundamental problem in combinatorial optimization is identifying equivalent formulations. Despite the growing need for automated equivalence checks---driven, for example, by *optimization copilots*, which generate problem formulations from natural language descriptions---current approaches rely on simple heuristics that fail to reliably check formulation equivalence. Inspired by Karp reductions, in this work we introduce *Quasi-Karp equivalence*, a formal criterion for determining when two optimization formulations are equivalent based on the existence of a mapping between their decision variables. We propose *EquivaMap*, a framework that leverages large language models to automatically discover such mappings for scalable, reliable equivalence checking, with a verification stage that ensures mapped solutions preserve feasibility and optimality without additional solver calls. To evaluate our approach, we construct *EquivaFormulation*, the first open-source dataset of equivalent optimization formulations, generated by applying transformations such as adding slack variables or valid inequalities to existing formulations. Empirically, *EquivaMap* significantly outperforms existing methods, achieving substantial improvements in correctly identifying formulation equivalence.
BibTeX
@inproceedings{
zhai2025equivamap,
title={EquivaMap: Leveraging {LLM}s for Automatic Equivalence Checking of Optimization Formulations},
author={Haotian Zhai and Connor Lawless and Ellen Vitercik and Liu Leqi},
booktitle={Forty-second International Conference on Machine Learning},
year={2025},
url={https://openreview.net/forum?id=jaCD2nEpyr}
}