Guiding Large Language Models in Modeling Optimization Problems via Question Partitioning

Abstract

Optimization problems are ubiquitous across various domains, such as resource scheduling, production planning, and sales management. Traditionally, they are modeled manually, leading to inefficiencies due to difficulties in communication and collaboration between modeling and domain experts. The emergence of Large Language Models (LLMs) has made automated modeling possible. However, real-world applications are often large-scale and have numerous variables and constraints, limiting the applicability of existing methods. To address this, we propose PaMOP, a novel modeling framework based on LLMs, to model optimization problems automatically, given only natural language descriptions. Specifically, we extract and partition the problems using a tree structure, guiding the LLMs to model each set of constraints with self-augmented prompts, thus reducing the demands on the LLM's capabilities of large contents. The mathematical model is then iteratively corrected and validated through our correction procedures. The experiments demonstrate that our method improves performance on the common benchmark dataset NLP4LP, achieving an accuracy of 62.3% and a code executability rate of 86.8% when tested on GPT-4. Additionally, we demonstrate the effectiveness of our PaMOP in handling large real-world problems.

Cite

Text

Pan et al. "Guiding Large Language Models in Modeling Optimization Problems via Question Partitioning." International Joint Conference on Artificial Intelligence, 2025. doi:10.24963/IJCAI.2025/296

Markdown

[Pan et al. "Guiding Large Language Models in Modeling Optimization Problems via Question Partitioning." International Joint Conference on Artificial Intelligence, 2025.](https://mlanthology.org/ijcai/2025/pan2025ijcai-guiding/) doi:10.24963/IJCAI.2025/296

BibTeX

@inproceedings{pan2025ijcai-guiding,
  title     = {{Guiding Large Language Models in Modeling Optimization Problems via Question Partitioning}},
  author    = {Pan, Xiaotian and Fang, Junhao and Wu, Feng and Zhang, Sijia and Hu, Yixiang and Li, Shaoang and Li, Xiangyang},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year      = {2025},
  pages     = {2657-2665},
  doi       = {10.24963/IJCAI.2025/296},
  url       = {https://mlanthology.org/ijcai/2025/pan2025ijcai-guiding/}
}