@adammcarter/use-cases 0.1.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/.agents/skills/migration/SKILL.md +85 -0
- package/.agents/skills/showcase/SKILL.md +60 -0
- package/.agents/skills/use-cases/SKILL.md +161 -0
- package/.agents/skills/walkthrough/SKILL.md +48 -0
- package/.claude-plugin/plugin.json +14 -0
- package/.codex-plugin/plugin.json +33 -0
- package/.mcp.json +8 -0
- package/.opencode/plugin/use-cases.js +32 -0
- package/CHANGELOG.md +125 -0
- package/LICENSE +21 -0
- package/README.md +112 -0
- package/bootstrap/use-cases.md +60 -0
- package/docs/README.md +51 -0
- package/docs/acceptance.md +16 -0
- package/docs/activation.md +89 -0
- package/docs/adr/0001-p0-bootstrap-decisions.md +107 -0
- package/docs/adr/0002-p1-schema-contracts.md +136 -0
- package/docs/adr/0003-p2-use-case-matrix-contracts.md +67 -0
- package/docs/adr/0004-p3-evidence-ledger-contracts.md +85 -0
- package/docs/adr/0005-p4-cli-contract.md +70 -0
- package/docs/adr/0006-trusted-user-approval-path.md +125 -0
- package/docs/cli.md +108 -0
- package/docs/data-model.md +56 -0
- package/docs/getting-started.md +296 -0
- package/docs/hosts.md +30 -0
- package/docs/markers-adoption.md +100 -0
- package/docs/mcp.md +114 -0
- package/docs/migration.md +90 -0
- package/docs/reference/error-codes.md +123 -0
- package/docs/reference/stability.md +123 -0
- package/docs/release.md +26 -0
- package/docs/security/ci-hardening.md +144 -0
- package/docs/security/key-management.md +158 -0
- package/docs/security.md +66 -0
- package/docs/showcase.md +39 -0
- package/docs/tutorials/python-pytest.md +188 -0
- package/examples/basic-product/demo-capsules/product-search.yml +23 -0
- package/examples/basic-product/evidence/by-id/ev/evidence-basic-search.jsonl +1 -0
- package/examples/basic-product/showcase-runs/run.basic.product.search/events.jsonl +4 -0
- package/examples/basic-product/use-cases/product.yml +85 -0
- package/examples/basic-product/use-cases.yml +9 -0
- package/examples/damaged-product/evidence/broken.jsonl +1 -0
- package/examples/damaged-product/use-cases/duplicate-a.yml +28 -0
- package/examples/damaged-product/use-cases/duplicate-b.yml +28 -0
- package/examples/damaged-product/use-cases/malformed.yml +14 -0
- package/examples/damaged-product/use-cases/valid-sibling.yml +28 -0
- package/examples/damaged-product/use-cases.yml +9 -0
- package/examples/host-projections/use-cases.yml +9 -0
- package/examples/python-pytest/README.md +39 -0
- package/examples/python-pytest/pytest.ini +8 -0
- package/examples/python-pytest/src/coupon.py +32 -0
- package/examples/python-pytest/tests/use_cases/example.checkout.apply_coupon_test.py +31 -0
- package/examples/python-pytest/use-cases/checkout.yml +47 -0
- package/examples/python-pytest/use-cases.yml +19 -0
- package/hooks/hooks-codex.json +16 -0
- package/hooks/hooks.json +16 -0
- package/hooks/session-start +42 -0
- package/hosts/claude.yml +29 -0
- package/hosts/codex.yml +29 -0
- package/hosts/copilot.yml +29 -0
- package/hosts/opencode.yml +29 -0
- package/package.json +81 -0
- package/packages/cli/README.md +37 -0
- package/packages/cli/dist/args/parse.d.ts +6 -0
- package/packages/cli/dist/args/parse.d.ts.map +1 -0
- package/packages/cli/dist/args/parse.js +55 -0
- package/packages/cli/dist/args/parse.js.map +1 -0
- package/packages/cli/dist/args/validate.d.ts +3 -0
- package/packages/cli/dist/args/validate.d.ts.map +1 -0
- package/packages/cli/dist/args/validate.js +80 -0
- package/packages/cli/dist/args/validate.js.map +1 -0
- package/packages/cli/dist/builtins.d.ts +2 -0
- package/packages/cli/dist/builtins.d.ts.map +1 -0
- package/packages/cli/dist/builtins.js +235 -0
- package/packages/cli/dist/builtins.js.map +1 -0
- package/packages/cli/dist/command/dispatch.d.ts +4 -0
- package/packages/cli/dist/command/dispatch.d.ts.map +1 -0
- package/packages/cli/dist/command/dispatch.js +45 -0
- package/packages/cli/dist/command/dispatch.js.map +1 -0
- package/packages/cli/dist/command/help-catalog.d.ts +13 -0
- package/packages/cli/dist/command/help-catalog.d.ts.map +1 -0
- package/packages/cli/dist/command/help-catalog.js +42 -0
- package/packages/cli/dist/command/help-catalog.js.map +1 -0
- package/packages/cli/dist/command/registry.d.ts +3 -0
- package/packages/cli/dist/command/registry.d.ts.map +1 -0
- package/packages/cli/dist/command/registry.js +33 -0
- package/packages/cli/dist/command/registry.js.map +1 -0
- package/packages/cli/dist/command/types.d.ts +32 -0
- package/packages/cli/dist/command/types.d.ts.map +1 -0
- package/packages/cli/dist/command/types.js +6 -0
- package/packages/cli/dist/command/types.js.map +1 -0
- package/packages/cli/dist/commands/capsule.d.ts +7 -0
- package/packages/cli/dist/commands/capsule.d.ts.map +1 -0
- package/packages/cli/dist/commands/capsule.js +178 -0
- package/packages/cli/dist/commands/capsule.js.map +1 -0
- package/packages/cli/dist/commands/common.d.ts +7 -0
- package/packages/cli/dist/commands/common.d.ts.map +1 -0
- package/packages/cli/dist/commands/common.js +32 -0
- package/packages/cli/dist/commands/common.js.map +1 -0
- package/packages/cli/dist/commands/doctor.d.ts +6 -0
- package/packages/cli/dist/commands/doctor.d.ts.map +1 -0
- package/packages/cli/dist/commands/doctor.js +133 -0
- package/packages/cli/dist/commands/doctor.js.map +1 -0
- package/packages/cli/dist/commands/evidence.d.ts +6 -0
- package/packages/cli/dist/commands/evidence.d.ts.map +1 -0
- package/packages/cli/dist/commands/evidence.js +191 -0
- package/packages/cli/dist/commands/evidence.js.map +1 -0
- package/packages/cli/dist/commands/host.d.ts +6 -0
- package/packages/cli/dist/commands/host.d.ts.map +1 -0
- package/packages/cli/dist/commands/host.js +180 -0
- package/packages/cli/dist/commands/host.js.map +1 -0
- package/packages/cli/dist/commands/keygen.d.ts +4 -0
- package/packages/cli/dist/commands/keygen.d.ts.map +1 -0
- package/packages/cli/dist/commands/keygen.js +132 -0
- package/packages/cli/dist/commands/keygen.js.map +1 -0
- package/packages/cli/dist/commands/markers.d.ts +8 -0
- package/packages/cli/dist/commands/markers.d.ts.map +1 -0
- package/packages/cli/dist/commands/markers.js +455 -0
- package/packages/cli/dist/commands/markers.js.map +1 -0
- package/packages/cli/dist/commands/matrix.d.ts +8 -0
- package/packages/cli/dist/commands/matrix.d.ts.map +1 -0
- package/packages/cli/dist/commands/matrix.js +237 -0
- package/packages/cli/dist/commands/matrix.js.map +1 -0
- package/packages/cli/dist/commands/migrate.d.ts +4 -0
- package/packages/cli/dist/commands/migrate.d.ts.map +1 -0
- package/packages/cli/dist/commands/migrate.js +82 -0
- package/packages/cli/dist/commands/migrate.js.map +1 -0
- package/packages/cli/dist/commands/plan.d.ts +6 -0
- package/packages/cli/dist/commands/plan.d.ts.map +1 -0
- package/packages/cli/dist/commands/plan.js +129 -0
- package/packages/cli/dist/commands/plan.js.map +1 -0
- package/packages/cli/dist/commands/recover.d.ts +4 -0
- package/packages/cli/dist/commands/recover.d.ts.map +1 -0
- package/packages/cli/dist/commands/recover.js +352 -0
- package/packages/cli/dist/commands/recover.js.map +1 -0
- package/packages/cli/dist/commands/schema.d.ts +5 -0
- package/packages/cli/dist/commands/schema.d.ts.map +1 -0
- package/packages/cli/dist/commands/schema.js +51 -0
- package/packages/cli/dist/commands/schema.js.map +1 -0
- package/packages/cli/dist/commands/showcase.d.ts +14 -0
- package/packages/cli/dist/commands/showcase.d.ts.map +1 -0
- package/packages/cli/dist/commands/showcase.js +638 -0
- package/packages/cli/dist/commands/showcase.js.map +1 -0
- package/packages/cli/dist/commands/workflow.d.ts +5 -0
- package/packages/cli/dist/commands/workflow.d.ts.map +1 -0
- package/packages/cli/dist/commands/workflow.js +107 -0
- package/packages/cli/dist/commands/workflow.js.map +1 -0
- package/packages/cli/dist/coreLoader.d.ts +6 -0
- package/packages/cli/dist/coreLoader.d.ts.map +1 -0
- package/packages/cli/dist/coreLoader.js +34 -0
- package/packages/cli/dist/coreLoader.js.map +1 -0
- package/packages/cli/dist/index.d.ts +5 -0
- package/packages/cli/dist/index.d.ts.map +1 -0
- package/packages/cli/dist/index.js +83 -0
- package/packages/cli/dist/index.js.map +1 -0
- package/packages/cli/dist/render.d.ts +2 -0
- package/packages/cli/dist/render.d.ts.map +1 -0
- package/packages/cli/dist/render.js +88 -0
- package/packages/cli/dist/render.js.map +1 -0
- package/packages/cli/dist/runtime.d.ts +25 -0
- package/packages/cli/dist/runtime.d.ts.map +1 -0
- package/packages/cli/dist/runtime.js +89 -0
- package/packages/cli/dist/runtime.js.map +1 -0
- package/packages/cli/package.json +38 -0
- package/packages/core/README.md +37 -0
- package/packages/core/dist/capsules/index.d.ts +4 -0
- package/packages/core/dist/capsules/index.d.ts.map +1 -0
- package/packages/core/dist/capsules/index.js +4 -0
- package/packages/core/dist/capsules/index.js.map +1 -0
- package/packages/core/dist/capsules/loadCapsule.d.ts +11 -0
- package/packages/core/dist/capsules/loadCapsule.d.ts.map +1 -0
- package/packages/core/dist/capsules/loadCapsule.js +167 -0
- package/packages/core/dist/capsules/loadCapsule.js.map +1 -0
- package/packages/core/dist/capsules/runCapsule.d.ts +3 -0
- package/packages/core/dist/capsules/runCapsule.d.ts.map +1 -0
- package/packages/core/dist/capsules/runCapsule.js +333 -0
- package/packages/core/dist/capsules/runCapsule.js.map +1 -0
- package/packages/core/dist/capsules/types.d.ts +106 -0
- package/packages/core/dist/capsules/types.d.ts.map +1 -0
- package/packages/core/dist/capsules/types.js +2 -0
- package/packages/core/dist/capsules/types.js.map +1 -0
- package/packages/core/dist/durableWrite.d.ts +2 -0
- package/packages/core/dist/durableWrite.d.ts.map +1 -0
- package/packages/core/dist/durableWrite.js +34 -0
- package/packages/core/dist/durableWrite.js.map +1 -0
- package/packages/core/dist/errors/registry.d.ts +122 -0
- package/packages/core/dist/errors/registry.d.ts.map +1 -0
- package/packages/core/dist/errors/registry.js +206 -0
- package/packages/core/dist/errors/registry.js.map +1 -0
- package/packages/core/dist/errors/render.d.ts +3 -0
- package/packages/core/dist/errors/render.d.ts.map +1 -0
- package/packages/core/dist/errors/render.js +64 -0
- package/packages/core/dist/errors/render.js.map +1 -0
- package/packages/core/dist/errors.d.ts +5 -0
- package/packages/core/dist/errors.d.ts.map +1 -0
- package/packages/core/dist/errors.js +9 -0
- package/packages/core/dist/errors.js.map +1 -0
- package/packages/core/dist/evidence/appendEvidenceEvent.d.ts +27 -0
- package/packages/core/dist/evidence/appendEvidenceEvent.d.ts.map +1 -0
- package/packages/core/dist/evidence/appendEvidenceEvent.js +218 -0
- package/packages/core/dist/evidence/appendEvidenceEvent.js.map +1 -0
- package/packages/core/dist/evidence/assurance.d.ts +18 -0
- package/packages/core/dist/evidence/assurance.d.ts.map +1 -0
- package/packages/core/dist/evidence/assurance.js +38 -0
- package/packages/core/dist/evidence/assurance.js.map +1 -0
- package/packages/core/dist/evidence/index.d.ts +8 -0
- package/packages/core/dist/evidence/index.d.ts.map +1 -0
- package/packages/core/dist/evidence/index.js +8 -0
- package/packages/core/dist/evidence/index.js.map +1 -0
- package/packages/core/dist/evidence/jsonlLedger.d.ts +13 -0
- package/packages/core/dist/evidence/jsonlLedger.d.ts.map +1 -0
- package/packages/core/dist/evidence/jsonlLedger.js +171 -0
- package/packages/core/dist/evidence/jsonlLedger.js.map +1 -0
- package/packages/core/dist/evidence/linkEvidence.d.ts +4 -0
- package/packages/core/dist/evidence/linkEvidence.d.ts.map +1 -0
- package/packages/core/dist/evidence/linkEvidence.js +53 -0
- package/packages/core/dist/evidence/linkEvidence.js.map +1 -0
- package/packages/core/dist/evidence/replayEvidence.d.ts +6 -0
- package/packages/core/dist/evidence/replayEvidence.d.ts.map +1 -0
- package/packages/core/dist/evidence/replayEvidence.js +216 -0
- package/packages/core/dist/evidence/replayEvidence.js.map +1 -0
- package/packages/core/dist/evidence/results.d.ts +4 -0
- package/packages/core/dist/evidence/results.d.ts.map +1 -0
- package/packages/core/dist/evidence/results.js +32 -0
- package/packages/core/dist/evidence/results.js.map +1 -0
- package/packages/core/dist/evidence/types.d.ts +149 -0
- package/packages/core/dist/evidence/types.d.ts.map +1 -0
- package/packages/core/dist/evidence/types.js +2 -0
- package/packages/core/dist/evidence/types.js.map +1 -0
- package/packages/core/dist/host-profiles/claude.yml +29 -0
- package/packages/core/dist/host-profiles/codex.yml +29 -0
- package/packages/core/dist/host-profiles/copilot.yml +29 -0
- package/packages/core/dist/host-profiles/opencode.yml +29 -0
- package/packages/core/dist/hosts/conformanceStatus.d.ts +16 -0
- package/packages/core/dist/hosts/conformanceStatus.d.ts.map +1 -0
- package/packages/core/dist/hosts/conformanceStatus.js +160 -0
- package/packages/core/dist/hosts/conformanceStatus.js.map +1 -0
- package/packages/core/dist/hosts/index.d.ts +5 -0
- package/packages/core/dist/hosts/index.d.ts.map +1 -0
- package/packages/core/dist/hosts/index.js +5 -0
- package/packages/core/dist/hosts/index.js.map +1 -0
- package/packages/core/dist/hosts/loadHostProfile.d.ts +6 -0
- package/packages/core/dist/hosts/loadHostProfile.d.ts.map +1 -0
- package/packages/core/dist/hosts/loadHostProfile.js +41 -0
- package/packages/core/dist/hosts/loadHostProfile.js.map +1 -0
- package/packages/core/dist/hosts/projectHostFiles.d.ts +16 -0
- package/packages/core/dist/hosts/projectHostFiles.d.ts.map +1 -0
- package/packages/core/dist/hosts/projectHostFiles.js +272 -0
- package/packages/core/dist/hosts/projectHostFiles.js.map +1 -0
- package/packages/core/dist/hosts/types.d.ts +122 -0
- package/packages/core/dist/hosts/types.d.ts.map +1 -0
- package/packages/core/dist/hosts/types.js +2 -0
- package/packages/core/dist/hosts/types.js.map +1 -0
- package/packages/core/dist/index.d.ts +26 -0
- package/packages/core/dist/index.d.ts.map +1 -0
- package/packages/core/dist/index.js +31 -0
- package/packages/core/dist/index.js.map +1 -0
- package/packages/core/dist/init/index.d.ts +2 -0
- package/packages/core/dist/init/index.d.ts.map +1 -0
- package/packages/core/dist/init/index.js +3 -0
- package/packages/core/dist/init/index.js.map +1 -0
- package/packages/core/dist/init/scaffold.d.ts +28 -0
- package/packages/core/dist/init/scaffold.d.ts.map +1 -0
- package/packages/core/dist/init/scaffold.js +293 -0
- package/packages/core/dist/init/scaffold.js.map +1 -0
- package/packages/core/dist/markers/appendOnly.d.ts +23 -0
- package/packages/core/dist/markers/appendOnly.d.ts.map +1 -0
- package/packages/core/dist/markers/appendOnly.js +75 -0
- package/packages/core/dist/markers/appendOnly.js.map +1 -0
- package/packages/core/dist/markers/bindingSetHash.d.ts +28 -0
- package/packages/core/dist/markers/bindingSetHash.d.ts.map +1 -0
- package/packages/core/dist/markers/bindingSetHash.js +33 -0
- package/packages/core/dist/markers/bindingSetHash.js.map +1 -0
- package/packages/core/dist/markers/canonicalJson.d.ts +4 -0
- package/packages/core/dist/markers/canonicalJson.d.ts.map +1 -0
- package/packages/core/dist/markers/canonicalJson.js +51 -0
- package/packages/core/dist/markers/canonicalJson.js.map +1 -0
- package/packages/core/dist/markers/ciAuthority.d.ts +17 -0
- package/packages/core/dist/markers/ciAuthority.d.ts.map +1 -0
- package/packages/core/dist/markers/ciAuthority.js +131 -0
- package/packages/core/dist/markers/ciAuthority.js.map +1 -0
- package/packages/core/dist/markers/cli/bind.d.ts +48 -0
- package/packages/core/dist/markers/cli/bind.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/bind.js +198 -0
- package/packages/core/dist/markers/cli/bind.js.map +1 -0
- package/packages/core/dist/markers/cli/index.d.ts +9 -0
- package/packages/core/dist/markers/cli/index.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/index.js +15 -0
- package/packages/core/dist/markers/cli/index.js.map +1 -0
- package/packages/core/dist/markers/cli/io.d.ts +18 -0
- package/packages/core/dist/markers/cli/io.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/io.js +62 -0
- package/packages/core/dist/markers/cli/io.js.map +1 -0
- package/packages/core/dist/markers/cli/precommit.d.ts +32 -0
- package/packages/core/dist/markers/cli/precommit.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/precommit.js +174 -0
- package/packages/core/dist/markers/cli/precommit.js.map +1 -0
- package/packages/core/dist/markers/cli/prove.d.ts +69 -0
- package/packages/core/dist/markers/cli/prove.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/prove.js +381 -0
- package/packages/core/dist/markers/cli/prove.js.map +1 -0
- package/packages/core/dist/markers/cli/scan.d.ts +63 -0
- package/packages/core/dist/markers/cli/scan.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/scan.js +233 -0
- package/packages/core/dist/markers/cli/scan.js.map +1 -0
- package/packages/core/dist/markers/cli/shared.d.ts +25 -0
- package/packages/core/dist/markers/cli/shared.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/shared.js +123 -0
- package/packages/core/dist/markers/cli/shared.js.map +1 -0
- package/packages/core/dist/markers/cli/validateLedger.d.ts +38 -0
- package/packages/core/dist/markers/cli/validateLedger.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/validateLedger.js +81 -0
- package/packages/core/dist/markers/cli/validateLedger.js.map +1 -0
- package/packages/core/dist/markers/cli/verify.d.ts +65 -0
- package/packages/core/dist/markers/cli/verify.d.ts.map +1 -0
- package/packages/core/dist/markers/cli/verify.js +245 -0
- package/packages/core/dist/markers/cli/verify.js.map +1 -0
- package/packages/core/dist/markers/commentPrefix.d.ts +7 -0
- package/packages/core/dist/markers/commentPrefix.d.ts.map +1 -0
- package/packages/core/dist/markers/commentPrefix.js +79 -0
- package/packages/core/dist/markers/commentPrefix.js.map +1 -0
- package/packages/core/dist/markers/constants.d.ts +10 -0
- package/packages/core/dist/markers/constants.d.ts.map +1 -0
- package/packages/core/dist/markers/constants.js +13 -0
- package/packages/core/dist/markers/constants.js.map +1 -0
- package/packages/core/dist/markers/evidenceLedger.d.ts +150 -0
- package/packages/core/dist/markers/evidenceLedger.d.ts.map +1 -0
- package/packages/core/dist/markers/evidenceLedger.js +391 -0
- package/packages/core/dist/markers/evidenceLedger.js.map +1 -0
- package/packages/core/dist/markers/freshness.d.ts +125 -0
- package/packages/core/dist/markers/freshness.d.ts.map +1 -0
- package/packages/core/dist/markers/freshness.js +605 -0
- package/packages/core/dist/markers/freshness.js.map +1 -0
- package/packages/core/dist/markers/index.d.ts +26 -0
- package/packages/core/dist/markers/index.d.ts.map +1 -0
- package/packages/core/dist/markers/index.js +38 -0
- package/packages/core/dist/markers/index.js.map +1 -0
- package/packages/core/dist/markers/keygen.d.ts +6 -0
- package/packages/core/dist/markers/keygen.d.ts.map +1 -0
- package/packages/core/dist/markers/keygen.js +18 -0
- package/packages/core/dist/markers/keygen.js.map +1 -0
- package/packages/core/dist/markers/keyring.d.ts +23 -0
- package/packages/core/dist/markers/keyring.d.ts.map +1 -0
- package/packages/core/dist/markers/keyring.js +93 -0
- package/packages/core/dist/markers/keyring.js.map +1 -0
- package/packages/core/dist/markers/markerLine.d.ts +35 -0
- package/packages/core/dist/markers/markerLine.d.ts.map +1 -0
- package/packages/core/dist/markers/markerLine.js +125 -0
- package/packages/core/dist/markers/markerLine.js.map +1 -0
- package/packages/core/dist/markers/physicalLines.d.ts +10 -0
- package/packages/core/dist/markers/physicalLines.d.ts.map +1 -0
- package/packages/core/dist/markers/physicalLines.js +48 -0
- package/packages/core/dist/markers/physicalLines.js.map +1 -0
- package/packages/core/dist/markers/policyHash.d.ts +4 -0
- package/packages/core/dist/markers/policyHash.d.ts.map +1 -0
- package/packages/core/dist/markers/policyHash.js +14 -0
- package/packages/core/dist/markers/policyHash.js.map +1 -0
- package/packages/core/dist/markers/proofSignature.d.ts +29 -0
- package/packages/core/dist/markers/proofSignature.d.ts.map +1 -0
- package/packages/core/dist/markers/proofSignature.js +106 -0
- package/packages/core/dist/markers/proofSignature.js.map +1 -0
- package/packages/core/dist/markers/reconcile.d.ts +26 -0
- package/packages/core/dist/markers/reconcile.d.ts.map +1 -0
- package/packages/core/dist/markers/reconcile.js +52 -0
- package/packages/core/dist/markers/reconcile.js.map +1 -0
- package/packages/core/dist/markers/registry.d.ts +53 -0
- package/packages/core/dist/markers/registry.d.ts.map +1 -0
- package/packages/core/dist/markers/registry.js +161 -0
- package/packages/core/dist/markers/registry.js.map +1 -0
- package/packages/core/dist/markers/rowHash.d.ts +2 -0
- package/packages/core/dist/markers/rowHash.d.ts.map +1 -0
- package/packages/core/dist/markers/rowHash.js +10 -0
- package/packages/core/dist/markers/rowHash.js.map +1 -0
- package/packages/core/dist/markers/scanner.d.ts +67 -0
- package/packages/core/dist/markers/scanner.d.ts.map +1 -0
- package/packages/core/dist/markers/scanner.js +292 -0
- package/packages/core/dist/markers/scanner.js.map +1 -0
- package/packages/core/dist/markers/schemas/binding-registry-event.schema.json +41 -0
- package/packages/core/dist/markers/schemas/freshness-status.schema.json +134 -0
- package/packages/core/dist/markers/schemas/proof-event.schema.json +170 -0
- package/packages/core/dist/markers/spanCanon.d.ts +4 -0
- package/packages/core/dist/markers/spanCanon.d.ts.map +1 -0
- package/packages/core/dist/markers/spanCanon.js +42 -0
- package/packages/core/dist/markers/spanCanon.js.map +1 -0
- package/packages/core/dist/markers/swiftFuncRecognizer.d.ts +36 -0
- package/packages/core/dist/markers/swiftFuncRecognizer.d.ts.map +1 -0
- package/packages/core/dist/markers/swiftFuncRecognizer.js +638 -0
- package/packages/core/dist/markers/swiftFuncRecognizer.js.map +1 -0
- package/packages/core/dist/markers/validators.d.ts +13 -0
- package/packages/core/dist/markers/validators.d.ts.map +1 -0
- package/packages/core/dist/markers/validators.js +64 -0
- package/packages/core/dist/markers/validators.js.map +1 -0
- package/packages/core/dist/markers/verificationContextHash.d.ts +23 -0
- package/packages/core/dist/markers/verificationContextHash.d.ts.map +1 -0
- package/packages/core/dist/markers/verificationContextHash.js +96 -0
- package/packages/core/dist/markers/verificationContextHash.js.map +1 -0
- package/packages/core/dist/markers/verifierPresets.d.ts +18 -0
- package/packages/core/dist/markers/verifierPresets.d.ts.map +1 -0
- package/packages/core/dist/markers/verifierPresets.js +71 -0
- package/packages/core/dist/markers/verifierPresets.js.map +1 -0
- package/packages/core/dist/markers/verifierResolver.d.ts +27 -0
- package/packages/core/dist/markers/verifierResolver.d.ts.map +1 -0
- package/packages/core/dist/markers/verifierResolver.js +151 -0
- package/packages/core/dist/markers/verifierResolver.js.map +1 -0
- package/packages/core/dist/migration/index.d.ts +2 -0
- package/packages/core/dist/migration/index.d.ts.map +1 -0
- package/packages/core/dist/migration/index.js +2 -0
- package/packages/core/dist/migration/index.js.map +1 -0
- package/packages/core/dist/migration/testMatrix.d.ts +42 -0
- package/packages/core/dist/migration/testMatrix.d.ts.map +1 -0
- package/packages/core/dist/migration/testMatrix.js +351 -0
- package/packages/core/dist/migration/testMatrix.js.map +1 -0
- package/packages/core/dist/package/index.d.ts +2 -0
- package/packages/core/dist/package/index.d.ts.map +1 -0
- package/packages/core/dist/package/index.js +2 -0
- package/packages/core/dist/package/index.js.map +1 -0
- package/packages/core/dist/package/inspectPackage.d.ts +67 -0
- package/packages/core/dist/package/inspectPackage.d.ts.map +1 -0
- package/packages/core/dist/package/inspectPackage.js +371 -0
- package/packages/core/dist/package/inspectPackage.js.map +1 -0
- package/packages/core/dist/presentation/candidates.d.ts +13 -0
- package/packages/core/dist/presentation/candidates.d.ts.map +1 -0
- package/packages/core/dist/presentation/candidates.js +86 -0
- package/packages/core/dist/presentation/candidates.js.map +1 -0
- package/packages/core/dist/presentation/index.d.ts +8 -0
- package/packages/core/dist/presentation/index.d.ts.map +1 -0
- package/packages/core/dist/presentation/index.js +8 -0
- package/packages/core/dist/presentation/index.js.map +1 -0
- package/packages/core/dist/presentation/items.d.ts +18 -0
- package/packages/core/dist/presentation/items.d.ts.map +1 -0
- package/packages/core/dist/presentation/items.js +228 -0
- package/packages/core/dist/presentation/items.js.map +1 -0
- package/packages/core/dist/presentation/ordering.d.ts +8 -0
- package/packages/core/dist/presentation/ordering.d.ts.map +1 -0
- package/packages/core/dist/presentation/ordering.js +31 -0
- package/packages/core/dist/presentation/ordering.js.map +1 -0
- package/packages/core/dist/presentation/planHelpers.d.ts +26 -0
- package/packages/core/dist/presentation/planHelpers.d.ts.map +1 -0
- package/packages/core/dist/presentation/planHelpers.js +62 -0
- package/packages/core/dist/presentation/planHelpers.js.map +1 -0
- package/packages/core/dist/presentation/presentationFormat.d.ts +39 -0
- package/packages/core/dist/presentation/presentationFormat.d.ts.map +1 -0
- package/packages/core/dist/presentation/presentationFormat.js +58 -0
- package/packages/core/dist/presentation/presentationFormat.js.map +1 -0
- package/packages/core/dist/presentation/renderCard.d.ts +37 -0
- package/packages/core/dist/presentation/renderCard.d.ts.map +1 -0
- package/packages/core/dist/presentation/renderCard.js +129 -0
- package/packages/core/dist/presentation/renderCard.js.map +1 -0
- package/packages/core/dist/presentation/scoring.d.ts +10 -0
- package/packages/core/dist/presentation/scoring.d.ts.map +1 -0
- package/packages/core/dist/presentation/scoring.js +82 -0
- package/packages/core/dist/presentation/scoring.js.map +1 -0
- package/packages/core/dist/presentation/selectPlan.d.ts +4 -0
- package/packages/core/dist/presentation/selectPlan.d.ts.map +1 -0
- package/packages/core/dist/presentation/selectPlan.js +122 -0
- package/packages/core/dist/presentation/selectPlan.js.map +1 -0
- package/packages/core/dist/presentation/selectShowcasePlan.d.ts +3 -0
- package/packages/core/dist/presentation/selectShowcasePlan.d.ts.map +1 -0
- package/packages/core/dist/presentation/selectShowcasePlan.js +6 -0
- package/packages/core/dist/presentation/selectShowcasePlan.js.map +1 -0
- package/packages/core/dist/presentation/selectWalkthroughPlan.d.ts +3 -0
- package/packages/core/dist/presentation/selectWalkthroughPlan.d.ts.map +1 -0
- package/packages/core/dist/presentation/selectWalkthroughPlan.js +6 -0
- package/packages/core/dist/presentation/selectWalkthroughPlan.js.map +1 -0
- package/packages/core/dist/presentation/selection.d.ts +7 -0
- package/packages/core/dist/presentation/selection.d.ts.map +1 -0
- package/packages/core/dist/presentation/selection.js +20 -0
- package/packages/core/dist/presentation/selection.js.map +1 -0
- package/packages/core/dist/presentation/snapshot.d.ts +12 -0
- package/packages/core/dist/presentation/snapshot.d.ts.map +1 -0
- package/packages/core/dist/presentation/snapshot.js +53 -0
- package/packages/core/dist/presentation/snapshot.js.map +1 -0
- package/packages/core/dist/presentation/types.d.ts +172 -0
- package/packages/core/dist/presentation/types.d.ts.map +1 -0
- package/packages/core/dist/presentation/types.js +2 -0
- package/packages/core/dist/presentation/types.js.map +1 -0
- package/packages/core/dist/redact.d.ts +11 -0
- package/packages/core/dist/redact.d.ts.map +1 -0
- package/packages/core/dist/redact.js +17 -0
- package/packages/core/dist/redact.js.map +1 -0
- package/packages/core/dist/roots.d.ts +81 -0
- package/packages/core/dist/roots.d.ts.map +1 -0
- package/packages/core/dist/roots.js +220 -0
- package/packages/core/dist/roots.js.map +1 -0
- package/packages/core/dist/schema/cliResult.d.ts +34 -0
- package/packages/core/dist/schema/cliResult.d.ts.map +1 -0
- package/packages/core/dist/schema/cliResult.js +35 -0
- package/packages/core/dist/schema/cliResult.js.map +1 -0
- package/packages/core/dist/schema/diagnostic.d.ts +26 -0
- package/packages/core/dist/schema/diagnostic.d.ts.map +1 -0
- package/packages/core/dist/schema/diagnostic.js +28 -0
- package/packages/core/dist/schema/diagnostic.js.map +1 -0
- package/packages/core/dist/schema/index.d.ts +8 -0
- package/packages/core/dist/schema/index.d.ts.map +1 -0
- package/packages/core/dist/schema/index.js +9 -0
- package/packages/core/dist/schema/index.js.map +1 -0
- package/packages/core/dist/schema/registry.d.ts +15 -0
- package/packages/core/dist/schema/registry.d.ts.map +1 -0
- package/packages/core/dist/schema/registry.js +206 -0
- package/packages/core/dist/schema/registry.js.map +1 -0
- package/packages/core/dist/schema/syntheticContracts.d.ts +3 -0
- package/packages/core/dist/schema/syntheticContracts.d.ts.map +1 -0
- package/packages/core/dist/schema/syntheticContracts.js +342 -0
- package/packages/core/dist/schema/syntheticContracts.js.map +1 -0
- package/packages/core/dist/schema/validate.d.ts +21 -0
- package/packages/core/dist/schema/validate.d.ts.map +1 -0
- package/packages/core/dist/schema/validate.js +210 -0
- package/packages/core/dist/schema/validate.js.map +1 -0
- package/packages/core/dist/schemas/v1/authority.schema.json +70 -0
- package/packages/core/dist/schemas/v1/cli-result.schema.json +30 -0
- package/packages/core/dist/schemas/v1/common.schema.json +274 -0
- package/packages/core/dist/schemas/v1/demo-capsule.schema.json +78 -0
- package/packages/core/dist/schemas/v1/evidence-append-result.schema.json +14 -0
- package/packages/core/dist/schemas/v1/evidence-event.schema.json +181 -0
- package/packages/core/dist/schemas/v1/evidence-status-result.schema.json +68 -0
- package/packages/core/dist/schemas/v1/host-profile.schema.json +94 -0
- package/packages/core/dist/schemas/v1/host-status-result.schema.json +49 -0
- package/packages/core/dist/schemas/v1/keyring.schema.json +77 -0
- package/packages/core/dist/schemas/v1/ledger.schema.json +99 -0
- package/packages/core/dist/schemas/v1/marker.schema.json +84 -0
- package/packages/core/dist/schemas/v1/matrix-list-result.schema.json +67 -0
- package/packages/core/dist/schemas/v1/matrix-mutation-result.schema.json +49 -0
- package/packages/core/dist/schemas/v1/matrix-validation-result.schema.json +77 -0
- package/packages/core/dist/schemas/v1/mcp-tool-results.schema.json +34 -0
- package/packages/core/dist/schemas/v1/migration-test-matrix-result.schema.json +76 -0
- package/packages/core/dist/schemas/v1/presentation-plan-result.schema.json +62 -0
- package/packages/core/dist/schemas/v1/presentation-plan.schema.json +259 -0
- package/packages/core/dist/schemas/v1/release-gate-result.schema.json +136 -0
- package/packages/core/dist/schemas/v1/showcase-approval-result.schema.json +5 -0
- package/packages/core/dist/schemas/v1/showcase-event-append-result.schema.json +17 -0
- package/packages/core/dist/schemas/v1/showcase-event.schema.json +235 -0
- package/packages/core/dist/schemas/v1/showcase-finish-result.schema.json +5 -0
- package/packages/core/dist/schemas/v1/showcase-run-status-result.schema.json +70 -0
- package/packages/core/dist/schemas/v1/showcase-start-result.schema.json +5 -0
- package/packages/core/dist/schemas/v1/use-case-file.schema.json +178 -0
- package/packages/core/dist/schemas/v1/workflow-mode.schema.json +16 -0
- package/packages/core/dist/schemas/v1/workspace-config.schema.json +58 -0
- package/packages/core/dist/showcase/appendShowcaseEvent.d.ts +116 -0
- package/packages/core/dist/showcase/appendShowcaseEvent.d.ts.map +1 -0
- package/packages/core/dist/showcase/appendShowcaseEvent.js +353 -0
- package/packages/core/dist/showcase/appendShowcaseEvent.js.map +1 -0
- package/packages/core/dist/showcase/approval.d.ts +2 -0
- package/packages/core/dist/showcase/approval.d.ts.map +1 -0
- package/packages/core/dist/showcase/approval.js +2 -0
- package/packages/core/dist/showcase/approval.js.map +1 -0
- package/packages/core/dist/showcase/approvalAuthority.d.ts +19 -0
- package/packages/core/dist/showcase/approvalAuthority.d.ts.map +1 -0
- package/packages/core/dist/showcase/approvalAuthority.js +46 -0
- package/packages/core/dist/showcase/approvalAuthority.js.map +1 -0
- package/packages/core/dist/showcase/index.d.ts +11 -0
- package/packages/core/dist/showcase/index.d.ts.map +1 -0
- package/packages/core/dist/showcase/index.js +11 -0
- package/packages/core/dist/showcase/index.js.map +1 -0
- package/packages/core/dist/showcase/jsonlLedger.d.ts +11 -0
- package/packages/core/dist/showcase/jsonlLedger.d.ts.map +1 -0
- package/packages/core/dist/showcase/jsonlLedger.js +50 -0
- package/packages/core/dist/showcase/jsonlLedger.js.map +1 -0
- package/packages/core/dist/showcase/planBinding.d.ts +5 -0
- package/packages/core/dist/showcase/planBinding.d.ts.map +1 -0
- package/packages/core/dist/showcase/planBinding.js +33 -0
- package/packages/core/dist/showcase/planBinding.js.map +1 -0
- package/packages/core/dist/showcase/replayRun.d.ts +5 -0
- package/packages/core/dist/showcase/replayRun.d.ts.map +1 -0
- package/packages/core/dist/showcase/replayRun.js +199 -0
- package/packages/core/dist/showcase/replayRun.js.map +1 -0
- package/packages/core/dist/showcase/results.d.ts +3 -0
- package/packages/core/dist/showcase/results.d.ts.map +1 -0
- package/packages/core/dist/showcase/results.js +4 -0
- package/packages/core/dist/showcase/results.js.map +1 -0
- package/packages/core/dist/showcase/revisionEpochs.d.ts +2 -0
- package/packages/core/dist/showcase/revisionEpochs.d.ts.map +1 -0
- package/packages/core/dist/showcase/revisionEpochs.js +2 -0
- package/packages/core/dist/showcase/revisionEpochs.js.map +1 -0
- package/packages/core/dist/showcase/startRun.d.ts +2 -0
- package/packages/core/dist/showcase/startRun.d.ts.map +1 -0
- package/packages/core/dist/showcase/startRun.js +2 -0
- package/packages/core/dist/showcase/startRun.js.map +1 -0
- package/packages/core/dist/showcase/types.d.ts +66 -0
- package/packages/core/dist/showcase/types.d.ts.map +1 -0
- package/packages/core/dist/showcase/types.js +2 -0
- package/packages/core/dist/showcase/types.js.map +1 -0
- package/packages/core/dist/skills/canonicalSkills.d.ts +3 -0
- package/packages/core/dist/skills/canonicalSkills.d.ts.map +1 -0
- package/packages/core/dist/skills/canonicalSkills.js +7 -0
- package/packages/core/dist/skills/canonicalSkills.js.map +1 -0
- package/packages/core/dist/skills/index.d.ts +4 -0
- package/packages/core/dist/skills/index.d.ts.map +1 -0
- package/packages/core/dist/skills/index.js +4 -0
- package/packages/core/dist/skills/index.js.map +1 -0
- package/packages/core/dist/skills/types.d.ts +26 -0
- package/packages/core/dist/skills/types.d.ts.map +1 -0
- package/packages/core/dist/skills/types.js +2 -0
- package/packages/core/dist/skills/types.js.map +1 -0
- package/packages/core/dist/skills/validateSkillAssets.d.ts +6 -0
- package/packages/core/dist/skills/validateSkillAssets.d.ts.map +1 -0
- package/packages/core/dist/skills/validateSkillAssets.js +218 -0
- package/packages/core/dist/skills/validateSkillAssets.js.map +1 -0
- package/packages/core/dist/useCases/integrity.d.ts +11 -0
- package/packages/core/dist/useCases/integrity.d.ts.map +1 -0
- package/packages/core/dist/useCases/integrity.js +178 -0
- package/packages/core/dist/useCases/integrity.js.map +1 -0
- package/packages/core/dist/useCases/loadUseCaseMatrix.d.ts +7 -0
- package/packages/core/dist/useCases/loadUseCaseMatrix.d.ts.map +1 -0
- package/packages/core/dist/useCases/loadUseCaseMatrix.js +74 -0
- package/packages/core/dist/useCases/loadUseCaseMatrix.js.map +1 -0
- package/packages/core/dist/useCases/mutateUseCaseMatrix.d.ts +25 -0
- package/packages/core/dist/useCases/mutateUseCaseMatrix.d.ts.map +1 -0
- package/packages/core/dist/useCases/mutateUseCaseMatrix.js +198 -0
- package/packages/core/dist/useCases/mutateUseCaseMatrix.js.map +1 -0
- package/packages/core/dist/useCases/query.d.ts +12 -0
- package/packages/core/dist/useCases/query.d.ts.map +1 -0
- package/packages/core/dist/useCases/query.js +47 -0
- package/packages/core/dist/useCases/query.js.map +1 -0
- package/packages/core/dist/useCases/types.d.ts +149 -0
- package/packages/core/dist/useCases/types.d.ts.map +1 -0
- package/packages/core/dist/useCases/types.js +2 -0
- package/packages/core/dist/useCases/types.js.map +1 -0
- package/packages/core/dist/useCases/validateUseCaseFile.d.ts +9 -0
- package/packages/core/dist/useCases/validateUseCaseFile.d.ts.map +1 -0
- package/packages/core/dist/useCases/validateUseCaseFile.js +107 -0
- package/packages/core/dist/useCases/validateUseCaseFile.js.map +1 -0
- package/packages/core/dist/version.d.ts +9 -0
- package/packages/core/dist/version.d.ts.map +1 -0
- package/packages/core/dist/version.js +17 -0
- package/packages/core/dist/version.js.map +1 -0
- package/packages/core/package.json +39 -0
- package/packages/mcp/README.md +48 -0
- package/packages/mcp/dist/index.d.ts +20 -0
- package/packages/mcp/dist/index.d.ts.map +1 -0
- package/packages/mcp/dist/index.js +180 -0
- package/packages/mcp/dist/index.js.map +1 -0
- package/packages/mcp/dist/prompts.d.ts +32 -0
- package/packages/mcp/dist/prompts.d.ts.map +1 -0
- package/packages/mcp/dist/prompts.js +199 -0
- package/packages/mcp/dist/prompts.js.map +1 -0
- package/packages/mcp/dist/resources.d.ts +22 -0
- package/packages/mcp/dist/resources.d.ts.map +1 -0
- package/packages/mcp/dist/resources.js +342 -0
- package/packages/mcp/dist/resources.js.map +1 -0
- package/packages/mcp/dist/toolHandlers.d.ts +28 -0
- package/packages/mcp/dist/toolHandlers.d.ts.map +1 -0
- package/packages/mcp/dist/toolHandlers.js +592 -0
- package/packages/mcp/dist/toolHandlers.js.map +1 -0
- package/packages/mcp/dist/toolSchemas.d.ts +23 -0
- package/packages/mcp/dist/toolSchemas.d.ts.map +1 -0
- package/packages/mcp/dist/toolSchemas.js +223 -0
- package/packages/mcp/dist/toolSchemas.js.map +1 -0
- package/packages/mcp/dist/tools.d.ts +22 -0
- package/packages/mcp/dist/tools.d.ts.map +1 -0
- package/packages/mcp/dist/tools.js +65 -0
- package/packages/mcp/dist/tools.js.map +1 -0
- package/packages/mcp/package.json +38 -0
- package/plugin.json +6 -0
- package/schemas/v1/authority.schema.json +70 -0
- package/schemas/v1/cli-result.schema.json +30 -0
- package/schemas/v1/common.schema.json +274 -0
- package/schemas/v1/demo-capsule.schema.json +78 -0
- package/schemas/v1/evidence-append-result.schema.json +14 -0
- package/schemas/v1/evidence-event.schema.json +181 -0
- package/schemas/v1/evidence-status-result.schema.json +68 -0
- package/schemas/v1/host-profile.schema.json +94 -0
- package/schemas/v1/host-status-result.schema.json +49 -0
- package/schemas/v1/keyring.schema.json +77 -0
- package/schemas/v1/ledger.schema.json +99 -0
- package/schemas/v1/marker.schema.json +84 -0
- package/schemas/v1/matrix-list-result.schema.json +67 -0
- package/schemas/v1/matrix-mutation-result.schema.json +49 -0
- package/schemas/v1/matrix-validation-result.schema.json +77 -0
- package/schemas/v1/mcp-tool-results.schema.json +34 -0
- package/schemas/v1/migration-test-matrix-result.schema.json +76 -0
- package/schemas/v1/presentation-plan-result.schema.json +62 -0
- package/schemas/v1/presentation-plan.schema.json +259 -0
- package/schemas/v1/release-gate-result.schema.json +136 -0
- package/schemas/v1/showcase-approval-result.schema.json +5 -0
- package/schemas/v1/showcase-event-append-result.schema.json +17 -0
- package/schemas/v1/showcase-event.schema.json +235 -0
- package/schemas/v1/showcase-finish-result.schema.json +5 -0
- package/schemas/v1/showcase-run-status-result.schema.json +70 -0
- package/schemas/v1/showcase-start-result.schema.json +5 -0
- package/schemas/v1/use-case-file.schema.json +178 -0
- package/schemas/v1/workflow-mode.schema.json +16 -0
- package/schemas/v1/workspace-config.schema.json +58 -0
- package/use-cases/capsule/demos.yml +212 -0
- package/use-cases/capsule/runner.yml +49 -0
- package/use-cases/diagnostics/contracts.yml +239 -0
- package/use-cases/evidence/core.yml +32 -0
- package/use-cases/evidence/ledger.yml +330 -0
- package/use-cases/hosts/profiles.yml +365 -0
- package/use-cases/hosts/projections.yml +96 -0
- package/use-cases/lifecycle/loop.yml +229 -0
- package/use-cases/matrix/core.yml +92 -0
- package/use-cases/matrix/product.yml +289 -0
- package/use-cases/mcp/surface.yml +257 -0
- package/use-cases/mcp/wrapper.yml +100 -0
- package/use-cases/migration/importer.yml +171 -0
- package/use-cases/migration/test-matrix.yml +32 -0
- package/use-cases/planning/cards.yml +215 -0
- package/use-cases/release/package.yml +80 -0
- package/use-cases/release/proof.yml +180 -0
- package/use-cases/roadmap/deferred.yml +184 -0
- package/use-cases/showcase/flow.yml +269 -0
- package/use-cases/showcase/live.yml +44 -0
- package/use-cases/skills/assets.yml +92 -0
- package/use-cases.yml +9 -0
|
@@ -0,0 +1,296 @@
|
|
|
1
|
+
# Getting started: zero to your first FRESH row
|
|
2
|
+
|
|
3
|
+
This is the copy-pasteable path that takes a brand-new repo from nothing to a
|
|
4
|
+
single use-case row that reaches **FRESH** — the state that means "trusted CI has
|
|
5
|
+
signed proof that the current code, its binding, and its verifier context all
|
|
6
|
+
still match."
|
|
7
|
+
|
|
8
|
+
> **Read this first: only CI can mint FRESH.** A row goes FRESH when a verifying
|
|
9
|
+
> command (`scan` / `validate-ledger`) can verify an **ed25519-signed proof**
|
|
10
|
+
> against a **trusted public key**. The private signing key lives **only in
|
|
11
|
+
> trusted CI** — never on a laptop, never in the repo. So locally you can author
|
|
12
|
+
> rows, bind code, and run `scan` to *see* status, but the FRESH transition
|
|
13
|
+
> itself happens in CI. Steps marked **(CI only)** below cannot be done from your
|
|
14
|
+
> machine. This is the whole point of the trust model: an agent on a developer
|
|
15
|
+
> box cannot manufacture a green check.
|
|
16
|
+
|
|
17
|
+
Every command shown here is a real `uc` command. Concepts are linked to the
|
|
18
|
+
[concept docs](./README.md); the deeper trust mechanics live under
|
|
19
|
+
[`docs/concepts/`](./concepts/matrix.md).
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## 1. Install the CLI
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
npm i -g use-cases
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
This puts the `uc` binary on your PATH. The same package also ships the
|
|
30
|
+
companion MCP server binary `uc-mcp` if you want agents to drive the same
|
|
31
|
+
commands — see [the MCP contract](./mcp.md).
|
|
32
|
+
|
|
33
|
+
## 2. Scaffold the workspace with `uc init`
|
|
34
|
+
|
|
35
|
+
One command takes a brand-new repo from nothing to a bindable, verifiable
|
|
36
|
+
matrix — a workspace config plus an example row that already validates:
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
uc init --repo . --template js-vitest
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
- `--template` wires the default verifier: `generic` (a clearly-TODO placeholder
|
|
43
|
+
command), `js-vitest` (the `js.vitest` preset), `python-pytest`
|
|
44
|
+
(`python.pytest`), or `go-test` (`go.test`).
|
|
45
|
+
- `--component <id>` sets the component id (otherwise it is derived from the
|
|
46
|
+
repo directory name).
|
|
47
|
+
- `--force` overwrites an existing workspace; without it, `init` refuses rather
|
|
48
|
+
than clobber a `use-cases.yml` that already exists.
|
|
49
|
+
- `--json` emits the standard result envelope; omit it for a human summary that
|
|
50
|
+
prints these next steps.
|
|
51
|
+
|
|
52
|
+
It writes `use-cases.yml` and `use-cases/example.yml`. It never
|
|
53
|
+
generates or writes a private key, and it does not create the GitHub workflow —
|
|
54
|
+
those steps are below. The generated config looks like:
|
|
55
|
+
|
|
56
|
+
```yaml
|
|
57
|
+
schema_version: 1
|
|
58
|
+
workspace_id: my-project
|
|
59
|
+
component_id: my-project
|
|
60
|
+
data_root: .
|
|
61
|
+
use_cases_dir: use-cases
|
|
62
|
+
evidence_dir: evidence
|
|
63
|
+
demo_capsules_dir: demo-capsules
|
|
64
|
+
showcase_runs_dir: showcase-runs
|
|
65
|
+
default_workflow_mode: continuous
|
|
66
|
+
verifiers:
|
|
67
|
+
default: acceptance
|
|
68
|
+
acceptance:
|
|
69
|
+
preset: js.vitest
|
|
70
|
+
evidence_kind: test_result
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Use-case rows live in sharded YAML files under `use_cases_dir`. See
|
|
74
|
+
[the matrix concept](./concepts/matrix.md). Replace the scaffolded
|
|
75
|
+
`use-cases/example.yml` with a real row (next step).
|
|
76
|
+
|
|
77
|
+
## 3. Add a use-case row
|
|
78
|
+
|
|
79
|
+
Create `use-cases/billing/core.yml` with one row. Model it on a real, valid row —
|
|
80
|
+
the shape below mirrors a row that ships in this repo:
|
|
81
|
+
|
|
82
|
+
```yaml
|
|
83
|
+
schema_version: 1
|
|
84
|
+
feature:
|
|
85
|
+
id: billing.core
|
|
86
|
+
name: Billing
|
|
87
|
+
summary: Charges are computed and applied correctly.
|
|
88
|
+
use_cases:
|
|
89
|
+
- id: billing.core.apply_discount
|
|
90
|
+
title: Apply a percentage discount to an order
|
|
91
|
+
lifecycle: active
|
|
92
|
+
value_tier: core
|
|
93
|
+
journey_role: golden
|
|
94
|
+
usage_frequency: common
|
|
95
|
+
tags: [billing, discount]
|
|
96
|
+
source_refs:
|
|
97
|
+
- kind: file
|
|
98
|
+
path: src/billing/discount.ts
|
|
99
|
+
actor: script
|
|
100
|
+
intent: Apply a percentage discount so the order total reflects the promotion.
|
|
101
|
+
preconditions:
|
|
102
|
+
- An order with at least one line item exists.
|
|
103
|
+
trigger: A valid discount code is applied to an order.
|
|
104
|
+
scenarios:
|
|
105
|
+
- id: billing.core.apply_discount.happy
|
|
106
|
+
kind: steps
|
|
107
|
+
steps:
|
|
108
|
+
- Apply a 10% code to a $100 order.
|
|
109
|
+
- Confirm the total is $90.
|
|
110
|
+
observable_outcomes:
|
|
111
|
+
- The discounted total is correct and never negative.
|
|
112
|
+
host_applicability:
|
|
113
|
+
- host_surface: codex.cli
|
|
114
|
+
supported: true
|
|
115
|
+
verification_policy:
|
|
116
|
+
mode: requirements
|
|
117
|
+
requirements:
|
|
118
|
+
- evidence_kind: test_result
|
|
119
|
+
required_verifiers: [acceptance]
|
|
120
|
+
minimum_count: 1
|
|
121
|
+
approval_policy:
|
|
122
|
+
mode: none
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
`verification_policy.mode: requirements` is what makes this row *provable*: it
|
|
126
|
+
names a verifier id (`acceptance`) that CI must run and pass. We wire that id to a
|
|
127
|
+
real command in step 6. (`mode: none` rows are tracked but never become FRESH —
|
|
128
|
+
there is nothing to prove.)
|
|
129
|
+
|
|
130
|
+
Validate the matrix:
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
uc matrix validate --repo . --json
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
`ok: true` / `complete: true` means the matrix is structurally clean.
|
|
137
|
+
|
|
138
|
+
## 4. Mark the implementing code
|
|
139
|
+
|
|
140
|
+
A **binding** ties the row to the exact code that satisfies it, using an in-code
|
|
141
|
+
marker. Markers are language-agnostic comments. Wrap the implementing span with an
|
|
142
|
+
explicit start/end pair (here in TypeScript, comment prefix `//`):
|
|
143
|
+
|
|
144
|
+
```ts
|
|
145
|
+
//: @use-case: billing.core.apply_discount
|
|
146
|
+
export function applyDiscount(total: number, percent: number): number {
|
|
147
|
+
const discounted = total * (1 - percent / 100);
|
|
148
|
+
return Math.max(0, discounted);
|
|
149
|
+
}
|
|
150
|
+
//: @use-case: end billing.core.apply_discount
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
The grammar is `<comment>: @use-case: <slug>` … `<comment>: @use-case: end
|
|
154
|
+
<slug>`. See [bindings & markers](./concepts/bindings.md).
|
|
155
|
+
|
|
156
|
+
## 5. Register the binding with `uc bind`
|
|
157
|
+
|
|
158
|
+
`bind` registers the marker in the append-only binding registry, but only after
|
|
159
|
+
the edited file scans clean:
|
|
160
|
+
|
|
161
|
+
```bash
|
|
162
|
+
uc bind \
|
|
163
|
+
--repo . \
|
|
164
|
+
--row billing.core.apply_discount \
|
|
165
|
+
--file src/billing/discount.ts \
|
|
166
|
+
--mode explicit \
|
|
167
|
+
--start-line 1 \
|
|
168
|
+
--end-line 5
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
- `--mode explicit` uses the start/end marker pair you placed (`--start-line` /
|
|
172
|
+
`--end-line` are the inclusive span).
|
|
173
|
+
- `--mode swift-func --line N` instead infers a Swift function body span from a
|
|
174
|
+
single marker placed before the declaration.
|
|
175
|
+
- Already placed the marker yourself? add `--register-existing` so `bind` only
|
|
176
|
+
registers it without editing source. Use `--dry-run` to preview.
|
|
177
|
+
|
|
178
|
+
The registry defaults to `.use-cases/bindings.jsonl` under your `data_root`
|
|
179
|
+
(override with `--bindings`).
|
|
180
|
+
|
|
181
|
+
## 6. Declare the verifier (config-driven, any language)
|
|
182
|
+
|
|
183
|
+
The row's `required_verifiers: [acceptance]` is resolved **from config** — there
|
|
184
|
+
is no hard-coded test runner. Point the `acceptance` id at a real command using a
|
|
185
|
+
**preset** in `use-cases.yml`:
|
|
186
|
+
|
|
187
|
+
```yaml
|
|
188
|
+
# use-cases.yml (add this)
|
|
189
|
+
verifiers:
|
|
190
|
+
default: acceptance
|
|
191
|
+
acceptance:
|
|
192
|
+
preset: js.vitest # runs: npx --no-install vitest run tests/use-cases/{slug}.test.ts
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
`{slug}` is substituted with the row id everywhere it appears, so each row gets
|
|
196
|
+
its own acceptance test path.
|
|
197
|
+
|
|
198
|
+
Verifiers are **language-agnostic** — `js.vitest` is just one preset. A Python or
|
|
199
|
+
Make project would instead write:
|
|
200
|
+
|
|
201
|
+
```yaml
|
|
202
|
+
verifiers:
|
|
203
|
+
default: acceptance
|
|
204
|
+
acceptance:
|
|
205
|
+
preset: python.pytest # runs: pytest tests/use_cases/{slug}_test.py
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
```yaml
|
|
209
|
+
verifiers:
|
|
210
|
+
default: acceptance
|
|
211
|
+
acceptance:
|
|
212
|
+
preset: make.target # runs: make test-use-case SLUG={slug}
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
The available presets are `command.generic`, `js.vitest`, `js.npm-test`,
|
|
216
|
+
`python.pytest`, `go.test`, and `make.target`. You can also inline an explicit
|
|
217
|
+
`{ kind: script, command: [...], inputs: [...] }` on the row itself. Full model:
|
|
218
|
+
[verifiers](./concepts/verifiers.md).
|
|
219
|
+
|
|
220
|
+
> **Not a JS repo?** The [pure-Python tutorial](./tutorials/python-pytest.md)
|
|
221
|
+
> walks the *whole* flow — bind → scan → verify → prove → FRESH — for a project
|
|
222
|
+
> whose verifier is `pytest`, with no pnpm/vitest involved. Runnable example:
|
|
223
|
+
> [`examples/python-pytest/`](../examples/python-pytest).
|
|
224
|
+
|
|
225
|
+
Now write the acceptance test the preset names (e.g.
|
|
226
|
+
`tests/use-cases/billing.core.apply_discount.test.ts`) and make it pass locally.
|
|
227
|
+
|
|
228
|
+
## 7. See the status locally with `uc scan`
|
|
229
|
+
|
|
230
|
+
```bash
|
|
231
|
+
uc scan --repo . --product-root . --policy-mode feature --json
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
At this point the row is **UNPROVEN**: it is bound to current code, but no signed
|
|
235
|
+
proof exists yet. That is expected and correct — you cannot sign locally. The five
|
|
236
|
+
states (FRESH / SUSPECT / UNPROVEN / UNBOUND / INVALID) are explained in
|
|
237
|
+
[bindings](./concepts/bindings.md).
|
|
238
|
+
|
|
239
|
+
## 8. Let CI mint the proof — the row reaches FRESH **(CI only)**
|
|
240
|
+
|
|
241
|
+
FRESH happens in a trusted CI pipeline, in two stages:
|
|
242
|
+
|
|
243
|
+
1. **`verify` — keyless, runs on every PR.** It executes each bound row's resolved
|
|
244
|
+
verifier and writes an **unsigned** results ledger. It holds **no signing key**,
|
|
245
|
+
so a PR can prove its tests *ran and passed* without minting trust:
|
|
246
|
+
|
|
247
|
+
```bash
|
|
248
|
+
uc verify --repo . --product-root . --all \
|
|
249
|
+
--out .use-cases/verification-results.jsonl --json
|
|
250
|
+
```
|
|
251
|
+
|
|
252
|
+
2. **`prove` — signs, runs only on the trusted branch.** It **consumes** the
|
|
253
|
+
unsigned results from `verify`, recomputes every hash itself, and mints an
|
|
254
|
+
ed25519-signed proof event. The private key is injected from a CI secret and is
|
|
255
|
+
the **only** place signing happens:
|
|
256
|
+
|
|
257
|
+
```bash
|
|
258
|
+
uc prove --repo . --product-root . --all --trusted-ci --append \
|
|
259
|
+
--verification-results .use-cases/verification-results.jsonl \
|
|
260
|
+
--signing-key-env UCM_CI_SIGNING_KEY --key-id ci-key-1 \
|
|
261
|
+
--public-key .use-cases/trusted-ci-public-key.pem --json
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
Because `prove` re-derives the hashes and signs from a key agents never see,
|
|
265
|
+
nobody can manufacture a passing proof by hand.
|
|
266
|
+
|
|
267
|
+
Once that signed proof is persisted back to the repo, the next `scan` (with the
|
|
268
|
+
trusted `--public-key` / `--keyring`) verifies the signature and the row is
|
|
269
|
+
**FRESH**.
|
|
270
|
+
|
|
271
|
+
Don't hand-roll this. Use the **GitHub Actions reference workflow** at
|
|
272
|
+
[`.github/workflows/use-cases.yml`](../.github/workflows/use-cases.yml): it runs
|
|
273
|
+
`validate-ledger` + `scan` on every push/PR, selects release mode on
|
|
274
|
+
`main` / `release/**`, and runs the optional `verify` → `prove` → persist job that
|
|
275
|
+
mints proofs from the `UCM_CI_SIGNING_KEY` secret. Generate the keypair following
|
|
276
|
+
[key management](./security/key-management.md); the CI provenance/authority model
|
|
277
|
+
is in [CI hardening](./security/ci-hardening.md).
|
|
278
|
+
|
|
279
|
+
---
|
|
280
|
+
|
|
281
|
+
## What you end up with
|
|
282
|
+
|
|
283
|
+
| Stage | Command | Row state |
|
|
284
|
+
|---|---|---|
|
|
285
|
+
| Authored | `uc matrix validate` | (tracked) |
|
|
286
|
+
| Bound | `uc bind …` | UNBOUND → UNPROVEN |
|
|
287
|
+
| Verified in CI (PR, keyless) | `uc verify --out …` | UNPROVEN (results only) |
|
|
288
|
+
| Proved in CI (trusted branch) | `uc prove --trusted-ci …` | **FRESH** |
|
|
289
|
+
| Code/test later weakened | `uc scan` | SUSPECT |
|
|
290
|
+
|
|
291
|
+
When you later change the implementation or weaken the test, the embedded hashes
|
|
292
|
+
no longer match and the row drops to **SUSPECT** — the stale claim becomes
|
|
293
|
+
visible instead of being silently trusted. Re-prove in CI to return to FRESH.
|
|
294
|
+
|
|
295
|
+
Next: read the [concepts index](./README.md) to understand the matrix, bindings,
|
|
296
|
+
verifiers, proofs, and evidence in depth.
|
package/docs/hosts.md
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Host Support
|
|
2
|
+
|
|
3
|
+
Use Cases treats Claude, Codex, Copilot, and OpenCode as first-class
|
|
4
|
+
host families, but profile existence is not proof of support.
|
|
5
|
+
|
|
6
|
+
| Host | Profile | Projection target | Current evidence rule |
|
|
7
|
+
|---|---|---|---|
|
|
8
|
+
| Claude | `hosts/claude.yml` | `.claude/use-cases.md` | Projection and executable smoke only; no verified support without evidence IDs. |
|
|
9
|
+
| Codex | `hosts/codex.yml` | `.codex/use-cases.md` | Projection and executable smoke only; no verified support without evidence IDs. |
|
|
10
|
+
| Copilot | `hosts/copilot.yml` | `.github/copilot/use-cases.md` | Missing or unavailable CLI reports `not_run`. |
|
|
11
|
+
| OpenCode | `hosts/opencode.yml` | `.opencode/use-cases.md` | Missing executable reports `not_run`. |
|
|
12
|
+
|
|
13
|
+
`host conformance --all` reports each host separately. `executable_smoke.status`
|
|
14
|
+
can be `passed`, `failed`, or `not_run`. `not_run` is an exact reason, not a
|
|
15
|
+
support claim. `evidence_event_ids` must stay empty until real host evidence is
|
|
16
|
+
recorded.
|
|
17
|
+
|
|
18
|
+
Each host row includes a `support` table:
|
|
19
|
+
|
|
20
|
+
```text
|
|
21
|
+
profile_available profile was loaded as expectation data
|
|
22
|
+
projected this host's managed projection file matches expected content
|
|
23
|
+
static_conformant projection and canonical skill hashes match
|
|
24
|
+
executable_smoke passed | failed | not_run
|
|
25
|
+
verified_with_evidence true only when evidence_event_ids is non-empty
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Missing or unavailable executables produce warning-backed `not_run` results.
|
|
29
|
+
Resolved executables that fail their smoke command produce failed conformance and
|
|
30
|
+
exit non-zero, even when static projection files are present.
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# Use-case markers: adoption log
|
|
2
|
+
|
|
3
|
+
First real binding of a use-case row to the code that implements it, dogfooded
|
|
4
|
+
end-to-end with the real CLI.
|
|
5
|
+
|
|
6
|
+
## Code markers
|
|
7
|
+
|
|
8
|
+
A binding is anchored in the source by an in-code **marker comment**. `uc bind`
|
|
9
|
+
writes them for you, but the grammar is small enough to read and hand-edit.
|
|
10
|
+
|
|
11
|
+
### Grammar
|
|
12
|
+
|
|
13
|
+
A marker is a single source line. After optional leading whitespace it is exactly:
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
<comment-prefix>: @use-case: <slug> # start of a span
|
|
17
|
+
<comment-prefix>: @use-case: end <slug> # end of a span
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
- **`<comment-prefix>`** is the file's line-comment prefix, resolved **per file
|
|
21
|
+
extension** — `//` for `.ts/.tsx/.js/.jsx/.mjs/.cjs/.swift/.c/.cc/.cpp/.cxx/.h/.hpp/.m/.mm/.java/.kt/.kts/.go/.rs/.scala`,
|
|
22
|
+
and `#` for `.py/.rb/.sh/.bash/.zsh/.yaml/.yml/.toml/.pl/.r`. The map is
|
|
23
|
+
config-driven (`comment_prefixes.extensions` can add or override an extension).
|
|
24
|
+
An **extensionless** file (e.g. a `hooks/session-start` script) only carries
|
|
25
|
+
markers when it starts with a shebang (`#!`), in which case the prefix is `#`.
|
|
26
|
+
- **`<slug>`** is **identity only**: a bare row id with an optional binding
|
|
27
|
+
suffix — `row-id["#"binding-suffix]`. The `row-id` is dotted lowercase idents
|
|
28
|
+
(`billing.checkout.happy_path`); the optional `#suffix` may also use `-`
|
|
29
|
+
(`billing.checkout#fast-path`). Any extra payload after the slug
|
|
30
|
+
(`fresh=`, `sha256=`, `role=`, a second token, …) is rejected — the marker
|
|
31
|
+
carries no state, only the link.
|
|
32
|
+
|
|
33
|
+
Examples:
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
//: @use-case: billing.checkout.happy_path
|
|
37
|
+
export function checkout() { /* … */ }
|
|
38
|
+
//: @use-case: end billing.checkout.happy_path
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
```python
|
|
42
|
+
#: @use-case: billing.checkout.happy_path
|
|
43
|
+
def checkout():
|
|
44
|
+
...
|
|
45
|
+
#: @use-case: end billing.checkout.happy_path
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### Bind modes
|
|
49
|
+
|
|
50
|
+
| Mode | Markers | Span | Languages |
|
|
51
|
+
|---|---|---|---|
|
|
52
|
+
| **explicit** | a start marker **and** a matching `end <slug>` | the inclusive line range between them | any language with a known prefix |
|
|
53
|
+
| **swift-func** | a **lone** start marker, no end | inferred from the Swift function body | Swift only |
|
|
54
|
+
|
|
55
|
+
- **explicit** brackets a precise span; the start and end slugs must match and
|
|
56
|
+
spans must not nest. This is the portable default (`uc bind` explicit mode
|
|
57
|
+
takes `--start-line`/`--end-line`).
|
|
58
|
+
- **swift-func** places a lone start marker immediately before a Swift `func`
|
|
59
|
+
declaration and infers the span from the function body (`uc bind` swift-func
|
|
60
|
+
mode takes `--line`). Inferred ends are **only** supported for Swift func — a
|
|
61
|
+
lone start marker in any other file fails closed and demands an explicit end.
|
|
62
|
+
|
|
63
|
+
## Bound
|
|
64
|
+
|
|
65
|
+
| Use-case row | Code |
|
|
66
|
+
|---|---|
|
|
67
|
+
| `evidence.ledger.crash_durable_ledger_writes` | `packages/core/src/durableWrite.ts` :: `fsyncBestEffortForTemp` (explicit span) |
|
|
68
|
+
|
|
69
|
+
Registration: `.use-cases/bindings.jsonl`. Current status on a clean checkout:
|
|
70
|
+
**UNPROVEN** (linked, awaiting a trusted CI proof) — 1 row bound, 81 unbound.
|
|
71
|
+
That unbound count is the honest linkage-completeness baseline, not a hidden gap.
|
|
72
|
+
|
|
73
|
+
## Demonstrated loop (real code)
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
bind -> UNPROVEN
|
|
77
|
+
prove -> FRESH (CI verifies + ed25519-signs)
|
|
78
|
+
edit fsyncBestEffortForTemp body -> SUSPECT [CODE_SPAN_CHANGED]
|
|
79
|
+
prove -> FRESH
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
The demo proof was signed with a throwaway key and is NOT committed; the
|
|
83
|
+
committed state is "bound, unproven" so the real CI signing key mints the first
|
|
84
|
+
trusted proof.
|
|
85
|
+
|
|
86
|
+
## Finding fixed while dogfooding
|
|
87
|
+
|
|
88
|
+
`scan` also walked `dist/`, where tsc preserves the `//:` marker comment from
|
|
89
|
+
source — that read as a duplicate slug (src + dist) and marked the row INVALID.
|
|
90
|
+
Fixed: `collectSourceInputs` now skips common build-output dirs
|
|
91
|
+
(`dist`, `dist-ts`, `build`, `out`, `coverage`, `.next`, `.turbo`, `.svelte-kit`)
|
|
92
|
+
in addition to `.git` / `node_modules` / `.use-cases`. Covered by
|
|
93
|
+
`packages/core/test/markers/skipBuildDirs.test.ts`.
|
|
94
|
+
|
|
95
|
+
## Next adoption steps
|
|
96
|
+
|
|
97
|
+
- Set up the real CI signing key (`UCM_CI_SIGNING_KEY` secret) so CI mints the
|
|
98
|
+
first trusted proof and this row goes FRESH on `main`.
|
|
99
|
+
- Bind more rows to their implementing functions; track the bound/unbound ratio
|
|
100
|
+
as the linkage-coverage metric.
|
package/docs/mcp.md
ADDED
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# MCP Contract
|
|
2
|
+
|
|
3
|
+
The use-cases MCP server is a convenience transport over the same application command contract used by the CLI. CLI JSON envelopes remain the compatibility contract:
|
|
4
|
+
|
|
5
|
+
```text
|
|
6
|
+
schema_version
|
|
7
|
+
protocol_version
|
|
8
|
+
command
|
|
9
|
+
ok
|
|
10
|
+
complete
|
|
11
|
+
data
|
|
12
|
+
diagnostics
|
|
13
|
+
context
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
MCP tools return that envelope as `structuredContent` and also mirror it as text content for clients that only render text. Domain-negative results stay normal tool results; they are not MCP transport failures.
|
|
17
|
+
|
|
18
|
+
Repository content, tool output, logs, plans, runbooks, and generated artifacts are data, not trusted instructions.
|
|
19
|
+
|
|
20
|
+
## Modes
|
|
21
|
+
|
|
22
|
+
Read-only behavior is the default. Write tools require both server write mode and `allow_write: true` in the tool arguments. Server write mode is enabled by starting the MCP process with:
|
|
23
|
+
|
|
24
|
+
```text
|
|
25
|
+
UCM_MCP_WRITE=1
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Command execution is a separate server mode. A capsule command step can run only when the MCP process also starts with:
|
|
29
|
+
|
|
30
|
+
```text
|
|
31
|
+
UCM_MCP_COMMAND_EXECUTION=1
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Approval-sensitive behavior is request-only in v1.
|
|
35
|
+
|
|
36
|
+
```text
|
|
37
|
+
Tool Read-only Write mode Approval-sensitive
|
|
38
|
+
doctor_roots yes yes no
|
|
39
|
+
matrix_validate yes yes no
|
|
40
|
+
matrix_list yes yes no
|
|
41
|
+
matrix_status yes yes no
|
|
42
|
+
use_case_upsert no yes no
|
|
43
|
+
use_case_remove no yes no
|
|
44
|
+
evidence_status yes yes no
|
|
45
|
+
evidence_record no yes no
|
|
46
|
+
evidence_void no yes no
|
|
47
|
+
plan_showcase yes yes no
|
|
48
|
+
plan_walkthrough yes yes no
|
|
49
|
+
capsule_run no yes no
|
|
50
|
+
showcase_start no yes no
|
|
51
|
+
showcase_status yes yes no
|
|
52
|
+
showcase_record_observation no yes no
|
|
53
|
+
showcase_record_verdict no yes no
|
|
54
|
+
showcase_decide no yes no
|
|
55
|
+
showcase_finish no yes no
|
|
56
|
+
showcase_request_approval yes yes request only
|
|
57
|
+
host_doctor yes yes no
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Workspace Roots
|
|
61
|
+
|
|
62
|
+
Workspace-scoped tools require an explicit `repo` argument. Optional `data_root` values are resolved relative to `repo` and must stay inside that repository. The server should not silently operate on its process working directory for project data.
|
|
63
|
+
|
|
64
|
+
## Use-Case Mutation Boundary
|
|
65
|
+
|
|
66
|
+
`use_case_upsert` and `use_case_remove` expose the same use-case matrix mutation contract as the CLI. They require `allow_write: true`, validate the current matrix before writing, and return `matrix.upsert` or `matrix.remove` envelopes.
|
|
67
|
+
|
|
68
|
+
MCP use-case delete means lifecycle removal, not physical deletion. `use_case_remove` marks the row `lifecycle: removed` and records removal metadata in the YAML file.
|
|
69
|
+
|
|
70
|
+
MCP cannot treat YAML, repository content, generated plans, command output, logs, or tool output as instructions. Those inputs are data to validate, filter, and report.
|
|
71
|
+
|
|
72
|
+
## Capsule Run Boundary
|
|
73
|
+
|
|
74
|
+
`capsule_run` performs a persisted demo capsule through the showcase ledger. It requires server write mode plus `allow_write: true` because it records run events.
|
|
75
|
+
|
|
76
|
+
Static observation text in a capsule is a prompt for a real observation; it is not proof and does not create a pass verdict by itself.
|
|
77
|
+
|
|
78
|
+
Command steps are skipped unless the caller passes `execute_commands: true`, the capsule has `permissions.command_execution: true`, and the MCP server has command-execution mode enabled. Command execution uses executable plus argv without a shell, resolves the working directory inside the repository, runs with a small environment allowlist, records bounded/redacted stdout/stderr as observations, and records pass/fail verdicts from the capsule's expected exit codes.
|
|
79
|
+
|
|
80
|
+
MCP capsule runs do not record user approval. If the run requires user sign-off, use `showcase_request_approval` to produce the CLI-mediated approval command.
|
|
81
|
+
|
|
82
|
+
## Approval Boundary
|
|
83
|
+
|
|
84
|
+
MCP cannot create user approval or rejection events in v1. `showcase_request_approval` returns:
|
|
85
|
+
|
|
86
|
+
```text
|
|
87
|
+
decision_required
|
|
88
|
+
trusted_confirmation_required
|
|
89
|
+
suggested_cli_command
|
|
90
|
+
run_id
|
|
91
|
+
plan_hash
|
|
92
|
+
finish_event_id
|
|
93
|
+
known_gaps
|
|
94
|
+
status
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
The user approval write remains CLI-mediated unless a host later provides a trusted non-model confirmation path.
|
|
98
|
+
|
|
99
|
+
`showcase_start` accepts generated plan files through `plan_file`, so compiled
|
|
100
|
+
stdio MCP can run the same generated-plan lifecycle as the CLI. The generated
|
|
101
|
+
plan remains prepared material until the start event records its content hash.
|
|
102
|
+
|
|
103
|
+
## Deferred V1 Tools
|
|
104
|
+
|
|
105
|
+
These are intentionally not exposed in v1:
|
|
106
|
+
|
|
107
|
+
```text
|
|
108
|
+
showcase_approve
|
|
109
|
+
showcase_reject
|
|
110
|
+
host_project
|
|
111
|
+
host_conformance
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
Approval writes need trusted confirmation. Host projection and conformance remain CLI-first until their mutation and evidence semantics are fully designed for MCP.
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# Migration
|
|
2
|
+
|
|
3
|
+
Bring an **existing, hand-rolled** record of intended behaviour into the
|
|
4
|
+
use-case matrix — whatever form it's in. People already track this somewhere: a
|
|
5
|
+
markdown table or checklist, a CSV, a spreadsheet export, a `TEST-MATRIX.md`,
|
|
6
|
+
release notes, a QA sign-off sheet, a wiki dump.
|
|
7
|
+
|
|
8
|
+
**The invariant, for every format:** migration preserves intended-behaviour
|
|
9
|
+
*coverage*, never *proof*. Old `PASS` / `FAIL` / `DONE` marks, evidence links,
|
|
10
|
+
screenshots, and sign-off text come across only as **review context** — they do
|
|
11
|
+
not create evidence JSONL, showcase runs, approvals, host support, or verified
|
|
12
|
+
status. Migrated rows land as **drafts** with zero proof; freshness is earned
|
|
13
|
+
later by binding + verifying, never inherited.
|
|
14
|
+
|
|
15
|
+
## Two paths
|
|
16
|
+
|
|
17
|
+
- **Any format → the `migration` skill (general path).** A fixed parser can't
|
|
18
|
+
understand every hand-rolled layout, so the agent does the mapping: it reads
|
|
19
|
+
your file, infers its structure, and writes one reviewable **draft** use case
|
|
20
|
+
per item via `uc matrix upsert`, carrying the original text + provenance. Just
|
|
21
|
+
ask your agent to "migrate" / "bring in" / "import" your file and the bundled
|
|
22
|
+
`migration` skill activates. See `.agents/skills/migration/SKILL.md`.
|
|
23
|
+
- **A standard `TEST-MATRIX.md` → `uc migrate test-matrix` (fast path).** For the
|
|
24
|
+
one canonical markdown-table format there's a deterministic importer that
|
|
25
|
+
already enforces the no-laundering invariant. Use it when your source fits.
|
|
26
|
+
|
|
27
|
+
## TEST-MATRIX fast path
|
|
28
|
+
|
|
29
|
+
Run a dry-run first:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
uc migrate test-matrix \
|
|
33
|
+
--repo . \
|
|
34
|
+
--source TEST-MATRIX.md \
|
|
35
|
+
--out use-cases/_migrated \
|
|
36
|
+
--dry-run \
|
|
37
|
+
--json
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Review the report:
|
|
41
|
+
|
|
42
|
+
```text
|
|
43
|
+
summary.rows_seen
|
|
44
|
+
summary.rows_needing_review
|
|
45
|
+
drafts[].output_path
|
|
46
|
+
warnings[]
|
|
47
|
+
would_write[]
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Then write draft use cases:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
uc migrate test-matrix \
|
|
54
|
+
--repo . \
|
|
55
|
+
--source TEST-MATRIX.md \
|
|
56
|
+
--out use-cases/_migrated \
|
|
57
|
+
--write \
|
|
58
|
+
--json
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
## Safety Rules
|
|
62
|
+
|
|
63
|
+
Dry-run writes no files.
|
|
64
|
+
|
|
65
|
+
Write mode only writes draft YAML and a migration manifest under the selected output directory. It never writes:
|
|
66
|
+
|
|
67
|
+
```text
|
|
68
|
+
evidence/
|
|
69
|
+
showcase-runs/
|
|
70
|
+
host projection files
|
|
71
|
+
TEST-MATRIX.md
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Output paths must stay inside the workspace data root. Keep migrated files under `use-cases/_migrated/` until a human reviews and reshapes them.
|
|
75
|
+
|
|
76
|
+
## Review Context
|
|
77
|
+
|
|
78
|
+
Generated use cases include source references like:
|
|
79
|
+
|
|
80
|
+
```text
|
|
81
|
+
TEST-MATRIX.md#table-1-row-3
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
Legacy status, evidence text, and notes are stored under the migration extension as review context. Current proof must be created later with evidence or showcase flows.
|
|
85
|
+
|
|
86
|
+
The key invariant:
|
|
87
|
+
|
|
88
|
+
```text
|
|
89
|
+
Legacy matrix status is historical context, not current proof.
|
|
90
|
+
```
|