Learning That Isn't Shared Is Drift
12 min
Confidence the levers are real and two are in use; the batch-versus-autonomous recommendation is a design I have not run, and the measurement consequence is argued rather than measured — but the divergence itself is now observed, in two shipped deployments that disagree about a package they both import
“A system must have an aim. Without an aim, there is no system.” — W. Edwards Deming, The New Economics (1993)
There is a moment in building any agent system where the hand-tuning starts to feel like the bottleneck, and you wonder whether the thing can improve itself. It can, partly, in three specific ways — and the question that decides whether any of it compounds is not which lever you pull. It is whether what gets learned in one place reaches everywhere else.
This is drawn from building a multi-stage code reviewer, described across the three parts of Building an Agent Graph. The levers assume you have what those end with: nodes behind typed contracts from [Where to Cut](/notes/graph- guide/), and something to measure against from [How You Know](/notes/graph- guide-how-you-know/).
Bottom line up front
- Swapping the model costs no rewiring once a node’s contract is typed JSON — which is not the same as free. The schema fixes the shape of the output, not its quality, latency or price, so every swap still has to be evaluated against the node’s objective.
- Tuning the prompt has the most headroom, and a node is a better target than a whole prompt because its objective is narrower.
- Retraining a node is legal by construction and needs data you probably do not have. The gate is the nearest source — a refuted lead is a labelled negative — but only if the refusal is trustworthy and you kept the input and the reason alongside it.
- Rules that tune themselves need the promotion gate to sit outside the loop that generated the candidate, because a loop scoring its own output cannot see what it stopped finding.
- Improve on a side track, never in the request path. A system that adjusts itself mid-run is a different system at the end of the run than at the start, and nothing measured across it means anything.
- Batch-and-version shares the learning; autonomous loops distribute it. Learning that is not shared is not an asset, it is drift.
Say you have a working multi-stage system — nodes behind typed contracts, an eval corpus, a sense of what good looks like. All of it tuned by hand. The next question is whether it can improve itself, and there are three levers, in increasing order of how much they are actually demonstrated.
Make the model swappable behind the schema. The schemas already bought you this. A node whose contract is typed JSON does not care what produced it, so the model is a parameter. A cheap one on mechanical adjudication, an expensive one on judgment, a different one next quarter when the prices move. Nothing about the graph changes. If you have done the schema sections of Building an Agent Graph you have this already and may not have noticed.
Tune the prompt behind the same interface. Same argument, slower loop, and usually the lever with the most headroom. It has its own how-to — Tune the Prompt Before You Split It — and what matters here is that a node is a better tuning target than a whole prompt, because its objective is narrower. A scout is tuned for recall and a deep pass for precision, and once they are separate calls you can optimise each against the error budget it actually has instead of one compromise serving both.
Substitute a trained model at a node. Legal by construction: a fine-tune emitting the same schema drops into the same slot. This build has not done it, so take it as a design property rather than a result. What the interface does not tell you is whether you have anything to train on. The usual answer is that your artifacts record the decision and not what you knew when you made it — see [You Can’t Fine-Tune Yourself](/posts/encode-vs- train/). The one place this build mints trainable material is the reject pile — every refuted lead is a hard negative sitting exactly at the boundary, which is Train on What the Gate Throws Away. With one caveat that post and this one both owe you: a refutation by the current reviewer is not an independently verified negative. It is the reviewer’s own verdict. Train on it and you are teaching the next version to reproduce this version’s false negatives, confidently, with the boundary drawn exactly where the old one drew it.
Rules that update themselves is the one to be careful about. Most attractive, least supported here. The honest version is a controlled update loop rather than an autonomous one: change one rule or one node, run repeated draws against the pinned cases and a held-out set, and promote only on a measured improvement. The promotion gate is the whole thing, because a loop that scores its own output cannot see what it stopped finding. That is You Can’t Grade Your Own Misses applied to the improvement loop itself, and it is why the gate needs a signal from outside the loop rather than a better judge inside it.
Improve on a side track, not in the request path
Whatever the lever, the improving should not happen inside the run that someone is waiting on. The production path emits; a separate loop consumes what it emitted. That is what §9’s per-item record is for — it is the material the improvement loop reads, and a graph that keeps nothing has nothing to improve from no matter which lever you pick.
Keeping it off the request path also keeps the measurement honest. A system that adjusts itself mid-run is a different system at the end of the run than at the start, so anything measured across that boundary is pooling two systems. Recoverable if you tagged the change and can split the run; lost if you did not.
Two shapes, and the tradeoff between them
Batch, then version. Collect the material, run the improvement loop over all of it at once, gate the result, and ship it as a new version. Everyone moves to the same artifact at the same time.
Autonomous loops. Each deployment improves against its own traffic, continuously, without a release.
They trade the same thing in opposite directions, and the thing is shared learning versus distributed learning.
| Batch → version | Autonomous loops | |
|---|---|---|
| Who gets the improvement | everyone, at once | whoever generated it |
| Learning rate | one step per release | continuous, in parallel, everywhere |
| Reproducibility | a version number explains a result | two runs can differ and both be “current” |
| Rollback | revert one artifact | there is no one artifact |
| Failure mode | slow; good signal waits for the train | silent divergence |
The batch version’s weakness is latency: a real improvement sits in a branch while people keep hitting the old behaviour. The autonomous version’s weakness is worse and less visible. Learning that isn’t shared isn’t an asset, it’s drift. Two engineers on “the same” reviewer get different findings on the same diff, and a rule that improved on one machine never reaches the other. Worse, your corpus stops measuring one system, which quietly invalidates every comparison in Part III — see the guide’s section on fidelity and determinism.
The version I would build is both, with the gate in the middle — and it is a design I have not run, so read it as a proposal rather than a result. Let the distributed loops propose — they see far more real traffic than any batch you could assemble, and that is their whole advantage. Promote centrally, on the measured comparison, and ship the result as a version everyone moves to. Distribute the learning, centralise the promotion. That also puts the promotion gate outside the loop that generated the candidate, which is the condition the previous section said it needed.
None of that shape is mine, and I should say so before it reads as a finding. Learn locally, aggregate centrally, redistribute one artifact is the shape of federated learning, worked over since 2016. Treat it as an analogy rather than the same mechanism: federated learning aggregates locally trained model updates, and what is being collected here is candidate changes for central evaluation. The improvement loop itself — acquire experience, select from it, optimise, redeploy — is the closed lifecycle two 2026 surveys already lay out. And golden sets, failure archives, promotion criteria and canary rollouts are established practice for shipping prompt changes. If you are building this, read those rather than this section.
What I have not found stated anywhere, and what the rest of this guide makes visible, is the measurement consequence. The literature on distributed improvement worries about accuracy, privacy and convergence; the CI-for-prompts writing worries about regressions. Neither says the thing Part III makes unavoidable: once instances diverge, your corpus stops measuring one system, and unless every run is tagged with the version that produced it, the numbers quietly stop comparing. That caveat matters — versioned runs can be separated and compared, and experiment-tracking tools exist for exactly that, so the failure is pooling unversioned results rather than divergence itself. What remains is that an autonomous loop makes the version a moving target nobody declared, which is the state in which pooling happens by default. That is argued rather than measured.
One divergence, observed — and here is what to go and look at. This build ships override files for two deployments of the same reviewer. They have diverged, and the sharpest evidence is not a preference but an identifier: the two files use different rule IDs for the same rules. Both map a rule to the same utility for the same reason, under different numbers, because they are pinned to different versions of the base rule set and only one deployment followed the renumbering. You can read the drift straight off the identifiers, which makes it the cheapest check available to you — diff the two config files and see whether they still agree about what things are called.
The rest runs one way. One file is simply further along: a far longer table of rules its CI already covers, and a convention written down because a specific class of bug caused incidents, which is the most expensive kind of learning there is and it never reached the other deployment. The two even disagree about a helper from a package they both import, neither file aware of the other.
That is an instance, not a cost. I went looking for the cost and did not find one: no firing in the corpus landed on a rule the two files actually disagree about suppressing. So the divergence is real and visible, and on the one corpus I can measure it on, it charged nothing. The honest version is that the failure mode exists in this build and has not yet cost anything I can point to.
What this build can and cannot say about that. The matrix pilots came back null twice, and the second null is the worse one. The first was a single piloted rule that never flipped, so the mechanism had nothing to fix. The second ran across seventeen rules on real pull requests, where there was plenty to fix, and the reviewer disagreed with itself just as often afterwards — the instability moved between rules rather than going away. The improvement I saw first was an artifact of having chosen the rules to fix by measuring which ones were broken. The compiler that would derive the rule artifacts from one source does not exist (the guide’s one-source-of-truth section). And that corpus measures stability — whether the reviewer agrees with itself, not whether it is right. The corpus with labelled answers on it is still four pull requests with no oracle (the guide’s eval section), which is what bounds every recall number in this build. None of that refutes automatic tuning. It means this system has not demonstrated it, and a section claiming otherwise would be the exact failure the rest of this guide is written against.
How sure I am: the first two levers are in use — models are swapped behind schemas routinely, and the prompt tuning has its own how-to. The third is untried here. The batch-versus-autonomous recommendation is a design I have not run, and the measurement consequence at the end of it is argued rather than measured. The boundaries in the last section are the honest frame for all of it: the matrix pilots came back null twice, the compiler that would derive the rule artifacts does not exist, and the corpus with labelled answers on it is four pull requests with no oracle. The divergence instance is new and is the one thing here that moved — two shipped deployments have diverged on a package they both import, which is an observed case of the failure this guide describes, and still not a measurement of what it cost. None of that refutes self-improvement; it means this build has not demonstrated it.
Sources
- Federated learning — learn locally, aggregate centrally, redistribute one artifact. Worked over since 2016, and the structure of the batch-plus-autonomous recommendation here.
- Self-Improvements in Modern Agentic Systems: A Survey (arXiv:2607.13104, July 2026) and Self-Improvement of Large Language Models: A Technical Overview and Future Outlook (arXiv:2603.25681, March 2026) — the closed improvement lifecycle of acquire, select, optimise, redeploy. The loop described here is a restatement of that, not a discovery.
- Regression gates for prompt changes — golden sets, failure archives, promotion criteria and canary rollouts, established practice in the CI-for-prompts writing.
- Experiment tracking — the reason the divergence claim is narrowed: versioned runs can be separated and compared, so the failure is pooling unversioned results rather than divergence as such.
Related: [Building an Agent Graph: How You Know](/notes/graph-guide-how-you- know/) — the measurement these levers have to pass, and part three of the build; Tune the Prompt Before You Split It — the second lever, at length; Train on What the Gate Throws Away — where the labels for the third one come from; You Can’t Grade Your Own Misses — why the promotion gate cannot live inside the loop.