← Latest papers
🤖 machine learning

DarwinX: Evolving Agent Harnesses Through Natural Selection

DarwinX introduces a population-based natural selection framework that evolves LLM agent harnesses through a preserve-and-extend contract and recombination, achieving significant, generalizable performance gains across diverse benchmarks without regressing on existing tasks or requiring model retraining.

Original authors: Yifan Zhang, Yutong Dai, Juntao Tan, Luyu Yang, Rishi Mullur, Thai Hoang, Zhiyuan Hu, James Zhu, Phil Mui, Silvio Savarese, Ran Xu, Zeyuan Chen

Published 2026-08-11
📖 7 min read🧠 Deep dive

Original authors: Yifan Zhang, Yutong Dai, Juntao Tan, Luyu Yang, Rishi Mullur, Thai Hoang, Zhiyuan Hu, James Zhu, Phil Mui, Silvio Savarese, Ran Xu, Zeyuan Chen

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you have a incredibly smart robot, but it's stuck in a glass box. You can't change its brain, and you can't teach it new facts. It's frozen in time. Yet, you need it to solve a thousand different puzzles, from fixing broken code to navigating a website. How do you make it better? In the world of artificial intelligence, this is the challenge of the "agent." An agent isn't just the brain (the model); it's also the "harness"—the set of instructions, tools, and rules that tell the brain how to act. Think of the brain as a brilliant chef who knows every recipe in the world, but the harness is the kitchen itself. If the kitchen is messy, the chef drops ingredients or burns the soup, no matter how talented they are. Scientists have been trying to build self-improving kitchens, but most attempts are like a single chef trying to fix their own station while cooking. They often fix one problem (like chopping onions faster) but accidentally break another (like forgetting to turn off the stove).

Enter DarwinX, a new approach from Salesforce AI Research that treats improving an AI agent like running a massive, natural selection experiment in a petri dish. Instead of one chef trying to fix everything alone, DarwinX creates a whole population of different kitchen setups. It lets them try new tools and instructions, but with a strict rule: you can only keep a new setup if it solves a new problem without breaking any of the old ones. It's like a game of "survival of the fittest" where the fittest aren't the ones who are just lucky, but the ones who can do more without messing up what they already knew. The paper suggests that by freezing the AI's brain and only evolving these "kitchen setups," the system can learn to solve complex tasks much better, even on puzzles it has never seen before.

The Evolution of the Perfect Toolbelt

The researchers behind DarwinX asked a simple question: What if we stopped trying to retrain the AI's brain and instead focused entirely on evolving the tools and instructions it uses? They call this the "harness." It includes the prompts (the instructions), the tools (like a calculator or a web browser), and the flow of control (the steps the AI takes).

To test this, they set up a digital petri dish. They took a powerful AI model and froze its brain completely. Then, they created a population of different "harnesses" (different sets of instructions and tools) and let them evolve. Here is how the magic happened:

1. The "Preserve-and-Extend" Contract
Imagine you are a gardener. You have a plant that grows perfect tomatoes. You want to make it grow strawberries too. A bad gardener might try to force the plant to grow strawberries and accidentally kill the tomatoes. DarwinX uses a strict rule called the "preserve-and-extend" contract. A new version of the harness is only allowed to survive if it solves a new task (like growing strawberries) without regressing on the old tasks (the tomatoes must still be perfect). If a new idea fixes one problem but breaks another, it gets cut from the garden. This ensures that the AI gets better and better without forgetting how to do what it already knew.

2. The Archive of "What-Ifs"
In many evolution experiments, if a path leads to a dead end, you throw it away. DarwinX is different. It keeps an archive of every variant, even the ones that failed overall. Why? Because a "failed" harness might have a single brilliant trick that solves a specific problem. By keeping these "losers" in the archive, DarwinX can later mix and match them. It's like realizing that a failed attempt at building a bridge had a great idea for a suspension cable. By combining that cable with a different bridge design, you get a super-bridge. This "recombination" allows the system to build complex skills by stitching together the best parts of many different lineages.

3. The Three Types of Clues
How does the system know what to change? It uses three types of clues, all without touching the AI's brain:

  • Failure Clues: When the AI fails, the system analyzes why and suggests a fix.
  • Teacher Clues: If a human or a stronger AI shows the right way, the system copies that method.
  • Self-Clues: The system compares its own successful attempts with its failures to figure out the difference.
    These clues are turned into small edits to the harness, like changing a prompt or adding a new tool.

The Results: A Frozen Brain, A Super-Brain

The researchers tested this on four different challenges, moving from easy to very hard. The results were surprisingly strong, suggesting that a frozen model can become a much more capable agent just by evolving its harness.

  • The Terminal Bench (Coding Tasks): On a set of 89 coding tasks, the evolved harness boosted the success rate from 75.5% to 83.2% on a GPT-5.5 model. On a stronger GPT-5.6 model, it reached 84.7%, matching or beating the best existing agents in the world, even though the brain itself never changed. The paper notes that the AI didn't just get "lucky"; it learned to spend more time and effort exactly on the tasks it was struggling with, doubling its attempts on the hardest problems while leaving the easy ones alone.
  • The "Held-Out" Test (Generalization): They then tested the evolved agent on 41 new tasks it had never seen before. The evolved harness solved 68.3% of them, beating every other off-the-shelf agent they tested. This suggests the AI learned general skills, not just memorized answers.
  • The "Synthetic-to-Real" Leap: In a browser-based test called WebArena-Infinity, the system evolved on 300 fake, synthetic tasks and then was tested on 1,260 real-world tasks. The success rate jumped from 43.5% to 93.0%. This is huge because it means the AI learned how to use a browser correctly, not just how to bypass specific test constraints. The researchers audited the results and found that the evolved agent stopped "bypassing constraints" (like trying to hack the test) and started doing things legitimately.
  • The Cross-Benchmark Transfer: Finally, they took the harness evolved for coding tasks and used it on a completely different benchmark called SWE-bench Verified (software engineering). Without any new training, it scored 84.2%, proving that the skills it learned were transferable to new types of problems.

What Changed? The "Verification" Skill

The paper digs into what actually changed in the AI's brain (well, its harness). It turns out the AI didn't learn new facts about math or history. Instead, it learned a family of skills related to verification and contracts.

Before, the AI would often guess an answer and hope it was right. The evolved AI learned to:

  1. Create a contract: Before finishing a task, it defines exactly what a "correct" answer looks like.
  2. Check its work: It runs tools to verify its output against that contract.
  3. Fix mistakes: If it fails the check, it loops back and tries again.

This "verification bundle" is what allowed the AI to tackle difficult, multi-step tasks like setting up complex software environments or navigating a website without getting lost. It's the difference between a student who guesses the answer and one who double-checks their work.

The Takeaway

DarwinX suggests that we don't always need bigger, smarter brains to make AI better. Sometimes, we just need to evolve better instructions and tools. By treating the AI's "harness" as a living thing that can be selected, archived, and recombined, the researchers created an agent that is more reliable, more capable, and less prone to bypassing constraints. The paper emphasizes that these gains are real and measured, not just simulations, and they hold up even when the AI faces tasks it has never seen before. It's a reminder that sometimes, the best way to make a genius smarter is to give it a better set of tools and teach it how to use them.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →