@tiangong-lca/foundry 0.1.2
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/LICENSE +21 -0
- package/README.md +532 -0
- package/docs/architecture.md +450 -0
- package/docs/foundry-task-contracts.md +147 -0
- package/docs/import-profiles/bafu/constraints.md +343 -0
- package/docs/import-profiles/bafu/leaf-process-classification-authoring.md +153 -0
- package/docs/import-profiles/bafu/profile.md +183 -0
- package/docs/import-profiles/uslci/constraints.md +29 -0
- package/docs/import-profiles/uslci/profile.md +43 -0
- package/docs/import-profiles/worldsteel/constraints.md +77 -0
- package/docs/import-profiles/worldsteel/import-coverage.md +93 -0
- package/docs/import-profiles/worldsteel/import-plan.md +375 -0
- package/docs/import-profiles/worldsteel/profile.md +78 -0
- package/docs/package-distribution-contract.md +287 -0
- package/docs/public-runtime-contract.md +218 -0
- package/docs/runtime-context-contract.md +138 -0
- package/docs/safety-policy.md +164 -0
- package/docs/task-authorization-contract.md +131 -0
- package/docs/uslci-import-runbook.md +336 -0
- package/docs/workspace-migration-contract.md +127 -0
- package/package-dist/assets/foundry-package-descriptor.json +1661 -0
- package/package-dist/scripts/foundry-facade.d.ts +78 -0
- package/package-dist/scripts/foundry-facade.js +1317 -0
- package/package-dist/scripts/foundry-runtime.d.ts +180 -0
- package/package-dist/scripts/foundry-runtime.js +190 -0
- package/package-dist/scripts/lib/batch-orchestration/scope-attempt-ledger.d.ts +27 -0
- package/package-dist/scripts/lib/batch-orchestration/scope-attempt-ledger.js +85 -0
- package/package-dist/scripts/lib/batch-orchestration/scope-resume-contract.d.ts +38 -0
- package/package-dist/scripts/lib/batch-orchestration/scope-resume-contract.js +90 -0
- package/package-dist/scripts/lib/bundle-row-types.d.ts +44 -0
- package/package-dist/scripts/lib/bundle-row-types.js +46 -0
- package/package-dist/scripts/lib/bundle-sample-utils.d.ts +183 -0
- package/package-dist/scripts/lib/bundle-sample-utils.js +526 -0
- package/package-dist/scripts/lib/bundle-source-context.d.ts +31 -0
- package/package-dist/scripts/lib/bundle-source-context.js +142 -0
- package/package-dist/scripts/lib/canonical-description.d.ts +12 -0
- package/package-dist/scripts/lib/canonical-description.js +72 -0
- package/package-dist/scripts/lib/canonical-support-rewrites.d.ts +127 -0
- package/package-dist/scripts/lib/canonical-support-rewrites.js +527 -0
- package/package-dist/scripts/lib/decision-owners/classification.d.ts +245 -0
- package/package-dist/scripts/lib/decision-owners/classification.js +754 -0
- package/package-dist/scripts/lib/decision-owners/identity-preflight.d.ts +333 -0
- package/package-dist/scripts/lib/decision-owners/identity-preflight.js +1353 -0
- package/package-dist/scripts/lib/decision-owners/identity-task.d.ts +130 -0
- package/package-dist/scripts/lib/decision-owners/identity-task.js +494 -0
- package/package-dist/scripts/lib/decision-owners/identity.d.ts +74 -0
- package/package-dist/scripts/lib/decision-owners/identity.js +443 -0
- package/package-dist/scripts/lib/decision-owners/location.d.ts +239 -0
- package/package-dist/scripts/lib/decision-owners/location.js +704 -0
- package/package-dist/scripts/lib/decision-task-utils.d.ts +484 -0
- package/package-dist/scripts/lib/decision-task-utils.js +735 -0
- package/package-dist/scripts/lib/finalize-owners/cli-wrappers.d.ts +52 -0
- package/package-dist/scripts/lib/finalize-owners/cli-wrappers.js +146 -0
- package/package-dist/scripts/lib/finalize-owners/commit-handoff.d.ts +79 -0
- package/package-dist/scripts/lib/finalize-owners/commit-handoff.js +515 -0
- package/package-dist/scripts/lib/finalize-owners/post-authoring.d.ts +234 -0
- package/package-dist/scripts/lib/finalize-owners/post-authoring.js +1720 -0
- package/package-dist/scripts/lib/finalize-owners/post-write-closeout.d.ts +140 -0
- package/package-dist/scripts/lib/finalize-owners/post-write-closeout.js +656 -0
- package/package-dist/scripts/lib/foundry-args.d.ts +7 -0
- package/package-dist/scripts/lib/foundry-args.js +38 -0
- package/package-dist/scripts/lib/foundry-authentication-environment.d.ts +17 -0
- package/package-dist/scripts/lib/foundry-authentication-environment.js +55 -0
- package/package-dist/scripts/lib/foundry-authorization-input.d.ts +31 -0
- package/package-dist/scripts/lib/foundry-authorization-input.js +151 -0
- package/package-dist/scripts/lib/foundry-command-metadata.d.ts +32 -0
- package/package-dist/scripts/lib/foundry-command-metadata.js +1012 -0
- package/package-dist/scripts/lib/foundry-command-registry.d.ts +34 -0
- package/package-dist/scripts/lib/foundry-command-registry.js +241 -0
- package/package-dist/scripts/lib/foundry-command-spec.d.ts +1 -0
- package/package-dist/scripts/lib/foundry-command-spec.js +1 -0
- package/package-dist/scripts/lib/foundry-decision-owners.d.ts +17 -0
- package/package-dist/scripts/lib/foundry-decision-owners.js +68 -0
- package/package-dist/scripts/lib/foundry-decision-routing.d.ts +3 -0
- package/package-dist/scripts/lib/foundry-decision-routing.js +38 -0
- package/package-dist/scripts/lib/foundry-execution-admission.d.ts +33 -0
- package/package-dist/scripts/lib/foundry-execution-admission.js +225 -0
- package/package-dist/scripts/lib/foundry-execution-attempt.d.ts +11 -0
- package/package-dist/scripts/lib/foundry-execution-attempt.js +33 -0
- package/package-dist/scripts/lib/foundry-execution-context-format.d.ts +18 -0
- package/package-dist/scripts/lib/foundry-execution-context-format.js +83 -0
- package/package-dist/scripts/lib/foundry-facade-store.d.ts +25 -0
- package/package-dist/scripts/lib/foundry-facade-store.js +449 -0
- package/package-dist/scripts/lib/foundry-finalize-owners.d.ts +21 -0
- package/package-dist/scripts/lib/foundry-finalize-owners.js +203 -0
- package/package-dist/scripts/lib/foundry-identity-owners.d.ts +13 -0
- package/package-dist/scripts/lib/foundry-identity-owners.js +58 -0
- package/package-dist/scripts/lib/foundry-managed-host.d.ts +7 -0
- package/package-dist/scripts/lib/foundry-managed-host.js +173 -0
- package/package-dist/scripts/lib/foundry-migration-adoption-plan.d.ts +39 -0
- package/package-dist/scripts/lib/foundry-migration-adoption-plan.js +467 -0
- package/package-dist/scripts/lib/foundry-migration-adoption.d.ts +31 -0
- package/package-dist/scripts/lib/foundry-migration-adoption.js +187 -0
- package/package-dist/scripts/lib/foundry-migration-authority.d.ts +42 -0
- package/package-dist/scripts/lib/foundry-migration-authority.js +280 -0
- package/package-dist/scripts/lib/foundry-migration-inventory.d.ts +31 -0
- package/package-dist/scripts/lib/foundry-migration-inventory.js +148 -0
- package/package-dist/scripts/lib/foundry-migration-plan.d.ts +48 -0
- package/package-dist/scripts/lib/foundry-migration-plan.js +234 -0
- package/package-dist/scripts/lib/foundry-migration-replay.d.ts +3 -0
- package/package-dist/scripts/lib/foundry-migration-replay.js +134 -0
- package/package-dist/scripts/lib/foundry-migration-stage.d.ts +15 -0
- package/package-dist/scripts/lib/foundry-migration-stage.js +152 -0
- package/package-dist/scripts/lib/foundry-migration-transfer-io.d.ts +13 -0
- package/package-dist/scripts/lib/foundry-migration-transfer-io.js +226 -0
- package/package-dist/scripts/lib/foundry-migration-transfer.d.ts +36 -0
- package/package-dist/scripts/lib/foundry-migration-transfer.js +350 -0
- package/package-dist/scripts/lib/foundry-operation-result.d.ts +71 -0
- package/package-dist/scripts/lib/foundry-operation-result.js +264 -0
- package/package-dist/scripts/lib/foundry-owner-execution-store.d.ts +319 -0
- package/package-dist/scripts/lib/foundry-owner-execution-store.js +293 -0
- package/package-dist/scripts/lib/foundry-owner-readback.d.ts +22 -0
- package/package-dist/scripts/lib/foundry-owner-readback.js +189 -0
- package/package-dist/scripts/lib/foundry-owner-trace-acceptance.d.ts +15 -0
- package/package-dist/scripts/lib/foundry-owner-trace-acceptance.js +68 -0
- package/package-dist/scripts/lib/foundry-package-contract.d.ts +56 -0
- package/package-dist/scripts/lib/foundry-package-contract.js +392 -0
- package/package-dist/scripts/lib/foundry-private-path.d.ts +2 -0
- package/package-dist/scripts/lib/foundry-private-path.js +20 -0
- package/package-dist/scripts/lib/foundry-runtime-cache.d.ts +3 -0
- package/package-dist/scripts/lib/foundry-runtime-cache.js +25 -0
- package/package-dist/scripts/lib/foundry-runtime-command-policy.d.ts +20 -0
- package/package-dist/scripts/lib/foundry-runtime-command-policy.js +173 -0
- package/package-dist/scripts/lib/foundry-runtime-context-types.d.ts +59 -0
- package/package-dist/scripts/lib/foundry-runtime-context-types.js +1 -0
- package/package-dist/scripts/lib/foundry-runtime-context.d.ts +27 -0
- package/package-dist/scripts/lib/foundry-runtime-context.js +668 -0
- package/package-dist/scripts/lib/foundry-runtime-environment.d.ts +9 -0
- package/package-dist/scripts/lib/foundry-runtime-environment.js +90 -0
- package/package-dist/scripts/lib/foundry-runtime-error.d.ts +4 -0
- package/package-dist/scripts/lib/foundry-runtime-error.js +8 -0
- package/package-dist/scripts/lib/foundry-runtime-identity.d.ts +18 -0
- package/package-dist/scripts/lib/foundry-runtime-identity.js +127 -0
- package/package-dist/scripts/lib/foundry-runtime-paths.d.ts +16 -0
- package/package-dist/scripts/lib/foundry-runtime-paths.js +159 -0
- package/package-dist/scripts/lib/foundry-runtime-qualification.d.ts +66 -0
- package/package-dist/scripts/lib/foundry-runtime-qualification.js +223 -0
- package/package-dist/scripts/lib/foundry-runtime-selection-record.d.ts +16 -0
- package/package-dist/scripts/lib/foundry-runtime-selection-record.js +32 -0
- package/package-dist/scripts/lib/foundry-runtime-selection.d.ts +14 -0
- package/package-dist/scripts/lib/foundry-runtime-selection.js +123 -0
- package/package-dist/scripts/lib/foundry-runtime-utils.d.ts +178 -0
- package/package-dist/scripts/lib/foundry-runtime-utils.js +603 -0
- package/package-dist/scripts/lib/foundry-semantic-input.d.ts +30 -0
- package/package-dist/scripts/lib/foundry-semantic-input.js +132 -0
- package/package-dist/scripts/lib/foundry-task-authorization.d.ts +68 -0
- package/package-dist/scripts/lib/foundry-task-authorization.js +350 -0
- package/package-dist/scripts/lib/foundry-task-io.d.ts +18 -0
- package/package-dist/scripts/lib/foundry-task-io.js +92 -0
- package/package-dist/scripts/lib/foundry-task-registration.d.ts +6 -0
- package/package-dist/scripts/lib/foundry-task-registration.js +384 -0
- package/package-dist/scripts/lib/foundry-task-start-spec.d.ts +34 -0
- package/package-dist/scripts/lib/foundry-task-start-spec.js +161 -0
- package/package-dist/scripts/lib/foundry-task-store.d.ts +18 -0
- package/package-dist/scripts/lib/foundry-task-store.js +466 -0
- package/package-dist/scripts/lib/foundry-task-types.d.ts +99 -0
- package/package-dist/scripts/lib/foundry-task-types.js +1 -0
- package/package-dist/scripts/lib/foundry-workflow-approval-continuation.d.ts +6 -0
- package/package-dist/scripts/lib/foundry-workflow-approval-continuation.js +136 -0
- package/package-dist/scripts/lib/foundry-workflow-assessment.d.ts +3 -0
- package/package-dist/scripts/lib/foundry-workflow-assessment.js +231 -0
- package/package-dist/scripts/lib/foundry-workflow-authorization.d.ts +22 -0
- package/package-dist/scripts/lib/foundry-workflow-authorization.js +174 -0
- package/package-dist/scripts/lib/foundry-workflow-context.d.ts +3 -0
- package/package-dist/scripts/lib/foundry-workflow-context.js +99 -0
- package/package-dist/scripts/lib/foundry-workflow-decisions.d.ts +18 -0
- package/package-dist/scripts/lib/foundry-workflow-decisions.js +123 -0
- package/package-dist/scripts/lib/foundry-workflow-execution.d.ts +8 -0
- package/package-dist/scripts/lib/foundry-workflow-execution.js +248 -0
- package/package-dist/scripts/lib/foundry-workflow-finalize.d.ts +13 -0
- package/package-dist/scripts/lib/foundry-workflow-finalize.js +264 -0
- package/package-dist/scripts/lib/foundry-workflow-identity-apply.d.ts +14 -0
- package/package-dist/scripts/lib/foundry-workflow-identity-apply.js +159 -0
- package/package-dist/scripts/lib/foundry-workflow-identity.d.ts +6 -0
- package/package-dist/scripts/lib/foundry-workflow-identity.js +153 -0
- package/package-dist/scripts/lib/foundry-workflow-import.d.ts +4 -0
- package/package-dist/scripts/lib/foundry-workflow-import.js +70 -0
- package/package-dist/scripts/lib/foundry-workflow-io.d.ts +11 -0
- package/package-dist/scripts/lib/foundry-workflow-io.js +77 -0
- package/package-dist/scripts/lib/foundry-workflow-reference-verify.d.ts +41 -0
- package/package-dist/scripts/lib/foundry-workflow-reference-verify.js +266 -0
- package/package-dist/scripts/lib/foundry-workflow-rows.d.ts +2 -0
- package/package-dist/scripts/lib/foundry-workflow-rows.js +47 -0
- package/package-dist/scripts/lib/foundry-workflow-semantic.d.ts +5 -0
- package/package-dist/scripts/lib/foundry-workflow-semantic.js +367 -0
- package/package-dist/scripts/lib/foundry-workflow-state.d.ts +37 -0
- package/package-dist/scripts/lib/foundry-workflow-state.js +158 -0
- package/package-dist/scripts/lib/full-context-proof.d.ts +51 -0
- package/package-dist/scripts/lib/full-context-proof.js +932 -0
- package/package-dist/scripts/lib/identity-preflight-artifacts.d.ts +184 -0
- package/package-dist/scripts/lib/identity-preflight-artifacts.js +573 -0
- package/package-dist/scripts/lib/identity-preflight-proof.d.ts +117 -0
- package/package-dist/scripts/lib/identity-preflight-proof.js +341 -0
- package/package-dist/scripts/lib/identity-reference-rewrite-utils.d.ts +147 -0
- package/package-dist/scripts/lib/identity-reference-rewrite-utils.js +817 -0
- package/package-dist/scripts/lib/import-curation/authoring-packages.d.ts +28 -0
- package/package-dist/scripts/lib/import-curation/authoring-packages.js +92 -0
- package/package-dist/scripts/lib/import-curation/curation-cleanup.d.ts +32 -0
- package/package-dist/scripts/lib/import-curation/curation-cleanup.js +203 -0
- package/package-dist/scripts/lib/import-curation/curation-gate.d.ts +47 -0
- package/package-dist/scripts/lib/import-curation/curation-gate.js +528 -0
- package/package-dist/scripts/lib/import-curation/internal/artifact-inputs.d.ts +24 -0
- package/package-dist/scripts/lib/import-curation/internal/artifact-inputs.js +152 -0
- package/package-dist/scripts/lib/import-curation/internal/authoring-patch-workflow.d.ts +3 -0
- package/package-dist/scripts/lib/import-curation/internal/authoring-patch-workflow.js +3 -0
- package/package-dist/scripts/lib/import-curation/internal/authoring-task-workflow.d.ts +1 -0
- package/package-dist/scripts/lib/import-curation/internal/authoring-task-workflow.js +1 -0
- package/package-dist/scripts/lib/import-curation/internal/context-inputs.d.ts +56 -0
- package/package-dist/scripts/lib/import-curation/internal/context-inputs.js +206 -0
- package/package-dist/scripts/lib/import-curation/internal/curation-gate-workflow.d.ts +14 -0
- package/package-dist/scripts/lib/import-curation/internal/curation-gate-workflow.js +14 -0
- package/package-dist/scripts/lib/import-curation/internal/dataset-payload.d.ts +70 -0
- package/package-dist/scripts/lib/import-curation/internal/dataset-payload.js +141 -0
- package/package-dist/scripts/lib/import-curation/internal/dataset-types.d.ts +25 -0
- package/package-dist/scripts/lib/import-curation/internal/dataset-types.js +45 -0
- package/package-dist/scripts/lib/import-curation/internal/full-context-proof.d.ts +129 -0
- package/package-dist/scripts/lib/import-curation/internal/full-context-proof.js +552 -0
- package/package-dist/scripts/lib/import-curation/internal/hash-utils.d.ts +2 -0
- package/package-dist/scripts/lib/import-curation/internal/hash-utils.js +10 -0
- package/package-dist/scripts/lib/import-curation/internal/mutation-manifest-workflow.d.ts +15 -0
- package/package-dist/scripts/lib/import-curation/internal/mutation-manifest-workflow.js +15 -0
- package/package-dist/scripts/lib/import-curation/internal/prewrite-cleanup.d.ts +31 -0
- package/package-dist/scripts/lib/import-curation/internal/prewrite-cleanup.js +467 -0
- package/package-dist/scripts/lib/import-curation/internal/profiles-config.d.ts +47 -0
- package/package-dist/scripts/lib/import-curation/internal/profiles-config.js +88 -0
- package/package-dist/scripts/lib/import-curation/internal/runtime-io.d.ts +23 -0
- package/package-dist/scripts/lib/import-curation/internal/runtime-io.js +132 -0
- package/package-dist/scripts/lib/import-curation/internal/trace-summary.d.ts +53 -0
- package/package-dist/scripts/lib/import-curation/internal/trace-summary.js +114 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-authoring-tasks.d.ts +141 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-authoring-tasks.js +854 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-decision-apply-context.d.ts +20 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-decision-apply-context.js +46 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-decision-full-context.d.ts +110 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-decision-full-context.js +782 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-dry-run-context.d.ts +24 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-dry-run-context.js +191 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-evidence-scope.d.ts +80 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-evidence-scope.js +359 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-identity-decision-context.d.ts +146 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-identity-decision-context.js +381 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-identity-preflight.d.ts +223 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-identity-preflight.js +1079 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-collect.d.ts +41 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-collect.js +412 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-evidence-context.d.ts +117 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-evidence-context.js +278 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-evidence.d.ts +59 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-patch-evidence.js +593 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-queue-context.d.ts +58 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-queue-context.js +263 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-reference-closure.d.ts +177 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-reference-closure.js +812 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-row-transform-context.d.ts +159 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-row-transform-context.js +466 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-semantic-actions.d.ts +152 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-semantic-actions.js +1377 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-source-reference-context.d.ts +38 -0
- package/package-dist/scripts/lib/import-curation/internal/workflow-source-reference-context.js +116 -0
- package/package-dist/scripts/lib/import-curation/mutation-manifest.d.ts +51 -0
- package/package-dist/scripts/lib/import-curation/mutation-manifest.js +542 -0
- package/package-dist/scripts/lib/import-curation/patch-collect.d.ts +18 -0
- package/package-dist/scripts/lib/import-curation/patch-collect.js +172 -0
- package/package-dist/scripts/lib/import-curation/profiles.d.ts +1 -0
- package/package-dist/scripts/lib/import-curation/profiles.js +1 -0
- package/package-dist/scripts/lib/import-curation/trace-summary.d.ts +1 -0
- package/package-dist/scripts/lib/import-curation/trace-summary.js +1 -0
- package/package-dist/scripts/lib/oauth-session-reference.d.ts +1 -0
- package/package-dist/scripts/lib/oauth-session-reference.js +20 -0
- package/package-dist/scripts/lib/post-authoring-finalize-utils.d.ts +95 -0
- package/package-dist/scripts/lib/post-authoring-finalize-utils.js +548 -0
- package/package-dist/scripts/lib/post-write-root-proof.d.ts +44 -0
- package/package-dist/scripts/lib/post-write-root-proof.js +169 -0
- package/package-dist/scripts/lib/reference-description-text.d.ts +2 -0
- package/package-dist/scripts/lib/reference-description-text.js +12 -0
- package/package-dist/scripts/lib/remote-verification-accepted-diff.d.ts +42 -0
- package/package-dist/scripts/lib/remote-verification-accepted-diff.js +424 -0
- package/package-dist/scripts/lib/same-identity-commit-recovery.d.ts +8 -0
- package/package-dist/scripts/lib/same-identity-commit-recovery.js +52 -0
- package/package-dist/scripts/lib/source-semantics.d.ts +255 -0
- package/package-dist/scripts/lib/source-semantics.js +888 -0
- package/package-dist/scripts/lib/stage-contract.d.ts +36 -0
- package/package-dist/scripts/lib/stage-contract.js +25 -0
- package/package-dist/scripts/lib/task-authorization.d.ts +84 -0
- package/package-dist/scripts/lib/task-authorization.js +210 -0
- package/package-dist/scripts/lib/tidas-adapter.d.ts +113 -0
- package/package-dist/scripts/lib/tidas-adapter.js +525 -0
- package/package-dist/scripts/lib/tidas-language-utils.d.ts +8 -0
- package/package-dist/scripts/lib/tidas-language-utils.js +206 -0
- package/package-dist/scripts/lib/tidas-row-utils.d.ts +70 -0
- package/package-dist/scripts/lib/tidas-row-utils.js +225 -0
- package/package-dist/scripts/lib/trace-coverage.d.ts +53 -0
- package/package-dist/scripts/lib/trace-coverage.js +178 -0
- package/package-dist/scripts/package-entry.d.ts +2 -0
- package/package-dist/scripts/package-entry.js +4 -0
- package/package-dist/scripts/public-api.d.ts +80 -0
- package/package-dist/scripts/public-api.js +28 -0
- package/package-dist/scripts/runtime-entry.d.ts +23 -0
- package/package-dist/scripts/runtime-entry.js +424 -0
- package/package.json +93 -0
- package/specs/canonical-support/flow-properties-unit-groups.json +2692 -0
- package/specs/import-profiles.json +118 -0
- package/specs/prewrite-content-policy.json +105 -0
- package/specs/schemas/authorization-derivation.schema.json +34 -0
- package/specs/schemas/execution-context.schema.json +68 -0
- package/specs/schemas/foundry-authorization-input.schema.json +120 -0
- package/specs/schemas/foundry-facade-request-index.schema.json +78 -0
- package/specs/schemas/foundry-managed-runtime.schema.json +122 -0
- package/specs/schemas/foundry-migration-activation.schema.json +213 -0
- package/specs/schemas/foundry-migration-adoption-plan.schema.json +548 -0
- package/specs/schemas/foundry-migration-transfer-receipt.schema.json +93 -0
- package/specs/schemas/foundry-operation-result.schema.json +147 -0
- package/specs/schemas/foundry-package-descriptor.schema.json +134 -0
- package/specs/schemas/foundry-runtime-selection.schema.json +59 -0
- package/specs/schemas/foundry-semantic-input.schema.json +36 -0
- package/specs/schemas/foundry-task-start.schema.json +123 -0
- package/specs/schemas/foundry-workspace-migration-pending.schema.json +17 -0
- package/specs/schemas/foundry-workspace-migration-plan.schema.json +59 -0
- package/specs/schemas/foundry-workspace-migration-transfer-plan.schema.json +357 -0
- package/specs/schemas/foundry-workspace-v2.schema.json +70 -0
- package/specs/schemas/runtime-qualification.schema.json +63 -0
- package/specs/schemas/task-authorization.schema.json +154 -0
- package/specs/schemas/tidas-runtime-expectation.schema.json +54 -0
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema_version": 2,
|
|
3
|
+
"updated_at_utc": "2026-09-08T09:24:59Z",
|
|
4
|
+
"default_profile": "generic",
|
|
5
|
+
"profiles": {
|
|
6
|
+
"generic": {
|
|
7
|
+
"id": "generic",
|
|
8
|
+
"description": "Default import profile for external datasets. It adds no dataset-specific waivers and relies on schema, QA, curation, cleanup, dry-run, and verification gates.",
|
|
9
|
+
"docs": []
|
|
10
|
+
},
|
|
11
|
+
"bafu": {
|
|
12
|
+
"id": "bafu",
|
|
13
|
+
"description": "BAFU / FOEN rules for BAFU 2025 ecoSpold1 conversion, library and process closure, canonical-first support reuse, true-source attribution, one canonical FOEN/BAFU contact, source-only-output proof and strict full-context authoring. Account-local support and elementary actions require separate task authorization.",
|
|
14
|
+
"docs": [
|
|
15
|
+
"docs/import-profiles/bafu/profile.md",
|
|
16
|
+
"docs/import-profiles/bafu/constraints.md",
|
|
17
|
+
"docs/import-profiles/bafu/leaf-process-classification-authoring.md"
|
|
18
|
+
],
|
|
19
|
+
"full_context_ai_completion": {
|
|
20
|
+
"required": true,
|
|
21
|
+
"dataset_types": ["flow", "process", "lifecyclemodel"],
|
|
22
|
+
"required_context_kinds": [
|
|
23
|
+
"schema",
|
|
24
|
+
"methodology_yaml",
|
|
25
|
+
"ruleset",
|
|
26
|
+
"classification_schema",
|
|
27
|
+
"location_schema"
|
|
28
|
+
],
|
|
29
|
+
"required_context_file_patterns": [
|
|
30
|
+
"schema.json",
|
|
31
|
+
"methodology.yaml",
|
|
32
|
+
"runtime-ruleset.json",
|
|
33
|
+
"tidas_contacts_category.json",
|
|
34
|
+
"tidas_flowproperties_category.json",
|
|
35
|
+
"tidas_flows_elementary_category.json",
|
|
36
|
+
"tidas_flows_product_category.json",
|
|
37
|
+
"tidas_lciamethods_category.json",
|
|
38
|
+
"tidas_processes_category.json",
|
|
39
|
+
"tidas_sources_category.json",
|
|
40
|
+
"tidas_unitgroups_category.json",
|
|
41
|
+
"tidas_locations_category.json"
|
|
42
|
+
],
|
|
43
|
+
"proof": "dataset-identity-decision-task-build plus dataset-identity-decisions-apply with authoring_package_sha256 and closes_action_items evidence for identity-preflight decisions, dataset-classification-decisions-apply with matching classification decision task/context_bundle_sha256 for classification queues, dataset-location-decisions-apply with matching location decision task/context_bundle_sha256 for location queues, dataset-curation-cleanup deterministic proof for source-only-output exchange completeness when an explicit source rows file proves the source and final exchange signatures, or dataset-authoring-patch-collect plus dataset-patch-apply with authoring_package_sha256 and closes_action_items evidence for other field patches"
|
|
44
|
+
},
|
|
45
|
+
"qa_observation_candidates": {
|
|
46
|
+
"process_material_balance_deviation": "May be classified as a source-model observation only with task-bound user approval and content-bound source-model evidence. All other QA, schema, unit-scale, curation and reference checks remain blocking."
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"uslci": {
|
|
50
|
+
"id": "uslci",
|
|
51
|
+
"description": "USLCI source-format and import guidance. Generic curation applies; source aggregation/formula observations and account-local support require separate evidence-bound task authorization.",
|
|
52
|
+
"docs": [
|
|
53
|
+
"docs/import-profiles/uslci/profile.md",
|
|
54
|
+
"docs/import-profiles/uslci/constraints.md",
|
|
55
|
+
"docs/uslci-import-runbook.md"
|
|
56
|
+
],
|
|
57
|
+
"full_context_ai_completion": {
|
|
58
|
+
"required": false,
|
|
59
|
+
"dataset_types": [],
|
|
60
|
+
"required_context_kinds": [],
|
|
61
|
+
"required_context_file_patterns": [],
|
|
62
|
+
"proof": "No USLCI-specific full-context AI proof override is approved yet; use generic curation and queue verification gates."
|
|
63
|
+
},
|
|
64
|
+
"qa_observation_candidates": {
|
|
65
|
+
"process_material_balance_deviation": "May be classified as a source-model observation only with task-bound user approval and content-bound source-model evidence. All other QA, schema, unit-scale, curation and reference checks remain blocking."
|
|
66
|
+
},
|
|
67
|
+
"domain_rules": {
|
|
68
|
+
"preserve_referenced_review_sources": true
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
"worldsteel": {
|
|
72
|
+
"id": "worldsteel",
|
|
73
|
+
"description": "Worldsteel EF3.1-reference ILCD rules: canonical UUID reuse, corrected eILCD validation, true source attachments and World Steel Association contact identity. Canonical cache misses remain gated task-local candidates. Account-local actions and source-model QA observations require separate task authorization; full-context proof is required.",
|
|
74
|
+
"docs": [
|
|
75
|
+
"docs/import-profiles/worldsteel/profile.md",
|
|
76
|
+
"docs/import-profiles/worldsteel/constraints.md",
|
|
77
|
+
"docs/import-profiles/worldsteel/import-plan.md",
|
|
78
|
+
"docs/import-profiles/worldsteel/import-coverage.md"
|
|
79
|
+
],
|
|
80
|
+
"full_context_ai_completion": {
|
|
81
|
+
"required": true,
|
|
82
|
+
"dataset_types": ["flow", "process", "lifecyclemodel"],
|
|
83
|
+
"required_context_kinds": [
|
|
84
|
+
"schema",
|
|
85
|
+
"methodology_yaml",
|
|
86
|
+
"ruleset",
|
|
87
|
+
"classification_schema",
|
|
88
|
+
"location_schema"
|
|
89
|
+
],
|
|
90
|
+
"required_context_file_patterns": [
|
|
91
|
+
"schema.json",
|
|
92
|
+
"methodology.yaml",
|
|
93
|
+
"runtime-ruleset.json",
|
|
94
|
+
"tidas_contacts_category.json",
|
|
95
|
+
"tidas_flowproperties_category.json",
|
|
96
|
+
"tidas_flows_elementary_category.json",
|
|
97
|
+
"tidas_flows_product_category.json",
|
|
98
|
+
"tidas_lciamethods_category.json",
|
|
99
|
+
"tidas_processes_category.json",
|
|
100
|
+
"tidas_sources_category.json",
|
|
101
|
+
"tidas_unitgroups_category.json",
|
|
102
|
+
"tidas_locations_category.json"
|
|
103
|
+
],
|
|
104
|
+
"proof": "dataset-identity-decision-task-build plus dataset-identity-decisions-apply with authoring_package_sha256 and closes_action_items evidence for identity-preflight decisions, dataset-classification-decisions-apply with matching classification decision task/context_bundle_sha256 for classification queues, dataset-location-decisions-apply with matching location decision task/context_bundle_sha256 for location queues, dataset-curation-cleanup deterministic proof for source-only-output exchange completeness when an explicit source rows file proves the source and final exchange signatures, or dataset-authoring-patch-collect plus dataset-patch-apply with authoring_package_sha256 and closes_action_items evidence for other field patches"
|
|
105
|
+
},
|
|
106
|
+
"qa_observation_candidates": {
|
|
107
|
+
"process_material_balance_deviation": "May be classified as a source-model observation only with task-bound user approval and content-bound source-model evidence. All other QA, schema, unit-scale, curation and reference checks remain blocking."
|
|
108
|
+
},
|
|
109
|
+
"domain_rules": {
|
|
110
|
+
"process_name_geography_year": {
|
|
111
|
+
"geographies": ["Global", "EU"],
|
|
112
|
+
"field": "baseName",
|
|
113
|
+
"marker": "latin-author-year"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema_version": 1,
|
|
3
|
+
"rules": [
|
|
4
|
+
{
|
|
5
|
+
"id": "dataset-name-describes-model-not-source-locator",
|
|
6
|
+
"code": "source_locator_in_dataset_name",
|
|
7
|
+
"stage": "prewrite_content_quality",
|
|
8
|
+
"severity": "blocker",
|
|
9
|
+
"dataset_types": ["flow", "process", "lifecyclemodel"],
|
|
10
|
+
"path_scope": {
|
|
11
|
+
"contains": ["dataSetInformation", "name"]
|
|
12
|
+
},
|
|
13
|
+
"lexicon": "source_locator_markers",
|
|
14
|
+
"message": "Dataset name information must describe the modeled product, process, route, or location. Source citation locators belong in source references or provenance artifacts."
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"id": "write-payload-excludes-foundry-workflow-state",
|
|
18
|
+
"code": "workflow_state_text_in_write_payload",
|
|
19
|
+
"stage": "prewrite_content_quality",
|
|
20
|
+
"severity": "blocker",
|
|
21
|
+
"dataset_types": ["flow", "process", "lifecyclemodel"],
|
|
22
|
+
"path_scope": {
|
|
23
|
+
"exclude_contains": ["common:other", "tiangongfoundry"]
|
|
24
|
+
},
|
|
25
|
+
"lexicon": "workflow_state_markers",
|
|
26
|
+
"message": "Write payload text must not contain Foundry workflow state, candidate status, curation state, dry-run state, handoff state, or remote-write approval language."
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
"lexicons": {
|
|
30
|
+
"source_locator_markers": [
|
|
31
|
+
{
|
|
32
|
+
"id": "latin-author-year",
|
|
33
|
+
"pattern": "\\b(?!(?:summer|winter|spring|autumn|fall)\\s)[A-Z][A-Za-z]+(?:\\s+et\\s+al\\.)?\\s+(?:19|20)\\d{2}\\b",
|
|
34
|
+
"flags": "iu"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"id": "cjk-author-year",
|
|
38
|
+
"pattern": "[\\p{Script=Han}·]{2,12}\\s*(?:19|20)\\d{2}",
|
|
39
|
+
"flags": "u"
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"id": "numbered-table",
|
|
43
|
+
"pattern": "\\b(?:Table|Tbl\\.)\\s*\\d+[A-Za-z]?\\b",
|
|
44
|
+
"flags": "iu"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"id": "numbered-table-cjk",
|
|
48
|
+
"pattern": "表\\s*\\d+",
|
|
49
|
+
"flags": "u"
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"id": "numbered-figure",
|
|
53
|
+
"pattern": "\\b(?:Figure|Fig\\.)\\s*\\d+[A-Za-z]?\\b",
|
|
54
|
+
"flags": "iu"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"id": "numbered-figure-cjk",
|
|
58
|
+
"pattern": "图\\s*\\d+",
|
|
59
|
+
"flags": "u"
|
|
60
|
+
}
|
|
61
|
+
],
|
|
62
|
+
"workflow_state_markers": [
|
|
63
|
+
{
|
|
64
|
+
"id": "foundry-runtime",
|
|
65
|
+
"pattern": "(?<!\\b(?:metal|iron|steel|brass|bronze|aluminium|aluminum)\\s)\\bFoundry\\b(?!\\s+(?:moulds?|molds?|sand|works?|goods|industry|industries)\\b)",
|
|
66
|
+
"flags": "iu"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"id": "candidate-state",
|
|
70
|
+
"pattern": "\\b(?:candidate|write\\s+candidate)\\b",
|
|
71
|
+
"flags": "iu"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"id": "remote-write-state",
|
|
75
|
+
"pattern": "\\bremote\\s+write\\b",
|
|
76
|
+
"flags": "iu"
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"id": "curation-state",
|
|
80
|
+
"pattern": "\\bcuration[-_\\s](?:gate|gates|state|states|status|queue|round|rounds|checkpoint|backlog|deferral|deferred|workflow|pass)\\b",
|
|
81
|
+
"flags": "iu"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"id": "dry-run-state",
|
|
85
|
+
"pattern": "\\bdry-?run\\b",
|
|
86
|
+
"flags": "iu"
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"id": "handoff-state",
|
|
90
|
+
"pattern": "\\bhandoff\\b",
|
|
91
|
+
"flags": "iu"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"id": "candidate-state-cjk",
|
|
95
|
+
"pattern": "候选",
|
|
96
|
+
"flags": "u"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"id": "remote-write-state-cjk",
|
|
100
|
+
"pattern": "远端写入|不得[^。;;]*写入",
|
|
101
|
+
"flags": "u"
|
|
102
|
+
}
|
|
103
|
+
]
|
|
104
|
+
}
|
|
105
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://tiangong-lca.local/foundry/authorization-derivation.schema.json",
|
|
4
|
+
"title": "Foundry authorization derivation evidence v1",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schema",
|
|
9
|
+
"parent_authorization_sha256",
|
|
10
|
+
"derived_authorization_sha256",
|
|
11
|
+
"approved_input",
|
|
12
|
+
"derived_input"
|
|
13
|
+
],
|
|
14
|
+
"properties": {
|
|
15
|
+
"schema": { "const": "tiangong-foundry.authorization-derivation.v1" },
|
|
16
|
+
"parent_authorization_sha256": { "$ref": "#/$defs/sha256" },
|
|
17
|
+
"derived_authorization_sha256": { "$ref": "#/$defs/sha256" },
|
|
18
|
+
"approved_input": { "$ref": "#/$defs/inputFact" },
|
|
19
|
+
"derived_input": { "$ref": "#/$defs/inputFact" }
|
|
20
|
+
},
|
|
21
|
+
"$defs": {
|
|
22
|
+
"sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
|
|
23
|
+
"inputFact": {
|
|
24
|
+
"type": "object",
|
|
25
|
+
"additionalProperties": false,
|
|
26
|
+
"required": ["path", "bytes", "sha256"],
|
|
27
|
+
"properties": {
|
|
28
|
+
"path": { "type": "string", "minLength": 1 },
|
|
29
|
+
"bytes": { "type": "integer", "minimum": 0 },
|
|
30
|
+
"sha256": { "$ref": "#/$defs/sha256" }
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://tiangong-lca.local/foundry/execution-context.schema.json",
|
|
4
|
+
"title": "Foundry child execution context v1",
|
|
5
|
+
"description": "Content-addressed handoff evidence. Rehydration and process-local checks are still required before execution.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"schema",
|
|
10
|
+
"workspace_id",
|
|
11
|
+
"task_id",
|
|
12
|
+
"actor_id",
|
|
13
|
+
"command",
|
|
14
|
+
"qualification_sha256",
|
|
15
|
+
"authorization_sha256",
|
|
16
|
+
"approved_input",
|
|
17
|
+
"final_rows",
|
|
18
|
+
"required_actions",
|
|
19
|
+
"required_qa_waivers",
|
|
20
|
+
"command_spec_sha256"
|
|
21
|
+
],
|
|
22
|
+
"properties": {
|
|
23
|
+
"schema": { "const": "tiangong-foundry.execution-context.v1" },
|
|
24
|
+
"workspace_id": { "$ref": "#/$defs/id" },
|
|
25
|
+
"task_id": { "$ref": "#/$defs/id" },
|
|
26
|
+
"actor_id": { "$ref": "#/$defs/id" },
|
|
27
|
+
"command": { "$ref": "#/$defs/id" },
|
|
28
|
+
"qualification_sha256": { "$ref": "#/$defs/sha256" },
|
|
29
|
+
"authorization_sha256": { "$ref": "#/$defs/sha256" },
|
|
30
|
+
"approved_input": { "$ref": "#/$defs/inputFact" },
|
|
31
|
+
"final_rows": { "$ref": "#/$defs/inputFact" },
|
|
32
|
+
"required_actions": {
|
|
33
|
+
"type": "array",
|
|
34
|
+
"maxItems": 5,
|
|
35
|
+
"uniqueItems": true,
|
|
36
|
+
"items": {
|
|
37
|
+
"enum": [
|
|
38
|
+
"elementary_flow_write",
|
|
39
|
+
"elementary_flow_create_new",
|
|
40
|
+
"flowproperty_write",
|
|
41
|
+
"unitgroup_write",
|
|
42
|
+
"canonical_support_local_mint"
|
|
43
|
+
]
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"required_qa_waivers": {
|
|
47
|
+
"type": "array",
|
|
48
|
+
"maxItems": 1,
|
|
49
|
+
"uniqueItems": true,
|
|
50
|
+
"items": { "const": "process_material_balance_deviation" }
|
|
51
|
+
},
|
|
52
|
+
"command_spec_sha256": { "$ref": "#/$defs/sha256" }
|
|
53
|
+
},
|
|
54
|
+
"$defs": {
|
|
55
|
+
"id": { "type": "string", "minLength": 1, "maxLength": 256 },
|
|
56
|
+
"sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
|
|
57
|
+
"inputFact": {
|
|
58
|
+
"type": "object",
|
|
59
|
+
"additionalProperties": false,
|
|
60
|
+
"required": ["path", "bytes", "sha256"],
|
|
61
|
+
"properties": {
|
|
62
|
+
"path": { "type": "string", "minLength": 1 },
|
|
63
|
+
"bytes": { "type": "integer", "minimum": 0 },
|
|
64
|
+
"sha256": { "$ref": "#/$defs/sha256" }
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"title": "Foundry Authorization Input v1",
|
|
4
|
+
"type": "object",
|
|
5
|
+
"additionalProperties": false,
|
|
6
|
+
"required": [
|
|
7
|
+
"schema",
|
|
8
|
+
"task_id",
|
|
9
|
+
"actor_id",
|
|
10
|
+
"finalization_sha256",
|
|
11
|
+
"dataset_type",
|
|
12
|
+
"input_kind",
|
|
13
|
+
"input_sha256",
|
|
14
|
+
"expected_previous_sha256",
|
|
15
|
+
"grant",
|
|
16
|
+
"evidence"
|
|
17
|
+
],
|
|
18
|
+
"properties": {
|
|
19
|
+
"schema": {
|
|
20
|
+
"const": "tiangong-foundry.authorization-input.v1"
|
|
21
|
+
},
|
|
22
|
+
"task_id": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"pattern": "^task-[0-9a-f]{64}-r[0-9]{4}$"
|
|
25
|
+
},
|
|
26
|
+
"actor_id": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9._:/-]{0,255}$"
|
|
29
|
+
},
|
|
30
|
+
"finalization_sha256": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
33
|
+
},
|
|
34
|
+
"dataset_type": {
|
|
35
|
+
"enum": [
|
|
36
|
+
"flow",
|
|
37
|
+
"process",
|
|
38
|
+
"contact",
|
|
39
|
+
"source",
|
|
40
|
+
"unitgroup",
|
|
41
|
+
"flowproperty",
|
|
42
|
+
"lifecyclemodel"
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
"input_kind": {
|
|
46
|
+
"enum": ["current_rows", "final_rows"]
|
|
47
|
+
},
|
|
48
|
+
"input_sha256": {
|
|
49
|
+
"type": "string",
|
|
50
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
51
|
+
},
|
|
52
|
+
"expected_previous_sha256": {
|
|
53
|
+
"anyOf": [
|
|
54
|
+
{
|
|
55
|
+
"type": "string",
|
|
56
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"type": "null"
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
},
|
|
63
|
+
"grant": {
|
|
64
|
+
"type": "object",
|
|
65
|
+
"additionalProperties": false,
|
|
66
|
+
"required": ["file", "sha256"],
|
|
67
|
+
"properties": {
|
|
68
|
+
"file": {
|
|
69
|
+
"type": "string",
|
|
70
|
+
"minLength": 1,
|
|
71
|
+
"maxLength": 4096,
|
|
72
|
+
"pattern": "^[^\\u0000\\r\\n]+$"
|
|
73
|
+
},
|
|
74
|
+
"sha256": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
"evidence": {
|
|
81
|
+
"type": "array",
|
|
82
|
+
"minItems": 1,
|
|
83
|
+
"maxItems": 100,
|
|
84
|
+
"items": {
|
|
85
|
+
"type": "object",
|
|
86
|
+
"additionalProperties": false,
|
|
87
|
+
"required": ["id", "kind", "file", "sha256"],
|
|
88
|
+
"properties": {
|
|
89
|
+
"id": {
|
|
90
|
+
"type": "string",
|
|
91
|
+
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9._:/-]{0,255}$"
|
|
92
|
+
},
|
|
93
|
+
"kind": {
|
|
94
|
+
"enum": ["user-decision", "source-model"]
|
|
95
|
+
},
|
|
96
|
+
"file": {
|
|
97
|
+
"type": "string",
|
|
98
|
+
"minLength": 1,
|
|
99
|
+
"maxLength": 4096,
|
|
100
|
+
"pattern": "^[^\\u0000\\r\\n]+$"
|
|
101
|
+
},
|
|
102
|
+
"sha256": {
|
|
103
|
+
"type": "string",
|
|
104
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
"contains": {
|
|
109
|
+
"type": "object",
|
|
110
|
+
"required": ["kind"],
|
|
111
|
+
"properties": {
|
|
112
|
+
"kind": {
|
|
113
|
+
"const": "user-decision"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"minContains": 1
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://tiangong-lca.local/foundry/facade-request-index.schema.json",
|
|
4
|
+
"title": "Foundry facade request index v1",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schema",
|
|
9
|
+
"workspace_id",
|
|
10
|
+
"request_id",
|
|
11
|
+
"request_sha256",
|
|
12
|
+
"revisions",
|
|
13
|
+
"index_sha256"
|
|
14
|
+
],
|
|
15
|
+
"properties": {
|
|
16
|
+
"schema": { "const": "tiangong-foundry.facade-request-index.v1" },
|
|
17
|
+
"workspace_id": { "$ref": "#/$defs/id" },
|
|
18
|
+
"request_id": { "$ref": "#/$defs/id" },
|
|
19
|
+
"request_sha256": { "$ref": "#/$defs/sha256" },
|
|
20
|
+
"revisions": {
|
|
21
|
+
"type": "array",
|
|
22
|
+
"minItems": 1,
|
|
23
|
+
"maxItems": 1000,
|
|
24
|
+
"items": { "$ref": "#/$defs/revision" }
|
|
25
|
+
},
|
|
26
|
+
"index_sha256": { "$ref": "#/$defs/sha256" }
|
|
27
|
+
},
|
|
28
|
+
"$defs": {
|
|
29
|
+
"id": { "type": "string", "minLength": 1, "maxLength": 256 },
|
|
30
|
+
"sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
|
|
31
|
+
"fact": {
|
|
32
|
+
"type": "object",
|
|
33
|
+
"additionalProperties": false,
|
|
34
|
+
"required": ["path", "bytes", "sha256"],
|
|
35
|
+
"properties": {
|
|
36
|
+
"path": { "type": "string", "minLength": 1 },
|
|
37
|
+
"bytes": { "type": "integer", "minimum": 0 },
|
|
38
|
+
"sha256": { "$ref": "#/$defs/sha256" }
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"revision": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"additionalProperties": false,
|
|
44
|
+
"required": [
|
|
45
|
+
"revision",
|
|
46
|
+
"task_id",
|
|
47
|
+
"predecessor_task_id",
|
|
48
|
+
"fingerprint_sha256",
|
|
49
|
+
"spec_source",
|
|
50
|
+
"spec",
|
|
51
|
+
"inputs",
|
|
52
|
+
"created_at_utc",
|
|
53
|
+
"record_sha256"
|
|
54
|
+
],
|
|
55
|
+
"properties": {
|
|
56
|
+
"revision": { "type": "integer", "minimum": 1, "maximum": 1000 },
|
|
57
|
+
"task_id": { "type": "string", "pattern": "^task-[0-9a-f]{64}-r[0-9]{4}$" },
|
|
58
|
+
"predecessor_task_id": {
|
|
59
|
+
"oneOf": [
|
|
60
|
+
{ "type": "string", "pattern": "^task-[0-9a-f]{64}-r[0-9]{4}$" },
|
|
61
|
+
{ "type": "null" }
|
|
62
|
+
]
|
|
63
|
+
},
|
|
64
|
+
"fingerprint_sha256": { "$ref": "#/$defs/sha256" },
|
|
65
|
+
"spec_source": { "$ref": "#/$defs/fact" },
|
|
66
|
+
"spec": { "$ref": "https://tiangong-lca.local/foundry/task-start.schema.json" },
|
|
67
|
+
"inputs": {
|
|
68
|
+
"type": "array",
|
|
69
|
+
"minItems": 1,
|
|
70
|
+
"maxItems": 1000,
|
|
71
|
+
"items": { "$ref": "#/$defs/fact" }
|
|
72
|
+
},
|
|
73
|
+
"created_at_utc": { "type": "string" },
|
|
74
|
+
"record_sha256": { "$ref": "#/$defs/sha256" }
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://tiangong-lca.local/foundry/foundry-managed-runtime.schema.json",
|
|
4
|
+
"title": "Foundry managed runtime binding v1",
|
|
5
|
+
"$comment": "Structural contract only. The package host additionally validates the independently trusted manifest, installed entry, component files, current platform and launch/target relationships.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": ["schema", "platform", "cli", "tidas", "launches"],
|
|
9
|
+
"properties": {
|
|
10
|
+
"schema": {
|
|
11
|
+
"const": "tiangong-foundry.managed-runtime.v1"
|
|
12
|
+
},
|
|
13
|
+
"platform": {
|
|
14
|
+
"$ref": "#/$defs/platform"
|
|
15
|
+
},
|
|
16
|
+
"cli": {
|
|
17
|
+
"type": "object",
|
|
18
|
+
"additionalProperties": false,
|
|
19
|
+
"required": [
|
|
20
|
+
"schema",
|
|
21
|
+
"package_version",
|
|
22
|
+
"platform",
|
|
23
|
+
"content_sha256",
|
|
24
|
+
"node_version",
|
|
25
|
+
"node_sha256"
|
|
26
|
+
],
|
|
27
|
+
"properties": {
|
|
28
|
+
"schema": {
|
|
29
|
+
"const": "tiangong-lca.cli-runtime-expectation.v1"
|
|
30
|
+
},
|
|
31
|
+
"package_version": {
|
|
32
|
+
"const": "0.1.12"
|
|
33
|
+
},
|
|
34
|
+
"platform": {
|
|
35
|
+
"$ref": "#/$defs/platform"
|
|
36
|
+
},
|
|
37
|
+
"content_sha256": {
|
|
38
|
+
"$ref": "#/$defs/sha256"
|
|
39
|
+
},
|
|
40
|
+
"node_sha256": {
|
|
41
|
+
"$ref": "#/$defs/sha256"
|
|
42
|
+
},
|
|
43
|
+
"node_version": {
|
|
44
|
+
"type": "string",
|
|
45
|
+
"maxLength": 64,
|
|
46
|
+
"pattern": "^(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)\\.(0|[1-9][0-9]*)$"
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
},
|
|
50
|
+
"tidas": {
|
|
51
|
+
"type": "object",
|
|
52
|
+
"additionalProperties": false,
|
|
53
|
+
"required": ["executable", "expectation"],
|
|
54
|
+
"properties": {
|
|
55
|
+
"executable": {
|
|
56
|
+
"$ref": "#/$defs/componentReference"
|
|
57
|
+
},
|
|
58
|
+
"expectation": {
|
|
59
|
+
"$ref": "https://tiangong-lca.local/foundry/tidas-runtime-expectation.schema.json"
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
"launches": {
|
|
64
|
+
"type": "array",
|
|
65
|
+
"minItems": 1,
|
|
66
|
+
"maxItems": 16,
|
|
67
|
+
"uniqueItems": true,
|
|
68
|
+
"items": {
|
|
69
|
+
"type": "object",
|
|
70
|
+
"additionalProperties": false,
|
|
71
|
+
"required": ["id", "access", "target"],
|
|
72
|
+
"properties": {
|
|
73
|
+
"id": {
|
|
74
|
+
"$ref": "#/$defs/identifier"
|
|
75
|
+
},
|
|
76
|
+
"access": {
|
|
77
|
+
"enum": ["read", "write"]
|
|
78
|
+
},
|
|
79
|
+
"target": {
|
|
80
|
+
"anyOf": [
|
|
81
|
+
{
|
|
82
|
+
"type": "null"
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
"$ref": "#/$defs/componentReference"
|
|
86
|
+
}
|
|
87
|
+
]
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
"$defs": {
|
|
94
|
+
"sha256": {
|
|
95
|
+
"type": "string",
|
|
96
|
+
"pattern": "^[0-9a-f]{64}$"
|
|
97
|
+
},
|
|
98
|
+
"platform": {
|
|
99
|
+
"enum": ["linux-x64", "linux-arm64", "darwin-arm64", "win32-x64"]
|
|
100
|
+
},
|
|
101
|
+
"identifier": {
|
|
102
|
+
"type": "string",
|
|
103
|
+
"pattern": "^[a-zA-Z0-9][a-zA-Z0-9._-]{0,63}$"
|
|
104
|
+
},
|
|
105
|
+
"componentReference": {
|
|
106
|
+
"type": "object",
|
|
107
|
+
"additionalProperties": false,
|
|
108
|
+
"required": ["component", "path"],
|
|
109
|
+
"properties": {
|
|
110
|
+
"component": {
|
|
111
|
+
"$ref": "#/$defs/identifier"
|
|
112
|
+
},
|
|
113
|
+
"path": {
|
|
114
|
+
"type": "string",
|
|
115
|
+
"minLength": 1,
|
|
116
|
+
"maxLength": 1024,
|
|
117
|
+
"pattern": "^(?!/)(?!.*\\\\)(?!.*\\u0000)(?!.*:)(?!.*//)(?!.*(?:^|/)\\.{1,2}(?:/|$))(?!.*/$).+$"
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
}
|