You can tune five different things around a model: the prompt, the context, the workflow, the harness code, or the optimizer that writes the harness. Each step up is a bigger object, searched by a more general method.
Pick a rung and watch the object change shape, from a string to a playbook to a graph to a repository. Then we build, rung by rung, the systems that optimize each one, and you run a workflow search yourself in Chapter 8.
You need a little Python, what a probability is, and the idea of a harness from Harness Engineering. We build the rest from zero.
Based on the harness optimization sections of Lilian Weng, Harness Engineering for Self-Improvement (Lil'Log, 2026), and the papers it cites: ACE, MCE, Meta-Harness, the AI Scientist, ScientistOne, Autodata, ADAS and AFlow. Every idea is re-taught here in our own words and devices.
The five rungs and their order come from Weng (2026). The two bars are a picture of her claim that objects get more complex and methods more general as you climb; their heights are illustrative.
Chapter 0
Sort every harness method by the one thing it changes, and pick the lowest rung that fixes your failure
Your coding agent fails 30 percent of its tasks. You have one week to improve it. You could sharpen the system prompt. You could change what enters the context window. You could add a review step, rewrite the harness code, or write a program that rewrites the harness for you.
Those five choices are a sequence. Weng names it in her 2026 survey: the object being optimized, the thing that differs between one version of the system and the next, moves from instruction prompts to structured context, then to workflow, harness code and optimizer code.
| Rung | Object | What changes | Methods here |
|---|---|---|---|
| 1 · Prompt | a string | the words | prompt engineering |
| 2 · Context | a playbook, a set of files | what enters, merges, leaves | ACE, MCE (Ch 2, 3) |
| 3 · Workflow | the shape of the run | which steps, in what order, with which checks | by hand: AI Scientist, ScientistOne, Autodata (Ch 5); by search: ADAS, AFlow (Ch 6, 7) |
| 4 · Harness code | the program around the model | its source code | Meta-Harness (Ch 4) |
| 5 · Optimizer code | the loop that improves the harness | the improver itself | next lesson |
Two things grow as you climb. The object gets bigger: a string, then a document, then a graph, then a repository. The method gets more general: a search over code does not care what the code is for. Weng ties the climb to model strength. Stronger models make bigger objects safe to hand over.
The rungs have soft edges. Meta-Harness optimizes harness code with an optimizer that is itself a harness, so it stands on rungs 4 and 5 at once.
A higher rung costs more to build and to evaluate. So read your failures first, then pick the lowest rung that fixes them. This rule of thumb is ours, not Weng's.
Each chip is a symptom you might see in your logs. Pick one and the ladder lights the rung that owns it.
The symptom-to-rung map and the cost bar are an illustrative rule of thumb made for this page.
The failure, as symptom, measurement and fix. Symptom: you built a search over workflows, and the agent still misreads the same instruction. Measurement: label 50 failed runs by cause and count each rung's share. Fix: spend the week on the rung with the largest share.
Chapter 1
Count what a growing transcript costs, then watch repeated summaries erase the detail that mattered
Your agent debugs a repository for 100 turns. Each turn adds a tool output and a reply. The plain harness appends both and sends the whole transcript every turn.
Call the tokens one turn adds c and the number of turns n. Turn t sends t times c tokens. Call the total billed over the run B.
B equals c times n times n plus one, over two.
Add the cost of every turn, c, 2c, up to n times c. The sum of 1 to n is n(n + 1) / 2, so B grows with n squared.
With made-up numbers: c = 2,000 tokens and n = 100 turns. B = 2,000 × 5,050 = 10,100,000 tokens. The final transcript is only c × n = 200,000 tokens, so you pay for it 50.5 times.
Warm is the window at the last turn. Yellow is everything billed. Drag the turns.
Illustrative: 2,000 tokens a turn, no caching, no trimming.
The obvious fix is to compact: ask the model to rewrite the context as a shorter summary every few turns. Follow one fact through three rewrites:
| Rewrite | What the context says | What was lost |
|---|---|---|
| 0 | "The flaky test fails only when CI runs in UTC+9, because the date assertion runs at local midnight." | nothing |
| 1 | "The flaky test is timezone dependent (UTC+9, midnight)." | the cause |
| 2 | "There are timezone test issues." | which zone, which test |
| 3 | "Timezone issues exist." | everything you can act on |
The ACE paper names both effects. Context collapse is detail eroding under repeated rewriting. Brevity bias is its direction: a summarizer drops specific insight for short, general statements. Call the share of detail one rewrite keeps r, the number of rewrites n, and the share left at the end F.
F equals r to the n.
Each rewrite keeps the share r of its input, and the next rewrite starts from what is left. So multiply r by itself n times.
With made-up numbers: r = 0.9 and n = 10. F = 0.910 ≈ 0.35. Two thirds of what the agent learned is gone, and no single rewrite looked bad.
Seven insights sit in context. With rewrite all, every rewrite touches all of them; with itemized, only the edited one. Drag the rewrites.
Illustrative toy with made-up insights and keep rate.
The paper saw this for real. On the AppWorld agent benchmark, a fully rewritten context held 18,282 tokens and scored 66.7 at step 60. One step later it collapsed to 122 tokens and scored 57.1, below the 63.7 of an agent that never adapted (Zhang et al., 2025, section 2.2).
The failure, as symptom, measurement and fix. Symptom: the agent re-derives last week's fix. Measurement: after each compaction, count how many key facts survive word for word. Fix: store facts as separate items and never rewrite the untouched ones (Chapter 2).
Chapter 2
Split the work into three roles and let plain code merge small itemized updates, so nothing untouched can decay
A sports team keeps a playbook. Players play, an analyst watches the tape, and an editor updates the binder. Nobody rewrites the whole binder after each game. The editor changes one page.
Agentic Context Engineering (ACE; Zhang et al., 2025, ICLR 2026) builds context the same way. The context is a playbook: a list of bullets, each with an identifier (a stable name such as api-rate-limit) and a description (the insight). Three roles maintain it.
| Role | Reads | Writes |
|---|---|---|
| Generator | the task and the current playbook | a trajectory: one full attempt at the task |
| Reflector | trajectories, both successes and failures | candidate insights |
| Curator | the insights | small updates, called deltas: (identifier, description) pairs |
The key choice: the Curator does not rewrite a full prompt. Ordinary code merges its deltas. A new identifier is appended. A known identifier updates that one entry. Every other bullet passes through as the same bytes. From time to time a refinement pass removes near-duplicates by comparing bullets with semantic embeddings.
pythondef curate(playbook: dict, deltas: list) -> dict: # deterministic merge: plain code, no model call for d in deltas: # d = {"id": str, "desc": str} if d["id"] in playbook: playbook[d["id"]] = merge(playbook[d["id"]], d["desc"]) # update that one entry else: playbook[d["id"]] = d["desc"] # append a new insight return playbook # every other entry: untouched bytes def ace_step(playbook, task, llm): traj = generate(task, playbook, llm) # Generator deltas = reflect(traj, llm) # Reflector: the only creative step return curate(playbook, deltas) # Curator's deltas, merged by code
Green rollouts passed, red failed; both teach something. A repeat insight raises its counter. Switch to rewrite and run again.
Illustrative toy: the insights are made up, and the rewrite mode drops each existing item with a 12% chance per rollout. ACE's real deltas also carry helpful and harmful counters.
Count the work in one step. With made-up numbers: the playbook holds 220 bullets of about 80 tokens, so 17,600 tokens. A delta touches 2 bullets. The merge regenerates nothing else. A full rewrite asks a model to re-emit all 17,600 tokens to apply the same two changes, and each token is a chance to drop detail.
The paper reports gains of 10.6 percent on agent tasks and 8.6 percent on finance tasks over strong baselines, with lower adaptation cost. It learns from execution feedback, so it needs no labels.
The failure, as symptom, measurement and fix. Symptom: two runs write opposite claims under one identifier, such as "cap retries at 3" and "cap retries at 5". Measurement: log each update that reverses a description. Fix: send conflicts to the periodic refinement pass, not to the per-step merge.
ACE's limit sets up the next chapter. The playbook learns, but its rules are fixed by hand: bullets, identifiers, deterministic merges. If a task needs a code library instead of bullets, ACE cannot find that out.
Chapter 3
Run two loops: an inner one that tunes the context, and an outer one that picks the recipe on data the inner loop never saw
ACE fixes the recipe and improves the dish. Meta Context Engineering (MCE; Ye et al., 2026) also changes the recipe. It separates the mechanism, the way context gets built, from the artifact, what the context contains.
The mechanism is a skill: static parts (prompts, knowledge bases, code libraries) plus dynamic operators (search, select, filter, format). In MCE a skill is a folder with a SKILL.md file. Both loops run as coding agents with Read, Write, Edit, Bash, Glob, Grep and TodoWrite.
Two scores drive the loops. Call the skill s and a context it can build c. Call the score on training tasks Jtrain and the score on held-out validation tasks Jval.
c-star-s equals the argmax over c of J-train of c, given s.
Hold the skill s fixed. Let the base agent edit the context files, run training tasks and keep the edits that raise J-train. The context it ends with is c-star-s.
With made-up numbers: skill C starts at J-train 0.52. After a few rounds of edits it reaches 0.84, so c-star-C is the context that scored 0.84.
s-star equals the argmax over s of J-val of c-star-s.
For each skill s, take its finished context c-star-s. Score it on the validation tasks. Keep the skill with the highest J-val.
With the made-up skills below: J-val is 0.79 for A, 0.64 for B and 0.82 for C. The argmax is C, so s-star is C, though B had the best J-train.
| Skill (made up) | Jtrain | Jval | Gap |
|---|---|---|---|
| A · full log, keyword search | 0.81 | 0.79 | 0.02 |
| B · memorize per-task hints | 0.88 | 0.64 | 0.24 |
| C · bullets plus top-k retrieval | 0.84 | 0.82 | 0.02 |
Why Jval outside? The inner loop squeezes the training tasks, so Jtrain flatters. Skill B learned their quirks: meta-overfitting, where the mechanism, not the weights, fits the training set. The 0.24 gap gives it away.
Four skills with train and measured validation scores. Choose the judge, then shrink the validation set and redraw it.
Illustrative toy. Each skill has a hidden score on new tasks; the measured J-val is that score plus binomial sampling noise from the number of validation tasks.
New skills come from agentic crossover. A meta-level agent reads the history of past skills, their contexts and both scores, then writes a new skill that combines their strengths. The paper calls the loop a history-informed (1 + 1) evolution strategy. Across five domains it reports 5.6 to 53.8 percent relative gains over earlier context engineering methods, 16.9 percent on average.
The failure, as symptom, measurement and fix. Symptom: the kept skill wins validation once, then falls on new tasks. Measurement: rescore the top skills on a fresh draw. Fix: more validation tasks, or repeated scoring.
Chapter 4
Let a coding agent propose whole harness programs, read the history with grep, and keep every candidate nobody beats on both cost and score
A harness is the code that decides what to store, retrieve and show to the model. Meta-Harness (Lee et al., 2026) searches over that code. It is a harness for optimizing harnesses.
grep and cat, never as one giant prompt.Step 4 is the file-system memory pattern from Harness Engineering, one level up: the history is too big for a prompt, so the proposer searches it.
A harness has two scores you care about: accuracy, where higher is better, and token cost, where lower is better. Call one candidate A and another B. A dominates B when it is at least as good on both and strictly better on one.
A dominates B if the cost of A is at most the cost of B, and the score of A is at least the score of B, with at least one of the two strict.
Compare candidate A with candidate B on both axes. If A is no worse on cost and on score, and better on one, drop B. The candidates nobody dominates form the Pareto frontier.
With made-up numbers (cost in thousands of tokens, score): A (9, 0.74), B (30, 0.73), C (40, 0.82), D (22, 0.78), E (45, 0.80). D dominates B: 22 ≤ 30 and 0.78 > 0.73. C dominates E: 40 ≤ 45 and 0.82 > 0.80. The frontier is A, D, C.
Why a frontier and not one winner? The best harness depends on the budget. Under 25,000 tokens a task, the answer above is D. With no limit it is C. One search answers both questions.
Each dot is a harness: cost across, score up. Green dots form the frontier. Propose batches, then set a budget.
Illustrative toy: candidates are drawn near the current frontier with random gains. The strong start mirrors the TerminalBench-2 runs, which began from Terminus 2 and Terminus-KIRA.
The results, as reported. On online text classification, the found harnesses beat ACE by 7.7 points while using 4 times fewer context tokens. On TerminalBench-2, search started from two strong hand-built harnesses, Terminus 2 and Terminus-KIRA. With Claude Opus 4.6 the found harness passed 76.4 percent of tasks, against 74.7 for Terminus-KIRA.
The failure, as symptom, measurement and fix. Symptom: a harness tops the benchmark it was searched on and slips on new tasks. Measurement: score the frontier on tasks the search never saw. The TerminalBench-2 search and final score used the same 89 tasks; the authors say so and audit for leaks. Fix: keep a held-out split whenever the benchmark is big enough; the RRSI lesson measures this overfit.
Chapter 5
See what experts build by hand on rung 3, why receipts matter, and how a data loop keeps problems at the edge of a model's skill
Rung 3 changes the shape of the run. Before anyone searched this space, experts drew workflows by hand. Three systems from Weng's survey show what that buys.
| System | The workflow | Its point |
|---|---|---|
| AI Scientist (Lu et al., 2026, Nature) | propose ideas, write code, run experiments, analyse, write the paper, peer review | a fixed six-stage research pipeline |
| ScientistOne (Meng et al., 2026) | literature review, solution search, writing, each step keeping an evidence chain | every claim must trace to its evidence |
| Autodata (Kulikov et al., 2026) | a challenger, a weak solver, a strong solver and a verifier | make training data at the right difficulty |
Every arrow in a handcrafted pipeline is a human decision. That buys reliability and costs flexibility: if good research sometimes needs analysis before more coding, a fixed pipeline cannot find that out.
ScientistOne attacks a different failure: a manuscript that reads well but is not true. Its Chain-of-Evidence audit runs four checks on any system's papers: score verification, specification violations, reference verification and method-code alignment. The paper reports zero hallucinated references out of 337, 12 of 12 scores verified and 14 of 15 methods matching their code. Some baselines hallucinated up to 21 percent of their references.
Autodata keeps a problem only when the strong solver passes it and the weak solver fails it. Easy problems teach the weak model nothing. Problems both fail give no correct answer to learn from. Call the chance the strong solver passes pS, the chance the weak solver passes pW, and the chance a new problem lands in the keep band Pgold.
P-gold equals p-S times one minus p-W.
Take the chance the strong solver passes, p-S. Multiply it by the chance the weak solver fails, one minus p-W. This assumes the two solvers fail for unrelated reasons.
With made-up numbers: at this difficulty p-S = 0.9 and p-W = 0.2. P-gold = 0.9 × 0.8 = 0.72, so about 7 problems in 10 are kept.
The solvers' and verifier's feedback updates the challenger's prompt. Too many problems both solve: push harder. Too many both fail: ease off.
Each curve is a solver's pass chance; green is P-gold. Drag the difficulty, then Run with the controller on and off.
Illustrative toy: both pass curves are made-up logistic curves, and the controller nudges difficulty by the share of both-pass minus both-fail outcomes over the last 20 problems.
Weng adds a caution. The synthesized problems fine-tune weak solvers, not the strong one, so nothing in the data goes beyond what the strong model can already do. She reads it as closer to indirect distillation than to recursive self-improvement. The Autodata paper also trains the data-making agent itself, which is a separate loop.
The failure, as symptom, measurement and fix. Symptom: the kept band fills with problems that look hard but have a shortcut. Measurement: hand-check a sample of kept problems against the verifier's verdicts. Fix: strengthen the verifier first; the loop is only as honest as its judge.
Chapter 6
Treat workflow design as search, keep an archive of working agents, and let a meta-agent program the next one
Handcrafted workflows inherit their designers' blind spots. Weng's next move: treat workflow design as a search problem, and let an algorithm find good designs.
ADAS, Automated Design of Agentic Systems (Hu, Lu and Clune, 2025), does this with Meta Agent Search. A meta-agent is an agent whose job is to write other agents.
Why code and not prompt text? Code runs, so every archive entry can be scored again. Code composes, so a new agent can wrap one agent's voting in another's retry loop. And the abstract's own argument: programming languages are Turing complete, so code can express any workflow.
pythonarchive = [Agent("CoT", cot_code), Agent("SelfRefine", sr_code)] # seeds, with scores for k in range(MAX_ITERS): desc = meta_agent("Archive and scores:\n" + render(archive) + "\nDescribe a new workflow.") code = meta_agent("Implement it as code:\n" + desc) for _ in range(2): # two self-refine passes crit = meta_agent("Is this new and correct?\n" + code) code = meta_agent("Revise using the critique:\n" + crit + code) score = evaluate(code) # the expensive step if is_successful(score, archive): archive.append(Agent(desc, code, score))
A worked micro-run, with made-up scores. The seeds score 0.62 (CoT) and 0.66 (self-refine). Our toy rule keeps a candidate if it beats the average of its two parents.
| Iteration | Parents | Candidate | Score vs parent average | Verdict |
|---|---|---|---|---|
| 1 | CoT, self-refine | CoT with voting | 0.69 > 0.640 | kept |
| 2 | self-refine, CoT with voting | reflection wrapper | 0.63 < 0.675 | dropped |
| 3 | CoT with voting, self-refine | 3-sample ensemble | 0.73 > 0.675 | kept |
Each step draws two parents from the archive, writes a candidate and scores it. Watch the best score climb in steps, not smoothly.
Illustrative toy: candidate scores are drawn near the better parent, with rare jumps; the keep rule is ours. ADAS evaluates on real benchmarks across coding, science and math.
The failure, as symptom, measurement and fix. Symptom: the archive fills with near-copies of the current best. Measurement: compare each new description with its nearest archive entry. Fix: the novelty check in the self-refine passes. Watch the budget too: every iteration pays for a full benchmark run, which costs far more than writing the code.
Chapter 7
Make a workflow a graph, grow a tree of edited versions, and choose what to edit next with a mix of merit and chance
ADAS searches all programs with loose guidance. AFlow (Zhang et al., ICLR 2025) narrows the space and adds a search algorithm. A workflow is a graph: each node is an LLM call, and each edge is code that decides what flows where.
The search is Monte Carlo tree search (MCTS). The root is a starting workflow. Each child is its parent with one edit. Each node carries a score from real runs.
Why not always edit the best node? Scores are noisy and the best node may be a dead end. AFlow mixes a fair lottery with a strong preference for high scores. Call the number of candidate workflows n, workflow i's score si, the best score smax, the lottery share λ and the sharpness α.
P of i equals lambda times one over n, plus one minus lambda times e to the alpha times s-i minus s-max, over the sum over j of e to the alpha times s-j minus s-max.
Give each workflow a merit weight that falls off fast below the best score. Turn the weights into shares that add to 1. Blend those shares with a fair lottery, lambda of the lottery and one minus lambda of merit.
With made-up scores in points, 62, 71, 58 and 74, and the paper's λ = 0.2, α = 0.4: the weights are e−4.8 = 0.008, e−1.2 = 0.301, e−6.4 = 0.002 and 1, summing to 1.311. The best workflow gets 0.05 + 0.8 × 1/1.311 = 0.66. The worst still gets 0.05 + 0.8 × 0.0013 = 0.051.
So the leader gets about two picks in three, and every workflow keeps a floor of λ/n = 0.05, enough to revisit an unlucky 58. The score scale matters: AFlow's released code multiplies scores by 100 before this step.
Grey is the lottery floor; purple is the merit share. Move the knobs, then sample 100 picks.
The formula and the defaults λ = 0.2, α = 0.4 are from the AFlow paper (equation 3). The four scores are made up.
On six benchmarks (HumanEval, MBPP, MATH, GSM8K, HotpotQA and DROP), the paper reports workflows 5.7 percent better on average than hand-designed methods and 19.5 percent better than earlier automated ones, ADAS among them. A smaller space, searched with statistics, beat a larger one searched loosely.
The failure, as symptom, measurement and fix. Symptom: set λ = 0 and a large α, and every edit lands on one branch. Measurement: count how many distinct nodes were expanded in the last 10 rounds. Fix: keep the lottery floor.
Chapter 8
Race three search strategies on one hidden landscape and see why averaged scores beat single readings when evaluation is noisy
Now run a search yourself. A workflow is a chain of 1 to 4 operators from a library of six: direct, CoT, refine, ens-3 (three samples and a vote), verify and decompose. That gives 6 + 36 + 216 + 1,296 = 1,554 workflows. Each has a hidden true quality.
You never see the true quality. Each evaluation returns it plus noise, as a finite test batch does. Three strategies compete with the same budget of evaluations:
| Strategy | Each step | It believes |
|---|---|---|
| Random | evaluate a fresh random workflow | the best single reading so far |
| Greedy | change one operator of the champion; switch if the reading is higher | the champion's one reading |
| Averaging | soft mixed selection over the top workflows; re-evaluate a workflow once, then edit it | a mean over repeated readings |
Averaging borrows AFlow's two habits: sampled selection, and repeated evaluation. Why repeat? Call the noise of one reading σ, the number of readings averaged m, and the noise left in their mean SE, the standard error.
S-E equals sigma over the square root of m.
Evaluate the same workflow m times and average. Independent errors partly cancel, so the error of the mean is the error of one reading, sigma, divided by the square root of m.
With made-up numbers: σ = 0.12 (high noise) and m = 5, AFlow's repeat count. SE = 0.12 / 2.236 ≈ 0.054, so the mean is 2.2 times sharper than one reading.
The chart plots the true quality of each strategy's current champion, a number no strategy can see. Pick a noise level and a budget, then Run.
Illustrative toy landscape made for this page. The lines are one seeded run; the averages in the read-out are over 200 seeds with the same settings.
Three experiments. Low noise, budget 60: greedy does well, because local moves on honest readings work. High noise, budget 100: averaging wins and greedy falls behind random. Budget 15: random wins, because averaging has no time to repeat anything. Structure needs budget to beat luck.
Why greedy breaks: one lucky reading crowns a champion, and that inflated number becomes a bar no honest challenger clears. The read-out shows what greedy believes against the truth.
Each operator pulls the workflow's quality half of the way toward its own level: direct 0.45, CoT 0.62, refine 0.60, ens-3 0.66, verify 0.64, decompose 0.58, from a start of 0.35. Three ordered pairs earn a bonus: CoT then refine (+0.07), refine then verify (+0.06), decompose then ens-3 (+0.05). Repeating an operator back to back costs 0.04. The best chains, such as CoT, refine, verify, ens-3, reach 0.756.
Chapter 9
Keep the methods, the numbers and the three questions that sort any new paper onto the ladder
Every method here is defined by the object it changes, who proposes changes, and who judges them.
| Method | Object (rung) | Proposes | Judges | Key number |
|---|---|---|---|---|
| ACE | context playbook (2) | Reflector, merged by code | execution feedback | +10.6% agents, +8.6% finance |
| MCE | skill and context (2 to 3) | meta-agent crossover | J-train inside, J-val outside | 5.6 to 53.8% relative, mean 16.9% |
| Meta-Harness | harness code (4) | coding agent | several objectives, Pareto | +7.7 points over ACE, 4x fewer tokens |
| AI Scientist | fixed workflow (3) | human experts | a peer review stage | 6 stages |
| ScientistOne | fixed workflow (3) | human experts | Chain-of-Evidence audit | 0 of 337 references hallucinated |
| Autodata | challenger prompt (1 to 3) | challenger agent | verifier and two solvers | keep: strong passes, weak fails |
| ADAS | agent programs (3) | meta-agent, in code | benchmark runs | 2 self-refine passes |
| AFlow | workflow graph (3) | LLM edits in a tree | 5 validation runs each | +5.7% vs manual, +19.5% vs automated |
| Equation | Read it as |
|---|---|
| B = c · n(n + 1) / 2 | appending makes the bill grow with turns squared |
| F = rn | repeated summaries lose detail by multiplication |
| c*s = argmaxc Jtrain(c ; s) | tune the context on training tasks |
| s* = argmaxs Jval(c*s) | pick the skill on held-out tasks |
| A ≻ B | no worse on cost and score, better on one |
| Pgold = pS(1 − pW) | the share of problems in the keep band |
| P(i) = λ/n + (1 − λ) · softmax(αs)i | a lottery floor plus a sharp merit share |
| SE = σ / √m | averaging m readings cuts noise by √m |
pythonimport numpy as np def soft_mixed(scores, lam=0.2, alpha=0.4): # scores in points, AFlow eq. 3 s = np.asarray(scores, float) w = np.exp(alpha * (s - s.max())) # 1 for the best, smaller below return lam / len(s) + (1 - lam) * w / w.sum() def pareto(cands): # cands: [(cost, score, name)] return [a for a in cands if not any( b[0] <= a[0] and b[1] >= a[1] and (b[0], b[1]) != (a[0], a[1]) for b in cands)] print(soft_mixed([62, 71, 58, 74]).round(3)) # [0.055 0.234 0.051 0.66 ] print(pareto([(9,.74,"A"),(30,.73,"B"),(40,.82,"C"),(22,.78,"D"),(45,.80,"E")])) # A, C, D
Now press Present or Teach and explain from memory the five rungs, the two loops of MCE and the soft mixed selection rule. Then go back to the ladder and say, for each rung, which chapter's method changes it.
This lesson re-teaches the harness optimization sections of Lilian Weng, Harness Engineering for Self-Improvement (2026). Papers: Zhang et al., ACE (2025); Ye et al., MCE (2026); Lee et al., Meta-Harness (2026); Lu et al., The AI Scientist (Nature, 2026); Meng et al., ScientistOne (2026); Kulikov et al., Autodata (2026); Hu, Lu and Clune, ADAS (2025); Zhang et al., AFlow (2025); Madaan et al., Self-Refine (2023). The toy numbers and devices are our own.