# Coding agent writes scheduling solvers that beat commercial tools on benchmarks

A preprint reports that Claude Code, using only free software, wrote factory-scheduling programs. On the same computer, these came closer to the best possible result than the paid solvers CP Optimizer and Hexaly. The advantage held on large, regular test problems, but not on every problem type.

- Category: Agents
- Readiness level: III (Open source) on Science Underway's four-step scale, as proposed
- Published: 2026-11-16
- Editor: Stefan Perdal
- URL: https://scienceunderway.com/articles/coding-agent-writes-scheduling-solvers-that-beat-commercial-tools-on-benchmarks

## The study

Agent-written heuristics versus commercial solvers on unsolved job-shop benchmark instances (preprint, not peer reviewed). arXiv 2611.17682. https://arxiv.org/abs/2611.17682

## At a glance

- What it shows: An AI coding assistant, given only free software, wrote programs that plan factory work. On large public test problems, its plans finished all work sooner than plans from two paid commercial tools. These tools were run on the same computer for the same time.
- What it does not show: It does not show that this works on real factory data, or against commercial tools set up by an expert. Only one AI provider's models were tested.
- Why it matters: Commercial scheduling software needs a paid licence. Here, one AI session costing about US$10 produced a program that can be rerun for the cost of computer time alone.

## What the study shows

Researchers in Brazil and Canada tested whether an AI coding agent can stand in for a commercial optimisation solver. A solver is software that searches for the best plan under constraints. The agent was Claude Code, a command-line tool that writes, runs and revises its own programs. It had no access to commercial solvers. The work is a preprint and has not been peer reviewed.

The test problems are job shops: jobs must pass through machines in a set order, and one machine handles one job at a time. The goal is the shortest makespan, the time until the last job finishes. Each problem also has a lower bound, a proven floor that no schedule can beat. A separate checker, sharing no code with the agent, verified every schedule. The authors say they report every run, including failures.

The largest problem has 100 jobs, 1,000 machines and 100,000 operations. After 42 minutes of a session, the agent changed its approach. It fixed a target finish time and gave each operation a time window that guaranteed that target. It then removed machine clashes one by one. With 30 minutes on 16 cores, the resulting program ended about 0.6% above the floor. On the same machine and budget, CP Optimizer ended about 4% above and Hexaly about 3.3% above.

The same program, unchanged, was run on nine sister problems of the same size. It beat the previous best-known result on all ten and reached the floor on two, which proves those schedules optimal. A later 24-hour campaign, run by the agent itself, brought this to four of ten.

On a second family, flexible job shops where each step can use one of several machines, an agent-written search program improved the best-known result on 11 of 32 unsolved problems. A third family adds two transport robots that carry jobs between machines. Here the agent's program beat all valid published results on 7 of 10 problems. On a different set of 21 transport problems, where machine time matters more than travel, a published approach based on CP Optimizer did better on 20.

Results varied a lot between sessions. On the largest job shop, single sessions ended anywhere from about 1% to about 6% above the floor. The session that wrote the best program took 101.6 minutes and cost US$10.07 in usage charges.

## Our reading

In our reading, the main lesson is about specialisation, not raw intelligence. Commercial solvers must work on any problem a customer brings. The agent only had to work on one. On the big job shop, it noticed that machines sat idle about 90% of the time while jobs were almost always busy. It built a method around that fact. The authors say this specialisation appears to be the main source of the advantage, and the results support that view.

The most useful output is a program, not a schedule. When the agent itself produced schedules, quality swung widely from session to session. When it wrote a reusable solver, results became repeatable with fixed random seeds, auditable as source code, and cheap to rerun. A plant that schedules the same kind of line every day could have an agent write a solver once, then run it nightly at the cost of computer time.

The loss on the 21 machine-heavy transport problems matters as much as the wins. A solver tuned to robot routing could not shorten schedules where machines were the bottleneck. Tailored code is strong on the structure it was built for and can be weak elsewhere. Anyone using this approach needs to test it on problems that look like their real ones.

The rest of the article (what it means, limits, what to watch) is free for members: https://scienceunderway.com/articles/coding-agent-writes-scheduling-solvers-that-beat-commercial-tools-on-benchmarks

## How this was made

An AI model read the study and wrote this article in the structure Science Underway uses. An editor reviewed it and approved it for publication. Check the original study before you rely on the details.

---
Source: Science Underway, https://scienceunderway.com/. Please link to the article when you cite it.
