Skip to content
Browse standards

Standard ·Markdown source ·View on GitHub

Conformance roles and trust

A consumer MUST state the role, supported schema/profile subset and fixture evidence behind its claims. No role alone implies the others.

RoleMinimum responsibility
Archival reader/writerPreserve supported envelopes and opaque data without executing it; report unsupported preservation
Structural validatorValidate supported pinned schemas offline; distinguish invalid data, invalid contracts and unsupported contracts
Semantic consumerExpose declared meaning and unresolved limitations without inferring arbitrary code behavior
PreparerApply explicit approved preparation steps; disclose executable requirements
Static compilerLower supported content to readable output with diagnostics and fidelity limitations
Interactive rendererImplement its declared behavior and lifecycle, not claim universal simulation
Artifact serverStore/serve approved precompiled HTML/assets without recompiling each request

These are role definitions, not declarations that every role is currently implemented. Current tooling provides JSON/digests, structural validation, descriptive meaning, bounded traversal, readable preservation, locked archival exchange, renderer-free semantic exports/inspection and native/artifact delivery checks. The independent Python consumer and precompiled host have offline and real-browser evidence. Python reports semantic/traversal execution and opaque hooks as unsupported rather than claiming full preparer/renderer conformance. Bounded composition has direct JavaScript lowering, scalar state, compatible snapshots and typed port propagation; it does not implement arbitrary simulation.

Required P0 gate

pnpm test:conformance:p0 runs the Python standard-library suite, TypeScript unit suite and Chromium acceptance suite, then verifies required passing evidence for every TEST-01–10 group and this batch's P1 TEST-11/12/13 in tools/p0-gate.ts. Empty, missing or skipped evidence is an error. CI installs Python 3.11 and executes this gate in its required check job.

Claim and evidence matrix

The TEST identifiers name the requirement groups summarized below. Rows describe bounded evidence rather than certifying a future checkout. TEST-01–13 are required by the fresh-report P0 gate; their linked sources identify the passing assertions that the gate must find. The independent renderer contribution to TEST-01 has its own required gate. Run both gates for the revision being claimed; stored documentation is not the report.

TestClaim and scopeExecutable evidence / explicit limit
TEST-01Independent structural classifications, JCS Unicode/binary64 digests and the declared static renderer corpusIndependent validator fixtures, Python tests, static/MathML parity, migration/fallback/refusal parity; P0 + renderer gates
TEST-02Offline built-in closure and exact transitive contract resolutionIndependent locked closure, export dependency fixtures; P0
TEST-03Unfamiliar declarations are exposed as JSON without renderer executionMeaning fixtures; P0
TEST-04Executable refinements, normalization and migrations remain implementation-boundExport capability/refusal fixtures; P0; universal callback portability is not claimed
TEST-05JSON object, array, scalar and null inputs match native/artifact deliveryReact delivery, Svelte delivery; P0 Chromium
TEST-06Missing contracts/plugins retain opaque source and substantive no-JavaScript explanationPreservation fixtures, shared browser acceptance; P0
TEST-07Unsupported vocabulary/pattern/ref/branching and substituted digests rejectStructural refusal fixtures, seal tampering; P0
TEST-08Archival Markdown identity/pins and locked JSON/resource exchange round-tripArchival Markdown, exchange fixtures; P0
TEST-09Independent Python host serves compiled islands, shared chunks, independent placements and no-JavaScript fallbackPython host Chromium acceptance; P0; Python does not execute arbitrary plugin semantics
TEST-10Production readers exclude registry/schema/core/compiler/Ajv and retain lifecycle/module/state behaviorReact production, Svelte production, Python host; P0
TEST-11Fourier sample numerics, native/artifact delivery, renderer-free inspection and authored reading projectionNumerical fixtures, Fourier browser fixtures, inspection, reading projection; P0; arbitrary scientific verification is not claimed
TEST-12Keyboard activation/focus, cancellation, reduced motion and substantive print/no-JavaScript alternativesLifecycle browser fixtures, interactive profile fixtures; P0; universal accessibility conformance is not claimed
TEST-13Sealed bounded composition, compatible snapshots, typed ports and isolated repeated placementsProfile sealing, composition unit fixtures, browser isolation; P0; arbitrary simulation is not claimed
TEST-14Full corpus/instance-scale contract and module deduplication claim not claimedScoped host cache deduplication and browser module sharing pass through the unit/browser suites; scale measurements are local observations, not a required complete TEST-14 gate
TEST-15Affected-only host compilation reuse for changed documents, contract/resource identities and shared dependenciesCompilation cache regression fixtures run in pnpm test and the P0 unit run; persistent storage/watch infrastructure and arbitrary host caches are not claimed
TEST-16Universal matched performance/cost claim not claimedReproduction harness, measured preparation report, calibration snapshot and limits; no required CI timing/byte comparison; heap, long tasks, CLS and unmeasured comparators remain observations

These are scoped profile/fixture claims, not universal parser equivalence, scientific verification or a declaration that arbitrary HTML is safe.

Independent renderer gate

pnpm test:conformance:renderer is the required CI sibling of the P0 gate. It runs the Python suite and requires passing TypeScript evidence for the shared static document, normalized MathML trees, built-in migration payloads, the fallback/refusal cases in packages/contracts/fixtures/renderer-parity.json, and the Research citation corpus in packages/contracts/fixtures/citations.json. Missing, skipped or failing evidence fails the gate, including an unavailable Python executable.

The compared TypeScript configuration uses only built-in definitions and no host renderers or host migrations. Both implementations declare the same static role: schema version 1, portable built-in migrations, no plugins, no full CSL. The schematic v1→2 conversion runs before rendering; future schematic and document versions reject the document with the existing shared version codes. Source inputs remain immutable. Authored fallback paragraph structure/text and diagnostic code sets must match. Host wrappers and KaTeX's visual spans may differ; the math comparison removes annotations and compares presentation MathML.

This evidence covers the committed corpus, not arbitrary HTML tree equivalence. Full CSL, executable host migration parity and arbitrary plugin execution are not claimed. The TypeScript preparer can separately execute host-approved migrations; that capability is outside this portable renderer configuration.

The optional Research citation role compares resolvePortableCitations from @publisle/research (citeproc-js) with tools/python/citations.py and its Python HTML integration. Both consume the same source documents, declare the capability record in packages/contracts/citation-subset.json, and reject unsupported features with unsupported-citation-feature. The corpus covers numeric and author-date styles, en-US/fr-FR, first-appearance numbering, numeric ranges, author/year bibliography sorting, et-al names, identical-author year suffixes, locators, missing/duplicate references, literal references and punctuation. Markers and reference-list text are whitespace-normalized; bibliography ids, labels, ordering, classification and diagnostic code sets must match exactly.

This role admits only paragraphs/headings and bibliography blocks with v1 payloads. Names use the restricted ASCII Family / Family, Given form in the descriptor; years and ranges have explicit patterns. General CSL XML/macros, structured names, particles, given-name/coauthor disambiguation, quotation processing, BibTeX acquisition, other locales and other block locations are rejected by both implementations under this role. The broader TypeScript resolveDocument API remains outside this parity claim. The gate also verifies the expectations generator's citeproc-js 2.4.63 pin; expectations are regenerated only with pnpm generate:citations and reviewed as source changes.

Research artifact evidence

Research export validation is separate from TEST-01–16 and Core reader claims. The current local verification on 2026-10-10 passed the following bounded checks; CI must rerun them for the revision it reports.

ClaimEvidence and limits
Standard article and article-arabic PDF/UA fixturespnpm test:pdf-ua passes three fixtures through the pinned container and veraPDF: English UA-2, the authored Arabic article UA-2, and English UA-1. Checks include PDF 2.0 for UA-2 / PDF 1.7 for UA-1, tagged structure, language metadata, figure/Formula tags, column-scoped table headers, attached MathML and extracted Arabic/Han text. The strict report checker requires one compliant result for the selected UA-1/UA-2 flavour with no failed rules/checks or job errors. On 2026-10-10 all three fixtures passed on the pinned amd64 compiler image natively and on the arm64 compiler image under QEMU emulation (linux/arm64 confirmed by docker image inspect).
Publisher/source export compatibilitypnpm test:research passes all 14 local integration checks with the container test enabled, including publisher starters and source rebuilds. Compiler success does not establish publisher PDF/UA or journal acceptance.
CI reproducibilityThe Research workflow installs checksum-pinned veraPDF, runs the artifact gates and uploads PDFs, sources, logs and XML reports as research-exports-and-pdf-ua-reports. A hosted run of revision e95916c (2026-10-10, run 38063436064) passed the workflow end to end and retained that artifact; future claims must cite their own rerun.

The committed PDF/UA claim covers those three generated fixtures, not every possible article or visual/assistive usability. UA-1 has English fixture evidence; Arabic UA-1 is not claimed. Publisher starters emit explicit unavailable tagging losses. Core profile warnings and PDF tagging declarations alone do not certify WCAG or PDF/UA. See the accessibility guide.

Capabilities

Structural, descriptive, declarative and implementation-bound capabilities are orthogonal. A block MAY be descriptive and implementation-bound simultaneously. A schema does not prove semantic equivalence, numerical correctness, visual fidelity or accessible usability. Unknown or unsupported behavior MUST remain preserved where the supported archival contract permits it and MUST be reported rather than treated as implemented.

A portable claim requires an exportable verified contract. Arbitrary parse/refinement/normalization/migration callbacks MUST be declared executable and implementation-bound; do not serialize callback source or fabricate complete schemas from callbacks. Lightweight SDK descriptors are documentation, NOT complete portable contracts. Schema-first definitions, verified adapters and offline export now implement this boundary; fixture parity does not prove universal code/schema equivalence.

Trust boundary

JSON contracts, examples and descriptor strings are untrusted content, not host instructions. Validation does not authorize implementations or resources, sandbox plugins, sanitize arbitrary HTML, or verify scientific claims. Hosts separately approve executable modules, resources, capabilities, HTML/URL policy and asset serving. No document-provided import string grants execution authority.

Validation/importing contracts MUST NOT perform network retrieval by default. Schema tooling compiles trusted/reviewed schema inputs at preparation time; it is not a sandbox for hostile executable code. Unknown-origin schema compilation requires host isolation/time/memory limits in addition to the synchronous profile's structural limits. The contract resolver permits retrieval only under explicit host-origin, byte, graph and timeout policy. Readers do not fetch schemas or receive the full registry/compiler merely to display a publication.

Beta policy and release governance

Governance and versioning defines the beta freeze, exact digest identities, Core/Research compatibility, independent version domains, change review and deprecation policy. Existing numeric contract versions remain frozen; changed pinned content gets a new digest. Namespace authority and host execution approval are separate from integrity. No stable release support window is implied.

TEST-14 deduplication, TEST-15 affected-only rebuilding and TEST-16 benchmark methodology are separate requirements. The matrix above distinguishes their bounded evidence and unclaimed limits. Passing the P0 gate does not run timing or byte benchmarks. The optional local budget comparison uses a recorded snapshot; GitHub Actions does not enforce it.