Four coding agents that share one notebook cut a GPU kernel from 1,363 to 1,103 cycles. Fixed evolutionary search stalled at 2,740. Press Run, then switch systems.
Learn how CORAL hands the whole search loop to long-running coding agents, then gives them a shared file-system memory, a heartbeat that nudges them, and an evaluator they cannot read.
Pick a system, press Run, and watch how many of its evaluations (each one a test of a new program) actually beat the best score so far. Then we build the idea piece by piece: the loop, the memory, the heartbeat, the team, and the proof.
You need a feel for what a coding agent is (a language model that edits files and runs commands in a loop). We build the rest from zero.
A reading for MIT MMAI, Multimodal AI (Spring 2026), paired with the lecture Self-Evolving AI. Paper: Ao Qu, Han Zheng, Zijian Zhou, Yihong Tang, Shao Yong Ong, Fenglu Hong, Kaichen Zhou, Chonghe Jiang, Minwei Kong, Jiacheng Zhu, Xuan Jiang, Sirui Li, Yihao Yan, Bryan Kian Hsiang Low, Jinhua Zhao, Cathy Wu and Paul Pu Liang, CORAL: Towards Autonomous Multi-agent Evolution for Open-ended Discovery (COLM 2026). Code: Human-Agent-Society/CORAL.
Evaluation counts, improvement counts and final cycles are the paper’s (the Figure 1 table: 363 and 12 and 2,740; 56 and 24 and 1,350; 596 and 54 and 1,103), all with Claude Opus 4.6. Which dots improved, and when, is illustrative: the paper gives totals, not the order.
Chapter 0
See why some problems cannot be solved in one shot, and what CORAL changes about who runs the search
It is late. You have a small program, a kernel, which is a short routine that does one heavy job on a chip. Yours walks a tree of numbers again and again. Today it takes 147,734 cycles. A cycle is one tick of the chip's clock, so fewer cycles means a faster kernel.
Someone has already made it much faster. The best known version runs in 1,363 cycles. Can you do better? Nobody knows. No answer key says the floor is 1,300 or 1,000 or 900.
The paper calls this open-ended discovery. The goal is clear: fewer cycles. The best solution is unknown. You cannot look it up, and you cannot reason straight to it. You have to try ideas, measure them, keep what works and learn from what does not.
Ask a language model to write the fastest kernel in one reply and you get a plausible program. It is rarely a record. The paper says it plainly: one-shot generation is insufficient, because strong solutions are found through proposal, testing, revision and progress over time.
So the field built a loop around the model. A program called an evaluator runs each candidate and returns a score. The model sees the best earlier candidates and proposes a new one. Repeat a few hundred times. Systems such as FunSearch and AlphaEvolve work this way, and the loop has found new mathematics and faster algorithms.
In those systems, ordinary code runs the loop. Fixed rules pick which earlier solutions to show the model. Fixed rules decide when to test. Fixed rules decide what to remember. The model only does one job: write the next candidate from the context it is handed.
The authors of CORAL ask a simple question. What if the model were an agent, a model that can read files, run commands and decide its own next move? Could it do better if it also chose what to read, when to test and what to write down?
That is the whole paper. CORAL gives long-running coding agents the search loop, and adds three supports so they do not wander off: a shared memory made of ordinary files, a heartbeat that reminds them to reflect, and an evaluator they cannot read or edit.
Scroll back to the race at the top and compare the three systems. Look at two things: the final cycles, and the share of evaluations that improved.
| System | Evaluations | Improved | Final cycles | Speedup |
|---|---|---|---|---|
| Fixed search (OpenEvolve) | 363 | 12 (3%) | 2,740 | 53.9x |
| CORAL, one agent | 56 | 24 (43%) | 1,350 | 109.4x |
| CORAL, four agents | 596 | 54 (9%) | 1,103 | 133.9x |
One agent needed 56 evaluations to reach 1,350 cycles, already past the 1,363 best known; four agents needed 596 and ended at 1,103 cycles, which is 18.3% fewer than one agent.
All numbers are from the paper's Figure 1 table and Table 2. Speedup is 147,734 divided by the final cycles. Every run uses Claude Opus 4.6.
Notice the odd part. Four agents improved only 9% of the time, while one agent improved 43% of the time. Yet four agents ended far ahead. A high improvement rate is not the same as a high final score. Chapter 7 explains why.
By the end you can rebuild the idea yourself. You will know the four-stage loop, the three folders of memory, the seven steps of one evaluation, the three heartbeat reminders and the way agents share work without messages. You will also know which results back each claim.
Chapter 1
Name the four stages every discovery system repeats, and write them as one small equation
Picture a baker tuning a loaf. She bakes one, and a taster scores it from 0 to 100 with a short hint: "too dry". She cannot see inside the taster's head. She only gets a score and a hint. So she keeps notes, bakes again, and changes one thing.
That is the whole shape of open-ended discovery. Swap the baker for a model, the loaf for a program, and the taster for a test harness. The rest of this chapter makes it exact.
A task is a written description x, such as "make this kernel use fewer cycles". A candidate y is one proposed answer, here a whole program. An evaluator E is code that runs a candidate and reports how good it is.
The evaluator returns two things. The score s is a number, such as 1,274 cycles. The feedback f is extra detail: a breakdown of sub-scores, an error message, or a written critique from another model. The score tells you how far; the feedback often tells you why.
The evaluator is the only source of truth. Nobody knows the best program, but anyone can run a program and read its score. That is why this setting works at all.
The search also needs a memory Mt: everything kept after t steps, such as earlier candidates and how they scored. Each improvement step then has four stages.
Step through a toy version. The task is "find the tile size that scores highest", and the hidden best size is 62. A tiny agent, written as ordinary code, follows the four stages. Press Next stage and watch each one change the picture.
The purple bars are memory: one bar per tried candidate. The highlighted box is the stage that runs next. Press Next stage four times to finish one loop.
A toy. The score is 100 minus the distance from 62, and the feedback says "too small" or "too big". The proposal rule is plain code, not a language model.
Run the toy by hand. Memory starts with size 20, which scores 100 minus 42, so 58. Its feedback says "too small". Retrieve picks it. Propose adds a step of 24 and tries size 44.
Evaluate gives 100 minus 18, so 82: a new best. Update stores it. The next loop tries 68, which scores 94 and says "too big". The direction flipped, so the step halves to 12. Size 56 also scores 94, a tie, not an improvement.
Now the agent would repeat size 56 again, so it halves the step to 6 and tries 62. The score is 100. Five attempts reached the optimum. A blind search over sizes 1 to 100 would need about 50 tries on average.
Symptom: after many evaluations the best score does not move. Measurement: the improvement rate sits near zero, and the feedback text is just "score: 58". Fix: return richer feedback. The toy's hint "too small" is the reason it needs five steps and not fifty. Real evaluators in the paper do the same, with sub-score breakdowns and error text.
The loop turns a hard question, "what is the best program?", into an easy one: "given what we know, what should we try next?". Each pass spends one evaluation, one run of the evaluator. Evaluations are the budget. One grader run can take long, so the paper gives each a hard time limit, 300 seconds by default.
So the useful measure is improvement rate: improving evaluations divided by all evaluations. A system with a high rate wastes few runs on candidates that do not beat the best.
One more fact for later. The four stages are the same in every system the paper compares. What differs is who performs each stage. In the next chapter you will see that most of them were performed by fixed code, and only Propose was left to the model.
Chapter 2
Find the four decisions that fixed evolutionary search takes away from the model, and see what CORAL gives back
Think of a research lab with a strict manager. The manager picks which old experiment each scientist reads. The manager says when to run tests. The manager files the notes. The scientist only does one thing: write the next experiment. Would you expect the lab to find a lot?
That is how most LLM-driven discovery systems work. The model is a very good scientist in a very small box.
Evolutionary search copies the idea of evolution. Keep a population, a pool of programs with scores. Pick a parent from the pool. Make a changed copy, called a mutation. Score it. If it is good, it joins the pool.
In FunSearch and AlphaEvolve the language model is the mutation operator. It reads earlier high-scoring programs, written into one prompt, and returns a changed program. The paper says AlphaEvolve builds that prompt with rules inspired by MAP-Elites (a grid of niches where each niche keeps its single best program) and island models (several separate sub-populations that rarely mix). These keep the pool varied.
Later systems tune those rules. OpenEvolve, ShinkaEvolve and EvoX adapt sampling, use islands, or even evolve the search strategy itself. The paper's summary of all of them: they follow a fixed pipeline. Select parents by a predefined rule, build a prompt, call the model for one mutation. The model has no say over what to explore next.
The authors name what the model cannot decide in a fixed pipeline. These are the four decisions:
The paper's argument is that for open-ended problems these choices are part of the problem itself. A good kernel engineer does not only write code. She reads logs, runs small tests, notices a bottleneck, and writes it down for next week.
Figure 1 of the paper draws three ways to run the loop. In fixed evolutionary search, rules pick the context, one model call proposes, a fixed loop triggers the evaluator, and fixed rules update memory.
In autonomous single-agent evolution, one agent controls most of the process. It chooses what to read, plans and edits code, tests locally, decides when to call the evaluator, and decides what to store. The four stages are the same. Only the timing and the owner change.
In autonomous multi-agent evolution, several such agents run at once. They do not follow assigned roles. They coordinate only through the shared memory they all read and write.
Try it. Flip each stage between a fixed rule and the agent, or use the three presets. Watch what the agent holds.
Pink stages are decided by code. Teal stages are decided by an agent. Press a preset, then flip single stages to see the difference.
The stage labels and who owns them are the paper's Figure 1 and Section 3.2. Pressed means the agent decides.
The same question applies to teams of agents. Many multi-agent systems scale vertically: a human splits the task, gives each agent a role such as planner, coder or reviewer, and fixes who talks to whom. The AI Scientist and the AI Co-Scientist work this way. That assumes you already know the right split.
CORAL scales horizontally. Every agent has the same instructions and the same job. They explore in parallel, trade discoveries through shared memory, and build on each other's progress. In FunSearch and AlphaEvolve, parallel workers also exist, but they are stateless evaluation workers with no memory across steps.
Symptom: a fixed system keeps testing candidates that cannot win. Measurement: on the kernel task, OpenEvolve improved on the best score in 12 of 363 evaluations, which is 3%. Fix: let the agent decide when a candidate is ready. One CORAL agent improved in 24 of 56, which is 43%. The paper's wording: CORAL wastes far fewer evaluations on unproductive candidates.
Chapter 3
Open the three folders where CORAL agents keep what they learn, and see why plain files beat a clever database
Imagine a shared lab cupboard. Every scientist drops in a lab sheet after each experiment, a page of lessons, and a recipe card for a trick that worked. Anyone can open the cupboard and read. Nobody has to ask a clerk for permission.
CORAL's memory is that cupboard. It is an ordinary file system, the folders and files on a disk. The paper calls it shared persistent memory: shared because every agent sees it, persistent because it stays after any agent stops.
A coding agent already knows how to use files. It can list a folder, open a file and search for a word. So the authors did not invent a memory API for the model to learn. They made memory look like a library, and the agent uses the same shell tools it uses on code.
This also gives progressive disclosure: the agent first sees only folder names, and opens a file only when it needs it. That saves its context window, the limited text the model can read at once. A database that dumped all past notes into the prompt would waste it.
Agents may even reorganise the folders, for example by grouping notes into sub-folders. The design stays easy to maintain and extend.
To give the agents a start, CORAL defines three root folders. Each holds a different kind of knowledge.
Attempts are facts. Notes are understanding. Skills are tools. A note says "relaxing one dependency made things worse, and here is why". A skill says "run this script to try it".
Open each kind of file in the device below. The records are real examples from a four-agent kernel run in the paper's appendix.
The tree shows where each file lives. Pick a file to read what an agent actually wrote. Try the grader at the end.
The attempt, note and skill are shortened copies of the paper's Boxes in Appendix C.4 (the skill is from the LLM-SQL task). The heartbeat defaults are Table 7. The tree is Figure 6 and the Appendix C.4 layout.
An attempt is a small JSON file (a plain-text format for labelled data) named by the git commit hash, an ID git gives to each saved version of the code. It has the agent's name, a title that doubles as a lab-notebook line, the score, a status, the hash of the parent attempt it started from, a timestamp, and the evaluator's feedback.
Because each attempt names its parent, the files form a family tree. That is how the paper later counts how often an agent builds on another agent's work.
The note in the device comes from agent-1. It records a gain from 1,187 to 1,181 cycles. The agent wrote the engine floors, the least number of cycles the hardware allows for each unit of work.
The vector unit (VALU) does 6 operations per cycle. The note counts 6,944 of them. So the floor is 6,944 divided by 6, which is 1,157.3. Round up to 1,158 cycles, because a cycle cannot be partial. The scalar unit (ALU) does 12 per cycle and has 12,544 operations: 1,045.3, so 1,046 cycles.
The VALU floor is the larger one, so it binds. The kernel runs at 1,181, which is 23 cycles above 1,158. The agent now knows exactly how much room is left, and which unit to relieve. A bare score of 1,181 could never say that.
Raw notes pile up fast. On the kernel task one run wrote hundreds of attempts. So CORAL also asks the agents to tidy the notes. Later chapters show the timer that triggers it. The result is three kinds of tidy file.
A synthesis note sits in notes/synthesis/. It covers any topic with three or more notes, states the conclusion first, cites attempts as evidence, and gives a confidence level. A file called connections.md maps patterns across topics. A file called open-questions.md lists gaps and contradictions. A new agent can read these three files in a minute and skip hundreds of raw notes.
Symptom: two agents write to memory at once and one overwrites the other. Measurement: the paper reports no file-level conflicts across agents. Fix by design: each attempt goes to its own file named by hash, and notes and skills use unique filenames, so no locks are needed. Chapter 6 comes back to this.
Chapter 4
Follow a single coral eval command through its seven steps, and see why the agent never reads the grader
A student sits an exam. She can hand in her paper and read her mark. She cannot read the marking scheme, and she cannot edit it. If she could, the easiest way to a perfect mark would be to rewrite the scheme.
An agent in a discovery loop faces the same temptation. The paper names it reward hacking: raising the score by gaming the evaluator instead of solving the task. CORAL's answer is structural, and you will see it in this chapter.
Each agent starts with one instruction file, CORAL.md, written into its workspace at launch. It is the agent's only source of task-level instructions. Fields such as the task text and whether lower or higher scores are better are filled in from a template.
The multi-agent version tells the agent it is one of several colleagues sharing a .coral/ folder. It then lists an orientation: read the task, read the key files, check the leaderboard with coral log, inspect top attempts with coral show, search prior work, read notes, list skills. Then comes a loop: plan, edit, eval, repeat.
The ground rules are short. Be fully autonomous. Never run git directly. Write eval messages like lab notebook entries. Eval early and often. After every eval, update a note and a skill.
The agent never types git commands. It edits files, then runs coral eval -m "what I changed and why". CORAL handles version control, so every candidate becomes a commit with a hash, and the agent's message becomes the attempt title. The agent can still move around its history with coral checkout, coral diff and coral revert.
The command line has 17 commands in four groups: workflow (eval, diff, revert, checkout), query (log, show, notes, skills, runs), orchestration (start, resume, stop, status) and heartbeat (view, set, remove, reset). The agent uses the first two groups and the heartbeat group. A human operator uses the orchestration commands.
Step 4 has five outcomes. Improved: strictly better than the previous best. Baseline: equal. Regressed: worse. Crashed: the grader returned nothing. Timeout: the grader ran past its limit, and the score is recorded as null. For the kernel, lower is better, so "better" means fewer cycles.
Run it yourself. The previous best is 1,274 cycles, the number from the attempt record in Chapter 3.
Choose what the candidate does, then slide its cycle count. The pipeline lights up, the wall hides steps 2 and 3, and the status appears.
The seven steps, the five statuses and the 300 s default are Appendix C.2. The previous best of 1,274 cycles is the attempt record in Appendix C.4. The slider range is illustrative.
At the start of a run, the grader code is copied into .coral/private/eval/. Agents can submit a candidate and see the score, but they cannot read or change the logic. In the paper's words, the evaluator is an API the agent can call, with the grader details hidden.
A task needs only two pieces: a YAML file (a plain-text settings file) and a Python class. The YAML names the task, the files to show, the direction (maximize or minimize), the agent count and the model. The class has one method, evaluate. It runs the agent's program, returns self.fail(stderr) on an error, and otherwise returns a score with a short explanation. Chapter 9 shows the code.
Failure to watch for: symptom, a score that jumps to a perfect value in one step. Measurement: read the attempt's diff with coral show, and check that the candidate still solves the task. Fix: keep the grader private, keep correctness mandatory in it (the kernel task states that correctness is required), and give feedback that names what was checked. The wall removes the easy route to the symptom; it does not remove the need to look.
Because evaluations are costly, a good agent tries its code on its own machine before using the official one. The paper measures this. On Transaction Scheduling, 61% of attempts were tested locally first, and on Kernel Engineering 57%. A local run often catches a compile error before an evaluation is spent. On PRISM the rate was 0%, because that grader uses randomized hidden tests, so there is nothing to reproduce locally.
Chapter 5
Learn the three timed reminders that keep a free agent writing notes and escaping dead ends
You are fixing a stubborn bug. Four hours pass. You have tried the same small tweak twenty times, and you never wrote down what you learned. Then a reminder pops up: "Stuck for an hour. Try something different?" Annoying, and exactly what you needed.
Free agents have this problem at scale. CORAL does not force a fixed workflow, so an agent can fall into a local minimum: a spot where small changes no longer help, so it polishes details instead of trying new ideas. It can also forget to read or write shared memory.
A heartbeat is a reminder that CORAL injects into an agent's session when a trigger fires. Each reminder has a trigger: a count of evaluations, an amount of time, or a change in the score. When it fires at step t, it edits the agent's local context, the text the agent is currently working from. The new context steers what the agent does next.
Heartbeats can be preset or created by the agents. An agent may set its own, for example "remind me every 3 evals", or add a custom reminder with a prompt for its domain.
The reflect prompt asks five things. Anchor in concrete results: which change moved the score? Examine surprises. Explain the cause: why did it happen? Assess confidence: what evidence would change your mind? Plan one specific next experiment, with an expected result. Then save a note, and a skill if the technique is reusable.
The consolidate prompt asks the agent to pause and synthesise. Browse the notes. Write a synthesis note for any topic with three or more notes. Update the connections map and the open-questions list. Reorganise the folders. Promote techniques that held up into skills. It must produce files, not just thoughts.
The pivot prompt starts bluntly: you have not improved in several evaluations, and you are probably stuck in a local optimum. It walks through five steps. Diagnose the ceiling. Study what is different at the top, especially other agents' work. Choose a fundamentally different direction. Reset to the best attempt with coral checkout. Commit quickly, with a minimal version, and give the new idea two or three evaluations before judging. Its last line: the goal is not to find the best tweak, it is to find a better mountain to climb.
Each action is set by four fields: how often (every), the trigger kind (interval or plateau), the scope (local to one agent, or global across all), and the prompt. The manager process polls the attempts folder every 5 seconds, updates a count for each agent (evaluations so far, best score, evaluations since the last improvement), then checks every action.
Delivery is careful. The manager interrupts the agent with a graceful stop signal that lets the runtime save the session. Then it resumes the agent with one combined message: the latest evaluation result (score, hash, status, feedback) plus the heartbeat prompt. So the agent keeps all its accumulated context and just receives a new instruction.
Two actions, reflect and consolidate, are protected. An agent can change how often they fire but cannot delete them. This guarantees a minimum amount of knowledge ends up in memory.
Each square is one evaluation, green when it improved. The lanes below show when each reminder fires. Change the pattern, then move the two sliders.
The defaults (reflect every 1, consolidate every 10, pivot after 5) and the trigger rules are Appendix C.5 and Table 7. The three score patterns are toys made for this device. The agent's behaviour after a pivot is not simulated.
Take the first pattern. Evaluations 1, 2 and 4 improve. After evaluation 4 the stall count s is 0. Evaluations 5, 6, 7, 8 and 9 add one each, so s reaches 5 at evaluation 9 and the pivot fires. Evaluation 10 makes s = 6. Evaluation 14 would make s = 10, which is 2k, so a second pivot fires at 14 if the stall continues. Consolidate fires at 10, 20 and 30 whatever the scores. Reflect fires after every one of the 30.
Symptom: the best score is flat while the agent logs "tuned a constant" again and again. Measurement: s keeps rising, and the agent's own notes show the same topic in a row. Fix: the pivot prompt sends it to study other agents' top attempts and pick a new approach. The paper says these reminders promote explicit memory formation and reduce myopic local search.
Chapter 6
See how four agents work side by side without a chat channel, without locks and without stepping on each other
Four cooks work in four separate kitchens. They never talk. But a shared wall in the hallway holds every recipe card and every note about what burned. Each cook reads the wall before trying something new, and pins up what she learned.
That is CORAL's multi-agent design. It is unusual. Many multi-agent systems have agents message each other directly. CORAL says: coordination occurs primarily through shared persistent memory.
Run N agents at once. Agent i keeps its own local context (what it has read and done in its session) and works in an isolated workspace. Technically this is a git worktree: a second working copy of the same repository, on its own branch. Edits in one worktree never touch another.
All agents share two things: the same evaluator, and the same memory. The memory lives in one folder, the hub (.coral/public/). Each workspace reaches it through symbolic links, shortcuts that point at the original files. In a Claude Code run, the agent's .claude/notes points at the hub's notes, and the same for skills and attempts. The agent then reads and writes with its normal file tools, while the real data stays in one place.
A .gitignore rule in each worktree keeps the hub out of the agent's commits, so an agent cannot accidentally commit shared notes into its own branch.
There is no message. Agent i writes artifacts Wt(i), which are attempts, notes and skills, into the hub. Later, agent j runs ls or coral log, finds them, and reads them as part of its own working context. Agent j may pick agent i's commit as its starting point, copy an idea from a note, or run a skill.
The paper calls the useful effect technique diffusion. A trick found by one agent spreads to the others without anyone assigning it. It also reports spontaneous consensus and cross-referencing among agents. None of these behaviours is hard-coded.
Concurrent writers are a classic bug source. Two programs save the same file at the same moment, and one save disappears. CORAL avoids the problem by design. Each attempt is written to a unique file named by its commit hash. Notes and skills use unique filenames. Two agents never write the same path, so no locking is needed. The paper reports no file-level conflicts in practice.
A process called the AgentManager runs the show. It creates the run folder, clones the source repository once for the run, seeds the heartbeat settings, then for each agent: creates the worktree, installs the symlinks, writes a small file naming the agent, generates CORAL.md, and starts the agent runtime.
Then it monitors. It detects new attempts, checks heartbeat triggers and delivers prompts. If an agent process dies, for example from running out of turns or a crash, the manager notices within 5 seconds and restarts it with the latest results. On shutdown it saves each session ID. With coral resume, agents pick up their old context.
Each toy agent improves one setting at a time. Sharing lets an agent copy a setting from the team's best attempt. Move the sliders and compare the two curves.
A toy, not the paper's experiment. Six settings with eight levels each and random scores; every agent starts from the same program; each round it changes one setting and keeps the change if the score rises. Averaged over 200 random toy problems. The paper's own comparison is in Chapter 8.
Say you have 4 agents and six settings. An independent agent finds a good level for a setting only by luck, and each agent must find all six. A sharing agent can copy a good level that another agent already found. Discoveries combine. That is why the shared curve climbs faster. Set the memory slider to 0 and the two curves match, because without reading memory there is nothing to share.
What the toy leaves out is just as important. Real agents do not copy at random, and the paper's team also gains from different search directions. The paper measures both effects on real runs, which is Chapter 8.
Prevented: agents corrupting each other's work. Symptom: a half-written file or a broken build after two agents edit at once. Fix: separate worktrees and unique filenames. Not prevented: sameness. All agents start identically with the same information, which the authors list as a limitation. They suggest giving agents different personalities, roles or private information in future work to make their search more varied.
Chapter 7
Read Tables 1 and 2 task by task, and learn why a lower improvement rate can come with a better final score
Two runners. One sprints to a decent time in a few laps and stops. The other jogs for much longer, trips more often, and finishes with a record. If you scored only "how often did a lap beat my best?", the sprinter wins. If you scored the final time, the jogger wins. The paper's tables contain both runners.
The paper uses two benchmark suites and two stress tests. The suites follow the set-up of two earlier systems, EvoX and TTT-Discover. There are 6 math tasks, such as circle packing (fit circles in a square) and the Erdős minimum overlap problem, and 5 systems tasks, such as expert placement for load balancing (EPLB), GPU placement and cross-cloud data transfer (Cloudcast).
The two stress tests are harder. The first is Anthropic's kernel engineering task, a tree walk on a simulated chip that issues many operations per cycle, with an official best of 1,363 cycles. The second is polyomino packing from the Frontier-CS benchmark, the hardest of its 172 problems: tile a grid with shapes made of joined squares so as little area as possible is left unused.
Baselines are OpenEvolve (OE), ShinkaEvolve (SE) and EvoX, all given the same starting programs, evaluators and budgets. Single-agent runs use Claude Code with Claude Opus 4.6. Multi-agent runs on the suites use an open stack, the MiniMax M2.5 model with the OpenCode agent, to show the gains are not tied to one vendor. No agent has internet access, with one flagged exception later.
Budgets are fair by design: the suites get 3 hours of wall-clock time (real elapsed time), or 100 iterations for the baselines, whichever is longer, and CORAL runs only as long as the shortest baseline run. Stress tests run to convergence. Every number is an average of 4 independent trials.
Worked: kernel, four agents. Improvement rate is 54 divided by 596, which is 9.06%, shown as 9%. Speedup is 147,734 divided by 1,103, which is 133.9. Gain over one agent is (1,350 minus 1,103) divided by 1,350, which is 247 over 1,350, or 18.30%. Each of these matches the paper's table.
Now explore. Pick a table and a task. Switch between the improvement rate and the number of evaluations.
Choose a table, then a task. Bars show the metric you pick. The label above each bar gives that system's final score.
Every number is read from the paper's Table 1 and Table 2 (averages of 4 trials). Arrows give the direction of a good score: ↑ higher, ↓ lower. Evaluations are the number needed to reach the final score.
In Table 1, CORAL has the best final score on all 11 tasks, and the paper counts new records on 8 of them. The abstract says 10. My own count from Table 1 is 6 clear wins and 4 ties with the previous best. Its improvement rate runs 3 to 10 times above the baselines, and it usually converges in 5 to 20 evaluations against 60 to 100. EvoX is the strongest baseline, and CORAL still beats it everywhere. On four tasks, MMD-16-2, MMD-14-3, third autocorrelation and PRISM, CORAL ties the previous best. On Erdős it misses it by 0.00001.
In Table 2 the picture shifts. The four-agent team ends better on the kernel (1,103 against 1,350) and on polyominoes (84.2 against 80.2). Yet it improves less often: 9.0% against 43.0% on the kernel, and 19.4% against 42.4% on polyominoes. It also uses more evaluations, 596 against 56.
The open-stack half repeats the pattern. All eleven gains are positive, from 0.15% on MMD-16-2 to 20.8% on Cloudcast. But the four-agent improvement rate is lower in 8 of those 11 tasks, and in 10 of all 13 comparisons.
A one-agent run improves often, early, with small steps, then plateaus. A team explores more varied paths. Most of those paths do not beat the current best, so the rate falls. But a few reach areas a single agent never finds, and the final score is better. The paper's own wording: single-agent runs have higher per-evaluation rates, yet co-evolution wins by exploring more diverse trajectories.
One more caution. The paper reports the stress tests without web search, "for fairness". With web search on, four agents reach 89.4% coverage on polyominoes, above the previous record of 87%, against 56.0% for a single-attempt baseline. The kernel record needs no web search.
Chapter 8
Separate what the ablations prove from what the trajectory statistics only suggest, then read the paper's own limits
A team wins a match. Was it the new tactics, the new coach, or luck? A good analyst does two things: she turns a part off and replays the match, and she counts how often each habit appears in wins. The first is an ablation: remove one component and measure the loss. The second shows an association: two things go together, but one may not cause the other. The paper does both, and this chapter keeps them apart.
Agents often run code on their own machine before they spend an evaluation. The paper compares attempts with a local run against the average attempt on the same task. Local runs improve more often. The effect is strongest on compiled code: 61% of Transaction Scheduling attempts and 57% of Kernel Engineering attempts were tested locally, and the check often catches a compile error before an evaluation is wasted.
On Kernel Engineering, an attempt improved 43% of the time on average and 47% of the time after a local test. On PRISM, local testing was 0%. That task's grader makes randomized hidden tests, so a local copy cannot predict the result.
On standard tasks, agents wrote only 0.05 knowledge items per attempt. Reading knowledge helped only a little: attempts that read it improved 26% of the time, 2 points above those that did not. On the advanced tasks, they wrote more than ten times as much: 0.55 per attempt on Polyominoes and 0.68 on Kernel Engineering. Attempts that read knowledge improved 38% and 55% of the time.
The notes also differ in quality. On standard tasks they are mostly progress logs, such as parameter changes. On advanced tasks they hold reusable insights: Kernel Engineering notes name hardware bottlenecks such as the vector unit, and record a case where relaxing a dependency rule made things worse. Polyominoes agents kept a "what NEVER worked" folder so later attempts avoid dead ends.
In the four-agent runs, the paper follows each attempt's parent. On Kernel Engineering, 36% of attempts used another agent's commit as the parent. Those improved 17% of the time against 9% for all attempts, and 66% of new records came from a cross-agent parent. On Polyominoes direct code transfer was rarer, 12%, but strong: 50% improved against 19%. There, knowledge moved through notes and skills, and 87% of rounds referenced knowledge another agent committed.
To measure variety, the authors pull strategy keywords from each attempt title and compare agents with the Jaccard similarity: the size of the overlap divided by the size of the union of two keyword sets.
Toy example: agent A uses {unroll, vectorize, pack, pipeline} and agent B uses {pack, pipeline, hash, cse}. They share 2 words out of 6 different words, so J is 2 over 6, or 0.33. In the paper, the average overlap is 0.43 on Kernel Engineering and 0.31 on Polyominoes, and more than half of each agent's vocabulary is its own. So the team covers much more ground than any one agent.
Credit is shared too. On Kernel Engineering all four agents made 130 to 165 attempts and 10 to 16 improvements, and all four independently reached 1,103 cycles. Records split 14, 15, 10 and 15. Agent-1 held the lead for 45% of the run. On Polyominoes it is lumpier: agent-3 set 6 of 13 records.
Pick a comparison. Each pair of bars shows the paper's two numbers. The first two views are ablations, which show cause. The last two are associations, which do not. The state chip says which is which.
All values are the paper's: Table 3 (1-agent knowledge ablation and 4-agent co-evolution, Claude Code with Opus 4.6), Table 4 (improvement rate overall and when reading knowledge) and Section 4.4.2. Bars within one task share a scale; tasks do not.
Now the causal tests. With one agent, switching off note and skill creation worsened the result on all three tasks: Kernel Engineering from 1,350 to 1,601 cycles, which is 18.6% more cycles. Polyominoes fell from 80.2 to 77.3, and Transaction Scheduling from 4,566 to 4,444. So knowledge artifacts cause part of the search quality; they are not just riding along.
For teams, the paper asks whether the gain is only more compute. It compares 4-agent co-evolution with the best of 4 independent single-agent runs. Co-evolution wins on all three: kernel 1,103 against 1,180 cycles, Polyominoes 84.2 against 80.8, Transaction Scheduling 4,694 against 4,629. Four agents that talk through memory beat four agents that do not.
The authors list three limits. First, CORAL needs a frontier model that can run a complex coding-agent workflow, so it does not run on a laptop; they suggest training small models for it. Second, agents start identical with the same information, so variety is limited. Third, it assumes a well-specified evaluator. Many real problems have none, or an ambiguous one. There, the evaluator may need to evolve with the solutions.
Add your own cautions. The ablations cover three tasks, and the paper says results on tasks with fewer than 30 attempts should be read carefully. Nobody has isolated whether file-based inspection beats the retrieval rules of older systems. And the kernel result needs 596 evaluations and many hours of agent time.
Chapter 9
Keep the numbers, the checklist and the core code, then follow the links onward
CORAL takes the search loop that earlier systems ran with fixed code and hands it to long-running coding agents. It supports them with shared file memory, a heartbeat of timed reminders, isolated workspaces and a hidden evaluator. One agent beats fixed evolutionary search on a wide set of tasks. Four agents that share memory go further than four that do not, ending the kernel task at 1,103 cycles against the previous best of 1,363.
| Quantity | Value | Where |
|---|---|---|
| Kernel baseline | 147,734 cycles | Figure 1 |
| Previous best known | 1,363 cycles (108.4x) | Figure 1 |
| OpenEvolve | 2,740 cycles, 363 evals, 3% improved | Figure 1 |
| CORAL, 1 agent | 1,350 cycles, 56 evals, 43% improved | Figure 1, Table 2 |
| CORAL, 4 agents | 1,103 cycles (133.9x), 596 evals, 9% improved | Figure 1, Table 2 |
| Polyominoes, 4 agents | 84.2 without web, 89.4 with web (previous best 87) | Table 2, B.1 |
| Tasks with a final-score win | 11 of 11 (new records on 8; the abstract says 10) | Table 1 |
| Knowledge ablation, kernel | 1,350 to 1,601 cycles (+18.6%) | Table 3 |
| Team against best of 4, kernel | 1,103 against 1,180 cycles | Table 3 |
| Cross-agent parent, kernel | 36% of attempts, 17% improved against 9% | Section 4.4.2 |
| Heartbeat defaults | reflect 1, consolidate 10, pivot 5 | Table 7 |
| Grader time limit | 300 s by default | Appendix C.2 |
| Agent restart delay | within 5 s | Appendix C.6 |
A sketch of two pieces, written for this lesson, not taken from the authors' code: the evaluation record with its status rule, and the heartbeat trigger logic. The numbers match Chapters 4 and 5.
python import json, hashlib, time from dataclasses import dataclass, asdict @dataclass class Attempt: commit_hash: str agent_id: str title: str score: float | None status: str # improved | baseline | regressed | crashed | timeout parent_hash: str | None def status_of(score, best, lower_is_better): if score is None: return "crashed" if best is None or score == best: return "baseline" if best is not None else "improved" better = score < best if lower_is_better else score > best return "improved" if better else "regressed" def coral_eval(hub, agent, code, msg, grader, best, parent, lower=True, timeout=300): h = hashlib.sha1((agent + code + str(time.time())).encode()).hexdigest()[:8] # 1 commit try: score = grader(code) # 2-3 hidden grader st = status_of(score, best, lower) # 4 status except TimeoutError: score, st = None, "timeout" a = Attempt(h, agent, msg, score, st, parent) (hub / "attempts" / f"{h}.json").write_text(json.dumps(asdict(a))) # 5 record hub.joinpath("eval_count").write_text(str(int(hub.joinpath("eval_count").read_text() or 0) + 1)) # 7 count return a class Heartbeat: def __init__(self, reflect=1, consolidate=10, pivot=5): self.k = dict(reflect=reflect, consolidate=consolidate, pivot=pivot) self.stall = {} # per-agent evals since last improvement def after_eval(self, agent, n_local, n_global, improved): self.stall[agent] = 0 if improved else self.stall.get(agent, 0) + 1 fire = [] if n_local % self.k["reflect"] == 0: fire.append("reflect") if n_global % self.k["consolidate"] == 0: fire.append("consolidate") s, p = self.stall[agent], self.k["pivot"] if s >= p and (s - p) % p == 0: fire.append("pivot") return fire # prompts to append to the agent's session
CORAL belongs to the line of work that uses a language model inside an evaluator-guided loop. Start with FunSearch, then AlphaEvolve, then the open systems the paper compares against. It is also a case of self-improving agents, the topic of the lecture Self-Evolving AI, where this paper is a reading. Its memory design links to agent memory, and its team design to multi-agent systems. The harness side of long-running agents is in harness evolution.
Now press Present or Teach and explain from memory how one coral eval works, why the grader is hidden, what each heartbeat does, and why four agents with a lower improvement rate still win. Then go back to the race and watch it again.
Credit: the paper is by Ao Qu, Han Zheng, Zijian Zhou, Yihong Tang, Shao Yong Ong, Fenglu Hong, Kaichen Zhou, Chonghe Jiang, Minwei Kong, Jiacheng Zhu, Xuan Jiang, Sirui Li, Yihao Yan, Bryan Kian Hsiang Low, Jinhua Zhao, Cathy Wu and Paul Pu Liang, from MIT, NUS, MiniMax, McGill, Stanford, SambaNova, Meta, Amazon, Microsoft and the Singapore-MIT Alliance for Research and Technology (COLM 2026). Figures and numbers here come from that paper. Toy devices are labelled as toys.