Keep a checked specification connected to the shipped service
Distinguish model correctness, implementation refinement, trace checking, and operational evidence while maintaining an explicit assumption and artifact ledger.
On this page
The question for today
What you’ll understand
- State an implementation-to-specification trace-inclusion goal under an explicit environment.
- Separate finite conformance tests from a universal refinement proof.
- Define evidence that must change when code, dependencies, configuration, or specification assumptions change.
A verified design does not automatically verify the service binary assembled months later. The specification may omit a parser, assume atomic storage that a new backend lacks, or rely on an identity-retention rule that operations shortened. Keep model analysis, implementation correspondence, and deployed-configuration evidence as separate links. Each link has a scope, artifacts, and assumptions. Maintaining those links makes a correctness claim reviewable instead of turning an old successful model-checking run into a permanent badge.
Name the implementation and the environment of the claim
The intended conformance statement is that every implementation behavior allowed by the declared environment maps to a behavior permitted by the specification. The environment includes failure modes, storage guarantees, clocks, message behavior, and caller obligations. The mapping defines which implementation events and states represent abstract actions and observations. A proof about a protocol library may leave serialization, resource exhaustion, system calls, and deployment orchestration outside its verified boundary. State those boundaries explicitly rather than implying that correctness of one layer covers all code that happens to call it.
Full implementation verification can connect program-level reasoning to state-machine refinement, as projects such as IronFleet demonstrate under their stated methodology and assumptions. Other teams use a design model plus disciplined reviews, model-based tests, deterministic simulation, and runtime trace checks. Those methods can expose important defects without constituting the same universal proof. Match the language of the claim to the evidence obtained. A useful partial claim identifies its remaining correspondence obligations instead of treating every unverified layer as either irrelevant or a reason to abandon specification work.
Observed conformance does not quantify over unobserved executions
A trace checker can map a captured execution to the model and reject an impossible transition or an inconsistent history. Its instrumentation must observe the relevant boundaries, preserve identities and ordering, and classify missing events honestly. A dropped trace segment can make an actual violation invisible or create a spurious apparent violation. Test the checker and instrumentation with known legal traces and deliberately invalid mutations. A passing checker over an incomplete observation is evidence only for the property and information it actually examined.
Finite test campaigns explore a selected subset of schedules and configurations. Record planned cells, executed cells, failures, inconclusive outcomes, and the coverage criterion rather than converting the passing fraction into a production reliability probability. Repeated identical schedules can produce many passing operations while adding little new behavioral coverage. A simulation's deterministic replay is valuable for diagnosis, but its network, storage, and timing abstractions still need validation against the real service. A test harness and a specification can also share the same mistaken assumption, so independent semantic review remains necessary.
Version the correspondence obligations with the release
Retain the specification revision, checked properties, parameter domains, fairness assumptions, tool versions, solver status, implementation revision, configuration, and mapping used for each release claim. Link counterexamples to regression tests and document which code boundary enforces each modeled atomic action. When a storage engine, retry policy, deduplication horizon, scheduler, or wire format changes, review the affected assumption and correspondence obligations. A comment stating that a model exists is not evidence that the new mechanism still implements it. Include operational checks for assumptions that can become false after deployment.
The quadratic instrument illustrates the limits of a single passing example. Reset, set a=1 and x=0, predict y=0, then Play or Step. Separately Reset, set a=2 and x=0, predict y=0 again, then Play or Step. Both selected functions agree at zero; at x=1 they produce one and two. The instrument computes its declared family exactly and is not comparing service implementations. Its narrow lesson is that agreement on an observed input does not establish agreement everywhere, just as finite conformance observations do not establish universal behavior inclusion.
Work it through
Report an incomplete conformance campaign honestly
A release plan has six fault scenarios, each with four predetermined schedules, for twenty-four test cells. Twenty cells finish with complete traces accepted by the checker. Four time out before sufficient evidence is captured and are marked inconclusive. Compute planned-cell completion and state the supported conclusion.
The plan contains 6×4=24 cells. Twenty have complete, passing checker evidence and four have no decisive conformance result; the latter are not passing tests.
Completed passing evidence covers 20/24=5/6≈83.33% of the planned cells, while 4/24≈16.67% are inconclusive. This measures execution of the declared plan, not all possible service schedules.
The supported statement is that the twenty captured executions conformed under the checker's mapping and property scope. It neither resolves the four missing outcomes nor proves the universal trace-inclusion goal for untested executions.
Report twenty observed passes and four inconclusive cells, then investigate the gaps. The planned-cell fraction is not an estimate of production correctness probability.
The living notebook
Explore the model
Interactive lab · function
One matching observation does not establish universal agreement
Reset, set a=1 and x=0, predict y=0, then Play or Step. Separately Reset, set a=2 and x=0, predict y=0, then Play or Step. For a further independent comparison, Reset and set a=1,x=1 to predict y=1; separately Reset and set a=2,x=1 to predict y=2, then Play or Step for each. This fixed quadratic family is no conformance prover or arbitrary-function tester.
- y at chosen x
- 0.608
- Tangent slope · 2ax
- 1.35
- Signed area · ax³/3
- 0.182
This lab uses only y = ax². Playback traces the curve within the fixed integration interval from 0 to x; it does not estimate numerical error or change the chosen point. Parameter changes pause playback and recompute the model at the current elapsed time. Reset restores both parameters and returns time to zero. Playback starts paused. Adjust either parameter, then choose Play or Step.
Look forThe scope of observed agreement is smaller than a universal refinement claim.
Pause & reason
Check your understanding
Your turn
Try it yourself
A history checker accepts fifty complete test histories, each containing twenty completed operations. How many completed operations were observed? Can that count alone establish correctness for every concurrent schedule or for histories with unrecorded crashes?
Take a moment to make a prediction or work it out on paper. Open a hint when you need one.
Give me a hint
Multiply the observed counts, then distinguish a finite test set from the universal behavior set.
Compare with the solution
The campaign observed 50×20=1,000 completed operations. That count alone establishes neither universal schedule coverage nor correctness under unrecorded crash behavior. The evidence is scoped to those histories, their capture quality, the sequential or state-machine model, and the checked properties. A stronger claim requires a justified completeness argument or proof covering the additional behaviors.
Keep the idea
Take it with you
- A service claim connects specification, implementation, environment, and an explicit observation mapping.
- Finite observed conformance and universal refinement are different evidence levels.
- Release changes require reviewing the assumptions and correspondence obligations they affect.
Read further
Original sources and deeper explanations to follow at your own pace.
Optional progress, saved in this browser when available. Revisit any lesson at any time.
Lesson not marked complete.