universal-physics-tensor 9.0.0 → 10.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -16
- package/data/atlas/atlas.json +55 -44
- package/data/atlas/atlas.jsonld +1 -1
- package/data/atlas/diffusion.json +19 -18
- package/data/atlas/oscillators.json +15 -10
- package/data/atlas/waves.json +23 -18
- package/data/bridge-catalog.json +886 -1473
- package/data/bridge-catalog.schema.json +349 -132
- package/data/quantities.json +53 -19
- package/data/schemas/atlas-record.v0.json +184 -46
- package/data/units.json +33 -4
- package/dist/atlas/applicability.d.ts.map +1 -1
- package/dist/atlas/applicability.js +14 -3
- package/dist/atlas/applicability.js.map +1 -1
- package/dist/atlas/association.js.map +1 -1
- package/dist/atlas/benchmark/backend-shapes.d.ts.map +1 -1
- package/dist/atlas/benchmark/backend-shapes.js +5 -1
- package/dist/atlas/benchmark/backend-shapes.js.map +1 -1
- package/dist/atlas/benchmark/baselines.d.ts.map +1 -1
- package/dist/atlas/benchmark/baselines.js +8 -0
- package/dist/atlas/benchmark/baselines.js.map +1 -1
- package/dist/atlas/benchmark/hybrid-retrieval.d.ts +3 -2
- package/dist/atlas/benchmark/hybrid-retrieval.d.ts.map +1 -1
- package/dist/atlas/benchmark/hybrid-retrieval.js +15 -8
- package/dist/atlas/benchmark/hybrid-retrieval.js.map +1 -1
- package/dist/atlas/benchmark/leakage.js.map +1 -1
- package/dist/atlas/benchmark/loader.js.map +1 -1
- package/dist/atlas/benchmark/run-atlas.d.ts.map +1 -1
- package/dist/atlas/benchmark/run-atlas.js +14 -2
- package/dist/atlas/benchmark/run-atlas.js.map +1 -1
- package/dist/atlas/benchmark/stats.d.ts +1 -1
- package/dist/atlas/benchmark/stats.d.ts.map +1 -1
- package/dist/atlas/benchmark/stats.js +1 -1
- package/dist/atlas/benchmark/stats.js.map +1 -1
- package/dist/atlas/benchmark/study.js.map +1 -1
- package/dist/atlas/benchmark/types.js.map +1 -1
- package/dist/atlas/bridge-record.d.ts +4 -4
- package/dist/atlas/bridge-record.d.ts.map +1 -1
- package/dist/atlas/bridge-record.js +6 -6
- package/dist/atlas/bridge-record.js.map +1 -1
- package/dist/atlas/catalog-formal-ref.js.map +1 -1
- package/dist/atlas/chain-pipeline.d.ts +0 -11
- package/dist/atlas/chain-pipeline.d.ts.map +1 -1
- package/dist/atlas/chain-pipeline.js +5 -16
- package/dist/atlas/chain-pipeline.js.map +1 -1
- package/dist/atlas/composition-table.js.map +1 -1
- package/dist/atlas/conventions.js.map +1 -1
- package/dist/atlas/coverage.d.ts +2 -2
- package/dist/atlas/coverage.js.map +1 -1
- package/dist/atlas/derivation.js.map +1 -1
- package/dist/atlas/derive-evidence.d.ts +6 -4
- package/dist/atlas/derive-evidence.d.ts.map +1 -1
- package/dist/atlas/derive-evidence.js +7 -2
- package/dist/atlas/derive-evidence.js.map +1 -1
- package/dist/atlas/diffusion/bridges-closure.d.ts.map +1 -1
- package/dist/atlas/diffusion/bridges-closure.js +0 -5
- package/dist/atlas/diffusion/bridges-closure.js.map +1 -1
- package/dist/atlas/diffusion/bridges.d.ts.map +1 -1
- package/dist/atlas/diffusion/bridges.js +0 -3
- package/dist/atlas/diffusion/bridges.js.map +1 -1
- package/dist/atlas/diffusion/dimensions.js.map +1 -1
- package/dist/atlas/diffusion/index.d.ts +1 -1
- package/dist/atlas/diffusion/index.d.ts.map +1 -1
- package/dist/atlas/diffusion/index.js.map +1 -1
- package/dist/atlas/diffusion/models.js.map +1 -1
- package/dist/atlas/diffusion/numerics.js.map +1 -1
- package/dist/atlas/error-algebra.d.ts +6 -0
- package/dist/atlas/error-algebra.d.ts.map +1 -1
- package/dist/atlas/error-algebra.js +26 -0
- package/dist/atlas/error-algebra.js.map +1 -1
- package/dist/atlas/export.d.ts +18 -2
- package/dist/atlas/export.d.ts.map +1 -1
- package/dist/atlas/export.js +9 -3
- package/dist/atlas/export.js.map +1 -1
- package/dist/atlas/families.d.ts +19 -2
- package/dist/atlas/families.d.ts.map +1 -1
- package/dist/atlas/families.js +26 -3
- package/dist/atlas/families.js.map +1 -1
- package/dist/atlas/family.d.ts +27 -0
- package/dist/atlas/family.d.ts.map +1 -0
- package/dist/atlas/family.js +12 -0
- package/dist/atlas/family.js.map +1 -0
- package/dist/atlas/index.d.ts +3 -2
- package/dist/atlas/index.d.ts.map +1 -1
- package/dist/atlas/index.js +2 -1
- package/dist/atlas/index.js.map +1 -1
- package/dist/atlas/link-prediction.d.ts +1 -1
- package/dist/atlas/link-prediction.d.ts.map +1 -1
- package/dist/atlas/link-prediction.js.map +1 -1
- package/dist/atlas/model.js.map +1 -1
- package/dist/atlas/oscillators/bridges-coarse.d.ts.map +1 -1
- package/dist/atlas/oscillators/bridges-coarse.js +0 -1
- package/dist/atlas/oscillators/bridges-coarse.js.map +1 -1
- package/dist/atlas/oscillators/bridges-exact.d.ts.map +1 -1
- package/dist/atlas/oscillators/bridges-exact.js +0 -3
- package/dist/atlas/oscillators/bridges-exact.js.map +1 -1
- package/dist/atlas/oscillators/bridges-limits.d.ts.map +1 -1
- package/dist/atlas/oscillators/bridges-limits.js +0 -2
- package/dist/atlas/oscillators/bridges-limits.js.map +1 -1
- package/dist/atlas/oscillators/dimensions.js.map +1 -1
- package/dist/atlas/oscillators/index.d.ts +1 -16
- package/dist/atlas/oscillators/index.d.ts.map +1 -1
- package/dist/atlas/oscillators/index.js.map +1 -1
- package/dist/atlas/oscillators/limit-witnesses.js.map +1 -1
- package/dist/atlas/oscillators/models.js.map +1 -1
- package/dist/atlas/oscillators/norm-transport-witness.js.map +1 -1
- package/dist/atlas/oscillators/norm-transport.js.map +1 -1
- package/dist/atlas/oscillators/norms.js.map +1 -1
- package/dist/atlas/oscillators/pendulum-motion.js.map +1 -1
- package/dist/atlas/oscillators/phase-carriage.js.map +1 -1
- package/dist/atlas/oscillators/phase-translation.js.map +1 -1
- package/dist/atlas/oscillators/position-translation.js.map +1 -1
- package/dist/atlas/oscillators/rejections.js.map +1 -1
- package/dist/atlas/path-bound.js.map +1 -1
- package/dist/atlas/physjs-entries.generated.js.map +1 -1
- package/dist/atlas/physjs-ref.d.ts +79 -45
- package/dist/atlas/physjs-ref.d.ts.map +1 -1
- package/dist/atlas/physjs-ref.js +143 -62
- package/dist/atlas/physjs-ref.js.map +1 -1
- package/dist/atlas/physjs-reviewed.d.ts +31 -0
- package/dist/atlas/physjs-reviewed.d.ts.map +1 -0
- package/dist/atlas/physjs-reviewed.js +194 -0
- package/dist/atlas/physjs-reviewed.js.map +1 -0
- package/dist/atlas/poster/associations.js.map +1 -1
- package/dist/atlas/poster/derivations.js.map +1 -1
- package/dist/atlas/poster/statements.js.map +1 -1
- package/dist/atlas/proof-target.js.map +1 -1
- package/dist/atlas/public.d.ts +2 -1
- package/dist/atlas/public.d.ts.map +1 -1
- package/dist/atlas/public.js +2 -1
- package/dist/atlas/public.js.map +1 -1
- package/dist/atlas/regime.js.map +1 -1
- package/dist/atlas/serialize.d.ts +18 -12
- package/dist/atlas/serialize.d.ts.map +1 -1
- package/dist/atlas/serialize.js +28 -18
- package/dist/atlas/serialize.js.map +1 -1
- package/dist/atlas/statement.js.map +1 -1
- package/dist/atlas/translation-registry.js.map +1 -1
- package/dist/atlas/translation.js.map +1 -1
- package/dist/atlas/types.d.ts +9 -2
- package/dist/atlas/types.d.ts.map +1 -1
- package/dist/atlas/types.js +1 -1
- package/dist/atlas/types.js.map +1 -1
- package/dist/atlas/waves/bridges-closure.d.ts.map +1 -1
- package/dist/atlas/waves/bridges-closure.js +0 -3
- package/dist/atlas/waves/bridges-closure.js.map +1 -1
- package/dist/atlas/waves/bridges.d.ts.map +1 -1
- package/dist/atlas/waves/bridges.js +0 -4
- package/dist/atlas/waves/bridges.js.map +1 -1
- package/dist/atlas/waves/index.d.ts +1 -1
- package/dist/atlas/waves/index.d.ts.map +1 -1
- package/dist/atlas/waves/index.js.map +1 -1
- package/dist/atlas/waves/models.js.map +1 -1
- package/dist/atlas/waves/numerics.js.map +1 -1
- package/dist/atlas/witness-artifact.js.map +1 -1
- package/dist/atlas/witness-dominance.d.ts +4 -3
- package/dist/atlas/witness-dominance.d.ts.map +1 -1
- package/dist/atlas/witness-dominance.js +15 -5
- package/dist/atlas/witness-dominance.js.map +1 -1
- package/dist/atlas/witness-numeric.d.ts +8 -4
- package/dist/atlas/witness-numeric.d.ts.map +1 -1
- package/dist/atlas/witness-numeric.js +27 -2
- package/dist/atlas/witness-numeric.js.map +1 -1
- package/dist/atlas/witness-result.d.ts +7 -1
- package/dist/atlas/witness-result.d.ts.map +1 -1
- package/dist/atlas/witness-result.js.map +1 -1
- package/dist/atlas/witness-specs.js.map +1 -1
- package/dist/atlas/witness-symbolic.js.map +1 -1
- package/dist/atlas/witnesses/quantum-support.js.map +1 -1
- package/dist/bridges/caller-table.d.ts +1 -1
- package/dist/bridges/caller-table.d.ts.map +1 -1
- package/dist/bridges/caller-table.js.map +1 -1
- package/dist/bridges/carrier-sign.d.ts.map +1 -1
- package/dist/bridges/carrier-sign.js +8 -3
- package/dist/bridges/carrier-sign.js.map +1 -1
- package/dist/bridges/catalog-adapter.d.ts +12 -3
- package/dist/bridges/catalog-adapter.d.ts.map +1 -1
- package/dist/bridges/catalog-adapter.js +17 -9
- package/dist/bridges/catalog-adapter.js.map +1 -1
- package/dist/bridges/catalog-load.d.ts +12 -2
- package/dist/bridges/catalog-load.d.ts.map +1 -1
- package/dist/bridges/catalog-load.js +171 -8
- package/dist/bridges/catalog-load.js.map +1 -1
- package/dist/bridges/catalog-types.d.ts +48 -24
- package/dist/bridges/catalog-types.d.ts.map +1 -1
- package/dist/bridges/catalog-types.js.map +1 -1
- package/dist/bridges/coefficient-statement.js +1 -5
- package/dist/bridges/coefficient-statement.js.map +1 -1
- package/dist/bridges/confrontation-coverage.js.map +1 -1
- package/dist/bridges/confrontations.d.ts +1 -1
- package/dist/bridges/confrontations.d.ts.map +1 -1
- package/dist/bridges/confrontations.js +1 -1
- package/dist/bridges/confrontations.js.map +1 -1
- package/dist/bridges/evaluation-errors.d.ts +15 -2
- package/dist/bridges/evaluation-errors.d.ts.map +1 -1
- package/dist/bridges/evaluation-errors.js +20 -2
- package/dist/bridges/evaluation-errors.js.map +1 -1
- package/dist/bridges/evaluator-inputs.js.map +1 -1
- package/dist/bridges/evaluators.d.ts +17 -2
- package/dist/bridges/evaluators.d.ts.map +1 -1
- package/dist/bridges/evaluators.js +49 -16
- package/dist/bridges/evaluators.js.map +1 -1
- package/dist/bridges/expr-parse.d.ts +27 -4
- package/dist/bridges/expr-parse.d.ts.map +1 -1
- package/dist/bridges/expr-parse.js +90 -10
- package/dist/bridges/expr-parse.js.map +1 -1
- package/dist/bridges/holds.d.ts +5 -1
- package/dist/bridges/holds.d.ts.map +1 -1
- package/dist/bridges/holds.js +18 -3
- package/dist/bridges/holds.js.map +1 -1
- package/dist/bridges/index.d.ts +15 -14
- package/dist/bridges/index.d.ts.map +1 -1
- package/dist/bridges/index.js +14 -15
- package/dist/bridges/index.js.map +1 -1
- package/dist/bridges/input-contract.js.map +1 -1
- package/dist/bridges/membership.d.ts +5 -3
- package/dist/bridges/membership.d.ts.map +1 -1
- package/dist/bridges/membership.js +5 -6
- package/dist/bridges/membership.js.map +1 -1
- package/dist/bridges/notices.js.map +1 -1
- package/dist/bridges/observations/types.js.map +1 -1
- package/dist/bridges/rejected.d.ts +11 -17
- package/dist/bridges/rejected.d.ts.map +1 -1
- package/dist/bridges/rejected.js +13 -68
- package/dist/bridges/rejected.js.map +1 -1
- package/dist/bridges/relation-eval.d.ts +5 -6
- package/dist/bridges/relation-eval.d.ts.map +1 -1
- package/dist/bridges/relation-eval.js +9 -38
- package/dist/bridges/relation-eval.js.map +1 -1
- package/dist/bridges/rhs-registry.js.map +1 -1
- package/dist/bridges/sensitivity.d.ts +11 -3
- package/dist/bridges/sensitivity.d.ts.map +1 -1
- package/dist/bridges/sensitivity.js +24 -10
- package/dist/bridges/sensitivity.js.map +1 -1
- package/dist/bridges/tensor-index.js.map +1 -1
- package/dist/bridges/types.d.ts +1 -7
- package/dist/bridges/types.d.ts.map +1 -1
- package/dist/bridges/types.js +1 -4
- package/dist/bridges/types.js.map +1 -1
- package/dist/canonical/canonical-equation.js.map +1 -1
- package/dist/canonical/dimensional-fields.js.map +1 -1
- package/dist/canonical/entries/_l1-build.js.map +1 -1
- package/dist/canonical/entries/atomic.js.map +1 -1
- package/dist/canonical/entries/condensed-matter.js +4 -4
- package/dist/canonical/entries/condensed-matter.js.map +1 -1
- package/dist/canonical/entries/dimensional-classics.js +2 -2
- package/dist/canonical/entries/dimensional-classics.js.map +1 -1
- package/dist/canonical/entries/electromagnetism.js +2 -2
- package/dist/canonical/entries/electromagnetism.js.map +1 -1
- package/dist/canonical/entries/fluids-waves.js.map +1 -1
- package/dist/canonical/entries/mechanics.js.map +1 -1
- package/dist/canonical/entries/nonmonomial.d.ts.map +1 -1
- package/dist/canonical/entries/nonmonomial.js +29 -22
- package/dist/canonical/entries/nonmonomial.js.map +1 -1
- package/dist/canonical/entries/relativity.js.map +1 -1
- package/dist/canonical/entries/statistical-mechanics.js +5 -5
- package/dist/canonical/entries/statistical-mechanics.js.map +1 -1
- package/dist/canonical/entries/thermo-nuclear-cosmo.js.map +1 -1
- package/dist/canonical/linkage.d.ts +29 -4
- package/dist/canonical/linkage.d.ts.map +1 -1
- package/dist/canonical/linkage.js +31 -29
- package/dist/canonical/linkage.js.map +1 -1
- package/dist/canonical/normal-form.d.ts +0 -8
- package/dist/canonical/normal-form.d.ts.map +1 -1
- package/dist/canonical/normal-form.js +17 -12
- package/dist/canonical/normal-form.js.map +1 -1
- package/dist/canonical/registry.js.map +1 -1
- package/dist/canonical/residual.js.map +1 -1
- package/dist/canonical/seed-l-layer.d.ts +7 -1
- package/dist/canonical/seed-l-layer.d.ts.map +1 -1
- package/dist/canonical/seed-l-layer.js +7 -1
- package/dist/canonical/seed-l-layer.js.map +1 -1
- package/dist/canonical/structural.d.ts +21 -0
- package/dist/canonical/structural.d.ts.map +1 -1
- package/dist/canonical/structural.js +24 -4
- package/dist/canonical/structural.js.map +1 -1
- package/dist/cases/brownian-sphere.js +4 -4
- package/dist/cases/brownian-sphere.js.map +1 -1
- package/dist/cases/damped-resonator.js +2 -2
- package/dist/cases/damped-resonator.js.map +1 -1
- package/dist/cases/index.js.map +1 -1
- package/dist/cases/kepler-rv.js.map +1 -1
- package/dist/cases/lumped-cooling.js +1 -1
- package/dist/cases/lumped-cooling.js.map +1 -1
- package/dist/cases/quadrature.js.map +1 -1
- package/dist/cases/resistor-noise.js +3 -3
- package/dist/cases/resistor-noise.js.map +1 -1
- package/dist/cases/skin-depth.js.map +1 -1
- package/dist/cases/types.js.map +1 -1
- package/dist/cli/args.d.ts +7 -2
- package/dist/cli/args.d.ts.map +1 -1
- package/dist/cli/args.js +18 -2
- package/dist/cli/args.js.map +1 -1
- package/dist/cli/bindings.d.ts +13 -0
- package/dist/cli/bindings.d.ts.map +1 -0
- package/dist/cli/bindings.js +32 -0
- package/dist/cli/bindings.js.map +1 -0
- package/dist/cli/closed-form-range.js.map +1 -1
- package/dist/cli/command.js.map +1 -1
- package/dist/cli/commands/_atlas-map.d.ts +3 -3
- package/dist/cli/commands/_atlas-map.d.ts.map +1 -1
- package/dist/cli/commands/_atlas-map.js +43 -18
- package/dist/cli/commands/_atlas-map.js.map +1 -1
- package/dist/cli/commands/_atlas-route.js.map +1 -1
- package/dist/cli/commands/_discovery-opts.d.ts.map +1 -1
- package/dist/cli/commands/_discovery-opts.js +42 -7
- package/dist/cli/commands/_discovery-opts.js.map +1 -1
- package/dist/cli/commands/atlas.d.ts.map +1 -1
- package/dist/cli/commands/atlas.js +1 -3
- package/dist/cli/commands/atlas.js.map +1 -1
- package/dist/cli/commands/audit.d.ts.map +1 -1
- package/dist/cli/commands/audit.js +13 -20
- package/dist/cli/commands/audit.js.map +1 -1
- package/dist/cli/commands/axes.js.map +1 -1
- package/dist/cli/commands/candidates.d.ts.map +1 -1
- package/dist/cli/commands/candidates.js +16 -8
- package/dist/cli/commands/candidates.js.map +1 -1
- package/dist/cli/commands/canonical.js.map +1 -1
- package/dist/cli/commands/chain.js +1 -1
- package/dist/cli/commands/chain.js.map +1 -1
- package/dist/cli/commands/confront.d.ts.map +1 -1
- package/dist/cli/commands/confront.js +22 -14
- package/dist/cli/commands/confront.js.map +1 -1
- package/dist/cli/commands/connectors.js.map +1 -1
- package/dist/cli/commands/coverage.js.map +1 -1
- package/dist/cli/commands/derive.d.ts.map +1 -1
- package/dist/cli/commands/derive.js +42 -17
- package/dist/cli/commands/derive.js.map +1 -1
- package/dist/cli/commands/discover.d.ts.map +1 -1
- package/dist/cli/commands/discover.js +15 -9
- package/dist/cli/commands/discover.js.map +1 -1
- package/dist/cli/commands/eval.d.ts.map +1 -1
- package/dist/cli/commands/eval.js +13 -10
- package/dist/cli/commands/eval.js.map +1 -1
- package/dist/cli/commands/evaluate.d.ts.map +1 -1
- package/dist/cli/commands/evaluate.js +53 -31
- package/dist/cli/commands/evaluate.js.map +1 -1
- package/dist/cli/commands/explain.d.ts.map +1 -1
- package/dist/cli/commands/explain.js +14 -7
- package/dist/cli/commands/explain.js.map +1 -1
- package/dist/cli/commands/frontier.js.map +1 -1
- package/dist/cli/commands/ground.d.ts.map +1 -1
- package/dist/cli/commands/ground.js +40 -10
- package/dist/cli/commands/ground.js.map +1 -1
- package/dist/cli/commands/index.js.map +1 -1
- package/dist/cli/commands/map.d.ts.map +1 -1
- package/dist/cli/commands/map.js +82 -89
- package/dist/cli/commands/map.js.map +1 -1
- package/dist/cli/commands/metric.d.ts.map +1 -1
- package/dist/cli/commands/metric.js +53 -18
- package/dist/cli/commands/metric.js.map +1 -1
- package/dist/cli/commands/path.js +4 -4
- package/dist/cli/commands/path.js.map +1 -1
- package/dist/cli/commands/predict.js.map +1 -1
- package/dist/cli/commands/priority.js.map +1 -1
- package/dist/cli/commands/probe.d.ts.map +1 -1
- package/dist/cli/commands/probe.js +50 -26
- package/dist/cli/commands/probe.js.map +1 -1
- package/dist/cli/commands/recover.js +1 -1
- package/dist/cli/commands/recover.js.map +1 -1
- package/dist/cli/commands/regime.d.ts +5 -4
- package/dist/cli/commands/regime.d.ts.map +1 -1
- package/dist/cli/commands/regime.js +24 -26
- package/dist/cli/commands/regime.js.map +1 -1
- package/dist/cli/commands/retrieve.d.ts.map +1 -1
- package/dist/cli/commands/retrieve.js +22 -14
- package/dist/cli/commands/retrieve.js.map +1 -1
- package/dist/cli/commands/search.d.ts.map +1 -1
- package/dist/cli/commands/search.js +8 -4
- package/dist/cli/commands/search.js.map +1 -1
- package/dist/cli/commands/symbolic.d.ts.map +1 -1
- package/dist/cli/commands/symbolic.js +13 -9
- package/dist/cli/commands/symbolic.js.map +1 -1
- package/dist/cli/commands/testplan.js +1 -1
- package/dist/cli/commands/testplan.js.map +1 -1
- package/dist/cli/conventions.js.map +1 -1
- package/dist/cli/determination.js.map +1 -1
- package/dist/cli/errors.js.map +1 -1
- package/dist/cli/euler-guard.js.map +1 -1
- package/dist/cli/eval-numbers.js.map +1 -1
- package/dist/cli/expr-print.d.ts +29 -2
- package/dist/cli/expr-print.d.ts.map +1 -1
- package/dist/cli/expr-print.js +46 -2
- package/dist/cli/expr-print.js.map +1 -1
- package/dist/cli/flag-help.js.map +1 -1
- package/dist/cli/graphs.js.map +1 -1
- package/dist/cli/library-defaults.d.ts +19 -0
- package/dist/cli/library-defaults.d.ts.map +1 -0
- package/dist/cli/library-defaults.js +22 -0
- package/dist/cli/library-defaults.js.map +1 -0
- package/dist/cli/main.js +7 -3
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/map-evidence.js.map +1 -1
- package/dist/cli/output.d.ts +3 -6
- package/dist/cli/output.d.ts.map +1 -1
- package/dist/cli/output.js.map +1 -1
- package/dist/cli/published-url.js.map +1 -1
- package/dist/cli/record-reach.d.ts +6 -0
- package/dist/cli/record-reach.d.ts.map +1 -1
- package/dist/cli/record-reach.js +16 -10
- package/dist/cli/record-reach.js.map +1 -1
- package/dist/cli/record-tables.js +1 -1
- package/dist/cli/record-tables.js.map +1 -1
- package/dist/cli/record.d.ts.map +1 -1
- package/dist/cli/record.js +31 -12
- package/dist/cli/record.js.map +1 -1
- package/dist/cli/search-index.d.ts +5 -0
- package/dist/cli/search-index.d.ts.map +1 -1
- package/dist/cli/search-index.js +12 -1
- package/dist/cli/search-index.js.map +1 -1
- package/dist/cli/statuses.js.map +1 -1
- package/dist/cli/top-level-help.js.map +1 -1
- package/dist/cli/version.js.map +1 -1
- package/dist/cli-api.d.ts +15 -9
- package/dist/cli-api.d.ts.map +1 -1
- package/dist/cli-api.js +14 -13
- package/dist/cli-api.js.map +1 -1
- package/dist/composition/adjudication.js.map +1 -1
- package/dist/composition/aliases.js.map +1 -1
- package/dist/composition/audit-coverage.d.ts +2 -0
- package/dist/composition/audit-coverage.d.ts.map +1 -1
- package/dist/composition/audit-coverage.js.map +1 -1
- package/dist/composition/axes.d.ts +12 -0
- package/dist/composition/axes.d.ts.map +1 -1
- package/dist/composition/axes.js +18 -6
- package/dist/composition/axes.js.map +1 -1
- package/dist/composition/axis-audit.js.map +1 -1
- package/dist/composition/bridge-analysis.d.ts +0 -18
- package/dist/composition/bridge-analysis.d.ts.map +1 -1
- package/dist/composition/bridge-analysis.js +57 -47
- package/dist/composition/bridge-analysis.js.map +1 -1
- package/dist/composition/bridge-prediction.d.ts +5 -1
- package/dist/composition/bridge-prediction.d.ts.map +1 -1
- package/dist/composition/bridge-prediction.js +12 -16
- package/dist/composition/bridge-prediction.js.map +1 -1
- package/dist/composition/buckingham-filter.js.map +1 -1
- package/dist/composition/canonical-compare.d.ts.map +1 -1
- package/dist/composition/canonical-compare.js +12 -2
- package/dist/composition/canonical-compare.js.map +1 -1
- package/dist/composition/canonical-graph.d.ts +8 -9
- package/dist/composition/canonical-graph.d.ts.map +1 -1
- package/dist/composition/canonical-graph.js +25 -67
- package/dist/composition/canonical-graph.js.map +1 -1
- package/dist/composition/canonical-json.js.map +1 -1
- package/dist/composition/canonical-prefactors.js.map +1 -1
- package/dist/composition/catalog-graph.d.ts.map +1 -1
- package/dist/composition/catalog-graph.js +6 -20
- package/dist/composition/catalog-graph.js.map +1 -1
- package/dist/composition/chain-candidate.d.ts +2 -0
- package/dist/composition/chain-candidate.d.ts.map +1 -1
- package/dist/composition/chain-candidate.js +2 -0
- package/dist/composition/chain-candidate.js.map +1 -1
- package/dist/composition/chain-match.js.map +1 -1
- package/dist/composition/chain-regime.js.map +1 -1
- package/dist/composition/chain-result.js.map +1 -1
- package/dist/composition/compose-surface.js.map +1 -1
- package/dist/composition/compose-symbolic.js.map +1 -1
- package/dist/composition/compose.d.ts.map +1 -1
- package/dist/composition/compose.js +153 -36
- package/dist/composition/compose.js.map +1 -1
- package/dist/composition/composition-recovery.js.map +1 -1
- package/dist/composition/consequence.d.ts.map +1 -1
- package/dist/composition/consequence.js +15 -6
- package/dist/composition/consequence.js.map +1 -1
- package/dist/composition/consistency.js.map +1 -1
- package/dist/composition/descriptor.d.ts +1 -1
- package/dist/composition/descriptor.d.ts.map +1 -1
- package/dist/composition/descriptor.js.map +1 -1
- package/dist/composition/dimension-adjacency.js.map +1 -1
- package/dist/composition/discovery.d.ts +21 -11
- package/dist/composition/discovery.d.ts.map +1 -1
- package/dist/composition/discovery.js +81 -21
- package/dist/composition/discovery.js.map +1 -1
- package/dist/composition/edge.d.ts +19 -8
- package/dist/composition/edge.d.ts.map +1 -1
- package/dist/composition/edge.js +24 -11
- package/dist/composition/edge.js.map +1 -1
- package/dist/composition/enumerate.d.ts +2 -2
- package/dist/composition/enumerate.d.ts.map +1 -1
- package/dist/composition/enumerate.js.map +1 -1
- package/dist/composition/evaluate-relation.js.map +1 -1
- package/dist/composition/explain.d.ts +14 -9
- package/dist/composition/explain.d.ts.map +1 -1
- package/dist/composition/explain.js +46 -13
- package/dist/composition/explain.js.map +1 -1
- package/dist/composition/expr-eval.js.map +1 -1
- package/dist/composition/expr-simplify.d.ts.map +1 -1
- package/dist/composition/expr-simplify.js +9 -39
- package/dist/composition/expr-simplify.js.map +1 -1
- package/dist/composition/expr-subst.js.map +1 -1
- package/dist/composition/formula-shape.d.ts +9 -0
- package/dist/composition/formula-shape.d.ts.map +1 -1
- package/dist/composition/formula-shape.js +54 -0
- package/dist/composition/formula-shape.js.map +1 -1
- package/dist/composition/frontier-account.d.ts +3 -2
- package/dist/composition/frontier-account.d.ts.map +1 -1
- package/dist/composition/frontier-account.js +7 -3
- package/dist/composition/frontier-account.js.map +1 -1
- package/dist/composition/graph-viz-svg.js.map +1 -1
- package/dist/composition/graph-viz.js.map +1 -1
- package/dist/composition/grounding.js.map +1 -1
- package/dist/composition/identifiability.js.map +1 -1
- package/dist/composition/index.d.ts +6 -4
- package/dist/composition/index.d.ts.map +1 -1
- package/dist/composition/index.js +4 -3
- package/dist/composition/index.js.map +1 -1
- package/dist/composition/mathts-quiet.d.ts +28 -0
- package/dist/composition/mathts-quiet.d.ts.map +1 -0
- package/dist/composition/mathts-quiet.js +56 -0
- package/dist/composition/mathts-quiet.js.map +1 -0
- package/dist/composition/mathts-scalar-symbols.d.ts.map +1 -1
- package/dist/composition/mathts-scalar-symbols.js +18 -34
- package/dist/composition/mathts-scalar-symbols.js.map +1 -1
- package/dist/composition/not-composable-seeds.d.ts +3 -1
- package/dist/composition/not-composable-seeds.d.ts.map +1 -1
- package/dist/composition/not-composable-seeds.js +2 -0
- package/dist/composition/not-composable-seeds.js.map +1 -1
- package/dist/composition/probe/backend-protocol.js.map +1 -1
- package/dist/composition/probe/candidate-store.js.map +1 -1
- package/dist/composition/probe/corpus.js.map +1 -1
- package/dist/composition/probe/dataset.js.map +1 -1
- package/dist/composition/probe/experiment-design.js.map +1 -1
- package/dist/composition/probe/expression-gaps.js.map +1 -1
- package/dist/composition/probe/falsify.d.ts +14 -3
- package/dist/composition/probe/falsify.d.ts.map +1 -1
- package/dist/composition/probe/falsify.js +14 -27
- package/dist/composition/probe/falsify.js.map +1 -1
- package/dist/composition/probe/fingerprint.js.map +1 -1
- package/dist/composition/probe/fit.d.ts +1 -1
- package/dist/composition/probe/fit.d.ts.map +1 -1
- package/dist/composition/probe/fit.js +2 -1
- package/dist/composition/probe/fit.js.map +1 -1
- package/dist/composition/probe/frontier.js.map +1 -1
- package/dist/composition/probe/generator.js.map +1 -1
- package/dist/composition/probe/index.d.ts +4 -2
- package/dist/composition/probe/index.d.ts.map +1 -1
- package/dist/composition/probe/index.js +4 -2
- package/dist/composition/probe/index.js.map +1 -1
- package/dist/composition/probe/limits.js.map +1 -1
- package/dist/composition/probe/metadata.js.map +1 -1
- package/dist/composition/probe/pipeline.d.ts +5 -0
- package/dist/composition/probe/pipeline.d.ts.map +1 -1
- package/dist/composition/probe/pipeline.js +13 -6
- package/dist/composition/probe/pipeline.js.map +1 -1
- package/dist/composition/probe/problem.d.ts +8 -0
- package/dist/composition/probe/problem.d.ts.map +1 -1
- package/dist/composition/probe/problem.js +78 -12
- package/dist/composition/probe/problem.js.map +1 -1
- package/dist/composition/probe/report.js.map +1 -1
- package/dist/composition/probe/residual.js.map +1 -1
- package/dist/composition/probe/run-manifest.js +2 -2
- package/dist/composition/probe/run-manifest.js.map +1 -1
- package/dist/composition/probe/scoring.d.ts +2 -1
- package/dist/composition/probe/scoring.d.ts.map +1 -1
- package/dist/composition/probe/scoring.js +21 -7
- package/dist/composition/probe/scoring.js.map +1 -1
- package/dist/composition/probe/search-budget.js.map +1 -1
- package/dist/composition/probe/serialize.js.map +1 -1
- package/dist/composition/probe/structure.js.map +1 -1
- package/dist/composition/probe/study.d.ts +4 -3
- package/dist/composition/probe/study.d.ts.map +1 -1
- package/dist/composition/probe/study.js +5 -3
- package/dist/composition/probe/study.js.map +1 -1
- package/dist/composition/probe/types.d.ts +3 -1
- package/dist/composition/probe/types.d.ts.map +1 -1
- package/dist/composition/probe/types.js +2 -0
- package/dist/composition/probe/types.js.map +1 -1
- package/dist/composition/proposed-bridges.d.ts +11 -4
- package/dist/composition/proposed-bridges.d.ts.map +1 -1
- package/dist/composition/proposed-bridges.js +11 -4
- package/dist/composition/proposed-bridges.js.map +1 -1
- package/dist/composition/quantities.d.ts +0 -4
- package/dist/composition/quantities.d.ts.map +1 -1
- package/dist/composition/quantities.js +5 -5
- package/dist/composition/quantities.js.map +1 -1
- package/dist/composition/quantity.d.ts +18 -2
- package/dist/composition/quantity.d.ts.map +1 -1
- package/dist/composition/quantity.js +35 -6
- package/dist/composition/quantity.js.map +1 -1
- package/dist/composition/representative-values.js.map +1 -1
- package/dist/composition/retrodiction.d.ts +16 -6
- package/dist/composition/retrodiction.d.ts.map +1 -1
- package/dist/composition/retrodiction.js +34 -9
- package/dist/composition/retrodiction.js.map +1 -1
- package/dist/composition/uncertainty.js.map +1 -1
- package/dist/composition/user-equation.js.map +1 -1
- package/dist/core/axes-registry.d.ts +8 -5
- package/dist/core/axes-registry.d.ts.map +1 -1
- package/dist/core/axes-registry.js.map +1 -1
- package/dist/core/cell.js.map +1 -1
- package/dist/core/constants.d.ts +8 -8
- package/dist/core/constants.d.ts.map +1 -1
- package/dist/core/constants.js +8 -10
- package/dist/core/constants.js.map +1 -1
- package/dist/core/data-file.js.map +1 -1
- package/dist/core/flux-rules.js +1 -1
- package/dist/core/flux-rules.js.map +1 -1
- package/dist/core/json-schema.d.ts +1 -1
- package/dist/core/json-schema.d.ts.map +1 -1
- package/dist/core/json-schema.js +31 -7
- package/dist/core/json-schema.js.map +1 -1
- package/dist/core/labeled-tensor.d.ts +6 -1
- package/dist/core/labeled-tensor.d.ts.map +1 -1
- package/dist/core/labeled-tensor.js +18 -8
- package/dist/core/labeled-tensor.js.map +1 -1
- package/dist/core/regime-registry.d.ts +6 -2
- package/dist/core/regime-registry.d.ts.map +1 -1
- package/dist/core/regime-registry.js.map +1 -1
- package/dist/core/regime-rule-install.js.map +1 -1
- package/dist/core/regimes-builtins.js.map +1 -1
- package/dist/core/tensor.d.ts +7 -4
- package/dist/core/tensor.d.ts.map +1 -1
- package/dist/core/tensor.js +40 -8
- package/dist/core/tensor.js.map +1 -1
- package/dist/core/types.js.map +1 -1
- package/dist/core/universal-index.js.map +1 -1
- package/dist/diff/bridge-ast-gradient.d.ts +4 -5
- package/dist/diff/bridge-ast-gradient.d.ts.map +1 -1
- package/dist/diff/bridge-ast-gradient.js +10 -6
- package/dist/diff/bridge-ast-gradient.js.map +1 -1
- package/dist/diff/bridge-gradient.d.ts +24 -80
- package/dist/diff/bridge-gradient.d.ts.map +1 -1
- package/dist/diff/bridge-gradient.js +21 -98
- package/dist/diff/bridge-gradient.js.map +1 -1
- package/dist/diff/bridge-specs.d.ts +16 -5
- package/dist/diff/bridge-specs.d.ts.map +1 -1
- package/dist/diff/bridge-specs.js +16 -4
- package/dist/diff/bridge-specs.js.map +1 -1
- package/dist/dimensional/algebra.js.map +1 -1
- package/dist/dimensional/ast-builders.d.ts +5 -4
- package/dist/dimensional/ast-builders.d.ts.map +1 -1
- package/dist/dimensional/ast-builders.js +6 -5
- package/dist/dimensional/ast-builders.js.map +1 -1
- package/dist/dimensional/ast-types.js.map +1 -1
- package/dist/dimensional/bridge-check.js.map +1 -1
- package/dist/dimensional/buckingham.js.map +1 -1
- package/dist/dimensional/connection-validators.d.ts +2 -1
- package/dist/dimensional/connection-validators.d.ts.map +1 -1
- package/dist/dimensional/connection-validators.js.map +1 -1
- package/dist/dimensional/connection.js.map +1 -1
- package/dist/dimensional/constant-rows.d.ts.map +1 -1
- package/dist/dimensional/constant-rows.js +9 -5
- package/dist/dimensional/constant-rows.js.map +1 -1
- package/dist/dimensional/constants.d.ts +5 -6
- package/dist/dimensional/constants.d.ts.map +1 -1
- package/dist/dimensional/constants.js +5 -6
- package/dist/dimensional/constants.js.map +1 -1
- package/dist/dimensional/curvature-composite.js.map +1 -1
- package/dist/dimensional/curvature-invariants.js.map +1 -1
- package/dist/dimensional/curvature.js.map +1 -1
- package/dist/dimensional/dimension-inference.js.map +1 -1
- package/dist/dimensional/dimension-spec.d.ts +13 -7
- package/dist/dimensional/dimension-spec.d.ts.map +1 -1
- package/dist/dimensional/dimension-spec.js +49 -23
- package/dist/dimensional/dimension-spec.js.map +1 -1
- package/dist/dimensional/einstein-equation.js.map +1 -1
- package/dist/dimensional/errors.d.ts +3 -1
- package/dist/dimensional/errors.d.ts.map +1 -1
- package/dist/dimensional/errors.js +2 -2
- package/dist/dimensional/errors.js.map +1 -1
- package/dist/dimensional/exact-scale.js.map +1 -1
- package/dist/dimensional/field-equation-helpers.js.map +1 -1
- package/dist/dimensional/formula-names.js.map +1 -1
- package/dist/dimensional/fresh-label.js.map +1 -1
- package/dist/dimensional/friedmann-equation.d.ts +3 -3
- package/dist/dimensional/friedmann-equation.js +3 -3
- package/dist/dimensional/friedmann-equation.js.map +1 -1
- package/dist/dimensional/gauge-field.d.ts +2 -3
- package/dist/dimensional/gauge-field.d.ts.map +1 -1
- package/dist/dimensional/gauge-field.js +0 -1
- package/dist/dimensional/gauge-field.js.map +1 -1
- package/dist/dimensional/hyphen-names.d.ts.map +1 -1
- package/dist/dimensional/hyphen-names.js +8 -0
- package/dist/dimensional/hyphen-names.js.map +1 -1
- package/dist/dimensional/killing-validators.js.map +1 -1
- package/dist/dimensional/klein-gordon-equation.js.map +1 -1
- package/dist/dimensional/metric-validators.d.ts +2 -1
- package/dist/dimensional/metric-validators.d.ts.map +1 -1
- package/dist/dimensional/metric-validators.js.map +1 -1
- package/dist/dimensional/metric.js.map +1 -1
- package/dist/dimensional/natural-units.js.map +1 -1
- package/dist/dimensional/quantity-registry.d.ts +13 -0
- package/dist/dimensional/quantity-registry.d.ts.map +1 -1
- package/dist/dimensional/quantity-registry.js +14 -6
- package/dist/dimensional/quantity-registry.js.map +1 -1
- package/dist/dimensional/rg-flow.js.map +1 -1
- package/dist/dimensional/stress-energy-validators.js.map +1 -1
- package/dist/dimensional/symbolic-constants.d.ts.map +1 -1
- package/dist/dimensional/symbolic-constants.js +7 -2
- package/dist/dimensional/symbolic-constants.js.map +1 -1
- package/dist/dimensional/tensor-trace.js.map +1 -1
- package/dist/dimensional/tensor.js.map +1 -1
- package/dist/dimensional/types.js.map +1 -1
- package/dist/dimensional/unit-convention.d.ts +0 -2
- package/dist/dimensional/unit-convention.d.ts.map +1 -1
- package/dist/dimensional/unit-convention.js +2 -2
- package/dist/dimensional/unit-convention.js.map +1 -1
- package/dist/dimensional/unit-data.d.ts.map +1 -1
- package/dist/dimensional/unit-data.js +9 -5
- package/dist/dimensional/unit-data.js.map +1 -1
- package/dist/dimensional/units.d.ts.map +1 -1
- package/dist/dimensional/units.js +38 -20
- package/dist/dimensional/units.js.map +1 -1
- package/dist/dimensional/validator-registry.js.map +1 -1
- package/dist/dimensional/validator.d.ts +0 -16
- package/dist/dimensional/validator.d.ts.map +1 -1
- package/dist/dimensional/validator.js +65 -29
- package/dist/dimensional/validator.js.map +1 -1
- package/dist/dimensional/weyl-validators.js.map +1 -1
- package/dist/index.d.ts +50 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +12 -20
- package/dist/index.js.map +1 -1
- package/dist/numerical/bianchi-residual.js.map +1 -1
- package/dist/numerical/binding-value.d.ts +11 -6
- package/dist/numerical/binding-value.d.ts.map +1 -1
- package/dist/numerical/binding-value.js +126 -122
- package/dist/numerical/binding-value.js.map +1 -1
- package/dist/numerical/christoffel-flat.js.map +1 -1
- package/dist/numerical/connection-lowering-helpers.js.map +1 -1
- package/dist/numerical/covariant-eikonal.d.ts.map +1 -1
- package/dist/numerical/covariant-eikonal.js +2 -2
- package/dist/numerical/covariant-eikonal.js.map +1 -1
- package/dist/numerical/curvature-lowering-helpers.d.ts +20 -0
- package/dist/numerical/curvature-lowering-helpers.d.ts.map +1 -1
- package/dist/numerical/curvature-lowering-helpers.js +6 -3
- package/dist/numerical/curvature-lowering-helpers.js.map +1 -1
- package/dist/numerical/derivative-lowering.js.map +1 -1
- package/dist/numerical/einstein-equation.js.map +1 -1
- package/dist/numerical/engine-registry.js.map +1 -1
- package/dist/numerical/errors.d.ts +7 -3
- package/dist/numerical/errors.d.ts.map +1 -1
- package/dist/numerical/errors.js +5 -5
- package/dist/numerical/errors.js.map +1 -1
- package/dist/numerical/evaluator-uncertainty.d.ts.map +1 -1
- package/dist/numerical/evaluator-uncertainty.js +19 -2
- package/dist/numerical/evaluator-uncertainty.js.map +1 -1
- package/dist/numerical/formula-contract.d.ts +63 -7
- package/dist/numerical/formula-contract.d.ts.map +1 -1
- package/dist/numerical/formula-contract.js +61 -42
- package/dist/numerical/formula-contract.js.map +1 -1
- package/dist/numerical/formula-dimension.d.ts +8 -7
- package/dist/numerical/formula-dimension.d.ts.map +1 -1
- package/dist/numerical/formula-dimension.js +58 -36
- package/dist/numerical/formula-dimension.js.map +1 -1
- package/dist/numerical/formula-mathts.d.ts.map +1 -1
- package/dist/numerical/formula-mathts.js +5 -2
- package/dist/numerical/formula-mathts.js.map +1 -1
- package/dist/numerical/formula-registry.d.ts +13 -3
- package/dist/numerical/formula-registry.d.ts.map +1 -1
- package/dist/numerical/formula-registry.js +7 -2
- package/dist/numerical/formula-registry.js.map +1 -1
- package/dist/numerical/geodesic-integrator.js.map +1 -1
- package/dist/numerical/geometrized.js.map +1 -1
- package/dist/numerical/gl4-integrator.d.ts +28 -27
- package/dist/numerical/gl4-integrator.d.ts.map +1 -1
- package/dist/numerical/gl4-integrator.js +41 -42
- package/dist/numerical/gl4-integrator.js.map +1 -1
- package/dist/numerical/grid-field.js.map +1 -1
- package/dist/numerical/index.js.map +1 -1
- package/dist/numerical/input-validation.d.ts +3 -6
- package/dist/numerical/input-validation.d.ts.map +1 -1
- package/dist/numerical/input-validation.js +4 -8
- package/dist/numerical/input-validation.js.map +1 -1
- package/dist/numerical/killing.d.ts +8 -5
- package/dist/numerical/killing.d.ts.map +1 -1
- package/dist/numerical/killing.js.map +1 -1
- package/dist/numerical/klein-gordon.js.map +1 -1
- package/dist/numerical/kretschmann.js.map +1 -1
- package/dist/numerical/lowering-utils.js.map +1 -1
- package/dist/numerical/lowering.d.ts.map +1 -1
- package/dist/numerical/lowering.js +7 -17
- package/dist/numerical/lowering.js.map +1 -1
- package/dist/numerical/mathts-engine.d.ts.map +1 -1
- package/dist/numerical/mathts-engine.js +11 -6
- package/dist/numerical/mathts-engine.js.map +1 -1
- package/dist/numerical/metric-inverse.js.map +1 -1
- package/dist/numerical/null-ic.js.map +1 -1
- package/dist/numerical/null-ray-integrator.js +4 -4
- package/dist/numerical/null-ray-integrator.js.map +1 -1
- package/dist/numerical/painleve-gullstrand-metric.js.map +1 -1
- package/dist/numerical/pderiv.d.ts.map +1 -1
- package/dist/numerical/pderiv.js +9 -2
- package/dist/numerical/pderiv.js.map +1 -1
- package/dist/numerical/perihelion-finder.js.map +1 -1
- package/dist/numerical/quadrature.d.ts +5 -2
- package/dist/numerical/quadrature.d.ts.map +1 -1
- package/dist/numerical/quadrature.js +20 -3
- package/dist/numerical/quadrature.js.map +1 -1
- package/dist/numerical/spacetime-metrics.d.ts +13 -19
- package/dist/numerical/spacetime-metrics.d.ts.map +1 -1
- package/dist/numerical/spacetime-metrics.js +126 -248
- package/dist/numerical/spacetime-metrics.js.map +1 -1
- package/dist/numerical/strides.js.map +1 -1
- package/dist/numerical/tensor-engine.d.ts +9 -5
- package/dist/numerical/tensor-engine.d.ts.map +1 -1
- package/dist/numerical/tensor-engine.js.map +1 -1
- package/dist/numerical/types.js.map +1 -1
- package/dist/numerical/weyl-lowering.js.map +1 -1
- package/dist/relations/category.js.map +1 -1
- package/dist/relations/composition-table.d.ts +4 -4
- package/dist/relations/composition-table.js +4 -4
- package/dist/relations/composition-table.js.map +1 -1
- package/dist/relations/conventions.js.map +1 -1
- package/dist/relations/domain-regimes.js.map +1 -1
- package/dist/relations/regime-registration.js.map +1 -1
- package/dist/relations/regime-vocabularies.js.map +1 -1
- package/dist/relations/regime.d.ts +18 -8
- package/dist/relations/regime.d.ts.map +1 -1
- package/dist/relations/regime.js +26 -14
- package/dist/relations/regime.js.map +1 -1
- package/dist/relations/types.d.ts +18 -5
- package/dist/relations/types.d.ts.map +1 -1
- package/dist/relations/types.js +5 -3
- package/dist/relations/types.js.map +1 -1
- package/package.json +10 -14
- package/dist/bridges/registry.d.ts +0 -60
- package/dist/bridges/registry.d.ts.map +0 -1
- package/dist/bridges/registry.js +0 -87
- package/dist/bridges/registry.js.map +0 -1
- package/dist/cli/poster-source.d.ts +0 -154
- package/dist/cli/poster-source.d.ts.map +0 -1
- package/dist/cli/poster-source.js +0 -184
- package/dist/cli/poster-source.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"compose.js","sourceRoot":"","sources":["../../src/composition/compose.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AAI3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,mCAAmC,CAAC;AACrE,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,wBAAwB,EACxB,yBAAyB,GAC1B,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AACvE,0EAA0E;AAC1E,+EAA+E;AAC/E,kEAAkE;AAClE,OAAO,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAC;AACxF,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAG/D;;;;;;;;;;;;;;;;;;;GAmBG;AACH,SAAS,gBAAgB,CACvB,IAA4C,EAC5C,KAAuB,EACvB,MAAwB;IAExB,MAAM,cAAc,GAAG,GAAG,KAAK,CAAC,cAAc,SAAS,MAAM,CAAC,cAAc,EAAE,CAAC;IAC/E,IAAI,IAAI,KAAK,mBAAmB,EAAE,CAAC;QACjC,2EAA2E;QAC3E,6CAA6C;QAC7C,MAAM,EAAE,GAAI,KAAkE,CAAC,OAAO,CAAC;QACvF,MAAM,EAAE,GAAI,MAAmE,CAAC,OAAO,CAAC;QACxF,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,OAAO,EAAE,GAAG,EAAE,SAAS,E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,EAAE,CAAC;YAC9G,GAAG,CAAC,QAAQ,GAAG,IAAI,CAAC;QACtB,CAAC;IACH,CAAC;IAED,OAAO,GAAG,CAAC;AACb,CAAC","sourcesContent":["/**\n * Composition graph — the composition operator (v0.8.0 T2/T4, per\n * docs/planning/v0.8.0-Design.md §3 + r2 deltas).\n *\n * `composeEdges(first, second)` pipes `first`'s output quantity into a\n * matching source of `second`, producing a NEW `BridgeEdge` (design\n * D-2 — composition closes over the edge type, so chains nest\n * arbitrarily). Defined iff:\n *\n * 1. `first.target` matches one of `second.sources` — by canonical\n * name, or via an explicit {@link QuantityIdentification} (the\n * reviewable physics judgments, e.g. \"the Hawking temperature IS\n * the temperature in Landauer's bound\");\n * 2. the junction dimensions are EXACTLY equal (the dimension-functor\n * check — ℤ⁷ integer-vector equality via the dimensional\n * calculus's `equals`);\n * 3. domains conjoin THROUGH the pipe (design D-5): the composed\n * domain checks `first`'s domain on the outer inputs and\n * `second`'s domain on the piped intermediate value. This\n * evaluates `first.evaluate` inside the predicate — acceptable\n * for scalar closed forms.\n *\n * Confidence demotes: `min(first, second)` on\n * established > speculative > highly-speculative. Composition never\n * launders credibility (improvement-plan confidence algebra).\n *\n * Operator is named `composeEdges` (NOT `compose`) — `compose` is the\n * public v0.7 Cell factory in `src/core/cell.ts` (Adam A-1).\n *\n * @module composition/compose\n */\n\nimport { equals, format } from '../dimensional/algebra.js';\nimport type { Dimension } from '../dimensional/types.js';\nimport { validate } from '../dimensional/validator.js';\nimport type { ExprNode } from '../dimensional/validator.js';\nimport type { BridgeEdge, EdgeConfidence } from './edge.js';\nimport type { Quantity, RegimeAttributes } from './quantity.js';\nimport { regimeAttributesOf } from './quantity.js';\nimport { AXES } from './axes.js';\nimport { conventionFactor } from '../dimensional/unit-convention.js';\nimport {\n assertCoefficientSet,\n CompositionAliasError,\n CompositionDimensionError,\n CompositionJunctionError,\n UndefinedCompositionError,\n} from './edge.js';\nimport { DomainViolationError } from '../bridges/evaluation-errors.js';\nimport { substitute } from './expr-subst.js';\nimport { monomialExponents } from './formula-shape.js';\n// Atlas Phase 1 overlay. The composition table is a leaf module (pure, no\n// registry reads, no import from `src/composition/`), so this does not close a\n// cycle — same rule as the type-only atlas import in `./edge.ts`.\nimport { composeRelation, NO_COMPOSITE_CLAIM } from '../relations/composition-table.js';\nimport { checkConventions } from '../relations/conventions.js';\nimport { intersectRegimes } from '../relations/regime.js';\nimport type { Conventions, Regime, RelationContract, RelationType } from '../relations/types.js';\n\n/**\n * The `RelationContract` a composed edge carries, given the composite TYPE the\n * table returned and the two operand contracts.\n *\n * Only four types can be returned by the table (`derivation`,\n * `exact-equivalence`, `restriction`, `coarse-graining`); the other four appear\n * only as operands. `exact-equivalence` is produced by exactly one cell —\n * `exact-equivalence ∘ exact-equivalence` — so both operands are guaranteed to\n * carry the `inverse` its contract requires, and the composed inverse undoes\n * the second map first.\n *\n * NOT composed here: an `ApproximationBound`. `coarse-graining ∘\n * coarse-graining` accumulates error through `composeBounds`\n * (`src/atlas/error-algebra.ts`), which the implementation plan wires in as a\n * SEPARATE task behind this same guard. Until then the composite states its\n * type and no bound — it does not restate either operand's bound, which would\n * be a narrower error claim than the chain supports.\n *\n * @internal\n */\nfunction composedContract(\n type: Exclude<RelationType, 'approximation'>,\n first: RelationContract,\n second: RelationContract,\n): RelationContract {\n const transformation = `${first.transformation} then ${second.transformation}`;\n if (type === 'exact-equivalence') {\n // Guarded by the table: only exact ∘ exact yields exact, and that contract\n // makes `inverse` REQUIRED on both operands.\n const fi = (first as Extract<RelationContract, { type: 'exact-equivalence' }>).inverse;\n const si = (second as Extract<RelationContract, { type: 'exact-equivalence' }>).inverse;\n return { type, transformation, inverse: `${si} then ${fi}` };\n }\n return { type, transformation };\n}\n\n/**\n * A reviewable quantity-identification judgment: the assertion that\n * the quantity named `from` (an edge's target) IS the quantity named\n * `to` (another edge's source), with the physics rationale on record.\n *\n * @public\n */\nexport interface QuantityIdentification {\n readonly from: string;\n readonly to: string;\n readonly rationale: string;\n readonly citation?: string;\n}\n\n/**\n * Registered identifications (v0.8.0 CT-1). Each entry is a physics\n * judgment intended for review — see CONTRIBUTING.md.\n *\n * @public\n */\nexport const QUANTITY_IDENTIFICATIONS: readonly QuantityIdentification[] = [\n {\n from: 'hawking-temperature',\n to: 'temperature',\n rationale:\n 'The Hawking temperature of a black-hole horizon is a genuine ' +\n 'thermodynamic temperature — the temperature appearing in ' +\n \"Landauer's bound for erasure at the horizon. This is the \" +\n 'standard identification underlying black-hole thermodynamics ' +\n '(the horizon radiates as a black body at T_H).',\n citation: 'Hawking 1975 CMP 43:199; Bekenstein 1973 PRD 7:2333',\n },\n {\n from: 'de-broglie-wavelength',\n to: 'compton-wavelength',\n rationale:\n 'The de Broglie wavelength λ = h/p and the Compton wavelength ' +\n 'λ_C = h/(mc) are the SAME matter-wavelength quantity of a massive ' +\n 'particle; the Compton wavelength is its value in the relativistic ' +\n 'limit p = mc (v → c). They are equal only in that limit, but at the ' +\n 'composition graph’s quantity-KIND resolution they name one node. ' +\n 'Folded ONTO compton-wavelength (not the reverse) because that node is ' +\n 'anchor-determinable (ℏ/mc from a mass) and carries the sourced atomic ' +\n 'scale the magnitude gate needs; de-broglie’s own form needs a ' +\n 'momentum the single-mass anchor does not supply.',\n citation: 'de Broglie 1924; Compton 1923 Phys. Rev. 21:483',\n },\n {\n from: 'thermal-de-broglie-wavelength',\n to: 'thermal-wavelength',\n rationale:\n 'The catalog names the thermal de Broglie wavelength ' +\n 'λ_T = √(2πℏ²/(m k_B T)) `thermal-de-broglie-wavelength` (BE-11 Zurek ' +\n 'decoherence, BE-12 Caldeira–Leggett coherence length), while the ' +\n 'canonical L-layer law `CE-thermal-de-broglie` names the SAME physical ' +\n 'quantity `thermal-wavelength`. They are one node. Folded ONTO the ' +\n 'canonical `thermal-wavelength` (anchor-determinable: √(2πℏ²/(m k_B T)) ' +\n 'from a mass + temperature), reconnecting BE-11 — an ESTABLISHED bridge — ' +\n 'to standard physics (surfaced by the bridges-vs-canonical map; the link ' +\n 'was hidden purely by the name divergence).',\n citation: 'de Broglie 1924; standard statistical mechanics (λ_T)',\n },\n];\n\n/**\n * Effective regime attributes for a candidate NAME, resolved through the\n * `QUANTITY_IDENTIFICATIONS` fold — the SINGLE shared implementation every\n * attribute consumer must use (Eve r3 #2 mandate; the discovery-hardening\n * Phase-2 axis-compatibility gate is the first). `attributesByName` is the\n * REGISTRY-only source (never canonical per-equation stamps — Option-A,\n * audit adjudication F1): callers supply it (production: every centralized\n * `Quantity.attributes`; tests: an injected fixture map), this function only\n * does the fold resolution.\n *\n * Candidate names are already fold-canonicalized (the `to` side of an\n * identification); this additionally pulls in every `from` contributor that\n * folds ONTO `name` and, per axis, unions their stated value with `name`'s\n * own. Where contributors DISAGREE on an axis, the axis counts as UNSTATED\n * (conflict → abstain) rather than picking a side — the fold-conflict rule.\n *\n * @internal\n */\nexport function effectiveAttributes(\n name: string,\n attributesByName: ReadonlyMap<string, RegimeAttributes>,\n idents: readonly QuantityIdentification[] = QUANTITY_IDENTIFICATIONS,\n): RegimeAttributes {\n const contributors: RegimeAttributes[] = [];\n const own = attributesByName.get(name);\n if (own) contributors.push(own);\n for (const id of idents) {\n if (id.to !== name) continue;\n const folded = attributesByName.get(id.from);\n if (folded) contributors.push(folded);\n }\n\n // One-value-agrees, zero-or-conflicting-values-abstain, per REGISTRY axis.\n // The fold reads `AXES`, so an axis the registry carries is folded here: a\n // hand list once named scale, force and information only, and the\n // discrimination audit then measured symmetry, topology and statistics as\n // `checked: 0` whatever the data said (9.0.0 audit §4 C2).\n const folded: Record<string, string> = {};\n for (const { name } of AXES) {\n const values = new Set(\n contributors.map((c) => (c as Readonly<Record<string, string | undefined>>)[name]).filter((v) => v !== undefined),\n );\n if (values.size === 1) folded[name] = [...values][0]!;\n }\n return regimeAttributesOf(folded, `effectiveAttributes(${name})`);\n}\n\n/**\n * A recorded aliasing judgment for one duplicate source name in a\n * composition (v0.11 Option D). `'shared'` = one input deliberately\n * feeds both slots (e.g. ST-2: one M is both the lens and the r_s\n * source). `renameSecond` = split the collision: the SECOND operand's\n * quantity is renamed, and the composed evaluator remaps the renamed\n * input key back to the operand's internal name (vet A-4 — without the\n * remap the rename is a no-op).\n *\n * @public\n */\nexport interface AliasDisposition {\n readonly name: string;\n readonly treatAs: 'shared' | { readonly renameSecond: string };\n readonly rationale: string;\n readonly citation?: string;\n}\n\n/**\n * Registered alias dispositions, keyed by composed id\n * (`first.id>>second.id`) — judgments live in reviewable registry\n * data, mirroring {@link QUANTITY_IDENTIFICATIONS} (vet A-6.2).\n *\n * @public\n */\nexport const SOURCE_ALIAS_DISPOSITIONS: Readonly<\n Record<string, readonly AliasDisposition[]>\n> = {\n // Empty. The one entry this table held, `law-schwarzschild-radius>>be-51`\n // (\"ST-2\": one M is both the lens and the r_s source), keyed a composition\n // no call can reach: the law's target `schwarzschild-radius` matches none\n // of be-51's sources (`mass`, `impact-parameter`) by name or registered\n // identification, so `composeEdges` throws `CompositionJunctionError`\n // before the alias gate runs. The judgment was never applied. Retracted in\n // the 9.0.0 audit (§4 C8); `tests/composition/compose.test.ts` now requires\n // every key here to reach the gate.\n};\n\nconst CONFIDENCE_RANK: Record<EdgeConfidence, number> = {\n established: 2,\n speculative: 1,\n 'highly-speculative': 0,\n};\n\n/**\n * Confidence demotion: the min of the two grades on the ordering\n * established > speculative > highly-speculative.\n *\n * @public\n */\nexport function minConfidence(\n a: EdgeConfidence,\n b: EdgeConfidence,\n): EdgeConfidence {\n return CONFIDENCE_RANK[a] <= CONFIDENCE_RANK[b] ? a : b;\n}\n\n/** Options for {@link composeEdges}. @public */\nexport interface ComposeOptions {\n /** Extra identifications, consulted after the registered ones. */\n readonly identifications?: readonly QuantityIdentification[];\n /**\n * Alias dispositions for duplicate source names (v0.11 Option D);\n * consulted after {@link SOURCE_ALIAS_DISPOSITIONS} entries for the\n * composed id.\n */\n readonly aliases?: readonly AliasDisposition[];\n}\n\nfunction findJunction(\n first: BridgeEdge,\n second: BridgeEdge,\n identifications: readonly QuantityIdentification[],\n): {\n junction: BridgeEdge['sources'][number];\n /** Position in `second.sources`: the slot the pipe fills. One slot, even when the same object sits twice. */\n index: number;\n viaIdentification: QuantityIdentification | null;\n} {\n for (const [index, src] of second.sources.entries()) {\n if (src.name === first.target.name) {\n return { junction: src, index, viaIdentification: null };\n }\n }\n for (const ident of identifications) {\n if (ident.from !== first.target.name) continue;\n for (const [index, src] of second.sources.entries()) {\n if (src.name === ident.to) {\n return { junction: src, index, viaIdentification: ident };\n }\n }\n }\n throw new CompositionJunctionError(\n `Cannot compose ${first.id} -> ${second.id}: target quantity ` +\n `'${first.target.name}' matches none of [${second.sources\n .map((s) => `'${s.name}'`)\n .join(', ')}] by name or registered identification`,\n );\n}\n\n/**\n * The two sides of a composition pipe have the same dimension.\n *\n * This is the check `composeEdges` already applied: `equals` on the seven\n * SI bases, including that function's exponent tolerance. A mismatch is\n * still {@link CompositionDimensionError}.\n *\n * @internal\n */\nexport function junctionDimensionsMatch(left: Dimension, right: Dimension): boolean {\n return equals(left, right);\n}\n\n/**\n * Compose two edges into a new edge (sequential composition through a\n * shared quantity). See module docs for the definedness conditions.\n *\n * The composed edge's `sources` are `first.sources` followed by\n * `second`'s remaining (non-junction) sources; `kind` is `'law'` only\n * when both operands are laws; `beId` is null (a derived relation has\n * no single catalog row).\n *\n * @public\n */\nexport function composeEdges(\n first: BridgeEdge,\n second: BridgeEdge,\n opts: ComposeOptions = {},\n): BridgeEdge {\n const identifications = [\n ...QUANTITY_IDENTIFICATIONS,\n ...(opts.identifications ?? []),\n ];\n const { junction, index: junctionIndex, viaIdentification } = findJunction(\n first,\n second,\n identifications,\n );\n\n if (!junctionDimensionsMatch(first.target.dim, junction.dim)) {\n throw new CompositionDimensionError(\n `Cannot compose ${first.id} -> ${second.id}: junction dimension ` +\n `mismatch — ${first.target.name} is ${format(first.target.dim)} ` +\n `but ${junction.name} is ${format(junction.dim)}`,\n );\n }\n const junctionScale =\n viaIdentification === null\n ? 1\n : conventionFactor(first.target.name, junction.name);\n\n // The pipe fills ONE slot of `second.sources`, the one `findJunction`\n // returned. Removal by object identity would also drop a second slot that\n // holds the same `Quantity` object, which a `shared` disposition produces.\n const remainingSources = second.sources.filter((_, i) => i !== junctionIndex);\n\n // v0.11 Option D (namespacing gate): pure name-collision rule across\n // operands. Intra-operand duplicates (e.g. ['mass','mass'] inherited\n // from a prior 'shared' disposition) are exempt by construction —\n // only names present in BOTH first.sources and second's remaining\n // sources are collisions, and each needs a recorded disposition.\n const firstNames = new Set(first.sources.map((s) => s.name));\n const collisionNames = [\n ...new Set(\n remainingSources\n .filter((s) => firstNames.has(s.name))\n .map((s) => s.name),\n ),\n ];\n const composedId = `${first.id}>>${second.id}`;\n const dispositions: AliasDisposition[] = [\n ...(SOURCE_ALIAS_DISPOSITIONS[composedId] ?? []),\n ...(opts.aliases ?? []),\n ];\n const renameMap: Record<string, string> = {}; // renamed key -> operand-internal name\n const dispositionsUsed: AliasDisposition[] = [];\n let finalRemaining: Quantity[] = [...remainingSources];\n for (const name of collisionNames) {\n const d = dispositions.find((x) => x.name === name);\n if (!d) {\n throw new CompositionAliasError(\n `Cannot compose ${composedId}: source quantity '${name}' appears ` +\n `in BOTH operands (first: [${[...firstNames].join(', ')}]; ` +\n `second remaining: [${remainingSources\n .map((s) => s.name)\n .join(', ')}]). Same name does not imply same physical ` +\n `quantity — record an AliasDisposition ('shared' or ` +\n `{renameSecond}) in SOURCE_ALIAS_DISPOSITIONS or opts.aliases.`,\n );\n }\n dispositionsUsed.push(d);\n if (d.treatAs === 'shared') continue; // one input key feeds both slots\n const renamed = d.treatAs.renameSecond;\n if (\n firstNames.has(renamed) ||\n second.sources.some((s) => s.name === renamed)\n ) {\n throw new CompositionAliasError(\n `Cannot compose ${composedId}: renameSecond target '${renamed}' ` +\n `collides with an existing source name of an operand (vet A-4).`,\n );\n }\n finalRemaining = finalRemaining.map((s) =>\n s.name === name ? { ...s, name: renamed, symbol: s.symbol } : s,\n );\n renameMap[renamed] = name;\n }\n\n /** Build the second operand's input map: remap renamed keys back to\n * the operand-internal names (shadowing the first operand's value\n * for that name — vet A-4's required remap), then pipe the junction. */\n const buildSecondInputs = (\n inputs: Record<string, number>,\n intermediate: number,\n ): Record<string, number> => {\n const si: Record<string, number> = { ...inputs };\n for (const [renamed, original] of Object.entries(renameMap)) {\n si[original] = inputs[renamed];\n delete si[renamed];\n }\n si[junction.name] = intermediate * junctionScale;\n return si;\n };\n\n const composedDomain = {\n description:\n `(${first.domain.description}) AND, on the piped ` +\n `${junction.name}, (${second.domain.description})`,\n // Standalone domain queries evaluate `first` to obtain the piped\n // intermediate (design D-5; acceptable for scalar closed forms).\n // The composed `evaluate` below does NOT call this predicate — it\n // computes the intermediate once and checks both domains inline\n // (v0.8.0 punch-list: removed the double evaluation of `first`).\n predicate: (inputs: Record<string, number>): boolean => {\n if (!first.domain.predicate(inputs)) return false;\n const intermediate = first.evaluate(inputs);\n return second.domain.predicate(buildSecondInputs(inputs, intermediate));\n },\n };\n\n const id = `${first.id}>>${second.id}`;\n\n // ── Atlas Phase 1 (S1.2b): the relation overlay, and NOTHING else. ────────\n // Entered only when BOTH operands carry a `relation`. An operand with no\n // relation skips this block, and the composed edge then has no `relation`\n // key. The catalog edges that carry one are the catalog's `relation` rows\n // (`tests/composition/relation-refusal.test.ts` lists them); they stay.\n // When both operands carry a relation, a silent table cell throws\n // `UndefinedCompositionError`. The approximation cell throws the same\n // error, because an edge relation carries no norm transport and this\n // layer does not invent a bound. `enumerateCompositionsWithRefusals`\n // records that throw on its own list. A dimension or junction failure\n // is a different error and is not that list.\n let relationOverlay: Pick<\n BridgeEdge,\n 'relation' | 'relationDerivedFrom' | 'conventions'\n > = {};\n if (first.relation !== undefined && second.relation !== undefined) {\n const composite = composeRelation(first.relation.type, second.relation.type);\n if (composite === NO_COMPOSITE_CLAIM) {\n throw new UndefinedCompositionError(\n `Cannot compose ${first.id} -> ${second.id}: the composition table ` +\n `asserts no composite relation for '${first.relation.type}' ` +\n `(${first.id}) followed by '${second.relation.type}' ` +\n `(${second.id}). This is silence, not refutation — see ` +\n `docs/planning/Atlas-Phase-1-Design.md §2.2.`,\n );\n }\n if (composite === 'approximation') {\n // Reachable since the table's one widening: approximation then\n // exact-equivalence (docs/planning/ADR-transported-norm-composition.md).\n // An `approximation` contract REQUIRES an `ApproximationBound`, and the\n // composed bound exists only when the exact map declares a norm\n // transport. A `RelationContract` on an edge carries none, so this layer\n // cannot compose the bound and must refuse rather than fabricate one.\n // The atlas route layer (`boundPath`) is where a declared transport is\n // applied.\n throw new UndefinedCompositionError(\n `Cannot compose ${first.id} -> ${second.id}: the composition table ` +\n `returned 'approximation', which requires a composed ` +\n `ApproximationBound; an edge relation declares no norm transport, ` +\n `so no bound is composed here (the atlas boundPath applies declared transports).`,\n );\n }\n // Conventions carry forward only when the operands do not CONTRADICT each\n // other. `checkConventions` treats an undeclared key as unknown, so a\n // silent operand never blocks the carry-forward; a genuine disagreement\n // does, and then the composite declares no conventions at all rather than\n // picking one operand's choice over the other's. One rule, not a per-key\n // filter: a chain built across a sign disagreement has no single first-law\n // convention to state, and stating one would be a claim about the chain\n // that neither operand supports.\n const merged: Conventions =\n checkConventions(first.conventions, second.conventions).length === 0\n ? { ...first.conventions, ...second.conventions }\n : {};\n relationOverlay = {\n relation: composedContract(composite, first.relation, second.relation),\n relationDerivedFrom: [first.id, second.id],\n ...(Object.keys(merged).length > 0 ? { conventions: merged } : {}),\n };\n }\n\n return {\n id,\n beId: null,\n kind: first.kind === 'law' && second.kind === 'law' ? 'law' : 'bridge',\n label: `${first.label} ∘ ${second.label}`,\n sources: [...first.sources, ...finalRemaining],\n target: second.target,\n confidence: minConfidence(first.confidence, second.confidence),\n domain: composedDomain,\n evaluate: (inputs) => {\n if (!first.domain.predicate(inputs)) {\n throw new DomainViolationError(\n `${id}: inputs violate composed validity domain ` +\n `(${composedDomain.description})`,\n );\n }\n // Each operand's unset-coefficient gate is the one `evaluateEdge`\n // applies to a primitive edge; an operand's monomial times an absent 1\n // must not reach the caller as a number through the pipe.\n assertCoefficientSet(first, inputs);\n const intermediate = first.evaluate(inputs);\n const pipedInputs = buildSecondInputs(inputs, intermediate);\n if (!second.domain.predicate(pipedInputs)) {\n throw new DomainViolationError(\n `${id}: inputs violate composed validity domain ` +\n `(${composedDomain.description})`,\n );\n }\n assertCoefficientSet(second, pipedInputs);\n return second.evaluate(pipedInputs);\n },\n citation: `${first.citation} | ${second.citation}`,\n ...(viaIdentification !== null\n ? { identificationUsed: viaIdentification }\n : {}),\n ...(dispositionsUsed.length > 0\n ? { aliasDispositionsUsed: dispositionsUsed }\n : {}),\n ...relationOverlay,\n ...carriedClaims(first, second, junction, junctionScale, finalRemaining, renameMap),\n };\n}\n\n/**\n * The claims a composed edge carries from its operands (9.0.0 audit §4 C5).\n * A composed edge that dropped them answered differently from its operands:\n * the regime gate abstained on every chain longer than two, an unset\n * coefficient became a number, an even input lost its magnitude reading,\n * a count became a Buckingham governor, and an alias key stopped working.\n *\n * - `regime`: the one an operand states; two of one family intersect\n * (`intersectRegimes`, which also refuses conflicting group definitions);\n * two of different families refuse with `UndefinedCompositionError`, since\n * this layer does not state where a cross-family chain applies.\n * - `coefficientUnset`: either operand's. `evaluateEdge` then refuses the\n * composite; a bound group lifts a primitive entry only, because the group\n * row is keyed by the entry id, so a composite with an unset operand is\n * refused by `evaluateEdge` whatever is bound (its own `evaluate` applies\n * each operand's gate and does lift the operand whose group is bound).\n * - `evenInputs`, `aliases`: the first operand's, plus the second's for its\n * remaining sources under their composed names. The piped junction is not\n * an input and is dropped. An alias key that two quantities would share is\n * carried for neither.\n * - `formulaFactors`: the second operand's for its remaining sources, exact.\n * The first operand's counts enter through the pipe with their exponent\n * times the junction's exponent in the second's monomial, so they are\n * carried only when `second.symbolic` is a monomial that states it.\n * - `symbolic`: the second's form with the junction leaf replaced by the\n * first's, when both exist, the junction carries no convention factor, no\n * source was renamed, the leaf occurs, and the result validates to the\n * target dimension. Otherwise absent, as on a numeric-only edge.\n */\nfunction carriedClaims(\n first: BridgeEdge,\n second: BridgeEdge,\n junction: Quantity,\n junctionScale: number,\n finalRemaining: readonly Quantity[],\n renameMap: Readonly<Record<string, string>>,\n): Pick<BridgeEdge, 'regime' | 'coefficientUnset' | 'evenInputs' | 'formulaFactors' | 'aliases' | 'symbolic'> {\n const out: {\n regime?: Regime;\n coefficientUnset?: boolean;\n evenInputs?: readonly string[];\n formulaFactors?: Readonly<Record<string, number>>;\n aliases?: Readonly<Record<string, readonly string[]>>;\n symbolic?: ExprNode;\n } = {};\n\n if (first.regime !== undefined && second.regime !== undefined) {\n if (first.regime.family !== second.regime.family) {\n throw new UndefinedCompositionError(\n `Cannot compose ${first.id} -> ${second.id}: the regimes are of different ` +\n `families ('${first.regime.family}', '${second.regime.family}'), and this ` +\n `layer does not state where a cross-family chain applies.`,\n );\n }\n try {\n out.regime = intersectRegimes(first.regime, second.regime);\n } catch (e) {\n // Conflicting definitions of one group name: the composite has no regime this\n // layer can state, the same refusal as a cross-family chain.\n throw new UndefinedCompositionError(`Cannot compose ${first.id} -> ${second.id}: ${(e as Error).message}`);\n }\n } else if (first.regime !== undefined || second.regime !== undefined) {\n out.regime = first.regime ?? second.regime;\n }\n\n if (first.coefficientUnset === true || second.coefficientUnset === true) out.coefficientUnset = true;\n\n // Operand-internal name → the name the composite exposes it under.\n const composedName = new Map(Object.entries(renameMap).map(([renamed, original]) => [original, renamed]));\n const exposed = (name: string): string => composedName.get(name) ?? name;\n const remainingNames = new Set(finalRemaining.map((s) => s.name));\n const secondRemaining = (name: string): boolean => name !== junction.name && remainingNames.has(exposed(name));\n\n const even = [\n ...(first.evenInputs ?? []),\n ...(second.evenInputs ?? []).filter(secondRemaining).map(exposed),\n ];\n if (even.length > 0) out.evenInputs = even;\n\n const factors: Record<string, number> = {};\n const junctionExponent = monomialExponents(second.symbolic)?.get(junction.name);\n if (first.formulaFactors !== undefined && junctionExponent !== undefined) {\n for (const [name, exp] of Object.entries(first.formulaFactors)) factors[name] = exp * junctionExponent;\n }\n for (const [name, exp] of Object.entries(second.formulaFactors ?? {})) {\n if (secondRemaining(name)) factors[exposed(name)] = exp;\n }\n if (Object.keys(factors).length > 0) out.formulaFactors = factors;\n\n const aliasOwner = new Map<string, string>();\n const shared = new Set<string>();\n const aliases: Record<string, string[]> = {};\n const addAliases = (quantity: string, keys: readonly string[]): void => {\n for (const key of keys) {\n const owner = aliasOwner.get(key);\n if (owner !== undefined && owner !== quantity) shared.add(key);\n aliasOwner.set(key, quantity);\n (aliases[quantity] ??= []).push(key);\n }\n };\n for (const [quantity, keys] of Object.entries(first.aliases ?? {})) addAliases(quantity, keys);\n for (const [quantity, keys] of Object.entries(second.aliases ?? {})) {\n if (secondRemaining(quantity)) addAliases(exposed(quantity), keys);\n }\n const kept = Object.fromEntries(\n Object.entries(aliases)\n .map(([quantity, keys]) => [quantity, keys.filter((k) => !shared.has(k))] as const)\n .filter(([, keys]) => keys.length > 0),\n );\n if (Object.keys(kept).length > 0) out.aliases = kept;\n\n if (\n first.symbolic !== undefined &&\n second.symbolic !== undefined &&\n junctionScale === 1 &&\n Object.keys(renameMap).length === 0\n ) {\n const { expr, count } = substitute(second.symbolic, junction.name, first.symbolic);\n const v = count > 0 ? validate(expr) : undefined;\n if (v !== undefined && v.ok && v.inferredDimension !== null && equals(v.inferredDimension, second.target.dim)) {\n out.symbolic = expr;\n }\n }\n\n return out;\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"composition-recovery.js","sourceRoot":"","sources":["../../src/composition/composition-recovery.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAC/D,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAC;AAyBlF,SA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,OAAO,CAAC,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAC9E,IAAI,MAAM,KAAK,CAAC;YAAE,OAAO,MAAM,CAAC;QAChC,OAAO,CAAC,CAAC,WAAW,GAAG,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,WAAW,GAAG,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACpF,CAAC,CAAC,CAAC;IACH,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;AACzB,CAAC","sourcesContent":["/**\n * Composition-derived recovery.\n *\n * Single-bridge linkage asks whether one bridge RHS is a canonical equation.\n * This asks the same question of a chain of two edges that both carry a\n * symbolic form. The comparison is `normalForm`: the same relation up to a\n * dimensionless factor. Dimensionful cancellation is not applied, so an\n * unsimplified chain is not rewritten into a simpler formula.\n *\n * A chain is never `restates-canonical`. That label is the F4 guard on one\n * bridge the registry already names. A chain is a derivation, and a\n * structural match is `recovers`.\n *\n * @module composition/composition-recovery\n * @internal\n */\n\nimport { CANONICAL_EQUATIONS } from '../canonical/registry.js';\nimport { normalForm } from '../canonical/normal-form.js';\nimport { CATALOG_GRAPH } from './catalog-graph.js';\nimport { composeSymbolic, SymbolicCompositionError } from './compose-symbolic.js';\nimport type { BridgeEdge } from './edge.js';\n\n/** One ordered pair of edges that composed. @internal */\nexport interface CompositionRecoveryPair {\n readonly firstId: string;\n readonly secondId: string;\n}\n\n/**\n * A chain whose normal form equals a canonical scalar AST.\n * `classification` is always `recovers`.\n * @internal\n */\nexport interface CompositionRecoveryHit extends CompositionRecoveryPair {\n readonly canonicalId: string;\n readonly classification: 'recovers';\n}\n\n/** The chains that were searched, and the ones that matched. @internal */\nexport interface CompositionRecoveryScan {\n readonly pairs: readonly CompositionRecoveryPair[];\n readonly hits: readonly CompositionRecoveryHit[];\n}\n\nfunction pairKey(pair: CompositionRecoveryPair): string {\n return `${pair.firstId}\\0${pair.secondId}`;\n}\n\n/**\n * Search two-edge symbolic chains against the canonical registry.\n *\n * The default edge list is the catalog graph. A caller may pass a shorter\n * list; the canonical side stays the registry. Pairs that cannot compose\n * are not examined. Order is by edge id, then canonical id.\n *\n * @internal\n */\nexport function scanCompositionRecovery(\n edges: readonly BridgeEdge[] = CATALOG_GRAPH,\n): CompositionRecoveryScan {\n const symbolic = edges.filter((edge) => edge.symbolic !== undefined);\n const canons = CANONICAL_EQUATIONS.filter((ce) => ce.scalarAst !== undefined).map((ce) => ({\n id: ce.id,\n normal: normalForm(ce.scalarAst!),\n }));\n\n const pairs: CompositionRecoveryPair[] = [];\n const hits: CompositionRecoveryHit[] = [];\n\n for (const first of symbolic) {\n for (const second of symbolic) {\n if (first.id === second.id) continue;\n let expr;\n try {\n expr = composeSymbolic(first, second).expr;\n } catch (error) {\n if (error instanceof SymbolicCompositionError) continue;\n throw error;\n }\n pairs.push({ firstId: first.id, secondId: second.id });\n const form = normalForm(expr);\n for (const canon of canons) {\n if (form !== canon.normal) continue;\n hits.push({\n firstId: first.id,\n secondId: second.id,\n canonicalId: canon.id,\n classification: 'recovers',\n });\n }\n }\n }\n\n pairs.sort((a, b) => (pairKey(a) < pairKey(b) ? -1 : pairKey(a) > pairKey(b) ? 1 : 0));\n hits.sort((a, b) => {\n const byPair = pairKey(a) < pairKey(b) ? -1 : pairKey(a) > pairKey(b) ? 1 : 0;\n if (byPair !== 0) return byPair;\n return a.canonicalId < b.canonicalId ? -1 : a.canonicalId > b.canonicalId ? 1 : 0;\n });\n return { pairs, hits };\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"consequence.d.ts","sourceRoot":"","sources":["../../src/composition/consequence.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CA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iBAAiB,CAAC;QACnC,QAAQ,CAAC,QAAQ,EAAE,SAAS,mBAAmB,EAAE,CAAC;KACnD,CAAC;CACH,CAAC,EAAE,CA0BH"}
|
|
@@ -48,13 +48,22 @@ export function classifyProposal(proposal, canonical = CANONICAL_EQUATIONS) {
|
|
|
48
48
|
*/
|
|
49
49
|
export function describeDerivedClaim(proposal, canonical = CANONICAL_EQUATIONS) {
|
|
50
50
|
const { identification, sourceEquationIds, solvedFor } = proposal.derivedFrom;
|
|
51
|
+
// `deriveProposedBridges` resolves the first source id for the smaller
|
|
52
|
+
// endpoint name and the second for the larger, so each id's target is known
|
|
53
|
+
// even when the source is a catalog bridge the canonical registry does not
|
|
54
|
+
// hold (then `canonical.find` is undefined; the sentence once printed
|
|
55
|
+
// "equals ? (undefined)" there, 9.0.0 audit §7 T1).
|
|
56
|
+
const [t0, t1] = [identification.a, identification.b].sort();
|
|
57
|
+
const endpointOf = (id) => (id === sourceEquationIds[0] ? t0 : t1);
|
|
51
58
|
const sources = sourceEquationIds
|
|
52
59
|
.map((id) => canonical.find((e) => e.id === id))
|
|
53
60
|
.filter((e) => e !== undefined);
|
|
54
61
|
const home = sources.find((e) => e.dimensional.governing.some((g) => g.name === solvedFor)) ?? sources[0];
|
|
55
|
-
const
|
|
56
|
-
const
|
|
57
|
-
const
|
|
62
|
+
const homeId = home?.id ?? sourceEquationIds[0];
|
|
63
|
+
const otherId = sourceEquationIds.find((id) => id !== homeId) ?? sourceEquationIds[1];
|
|
64
|
+
const other = sources.find((e) => e.id === otherId);
|
|
65
|
+
const homeTarget = home?.dimensional.target.name ?? endpointOf(homeId);
|
|
66
|
+
const otherTarget = other?.dimensional.target.name ?? endpointOf(otherId);
|
|
58
67
|
const derivedNF = normalForm(proposal.scalarAst);
|
|
59
68
|
const sameTarget = canonical.filter((e) => e.scalarAst && e.dimensional.target.name === proposal.target.name);
|
|
60
69
|
const sameGov = sameTarget.filter((e) => sameGoverning(e.dimensional.governing, proposal.governing));
|
|
@@ -65,9 +74,9 @@ export function describeDerivedClaim(proposal, canonical = CANONICAL_EQUATIONS)
|
|
|
65
74
|
tested: false,
|
|
66
75
|
symbol: {
|
|
67
76
|
name: solvedFor,
|
|
68
|
-
fromEquation:
|
|
69
|
-
meaning: `${solvedFor} is the ${solvedFor} of ${home
|
|
70
|
-
`${homeTarget} equals ${otherTarget} (${
|
|
77
|
+
fromEquation: homeId,
|
|
78
|
+
meaning: `${solvedFor} is the ${solvedFor} of ${homeId}${home !== undefined ? ` (${home.name})` : ''}: the ${solvedFor} for which ` +
|
|
79
|
+
`${homeTarget} equals ${otherTarget} (${otherId}) — an equal-${identification.dim} scale; ` +
|
|
71
80
|
`the ${otherTarget} side is not given a ${solvedFor}`,
|
|
72
81
|
},
|
|
73
82
|
assumptions: sources.map((e) => ({ equation: e.id, assumptions: [...e.assumptions] })),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"consequence.js","sourceRoot":"","sources":["../../src/composition/consequence.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAwB/D,uDAAuD;AACvD,SAAS,aAAa,CAAC,CAA8B,EAAE,CAA8B;IACnF,IAAI,CAAC,CAAC,MAAM,KAAK,CAAC,CAAC,MAAM;QAAE,OAAO,KAAK,CAAC;IACxC,MAAM,EAAE,GAAG,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;IACzC,OAAO,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AACxC,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,gBA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C,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACxC,MAAM,GAAG,GAAG,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QAC5B,MAAM,MAAM,GAAsB,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,cAAc,CAAC;QACpE,OAAO,EAAE,GAAG,CAAC,EAAE,WAAW,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,EAAE,QAAQ,IAAI,EAAE,EAAE,EAAE,CAAC;IAC1E,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["/**\n * Consequence propagation — the machine pre-classifier for the human\n * adjudication ledger. A POST-PASS annotation over ranked candidates (mirrors\n * `annotateAdjudications`): reuse `deriveProposedBridges` to derive each\n * promising candidate's monomial consequence, then compare its `normalForm`\n * against the canonical registry (SAME target AND SAME governing set) to label\n * it `entailed` (re-derives known physics), `novel-consequence` (valid, no\n * match), or `inconclusive` (no monomial consequence). Annotation-only: never\n * mutates the catalog/graph, never re-orders or re-scores, never writes to\n * ADJUDICATIONS. The underlying ProposedBridge stays `status:'unadjudicated'`.\n *\n * @module composition/consequence\n */\nimport type { VettedCandidate } from './discovery.js';\nimport type { ProposedBridge } from './proposed-bridges.js';\nimport { deriveProposedBridges } from './proposed-bridges.js';\nimport { normalForm } from '../canonical/normal-form.js';\nimport { CANONICAL_EQUATIONS } from '../canonical/registry.js';\nimport type { CanonicalEquation } from '../canonical/canonical-equation.js';\n\n/** @public */\nexport type ConsequenceSignal = 'entailed' | 'novel-consequence' | 'inconclusive';\n\n/** @public */\nexport interface ConsequenceEvidence {\n readonly target: string;\n readonly governing: readonly string[];\n readonly derivedNormalForm: string;\n /** The id of the canonical equation whose normalForm matched, or null. */\n readonly canonicalMatch: string | null;\n readonly sourceEquationIds: readonly [string, string];\n}\n\n/** @public */\nexport type ConsequenceAnnotatedCandidate = VettedCandidate & {\n readonly consequence?: {\n readonly signal: ConsequenceSignal;\n readonly evidence: readonly ConsequenceEvidence[];\n };\n};\n\n/** Governing-name set equality (order-insensitive). */\nfunction sameGoverning(a: readonly { name: string }[], b: readonly { name: string }[]): boolean {\n if (a.length !== b.length) return false;\n const sa = new Set(a.map((g) => g.name));\n return b.every((g) => sa.has(g.name));\n}\n\n/**\n * Classify ONE derived proposal against the canonical registry.\n * `entailed` iff some canonical equation with a `scalarAst` has the SAME target\n * name AND SAME governing set AND a matching `normalForm`. Otherwise\n * `novel-consequence`. There is NO contradiction signal — a differing normalForm\n * for the same target is NOT a contradiction (design r2: E=mc² vs E=hf).\n * @public\n */\nexport function classifyProposal(\n proposal: Pick<ProposedBridge, 'target' | 'governing' | 'scalarAst' | 'derivedFrom'>,\n canonical: readonly CanonicalEquation[] = CANONICAL_EQUATIONS,\n): { readonly signal: Exclude<ConsequenceSignal, 'inconclusive'>; readonly evidence: ConsequenceEvidence } {\n const derivedNF = normalForm(proposal.scalarAst);\n let canonicalMatch: string | null = null;\n for (const ce of canonical) {\n if (!ce.scalarAst) continue;\n if (ce.dimensional.target.name !== proposal.target.name) continue;\n if (!sameGoverning(ce.dimensional.governing, proposal.governing)) continue;\n if (normalForm(ce.scalarAst) === derivedNF) {\n canonicalMatch = ce.id; // CanonicalEquation.id is a top-level `readonly id: string` (verified)\n break;\n }\n }\n return {\n signal: canonicalMatch ? 'entailed' : 'novel-consequence',\n evidence: {\n target: proposal.target.name,\n governing: proposal.governing.map((g) => g.name),\n derivedNormalForm: derivedNF,\n canonicalMatch,\n sourceEquationIds: proposal.derivedFrom.sourceEquationIds,\n },\n };\n}\n\n/**\n * What a derived proposal claims, in a form that travels with it: the premise,\n * whether it is a known law or a conditional identity, what the solved-for\n * symbol means, the source equations' assumptions, and the exact scope of the\n * canonical-match check.\n * @internal\n */\nexport interface DerivedClaim {\n /** The unadjudicated identification the relation rests on. */\n readonly premise: string;\n /** `known-law`: re-derives a registry equation. `conditional-identity`: holds only if the premise does. */\n readonly relation: 'known-law' | 'conditional-identity';\n /** No derived proposal has been confronted with a measurement. */\n readonly tested: false;\n readonly symbol: { readonly name: string; readonly fromEquation: string; readonly meaning: string };\n readonly assumptions: readonly { readonly equation: string; readonly assumptions: readonly string[] }[];\n readonly canonicalMatch: {\n readonly id: string | null;\n readonly sameTarget: number;\n readonly sameTargetAndGoverning: number;\n readonly scope: 'the canonical registry only';\n };\n}\n\ntype ClaimEquation = Pick<CanonicalEquation, 'id' | 'name' | 'assumptions' | 'scalarAst'> & {\n readonly dimensional: Pick<CanonicalEquation['dimensional'], 'target' | 'governing'>;\n};\n\n/**\n * Describe the claim a derived proposal makes. Pure; the proposal is unchanged.\n * @internal\n */\nexport function describeDerivedClaim(\n proposal: Pick<ProposedBridge, 'target' | 'governing' | 'scalarAst' | 'derivedFrom'>,\n canonical: readonly ClaimEquation[] = CANONICAL_EQUATIONS,\n): DerivedClaim {\n const { identification, sourceEquationIds, solvedFor } = proposal.derivedFrom;\n // `deriveProposedBridges` resolves the first source id for the smaller\n // endpoint name and the second for the larger, so each id's target is known\n // even when the source is a catalog bridge the canonical registry does not\n // hold (then `canonical.find` is undefined; the sentence once printed\n // \"equals ? (undefined)\" there, 9.0.0 audit §7 T1).\n const [t0, t1] = [identification.a, identification.b].sort();\n const endpointOf = (id: string): string => (id === sourceEquationIds[0] ? t0 : t1);\n const sources = sourceEquationIds\n .map((id) => canonical.find((e) => e.id === id))\n .filter((e): e is ClaimEquation => e !== undefined);\n const home = sources.find((e) => e.dimensional.governing.some((g) => g.name === solvedFor)) ?? sources[0];\n const homeId = home?.id ?? sourceEquationIds[0];\n const otherId = sourceEquationIds.find((id) => id !== homeId) ?? sourceEquationIds[1];\n const other = sources.find((e) => e.id === otherId);\n const homeTarget = home?.dimensional.target.name ?? endpointOf(homeId);\n const otherTarget = other?.dimensional.target.name ?? endpointOf(otherId);\n\n const derivedNF = normalForm(proposal.scalarAst);\n const sameTarget = canonical.filter((e) => e.scalarAst && e.dimensional.target.name === proposal.target.name);\n const sameGov = sameTarget.filter((e) => sameGoverning(e.dimensional.governing, proposal.governing));\n const match = sameGov.find((e) => normalForm(e.scalarAst!) === derivedNF);\n\n return {\n premise: `${identification.a} ≡ ${identification.b}`,\n relation: match ? 'known-law' : 'conditional-identity',\n tested: false,\n symbol: {\n name: solvedFor,\n fromEquation: homeId,\n meaning:\n `${solvedFor} is the ${solvedFor} of ${homeId}${home !== undefined ? ` (${home.name})` : ''}: the ${solvedFor} for which ` +\n `${homeTarget} equals ${otherTarget} (${otherId}) — an equal-${identification.dim} scale; ` +\n `the ${otherTarget} side is not given a ${solvedFor}`,\n },\n assumptions: sources.map((e) => ({ equation: e.id, assumptions: [...e.assumptions] })),\n canonicalMatch: {\n id: match?.id ?? null,\n sameTarget: sameTarget.length,\n sameTargetAndGoverning: sameGov.length,\n scope: 'the canonical registry only',\n },\n };\n}\n\n/**\n * Annotate ranked candidates with their consequence signal. Order-preserving,\n * 1:1 with the input; only `promising` candidates are classified (they are the\n * only ones `deriveProposedBridges` processes). A promising candidate with no\n * derived proposal is `inconclusive`. Generic over the input candidate type so\n * it composes with other post-pass annotators (e.g. `annotateAdjudications`)\n * without forgetting fields the caller already attached.\n * @public\n */\nexport function annotateConsequences<T extends VettedCandidate>(\n candidates: readonly T[],\n): readonly (T & {\n readonly consequence?: {\n readonly signal: ConsequenceSignal;\n readonly evidence: readonly ConsequenceEvidence[];\n };\n})[] {\n const promising = candidates.filter((c) => c.verdict === 'promising');\n const proposals = deriveProposedBridges(promising);\n\n // Group proposals + their classification by the sorted candidate-pair key.\n const byPair = new Map<string, { signal: ConsequenceSignal; evidence: ConsequenceEvidence[] }>();\n for (const p of proposals) {\n const key = [p.derivedFrom.identification.a, p.derivedFrom.identification.b].sort().join('~');\n const cls = classifyProposal(p);\n const cur = byPair.get(key);\n if (!cur) {\n byPair.set(key, { signal: cls.signal, evidence: [cls.evidence] });\n } else {\n cur.evidence.push(cls.evidence);\n // entailed dominates novel: if ANY consequence re-derives known physics, the pair is entailed.\n if (cls.signal === 'entailed') cur.signal = 'entailed';\n }\n }\n\n return candidates.map((c) => {\n if (c.verdict !== 'promising') return c;\n const key = [c.a, c.b].sort().join('~');\n const hit = byPair.get(key);\n const signal: ConsequenceSignal = hit ? hit.signal : 'inconclusive';\n return { ...c, consequence: { signal, evidence: hit?.evidence ?? [] } };\n });\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"consistency.js","sourceRoot":"","sources":["../../src/composition/consistency.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,UAAU,gBAAgB,CAC9B,CAAa,EACb,CAAa,EACb,MAA8B;IAE9B,OAAO,YAAY,CAAC,CAAC,EAAE,MAAM,CAAC,GAAG,YAAY,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;AAC3D,CAAC"}
|
|
1
|
+
{"version":3,"file":"consistency.js","sourceRoot":"","sources":["../../src/composition/consistency.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAGH,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,UAAU,gBAAgB,CAC9B,CAAa,EACb,CAAa,EACb,MAA8B;IAE9B,OAAO,YAAY,CAAC,CAAC,EAAE,MAAM,CAAC,GAAG,YAAY,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;AAC3D,CAAC","sourcesContent":["/**\n * Composition graph — shared-source consistency relations (v0.8.0\n * CT-2, per docs/planning/v0.8.0-Design.md §2).\n *\n * `consistencyRatio` is a PARALLEL graph operation, honestly distinct\n * from sequential composition: two edges that share source quantities\n * are evaluated on the same inputs and their quotient taken. When the\n * shared quantities cancel algebraically (as G, M, c do between BE-51\n * lensing and BE-52 perihelion precession), the ratio is a\n * parameter-free consistency relation — varying the shared inputs must\n * leave it invariant.\n *\n * @module composition/consistency\n */\n\nimport type { BridgeEdge } from './edge.js';\nimport { evaluateEdge } from './edge.js';\n\n/**\n * Domain-checked quotient `a(inputs) / b(inputs)` of two edges sharing\n * source quantities. Throws {@link DomainViolationError} if either\n * edge's validity domain rejects the inputs.\n *\n * @public\n */\nexport function consistencyRatio(\n a: BridgeEdge,\n b: BridgeEdge,\n inputs: Record<string, number>,\n): number {\n return evaluateEdge(a, inputs) / evaluateEdge(b, inputs);\n}\n"]}
|
|
@@ -25,7 +25,7 @@ import type { BridgeEdge } from './edge.js';
|
|
|
25
25
|
import type { ExprNode } from '../dimensional/validator.js';
|
|
26
26
|
/** One bridge, joined across the catalog's three id-keyed registries. */
|
|
27
27
|
interface BridgeDescriptor {
|
|
28
|
-
/** Catalog id (
|
|
28
|
+
/** Catalog id (the range is the catalog's; NOTES.md records it). */
|
|
29
29
|
readonly id: number;
|
|
30
30
|
/** Catalog metadata (from `BRIDGE_EQUATIONS`). */
|
|
31
31
|
readonly entry: BridgeEquationEntry;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"descriptor.d.ts","sourceRoot":"","sources":["../../src/composition/descriptor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,EAAoB,KAAK,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAGjF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAE5D,yEAAyE;AACzE,UAAU,gBAAgB;IACxB,
|
|
1
|
+
{"version":3,"file":"descriptor.d.ts","sourceRoot":"","sources":["../../src/composition/descriptor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,OAAO,EAAoB,KAAK,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAGjF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,KAAK,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":["/**\n * Unified per-bridge descriptor — one lookup that JOINS the catalog's three\n * id-keyed registries so a consumer reads a single object instead of\n * cross-referencing three hand-maintained sources:\n *\n * 1. `BRIDGE_EQUATIONS` — catalog metadata (status, refs, signature, …)\n * 2. `BRIDGE_RHS_BY_ID` — faithful right-hand-side AST (where encoded)\n * 3. `CATALOG_GRAPH` — composition-graph edge(s) keyed by `beId`\n *\n * This is a DERIVED facade, not a fourth source of truth: every field still\n * lives in its home registry. The point is anti-drift — the failure mode behind\n * the stale `DATA_CONFRONTED = {23,36}` set and the `6.075e-12` value was the\n * registries silently disagreeing. They are now (a) reachable through one\n * accessor and (b) cross-checked by one guard\n * (`tests/bridges/descriptor-consistency.test.ts`), so a future id that exists\n * in one registry but not another fails loudly instead of drifting.\n *\n * The join lives here, beside `catalog-graph.ts`, because `composition/` owns\n * the graph and already imports `bridges/`. `bridges/` does not import it back.\n *\n * @module composition/descriptor\n */\nimport { BRIDGE_EQUATIONS, type BridgeEquationEntry } from '../bridges/index.js';\nimport { BRIDGE_RHS_BY_ID, parseBridgeId } from '../bridges/rhs-registry.js';\nimport { CATALOG_GRAPH } from './catalog-graph.js';\nimport type { BridgeEdge } from './edge.js';\nimport type { ExprNode } from '../dimensional/validator.js';\n\n/** One bridge, joined across the catalog's three id-keyed registries. */\ninterface BridgeDescriptor {\n /** Catalog id (the range is the catalog's; NOTES.md records it). */\n readonly id: number;\n /** Catalog metadata (from `BRIDGE_EQUATIONS`). */\n readonly entry: BridgeEquationEntry;\n /** Faithful RHS AST (from `BRIDGE_RHS_BY_ID`), or `undefined` if not encoded. */\n readonly rhs: ExprNode | undefined;\n /**\n * Composition-graph edges carrying this `beId` (from `CATALOG_GRAPH`).\n * Usually one; a few bridges have several (e.g. BE-42 + BE-42-via-rs).\n * Empty when the bridge has no graph edge.\n */\n readonly edges: readonly BridgeEdge[];\n}\n\nconst DESCRIPTORS: ReadonlyMap<number, BridgeDescriptor> = (() => {\n const edgesById = new Map<number, BridgeEdge[]>();\n for (const e of CATALOG_GRAPH) {\n if (e.beId === null) continue;\n const list = edgesById.get(e.beId);\n if (list) list.push(e);\n else edgesById.set(e.beId, [e]);\n }\n const m = new Map<number, BridgeDescriptor>();\n for (const entry of BRIDGE_EQUATIONS) {\n m.set(entry.id, {\n id: entry.id,\n entry,\n rhs: BRIDGE_RHS_BY_ID.get(entry.id),\n edges: edgesById.get(entry.id) ?? [],\n });\n }\n return m;\n})();\n\n/**\n * Every bridge descriptor, keyed by catalog id. The single joined view of the\n * three registries.\n *\n * @internal\n */\nexport const BRIDGE_DESCRIPTORS: ReadonlyMap<number, BridgeDescriptor> = DESCRIPTORS;\n\n/**\n * Look up one bridge by id (a number, `'42'`, or `'BE-42'` — case-insensitive).\n * Returns the joined descriptor (metadata + RHS + edges). Throws if the id is\n * unparseable or not catalogued.\n *\n * @internal\n */\nexport function getBridge(bridgeId: number | string): BridgeDescriptor {\n const id = parseBridgeId(bridgeId);\n const d = DESCRIPTORS.get(id);\n if (d === undefined) {\n throw new RangeError(\n `getBridge: no catalogued bridge with id ${id} (BE-${id}).`,\n );\n }\n return d;\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dimension-adjacency.js","sourceRoot":"","sources":["../../src/composition/dimension-adjacency.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAGH,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AAY3D;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAChC,UAAwE,EACxE,aAA6C;IAE7C,MAAM,UAAU,GAAG,CAAC,GAAG,aAAa,CAAC,OAAO,EAAE,CAAC,CAAC;IAChD,MAAM,GAAG,GAAG,IAAI,GAAG,EAA8B,CAAC;IAClD,KAAK,MAAM,CAAC,IAAI,UAAU,EAAE,CAAC;QAC3B,IAAI,GAAG,CAAC,GAAG,CAAC,CAAC,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MAAM,GAAG,GAAG,IAAI,GAAG,EAA8B,CAAC;IAClD,KAAK,MAAM,CAAC,IAAI,UAAU,EAAE,CAAC;QAC3B,IAAI,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC;YAAE,SAAS,CAAC,2BAA2B;QACvF,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,aAAa,CAAC;YAAE,SAAS,CAAC,uCAAuC;QACnF,MAAM,UAAU,GAAG,UAAU;aAC1B,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC;aACnC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC;aACf,IAAI,EAAE,CAAC;QACV,IAAI,UAAU,CAAC,MAAM;YAAE,GAAG,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,UAAU,EAAE,CAAC,CAAC;IAC3F,CAAC;IACD,OAAO,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC;AACxE,CAAC","sourcesContent":["/**\n * Dimension-adjacency — a review surface for quantities that are absent from a\n * reference vocabulary BY NAME but match a reference quantity BY DIMENSION.\n *\n * Name-based graph linkage misses connections hidden by a name divergence (e.g.\n * the catalog's `thermal-de-broglie-wavelength` vs the canonical L-layer's\n * `thermal-wavelength` — the same physical quantity). This sweep surfaces such\n * candidates so a reviewer can spot true aliases and registry gaps.\n *\n * It is strictly a **review surface, never an auto-merge**: same dimension does\n * NOT imply same quantity (`effective-mass` ≠ `mass`, every dimensionless\n * coupling shares `[dimensionless]`), so dimensionless quantities are excluded\n * and the output is for human adjudication only.\n *\n * @module composition/dimension-adjacency\n */\n\nimport type { Dimension } from '../dimensional/types.js';\nimport { DIMENSIONLESS } from '../dimensional/types.js';\nimport { equals, format } from '../dimensional/algebra.js';\n\n/** A name-divergent quantity and the reference quantities it dimension-matches. */\nexport interface DimensionAdjacency {\n /** The quantity name (absent from the reference vocabulary). */\n readonly name: string;\n /** Its formatted dimension. */\n readonly dim: string;\n /** Reference quantities of the SAME dimension — candidates for review. */\n readonly candidates: readonly string[];\n}\n\n/**\n * For every distinct quantity whose `name` is absent from `referenceDims` but\n * whose `dim` matches ≥1 reference quantity (dimensionless excluded), list the\n * same-dimension reference candidates. Sorted by quantity name; candidates\n * sorted. A review surface — same dimension ≠ same quantity.\n *\n * @public\n */\nexport function dimensionAdjacency(\n quantities: Iterable<{ readonly name: string; readonly dim: Dimension }>,\n referenceDims: ReadonlyMap<string, Dimension>,\n): DimensionAdjacency[] {\n const refEntries = [...referenceDims.entries()];\n const out = new Map<string, DimensionAdjacency>();\n for (const q of quantities) {\n if (out.has(q.name) || referenceDims.has(q.name)) continue; // dedupe + name-match skip\n if (equals(q.dim, DIMENSIONLESS)) continue; // too generic to be a useful candidate\n const candidates = refEntries\n .filter(([, d]) => equals(d, q.dim))\n .map(([n]) => n)\n .sort();\n if (candidates.length) out.set(q.name, { name: q.name, dim: format(q.dim), candidates });\n }\n return [...out.values()].sort((a, b) => a.name.localeCompare(b.name));\n}\n"]}
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
* (Direction 2).
|
|
4
4
|
*
|
|
5
5
|
* `proposeLinkCandidates` surfaces cross-cluster quantity pairs that share a
|
|
6
|
-
* dimension
|
|
6
|
+
* dimension and hands the raw coincidences to a human (the counts at a given
|
|
7
|
+
* catalog are measured by the tests and recorded in NOTES.md). This
|
|
7
8
|
* module closes the loop: it HYPOTHESIZES each candidate identification
|
|
8
9
|
* `a ≡ b` and tests it with the machinery that already exists —
|
|
9
10
|
*
|
|
@@ -61,13 +62,16 @@ export interface VettedCandidate {
|
|
|
61
62
|
*/
|
|
62
63
|
readonly unlocksFromAnchor: readonly string[];
|
|
63
64
|
/**
|
|
64
|
-
* Retrodiction over the graph WITH the hypothesized identification
|
|
65
|
-
*
|
|
66
|
-
*
|
|
65
|
+
* Retrodiction over the graph WITH the hypothesized identification creates
|
|
66
|
+
* no numerical contradiction in the anchor-reachable subgraph. The strong
|
|
67
|
+
* filter. A node whose routes already disagree in the base graph is the
|
|
68
|
+
* graph's finding (`retrodict` reports it) and does not make a candidate
|
|
69
|
+
* inconsistent; only a disagreement the hypothesis CREATES does.
|
|
67
70
|
*/
|
|
68
71
|
readonly numericallyConsistent: boolean;
|
|
69
|
-
/** Nodes that became inconsistent under the identification
|
|
70
|
-
*
|
|
72
|
+
/** Nodes that became inconsistent under the identification and were not
|
|
73
|
+
* inconsistent in the base graph (the falsification, when
|
|
74
|
+
* `numericallyConsistent` is false). Sorted. */
|
|
71
75
|
readonly inconsistentNodes: readonly string[];
|
|
72
76
|
/**
|
|
73
77
|
* Orders of magnitude between the representative values of a and b
|
|
@@ -171,7 +175,7 @@ export interface DiscoveryOptions {
|
|
|
171
175
|
readonly identifications?: readonly QuantityIdentification[];
|
|
172
176
|
/**
|
|
173
177
|
* Max orders of magnitude two identified quantities may differ before the
|
|
174
|
-
* identification is falsified as a `magnitude-clash`. Default
|
|
178
|
+
* identification is falsified as a `magnitude-clash`. Default {@link DEFAULT_MAX_ORDERS_OF_MAGNITUDE} — generous
|
|
175
179
|
* enough for O(1) dimensionless prefactors and unit-convention slack, strict
|
|
176
180
|
* enough to kill the scale-clash decoys.
|
|
177
181
|
*/
|
|
@@ -196,6 +200,12 @@ export interface DiscoveryOptions {
|
|
|
196
200
|
* @internal
|
|
197
201
|
*/
|
|
198
202
|
export declare const ANCHOR_DEFAULT: Readonly<Record<string, number>>;
|
|
203
|
+
/**
|
|
204
|
+
* The magnitude-clash threshold when the caller gives none: how many orders of magnitude two
|
|
205
|
+
* identified quantities may differ. Exported so the CLI states the default it runs with.
|
|
206
|
+
* @internal
|
|
207
|
+
*/
|
|
208
|
+
export declare const DEFAULT_MAX_ORDERS_OF_MAGNITUDE = 3;
|
|
199
209
|
/**
|
|
200
210
|
* Candidate-invariant state for the discovery funnel — everything in
|
|
201
211
|
* `vetLinkCandidate` that depends only on `(edges, opts)`, not on the specific
|
|
@@ -227,11 +237,11 @@ export interface DiscoveryContext {
|
|
|
227
237
|
/** `forwardClosure(edges, anchor, baseIdents)` — base determinable set. */
|
|
228
238
|
readonly closureBase: ReadonlySet<string>;
|
|
229
239
|
/**
|
|
230
|
-
*
|
|
231
|
-
*
|
|
232
|
-
*
|
|
240
|
+
* The targets the retrodiction of the anchor finds inconsistent with no
|
|
241
|
+
* hypothesized identification (empty when the base is consistent). An
|
|
242
|
+
* identification of two quantities outside {@link closureBase} cannot fire,
|
|
243
|
+
* so that candidate's numeric report is this one.
|
|
233
244
|
*/
|
|
234
|
-
readonly baseNumericallyConsistent: boolean;
|
|
235
245
|
readonly baseInconsistentNodes: readonly string[];
|
|
236
246
|
}
|
|
237
247
|
/** Resolve options and compute the candidate-invariant discovery state once.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discovery.d.ts","sourceRoot":"","sources":["../../src/composition/discovery.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"discovery.d.ts","sourceRoot":"","sources":["../../src/composition/discovery.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC5C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,cAAc,CAAC;AAG3D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAItD,OAAO,KAA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AED;;;;;;;GAOG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,SAAS,UAAU,EAAE,EAC5B,SAAS,EAAE,aAAa,EACxB,GAAG,EAAE,gBAAgB,GACpB,eAAe,CA+MjB;AAED;;;;;;;GAOG;AACH,wBAAgB,eAAe,CAC7B,KAAK,EAAE,SAAS,UAAU,EAAE,EAC5B,IAAI,GAAE,gBAAqB,GAC1B,eAAe,EAAE,CAmBnB"}
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
* (Direction 2).
|
|
4
4
|
*
|
|
5
5
|
* `proposeLinkCandidates` surfaces cross-cluster quantity pairs that share a
|
|
6
|
-
* dimension
|
|
6
|
+
* dimension and hands the raw coincidences to a human (the counts at a given
|
|
7
|
+
* catalog are measured by the tests and recorded in NOTES.md). This
|
|
7
8
|
* module closes the loop: it HYPOTHESIZES each candidate identification
|
|
8
9
|
* `a ≡ b` and tests it with the machinery that already exists —
|
|
9
10
|
*
|
|
@@ -34,8 +35,8 @@
|
|
|
34
35
|
*/
|
|
35
36
|
import { QUANTITY_IDENTIFICATIONS, effectiveAttributes } from './compose.js';
|
|
36
37
|
import { GATE_AXES } from './axes.js';
|
|
37
|
-
import { forwardClosure } from './identifiability.js';
|
|
38
|
-
import { retrodict, forwardEvaluate } from './retrodiction.js';
|
|
38
|
+
import { classifyIdentifiability, forwardClosure } from './identifiability.js';
|
|
39
|
+
import { retrodict, retrodictNode, forwardEvaluate } from './retrodiction.js';
|
|
39
40
|
import { proposeLinkCandidates } from './bridge-analysis.js';
|
|
40
41
|
import { M_SUN_KG } from '../core/constants.js';
|
|
41
42
|
import { REPRESENTATIVE_VALUES } from './representative-values.js';
|
|
@@ -118,6 +119,12 @@ function quantityComponents(edges, idents) {
|
|
|
118
119
|
* @internal
|
|
119
120
|
*/
|
|
120
121
|
export const ANCHOR_DEFAULT = { mass: M_SUN_KG };
|
|
122
|
+
/**
|
|
123
|
+
* The magnitude-clash threshold when the caller gives none: how many orders of magnitude two
|
|
124
|
+
* identified quantities may differ. Exported so the CLI states the default it runs with.
|
|
125
|
+
* @internal
|
|
126
|
+
*/
|
|
127
|
+
export const DEFAULT_MAX_ORDERS_OF_MAGNITUDE = 3;
|
|
121
128
|
/**
|
|
122
129
|
* Factor every anchor input is multiplied by to probe whether a magnitude ratio
|
|
123
130
|
* depends on the anchor at all (persona finding L3). Three decades moves any
|
|
@@ -159,7 +166,7 @@ export function buildDiscoveryContext(edges, opts) {
|
|
|
159
166
|
groundTruth,
|
|
160
167
|
anchor,
|
|
161
168
|
repVals: opts.representativeValues ?? REPRESENTATIVE_VALUES,
|
|
162
|
-
maxOrders: opts.maxOrdersOfMagnitude ??
|
|
169
|
+
maxOrders: opts.maxOrdersOfMagnitude ?? DEFAULT_MAX_ORDERS_OF_MAGNITUDE,
|
|
163
170
|
attributesByName: opts.quantityAttributes ?? REGISTRY_ATTRIBUTES_BY_NAME,
|
|
164
171
|
// Candidate-invariant: the anchor's forward evaluation, the base component
|
|
165
172
|
// partition, and the base forward closure all depend only on (edges, opts).
|
|
@@ -167,13 +174,63 @@ export function buildDiscoveryContext(edges, opts) {
|
|
|
167
174
|
anchorValuesProbe: forwardEvaluate(edges, Object.fromEntries(Object.entries(groundTruth).map(([k, v]) => [k, v * ANCHOR_PROBE_FACTOR])), baseIdents),
|
|
168
175
|
comps: quantityComponents(edges, baseIdents),
|
|
169
176
|
closureBase: forwardClosure(edges, anchor, baseIdents),
|
|
170
|
-
baseNumericallyConsistent: baseReport.allConsistent,
|
|
171
177
|
baseInconsistentNodes: baseReport.results
|
|
172
178
|
.filter((r) => r.outcome === 'inconsistent')
|
|
173
179
|
.map((r) => r.target)
|
|
174
180
|
.sort(),
|
|
175
181
|
};
|
|
176
182
|
}
|
|
183
|
+
/**
|
|
184
|
+
* The quantities whose value can depend on one of `seeds`: the seeds, every
|
|
185
|
+
* `to` of an identification from the set, and every target of an edge with a
|
|
186
|
+
* source in the set, to a fixed point. An over-approximation (an edge that
|
|
187
|
+
* does not fire still lists its target), which is the safe side: a target
|
|
188
|
+
* left out would keep its base retrodiction unexamined.
|
|
189
|
+
*/
|
|
190
|
+
function dependents(edges, seeds, idents) {
|
|
191
|
+
const set = new Set(seeds);
|
|
192
|
+
let changed = true;
|
|
193
|
+
while (changed) {
|
|
194
|
+
changed = false;
|
|
195
|
+
for (const id of idents) {
|
|
196
|
+
if (set.has(id.from) && !set.has(id.to)) {
|
|
197
|
+
set.add(id.to);
|
|
198
|
+
changed = true;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
for (const e of edges) {
|
|
202
|
+
if (set.has(e.target.name))
|
|
203
|
+
continue;
|
|
204
|
+
if (e.sources.some((s) => set.has(s.name))) {
|
|
205
|
+
set.add(e.target.name);
|
|
206
|
+
changed = true;
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
return set;
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* The nodes the hypothesis `a ≡ b` makes inconsistent that the base graph did
|
|
214
|
+
* not already have: inconsistent(hypothesis) minus inconsistent(base). Only a
|
|
215
|
+
* node downstream of `a` or `b` can change, so only those nodes are
|
|
216
|
+
* classified and retrodicted, with the same over-determined rule and the
|
|
217
|
+
* same tolerance `retrodict` applies to the whole graph. Sorted.
|
|
218
|
+
*/
|
|
219
|
+
function newInconsistencies(edges, groundTruth, anchor, candidate, withHyp, baseInconsistentNodes) {
|
|
220
|
+
const base = new Set(baseInconsistentNodes);
|
|
221
|
+
const nodes = [];
|
|
222
|
+
for (const target of [...dependents(edges, [candidate.a, candidate.b], withHyp)].sort()) {
|
|
223
|
+
if (base.has(target))
|
|
224
|
+
continue;
|
|
225
|
+
const classified = classifyIdentifiability(edges, anchor, target, { identifications: withHyp });
|
|
226
|
+
if (classified.verdict !== 'over-determined')
|
|
227
|
+
continue;
|
|
228
|
+
const result = retrodictNode(edges, groundTruth, target, { identifications: withHyp });
|
|
229
|
+
if (result.outcome === 'inconsistent')
|
|
230
|
+
nodes.push(target);
|
|
231
|
+
}
|
|
232
|
+
return nodes;
|
|
233
|
+
}
|
|
177
234
|
/**
|
|
178
235
|
* Vet one link candidate by hypothesizing the identification a≡b and
|
|
179
236
|
* measuring its structural and numerical consequences. See module docs.
|
|
@@ -192,7 +249,7 @@ export function vetLinkCandidate(edges, candidate, opts = {}) {
|
|
|
192
249
|
* @internal
|
|
193
250
|
*/
|
|
194
251
|
export function vetInContext(edges, candidate, ctx) {
|
|
195
|
-
const { baseIdents, groundTruth, anchor, repVals, maxOrders, anchorValues, anchorValuesProbe, comps, closureBase, attributesByName,
|
|
252
|
+
const { baseIdents, groundTruth, anchor, repVals, maxOrders, anchorValues, anchorValuesProbe, comps, closureBase, attributesByName, baseInconsistentNodes, } = ctx;
|
|
196
253
|
// Magnitude gate: an INDEPENDENT falsifier the single-anchor graph can't make.
|
|
197
254
|
// Only fires when both endpoints have a representative value; abstains (and
|
|
198
255
|
// never false-rejects) otherwise. A value comes from the sourced static table
|
|
@@ -288,26 +345,29 @@ export function vetInContext(edges, candidate, ctx) {
|
|
|
288
345
|
const mergesComponents = comps.has(candidate.a) &&
|
|
289
346
|
comps.has(candidate.b) &&
|
|
290
347
|
comps.get(candidate.a) !== comps.get(candidate.b);
|
|
348
|
+
// Neither endpoint in the anchor closure means the identification cannot
|
|
349
|
+
// fire: `forwardClosure` copies a value across `a ≡ b` only from a
|
|
350
|
+
// determinable side. The hypothesis closure is then the base closure, and no
|
|
351
|
+
// value in the graph moves, so neither closure nor retrodiction is recomputed
|
|
352
|
+
// (9.0.0 audit §4 C9: 4004 of 4196 catalog candidates are this case).
|
|
353
|
+
const touchesClosure = closureBase.has(candidate.a) || closureBase.has(candidate.b);
|
|
291
354
|
// Closure unlock: forward closure from the anchor, with vs without. The base
|
|
292
355
|
// closure is candidate-invariant (ctx); only the hypothesis closure is fresh.
|
|
293
|
-
const closureHyp = forwardClosure(edges, anchor, withHyp);
|
|
356
|
+
const closureHyp = touchesClosure ? forwardClosure(edges, anchor, withHyp) : closureBase;
|
|
294
357
|
const unlocksFromAnchor = [...closureHyp]
|
|
295
358
|
.filter((q) => !closureBase.has(q))
|
|
296
359
|
.sort();
|
|
297
|
-
// Numeric:
|
|
298
|
-
//
|
|
299
|
-
//
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
const
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
.filter((r) => r.outcome === 'inconsistent')
|
|
309
|
-
.map((r) => r.target)
|
|
310
|
-
.sort();
|
|
360
|
+
// Numeric: the hypothesis must not CREATE a disagreement. A node whose
|
|
361
|
+
// routes already disagree in the base graph is the graph's finding
|
|
362
|
+
// (`retrodict` reports it), not this candidate's, so the attribution is
|
|
363
|
+
// inconsistent(hypothesis) minus inconsistent(base) (9.0.0 audit §4 C4).
|
|
364
|
+
// Only a target downstream of `a` or `b` can change under the hypothesis;
|
|
365
|
+
// every other target's retrodiction is the base one, so only those targets
|
|
366
|
+
// are retrodicted (§4 C9).
|
|
367
|
+
const inconsistentNodes = touchesClosure
|
|
368
|
+
? newInconsistencies(edges, groundTruth, anchor, candidate, withHyp, baseInconsistentNodes)
|
|
369
|
+
: [];
|
|
370
|
+
const numericallyConsistent = inconsistentNodes.length === 0;
|
|
311
371
|
// Verdict precedence: a magnitude clash is the most decisive, most
|
|
312
372
|
// interpretable falsification, checked before the graph contradiction;
|
|
313
373
|
// the regime-label prior (axis-clash) is weaker than both numeric
|