Table of Contents
Fetching ...

Abstract Operations Research Modeling Using Natural Language Inputs

Junxuan Li, Ryan Wickman, Sahil Bhatnagar, Raj Kumar Maity, Arko Mukherjee

TL;DR

This paper introduces NL2OR, an end-to-end pipeline that converts natural language queries into abstract OR models and then into concrete models solvable by OR solvers, enabling what-if analysis for non-experts. It leverages large language models to generate DSLs, performs automated post-processing with error handling, and uses a FORA-based execution framework with solver triage to deliver solutions and reports. Compared to existing AMP approaches, NL2OR emphasizes abstract modeling, solver-agnostic triage, and an interactive multi-turn NL interface, achieving high accuracy across diverse problem sets and datasets such as LPWP. The experimental results show that NL2OR can create and edit OR models effectively, with GPT-4o often delivering the best accuracy and acceptable latency, suggesting practical impact for non-technical users and industrial deployments. The work highlights future directions including more compact language models and reinforcement learning to further improve efficiency and adaptability in real-world settings.

Abstract

Operations research (OR) uses mathematical models to enhance decision-making, but developing these models requires expert knowledge and can be time-consuming. Automated mathematical programming (AMP) has emerged to simplify this process, but existing systems have limitations. This paper introduces a novel methodology that uses recent advances in Large Language Model (LLM) to create and edit OR solutions from non-expert user queries expressed using Natural Language. This reduces the need for domain expertise and the time to formulate a problem. The paper presents an end-to-end pipeline, named NL2OR, that generates solutions to OR problems from natural language input, and shares experimental results on several important OR problems.

Abstract Operations Research Modeling Using Natural Language Inputs

TL;DR

This paper introduces NL2OR, an end-to-end pipeline that converts natural language queries into abstract OR models and then into concrete models solvable by OR solvers, enabling what-if analysis for non-experts. It leverages large language models to generate DSLs, performs automated post-processing with error handling, and uses a FORA-based execution framework with solver triage to deliver solutions and reports. Compared to existing AMP approaches, NL2OR emphasizes abstract modeling, solver-agnostic triage, and an interactive multi-turn NL interface, achieving high accuracy across diverse problem sets and datasets such as LPWP. The experimental results show that NL2OR can create and edit OR models effectively, with GPT-4o often delivering the best accuracy and acceptable latency, suggesting practical impact for non-technical users and industrial deployments. The work highlights future directions including more compact language models and reinforcement learning to further improve efficiency and adaptability in real-world settings.

Abstract

Operations research (OR) uses mathematical models to enhance decision-making, but developing these models requires expert knowledge and can be time-consuming. Automated mathematical programming (AMP) has emerged to simplify this process, but existing systems have limitations. This paper introduces a novel methodology that uses recent advances in Large Language Model (LLM) to create and edit OR solutions from non-expert user queries expressed using Natural Language. This reduces the need for domain expertise and the time to formulate a problem. The paper presents an end-to-end pipeline, named NL2OR, that generates solutions to OR problems from natural language input, and shares experimental results on several important OR problems.
Paper Structure (18 sections, 1 equation, 9 figures, 5 tables)

This paper contains 18 sections, 1 equation, 9 figures, 5 tables.

Figures (9)

  • Figure 1: Overview of the NL2OR architecture. There are 4 major blocks in the methodology depicted in the figure. Each performs one important task. 1) With user query as input, the system first decides to create if this is a new problem or edit if it is an old problem to be updated. Then natural language input is transformed to DSL (domain specific language) which is built using prompt engineering and processed to check for error. 2) In the next step, we take the DSL and then convert it into an executable form which we call an abstract model. 3) Then with the user provided data we instantiate the concrete model and solve the problem. 4) Then, with the user query, the variable information and solution the system designs a prompt that generates a database where the solution of the problem is stored, and report is generated.
  • Figure 2: An overview of the LLM prompt for model creation.
  • Figure 3: Created OR model YAML for the food purchasing planning optimization problem.
  • Figure 4: An overview of the LLM prompt for model edition.
  • Figure 5: Edited OR model YAML for the food purchasing planning optimization problem.
  • ...and 4 more figures