Abstract
Optimization problems are pervasive in sectors from manufacturing anddistribution to healthcare. However, most such problems are still solvedheuristically by hand rather than optimally by state-of-the-art solvers becausethe expertise required to formulate and solve these problems limits thewidespread adoption of optimization tools and techniques. This paper introducesOptiMUS, a Large Language Model (LLM)-based agent designed to formulate andsolve (mixed integer) linear programming problems from their natural languagedescriptions. OptiMUS can develop mathematical models, write and debug solvercode, evaluate the generated solutions, and improve its model and code based onthese evaluations. OptiMUS utilizes a modular structure to process problems,allowing it to handle problems with long descriptions and complex data withoutlong prompts. Experiments demonstrate that OptiMUS outperforms existingstate-of-the-art methods on easy datasets by more than $20\%$ and on harddatasets (including a new dataset, NLP4LP, released with this paper thatfeatures long and complex problems) by more than $30\%$.