Comparing two implementations of an inference API gets difficult when the model itself can produce different answers to the same prompt. If both services make independent model calls, a changed answer gives the reviewer two possible causes: a service difference and a fresh sample. A migration needs a way to isolate the transformation that actually changed.
Anthropic’s November 25 Messages API migration report compares service paths using shared model output. It extends our Fable prototype assessment into infrastructure, where a working implementation needs evidence of compatibility with existing behavior.
The reported mechanism and its limits
Anthropic reports roughly 70% lower CPU per request and 20% lower median time to first token. During the Python-to-Rust migration, passing about 98% of tests accompanied parity on about a quarter of production inputs. An audit found over 100 weakened assertions. Migration report
The comparison sampled once and replayed model output. Checkpoints compared surrounding transformations. Content-free fingerprints guided agents’ synthetic reproductions, with human review before shadow validation. The team prevented duplicate billing and limit accounting. These are selected first-party observations of an internal migration, with workload-specific measurements.
This approach makes an important experimental boundary visible. A model response becomes shared input to two service implementations, so the comparison can focus on parsing, streaming, usage accounting, and other surrounding behavior. A new service can be fast and still change what a customer receives.
Build a map of observable transformations
For an application migration, begin with the externally meaningful stages. A request may pass through validation, default resolution, tool assembly, prompt construction, token accounting, streaming conversion, and response serialization. Each stage should have an explicit comparison rule.
Exact comparison is appropriate when bytes or ordering are part of the contract. Other fields need a documented equivalence relation. Generated request IDs and observation timestamps may vary legitimately. A normalization rule should identify the reason each difference is ignored and the scope of that exception.
Keep normalization under review. A broad rule that drops all changing fields can remove the very evidence needed to detect a regression. Retain both the mismatch category and the underlying observation under the applicable privacy and retention controls. A small diagnostic record can still contain sensitive metadata, so collect only what the authorized investigation needs.
A stable replay needs more than the final answer
The same final text can be produced through different event sequences. A client may depend on the order of content blocks, the point at which a tool argument becomes available, or the distinction between a completed message and an interrupted stream.
For a proposed replay fixture, preserve chunk boundaries, event types, terminal states, and the errors that occur between chunks. Exercise an empty output, a partial tool call, a connection loss after a complete result, and a cancellation racing with completion. Check the client’s observable sequence and accounting in each case.
Use a synthetic service for effects during the comparison. The shadow copy should have a deliberately bounded path to billing, counters, queues, and external writes. An evaluation that reproduces the output by charging twice has changed the service’s most consequential behavior.
These are suggested application tests. The public report supports the replay principle, while the exact controls and traces needed for another deployment depend on that deployment’s contract.
Parity is a candidate acceptance rule
The old service captures behavior customers already encounter. It also carries its existing defects and accidental quirks. A reviewer needs to classify each mismatch as a migration regression, an intended change, or a problem in the original behavior.
Keep intended changes in a separate reviewed record. Bind the exception to the affected input class, release, and evidence, then test both implementations against the updated requirement where appropriate. This keeps a migration from silently inheriting every old defect or silently redefining compatibility.
Anthropic describes rejecting a locally passing workaround on design grounds, then retaining reviewed lessons and checks. Output matching needs accompanying design acceptance. Review and memory loops
For a team adapting the technique, separate permission to propose a repair from permission to change the comparison rules or deployment configuration. The worker can provide a diff and its evidence. The owner of the service contract decides which behavior should persist.
Test the verifier before expanding shadow traffic
Start with a resettable synthetic corpus and introduce a few benign known differences into the candidate implementation. The comparison should detect each difference at the relevant stage, while leaving explicitly allowed variation intact. Then increase the diversity of inputs under an approved data-handling plan.
| Proposed comparison | Evidence to retain |
|---|---|
| Identical model events through old and new paths | First differing stage, affected fields, and final client behavior |
| Missing or reordered event | Whether the client and accounting checks detect the discrepancy |
| Changed defaults or tool metadata | Whether the assembled model input preserves the declared contract |
| One request observed by two implementations | Exactly which copy may admit effects and update usage |
| Fixed candidate against later legacy changes | Whether the parity checker detects drift in the target |
Report task coverage, mismatch frequency, time to diagnose, false alarms, and reviewer effort. Count missing comparison records as an evidence gap. Under representative load, measure CPU and latency with the same traffic classes and feature mix. A rewrite can improve the median while making a rare streaming path worse.
The business value comes from reaching a compatible, maintainable release sooner while preserving useful changes to the service during the migration. Replaying a common model output helps create a stronger signal. Independent review determines whether the resulting repair preserves the behavior the service actually owes its users.