Skip to content

Schemas and Conformance

kadubon edited this page Jun 22, 2026 · 6 revisions

Schemas And Conformance

Schemas are the cross-language contract.

The TypeScript package keeps canonical schema files in the npm package and validates public JSON output against them. In v0.5.0, schemas are generated from the public schema output of Python percolation-inversion-compiler==0.5.0.

Show One Schema

npx pic-ts schema --type PhaseAccelerationPlan
npx pic-ts schema --type RuntimeStepReport
npx pic-ts schema --type EffectivePacketGraph
npx pic-ts schema --type PhaseWindowObservation
npx pic-ts schema --type TraceAdapterReport

Export All Schemas

npx pic-ts schema --all --output-dir schemas

This writes individual schemas, a bundle schema, and schema digest data.

Verify Portability Fixtures

npx pic-ts portability verify --manifest fixtures/portability_conformance/manifest.json
npx pic-ts portability verify --manifest fixtures/portability_conformance_v050/manifest.json

Portability checks are useful for npm consumers and CI because they confirm that bundled JSON fixtures match the expected schema and digest behavior.

JavaScript Validation

import { schemaByType, validateData } from "percolation-inversion-compiler-ts";

const schema = schemaByType("EffectivePacketGraph");
const result = validateData("EffectivePacketGraph", data);

Packaged Fixture Groups

  • fixtures/portability_conformance: v0.4 compatibility fixtures.
  • fixtures/portability_conformance_v050: v0.5.0 portability fixtures.
  • fixtures/python_v050_snapshots: Python v0.5.0 snapshot CLI golden JSON.
  • fixtures/python_v050_cli: public-shape and safe diagnostic compatibility records for v0.5.0 routes.

Important Boundary

Schema validation means the JSON shape is accepted. It does not mean the world claim is true, settled, legally valid, or safe to execute.

Clone this wiki locally