@intentius/chant 0.90.0 → 0.93.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/dist/cli/commands/build.d.ts.map +1 -1
- package/dist/cli/commands/lint.d.ts.map +1 -1
- package/dist/cli/handlers/components.d.ts +8 -0
- package/dist/cli/handlers/components.d.ts.map +1 -1
- package/dist/cli/handlers/graph.d.ts.map +1 -1
- package/dist/cli/handlers/operator.d.ts +20 -0
- package/dist/cli/handlers/operator.d.ts.map +1 -1
- package/dist/cli/handlers/run.d.ts.map +1 -1
- package/dist/cli/main.d.ts.map +1 -1
- package/dist/cli/mcp/workspace-tools.d.ts +7 -4
- package/dist/cli/mcp/workspace-tools.d.ts.map +1 -1
- package/dist/cli/plugins.d.ts.map +1 -1
- package/dist/cli/registry.d.ts +42 -1
- package/dist/cli/registry.d.ts.map +1 -1
- package/dist/codegen/pinned-upgrade.d.ts.map +1 -1
- package/dist/components/verbs/vuln-scan.d.ts +72 -0
- package/dist/components/verbs/vuln-scan.d.ts.map +1 -1
- package/dist/config.d.ts +22 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/lexicon-module.d.ts +22 -0
- package/dist/lexicon-module.d.ts.map +1 -1
- package/dist/lifecycle/converge-ledger.d.ts +19 -0
- package/dist/lifecycle/converge-ledger.d.ts.map +1 -1
- package/dist/lifecycle/git.d.ts +40 -5
- package/dist/lifecycle/git.d.ts.map +1 -1
- package/dist/lifecycle/lease.d.ts +72 -16
- package/dist/lifecycle/lease.d.ts.map +1 -1
- package/dist/lifecycle/member-ledger.d.ts +3 -2
- package/dist/lifecycle/member-ledger.d.ts.map +1 -1
- package/dist/lifecycle/plan-ledger.d.ts +114 -0
- package/dist/lifecycle/plan-ledger.d.ts.map +1 -0
- package/dist/lifecycle/run-ledger.d.ts +2 -0
- package/dist/lifecycle/run-ledger.d.ts.map +1 -1
- package/dist/lifecycle/symptoms.d.ts +51 -0
- package/dist/lifecycle/symptoms.d.ts.map +1 -1
- package/dist/lifecycle/work-lease.d.ts +140 -0
- package/dist/lifecycle/work-lease.d.ts.map +1 -0
- package/dist/lint/rules/index.d.ts +4 -2
- package/dist/lint/rules/index.d.ts.map +1 -1
- package/dist/lint/rules/op/index.d.ts +14 -3
- package/dist/lint/rules/op/index.d.ts.map +1 -1
- package/dist/lint/rules/op/ops014-converge-rule-refusals.d.ts.map +1 -1
- package/dist/lint/rules/op/sys010-key-over-plain-http.d.ts +29 -0
- package/dist/lint/rules/op/sys010-key-over-plain-http.d.ts.map +1 -0
- package/dist/lint/rules/sys001-no-literal-key.d.ts +3 -0
- package/dist/lint/rules/sys001-no-literal-key.d.ts.map +1 -0
- package/dist/op/__fixtures__/decide-stub-backend.d.ts +53 -0
- package/dist/op/__fixtures__/decide-stub-backend.d.ts.map +1 -0
- package/dist/op/activities/activity-contracts.d.ts +203 -2
- package/dist/op/activities/activity-contracts.d.ts.map +1 -1
- package/dist/op/activities/apply.d.ts.map +1 -1
- package/dist/op/activities/change-coverage.d.ts +44 -0
- package/dist/op/activities/change-coverage.d.ts.map +1 -0
- package/dist/op/activities/converge.d.ts +24 -1
- package/dist/op/activities/converge.d.ts.map +1 -1
- package/dist/op/activities/decide.d.ts +107 -0
- package/dist/op/activities/decide.d.ts.map +1 -0
- package/dist/op/activities/index.d.ts +10 -0
- package/dist/op/activities/index.d.ts.map +1 -1
- package/dist/op/activities/shell.d.ts +32 -0
- package/dist/op/activities/shell.d.ts.map +1 -1
- package/dist/op/activities/source-release.d.ts +86 -0
- package/dist/op/activities/source-release.d.ts.map +1 -0
- package/dist/op/activities/source-rollback.d.ts +100 -0
- package/dist/op/activities/source-rollback.d.ts.map +1 -0
- package/dist/op/activities/work-evidence.d.ts +42 -0
- package/dist/op/activities/work-evidence.d.ts.map +1 -0
- package/dist/op/activity-contract.d.ts +1 -0
- package/dist/op/activity-contract.d.ts.map +1 -1
- package/dist/op/activity-profiles.d.ts +16 -0
- package/dist/op/activity-profiles.d.ts.map +1 -1
- package/dist/op/builders.d.ts +84 -2
- package/dist/op/builders.d.ts.map +1 -1
- package/dist/op/composites/converge-op.d.ts +31 -4
- package/dist/op/composites/converge-op.d.ts.map +1 -1
- package/dist/op/decide-backend.d.ts +116 -0
- package/dist/op/decide-backend.d.ts.map +1 -0
- package/dist/op/decide-config.d.ts +120 -0
- package/dist/op/decide-config.d.ts.map +1 -0
- package/dist/op/decide-read-inputs.d.ts +40 -0
- package/dist/op/decide-read-inputs.d.ts.map +1 -0
- package/dist/op/discover.d.ts +25 -0
- package/dist/op/discover.d.ts.map +1 -1
- package/dist/op/gate-wait.d.ts +43 -0
- package/dist/op/gate-wait.d.ts.map +1 -0
- package/dist/op/gate.d.ts +5 -2
- package/dist/op/gate.d.ts.map +1 -1
- package/dist/op/index.d.ts +18 -5
- package/dist/op/index.d.ts.map +1 -1
- package/dist/op/lifecycle-receipt-store.d.ts +34 -0
- package/dist/op/lifecycle-receipt-store.d.ts.map +1 -0
- package/dist/op/local-executor.d.ts +48 -4
- package/dist/op/local-executor.d.ts.map +1 -1
- package/dist/op/local-output.d.ts +2 -0
- package/dist/op/local-output.d.ts.map +1 -1
- package/dist/op/op-ir.d.ts +12 -1
- package/dist/op/op-ir.d.ts.map +1 -1
- package/dist/op/op-verb-class.d.ts.map +1 -1
- package/dist/op/operator.d.ts +126 -1
- package/dist/op/operator.d.ts.map +1 -1
- package/dist/op/runtime.d.ts +46 -5
- package/dist/op/runtime.d.ts.map +1 -1
- package/dist/op/runtimes/local.d.ts.map +1 -1
- package/dist/op/source-archive.d.ts +63 -0
- package/dist/op/source-archive.d.ts.map +1 -0
- package/dist/op/step-output-ref.d.ts +2 -2
- package/dist/op/step-output-ref.d.ts.map +1 -1
- package/dist/op/steward-points.d.ts +136 -0
- package/dist/op/steward-points.d.ts.map +1 -0
- package/dist/op/steward-turn.d.ts +53 -0
- package/dist/op/steward-turn.d.ts.map +1 -0
- package/dist/op/steward.d.ts +161 -0
- package/dist/op/steward.d.ts.map +1 -0
- package/dist/op/types.d.ts +58 -0
- package/dist/op/types.d.ts.map +1 -1
- package/dist/op/work-lease-decl.d.ts +18 -0
- package/dist/op/work-lease-decl.d.ts.map +1 -0
- package/dist/op/work-lease-run.d.ts +173 -0
- package/dist/op/work-lease-run.d.ts.map +1 -0
- package/dist/workspace/__fixtures__/decide-workspace.d.ts +100 -0
- package/dist/workspace/__fixtures__/decide-workspace.d.ts.map +1 -0
- package/dist/workspace/answers-ledger.d.ts +76 -0
- package/dist/workspace/answers-ledger.d.ts.map +1 -0
- package/dist/workspace/box-isolation.d.ts +99 -0
- package/dist/workspace/box-isolation.d.ts.map +1 -0
- package/dist/workspace/changes-cli.d.ts +16 -0
- package/dist/workspace/changes-cli.d.ts.map +1 -0
- package/dist/workspace/changes.d.ts +200 -0
- package/dist/workspace/changes.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-fly-site.d.ts +59 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-fly-site.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-live-names.d.ts +51 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-live-names.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-rollback.d.ts +26 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-rollback.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-ship-inputs.d.ts +59 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-ship-inputs.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-ship-policy.d.ts +22 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit-ship-policy.d.ts.map +1 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit.d.ts +71 -0
- package/dist/workspace/chant-migrations/chud-lexicon-exit.d.ts.map +1 -0
- package/dist/workspace/chant-migrations.d.ts +99 -0
- package/dist/workspace/chant-migrations.d.ts.map +1 -0
- package/dist/workspace/checks/box-isolation.d.ts +18 -0
- package/dist/workspace/checks/box-isolation.d.ts.map +1 -0
- package/dist/workspace/checks/boxes.d.ts +104 -0
- package/dist/workspace/checks/boxes.d.ts.map +1 -0
- package/dist/workspace/checks/diagrams.d.ts +31 -0
- package/dist/workspace/checks/diagrams.d.ts.map +1 -0
- package/dist/workspace/checks/records.d.ts +8 -0
- package/dist/workspace/checks/records.d.ts.map +1 -1
- package/dist/workspace/checks.d.ts +13 -1
- package/dist/workspace/checks.d.ts.map +1 -1
- package/dist/workspace/compose-graph.d.ts +2 -0
- package/dist/workspace/compose-graph.d.ts.map +1 -1
- package/dist/workspace/conformance/index.d.ts.map +1 -1
- package/dist/workspace/decide.d.ts +229 -0
- package/dist/workspace/decide.d.ts.map +1 -0
- package/dist/workspace/decision-points.schema.json +137 -0
- package/dist/workspace/declaration.d.ts +103 -0
- package/dist/workspace/declaration.d.ts.map +1 -1
- package/dist/workspace/declaration.schema.json +285 -0
- package/dist/workspace/declared-kinds.d.ts +32 -0
- package/dist/workspace/declared-kinds.d.ts.map +1 -1
- package/dist/workspace/generated-files.d.ts +7 -0
- package/dist/workspace/generated-files.d.ts.map +1 -1
- package/dist/workspace/intent.d.ts.map +1 -1
- package/dist/workspace/lineage-check.d.ts +3 -0
- package/dist/workspace/lineage-check.d.ts.map +1 -1
- package/dist/workspace/lineage-upgrade.d.ts +6 -1
- package/dist/workspace/lineage-upgrade.d.ts.map +1 -1
- package/dist/workspace/ls.d.ts +39 -1
- package/dist/workspace/ls.d.ts.map +1 -1
- package/dist/workspace/point-answer.schema.json +95 -0
- package/dist/workspace/points-cli.d.ts +113 -0
- package/dist/workspace/points-cli.d.ts.map +1 -0
- package/dist/workspace/points.d.ts +320 -0
- package/dist/workspace/points.d.ts.map +1 -0
- package/dist/workspace/reason-codes.d.ts +38 -0
- package/dist/workspace/reason-codes.d.ts.map +1 -1
- package/dist/workspace/record-assets.d.ts.map +1 -1
- package/dist/workspace/records-cli.d.ts +23 -1
- package/dist/workspace/records-cli.d.ts.map +1 -1
- package/dist/workspace/records-close.d.ts +1 -1
- package/dist/workspace/records-close.d.ts.map +1 -1
- package/dist/workspace/records-write.d.ts +11 -5
- package/dist/workspace/records-write.d.ts.map +1 -1
- package/dist/workspace/records.d.ts +42 -6
- package/dist/workspace/records.d.ts.map +1 -1
- package/dist/workspace/status-gates.d.ts +7 -2
- package/dist/workspace/status-gates.d.ts.map +1 -1
- package/dist/workspace/status-stewards.d.ts +179 -0
- package/dist/workspace/status-stewards.d.ts.map +1 -0
- package/dist/workspace/status.d.ts +68 -1
- package/dist/workspace/status.d.ts.map +1 -1
- package/dist/workspace/work-cli.d.ts +189 -0
- package/dist/workspace/work-cli.d.ts.map +1 -0
- package/dist/workspace/work-evidence.d.ts +74 -0
- package/dist/workspace/work-evidence.d.ts.map +1 -0
- package/dist/workspace/work.d.ts +43 -1
- package/dist/workspace/work.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/cli/commands/audit.test.ts +9 -1
- package/src/cli/commands/build.ts +3 -2
- package/src/cli/commands/lint.ts +7 -1
- package/src/cli/handlers/components.test.ts +93 -0
- package/src/cli/handlers/components.ts +44 -3
- package/src/cli/handlers/graph.test.ts +20 -0
- package/src/cli/handlers/graph.ts +16 -2
- package/src/cli/handlers/operator.ts +141 -4
- package/src/cli/handlers/run.test.ts +173 -2
- package/src/cli/handlers/run.ts +174 -3
- package/src/cli/main.test.ts +50 -0
- package/src/cli/main.ts +97 -2
- package/src/cli/mcp/workspace-tools.test.ts +48 -19
- package/src/cli/mcp/workspace-tools.ts +110 -8
- package/src/cli/plugins.ts +11 -3
- package/src/cli/registry.ts +42 -1
- package/src/codegen/pinned-upgrade.ts +2 -1
- package/src/codegen/release-wiring.test.ts +49 -2
- package/src/components/capability-plugin-loader.ts +3 -3
- package/src/components/cli-support.ts +2 -2
- package/src/components/verbs/vuln-scan.test.ts +124 -1
- package/src/components/verbs/vuln-scan.ts +142 -1
- package/src/config.ts +11 -0
- package/src/lexicon-module.ts +56 -1
- package/src/lexicon-package.test.ts +96 -0
- package/src/lifecycle/converge-ledger.ts +20 -0
- package/src/lifecycle/git.ts +65 -15
- package/src/lifecycle/lease.test.ts +22 -0
- package/src/lifecycle/lease.ts +133 -29
- package/src/lifecycle/member-ledger.ts +3 -2
- package/src/lifecycle/plan-ledger.test.ts +148 -0
- package/src/lifecycle/plan-ledger.ts +158 -0
- package/src/lifecycle/run-ledger.ts +6 -0
- package/src/lifecycle/symptoms.ts +95 -0
- package/src/lifecycle/work-lease.test.ts +236 -0
- package/src/lifecycle/work-lease.ts +426 -0
- package/src/lint/rules/index.ts +6 -2
- package/src/lint/rules/op/index.ts +17 -4
- package/src/lint/rules/op/ops014-converge-rule-refusals.test.ts +23 -1
- package/src/lint/rules/op/ops014-converge-rule-refusals.ts +10 -6
- package/src/lint/rules/op/sys010-key-over-plain-http.test.ts +52 -0
- package/src/lint/rules/op/sys010-key-over-plain-http.ts +100 -0
- package/src/lint/rules/sys001-no-literal-key.test.ts +31 -0
- package/src/lint/rules/sys001-no-literal-key.ts +67 -0
- package/src/op/__fixtures__/decide-stub-backend.ts +143 -0
- package/src/op/activities/activity-contracts.ts +190 -1
- package/src/op/activities/apply.ts +7 -6
- package/src/op/activities/change-coverage.ts +60 -0
- package/src/op/activities/converge.test.ts +55 -1
- package/src/op/activities/converge.ts +208 -29
- package/src/op/activities/decide.live.test.ts +78 -0
- package/src/op/activities/decide.test.ts +300 -0
- package/src/op/activities/decide.ts +267 -0
- package/src/op/activities/index.ts +21 -0
- package/src/op/activities/shell.test.ts +91 -1
- package/src/op/activities/shell.ts +91 -2
- package/src/op/activities/source-release.test.ts +118 -0
- package/src/op/activities/source-release.ts +168 -0
- package/src/op/activities/source-rollback.test.ts +131 -0
- package/src/op/activities/source-rollback.ts +239 -0
- package/src/op/activities/work-evidence.ts +62 -0
- package/src/op/activity-contract-registry.test.ts +2 -0
- package/src/op/activity-contract-registry.ts +2 -2
- package/src/op/activity-contract.test.ts +12 -0
- package/src/op/activity-contract.ts +6 -1
- package/src/op/activity-profiles.ts +29 -0
- package/src/op/activity-registry.test.ts +1 -1
- package/src/op/activity-registry.ts +2 -2
- package/src/op/builders.ts +124 -5
- package/src/op/command-gate.test.ts +192 -0
- package/src/op/composites/converge-op.test.ts +27 -1
- package/src/op/composites/converge-op.ts +69 -15
- package/src/op/decide-backend.test.ts +44 -0
- package/src/op/decide-backend.ts +212 -0
- package/src/op/decide-config.test.ts +52 -0
- package/src/op/decide-config.ts +80 -0
- package/src/op/decide-read-inputs.ts +117 -0
- package/src/op/discover.ts +71 -0
- package/src/op/gate-approval.ts +2 -2
- package/src/op/gate-wait.ts +57 -0
- package/src/op/gate.ts +8 -3
- package/src/op/generate-pipeline.ts +2 -2
- package/src/op/index.ts +34 -6
- package/src/op/lifecycle-receipt-store.test.ts +60 -0
- package/src/op/lifecycle-receipt-store.ts +61 -0
- package/src/op/local-executor.ts +367 -33
- package/src/op/local-output.test.ts +33 -0
- package/src/op/local-output.ts +33 -2
- package/src/op/op-ir.test.ts +10 -0
- package/src/op/op-ir.ts +18 -0
- package/src/op/op-verb-class.ts +1 -0
- package/src/op/operator.ts +360 -10
- package/src/op/runtime.ts +37 -8
- package/src/op/runtimes/local.ts +6 -1
- package/src/op/source-archive.ts +161 -0
- package/src/op/step-output-ref.ts +6 -2
- package/src/op/steward-points.test.ts +313 -0
- package/src/op/steward-points.ts +194 -0
- package/src/op/steward-turn.ts +79 -0
- package/src/op/steward.test.ts +296 -0
- package/src/op/steward.ts +277 -0
- package/src/op/types.ts +60 -0
- package/src/op/work-lease-decl.ts +80 -0
- package/src/op/work-lease-run.test.ts +345 -0
- package/src/op/work-lease-run.ts +395 -0
- package/src/workspace/__fixtures__/decide-workspace.ts +129 -0
- package/src/workspace/__fixtures__/studio-template-84c8b21.json +67 -0
- package/src/workspace/answers-ledger.ts +118 -0
- package/src/workspace/box-isolation.test.ts +261 -0
- package/src/workspace/box-isolation.ts +205 -0
- package/src/workspace/changes-cli.ts +56 -0
- package/src/workspace/changes.schema.json +472 -0
- package/src/workspace/changes.test.ts +315 -0
- package/src/workspace/changes.ts +512 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit-fly-site.ts +234 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit-live-names.ts +164 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit-rollback.ts +223 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit-ship-inputs.ts +195 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit-ship-policy.ts +108 -0
- package/src/workspace/chant-migrations/chud-lexicon-exit.ts +882 -0
- package/src/workspace/chant-migrations.e2e.test.ts +1089 -0
- package/src/workspace/chant-migrations.ts +164 -0
- package/src/workspace/check-contract.test.ts +5 -1
- package/src/workspace/check.schema.json +25 -7
- package/src/workspace/checks/box-isolation.ts +68 -0
- package/src/workspace/checks/boxes.test.ts +276 -0
- package/src/workspace/checks/boxes.ts +442 -0
- package/src/workspace/checks/diagrams.test.ts +134 -0
- package/src/workspace/checks/diagrams.ts +108 -0
- package/src/workspace/checks/records.ts +72 -0
- package/src/workspace/checks.test.ts +7 -0
- package/src/workspace/checks.ts +27 -3
- package/src/workspace/compose-graph.ts +2 -0
- package/src/workspace/conformance/__fixture__/decisions/decision.kind.mjs +10 -0
- package/src/workspace/conformance/__fixture__/decisions/decision.schema.json +26 -0
- package/src/workspace/conformance/index.ts +5 -0
- package/src/workspace/decide.test.ts +224 -0
- package/src/workspace/decide.ts +709 -0
- package/src/workspace/decision-points.schema.json +137 -0
- package/src/workspace/declaration.schema.json +285 -0
- package/src/workspace/declaration.test.ts +58 -0
- package/src/workspace/declaration.ts +241 -0
- package/src/workspace/declared-kinds.test.ts +5 -5
- package/src/workspace/declared-kinds.ts +71 -3
- package/src/workspace/generated-files.ts +14 -0
- package/src/workspace/graph-cli.ts +1 -1
- package/src/workspace/graph.schema.json +9 -1
- package/src/workspace/intent.schema.json +12 -3
- package/src/workspace/intent.ts +3 -10
- package/src/workspace/lineage-check.ts +16 -1
- package/src/workspace/lineage-upgrade-cli.ts +1 -1
- package/src/workspace/lineage-upgrade.test.ts +70 -0
- package/src/workspace/lineage-upgrade.ts +81 -10
- package/src/workspace/ls-contract.test.ts +57 -0
- package/src/workspace/ls.schema.json +46 -1
- package/src/workspace/ls.ts +62 -3
- package/src/workspace/point-answer.schema.json +95 -0
- package/src/workspace/points-cli.ts +284 -0
- package/src/workspace/points-write.schema.json +499 -0
- package/src/workspace/points.schema.json +743 -0
- package/src/workspace/points.test.ts +264 -0
- package/src/workspace/points.ts +564 -0
- package/src/workspace/read-contract.test.ts +18 -1
- package/src/workspace/reason-codes.test.ts +24 -1
- package/src/workspace/reason-codes.ts +49 -0
- package/src/workspace/record-assets.test.ts +3 -2
- package/src/workspace/record-assets.ts +4 -1
- package/src/workspace/records-amend.schema.json +2 -0
- package/src/workspace/records-cli.ts +28 -5
- package/src/workspace/records-close.schema.json +2 -0
- package/src/workspace/records-contract.test.ts +3 -2
- package/src/workspace/records-new.schema.json +2 -0
- package/src/workspace/records-review.schema.json +2 -0
- package/src/workspace/records-sessions-write.e2e.test.ts +77 -0
- package/src/workspace/records-sessions-write.test.ts +2 -34
- package/src/workspace/records-write.e2e.test.ts +108 -0
- package/src/workspace/records-write.test.ts +32 -41
- package/src/workspace/records-write.ts +33 -15
- package/src/workspace/records.schema.json +53 -2
- package/src/workspace/records.test.ts +48 -3
- package/src/workspace/records.ts +142 -6
- package/src/workspace/status-contract.test.ts +189 -6
- package/src/workspace/status-gates.ts +9 -4
- package/src/workspace/status-stewards.ts +329 -0
- package/src/workspace/status.schema.json +335 -5
- package/src/workspace/status.ts +142 -6
- package/src/workspace/work-acceptance.test.ts +274 -0
- package/src/workspace/work-cli.e2e.test.ts +180 -0
- package/src/workspace/work-cli.ts +429 -0
- package/src/workspace/work-evidence.schema.json +212 -0
- package/src/workspace/work-evidence.ts +169 -0
- package/src/workspace/work-history.schema.json +349 -0
- package/src/workspace/work-history.test.ts +156 -0
- package/src/workspace/work-lease.schema.json +233 -0
- package/src/workspace/work-readiness-chud.test.ts +145 -0
- package/src/workspace/work.test.ts +3 -2
- package/src/workspace/work.ts +100 -1
- /package/src/cli/{discovery-skip.test.ts → discovery-skip.e2e.test.ts} +0 -0
- /package/src/workspace/conformance/{conformance.test.ts → conformance.e2e.test.ts} +0 -0
- /package/src/workspace/{which-chant.test.ts → which-chant.e2e.test.ts} +0 -0
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "urn:intentius:chant:point-answer:1",
|
|
4
|
+
"title": "Decision point answer front matter",
|
|
5
|
+
"description": "The front matter of one answer to a decision point (ws-058, #2739), as `chant workspace points ask` and `points answer` write it into the records directory of a record kind with an `answers` block. One record per point, declaration and inputs: its id is the point's name and the first 12 hex digits of the inputs hash, so the same question is answered once. A table's answer is `answered`; a model's answer at or above its threshold is `proposed` until a person confirms it; a question no decider before the quorum answered is `escalated`, open for people. A workspace copies this file next to its answer kind, as reference-workspace/answers/ does. Values stay within what YAML and JSON share. Fields other than these must start with x-.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"patternProperties": { "^x-": {} },
|
|
9
|
+
"required": ["id", "title", "point", "point_version", "question_type", "candidates", "inputs", "inputs_hash", "state", "decider", "asked_on"],
|
|
10
|
+
"properties": {
|
|
11
|
+
"id": { "type": "string", "pattern": "^[a-z][a-z0-9-]*-[0-9a-f]{12}$", "description": "The point's name, a hyphen, and the first 12 hex digits of inputs_hash." },
|
|
12
|
+
"title": { "type": "string", "minLength": 1 },
|
|
13
|
+
"point": { "type": "string", "pattern": "^[a-z][a-z0-9-]*$", "description": "The point in the points file this answers." },
|
|
14
|
+
"point_version": { "$ref": "#/definitions/sha256", "description": "sha256 of the point's declaration when it was asked. Editing the question or any decider changes it." },
|
|
15
|
+
"question_type": { "enum": ["noul", "choice", "score"] },
|
|
16
|
+
"candidates": { "type": "array", "minItems": 2, "items": { "type": ["string", "boolean"] }, "description": "The answers the question allowed: true and false, a choice's options, or a score's levels." },
|
|
17
|
+
"inputs": { "type": "object", "description": "The state the deciders saw, input name to value." },
|
|
18
|
+
"inputs_hash": { "$ref": "#/definitions/sha256", "description": "sha256 of the point, its version and its inputs. The same hash is answered once." },
|
|
19
|
+
"constrains": { "type": "array", "items": { "type": "string", "minLength": 1 }, "description": "What the question is about, such as a work item's id." },
|
|
20
|
+
"state": { "enum": ["escalated", "proposed", "answered"] },
|
|
21
|
+
"answer": { "type": ["string", "boolean"] },
|
|
22
|
+
"decider": {
|
|
23
|
+
"type": "object",
|
|
24
|
+
"required": ["kind"],
|
|
25
|
+
"properties": {
|
|
26
|
+
"kind": { "enum": ["table", "model", "quorum"] },
|
|
27
|
+
"row": { "type": "integer", "minimum": 0, "description": "table: the row that matched." },
|
|
28
|
+
"backend": { "type": "string", "minLength": 1 },
|
|
29
|
+
"model": { "type": "string", "minLength": 1, "description": "model: the model id that answered, as the backend reported it." },
|
|
30
|
+
"count": { "type": "integer", "minimum": 1 },
|
|
31
|
+
"roles": { "type": "array", "items": { "type": "string" } },
|
|
32
|
+
"by": { "type": "array", "items": { "type": "string" }, "description": "quorum: who answered." }
|
|
33
|
+
},
|
|
34
|
+
"additionalProperties": false
|
|
35
|
+
},
|
|
36
|
+
"probabilities": { "$ref": "#/definitions/probabilities" },
|
|
37
|
+
"confidence": { "$ref": "#/definitions/unit" },
|
|
38
|
+
"threshold": { "$ref": "#/definitions/unit" },
|
|
39
|
+
"escalations": {
|
|
40
|
+
"type": "array",
|
|
41
|
+
"description": "The deciders asked before the one that answered, or before the quorum, and why each did not answer.",
|
|
42
|
+
"items": { "$ref": "#/definitions/escalation" }
|
|
43
|
+
},
|
|
44
|
+
"answered_by": { "type": "array", "minItems": 1, "items": { "type": "string", "minLength": 1 }, "description": "The people who answered or confirmed it." },
|
|
45
|
+
"asked_on": { "$ref": "#/definitions/date" },
|
|
46
|
+
"answered_on": { "$ref": "#/definitions/date" },
|
|
47
|
+
"source": {
|
|
48
|
+
"type": "object",
|
|
49
|
+
"description": "Where the answer came from (#2708): via, client and model, the model id that answered when a model decider did."
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"allOf": [
|
|
53
|
+
{
|
|
54
|
+
"if": { "properties": { "state": { "const": "proposed" } }, "required": ["state"] },
|
|
55
|
+
"then": { "required": ["answer"], "properties": { "decider": { "properties": { "kind": { "const": "model" } } } } }
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"if": { "properties": { "state": { "const": "answered" } }, "required": ["state"] },
|
|
59
|
+
"then": { "required": ["answer", "answered_on"] }
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"if": { "properties": { "state": { "const": "escalated" } }, "required": ["state"] },
|
|
63
|
+
"then": { "not": { "required": ["answer"] }, "properties": { "decider": { "properties": { "kind": { "const": "quorum" } } } } }
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"if": { "properties": { "decider": { "properties": { "kind": { "const": "model" } }, "required": ["kind"] } }, "required": ["decider"] },
|
|
67
|
+
"then": { "required": ["probabilities", "confidence", "threshold"], "properties": { "decider": { "required": ["backend", "model"] } } }
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"if": { "properties": { "state": { "const": "answered" }, "decider": { "properties": { "kind": { "const": "quorum" } }, "required": ["kind"] } }, "required": ["state", "decider"] },
|
|
71
|
+
"then": { "required": ["answered_by"], "properties": { "decider": { "required": ["by"] } } }
|
|
72
|
+
}
|
|
73
|
+
],
|
|
74
|
+
"definitions": {
|
|
75
|
+
"sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" },
|
|
76
|
+
"unit": { "type": "number", "minimum": 0, "maximum": 1 },
|
|
77
|
+
"date": { "type": "string", "pattern": "^[0-9]{4}-[0-9]{2}-[0-9]{2}$" },
|
|
78
|
+
"probabilities": { "type": "object", "additionalProperties": { "$ref": "#/definitions/unit" } },
|
|
79
|
+
"escalation": {
|
|
80
|
+
"type": "object",
|
|
81
|
+
"required": ["kind", "reason"],
|
|
82
|
+
"properties": {
|
|
83
|
+
"kind": { "enum": ["table", "model"] },
|
|
84
|
+
"reason": { "type": "string", "minLength": 1 },
|
|
85
|
+
"backend": { "type": "string" },
|
|
86
|
+
"model": { "type": "string" },
|
|
87
|
+
"answer": { "type": ["string", "boolean", "null"] },
|
|
88
|
+
"probabilities": { "$ref": "#/definitions/probabilities" },
|
|
89
|
+
"confidence": { "$ref": "#/definitions/unit" },
|
|
90
|
+
"threshold": { "$ref": "#/definitions/unit" }
|
|
91
|
+
},
|
|
92
|
+
"additionalProperties": false
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `chant workspace points [--open] [--kind <kind file>] [--at <rev>] [--json]`
|
|
3
|
+
* (ws-058, #2739): the workspace's decision points and the questions asked of
|
|
4
|
+
* them, a read-contract output (`points.schema.json`).
|
|
5
|
+
*
|
|
6
|
+
* The points come from each record kind the declaration names with an
|
|
7
|
+
* `answers` block, or from `--kind`, and the questions are that kind's
|
|
8
|
+
* records. A question is open while it is escalated to people or proposed by a
|
|
9
|
+
* model and not yet confirmed, and it lists any model's answer with its
|
|
10
|
+
* confidence, so a reader such as hud can prompt a person and an MCP client
|
|
11
|
+
* can see it. With `--open`, only open questions are listed. It never writes
|
|
12
|
+
* and never calls a model.
|
|
13
|
+
*
|
|
14
|
+
* `points ask` and `points answer` are the writes, in `decide.ts`.
|
|
15
|
+
*/
|
|
16
|
+
import type { CommandContext } from "../cli/registry.js";
|
|
17
|
+
import { type ErrorLocation, type WorkspaceErrorCode } from "./declaration.js";
|
|
18
|
+
import { type QuestionView } from "./decide.js";
|
|
19
|
+
import { type Decider, type ModelAsk } from "./points.js";
|
|
20
|
+
export declare const POINTS_CONTRACT_VERSION = 1;
|
|
21
|
+
export declare const POINTS_OUTPUT_SCHEMA_ID = "https://intentius.io/chant/schemas/workspace/points/v1/points.schema.json";
|
|
22
|
+
/** Why `points` read nothing. Closed. */
|
|
23
|
+
export declare const POINTS_ERROR_CODES: readonly ["declaration-missing", "declaration-ambiguous", "declaration-unparseable", "declaration-invalid", "placement-invalid", "reader-too-old", "root-chant-required", "not-a-git-repository", "revision-unknown"];
|
|
24
|
+
/** Why one answer kind's points or questions could not be read. The document is still printed. Closed. */
|
|
25
|
+
export declare const POINTS_SOURCE_REASON_CODES: readonly ["kind-unreadable", "kind-invalid", "schema-unreadable", "schema-id-mismatch", "schema-invalid", "location-missing", "points-invalid"];
|
|
26
|
+
type SourceReasonCode = (typeof POINTS_SOURCE_REASON_CODES)[number];
|
|
27
|
+
/** One point as `points` lists it. */
|
|
28
|
+
export interface PointView {
|
|
29
|
+
name: string;
|
|
30
|
+
title: string;
|
|
31
|
+
/** The answer kind file, from the workspace root, whose records answer it. */
|
|
32
|
+
kind: string;
|
|
33
|
+
/** The points file, from the repository root. */
|
|
34
|
+
file: string;
|
|
35
|
+
/** sha256 of the declaration: a question asked under another version answers an older question. */
|
|
36
|
+
version: string;
|
|
37
|
+
questionType: string;
|
|
38
|
+
instructions: string;
|
|
39
|
+
candidates: (string | boolean)[];
|
|
40
|
+
/** Each input: its name, the read-contract output it names, and its description. */
|
|
41
|
+
inputs: {
|
|
42
|
+
name: string;
|
|
43
|
+
output: string;
|
|
44
|
+
description: string;
|
|
45
|
+
}[];
|
|
46
|
+
deciders: Decider[];
|
|
47
|
+
quorum: {
|
|
48
|
+
count: number;
|
|
49
|
+
roles?: string[];
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
/** One answer kind the read covered. */
|
|
53
|
+
export interface SourceView {
|
|
54
|
+
/** The kind file, as declared from the workspace root, or as given with --kind. */
|
|
55
|
+
kind: string;
|
|
56
|
+
/** The points file from the repository root, or null when the kind couldn't be loaded. */
|
|
57
|
+
points: string | null;
|
|
58
|
+
reason: {
|
|
59
|
+
code: SourceReasonCode;
|
|
60
|
+
message: string;
|
|
61
|
+
} | null;
|
|
62
|
+
}
|
|
63
|
+
export type PointsDocument = {
|
|
64
|
+
$schema: string;
|
|
65
|
+
contract: number;
|
|
66
|
+
chant: string;
|
|
67
|
+
at: string | null;
|
|
68
|
+
workspace: {
|
|
69
|
+
name: string;
|
|
70
|
+
root: string;
|
|
71
|
+
};
|
|
72
|
+
/** Whether only open questions are listed (--open). */
|
|
73
|
+
open: boolean;
|
|
74
|
+
sources: SourceView[];
|
|
75
|
+
points: PointView[];
|
|
76
|
+
questions: QuestionView[];
|
|
77
|
+
summary: {
|
|
78
|
+
points: number;
|
|
79
|
+
questions: number;
|
|
80
|
+
open: number;
|
|
81
|
+
escalated: number;
|
|
82
|
+
proposed: number;
|
|
83
|
+
answered: number;
|
|
84
|
+
};
|
|
85
|
+
} | {
|
|
86
|
+
$schema: string;
|
|
87
|
+
contract: number;
|
|
88
|
+
chant: string;
|
|
89
|
+
error: {
|
|
90
|
+
code: WorkspaceErrorCode;
|
|
91
|
+
message: string;
|
|
92
|
+
location: ErrorLocation | null;
|
|
93
|
+
};
|
|
94
|
+
};
|
|
95
|
+
export interface PointsQuery {
|
|
96
|
+
cwd: string;
|
|
97
|
+
at?: string;
|
|
98
|
+
open?: boolean;
|
|
99
|
+
/** One answer kind file, in place of the declared ones. */
|
|
100
|
+
kind?: string;
|
|
101
|
+
}
|
|
102
|
+
/** Read the points and questions. Never throws a read error: a declaration that can't be read is the failure document. */
|
|
103
|
+
export declare function workspacePoints(query: PointsQuery): Promise<PointsDocument>;
|
|
104
|
+
/** The document as lines for a person. */
|
|
105
|
+
export declare function formatPoints(doc: Extract<PointsDocument, {
|
|
106
|
+
points: unknown;
|
|
107
|
+
}>): string;
|
|
108
|
+
/** A POST /v1/systemone response the caller already has, as the model call: its answer to the point asked. */
|
|
109
|
+
export declare function responseAsk(response: unknown): ModelAsk;
|
|
110
|
+
/** `chant workspace points`, and its `ask` and `answer` verbs. */
|
|
111
|
+
export declare function runWorkspacePoints(ctx: CommandContext): Promise<number>;
|
|
112
|
+
export {};
|
|
113
|
+
//# sourceMappingURL=points-cli.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"points-cli.d.ts","sourceRoot":"","sources":["../../src/workspace/points-cli.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAA2E,KAAK,aAAa,EAAE,KAAK,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAErJ,OAAO,EAAwH,KAAK,YAAY,EAAE,MAAM,UAAU,CAAC;AACnK,OAAO,EAAoF,KAAK,OAAO,EAAE,KAAK,QAAQ,EAAmB,MAAM,UAAU,CAAC;AAQ1J,eAAO,MAAM,uBAAuB,IAAI,CAAC;AACzC,eAAO,MAAM,uBAAuB,8EAA8E,CAAC;AAEnH,yCAAyC;AACzC,eAAO,MAAM,kBAAkB,uNAUW,CAAC;AAE3C,0GAA0G;AAC1G,eAAO,MAAM,0BAA0B,iJASG,CAAC;AAC3C,KAAK,gBAAgB,GAAG,CAAC,OAAO,0BAA0B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEpE,sCAAsC;AACtC,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,8EAA8E;IAC9E,IAAI,EAAE,MAAM,CAAC;IACb,iDAAiD;IACjD,IAAI,EAAE,MAAM,CAAC;IACb,mGAAmG;IACnG,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,UAAU,EAAE,CAAC,MAAM,GAAG,OAAO,CAAC,EAAE,CAAC;IACjC,oFAAoF;IACpF,MAAM,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAChE,QAAQ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AE,CAAA;CAAE,CAAC;AAE/I,MAAM,WAAW,WAAW;IAC1B,GAAG,EAAE,MAAM,CAAC;IACZ,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,2DAA2D;IAC3D,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED,0HAA0H;AAC1H,wBAAsB,eAAe,CAAC,KAAK,EAAE,WAAW,GAAG,OAAO,CAAC,cAAc,CAAC,CA6EjF;AAED,0CAA0C;AAC1C,wBAAgB,YAAY,CAAC,GAAG,EAAE,OAAO,CAAC,cAAc,EAAE;IAAE,MAAM,EAAE,OAAO,CAAA;CAAE,CAAC,GAAG,MAAM,CAatF;AAED,8GAA8G;AAC9G,wBAAgB,WAAW,CAAC,QAAQ,EAAE,OAAO,GAAG,QAAQ,CASvD;AA0BD,kEAAkE;AAClE,wBAAsB,kBAAkB,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CAsC7E"}
|
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Decision points (ws-058, #2738): the recurring questions a workspace asks of
|
|
3
|
+
* its own graph, declared as data, and the answers they leave (#2739).
|
|
4
|
+
*
|
|
5
|
+
* A points file is JSON, validated against `decision-points.schema.json`, and
|
|
6
|
+
* named by a record kind's `answers.points`: the kind whose records are the
|
|
7
|
+
* answers. Each point is a typed question (`noul`, `choice` or `score`, the
|
|
8
|
+
* question types of the POST /v1/systemone wire format, #2491), the inputs it
|
|
9
|
+
* reads, each named as a read-contract output, and an ordered chain of
|
|
10
|
+
* deciders:
|
|
11
|
+
*
|
|
12
|
+
* table rows of { when, answer }; the first row whose conditions all hold answers.
|
|
13
|
+
* model a backend asked the question with the inputs as its state, at a
|
|
14
|
+
* pinned model id. An answer at or above the threshold is a
|
|
15
|
+
* proposal a person confirms; below it, the next decider is asked.
|
|
16
|
+
* quorum people. Always last: the question escalates to them.
|
|
17
|
+
*
|
|
18
|
+
* chant never calls a model (ws-052). {@link runChain} takes the model call
|
|
19
|
+
* as a function, {@link ModelAsk}, which the decide Op activity (#2740), a
|
|
20
|
+
* runtime's decider or a test's stub supplies. Without one, a model decider is
|
|
21
|
+
* not asked and the chain moves on.
|
|
22
|
+
*
|
|
23
|
+
* Taken from chud's `packages/runtime/src/decide.mjs` at 43afcf1: the chain,
|
|
24
|
+
* the observation rule, the point version and the inputs hash. The records
|
|
25
|
+
* are chant records: `decide.ts` writes them, and {@link applyAnswers} warns
|
|
26
|
+
* about them on read.
|
|
27
|
+
*/
|
|
28
|
+
import type { RecordSource } from "./record-source.js";
|
|
29
|
+
import type { LoadedRecordKind, ReadRecordsOptions, RecordEntry } from "./records.js";
|
|
30
|
+
export declare const DECISION_POINTS_SCHEMA_ID: string;
|
|
31
|
+
/**
|
|
32
|
+
* The read-contract outputs a point's input may name (#2738), each with the
|
|
33
|
+
* output schema and `$defs` entry that describes it. Closed: an input naming
|
|
34
|
+
* anything else is refused. `record`, `decision` and `work-item` are records
|
|
35
|
+
* as `records --json` lists them, of any kind, a decision kind and a work kind.
|
|
36
|
+
*/
|
|
37
|
+
export declare const POINT_INPUT_OUTPUTS: {
|
|
38
|
+
readonly record: {
|
|
39
|
+
readonly schema: "records";
|
|
40
|
+
readonly def: "record";
|
|
41
|
+
readonly description: "a record of any kind, as records --json lists it";
|
|
42
|
+
};
|
|
43
|
+
readonly decision: {
|
|
44
|
+
readonly schema: "records";
|
|
45
|
+
readonly def: "record";
|
|
46
|
+
readonly description: "a decision record, as records --json lists it";
|
|
47
|
+
};
|
|
48
|
+
readonly "work-item": {
|
|
49
|
+
readonly schema: "records";
|
|
50
|
+
readonly def: "record";
|
|
51
|
+
readonly description: "a work item record, as records --json lists it (#2683)";
|
|
52
|
+
};
|
|
53
|
+
readonly finding: {
|
|
54
|
+
readonly schema: "intent";
|
|
55
|
+
readonly def: "finding";
|
|
56
|
+
readonly description: "a finding of graph --intent, or of check --changes (#2794)";
|
|
57
|
+
};
|
|
58
|
+
readonly region: {
|
|
59
|
+
readonly schema: "intent";
|
|
60
|
+
readonly def: "region";
|
|
61
|
+
readonly description: "the region an intent graph covers";
|
|
62
|
+
};
|
|
63
|
+
readonly commit: {
|
|
64
|
+
readonly schema: "intent";
|
|
65
|
+
readonly def: "commit";
|
|
66
|
+
readonly description: "a commit in an intent graph's window";
|
|
67
|
+
};
|
|
68
|
+
readonly member: {
|
|
69
|
+
readonly schema: "ls";
|
|
70
|
+
readonly def: "member";
|
|
71
|
+
readonly description: "a member, as ls lists it";
|
|
72
|
+
};
|
|
73
|
+
readonly gate: {
|
|
74
|
+
readonly schema: "status";
|
|
75
|
+
readonly def: "gate";
|
|
76
|
+
readonly description: "a gate, as status lists it";
|
|
77
|
+
};
|
|
78
|
+
readonly release: {
|
|
79
|
+
readonly schema: "status";
|
|
80
|
+
readonly def: "release";
|
|
81
|
+
readonly description: "a release, as status lists it; a release plan's fields until the lifecycle ledger lists plans (#2717)";
|
|
82
|
+
};
|
|
83
|
+
readonly environment: {
|
|
84
|
+
readonly schema: "status";
|
|
85
|
+
readonly def: "environment";
|
|
86
|
+
readonly description: "an environment, as status lists it";
|
|
87
|
+
};
|
|
88
|
+
readonly component: {
|
|
89
|
+
readonly schema: "composites";
|
|
90
|
+
readonly def: "component";
|
|
91
|
+
readonly description: "a component, as graph --composites lists it";
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
export type PointInputOutput = keyof typeof POINT_INPUT_OUTPUTS;
|
|
95
|
+
export declare const POINT_INPUT_OUTPUT_NAMES: PointInputOutput[];
|
|
96
|
+
/** The output an input name reads: the part before its first dot. */
|
|
97
|
+
export declare function inputOutput(name: string): string;
|
|
98
|
+
export type QuestionType = "noul" | "choice" | "score";
|
|
99
|
+
export interface Question {
|
|
100
|
+
/** `boolean` in a points file is read as `noul`. */
|
|
101
|
+
type: QuestionType;
|
|
102
|
+
instructions: string;
|
|
103
|
+
criteria: Record<string, string> | string[];
|
|
104
|
+
}
|
|
105
|
+
export type Scalar = string | number | boolean | null;
|
|
106
|
+
export type Condition = Scalar | {
|
|
107
|
+
eq?: Scalar;
|
|
108
|
+
ne?: Scalar;
|
|
109
|
+
lt?: number;
|
|
110
|
+
lte?: number;
|
|
111
|
+
gt?: number;
|
|
112
|
+
gte?: number;
|
|
113
|
+
in?: Scalar[];
|
|
114
|
+
};
|
|
115
|
+
export interface TableRow {
|
|
116
|
+
when: Record<string, Condition>;
|
|
117
|
+
answer: string | boolean;
|
|
118
|
+
note?: string;
|
|
119
|
+
}
|
|
120
|
+
export type Decider = {
|
|
121
|
+
kind: "table";
|
|
122
|
+
rows: TableRow[];
|
|
123
|
+
note?: string;
|
|
124
|
+
} | {
|
|
125
|
+
kind: "model";
|
|
126
|
+
backend: string;
|
|
127
|
+
model: string;
|
|
128
|
+
threshold: number;
|
|
129
|
+
unreachable?: "escalate" | "fail";
|
|
130
|
+
note?: string;
|
|
131
|
+
} | {
|
|
132
|
+
kind: "quorum";
|
|
133
|
+
count: number;
|
|
134
|
+
roles?: string[];
|
|
135
|
+
note?: string;
|
|
136
|
+
};
|
|
137
|
+
export interface Point {
|
|
138
|
+
title: string;
|
|
139
|
+
question: Question;
|
|
140
|
+
inputs: Record<string, string>;
|
|
141
|
+
deciders: Decider[];
|
|
142
|
+
}
|
|
143
|
+
/** One problem with a points file: the JSON path of the field, or null for the file, and what is wrong. */
|
|
144
|
+
export interface PointProblem {
|
|
145
|
+
field: string | null;
|
|
146
|
+
message: string;
|
|
147
|
+
}
|
|
148
|
+
export declare class PointsError extends Error {
|
|
149
|
+
readonly file: string;
|
|
150
|
+
readonly problems: PointProblem[];
|
|
151
|
+
constructor(file: string, problems: PointProblem[]);
|
|
152
|
+
}
|
|
153
|
+
/** A question's candidate answers: true and false, a choice's options, or a score's levels. */
|
|
154
|
+
export declare function candidates(question: Question): (string | boolean)[];
|
|
155
|
+
/** The schema's problems with `data`, as JSON paths. */
|
|
156
|
+
export declare function schemaProblems(data: unknown): PointProblem[];
|
|
157
|
+
/**
|
|
158
|
+
* Parse and validate a points file's text. Returns its points, with
|
|
159
|
+
* `boolean` read as `noul`. Throws a {@link PointsError} naming the file and
|
|
160
|
+
* each field.
|
|
161
|
+
*/
|
|
162
|
+
export declare function parsePoints(text: string, file: string): Record<string, Point>;
|
|
163
|
+
/** One point by name, or undefined. */
|
|
164
|
+
export declare function pointOf(points: Record<string, Point>, name: string): Point | undefined;
|
|
165
|
+
/** JSON with keys sorted and undefined members left out, the text every hash here is taken over. */
|
|
166
|
+
export declare function canonical(value: unknown): string;
|
|
167
|
+
/** The version of a point: the sha256 of its declaration. Editing the question or any decider changes it. */
|
|
168
|
+
export declare const pointVersion: (point: Point) => string;
|
|
169
|
+
/** What is answered once: the point, its version and the inputs. */
|
|
170
|
+
export declare const inputsHash: (name: string, version: string, inputs: Record<string, unknown>) => string;
|
|
171
|
+
/** The id of the answer to `name` for inputs hashing to `hash`: the name and the hash's first 12 hex digits. */
|
|
172
|
+
export declare const answerId: (name: string, hash: string) => string;
|
|
173
|
+
/** The quorum a point ends in. */
|
|
174
|
+
export declare function quorumOf(point: Point): {
|
|
175
|
+
count: number;
|
|
176
|
+
roles?: string[];
|
|
177
|
+
};
|
|
178
|
+
/** Whether every condition in a row's `when` holds for these inputs. An input the state lacks never matches. */
|
|
179
|
+
export declare const matches: (when: Record<string, Condition>, inputs: Record<string, unknown>) => boolean;
|
|
180
|
+
/** A question as the POST /v1/systemone wire format asks it (#2491). */
|
|
181
|
+
export interface WireQuestion {
|
|
182
|
+
type: QuestionType;
|
|
183
|
+
instructions: string;
|
|
184
|
+
criteria: Record<string, string> | string[];
|
|
185
|
+
}
|
|
186
|
+
/** One answer in the wire format's shape. */
|
|
187
|
+
export type WireAnswer = {
|
|
188
|
+
type: "noul";
|
|
189
|
+
noul: number;
|
|
190
|
+
} | {
|
|
191
|
+
type: "choice";
|
|
192
|
+
choice: string;
|
|
193
|
+
probabilities?: Record<string, number>;
|
|
194
|
+
confidence?: number;
|
|
195
|
+
} | {
|
|
196
|
+
type: "score";
|
|
197
|
+
score?: number;
|
|
198
|
+
legend?: unknown;
|
|
199
|
+
probabilities?: Record<string, number>;
|
|
200
|
+
confidence?: number;
|
|
201
|
+
} | {
|
|
202
|
+
type: "unsupported";
|
|
203
|
+
};
|
|
204
|
+
export declare function wireQuestion(question: Question): WireQuestion;
|
|
205
|
+
/** What a model decider is asked. */
|
|
206
|
+
export interface ModelRequest {
|
|
207
|
+
point: string;
|
|
208
|
+
backend: string;
|
|
209
|
+
/** The pinned model id. */
|
|
210
|
+
model: string;
|
|
211
|
+
question: WireQuestion;
|
|
212
|
+
/** The inputs, as the state. */
|
|
213
|
+
state: Record<string, unknown>;
|
|
214
|
+
}
|
|
215
|
+
/**
|
|
216
|
+
* The model call, supplied by the caller: the decide Op activity (#2740), a
|
|
217
|
+
* runtime's decider, or a test's stub. It resolves with the model id that
|
|
218
|
+
* answered and one answer in the wire format's shape. Throwing means the
|
|
219
|
+
* backend could not be reached or gave nothing usable.
|
|
220
|
+
*/
|
|
221
|
+
export type ModelAsk = (request: ModelRequest) => Promise<{
|
|
222
|
+
model: string;
|
|
223
|
+
answer: WireAnswer;
|
|
224
|
+
}>;
|
|
225
|
+
export type Observation = {
|
|
226
|
+
observed: true;
|
|
227
|
+
answer: string | boolean;
|
|
228
|
+
probabilities: Record<string, number>;
|
|
229
|
+
confidence: number;
|
|
230
|
+
} | {
|
|
231
|
+
observed: false;
|
|
232
|
+
answer?: string | boolean | null;
|
|
233
|
+
probabilities?: Record<string, number>;
|
|
234
|
+
confidence?: number;
|
|
235
|
+
reason: string;
|
|
236
|
+
};
|
|
237
|
+
/**
|
|
238
|
+
* A model's wire answer against the question and the decider's threshold
|
|
239
|
+
* (chud's rule):
|
|
240
|
+
*
|
|
241
|
+
* - noul p: true when p is at least the threshold, false when 1 - p is,
|
|
242
|
+
* otherwise not observed. Its confidence is max(p, 1 - p).
|
|
243
|
+
* - choice and score: the choice (a score's most probable level) when the
|
|
244
|
+
* reported confidence is at least the threshold. A backend that reports no
|
|
245
|
+
* confidence is read by its largest probability.
|
|
246
|
+
*
|
|
247
|
+
* An answer outside the candidates, or an unsupported question, is not observed.
|
|
248
|
+
*/
|
|
249
|
+
export declare function observe(question: Question, answer: WireAnswer | undefined, threshold: number): Observation;
|
|
250
|
+
/** A decider that was asked and did not answer, and why. */
|
|
251
|
+
export interface Escalation {
|
|
252
|
+
kind: "table" | "model";
|
|
253
|
+
reason: string;
|
|
254
|
+
backend?: string;
|
|
255
|
+
model?: string;
|
|
256
|
+
answer?: string | boolean | null;
|
|
257
|
+
probabilities?: Record<string, number>;
|
|
258
|
+
confidence?: number;
|
|
259
|
+
threshold?: number;
|
|
260
|
+
}
|
|
261
|
+
export type ChainResult = {
|
|
262
|
+
status: "answered";
|
|
263
|
+
answer: string | boolean;
|
|
264
|
+
decider: {
|
|
265
|
+
kind: "table";
|
|
266
|
+
row: number;
|
|
267
|
+
};
|
|
268
|
+
note?: string;
|
|
269
|
+
escalations: Escalation[];
|
|
270
|
+
} | {
|
|
271
|
+
status: "proposed";
|
|
272
|
+
answer: string | boolean;
|
|
273
|
+
decider: {
|
|
274
|
+
kind: "model";
|
|
275
|
+
backend: string;
|
|
276
|
+
model: string;
|
|
277
|
+
};
|
|
278
|
+
probabilities: Record<string, number>;
|
|
279
|
+
confidence: number;
|
|
280
|
+
threshold: number;
|
|
281
|
+
escalations: Escalation[];
|
|
282
|
+
} | {
|
|
283
|
+
status: "escalated";
|
|
284
|
+
decider: {
|
|
285
|
+
kind: "quorum";
|
|
286
|
+
count: number;
|
|
287
|
+
roles?: string[];
|
|
288
|
+
};
|
|
289
|
+
escalations: Escalation[];
|
|
290
|
+
};
|
|
291
|
+
/** A model decider declared `unreachable: "fail"` could not answer, so the ask fails and nothing is written. */
|
|
292
|
+
export declare class DeciderFailed extends Error {
|
|
293
|
+
constructor(message: string);
|
|
294
|
+
}
|
|
295
|
+
/**
|
|
296
|
+
* Ask a point's deciders in order. A table row answers; a model at or above
|
|
297
|
+
* its threshold proposes; otherwise the question escalates to the quorum.
|
|
298
|
+
* Each decider that did not answer is in `escalations`, with why. A model
|
|
299
|
+
* decider is asked through `ask`; without it, it is not asked.
|
|
300
|
+
*/
|
|
301
|
+
export declare function runChain(name: string, point: Point, inputs: Record<string, unknown>, ask?: ModelAsk): Promise<ChainResult>;
|
|
302
|
+
/** Why an answer record carries a warning. Closed, like the record warning codes. */
|
|
303
|
+
export declare const ANSWER_WARNING_CODES: readonly ["answer-points-unreadable", "answer-point-unknown", "answer-point-changed"];
|
|
304
|
+
export type AnswerWarningCode = (typeof ANSWER_WARNING_CODES)[number];
|
|
305
|
+
/** The points file an answer kind names, from `root` with / separators. */
|
|
306
|
+
export declare function pointsFileOf(loaded: LoadedRecordKind, root: string): string;
|
|
307
|
+
/** The points an answer kind names, read from `source` (the tree read), or the problems reading them. */
|
|
308
|
+
export declare function readPointsThrough(source: RecordSource, file: string): {
|
|
309
|
+
points: Record<string, Point>;
|
|
310
|
+
} | {
|
|
311
|
+
error: string;
|
|
312
|
+
problems: PointProblem[];
|
|
313
|
+
};
|
|
314
|
+
/**
|
|
315
|
+
* Give an answer kind's records their warnings, in place: the points file
|
|
316
|
+
* can't be read, the answer's point is gone, or the point changed since. They
|
|
317
|
+
* never make a record invalid.
|
|
318
|
+
*/
|
|
319
|
+
export declare function applyAnswers(loaded: LoadedRecordKind, entries: RecordEntry[], options: ReadRecordsOptions): void;
|
|
320
|
+
//# sourceMappingURL=points.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"points.d.ts","sourceRoot":"","sources":["../../src/workspace/points.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAOH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,KAAK,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAEnF,eAAO,MAAM,yBAA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";
|
|
48
48
|
readonly "gates-no-gate-ledger": "The branch has no gate ledger for the member: no run of it has reached a gate.";
|
|
49
49
|
readonly "gates-ledger-unreadable": "Reading the member's gate ledger failed, so no gate is listed.";
|
|
50
|
+
readonly "stewards-unreadable": "An *.op.ts file could not be imported, so a steward it declares may be missing.";
|
|
51
|
+
readonly "stewards-conflict": "A steward was dropped: its name, or an Op it lists, belongs to another steward.";
|
|
52
|
+
readonly "steward-runs-unreadable": "Reading an Op's run ledger, or a ConvergeOp's converge ledger, failed, so its last run or last tick is null.";
|
|
50
53
|
readonly "record-unparseable": "No front matter, a YAML error or a value outside the JSON subset of YAML, or for a JSON kind a file that is not one object or repeats a member name.";
|
|
51
54
|
readonly "record-schema-invalid": "The record's front matter, or its JSON object, does not match the kind's schema.";
|
|
52
55
|
readonly "record-id-duplicate": "Another record earlier in path order has the same id.";
|
|
53
56
|
readonly "record-supersedes-unknown": "A supersedes link names an id no record has.";
|
|
54
57
|
readonly "record-supersedes-conflict": "A second closed record supersedes a record another one already superseded.";
|
|
58
|
+
readonly "record-remediates-unknown": "A remediates link names an id no record has.";
|
|
59
|
+
readonly "record-remediates-not-closed": "A remediates link names a record that isn't closed; a record still open is amended instead.";
|
|
55
60
|
readonly "session-seal-mismatch": "A closed session's seal is not the digest of its text: the session changed after it closed.";
|
|
56
61
|
readonly "session-verdict-unknown-record": "A session's verdict names a record that none of the session kind's subject records has.";
|
|
57
62
|
readonly "asset-drift": "A file the record pins by hash has changed: its bytes no longer hash to the pinned sha256.";
|
|
@@ -68,6 +73,11 @@ export declare const REASONS: {
|
|
|
68
73
|
readonly "work-done-unpinned": "A work record is done and its evidence list is empty: nothing shows the work was done.";
|
|
69
74
|
readonly "work-closed-without-date": "A work record is done or dropped and has no closing date.";
|
|
70
75
|
readonly "work-done-gap-open": "A work record is done, and the finding it came from still fires on its region. graph --intent raises it, and records does by walking that region.";
|
|
76
|
+
readonly "work-acceptance-unmet": "A work record is done, and one of its acceptance criteria has no passing evidence of the verification it expects. check fails on it (WSP117).";
|
|
77
|
+
readonly "work-acceptance-self-verified": "A passing manual verdict on a work record's criterion names the record's implementer, so it does not count: a manual verdict comes from someone else.";
|
|
78
|
+
readonly "answer-points-unreadable": "The points file the answer kind names can't be read, or is not valid.";
|
|
79
|
+
readonly "answer-point-unknown": "The answer's point is not declared in the points file the answer kind names.";
|
|
80
|
+
readonly "answer-point-changed": "The point's declaration changed since the question was asked, so the answer is to an older version of the question.";
|
|
71
81
|
readonly "review-decider": "The verdict is the decider's own, and the quorum counts verdicts besides the decider's.";
|
|
72
82
|
readonly "review-agent": "The reviewer holds the agent role in the trust policy at base.";
|
|
73
83
|
readonly "review-duplicate": "A later verdict by the same principal replaces this one. Names are compared after NFKC, trimming and lower-casing.";
|
|
@@ -101,6 +111,14 @@ export declare const REASONS: {
|
|
|
101
111
|
readonly "record-sign-failed": "--sign was given and no author seal could be made: the record names no author, the key can't be read or used, git names no ssh signing key, or ssh-keygen is not installed.";
|
|
102
112
|
readonly "session-unknown": "--session names no session of a session kind whose subjects are the record's kind.";
|
|
103
113
|
readonly "session-not-open": "--session names a session in a closed state, which takes no more verdicts.";
|
|
114
|
+
readonly "points-undeclared": "No record kind with an answers block is declared, or given with --kind, so there is no points file to ask.";
|
|
115
|
+
readonly "points-invalid": "The points file an answer kind names can't be read, or does not match decision-points.schema.json and the rules checked in code.";
|
|
116
|
+
readonly "point-unknown": "No points file declares the point asked, or the one an answer names.";
|
|
117
|
+
readonly "point-inputs-invalid": "The inputs given to an ask are not a JSON object of the point's declared inputs.";
|
|
118
|
+
readonly "point-decider-failed": "A model decider that fails closed (unreachable: fail) could not answer, so the ask wrote nothing.";
|
|
119
|
+
readonly "answer-not-candidate": "The people's answer is not one of the question's candidates.";
|
|
120
|
+
readonly "quorum-not-met": "Too few of the people who answered count toward the point's quorum: distinct, not holding the agent role, not the steward that asked, and holding one of its roles when it names any.";
|
|
121
|
+
readonly "answer-in-steward-turn": "The answer was given during a steward's turn, or by a process it started: a steward never answers a decision point, and a person answers it through hud or at a shell.";
|
|
104
122
|
readonly "since-rev-unknown": "--since names no commit, or a session with no opening revision and no commit that added it.";
|
|
105
123
|
readonly "since-session-unknown": "--since has the shape of a session id and names no commit, and no session the kind or the declaration reads has that id.";
|
|
106
124
|
readonly "since-session-open": "--since names a session that is still open, so the comparison runs to the working tree.";
|
|
@@ -124,6 +142,8 @@ export declare const REASONS: {
|
|
|
124
142
|
readonly "intent-decision-unimplemented": "A decided decision constrains the region, no work item that is not dropped implements it, and no commit falls in its window.";
|
|
125
143
|
readonly "intent-work-blocked": "A work item constraining the region has commits in its window while a work item it needs is not done.";
|
|
126
144
|
readonly "intent-work-open-decided-code": "Commits in the region are a decision's own work while the work item implementing that decision is still open.";
|
|
145
|
+
readonly "change-uncovered": "A path the diff changes is covered by no current decided record and no open work item, by path or by its member.";
|
|
146
|
+
readonly "change-out-of-scope": "A record in hand for the change, such as the work item it is for or a decision that item implements, lists a path the diff changes in its out_of_scope.";
|
|
127
147
|
readonly "composites-no-chant-member": "No member of kind chant was read, so nothing declares a composite instance or a component.";
|
|
128
148
|
readonly "composites-none-declared": "The members read declare no composite instance.";
|
|
129
149
|
readonly "composites-no-component": "The members read declare no component, so no composite instance has one.";
|
|
@@ -132,6 +152,24 @@ export declare const REASONS: {
|
|
|
132
152
|
readonly "environments-none-declared": "The member's chant.config.ts declares no environments, so only local and the environments in its ledger are listed.";
|
|
133
153
|
readonly "environments-ledger-undeclared": "The member's ledger has releases in an environment its config's environments don't cover, so chant run --env would refuse it and it is not listed.";
|
|
134
154
|
readonly "environments-ledger-unreadable": "The chant/lifecycle branch exists and the member's ledger environments could not be listed.";
|
|
155
|
+
readonly "diagram-source-missing": "A declared diagram's source file does not exist in the tree read.";
|
|
156
|
+
readonly "diagram-render-missing": "A declared diagram's render file does not exist in the tree read.";
|
|
157
|
+
readonly "diagram-render-drift": "A declared diagram records a sourceHash, and the source's bytes now hash to something else: the render is stale for its source.";
|
|
158
|
+
readonly "box-credential-declared": "A file in a box member's directory carries a literal secret: a credential's shape, or a literal where a credential goes. A variable or secret-manager reference is not one.";
|
|
159
|
+
readonly "box-capability-unbrokered": "A capability in a member's box block names no broker, so the box would hold its credential.";
|
|
160
|
+
readonly "box-fountain-callback-undeclared": "A box member builds a fountain Box, whose persistent sandbox fountain gives a callback token scoped to its owner, and the member's box block does not declare the fountain-callback capability brokered by fountain with scope owner.";
|
|
161
|
+
readonly "work-kind-missing": "No work kind to find the item in: --kind names a kind with no work block, or the declaration names no work kind.";
|
|
162
|
+
readonly "work-kind-ambiguous": "More than one declared work kind has a record with the id, so --kind must name one.";
|
|
163
|
+
readonly "work-item-unknown": "No work record has the id, so there is nothing to lease.";
|
|
164
|
+
readonly "work-item-closed": "A claim on a work item in a closed state, such as done or dropped: there is no work left to claim.";
|
|
165
|
+
readonly "work-criterion-unknown": "The work record lists no acceptance criterion with the id the evidence names, or its kind has no acceptance criteria.";
|
|
166
|
+
readonly "lease-held": "Someone holds a live lease on the work item: another worker, or, for a claim, the same one.";
|
|
167
|
+
readonly "lease-not-held": "Nobody holds a live lease on the work item: it expired, was released or was never claimed.";
|
|
168
|
+
readonly "lease-token-mismatch": "The live lease on the work item carries another fencing token than the one given.";
|
|
169
|
+
readonly "lease-race": "Another writer changed the lease between this command's read and its write.";
|
|
170
|
+
readonly "lease-push-rejected": "The remote refused the lease push: another clone claimed the item first, or the remote could not be reached.";
|
|
171
|
+
readonly "box-isolation-collision": "Two boxes on one host resolve to the same port, state path or cookie name, or two ports in one box share an offset.";
|
|
172
|
+
readonly "box-isolation-literal": "A host's stateRoot or a box's state entry is a literal machine path instead of one derived from an environment reference and the box's name.";
|
|
135
173
|
readonly "lock-invalid": "The lineage lock can't be read.";
|
|
136
174
|
readonly "manual-step-open": "A scope in the lineage lock has an open manual step.";
|
|
137
175
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reason-codes.d.ts","sourceRoot":"","sources":["../../src/workspace/reason-codes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,sHAAsH;AACtH,eAAO,MAAM,qBAAqB,IAAI,CAAC;AAEvC,uHAAuH;AACvH,eAAO,MAAM,mBAAmB,WAAW,CAAC;AAE5C,qFAAqF;AACrF,eAAO,MAAM,OAAO
|
|
1
|
+
{"version":3,"file":"reason-codes.d.ts","sourceRoot":"","sources":["../../src/workspace/reason-codes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,sHAAsH;AACtH,eAAO,MAAM,qBAAqB,IAAI,CAAC;AAEvC,uHAAuH;AACvH,eAAO,MAAM,mBAAmB,WAAW,CAAC;AAE5C,qFAAqF;AACrF,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyLV,CAAC;AAEX,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,OAAO,CAAC;AAE9C,mDAAmD;AACnD,eAAO,MAAM,YAAY,EAA2B,UAAU,EAAE,CAAC;AAEjE,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,UAAU,CAEhE;AAED;;;;;;GAMG;AACH,MAAM,MAAM,UAAU,GAAG,UAAU,MAAM,IAAI,MAAM,EAAE,CAAC;AAEtD,eAAO,MAAM,WAAW,QAAkD,CAAC;AAE3E,2HAA2H;AAC3H,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,MAAM,GAAG,KAAK,IAAI,UAAU,CAI/E"}
|