Table of Contents
Fetching ...

MIRROR: A Multi-Agent Framework with Iterative Adaptive Revision and Hierarchical Retrieval for Optimization Modeling in Operations Research

Yifan Shi, Jialong Shi, Jiayi Wang, Ye Fan, Jianyong Sun

TL;DR

MIRROR tackles the accessibility of optimization modeling by turning natural language problem descriptions into executable solver code through a training-free, multi-agent framework. It leverages Hierarchical Retrieval-Augmented Generation (HRAG) to incorporate external exemplars and Iterative Adaptive Revision (IAR) to diagnose and correct errors based on solver feedback, aided by a dual-memory architecture. The approach achieves state-of-the-art performance among multi-agent methods on standard OR benchmarks and shows strong transferability to smaller models without task-specific tuning. These results demonstrate MIRROR’s potential to democratize advanced optimization modeling in domains like logistics and energy scheduling, while maintaining reliability through structured error correction. The combination of external knowledge infusion with execution-driven revision provides a robust pathway for scalable, explainable AI-assisted decision making in operations research.

Abstract

Operations Research (OR) relies on expert-driven modeling-a slow and fragile process ill-suited to novel scenarios. While large language models (LLMs) can automatically translate natural language into optimization models, existing approaches either rely on costly post-training or employ multi-agent frameworks, yet most still lack reliable collaborative error correction and task-specific retrieval, often leading to incorrect outputs. We propose MIRROR, a fine-tuning-free, end-to-end multi-agent framework that directly translates natural language optimization problems into mathematical models and solver code. MIRROR integrates two core mechanisms: (1) execution-driven iterative adaptive revision for automatic error correction, and (2) hierarchical retrieval to fetch relevant modeling and coding exemplars from a carefully curated exemplar library. Experiments show that MIRROR outperforms existing methods on standard OR benchmarks, with notable results on complex industrial datasets such as IndustryOR and Mamo-ComplexLP. By combining precise external knowledge infusion with systematic error correction, MIRROR provides non-expert users with an efficient and reliable OR modeling solution, overcoming the fundamental limitations of general-purpose LLMs in expert optimization tasks.

MIRROR: A Multi-Agent Framework with Iterative Adaptive Revision and Hierarchical Retrieval for Optimization Modeling in Operations Research

TL;DR

MIRROR tackles the accessibility of optimization modeling by turning natural language problem descriptions into executable solver code through a training-free, multi-agent framework. It leverages Hierarchical Retrieval-Augmented Generation (HRAG) to incorporate external exemplars and Iterative Adaptive Revision (IAR) to diagnose and correct errors based on solver feedback, aided by a dual-memory architecture. The approach achieves state-of-the-art performance among multi-agent methods on standard OR benchmarks and shows strong transferability to smaller models without task-specific tuning. These results demonstrate MIRROR’s potential to democratize advanced optimization modeling in domains like logistics and energy scheduling, while maintaining reliability through structured error correction. The combination of external knowledge infusion with execution-driven revision provides a robust pathway for scalable, explainable AI-assisted decision making in operations research.

Abstract

Operations Research (OR) relies on expert-driven modeling-a slow and fragile process ill-suited to novel scenarios. While large language models (LLMs) can automatically translate natural language into optimization models, existing approaches either rely on costly post-training or employ multi-agent frameworks, yet most still lack reliable collaborative error correction and task-specific retrieval, often leading to incorrect outputs. We propose MIRROR, a fine-tuning-free, end-to-end multi-agent framework that directly translates natural language optimization problems into mathematical models and solver code. MIRROR integrates two core mechanisms: (1) execution-driven iterative adaptive revision for automatic error correction, and (2) hierarchical retrieval to fetch relevant modeling and coding exemplars from a carefully curated exemplar library. Experiments show that MIRROR outperforms existing methods on standard OR benchmarks, with notable results on complex industrial datasets such as IndustryOR and Mamo-ComplexLP. By combining precise external knowledge infusion with systematic error correction, MIRROR provides non-expert users with an efficient and reliable OR modeling solution, overcoming the fundamental limitations of general-purpose LLMs in expert optimization tasks.
Paper Structure (46 sections, 2 equations, 3 figures, 3 tables)

This paper contains 46 sections, 2 equations, 3 figures, 3 tables.

Figures (3)

  • Figure 1: MIRROR: An LLM-based multi-agent framework that automates end-to-end optimization modeling—from natural language to executable solver code—through four phases: Understanding, Modeling, Implementation, and Revision. Hierarchical Retrieval-Augmented Generation (HRAG) retrieves relevant exemplars for model and solver code synthesis; upon execution failure, the Iterative Analysis and Revision (IAR) mechanism leverages local memory to diagnose and refine outputs. Local memory stores per-task agent history for revision, while global memory accumulates cross-task knowledge for system-wide evolution.
  • Figure 2: Ablation Study of MIRROR
  • Figure 3: Comparison of optimization modeling methods. (a) Learning-based methods train task-specific models on dedicated datasets but lack execution feedback. (b) Existing agent-based methods employ a closed-loop to iteratively refine the multi-agent system using execution errors. (c) MIRROR combines hierarchical retrieval, which dynamically incorporates exemplar knowledge, with iterative adaptive revision to enable structured error diagnosis and collaborative correction, achieving accurate, robust, and fine-tuning-free optimization modeling.