# Agent-written heuristics versus commercial solvers on unsolved job-shop benchmark instances

Agent-written job shop solver beats commercial solvers at equal budgets

Andre Albrecht, Enzo Morosini Frazzon, Leandro C. Coelho, Bruno Vieira · arXiv · 2026-11-13

- **Problem** Commercial solvers are the standard for hard scheduling, but they need paid licenses and open-source solvers often fall behind on large instances. The open-source CP-SAT solver is often weaker on large scheduling instances.
- **Method** The corridor solver is written by a coding agent, Claude Code, which restricts each operation to a corridor of start times and fixes a makespan target T. A min-conflicts search then removes the remaining machine conflicts.
- **Results** On the 100,000-operation tai\_100\_1000\_1 instance, the agent-written solver reached 525,515, below OptalCP, Hexaly and CP Optimizer. With one core and 30 minutes, it ended 0.0-1.8% above the lower bound, against 2.6-5.8% for CP Optimizer.

## Where commercial solvers fall short on large open instances

Commercial solvers such as Hexaly, CP Optimizer and OptalCP perform very well and need little problem-specific work. Their use requires a paid license, and the open-source CP-SAT solver is often weaker on large scheduling instances. The job shop tai\_100\_1000\_1 has 100 jobs, 1,000 machines and 100,000 operations. Its lower bound is 522,298, and its upper bound of 533,080 is still open.

Scheduling suits this test, because a candidate schedule is cheap to check even when a good one is hard to find. That property lets an independent checker verify each schedule the agent produces. The agent is Claude Code, a command-line coding agent that writes, compiles and runs code in a loop.

Earlier LLM work on scheduling mostly checked whether generated models were correct, or compared against simple baselines on small instances. This study differs in three ways, and the first is that the agent writes a complete solution method. The second difference is that the targets are large open instances, and the third is a general coding environment.

## Why the agent changed the formulation on tai\_100\_1000\_1

The first solvers minimized the makespan directly, starting from a greedy schedule of 593,321 and stalling at 592,865. At minute 42, the agent stopped optimizing the makespan and fixed a target T, searching instead for a schedule with no machine conflict and Cmax ≤ T.

To make this search tractable, the agent confined each operation o of job j to a corridor of start times. The corridor is pref\_j(o) ≤ s\_j,o ≤ pref\_j(o) + (T − L\_j), where L\_j is the length of job j and pref\_j(o) is the start of operation o when the job runs without idle time. Inside these corridors, Cmax can't exceed T, but corridors alone don't keep the operations of a job in order.

Two consecutive operations may overlap while each lies inside its own corridor, so the initial schedules let the delay grow along each job. Every move also shifts the successors or predecessors of an operation on its job, and it rejects a shift that leaves a corridor or moves more than 60 operations.

A min-conflicts search with random perturbations then removes the remaining machine conflicts, so only machine conflicts stay in the search. Each feasible schedule lets the agent lower T by 1,000, and the first corridor prototype, started at T = 545,000, found 540,999 after about 60s. The agent then wrote a faster C version and ran 28 worker processes on the 4 CPUs of the container.

A csp3 worker found 527,000 at about minute 77, and Figure 3 shows the best makespan over time for the twelve single-core workers of the corridor solver.

![Figure 3: Best makespan ontai\_100\_1000\_1over time](https://refivu.com/papers/5984dfe9-586c-4235-a5c3-6bd1f931e1af/figures/figure-518aaa9dc433eeca488b1e500862634c.png?thumb=512)

**Figure 3** .Best makespan ontai\_100\_1000\_1over time

[Original paper](https://arxiv.org/abs/2611.17682v1) · [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) · Andre Albrecht, Enzo Morosini Frazzon, Leandro C. Coelho, Bruno Vieira · Agent-written heuristics versus commercial solvers on unsolved job-shop benchmark instances · Original paper figure · Extracted the figure area from page 9 of the original PDF.

## Job shop results against commercial solvers

The question is whether the corridor solver beats commercial solvers at equal budgets across the 100,000-operation job shop family. The authors ran the corridor solver on all ten tai\_100\_1000 instances, with three seeds per instance, one core and 1,800s per run. They compared it with CP Optimizer 22.2 and Hexaly 15.0 at 10 and 30 minutes on one core, and at 16 cores.

On tai\_100\_1000\_1, the agent-written solver reached 525,515, which is below the values of OptalCP, Hexaly and CP Optimizer. With one core and 30 minutes, CP Optimizer 22.2 ended 3.7–5.8% above the lower bound, and Hexaly 15.0 ended 2.7–4.4% above it.

With 16 cores, the agent solver's mean gap was 0.53%, against 3.79% for CP Optimizer and 3.30% for Hexaly. The solver reached the lower bound on tai\_100\_1000\_2 and tai\_100\_1000\_3, because its schedules equal the longest job's length. A second block of sixteen 1,800s runs, with two processes per core, improved five instances but closed none.

The same runs improved seven instances further, so the agent solver's advantage held at this larger budget too.

## Reusable tabu search on the Behnke instances

The authors ran a reusable tabu search, written in an assisted session, unchanged on all 60 Behnke instances. Behnke and Geiger published 60 instances, and FJSPLib lists 32 of them as open and 28 as closed. Over both blocks of runs, the tabu search improved the best-known upper bound on 11 of the 32 open instances.

On average it finished 0.60% above the best-known upper bound, compared to 1.42% for CP Optimizer, 2.85% for Hexaly and 6.42% for CP-SAT. With 1,200s on the open instances, the tabu search averaged 0.24% above the bound, compared to 0.79% for CP Optimizer with all 16 cores. Two blocks ran at different core counts, so the tabu search had about 8 cores while CP Optimizer had 16.

## Transport robots on the MKT instances

The assisted session used MKT10 as the main development instance, because it is the largest MKT instance. All of the replayed schedules reproduced the published makespans exactly, which confirmed that the model and data match the literature.

The transport solver improved seven of the ten MKT instances, against all valid published values. Four published MKT values are excluded, because they fall below a new lower bound on the distributed instance files. On the Chambers–Barnes instances, the CP Optimizer approach is better than the agent-written solver.

The open-source baseline is CP-SAT on a complete constraint model with optional intervals and a multiple-circuit constraint. The agent solver ran 20 minutes with one thread per run, and it used 1,200 thread-seconds against 4,800 for CP-SAT. Even with a quarter of the CPU time, CP-SAT ended 6–112% above the median of the agent solver.

The same transport solver was run without change on the small and medium two-vehicle sets. On MFJST09 the solver found 1,090, against the 1,075 of Meng et al. (2025), which equals relaxation (3) and is therefore optimal. The authors didn't tune the solver for these instances, because the goal was to test the unchanged method.

## A solver costs less per schedule than an agent session

In mode A, the agent is the algorithm, so every new schedule needs a new agent session. For tai\_100\_1000\_1, such a session cost US$2.43–22.69 and took 18–300 minutes. The results vary considerably, from 527,000 to 554,332.

The authors recompiled the transport solver from its source with the same seed, and it reproduced the MKT10 schedule exactly. The reusable solvers also apply to similar instances without change, and the transport solver found every optimum on the small transport instances.

The authors argue that the two modes work best together, because an agent session finds a method and a short assisted session turns it into a solver. Mode C then asked whether an agent could continue without human input, starting from the outputs of modes A and B.

## Limitations and what remains open

Run-to-run variation is large, so a single agent session can't stand in for the typical result on tai\_100\_1000\_1. Six Claude Opus 5 sessions ended between 527,000 and 533,386, with a median of 531,403. Nine Claude Sonnet 5 sessions that delivered a schedule ended between 535,930 and 554,332, with a median of 541,641. Because the provider doesn't expose sampling seeds, a session can't be replayed exactly.

The authors report the run-to-run spread for the solvers they wrote separately, since those solvers are re-run with explicit seeds.

All models come from one provider, Anthropic, and the study tested only Claude Opus and Claude Sonnet. Claude Fable was used in one campaign of mode C only. The authors say that controlled comparisons across models and problem classes are still needed. On the Chambers–Barnes transport instances, the CP Optimizer approach of Meng et al. (2025) is better than the agent-written solver.

The authors attribute this to the transport solver being tailored to the vehicles, which doesn't transfer to instances where the machines are the bottleneck.

All instances are literature benchmarks, and their generators can give them regular structure that the agents exploited. Models or parameters tuned by an expert may yield better results for these instances.

MKT10 was the main development instance, which may favor the transport solver on it. The agents didn't raise any lower bound on the job-shop or Behnke instances. The open instances tai\_100\_1000\_1 and behnke16 remain open after the study.

## Paper info

- **Authors**: Andre Albrecht, Enzo Morosini Frazzon, Leandro C. Coelho, Bruno Vieira
- **Venue**: arXiv · Preprint
- **First published**: 2026-11-13
- **Added**: 2026-11-16
- **Updated**: 2026-11-13
- **Version**: v1
- **arXiv**: 2611.17682
- **Category**: math.OC · cs.AI
- **Original paper terms**: [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/)
- **What we show**: Paper info, commentary and permitted figures from the original paper

[Original paper ↗](https://arxiv.org/abs/2611.17682v1) · [PDF ↗](https://arxiv.org/pdf/2611.17682v1)

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

## Abstract

Commercial solvers are the standard tool for difficult scheduling problems. We study whether a frontier large language model, used as a coding agent with open-source tools only, can match them in quality and speed. We report every run, and independent checkers verify every schedule. On the 100,000-operation job shop tai\_100\_1000\_1, an agent-written solver reached 525,515, below OptalCP, Hexaly, and CP Optimizer. Unchanged, it improved all ten instances of the family and closed two. With equal budgets on the same workstation, it ended 0.0-1.8% above the lower bound, against 2.6-5.8% for CP Optimizer and 2.4-4.4% for Hexaly. On the Behnke-Geiger flexible job shops, an agent-written tabu search improved 11 of 32 open instances. With two transport robots, an agent-written solver improved seven of ten MKT instances. New lower bounds show that four published MKT values cannot be attained on the distributed instance files. Agent-run improvement campaigns closed eight further instances.

## Quote from the paper

Andre Albrecht, Enzo Morosini Frazzon, Leandro C. Coelho, Bruno Vieira (2026). Agent-written heuristics versus commercial solvers on unsolved job-shop benchmark instances. arXiv:2611.17682v1. https://arxiv.org/abs/2611.17682v1

**BibTeX**

```
@misc{albrecht2026agent,
  title = {{Agent-written heuristics versus commercial solvers on unsolved job-shop benchmark instances}},
  author = {Andre Albrecht and Enzo Morosini Frazzon and Leandro C. Coelho and Bruno Vieira},
  year = {2026},
  eprint = {2611.17682},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.17682v1}
}
```

## Other paper commentary

- [Verifiable pXRD: Hill-climbing pXRD structure determination with LLM agents](https://refivu.com/en/papers/ac0271e9-392b-4197-8fd2-7a94703b5c28-verifiable-pxrd-hill-climbing-pxrd-structure-determination.md)
- [AgentSSL: Can MLE Agents Leverage Unlabeled Data?](https://refivu.com/en/papers/7ba356fa-3652-4ea1-a299-cdcb8ac47ade-agentssl-can-mle-agents-leverage-unlabeled-data.md)
- [Reducing Batch Makespan for LLM Agent Workloads through Inference-Environment Coordination](https://refivu.com/en/papers/4f221a0a-61bb-41b5-956d-57bddb732211-reducing-batch-makespan-for-llm-agent-workloads-through.md)
- [Eliciting and Mitigating Specification Satisficing in Coding Agents](https://refivu.com/en/papers/cfe84310-98d7-4917-8b3c-5b23d97305e8-eliciting-and-mitigating-specification-satisficing-in-coding.md)
- [Look Here, Then Decide: Small Decision Models in a Harness Find Memory-Safety Vulnerabilities at Scale on Commodity GPUs](https://refivu.com/en/papers/a4086ec5-33eb-4e68-bbd9-18476c04be04-look-here-then-decide-small-decision-models-in.md)
- [How Should Planning Agents ReSHAPE Their Search Space?](https://refivu.com/en/papers/9fffaa2e-ec66-4527-8bbc-c761e38be1cc-how-should-planning-agents-reshape-their-search-space.md)
- [Continuous Cuffless Blood Pressure Estimation Using PPG From Methods to Clinical Translation](https://refivu.com/en/papers/180bf06e-b537-4a2e-ae36-d6f387368854-continuous-cuffless-blood-pressure-estimation-using-ppg-from.md)
- [GraphScent: Calibrating Directional Relevance Signals for Bounded-Context Code Localization](https://refivu.com/en/papers/f485b130-6849-48e3-832f-e8d259afa756-graphscent-calibrating-directional-relevance-signals-for.md)
- [Racing the Clock: Teaching VLNs Budget-Conditioned Object Search](https://refivu.com/en/papers/992ab776-37be-4bb3-8f02-ac11228a0178-racing-the-clock-teaching-vlns-budget-conditioned-object.md)
- [Classification with Large-Step Gradient Descent: Unifying Self-Stabilization and Convergence Rates](https://refivu.com/en/papers/ba201378-eebf-47b4-b223-b9daff3608d3-classification-with-large-step-gradient-descent-unifying.md)
- [Superfluid: Local AI Server for Distributed LLM Inference](https://refivu.com/en/papers/8e6a37d1-98da-443c-a248-1340a46ef81c-superfluid-local-ai-server-for-distributed-llm-inference.md)
- [ParseBench-2: Severity-Aware Evaluation of Document Parsing](https://refivu.com/en/papers/6a634f4a-4067-4371-aad1-d4d152a8567d-parsebench-2-severity-aware-evaluation-of-document-parsing.md)

## Terms in this paper

- [Claude Code](https://refivu.com/en/terms/140ee6d8eb01-claude-code)
- [Claude Opus 5](https://refivu.com/en/terms/d6b418546d02-claude-opus-5)
- [corridor](https://refivu.com/en/terms/802c89bc5bc6-corridor)

---

AI-written text can contain mistakes. [Refivu](https://refivu.com/en/papers/5984dfe9-586c-4235-a5c3-6bd1f931e1af-agent-written-heuristics-versus-commercial-solvers-on)
