Skip to content

Conformance

Julio Toboso edited this page Sep 30, 2026 · 2 revisions

Conformance

An implementation of TOP, in any language, is conformant when it preserves the observable semantics of spec/SPECIFICATION.md for every ring it claims, and passes the conformance suite for those rings.

Rings

The Specification is written in rings. Conformance is claimed per ring, from the inside out: a Ring 2 implementation also satisfies Rings 0 and 1.

Ring 0 · Kernel

  • stable identity and preserved host behaviour;
  • upward-closed membership with a has-been check;
  • non-owning identity-indexed Fields;
  • Base-first Forms;
  • the five-step tagging sequence with rollback on gate and Record failure;
  • Rip sticky for contributions and for conditions
    • the author ends a condition: a guard, or Contract.Delete from the @Rip protocol)
    • refused while required
    • never cascading

Ring 1 · Contributions

  • two scopes, one slot per (scope, name)
  • latest-Layer Overlay with captured Underlays and stored-value Records
  • Tag members invisible on the Agent
  • @Secret and Public publication with a composition door, published members answering members only, and only sound ones (Rogue Access Failure for a Rogue Agent, the named promise for a defective one)
  • Delete
  • three access forms
  • Pins: Tags as Targets, the receiver rule, patching Tag-scope declarations with collision control, publication onto the Field, Fields never mixed

Ring 2 · Contracts

  • strict boolean conditions
  • Preconditions gate only the current call
  • Imprints after commit
  • Postconditions once per call and re-checked later
  • Forward-Post
  • Backward-Pre with weakening diagnosed
  • defective Agents, truthiness, sound and defective partitions, populations combined with |, &, - at every level
  • a condition read on the Agent by its name as a plain bool, its name refused to other kinds
  • a failure names its check (except Precondition.X)
  • @Pre and @Post stacked as one condition, spelled @Requirement in one word

Ring 3 · Lifecycle

  • @Rip protocols after membership ends
  • the three deletion tiers
  • the Agent's __del__ as Layers of its Overlay, after the teardowns, alone at interpreter exit

Surface spellings may differ between languages. The semantic laws may not. Every failure in the failure model must stay distinct and named.

The conformance suite

tests/test_topkit.py is organized by ring and is the seed of the language-agnostic suite. Test classes named for a ring assert laws; a port in another language satisfies the behaviours those tests assert, in its own spelling. Tests that exercise Python-only mechanics (garbage collection, weak references, warnings) are profile tests, not laws.

The "TOP Verified" mark

Implementing TOP is free and open. Claiming conformance under the "TOP Verified" / "TOP-conformant" designation is what the steward authorizes, per implementation and per ring, so the mark continues to mean something. Request review by opening an issue.

Clone this wiki locally