@volter/twin-standard
v1.0.143
Published
The Protocol 3 standard for Volter twin packs: the criteria a pack is graded by, the grader, the gate a pack repository and the twin catalog run on every change and submission, and the spec derivation the grade checks against. Pin a version: every place a
Readme
@volter/twin-standard
The Protocol 3 standard for Volter twin packs, as one versioned package: the criteria a pack is graded by
(protocol-3@3), the grader, the gate, and the spec derivation the grade reproduces. A pack repository's hook and
workflow, a release, and the twin catalog's check of a submitted version all run it at the version they pin, so every
place a pack is judged judges it by the same standard.
twin-standard create <dir> --init <vendor> --package <@scope/name> # fixed files, in your repository
twin-standard create <unit> --index # fixed handler map and fetch after derivation
twin-standard create <unit> --index --building # construction only: keep unfinished operations as gaps
twin-standard gate <pack repository> [<pack or lane dir>…] # every unit passes the form section, or exit 1
twin-standard gate-published <name>@<version>… [--registry <url>] # a published version, as the catalog grades a submission
twin-standard grade <pack or lane dir>… [--static] [--form] # each criterion's result
twin-standard derive <pack or lane dir> [--out <dir>] # write src/generated/ from the vendored spec
twin-standard check-sources <pack or lane dir> [--recheck] # fetch and record the sources the unit cites
twin-standard facts <pack dir> [--out <file>] # package-local facts from its descriptor
twin-standard prepare-consumer <pack dir> --app <new dir> --cli <volter executable> --integrity <sha512> --out <json>
twin-standard assess <pack dir> --prepared-consumer <json> [--browser] [--out <file>] # inside a World
twin-standard --version # this package's version and each standard'sThe commands run with this package and its @volter/world-core peer installed. @volter/world-runtime is an
optional peer, needed only to serve or walk a pack whose descriptor declares a managedDatabase (conform, assess):
install it beside this package for those, which name it when it is absent.
What each criterion asks, and the rules for changing one, are twin-world's architecture, "The grade". A changed criterion is a release of this package: a criterion's id never changes meaning; a changed criterion takes a new id and a new standard version, and a tightened check names what newly fails.
The public assessPack(packDir, { browser: true, consumer }) API runs inside a World, reports actual operation coverage from
kernel dispatch and replays journeys through Chromium when their wire is HTTP. Install Playwright and Chromium for
that target. Its report distinguishes API support, operations exercised, journey failures and replay, and does not
claim DOM interaction coverage. consumer contains absolute appDir and cli paths and the candidate's
artifactIntegrity. Prepare the pack's journeys/first-use.json with prepareConsumerApp(packDir, newAppDir, { cli, artifact }):
artifact is the absolute unpublished tarball path, or omitted for a registry release. Preparation adds the exact candidate
and the CLI's kernel peer to the app. Install those and its exact SDK dependencies with scripts disabled before the
assessment World starts. The journey refuses candidate or kernel imports from evaluator ancestors and checks the
app's own lockfile against the assessed integrity. Older evidence without this installation identity does not satisfy
the current completion check. The public
runConsumerWorkflow(packDir, consumer) lets a builder walk only that entry journey while authoring; it runs no
grade or conformance checks. Its CLI is twin-standard walk-consumer <pack dir> --prepared-consumer <options.json>
--out <walk.json>, using the options written by prepare-consumer. Run it inside a World after installing the
prepared app's dependencies. Installed readiness requires ordinary CLI initialization against the exact candidate,
SDK assertions, read-only state inspection after stop/resume for stored workflows, and verified teardown. A
stateless workflow records why retained-state inspection does not apply. Empty SDK case execution fails.
The canonical pack procedure owns the recipe format and completion requirements. Catalog controllers own provenance, admission and publication.
