Shared-World Compilation

What happens when “link to the law” has to mean something.

Elias Kunnas

Corpus frame

The corpus applies one lens to many domains: what mechanisms produce the outcome? It shares four methodological commitments and one explicit directional commitment. Each linked page argues for its part; the links are derivations and disputes, not evidence inherited by every page. The directional commitment does not by itself settle system boundary, distribution, sacrifice, or institutional authority.

  1. Mechanisms are what act. Incentive gradients, selection pressures, feedback loops, and capital stocks produce the distribution of outcomes. Intentions, labels, official categories, and stated values are evidence about mechanisms, or are themselves coordination mechanisms. They are not causal substitutes. — Mechanism Realism · Only Selection
  2. The reference telos is sustained flourishing. The broadest achievable adaptive safety margin over deep time — not the continuity of any incumbent state, coalition, institution, or doctrine. A mechanism's own stated goal can still serve as a local proof obligation — showing that its incentives defeat even the purpose it claims is a bounded finding — but meeting that goal establishes nothing about the margin. — Flourishing Is Maximum Safety Margin
  3. Law, rights, legitimacy, democracy, markets, and sovereignty are mechanisms under evaluation. They are constraints, carriers, or proxies inside the analysis. None is a terminal value or a boundary of what is real. Treating one as terminal ends the mechanism search before it starts. Evaluation carries current function, replacement cost, path dependence, uncertainty, capture risk, reversibility, and who bears model error into the ledger. — The Stack · Mechanism Space
  4. Optimization is a system function. A civilization has to build, exercise, and revise metamechanisms that search mechanism-space, discard dominated options, install, observe effects, and repair under uncertainty. Not running that loop leaves margin unrealized, and that is itself the failure. No single component — analyst, model, or institution — is presumed to contain a global optimum; the capacity is a property of the system. — From Telos to Policy · The Three-Layer Architecture
  5. Uncertainty is preserved, not spent. Partial orders, binding constraints, unknowns, and residuals stay explicit. An unmeasured effect is not a favorable default. — The Compression Paradox · Cargo Cult Epistemology

Each essay bears its own evidence. Links carry definitions, derivations, applications, and disputes; they do not transfer proof. Criticism is answered on its substance.

Where each commitment is derived

An exact file is not yet an exact answer. Laws, contracts, and standards depend on other texts, dates, events, and conditions. Shared-world compilation turns those separately maintained contributions into an explicit model of what follows from them together. Others can evaluate that model for their context, inspect its basis, and revisit the answer when something changes. A reference that preserves what it originally included, and explains what happened afterward, is one thing this makes possible.


I. Here is the file

final_final_v1.23_beta.docx

Which version is this?

The filename makes a brave attempt to answer. Suppose we improve it. Put the document in version control. Give every revision a permanent identifier. Retain the original bytes. Publish a machine-readable copy and an API.

Now we know exactly which file we have.

We still do not necessarily know which rule applies.

Consider a contract amended three times. Amendment two takes effect only after an approval. Amendment three changes the deadline, but preserves the old deadline for agreements signed before a particular date. The contract also incorporates a technical standard. Does it incorporate the edition named when the contract was signed, or the standard as subsequently revised?

“Give me the latest document” does not answer those questions. There may be no single document containing the answer. The relevant state is a composition of documents and events under rules about what changes what.

This is the distinction between artifact versioning and state composition. A version history tells us which artifacts changed. A composition system tells us what their changes jointly produce under a specified context.

The reusable product is the composition: identities, dependencies, conditions, and transformations made explicit enough for other people and systems to evaluate. A legal reference is a small place to test whether that larger operation actually works.

LawVM is where I encountered this problem in a particularly unforgiving form. It reconstructs point-in-time statutory text from published amendment streams: parse the instructions, identify the targets, apply the changes, account for the timeline. Its public scope is the text-state layer, with interpretation and application above it.1

Start there and a surprisingly ordinary request becomes a research programme:

Why can’t I copy a reference to this law and have it keep meaning what I meant?

Imagine an act containing a filing deadline. Here is the reference we want to be able to make.

The passage is only a coordinate inside a work. Add the act, the language, and the date.

Work:       Example Act
Expression: Finnish
Target:     chapter 2, section 10, subsection 2, paragraph 3
Legal date: 2026-09-01

Already we have left the filename behind. Yet “September 1” is still underspecified. Do we want what the system knew on September 1, or what current evidence says about the legal state on that date?

Suppose a relevant source was published before September, but our archive acquired it only in October. Two requests with the same legal date can now produce different answers. The date being described and the date of the available knowledge are different coordinates. Bitemporal databases already make this distinction between valid time and system-recorded time.2

So record the evidence snapshot too:

Legal date:        2026-09-01
Evidence snapshot: K17
Scope:             the specified procedure and territory
Selection rules:   profile P1
Produced by:       LawVM build B123
Answer:            “within 30 days”

The readable names stand for exact retained objects. A build number alone is not enough if its inputs can change behind it.

Now another person can ask the same question against the same inputs. They can also inspect why this answer was produced. A hash can bind the result to exact retained content independently of the server from which it is retrieved.3

It cannot establish that the content is legally correct. We will come back to that.

There is another trap. Next year, section 10 is renumbered to section 12. Later, a new provision occupies section 10.

What should the link follow?

These are different instructions. Identical wording does not prove continuing identity, and a familiar address does not prove an unchanged occupant. Continuity needs a justified relation through the changes, not a clever redirect.

Naming the passage was the easy part.

III. Open the same reference later

On September 22, a report quotes the deadline: “An application must be submitted within 30 days.”

The author clicks Copy reference. The reference anchors the result actually displayed, including its legal date, evidence snapshot, and scope. It does not quietly refresh the query during copying and attach a different answer.

On November 15, someone opens that reference.

A conventional update might show:

- within 30 days
+ within 20 days

That can conceal the important part.

In October, the archive acquired the previously missing source. The reconstructed answer for the original September date became 14 days. A separate amendment then changed the deadline to 20 days from November 1.

The useful interface has three views:

ORIGINAL OBSERVATION
Recorded on September 22, for legal date September 1:
30 days

REASSESSED ORIGINAL QUESTION
Current evidence, same legal date and scope:
14 days — an additional source changes the reconstruction

SUBSEQUENT STATE
Legal date advanced to November 15:
20 days — a later amendment took effect on November 1

The first change is a correction to the account of the past. The second is a later change in the modeled law. Collapsing both into “the document was updated” loses the distinction the reader needs.

This is anchored live transclusion: including a result in another document while preserving its original context and a declared rule for checking its continuation. The original inclusion stays fixed. Later assessments sit beside it.

“Live” does not mean “change everything to today.” A historical citation keeps its legal date. A current-law panel advances its legal date. A contract-specific reference keeps the signing date and relevant case facts. The continuation policy says which question to keep asking.

Nor should a later answer silently rewrite an author’s quotation. A maintained report can adopt the update in a new revision; the old report should continue to show what it actually included.

The underlying idea of a reference carrying later correction notices is not new. Crossmark already lets readers discover corrections and retractions associated with previously downloaded research, including through a button embedded in a PDF.4 The additional work here is to distinguish correction of the old answer from later change in the world, and to track that distinction through the reference’s context.

Even identical endpoints do not settle the history. A, then a temporary B, then A again. The text is back where it started. Someone whose transaction occurred during B still needs to know B existed.

IV. Unknown is not false

Now give the amendment a commencement condition: the new deadline takes effect when event E occurs.

Our source account has no accepted evidence establishing whether E has occurred.

Returning the old wording as definitively current would turn a missing fact into a false fact. Returning the newest wording would make the opposite guess.

The answer can remain conditional:

Unresolved dependency: event E.

That is a useful result. It identifies what is missing and what would change when the missing input is supplied.

Suppose E controls two provisions. Their alternatives must remain correlated:

DeadlineException
Before EA₀B₀
After EA₁B₁

The system must not let a reader assemble A₀ + B₁ merely because each provision has two separately valid versions. Individually acceptable pieces can form a state that no admissible scenario produces.

There is also a useful converse. Both branches might have the same heading. A query for the heading can return a single answer even while a query for the body remains conditional. Determinacy belongs to the question being asked, not to the entire world at once.

And “all alternatives” requires a boundary. The system may have accounted for every outcome under its declared sources and modeled effect families. That is different from having discovered every relevant source or interpretation. An incomplete result should say where its enumeration stops.

A conditional expression is not an excuse to invent all possible futures. For a future legal date, the model can account for scheduled effects in a specified snapshot. It cannot silently include legislation that has not yet been enacted or even conceived.

The useful primitive is a precise question with a precise account of its remaining uncertainty.

V. Nix for the answer

Software build systems provide a useful discipline here. Instead of “the executable on my laptop,” a derivation specifies the inputs and process that produce an artifact. Nix makes individual build steps explicit; reproducible-build practice asks whether the specified source, environment, and instructions reproduce identical outputs.5

Those sources do not arrive with every dependency already resolved. The compiler first has to recover which passages describe changes, what those changes target, and how their conditions interact. The resulting model is what a contextual query evaluates.

Apply that discipline to our legal query:

retained source population
+ modeled amendments and events
+ accepted external facts
+ legal date, scope, and branch
+ declared selection rules
+ exact implementation
→ contextual result

The product can be text, a structured state, a conditional family, or an explicit non-answer. With external inputs frozen and the evaluation deterministic, this is a reproducible derivation, not merely a metaphor for one.

But now break it.

Remove an applicable exception from the source population. Everyone reproduces the same answer. Everyone reproduces the same omission.

Restore the exception, but make the parser consistently translate “before” as “after.” The inputs are present. The result is still wrong.

Fix the parser, then admit a proposed amendment into the enacted branch. The operation may be perfectly represented and faithfully executed. It still does not belong in that answer.

Finally, compute two correct pieces under incompatible conditions and combine them. We have already seen that failure.

There is no magic number of boxes that produces trust. Each outward claim has obligations; the checks must address the ways that particular claim could be wrong. A hash is evidence about an object’s identity. A signature is evidence about its signer. A complete manifest is complete relative to the population it names. None substitutes for the others.

Software release systems face authority and provenance questions too. The distinction is not that software has solved truth and law has not. The transferable part is making dependencies inspectable, transformations repeatable, and unsupported assumptions visible.

The same discipline applies to the compiler itself. If a later implementation repairs an earlier mistake, the old computation remains an archived fact about what the system returned. Its current assessment changes. “The software was reproducible” is not a defence of the mistaken answer.

VI. The ingredients are not the interface

Pieces of this architecture already exist. Akoma Ntoso distinguishes a legal work from its versions, languages, manifestations, and components. Web Annotation binds selections to resource states. Memento retrieves historical web representations. The UK legislation publication log exposes publication, republication, withdrawal, and changes to legislation. LegalRuleML represents legal norms, alternatives, time, and authority.6

Those are substantive capabilities, not just nicer filenames. They are also components from which a broader interface can be built.

Run the same question through the proposed composition:

A version identifier supplies one input. A publication feed supplies another. Neither alone supplies the derivation connecting a changed source to a changed contextual answer.

The engineering target is the whole relation: a source changes, the appropriate historical or current query is reevaluated, and the reference shows what that changes for its reader. A bibliography of components does not implement that sequence.

This also gives “shared world” a bounded meaning. We are compiling declared models of shared institutional state, not issuing one final machine interpretation of reality. Two evaluators can use different explicitly identified source policies or interpretations. Their outputs become comparable because those differences remain visible.

A universal interface need not impose a universal ontology, publisher, or unquestionable resolver. It needs a reliable way to say which subject, question, model, inputs, and result a reference denotes.

VII. The deadline did not change. Its definition did.

Return to the report. It still contains the same sentence. No words in the referenced paragraph have changed.

A definition it depends on has.

That is the difference between watching a page and maintaining a dependency.

An even harder case is a newly introduced exception. It cannot appear in the original execution trace: it did not exist in the population that was searched. A live reference has to track the relevant discovery population as well as the objects previously used. Otherwise “nothing I used has changed” becomes a false assurance that nothing relevant has changed.

A document can therefore have something like a dependency lockfile:

Report revision R4
    filing rule      → frozen answer A17
    definition       → frozen answer A18
    standard edition → frozen answer A19

A later check does not automatically rewrite the report. It identifies what needs attention:

The intended reference behavior matters. A contract that names a fixed standard edition and a contract that follows later editions are different compositions. “Update everything” is not a neutral operation.

The same pattern applies to organizational policy, delegated authority, technical requirements, and scientific workflows. Each needs its own account of what establishes a claim. An institution can create a status through an authorized act; a signed scientific report does not create the physical fact it reports. Shared reference and derivation machinery can serve both without pretending their truth conditions are identical.

This is the reference class: shared state that independent actors need to identify, reconstruct, depend upon, and revisit under changing context. It is wider than legislation and narrower than “all coordination.”

A correct shared answer still does not make anybody act on it. The mechanism connecting information to action remains another problem. Correct Is Not Consequence is about precisely that gap.

VIII. What we are compiling

Return to the contract from the beginning.

The parties maintain the contract. A standards body maintains the technical specification it incorporates. An inspector records a measurement. Someone authorized under the contract can approve a change.

Four perfectly identified records still leave a composition problem.

CONTRACT C
Component U must satisfy Standard S, edition 3.
Approval E switches this requirement to edition 4.

STANDARD S
Edition 3: deviation must not exceed 5 mm.
Edition 4: deviation must not exceed 3 mm.

INSPECTION I
Component U: measured deviation = 4 mm.

APPROVAL ACCOUNT
Whether E has taken effect is not established.

Does the component meet the contract’s tolerance requirement?

Opening the latest standard gives the wrong method. The contract does not say “latest.” Opening the contract alone does not supply the measurement. Finding an approval document would not be enough either: it has to be the right approval, for this contract, with the relevant effective time.

The system has to connect the records.

The component in the inspection must be the component in the contract. The standard references must bind to the named editions. The approval must control the specified substitution. The measurement and thresholds must use compatible quantities. Each contribution must be admitted for the role it plays: the standards body specifies a threshold; it does not establish the measured condition of this component.

With prose-only records, recovering those relationships is itself part of the work. Once recovered, they should not disappear into someone’s private understanding.

They become an explicit model that can answer:

For component U, contract C, and query date T:

If E has not taken effect by T:
    required edition = 3
    4 mm ≤ 5 mm
    tolerance requirement met

If E has taken effect by T:
    required edition = 4
    4 mm > 3 mm
    tolerance requirement not met

Unresolved:
    whether E has taken effect by T

This is an answer about the specified tolerance requirement, not a certificate that the component satisfies every obligation or is safe to use. Its scope is part of the answer.

Now the standards body publishes edition 5.

Nothing necessarily changes. The contract names editions 3 and 4. A new edition is a publication event, not permission to substitute a new contractual requirement.

Now accepted evidence establishes that E took effect on October 1.

The same model selects edition 3 before that date and edition 4 afterward. Someone inspecting the September result should still see edition 3. Someone checking October should see edition 4. Someone revisiting an earlier unresolved answer should see which missing fact was supplied.

The records have not merely been collected. Their relationships have become an operation.

That is shared-world compilation: separately maintained contributions are turned into an explicit model of what follows from them together.

The world here is the modeled situation: this contract, component, standard, inspection, approval, and their changing relationships. It is larger than any one file and smaller than reality as a whole.

Shared does not require everyone to use one central database or agree with one evaluator. It means the model, its inputs, and its assumptions can be identified and inspected across the parties who depend on them. Two evaluators can disagree about whether an approval is admissible and show exactly where their answers diverge.

And compilation is more than putting the records into a common format. It makes their identities, references, conditions, and effects explicit enough to compose. Materialization then answers a particular question against that model.

Compilation:
    records → explicit dependencies and transformations

Materialization:
    model + context → accounted answer

Reference:
    identifies the question, context, and recorded answer

Transclusion:
    includes that answer somewhere else

Reassessment:
    determines what changed without rewriting the original inclusion

The same standard can be used by many contracts without all of them following its newest edition. The same approval can affect several provisions without letting their before-and-after versions be mixed arbitrarily. The same retained result can be included in several reports without losing the conditions under which it was produced.

This is where the work becomes infrastructure. Every recipient no longer has to recover the entire composition independently from scattered documents. They can evaluate a declared model, inspect its derivation, challenge a particular relationship, or supply a missing input.

Law is one difficult source of such models. Contracts, standards, organizational policies, and factual attestations supply others. The common operation is not making their authority or truth conditions identical. It is making their contributions compose without erasing those differences.

The copy button is one consumer of that machinery. It is not the machinery’s definition.

IX. The compiler changes what authors can see

So far, the compiler has reconstructed changes after publication. Move the same machinery into an authoring environment and it can show the proposed state before publication.

A drafter edits a deadline. The tool displays the consequences:

Target: section 10, subsection 2
Proposed wording: 20 days

One target reference matches two provisions.
A commencement condition has no bound event source.
A temporary replacement expires on June 1;
its successor state is unresolved.

These are questions the author can resolve while the intended change is still being designed. They are not a machine’s judgment about whether 20 days is a desirable deadline.

Some unresolved variables should remain. “Effective on an appointed day” can become an explicit runtime dependency: a named event, the actor entitled to establish it, its scope, its temporal meaning, and the evidence required to bind it. Failure to obtain that evidence is then a visible unresolved input rather than a hidden guess.

Open-textured language is another case. “Reasonable steps” may deliberately leave application to later judgment. Reconstructing the wording can be complete while evaluating whether a person’s steps were reasonable remains outside the computation. Removing that discretion would change the rule, not merely improve its machine readability. LegalRuleML likewise distinguishes textual provisions, formalized rules, temporal properties, and interpretive alternatives.7

The important design distinction is between declared openness and an accidental unresolved dependency.

An authoring tool could eventually produce conventional legal prose and a corresponding transition package from one modeled change. It could bind them together, test their agreement, and make disagreement explicit. Which representation carries legal authority, and what happens if they conflict, would still need an explicit institutional rule. A successful build does not enact itself.

The immediate engineering gain is available before that reversal: authors can inspect the state their changes would produce, rather than relying only on inspection of the instructions describing the changes.

X. The bootstrap is a consumer that exposes its missing inputs

This direction does not require waiting until all shared state has been formalized.

The first useful system can reconstruct a bounded domain and expose its failures precisely:

Cannot determine the selected version.

Missing input: event E
Required evidence: the designated source's dated assertion
Affected results: the following dependent queries

That is a smaller and more actionable problem than “legal information is complicated.” A contributor can supply one missing adapter or event account without rebuilding the entire compiler. If the contribution satisfies the relevant contract, the dependent queries can be reevaluated.

The possible feedback loop is concrete:

  1. Usable reconstructed state.
  2. Downstream references and applications.
  3. Visible missing inputs.
  4. Maintained upstream interfaces.
  5. More directly supported state.

The loop stalls if nobody uses the outputs, if a contributor cannot keep a feed current, or if a publisher saves nothing by changing its practice. A demonstration shows what the capability makes possible. It does not supply the people who will maintain it or their incentives.

There is also a failure mode in success: the compiler absorbs every upstream defect so effectively that publishers never need to change. Keeping the reconstruction’s dependencies and unresolved inputs visible lets consumers distinguish a native published fact from an elaborate repair.

The long-run opportunity is to retire some of that repair. New publications can carry the structured facts that older publications forced the compiler to reconstruct. Historical parsing becomes compatibility machinery rather than an endlessly expanding substitute for an upstream interface.

This is also how the abstractions earn their place. A failed reference exposes the difference between an address and a continuing subject. A corrected historical answer exposes the two clocks. A missing exception exposes the difference between the inputs used and the population that should have been considered.

The design grows when a simpler version fails a concrete case. It should contract when a distinction no longer changes any result, check, or useful operation. “Infrastructure for civilization” is not a licence to accumulate abstractions without end.

XI. The copy button

The whole stack should eventually disappear behind an ordinary action: copy reference.

What gets copied is not a promise that the answer will be right forever. It is the original answer, the context that gives it meaning, and a controlled continuation of the question.

Another reader can recover the original inclusion even if the live service is unavailable. When a recheck succeeds, it can distinguish a later amendment from a correction to the past, a relocated provision from a new occupant, and a resolved condition from an invented certainty. When the recheck fails, it says so instead of leaving a stale “current” label on the screen.

That is a usable test of the infrastructure. Can someone else reconstruct what was included, understand why, and inspect the changes pertinent to that use without needing the original author’s memory?

The copy button is a small interface to a larger change in how shared state is maintained. A contract names a standard; an approval changes which edition applies; an inspection supplies a fact; a report depends on the resulting answer. Those relationships become inspectable and reusable rather than work silently delegated to every downstream reader. The documents remain readable artifacts. Their composition becomes something other systems can operate on.

final_final_v1.23_beta.docx can remain a joke about filenames. It should not be the model of what we mean by sharing a state of the world.


Sources and Notes
  1. Implemented starting point. LawVM’s public overview describes deterministic reconstruction of statutory text from amendment streams and explicitly bounds the project at the text-state layer. Its frozen benchmark figures are not used here as a current accuracy claim. The anchored-live reference service, the readouts, and the authoring environment in this essay are proposed compositions, not claims that the public release already provides them. The author’s current repository contains more extensive identity, selection, dependency, and computation-lifecycle designs; those designs are not treated as evidence of completed deployment.↩︎

  2. Two clocks. XTDB, “Key concepts”, distinguishes valid time from system time. The example adds an explicit evidence account: publicly available by a date, acquired by a system by that date, and actually used in a historical computation need not select the same inputs. The October source acquisition and all deadlines in the essay are hypothetical.↩︎

  3. Content identity. RFC 6920, “Naming Things with Hashes”, specifies hash-based names separable from retrieval location. An identifier alone does not preserve availability, establish a source’s institutional authority, prove an observation time, or establish continuity of a legal subject. Retention, grounding, and identity relations are separate obligations.↩︎

  4. A reference with later notices. Crossref, “Crossmark”, documents correction, retraction, and update discovery, including from previously downloaded PDFs. It depends on maintained update records. This is a concrete predecessor for revisable assessment of a retained publication, not evidence that every field of the proposed legal reference is already implemented there.↩︎

  5. Reproducible derivations. Nix 2.34 Reference Manual, “Store Derivation and Deriving Path”, specifies build steps through inputs and an executable process. Reproducible Builds, “Definitions”, binds reproducibility to specified source, environment, instructions, and output artifacts. Neither promise establishes that a model’s inputs are complete for a real-world question or that its semantics are correct. “Nix for the answer” names the transferable derivation discipline, not a claim that Nix lacks dynamic dependency mechanisms or software supply chains lack authority concerns.↩︎

  6. Existing components and the composed function. Akoma Ntoso Naming Convention 1.0 distinguishes work, expression, manifestation, item, and components, including temporal reference concerns. W3C Web Annotation Data Model specifies selectors and resource states. RFC 7089, Memento, provides time-based access to prior web representations. The legislation.gov.uk publication-log documentation describes publications, withdrawals, revised points in time, and effects. LegalRuleML Core Specification 1.0 supplies the formal-rule concepts discussed further in the following note. These sources establish substantial prior work and interfaces that can contribute to the composition. The essay is not an exhaustive product comparison or a claim of worldwide absence.↩︎

  7. Text, norms, and deliberate openness. LegalRuleML Core Specification 1.0, especially §§4.2–4.4, treats defeasibility, alternatives, sources, authority, time, and context. It distinguishes textual provisions from formalized norms and allows interpretive alternatives. The authoring demonstration does not claim that a compiler can replace judgments intentionally left outside a modeled text-state computation.↩︎