COMPASS: Benchmarking Constrained Optimization in LLM Agents

Tian Qin, Haoping Bai, Ting-Yao Hu, Raviteja Vemulapalli, Hema Swetha Koppula, Zhiyang Xu, Bowen Jin, Mert Cemri, Jiarui Lu, Zirui Wang, Meng Cao

TL;DR

COMPASS is a new benchmark designed to evaluate how well LLM agents handle constrained optimization—the act of finding the "best" solution (like the cheapest flight) while adhering to strict rules (like a $1,500 budget). The study reveals a significant "feasible–optimal gap": while today’s best models are great at following rules, they struggle to actually find the best possible outcome, often settling for the first "good enough" option they encounter.

What Problem Does This Paper Address?

In the real world, we don't just want an AI agent to find a travel plan; we want the best travel plan. This involves two distinct challenges:

  1. Constraint Satisfaction: Meeting "hard" requirements (e.g., "I must have a direct flight" or "I need a 4-star hotel").
  2. Utility Optimization: Maximizing a "soft" preference (e.g., "Find the absolute cheapest total cost").

Existing benchmarks typically focus on tool-calling accuracy or simple rule-following. They fail to measure whether an agent can strategically explore a large search space to find a mathematically optimal solution. The authors argue that as LLMs move into agentic roles like shopping or scheduling, they must bridge the gap between being merely "feasible" and being truly "optimal."

Methods

The researchers built COMPASS, a framework that simulates a realistic travel planning environment. The core components include:

  • Multi-turn Interaction: Agents must talk to a user to elicit hidden constraints and preferences.
  • User Simulator: An LLM-based simulator with 108 distinct personas (varying in communication style, trust levels, and how quickly they reveal information).
  • Tool Ecosystem: 18 APIs for searching flights, hotels, and permits, plus utility tools like calculators and notebooks.
  • Ground Truth Solver: To evaluate the agents, the authors used exhaustive SQL enumeration to find the mathematically perfect solution for every task, providing a rigorous baseline for "optimality."
Figure 1: COMPASS tests the agent’s ability to perform constrained optimization tasks in realistic settings. (A) Agent needs to learn and update users’ hard constraints and optimization objective by interacting with an LLM-based user simulator. (B) We instantiate constrained optimization problems in travel planning scenarios. To succeed in the task, agents must satisfy hard constraints (e.g., feasibility) while optimizing user utility objective (e.g., optimality). (C) Agents use tools (D) to interact with realistic travel databases (E) to gather information, and propose a travel plan.

Datasets

The benchmark consists of 281 diverse tasks across three levels of complexity:

  • Level I: Single-service (e.g., just booking a hotel).
  • Level II: Multi-service coordination (e.g., aligning flight dates with hotel check-ins).
  • Level III: Complex dependency chains (e.g., securing a high-demand hiking permit that dictates the rest of the trip's timing).

The environment uses real-world data scraped via RapidAPI from Booking.com, covering 20 U.S. National Parks, 100,000+ hotel offers, and 67,000+ flight offers.

Key Insights and Ideas

  • The Feasible-Optimal Gap: This is the paper's most striking finding. Models are quite good at satisfying hard constraints (70–90% success) but fail to find the best option (only 20–60% success). They essentially "satisfice"—finding the first valid option and stopping.
  • Tool Use is Not the Bottleneck: Frontier models (like GPT-5 or Claude 4) have a tool-calling error rate of less than 1%. The failure isn't in how to call the tool, but in what to search for.
  • Search Effort vs. Yield: Success is highly correlated with how much information the agent gathers. Models that make more tool calls and retrieve more "bookable offers" are significantly more likely to reach optimality.
  • Coding Agents as a Solution: Equipping agents with the ability to write and execute Python scripts significantly narrows the gap. Code allows for systematic, structured searching that natural language reasoning struggles to maintain over long horizons.
Figure 2: Main evaluation results. Feasibility Rate (FR) measures feasibility (satisfying all hard constraints). Optimal rate (OR) measures utility objective optimization (achieving utility within the top 5%, 10% among all feasible solutions). All models show a ∼20% gap between high acceptable rates and low optimal rates, revealing that agents settle for feasible solutions rather than optimizing preferences. Coding-agents show a promising approach to resolve this gap. Open-source models achieve non-trivial performance, demonstrating emerging agentic capabilities.

Key Results

  • Performance Degradation: As task complexity increases from Level I to Level III, performance drops sharply, especially for open-source models which struggle with multi-service coordination.
  • Strategic Reasoning: Case studies showed that top-tier models like GPT-5 (simulated) use deliberate heuristics, such as checking mid-week flights to find lower prices, whereas other models search arbitrary dates without justification.
  • Information Gathering: Figure 4 illustrates that stronger models exhibit much higher "Search Effort" (number of tool calls) and "Search Yield" (unique offers found), which directly translates to higher optimality rates.
Figure 4: Information gathering and synthesis abilities determine task success. Left: Split violin plots of Search Effort E and Search Yield Y. Stronger models exhibit higher E and Y. Right: Distribution of tasks by search effort bins for Claude Sonnet 4.6 and it’s code-enabled counterpart, with each bin showing the proportion achieving top-5 optimality.

Limitations and Future Work

  • Domain Specificity: The current benchmark is limited to travel planning. While the authors believe these findings generalize to shopping or scheduling, those domains haven't been tested yet.
  • Ground Truth Scaling: The current evaluation relies on exhaustive search to find the "best" answer. This may not scale to live, open-web environments where the search space is effectively infinite.
  • Strategic vs. Exhaustive Search: The next frontier isn't just searching more, but searching smarter. Future work should focus on agents that can adaptively allocate their "search budget" based on the price distributions they observe.

Summary updated

BibTeX
@inproceedings{qin2026compass,
  author = {Tian Qin and Haoping Bai and Ting-Yao Hu and Raviteja Vemulapalli and Hema Swetha Koppula and Zhiyang Xu and Bowen Jin and Mert Cemri and Jiarui Lu and Zirui Wang and Meng Cao},
  title = {{COMPASS: Benchmarking Constrained Optimization in LLM Agents}},
  booktitle = {COLM},
  year = {2026},
  url = {https://openreview.net/forum?id=r231Adxjfl},
}
Figure