How Good Are Coding Agents at Automatic Algorithm Design?

Haoze Lv, Shaofeng Zhang, Shengcai Liu, Ke TangarXiv 2026

TL;DR

General-purpose AI coding agents can now step into a complex solver repository, run tests, and autonomously optimize discrete optimization algorithms—often matching or beating specialized evolutionary LLM workflows and even improving champion-level human code. However, when asked to invent solvers from scratch on gnarly industrial problems or fundamentally upgrade mature algorithmic cores, human intuition still holds a massive lead.

What Problem Does This Paper Address?

Combinatorial optimization—finding the best route, schedule, or packing plan out of an astronomical number of discrete possibilities—runs the modern logistical world. Because exact solutions take too long for massive problems, engineers rely on custom heuristics and metaheuristics (clever rules of thumb and guided search strategies). Designing these requires months of specialized human trial and error.

Recently, researchers have used Large Language Models (LLMs) to automate this, a field known as Automatic Heuristic Design (AHD). Yet most LLM approaches operate on training wheels: humans lock the LLM inside a rigid evolutionary loop and point it at a single, isolated Python function to tweak.

Meanwhile, general-purpose coding agents—systems equipped with shells, compilers, and file editors—have learned to navigate entire codebases autonomously. The authors ask a natural, high-stakes question: if we take the training wheels off, can general-purpose coding agents perform true Automatic Algorithm Design (AAD) on large-scale, real-world optimization problems with minimal human intervention?

Methods

The authors built a unified, sandboxed evaluation framework testing two realistic engineering scenarios: improving an existing expert solver and building a solver from scratch.

Figure 1: Common experimental framework. The two tasks differ in the initial code supplied. Agent development uses authorized materials and development feedback; the frozen program is assessed independently on held-out instances.

Inside an isolated Linux workspace, agents receive problem documentation, development ("training") instances, and an official solution checker, with held-out test data strictly locked away. Agents are given a budget ofcomplete evaluations (e.g., 50 full runs) to freely plan, edit code, compile, debug, and inspect performance feedback before freezing their best solver for independent testing under generous runtimes (up to an hour per instance).

The study benchmarks four frontier agent–model pairs:

  • Codex (GPT-6-Astra)
  • Kimi-code (KIMI-K3)
  • Zcode (GLM-5.3)
  • DeepSeek Harness (DeepSeek-V4-Flash)

They are compared against fixed-workflow LLM baselines (ReEvo, which evolves a single human-designated operator, and OpenEvolve, which evolves full programs) and powerhouse human solvers, such as GA-EAX for routing and champion-derived industrial competition code.

Datasets

The benchmark spans five discrete optimization domains, scaling from clean textbook classics to messy industrial headaches, with larger or distinct instances reserved for held-out testing:

  • Permutation Flow-Shop Scheduling (PFSP): VFR benchmark; 60 development instances (100–200 jobs) and 180 held-out instances (300–800 jobs).
  • Traveling Salesman Problem (TSP): Large-scale TSPLIB, National, and VLSI sets; 33 development instances (5,087–19,402 cities) and 21 held-out instances (21,215–47,608 cities).
  • ROADEF/EURO 2018 (Glass Cutting): Saint-Gobain's 2D guillotine cutting problem with material defects (15 dev, 15 test instances).
  • ROADEF/EURO 2020 (Grid Maintenance): French grid operator RTE's stochastic maintenance scheduling under risk quantiles (15 dev, 15 test instances).
  • ROADEF/EURO 2022 (Truck Loading): Renault's coupled freight routing, 3D stacking, and axle-weight planning (50 dev, 105 test instances).

Key Insights and Ideas

  • Agentic freedom beats rigid workflows on complex code: Without anyone telling them where to edit, coding agents match or beat fixed evolutionary pipelines—especially on intricate codebases where coordinating changes across multiple files matters.
  • Feasibility is solved; deep optimization is not: When coding from scratch on brutal 3D truck-loading or glass-cutting tasks, agents write 100% valid code that obeys every geometric and physical rule—yet their cost efficiency gets crushed by human matheuristics. Writing bug-free constraint logic is vastly easier for agents than discovering deep mathematical search structures.
  • Beware the "parameter tuning" illusion: Looking only at benchmark scores can fool you into thinking an agent invented a brilliant new algorithm. On TSP, massive gains over the default solver turned out to be achievable simply by changing a single population-size parameter from 300 to 100—the agents left the core crossover math untouched.

Key Results

  • Beating workflows: Using the identical DeepSeek model, DeepSeek Harness outperformed ReEvo on PFSP test gaps (1.08% vs. 1.94%) and beat OpenEvolve on TSP (0.020% vs. 0.041%), ROADEF 2018 (where OpenEvolve failed to improve the baseline), and ROADEF 2020. (OpenEvolve won only on PFSP at 0.91%).
  • Polishing expert code: Agents improved every existing human solver, and those gains generalized to unseen test sets. On PFSP, Zcode cut the Iterated Greedy baseline's test gap by 78% (from 2.05% down to 0.45%). On ROADEF 2018, Kimi-code trimmed waste on a competition-champion solver by ~3% relative. On ROADEF 2022, Kimi-code pushed the 6th-place competition solver's common-subset gap from +0.42% down to -0.29% while solving more instances validly (299/315 vs. 271/315).
  • Starting from scratch: On structurally simpler PFSP, all scratch-built agent solvers beat human baselines and frequently broke best-known upper bounds (DeepSeek Harness hit a -0.46% mean test gap). Conversely, on ROADEF 2018 and 2022, scratch solvers hit 100% test validity (e.g., 315/315 solves) but trailed human experts by over 13 and 21 percentage points in waste/cost, respectively.
  • Configuration vs. core innovation: On TSP, agents slashed the default population-300 EAX test gap from 2.24% to 0.014%–0.073%, but none beat a manual population-100 control (0.0143%).

Limitations and Future Work

Training champions frequently stumble at test time: rankings flip on larger scales, and seemingly great solvers hit out-of-memory violations (Zcode on ROADEF 2018) or sudden crashes (SIGABRT on ROADEF 2020) on unseen instances. Furthermore, subtle hardware, thread, and timeout differences across certain historical runs mean some cross-campaign comparisons are descriptive rather than strictly causal, and fixed nominal evaluation budgets do not equalize actual compute or token spend.

For future work, the authors highlight three frontiers: equipping agents to diagnose and redesign core search mechanisms rather than relying on surface-level tuning; integrating domain literature so scratch-built solvers can tackle complex industrial math; and building stricter generalization and resource-compliance checks directly into the agent's development loop.

Summary updated

BibTeX
@misc{lv2026how,
  author = {Haoze Lv and Shaofeng Zhang and Shengcai Liu and Ke Tang},
  title = {{How Good Are Coding Agents at Automatic Algorithm Design?}},
  year = {2026},
  eprint = {2611.36339},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.36339},
}
Figure