create-agdf 0.14.5 → 0.20.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/LICENSE +201 -0
- package/README.md +474 -11
- package/bin/create-agdf.js +2 -1
- package/generated/.agdf/control/README.md +29 -2
- package/generated/.agdf/control/templates/MASTER_BACKLOG.md +4 -2
- package/generated/.agdf/control/templates/RUN_STATE.md +1 -0
- package/generated/.agdf/control/templates/artefacts/BROWNFIELD_REVIEW.md +31 -0
- package/generated/.agdf/control/templates/artefacts/PRD.md +44 -5
- package/generated/.agdf/control/templates/artefacts/QA_REPORT.md +6 -0
- package/generated/.agdf/control/templates/artefacts/SD.md +31 -3
- package/generated/.agdf/control/templates/artefacts/TP.md +43 -8
- package/generated/.agdf/control/templates/artefacts/UR.md +17 -0
- package/generated/.agdf/control/templates/artefacts/UX_INTENT_DEFINITION.md +10 -0
- package/generated/.opencode/AGDF.md +17 -121
- package/generated/.opencode/README.md +7 -2
- package/generated/.opencode/agdf-agent-router.md +174 -0
- package/generated/.opencode/agdf-interaction-locales.json +2682 -495
- package/generated/.opencode/agdf-runtime-contract.md +17 -9
- package/generated/.opencode/contracts/closeout.md +7 -3
- package/generated/.opencode/contracts/control-scaffold.md +19 -6
- package/generated/.opencode/contracts/gate-artifact-preparation.md +132 -0
- package/generated/.opencode/contracts/gate-transition.md +56 -12
- package/generated/.opencode/contracts/interaction.md +331 -41
- package/generated/.opencode/contracts/modes.md +23 -11
- package/generated/.opencode/contracts/prd-definition.md +130 -0
- package/generated/.opencode/contracts/quality.md +85 -14
- package/generated/.opencode/contracts/request-activation.md +252 -0
- package/generated/.opencode/contracts/sd-definition.md +69 -0
- package/generated/.opencode/contracts/task-target-resolution.md +63 -9
- package/generated/.opencode/contracts/tp-definition.md +81 -0
- package/generated/.opencode/contracts/ur-definition.md +94 -0
- package/generated/.opencode/skills/agdf-brownfield-analysis/SKILL.md +70 -8
- package/generated/.opencode/skills/agdf-clean-implementation-review/SKILL.md +35 -3
- package/generated/.opencode/skills/agdf-code-review/SKILL.md +36 -2
- package/generated/.opencode/skills/agdf-delivery-closeout/SKILL.md +36 -4
- package/generated/.opencode/skills/agdf-delivery-path-search/SKILL.md +36 -4
- package/generated/.opencode/skills/agdf-gate-check/SKILL.md +68 -222
- package/generated/.opencode/skills/agdf-prd-definition/SKILL.md +51 -0
- package/generated/.opencode/skills/agdf-qa-gate/SKILL.md +78 -10
- package/generated/.opencode/skills/agdf-release-or/SKILL.md +44 -11
- package/generated/.opencode/skills/agdf-sd-definition/SKILL.md +51 -0
- package/generated/.opencode/skills/agdf-task-plan-review/SKILL.md +35 -3
- package/generated/.opencode/skills/agdf-tp-definition/SKILL.md +51 -0
- package/generated/.opencode/skills/agdf-ur-definition/SKILL.md +54 -0
- package/generated/.opencode/skills/agdf-ux-intent-definition/SKILL.md +100 -6
- package/generated/plugins/agdf/.claude-plugin/plugin.json +3 -2
- package/generated/plugins/agdf/.codex-plugin/plugin.json +3 -1
- package/generated/plugins/agdf/control/README.md +29 -2
- package/generated/plugins/agdf/control/templates/MASTER_BACKLOG.md +4 -2
- package/generated/plugins/agdf/control/templates/RUN_STATE.md +1 -0
- package/generated/plugins/agdf/control/templates/artefacts/BROWNFIELD_REVIEW.md +31 -0
- package/generated/plugins/agdf/control/templates/artefacts/PRD.md +44 -5
- package/generated/plugins/agdf/control/templates/artefacts/QA_REPORT.md +6 -0
- package/generated/plugins/agdf/control/templates/artefacts/SD.md +31 -3
- package/generated/plugins/agdf/control/templates/artefacts/TP.md +43 -8
- package/generated/plugins/agdf/control/templates/artefacts/UR.md +17 -0
- package/generated/plugins/agdf/control/templates/artefacts/UX_INTENT_DEFINITION.md +10 -0
- package/generated/plugins/agdf/hooks/hooks.json +2 -2
- package/generated/plugins/agdf/hooks/session-start.sh +5 -70
- package/generated/plugins/agdf/mcp/agdf-mcp-launch.js +7 -0
- package/generated/plugins/agdf/mcp/claude.mcp.json +11 -0
- package/generated/plugins/agdf/mcp/sdk/expected-sdk.json +21 -0
- package/generated/plugins/agdf/mcp/sdk/package-lock.json +47 -0
- package/generated/plugins/agdf/mcp/sdk/package.json +7 -0
- package/generated/plugins/agdf/mcp/server/NOTICE +10 -0
- package/generated/plugins/agdf/mcp/server/README.md +136 -0
- package/generated/plugins/agdf/mcp/server/bin/agdf-mcp.js +24 -0
- package/generated/plugins/agdf/mcp/server/package.json +59 -0
- package/generated/plugins/agdf/mcp/server/src/cockpit-resource.js +20 -0
- package/generated/plugins/agdf/mcp/server/src/generation-entry.js +86 -0
- package/generated/plugins/agdf/mcp/server/src/generation-protocol.js +44 -0
- package/generated/plugins/agdf/mcp/server/src/generation.js +211 -0
- package/generated/plugins/agdf/mcp/server/src/main.js +56 -0
- package/generated/plugins/agdf/mcp/server/src/server.js +187 -0
- package/generated/plugins/agdf/mcp/server/src/ui-capability.js +17 -0
- package/generated/plugins/agdf/mcp/server/src/worker-entry.js +39 -0
- package/generated/plugins/agdf/mcp/server/src/worker.js +134 -0
- package/generated/plugins/agdf/mcp/server/ui/cockpit.html +109 -0
- package/generated/plugins/agdf/mcp/server/ui/decision-manifest.json +8 -0
- package/generated/plugins/agdf/mcp/server/ui/decision.html +108 -0
- package/generated/plugins/agdf/mcp/server/ui/manifest.json +8 -0
- package/generated/plugins/agdf/mcp.json +28 -0
- package/generated/plugins/agdf/meta/agdf-agent-router.md +50 -8
- package/generated/plugins/agdf/meta/agdf-interaction-locales.json +2682 -495
- package/generated/plugins/agdf/meta/agdf-mcp-capability.json +158 -0
- package/generated/plugins/agdf/meta/agdf-plugin.definition.json +288 -42
- package/generated/plugins/agdf/meta/agdf-runtime-contract.md +17 -9
- package/generated/plugins/agdf/meta/contracts/closeout.md +6 -2
- package/generated/plugins/agdf/meta/contracts/control-scaffold.md +17 -4
- package/generated/plugins/agdf/meta/contracts/gate-artifact-preparation.md +132 -0
- package/generated/plugins/agdf/meta/contracts/gate-transition.md +48 -4
- package/generated/plugins/agdf/meta/contracts/interaction.md +328 -38
- package/generated/plugins/agdf/meta/contracts/modes.md +23 -11
- package/generated/plugins/agdf/meta/contracts/prd-definition.md +130 -0
- package/generated/plugins/agdf/meta/contracts/quality.md +77 -6
- package/generated/plugins/agdf/meta/contracts/request-activation.md +252 -0
- package/generated/plugins/agdf/meta/contracts/sd-definition.md +69 -0
- package/generated/plugins/agdf/meta/contracts/task-target-resolution.md +63 -9
- package/generated/plugins/agdf/meta/contracts/tp-definition.md +81 -0
- package/generated/plugins/agdf/meta/contracts/ur-definition.md +94 -0
- package/generated/plugins/agdf/meta/copilot-payload-baseline.json +3 -3
- package/generated/plugins/agdf/meta/distribution-profile-history.json +7 -0
- package/generated/plugins/agdf/meta/schemas/agent-plugins/1.0.0/mcp.schema.json +120 -0
- package/generated/plugins/agdf/meta/schemas/agent-plugins/1.0.0/plugin.schema.json +65 -0
- package/generated/plugins/agdf/meta/schemas/agent-plugins/1.0.0/provenance.json +19 -0
- package/generated/plugins/agdf/runtime/agdf-local.js +5 -4
- package/generated/plugins/agdf/runtime/agdf-session-check.js +127 -50
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/agdf-interaction-locales.json +2682 -495
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/agdf-plugin.definition.json +288 -42
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/closeout.md +7 -3
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/control-scaffold.md +19 -6
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/gate-artifact-preparation.md +132 -0
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/gate-transition.md +56 -12
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/interaction.md +777 -0
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/modes.md +23 -11
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/prd-definition.md +130 -0
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/quality.md +85 -14
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/request-activation.md +252 -0
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/sd-definition.md +69 -0
- package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/task-target-resolution.md +63 -9
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/tp-definition.md +81 -0
- package/generated/plugins/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/ur-definition.md +94 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/command-registry.js +251 -16
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/contract-command.js +24 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/control-maintenance-command.js +44 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/delivery-path-search-command.js +11 -11
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/parse-args.js +254 -5
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/runtime-context.js +14 -37
- package/generated/plugins/agdf/runtime/create-agdf/lib/cli/validation-handlers.js +205 -7
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-command.js +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-evaluation/git-observation.js +22 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-maintenance/interaction.js +28 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-maintenance/repair.js +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-maintenance/service.js +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-maintenance/startup.js +25 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-state/run-recovery.js +5 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/claude.js +3 -3
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/codex.js +3 -3
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/opencode.js +4 -4
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/protocol.js +1 -1
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/generators/claude.js +3 -3
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/generators/codex.js +3 -3
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/generators/protocol.js +1 -1
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/surfaces/capabilities.js +1 -1
- package/generated/plugins/agdf/runtime/create-agdf/lib/delivery-path-search/transports/read-only-guard.js +2 -1
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-adapters/claude/session-command.js +2 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-adapters/codex/session-command.js +7 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-adapters/copilot/session-command.js +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-adapters/opencode/session-command.js +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-adapters/session-command.js +11 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/host-command.js +112 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/mcp-dispatch-runtime.js +360 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/mcp-lifecycle/facade-entry.js +26 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/mcp-lifecycle/facade-owner-entry.js +34 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/mcp-lifecycle/package.js +527 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/mcp-lifecycle/plugin-runtime.js +420 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/npm-invocation.js +27 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/repository-context.js +87 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/control-command-service.js +12 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/control-context.js +11 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/git-history.js +7 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/git-originals.js +36 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/local-validator.js +39 -5
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/plugin-provenance.js +1 -298
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/runtime-probe.js +61 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime/validator-application.js +3 -3
- package/generated/plugins/agdf/runtime/create-agdf/lib/runtime-check-consent/contract.js +9 -8
- package/generated/plugins/agdf/runtime/create-agdf/lib/skill-dispatch/binding.js +9 -0
- package/generated/plugins/agdf/runtime/create-agdf/package.json +6 -2
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/acceptance-criteria.js +61 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/backlog-vocabulary.d.ts +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/backlog-vocabulary.js +15 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/closeout-readiness.js +103 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/decision-content-readiness.js +131 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/definition-sources.js +46 -0
- package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/delivery-map.js +31 -37
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/delivery-relationships.js +21 -0
- package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/doctor.js +85 -17
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/gate-check.js +827 -0
- package/generated/plugins/{copilot/agdf/runtime/create-agdf → agdf/runtime/create-agdf/runtime/core}/lib/control-evaluation/gate-policy.js +141 -10
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/markdown-table.js +40 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/next-action.js +32 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/normalized-gaps.js +105 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/prd-readiness.js +51 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/qa-follow-up.js +83 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/report-decision.js +237 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-state-policy.js +51 -0
- package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/run-state.js +108 -74
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-step-policy.js +20 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-work-summary.js +109 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/sd-readiness.js +56 -0
- package/generated/plugins/{copilot/agdf/runtime/create-agdf → agdf/runtime/create-agdf/runtime/core}/lib/control-evaluation/shared.js +5 -2
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/tp-planning.js +118 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/traceability-readiness.js +212 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/ur-readiness.js +47 -0
- package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/verified-change.js +10 -30
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/artifact-readiness.js +122 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-backlog.js +135 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-context.js +97 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-contract.js +86 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-list.d.ts +17 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-list.js +45 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit-session.js +217 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/cockpit.js +388 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/contract.js +299 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/decision-session.js +243 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/selection.js +35 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/service.js +319 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/compatibility.js +149 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/contract.js +41 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/interaction.js +57 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/migration.js +85 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/presentation.js +122 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/repair.js +226 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/service.js +38 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read/cockpit-pool.js +105 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read/cockpit-worker.js +33 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read/control-changes.js +33 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read/fs.js +55 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read/snapshot.js +378 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-read-boundary.js +22 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-command-contract.js +73 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-command.js +137 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-operations.js +95 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/artefact-binding-proof.js +90 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/artefact-bindings.js +94 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary-shape.d.ts +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary-shape.js +40 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary.js +67 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/contained-file.js +56 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/control-configuration.js +19 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/decision-action-contract.js +32 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/decision-action-service.js +55 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/decision-material-contract.js +12 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/evidence-bindings.js +132 -0
- package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/index.js +2 -0
- package/generated/plugins/{copilot/agdf/runtime/create-agdf → agdf/runtime/create-agdf/runtime/core}/lib/control-state/legacy-migration.js +5 -31
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/legacy-projection-reader.js +38 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/presentation-decision.js +138 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-render.js +130 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-review.js +136 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-snapshot.js +108 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/qa-deviation-acceptance.js +82 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/recording-formats.js +29 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-artefact-recording.js +81 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-backlog-writer.js +80 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-backlog.js +90 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-command-contract.js +143 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-command-service.js +174 -0
- package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/control-state/run-identity.js +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-identity.js +31 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-proof.js +103 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-status.js +59 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operations.js +80 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-owned-outputs.js +59 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation-envelope.js +36 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation-render.js +443 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation.js +348 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-recording.js +273 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-recovery.js +296 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-relationship-correction.js +74 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision-boundary.js +44 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision-history.js +184 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision.js +458 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-seal-compute.js +141 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-seal.js +26 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-source-revisions.js +221 -0
- package/generated/plugins/{copilot/agdf/runtime/create-agdf/lib/control-state/run-state-parser.js → agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-document.js} +17 -47
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-edits.js +170 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-parser.js +106 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-reader.js +57 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-repository.js +201 -0
- package/generated/plugins/{copilot/agdf/runtime/create-agdf → agdf/runtime/create-agdf/runtime/core}/lib/control-state/run-state-resolver.js +1 -1
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-writer.js +484 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-step-pending.js +15 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-step-transaction.js +359 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-steps.js +571 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-store-inspection.js +65 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-text.js +8 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/delivery-continuation/service.js +67 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/index.js +14 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/interaction-catalog-validation.js +26 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/interaction-catalog.d.ts +2 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/interaction-catalog.js +98 -0
- package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/interaction-presentation.js +437 -33
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/mcp-resource-contract.js +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/mcp-tool-errors.js +176 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/repository-context-reader.js +87 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/resources/artefact-templates.js +72 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/resources/binding.js +26 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/resources/context.js +70 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/resources/contracts.js +23 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/runtime/host-installation.js +200 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/runtime/plugin-provenance.js +496 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/binding.js +66 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/compact-continuation.js +76 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/contract.js +430 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/delivery-intake.js +80 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/delivery-run-assignment.js +74 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/prd-definition.js +39 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/sd-definition.js +39 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/service.js +833 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/tp-definition.js +41 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/task-target-resolution.js +202 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/LICENSE +11 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/decode.js +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/decode.js +511 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/encode.js +73 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/escape.js +121 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-html.js +10 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +10 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/encode-html.js +13 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/index.js +131 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/package.json +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/decode-codepoint.js +72 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/decode.js +497 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/encode.js +69 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/escape.js +117 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/decode-data-html.js +7 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/decode-data-xml.js +7 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/encode-html.js +10 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/index.js +107 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/package.json +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/escape.js +3 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/package.json +118 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/entities/src/generated/.eslintrc.json +10 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/LICENSE +20 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.browser.cjs +43 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.browser.js +43 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.cjs +47 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.js +47 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.native.js +38 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/package.json +12 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/bin/nanoid.cjs +55 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.browser.cjs +45 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.browser.js +45 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.cjs +63 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.js +63 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/nanoid.js +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/index.cjs +24 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/index.js +24 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/package.json +6 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/package.json +89 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/index.cjs +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/index.js +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/package.json +6 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/LICENSE +19 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/doctype.js +118 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/error-codes.js +66 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/foreign-content.js +237 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/html.js +528 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/token.js +24 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/unicode.js +70 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/index.js +54 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/package.json +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/formatting-element-list.js +114 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/index.js +3240 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/open-element-stack.js +328 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/serializer/index.js +172 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tokenizer/index.js +2714 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tokenizer/preprocessor.js +200 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/default.js +176 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/interface.js +2 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/doctype.js +114 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/error-codes.js +63 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/foreign-content.js +228 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/html.js +523 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/token.js +20 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/unicode.js +62 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/index.js +42 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/formatting-element-list.js +110 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/index.js +3245 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/open-element-stack.js +324 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/serializer/index.js +168 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tokenizer/index.js +2710 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tokenizer/preprocessor.js +196 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tree-adapters/default.js +173 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tree-adapters/interface.js +1 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/package.json +50 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/LICENSE +15 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/package.json +25 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/picocolors.browser.js +4 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/picocolors.js +75 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/LICENSE +20 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/at-rule.js +25 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/comment.js +13 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/container.js +494 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/css-syntax-error.js +133 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/declaration.js +24 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/document.js +33 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/fromJSON.js +107 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/input.js +282 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/lazy-result.js +626 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/list.js +79 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/map-generator.js +383 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/no-work-result.js +137 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/node.js +494 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/parse.js +42 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/parser.js +626 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/postcss.js +101 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/postcss.mjs +30 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/previous-map.js +176 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/processor.js +67 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/result.js +42 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/root.js +76 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/rule.js +27 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/stringifier.js +457 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/stringify.js +69 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/symbols.js +5 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/terminal-highlight.js +70 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/tokenize.js +270 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/warn-once.js +13 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/warning.js +47 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/package.json +88 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/LICENSE +28 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/array-set.js +121 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/base64.js +67 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/quick-sort.js +141 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-map-consumer.js +1236 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-map-generator.js +446 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-node.js +420 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/util.js +594 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/package.json +71 -0
- package/generated/plugins/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/source-map.js +8 -0
- package/generated/plugins/agdf/runtime/runtime-manifest.json +2 -2
- package/generated/plugins/agdf/scripts/agent-skills-conformance.mjs +9 -5
- package/generated/plugins/agdf/scripts/check-runtime-integrity.mjs +1123 -182
- package/generated/plugins/agdf/scripts/instruction-footprint.mjs +945 -0
- package/generated/plugins/agdf/skills/brownfield-analysis/SKILL.md +67 -5
- package/generated/plugins/agdf/skills/clean-implementation-review/SKILL.md +34 -2
- package/generated/plugins/agdf/skills/code-review/SKILL.md +36 -2
- package/generated/plugins/agdf/skills/delivery-closeout/SKILL.md +34 -2
- package/generated/plugins/agdf/skills/delivery-path-search/SKILL.md +34 -2
- package/generated/plugins/agdf/skills/gate-check/SKILL.md +68 -222
- package/generated/plugins/agdf/skills/prd-definition/SKILL.md +51 -0
- package/generated/plugins/agdf/skills/prd-definition/help.md +23 -0
- package/generated/plugins/agdf/skills/qa-gate/SKILL.md +73 -5
- package/generated/plugins/agdf/skills/release-or/SKILL.md +36 -3
- package/generated/plugins/agdf/skills/sd-definition/SKILL.md +51 -0
- package/generated/plugins/agdf/skills/sd-definition/help.md +17 -0
- package/generated/plugins/agdf/skills/task-plan-review/SKILL.md +34 -2
- package/generated/plugins/agdf/skills/tp-definition/SKILL.md +51 -0
- package/generated/plugins/agdf/skills/tp-definition/help.md +17 -0
- package/generated/plugins/agdf/skills/ur-definition/SKILL.md +54 -0
- package/generated/plugins/agdf/skills/ur-definition/help.md +19 -0
- package/generated/plugins/agdf/skills/ux-intent-definition/SKILL.md +100 -6
- package/generated/plugins/agdf/skills/ux-intent-definition/help.md +3 -0
- package/generated/plugins/agdf/submission/openai/availability.md +1 -1
- package/generated/plugins/agdf/submission/openai/capability-matrix.json +1 -1
- package/generated/plugins/agdf/submission/openai/release-notes.md +1 -1
- package/generated/plugins/agdf/submission/openai/reviewer-cases.json +1 -1
- package/generated/plugins/copilot/agdf/.agdf-payload-inventory.json +3314 -409
- package/generated/plugins/copilot/agdf/control/README.md +125 -0
- package/generated/plugins/copilot/agdf/control/templates/AGDF_RUN.md +139 -0
- package/generated/plugins/copilot/agdf/control/templates/AGENT_QUALITY_CONTRACTS.json +126 -0
- package/generated/plugins/copilot/agdf/control/templates/CONTEXT_GRAPH.md +51 -0
- package/generated/plugins/copilot/agdf/control/templates/MASTER_BACKLOG.md +39 -0
- package/generated/plugins/copilot/agdf/control/templates/RUN_STATE.md +93 -0
- package/generated/plugins/copilot/agdf/control/templates/SOT_REGISTRY.md +25 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/BROWNFIELD_REVIEW.md +135 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/OR.md +125 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/PRD.md +113 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/QA_REPORT.md +44 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/SD.md +70 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/TP.md +71 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/UR.md +58 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/UX_INTENT_DEFINITION.md +61 -0
- package/generated/plugins/copilot/agdf/control/templates/artefacts/VERIFIED_CHANGE.md +58 -0
- package/generated/plugins/copilot/agdf/mcp/agdf-mcp-launch.js +7 -0
- package/generated/plugins/copilot/agdf/mcp/sdk/expected-sdk.json +21 -0
- package/generated/plugins/copilot/agdf/mcp/sdk/package-lock.json +47 -0
- package/generated/plugins/copilot/agdf/mcp/sdk/package.json +7 -0
- package/generated/plugins/copilot/agdf/mcp/server/NOTICE +10 -0
- package/generated/plugins/copilot/agdf/mcp/server/README.md +136 -0
- package/generated/plugins/copilot/agdf/mcp/server/bin/agdf-mcp.js +24 -0
- package/generated/plugins/copilot/agdf/mcp/server/package.json +59 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/cockpit-resource.js +20 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/generation-entry.js +86 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/generation-protocol.js +44 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/generation.js +211 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/main.js +56 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/server.js +187 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/ui-capability.js +17 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/worker-entry.js +39 -0
- package/generated/plugins/copilot/agdf/mcp/server/src/worker.js +134 -0
- package/generated/plugins/copilot/agdf/mcp.json +16 -0
- package/generated/plugins/copilot/agdf/meta/agdf-agent-router.md +50 -8
- package/generated/plugins/copilot/agdf/meta/agdf-plugin.definition.json +288 -42
- package/generated/plugins/copilot/agdf/meta/agdf-runtime-contract.md +17 -9
- package/generated/plugins/copilot/agdf/meta/distribution-profile-history.json +7 -0
- package/generated/plugins/copilot/agdf/plugin.json +3 -5
- package/generated/plugins/copilot/agdf/runtime/agdf-local.js +5 -4
- package/generated/plugins/copilot/agdf/runtime/agdf-session-check.js +110 -47
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/agdf-interaction-locales.json +2682 -495
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/agdf-plugin.definition.json +288 -42
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/closeout.md +82 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/context-graph.md +48 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/control-scaffold.md +145 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/gate-artifact-preparation.md +132 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/gate-transition.md +209 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/interaction.md +777 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/modes.md +195 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/prd-definition.md +130 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/quality.md +228 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/request-activation.md +252 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/sd-definition.md +69 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/task-target-resolution.md +156 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/tp-definition.md +81 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/generated/plugins/agdf/meta/contracts/ur-definition.md +94 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/command-registry.js +251 -16
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/contract-command.js +24 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/control-maintenance-command.js +44 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/delivery-path-search-command.js +11 -11
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/parse-args.js +254 -5
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/runtime-context.js +14 -37
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/cli/validation-handlers.js +205 -7
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-command.js +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-evaluation/git-observation.js +22 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-maintenance/interaction.js +28 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-maintenance/repair.js +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-maintenance/service.js +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-maintenance/startup.js +25 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-state/run-recovery.js +5 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/claude.js +3 -3
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/codex.js +3 -3
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/opencode.js +4 -4
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/evaluators/protocol.js +1 -1
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/generators/claude.js +3 -3
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/generators/codex.js +3 -3
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/generators/protocol.js +1 -1
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/surfaces/capabilities.js +1 -1
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/delivery-path-search/transports/read-only-guard.js +2 -1
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-adapters/claude/session-command.js +2 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-adapters/codex/session-command.js +7 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-adapters/copilot/session-command.js +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-adapters/opencode/session-command.js +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-adapters/session-command.js +11 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/host-command.js +112 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/mcp-dispatch-runtime.js +360 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/mcp-lifecycle/facade-entry.js +26 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/mcp-lifecycle/facade-owner-entry.js +34 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/mcp-lifecycle/package.js +527 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/mcp-lifecycle/plugin-runtime.js +420 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/npm-invocation.js +27 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/repository-context.js +87 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/control-command-service.js +12 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/control-context.js +11 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/git-history.js +7 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/git-originals.js +36 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/local-validator.js +39 -5
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/plugin-provenance.js +1 -298
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/runtime-probe.js +61 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime/validator-application.js +3 -3
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/runtime-check-consent/contract.js +9 -8
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/skill-dispatch/binding.js +9 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/package.json +6 -2
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/acceptance-criteria.js +61 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/backlog-vocabulary.d.ts +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/backlog-vocabulary.js +15 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/closeout-readiness.js +103 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/decision-content-readiness.js +131 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/definition-sources.js +46 -0
- package/{lib → generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/delivery-map.js +31 -37
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/delivery-relationships.js +21 -0
- package/generated/plugins/{agdf/runtime/create-agdf → copilot/agdf/runtime/create-agdf/runtime/core}/lib/control-evaluation/doctor.js +85 -17
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/gate-check.js +827 -0
- package/{lib → generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/gate-policy.js +141 -10
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/markdown-table.js +40 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/next-action.js +32 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/normalized-gaps.js +105 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/prd-readiness.js +51 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/qa-follow-up.js +83 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/report-decision.js +237 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-state-policy.js +51 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/run-state.js +108 -74
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-step-policy.js +20 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/run-work-summary.js +109 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/sd-readiness.js +56 -0
- package/{lib → generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib}/control-evaluation/shared.js +5 -2
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/tp-planning.js +118 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/traceability-readiness.js +212 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-evaluation/ur-readiness.js +47 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/verified-change.js +10 -30
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/artifact-readiness.js +122 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/contract.js +299 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/selection.js +35 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-inspect/service.js +319 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/compatibility.js +149 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/contract.js +41 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/interaction.js +57 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/migration.js +85 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/presentation.js +122 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/repair.js +226 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-maintenance/service.js +38 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-read/fs.js +55 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-read/snapshot.js +378 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-read-boundary.js +22 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-command-contract.js +73 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-command.js +137 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/approval-operations.js +95 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/artefact-binding-proof.js +90 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/artefact-bindings.js +94 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary-shape.d.ts +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary-shape.js +40 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/backlog-summary.js +67 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/contained-file.js +56 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/control-configuration.js +19 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/decision-material-contract.js +12 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/evidence-bindings.js +132 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/index.js +2 -0
- package/generated/plugins/{agdf/runtime/create-agdf → copilot/agdf/runtime/create-agdf/runtime/core}/lib/control-state/legacy-migration.js +5 -31
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/legacy-projection-reader.js +38 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/presentation-decision.js +138 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-render.js +130 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-review.js +136 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/preview-snapshot.js +108 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/qa-deviation-acceptance.js +82 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/recording-formats.js +29 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-artefact-recording.js +81 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-backlog-writer.js +80 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-backlog.js +90 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-command-contract.js +143 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-command-service.js +174 -0
- package/generated/plugins/{agdf/runtime/create-agdf → copilot/agdf/runtime/create-agdf/runtime/core}/lib/control-state/run-identity.js +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-identity.js +31 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-proof.js +103 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operation-status.js +59 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-operations.js +80 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-owned-outputs.js +59 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation-envelope.js +36 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation-render.js +443 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-presentation.js +348 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-recording.js +273 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-recovery.js +296 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-relationship-correction.js +74 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision-boundary.js +44 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision-history.js +184 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision.js +458 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-seal-compute.js +141 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-seal.js +26 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-source-revisions.js +221 -0
- package/{lib/control-state/run-state-parser.js → generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-document.js} +17 -47
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-edits.js +170 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-parser.js +106 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-reader.js +57 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-repository.js +201 -0
- package/generated/plugins/{agdf/runtime/create-agdf → copilot/agdf/runtime/create-agdf/runtime/core}/lib/control-state/run-state-resolver.js +1 -1
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-state-writer.js +484 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-step-pending.js +15 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-step-transaction.js +359 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-steps.js +571 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-store-inspection.js +65 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-text.js +8 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/delivery-continuation/service.js +67 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/fs-swap.js +26 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/index.js +14 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/interaction-catalog-validation.js +26 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/interaction-catalog.js +98 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/interaction-presentation.js +437 -33
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/mcp-resource-contract.js +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/mcp-tool-errors.js +176 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/repository-context-reader.js +87 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/resources/artefact-templates.js +72 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/resources/binding.js +27 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/resources/context.js +70 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/resources/contracts.js +23 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/runtime/distribution-profile-history.js +173 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/runtime/plugin-provenance.js +496 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/binding.js +66 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/compact-continuation.js +76 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/contract.js +430 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/delivery-intake.js +80 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/delivery-run-assignment.js +74 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/prd-definition.js +39 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/sd-definition.js +39 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/service.js +833 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/skill-dispatch/tp-definition.js +41 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/lib/task-target-resolution.js +202 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/LICENSE +11 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/decode.js +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/decode.js +511 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/encode.js +73 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/escape.js +121 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-html.js +10 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +10 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/generated/encode-html.js +13 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/index.js +131 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/commonjs/package.json +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/decode-codepoint.js +72 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/decode.js +497 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/encode.js +69 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/escape.js +117 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/decode-data-html.js +7 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/decode-data-xml.js +7 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/generated/encode-html.js +10 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/index.js +107 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/dist/esm/package.json +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/escape.js +3 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/package.json +118 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/entities/src/generated/.eslintrc.json +10 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/LICENSE +20 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.browser.cjs +43 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.browser.js +43 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.cjs +47 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.js +47 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/index.native.js +38 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/async/package.json +12 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/bin/nanoid.cjs +55 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.browser.cjs +45 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.browser.js +45 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.cjs +63 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/index.js +63 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/nanoid.js +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/index.cjs +24 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/index.js +24 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/non-secure/package.json +6 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/package.json +89 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/index.cjs +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/index.js +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/nanoid/url-alphabet/package.json +6 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/LICENSE +19 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/doctype.js +118 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/error-codes.js +66 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/foreign-content.js +237 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/html.js +528 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/token.js +24 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/common/unicode.js +70 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/index.js +54 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/package.json +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/formatting-element-list.js +114 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/index.js +3240 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/parser/open-element-stack.js +328 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/serializer/index.js +172 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tokenizer/index.js +2714 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tokenizer/preprocessor.js +200 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/default.js +176 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/interface.js +2 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/doctype.js +114 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/error-codes.js +63 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/foreign-content.js +228 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/html.js +523 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/token.js +20 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/common/unicode.js +62 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/index.js +42 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/formatting-element-list.js +110 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/index.js +3245 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/parser/open-element-stack.js +324 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/serializer/index.js +168 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tokenizer/index.js +2710 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tokenizer/preprocessor.js +196 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tree-adapters/default.js +173 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/dist/tree-adapters/interface.js +1 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/parse5/package.json +50 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/LICENSE +15 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/package.json +25 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/picocolors.browser.js +4 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/picocolors/picocolors.js +75 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/LICENSE +20 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/at-rule.js +25 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/comment.js +13 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/container.js +494 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/css-syntax-error.js +133 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/declaration.js +24 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/document.js +33 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/fromJSON.js +107 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/input.js +282 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/lazy-result.js +626 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/list.js +79 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/map-generator.js +383 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/no-work-result.js +137 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/node.js +494 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/parse.js +42 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/parser.js +626 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/postcss.js +101 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/postcss.mjs +30 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/previous-map.js +176 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/processor.js +67 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/result.js +42 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/root.js +76 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/rule.js +27 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/stringifier.js +457 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/stringify.js +69 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/symbols.js +5 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/terminal-highlight.js +70 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/tokenize.js +270 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/warn-once.js +13 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/lib/warning.js +47 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/postcss/package.json +88 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/LICENSE +28 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/array-set.js +121 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/base64.js +67 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/quick-sort.js +141 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-map-consumer.js +1236 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-map-generator.js +446 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/source-node.js +420 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/lib/util.js +594 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/package.json +71 -0
- package/generated/plugins/copilot/agdf/runtime/create-agdf/runtime/core/node_modules/source-map-js/source-map.js +8 -0
- package/generated/plugins/copilot/agdf/runtime/runtime-manifest.json +2 -2
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-brownfield-analysis/SKILL.md +70 -8
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-clean-implementation-review/SKILL.md +35 -3
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-code-review/SKILL.md +36 -2
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-delivery-closeout/SKILL.md +36 -4
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-delivery-path-search/SKILL.md +36 -4
- package/generated/plugins/copilot/agdf/skills/agdf-gate-check/SKILL.md +86 -0
- package/generated/plugins/copilot/agdf/skills/agdf-interaction-locales.json +1 -0
- package/generated/plugins/copilot/agdf/skills/agdf-prd-definition/SKILL.md +51 -0
- package/generated/plugins/copilot/agdf/skills/agdf-qa-gate/SKILL.md +205 -0
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-release-or/SKILL.md +44 -11
- package/generated/plugins/copilot/agdf/skills/agdf-runtime-contract.md +24 -0
- package/generated/plugins/copilot/agdf/skills/agdf-sd-definition/SKILL.md +51 -0
- package/generated/plugins/copilot/agdf/{copilot-skills → skills}/agdf-task-plan-review/SKILL.md +35 -3
- package/generated/plugins/copilot/agdf/skills/agdf-tp-definition/SKILL.md +51 -0
- package/generated/plugins/copilot/agdf/skills/agdf-ur-definition/SKILL.md +54 -0
- package/generated/plugins/copilot/agdf/skills/agdf-ux-intent-definition/SKILL.md +188 -0
- package/generated/plugins/copilot/agdf/skills/contracts/closeout.md +82 -0
- package/generated/plugins/copilot/agdf/skills/contracts/context-graph.md +48 -0
- package/generated/plugins/copilot/agdf/skills/contracts/control-scaffold.md +145 -0
- package/generated/plugins/copilot/agdf/skills/contracts/gate-artifact-preparation.md +132 -0
- package/generated/plugins/copilot/agdf/skills/contracts/gate-transition.md +209 -0
- package/generated/plugins/copilot/agdf/skills/contracts/interaction.md +777 -0
- package/generated/plugins/copilot/agdf/skills/contracts/modes.md +195 -0
- package/generated/plugins/copilot/agdf/skills/contracts/prd-definition.md +130 -0
- package/generated/plugins/copilot/agdf/skills/contracts/quality.md +228 -0
- package/generated/plugins/copilot/agdf/skills/contracts/request-activation.md +252 -0
- package/generated/plugins/copilot/agdf/skills/contracts/sd-definition.md +69 -0
- package/generated/plugins/copilot/agdf/skills/contracts/task-target-resolution.md +156 -0
- package/generated/plugins/copilot/agdf/skills/contracts/tp-definition.md +81 -0
- package/generated/plugins/copilot/agdf/skills/contracts/ur-definition.md +94 -0
- package/generated/submissions/openai/agdf/.codex-plugin/plugin.json +1 -1
- package/generated/submissions/openai/agdf/meta/agdf-agent-router.md +50 -8
- package/generated/submissions/openai/agdf/meta/agdf-interaction-locales.json +2682 -495
- package/generated/submissions/openai/agdf/meta/agdf-plugin.definition.json +288 -42
- package/generated/submissions/openai/agdf/meta/agdf-runtime-contract.md +17 -9
- package/generated/submissions/openai/agdf/meta/contracts/closeout.md +6 -2
- package/generated/submissions/openai/agdf/meta/contracts/control-scaffold.md +17 -4
- package/generated/submissions/openai/agdf/meta/contracts/gate-artifact-preparation.md +132 -0
- package/generated/submissions/openai/agdf/meta/contracts/gate-transition.md +48 -4
- package/generated/submissions/openai/agdf/meta/contracts/interaction.md +328 -38
- package/generated/submissions/openai/agdf/meta/contracts/modes.md +23 -11
- package/generated/submissions/openai/agdf/meta/contracts/prd-definition.md +130 -0
- package/generated/submissions/openai/agdf/meta/contracts/quality.md +77 -6
- package/generated/submissions/openai/agdf/meta/contracts/request-activation.md +252 -0
- package/generated/submissions/openai/agdf/meta/contracts/sd-definition.md +69 -0
- package/generated/submissions/openai/agdf/meta/contracts/task-target-resolution.md +63 -9
- package/generated/submissions/openai/agdf/meta/contracts/tp-definition.md +81 -0
- package/generated/submissions/openai/agdf/meta/contracts/ur-definition.md +94 -0
- package/generated/submissions/openai/agdf/meta/copilot-payload-baseline.json +3 -3
- package/generated/submissions/openai/agdf/meta/distribution-profile-history.json +7 -0
- package/generated/submissions/openai/agdf/meta/schemas/agent-plugins/1.0.0/mcp.schema.json +120 -0
- package/generated/submissions/openai/agdf/meta/schemas/agent-plugins/1.0.0/plugin.schema.json +65 -0
- package/generated/submissions/openai/agdf/meta/schemas/agent-plugins/1.0.0/provenance.json +19 -0
- package/generated/submissions/openai/agdf/plugin.json +47 -0
- package/generated/submissions/openai/agdf/skills/brownfield-analysis/SKILL.md +67 -5
- package/generated/submissions/openai/agdf/skills/clean-implementation-review/SKILL.md +34 -2
- package/generated/submissions/openai/agdf/skills/code-review/SKILL.md +36 -2
- package/generated/submissions/openai/agdf/skills/delivery-closeout/SKILL.md +34 -2
- package/generated/submissions/openai/agdf/skills/delivery-path-search/SKILL.md +34 -2
- package/generated/submissions/openai/agdf/skills/gate-check/SKILL.md +68 -222
- package/generated/submissions/openai/agdf/skills/prd-definition/SKILL.md +51 -0
- package/generated/submissions/openai/agdf/skills/prd-definition/help.md +23 -0
- package/generated/submissions/openai/agdf/skills/qa-gate/SKILL.md +73 -5
- package/generated/submissions/openai/agdf/skills/release-or/SKILL.md +36 -3
- package/generated/submissions/openai/agdf/skills/sd-definition/SKILL.md +51 -0
- package/generated/submissions/openai/agdf/skills/sd-definition/help.md +17 -0
- package/generated/submissions/openai/agdf/skills/task-plan-review/SKILL.md +34 -2
- package/generated/submissions/openai/agdf/skills/tp-definition/SKILL.md +51 -0
- package/generated/submissions/openai/agdf/skills/tp-definition/help.md +17 -0
- package/generated/submissions/openai/agdf/skills/ur-definition/SKILL.md +54 -0
- package/generated/submissions/openai/agdf/skills/ur-definition/help.md +19 -0
- package/generated/submissions/openai/agdf/skills/ux-intent-definition/SKILL.md +100 -6
- package/generated/submissions/openai/agdf/skills/ux-intent-definition/help.md +3 -0
- package/generated/submissions/openai/agdf/submission/openai/availability.md +1 -1
- package/generated/submissions/openai/agdf/submission/openai/capability-matrix.json +1 -1
- package/generated/submissions/openai/agdf/submission/openai/inventory.json +104 -32
- package/generated/submissions/openai/agdf/submission/openai/listing.json +1 -1
- package/generated/submissions/openai/agdf/submission/openai/readiness.json +2 -2
- package/generated/submissions/openai/agdf/submission/openai/readiness.md +2 -2
- package/generated/submissions/openai/agdf/submission/openai/release-notes.md +1 -1
- package/generated/submissions/openai/agdf/submission/openai/reviewer-cases.json +1 -1
- package/lib/cli/application.js +726 -271
- package/lib/cli/command-registry.js +251 -16
- package/lib/cli/contract-command.js +24 -0
- package/lib/cli/control-maintenance-command.js +44 -0
- package/lib/cli/delivery-path-search-command.js +11 -11
- package/lib/cli/parse-args.js +254 -5
- package/lib/cli/runtime-context.js +14 -37
- package/lib/cli/validation-handlers.js +205 -7
- package/lib/control-command.js +4 -0
- package/lib/control-evaluation/git-observation.js +22 -0
- package/lib/control-maintenance/interaction.js +28 -0
- package/lib/control-maintenance/repair.js +4 -0
- package/lib/control-maintenance/service.js +3 -0
- package/lib/control-maintenance/startup.js +25 -0
- package/lib/control-state/run-recovery.js +5 -0
- package/lib/delivery-path-search/evaluators/claude.js +3 -3
- package/lib/delivery-path-search/evaluators/codex.js +3 -3
- package/lib/delivery-path-search/evaluators/opencode.js +4 -4
- package/lib/delivery-path-search/evaluators/protocol.js +1 -1
- package/lib/delivery-path-search/generators/claude.js +3 -3
- package/lib/delivery-path-search/generators/codex.js +3 -3
- package/lib/delivery-path-search/generators/protocol.js +1 -1
- package/lib/delivery-path-search/surfaces/capabilities.js +1 -1
- package/lib/delivery-path-search/transports/read-only-guard.js +2 -1
- package/lib/host-adapters/claude/loaded-sessions.js +45 -0
- package/lib/host-adapters/claude/marketplace.js +2 -0
- package/lib/host-adapters/claude/permission-rules.js +20 -0
- package/lib/host-adapters/claude/plugin-mcp.js +40 -0
- package/lib/host-adapters/claude/plugin.js +285 -0
- package/lib/host-adapters/claude/runtime-check.js +39 -0
- package/lib/host-adapters/claude/session-command.js +2 -0
- package/lib/host-adapters/claude/uninstall.js +80 -0
- package/lib/host-adapters/codex/identity.js +19 -0
- package/lib/host-adapters/codex/mcp-startup.js +14 -0
- package/lib/host-adapters/codex/plugin-mcp.js +39 -0
- package/lib/host-adapters/codex/plugin.js +243 -0
- package/lib/host-adapters/codex/runtime-check.js +27 -0
- package/lib/host-adapters/codex/session-command.js +7 -0
- package/lib/host-adapters/copilot/plugin.js +220 -0
- package/lib/host-adapters/copilot/session-command.js +1 -0
- package/lib/host-adapters/opencode/runtime-check.js +39 -0
- package/lib/host-adapters/opencode/session-command.js +1 -0
- package/lib/host-adapters/opencode/status.js +43 -0
- package/lib/host-adapters/session-command.js +11 -0
- package/lib/host-command.js +112 -0
- package/lib/install-setup/contract.js +319 -0
- package/lib/install-setup/control-migration.js +10 -0
- package/lib/install-setup/control-repair.js +1 -0
- package/lib/install-setup/interaction.js +157 -0
- package/lib/install-setup/presentation.js +337 -0
- package/lib/install-setup/service.js +441 -0
- package/lib/installers/copilot-marketplace-transport.js +74 -0
- package/lib/installers/copilot-settings.js +34 -3
- package/lib/installers/copilot-skill-discovery.js +27 -0
- package/lib/installers/local-development.js +107 -11
- package/lib/installers/local-marketplace.js +313 -37
- package/lib/installers/npm-invocation.js +2 -0
- package/lib/installers/opencode-activation.js +5 -31
- package/lib/installers/opencode.js +286 -89
- package/lib/installers/packaged-app-marketplace.js +67 -0
- package/lib/installers/plugin-command.js +115 -0
- package/lib/installers/plugin-installers.js +21 -521
- package/lib/lifecycle/operations.js +78 -137
- package/lib/lifecycle/owned-mutation.js +64 -0
- package/lib/lifecycle/presentation.js +47 -4
- package/lib/lifecycle/result.js +183 -2
- package/lib/lifecycle/status.js +150 -66
- package/lib/mcp-dispatch-runtime.js +360 -0
- package/lib/mcp-lifecycle/adapter-contract.js +54 -0
- package/lib/mcp-lifecycle/adapters/claude.js +123 -0
- package/lib/mcp-lifecycle/adapters/codex-origin-probe.js +87 -0
- package/lib/mcp-lifecycle/adapters/codex.js +502 -0
- package/lib/mcp-lifecycle/adapters/copilot.js +106 -0
- package/lib/mcp-lifecycle/adapters/file-utils.js +90 -0
- package/lib/mcp-lifecycle/adapters/opencode.js +148 -0
- package/lib/mcp-lifecycle/evidence.js +122 -0
- package/lib/mcp-lifecycle/facade-entry.js +26 -0
- package/lib/mcp-lifecycle/facade-owner-entry.js +34 -0
- package/lib/mcp-lifecycle/host-config.js +60 -0
- package/lib/mcp-lifecycle/package.js +527 -0
- package/lib/mcp-lifecycle/plugin-runtime.js +420 -0
- package/lib/mcp-lifecycle/presentation.js +61 -0
- package/lib/mcp-lifecycle/profile-context.js +11 -0
- package/lib/mcp-lifecycle/profile.js +63 -0
- package/lib/mcp-lifecycle/result.js +92 -0
- package/lib/mcp-lifecycle/service.js +533 -0
- package/lib/npm-invocation.js +27 -0
- package/lib/repository-context.js +87 -0
- package/lib/runtime/control-command-service.js +12 -0
- package/lib/runtime/control-context.js +11 -0
- package/lib/runtime/git-history.js +7 -0
- package/lib/runtime/git-originals.js +36 -0
- package/lib/runtime/local-validator.js +39 -5
- package/lib/runtime/plugin-provenance.js +1 -298
- package/lib/runtime/runtime-probe.js +61 -0
- package/lib/runtime/validator-application.js +3 -3
- package/lib/runtime-check-consent/adapters.js +3 -42
- package/lib/runtime-check-consent/claude-settings.js +2 -23
- package/lib/runtime-check-consent/codex-hooks.js +96 -0
- package/lib/runtime-check-consent/codex-plugin-consent.js +118 -0
- package/lib/runtime-check-consent/contract.js +9 -8
- package/lib/runtime-check-consent/coordinator.js +3 -3
- package/lib/runtime-check-consent/service.js +29 -53
- package/lib/runtime-check-consent/state.js +1 -1
- package/lib/scaffold/canonical-init.js +691 -0
- package/lib/scaffold/plan.js +8 -14
- package/lib/scaffold/presentation.js +53 -3
- package/lib/skill-dispatch/binding.js +9 -0
- package/opencode-plugin.js +99 -26
- package/package.json +22 -51
- package/runtime/core/lib/control-evaluation/acceptance-criteria.js +61 -0
- package/runtime/core/lib/control-evaluation/backlog-vocabulary.d.ts +3 -0
- package/runtime/core/lib/control-evaluation/backlog-vocabulary.js +15 -0
- package/runtime/core/lib/control-evaluation/closeout-readiness.js +103 -0
- package/runtime/core/lib/control-evaluation/decision-content-readiness.js +131 -0
- package/runtime/core/lib/control-evaluation/definition-sources.js +46 -0
- package/{generated/plugins/copilot/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/delivery-map.js +31 -37
- package/runtime/core/lib/control-evaluation/delivery-relationships.js +21 -0
- package/{generated/plugins/copilot/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/doctor.js +85 -17
- package/runtime/core/lib/control-evaluation/gate-check.js +827 -0
- package/{generated/plugins/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/gate-policy.js +141 -10
- package/runtime/core/lib/control-evaluation/markdown-table.js +40 -0
- package/runtime/core/lib/control-evaluation/next-action.js +32 -0
- package/runtime/core/lib/control-evaluation/normalized-gaps.js +105 -0
- package/runtime/core/lib/control-evaluation/prd-readiness.js +51 -0
- package/runtime/core/lib/control-evaluation/qa-follow-up.js +83 -0
- package/runtime/core/lib/control-evaluation/report-decision.js +237 -0
- package/runtime/core/lib/control-evaluation/run-state-policy.js +51 -0
- package/{generated/plugins/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/run-state.js +108 -74
- package/runtime/core/lib/control-evaluation/run-step-policy.js +20 -0
- package/runtime/core/lib/control-evaluation/run-work-summary.js +109 -0
- package/runtime/core/lib/control-evaluation/sd-readiness.js +56 -0
- package/{generated/plugins/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/shared.js +5 -2
- package/runtime/core/lib/control-evaluation/tp-planning.js +118 -0
- package/runtime/core/lib/control-evaluation/traceability-readiness.js +212 -0
- package/runtime/core/lib/control-evaluation/ur-readiness.js +47 -0
- package/{generated/plugins/agdf/runtime/create-agdf → runtime/core}/lib/control-evaluation/verified-change.js +10 -30
- package/runtime/core/lib/control-inspect/artifact-readiness.js +122 -0
- package/runtime/core/lib/control-inspect/cockpit-backlog.js +135 -0
- package/runtime/core/lib/control-inspect/cockpit-context.js +97 -0
- package/runtime/core/lib/control-inspect/cockpit-contract.js +86 -0
- package/runtime/core/lib/control-inspect/cockpit-list.d.ts +17 -0
- package/runtime/core/lib/control-inspect/cockpit-list.js +45 -0
- package/runtime/core/lib/control-inspect/cockpit-session.js +217 -0
- package/runtime/core/lib/control-inspect/cockpit.js +388 -0
- package/runtime/core/lib/control-inspect/contract.js +299 -0
- package/runtime/core/lib/control-inspect/decision-session.js +243 -0
- package/runtime/core/lib/control-inspect/selection.js +35 -0
- package/runtime/core/lib/control-inspect/service.js +319 -0
- package/runtime/core/lib/control-maintenance/compatibility.js +149 -0
- package/runtime/core/lib/control-maintenance/contract.js +41 -0
- package/runtime/core/lib/control-maintenance/interaction.js +57 -0
- package/runtime/core/lib/control-maintenance/migration.js +85 -0
- package/runtime/core/lib/control-maintenance/presentation.js +122 -0
- package/runtime/core/lib/control-maintenance/repair.js +226 -0
- package/runtime/core/lib/control-maintenance/service.js +38 -0
- package/runtime/core/lib/control-read/cockpit-pool.js +105 -0
- package/runtime/core/lib/control-read/cockpit-worker.js +33 -0
- package/runtime/core/lib/control-read/control-changes.js +33 -0
- package/runtime/core/lib/control-read/fs.js +55 -0
- package/runtime/core/lib/control-read/snapshot.js +378 -0
- package/runtime/core/lib/control-read-boundary.js +22 -0
- package/runtime/core/lib/control-state/approval-command-contract.js +73 -0
- package/runtime/core/lib/control-state/approval-command.js +137 -0
- package/runtime/core/lib/control-state/approval-operations.js +95 -0
- package/runtime/core/lib/control-state/artefact-binding-proof.js +90 -0
- package/runtime/core/lib/control-state/artefact-bindings.js +94 -0
- package/runtime/core/lib/control-state/backlog-summary-shape.d.ts +4 -0
- package/runtime/core/lib/control-state/backlog-summary-shape.js +40 -0
- package/runtime/core/lib/control-state/backlog-summary.js +67 -0
- package/runtime/core/lib/control-state/contained-file.js +56 -0
- package/runtime/core/lib/control-state/control-configuration.js +19 -0
- package/runtime/core/lib/control-state/decision-action-contract.js +32 -0
- package/runtime/core/lib/control-state/decision-action-service.js +55 -0
- package/runtime/core/lib/control-state/decision-material-contract.js +12 -0
- package/runtime/core/lib/control-state/evidence-bindings.js +132 -0
- package/{lib → runtime/core/lib}/control-state/index.js +2 -0
- package/{lib → runtime/core/lib}/control-state/legacy-migration.js +5 -31
- package/runtime/core/lib/control-state/legacy-projection-reader.js +38 -0
- package/runtime/core/lib/control-state/presentation-decision.js +138 -0
- package/runtime/core/lib/control-state/preview-render.js +130 -0
- package/runtime/core/lib/control-state/preview-review.js +136 -0
- package/runtime/core/lib/control-state/preview-snapshot.js +108 -0
- package/runtime/core/lib/control-state/qa-deviation-acceptance.js +82 -0
- package/runtime/core/lib/control-state/recording-formats.js +29 -0
- package/runtime/core/lib/control-state/run-artefact-recording.js +81 -0
- package/runtime/core/lib/control-state/run-backlog-writer.js +80 -0
- package/runtime/core/lib/control-state/run-backlog.js +90 -0
- package/runtime/core/lib/control-state/run-command-contract.js +143 -0
- package/runtime/core/lib/control-state/run-command-service.js +174 -0
- package/{generated/plugins/copilot/agdf/runtime/create-agdf → runtime/core}/lib/control-state/run-identity.js +1 -0
- package/runtime/core/lib/control-state/run-operation-identity.js +31 -0
- package/runtime/core/lib/control-state/run-operation-proof.js +103 -0
- package/runtime/core/lib/control-state/run-operation-status.js +59 -0
- package/runtime/core/lib/control-state/run-operations.js +80 -0
- package/runtime/core/lib/control-state/run-owned-outputs.js +59 -0
- package/runtime/core/lib/control-state/run-presentation-envelope.js +36 -0
- package/runtime/core/lib/control-state/run-presentation-render.js +443 -0
- package/runtime/core/lib/control-state/run-presentation.js +348 -0
- package/runtime/core/lib/control-state/run-recording.js +273 -0
- package/runtime/core/lib/control-state/run-recovery.js +296 -0
- package/runtime/core/lib/control-state/run-relationship-correction.js +74 -0
- package/runtime/core/lib/control-state/run-revision-boundary.js +44 -0
- package/runtime/core/lib/control-state/run-revision-history.js +184 -0
- package/runtime/core/lib/control-state/run-revision.js +458 -0
- package/runtime/core/lib/control-state/run-seal-compute.js +141 -0
- package/runtime/core/lib/control-state/run-seal.js +26 -0
- package/runtime/core/lib/control-state/run-source-revisions.js +221 -0
- package/{generated/plugins/agdf/runtime/create-agdf/lib/control-state/run-state-parser.js → runtime/core/lib/control-state/run-state-document.js} +17 -47
- package/runtime/core/lib/control-state/run-state-edits.js +170 -0
- package/runtime/core/lib/control-state/run-state-parser.js +106 -0
- package/runtime/core/lib/control-state/run-state-reader.js +57 -0
- package/runtime/core/lib/control-state/run-state-repository.js +201 -0
- package/{lib → runtime/core/lib}/control-state/run-state-resolver.js +1 -1
- package/runtime/core/lib/control-state/run-state-writer.js +484 -0
- package/runtime/core/lib/control-state/run-step-pending.js +15 -0
- package/runtime/core/lib/control-state/run-step-transaction.js +359 -0
- package/runtime/core/lib/control-state/run-steps.js +571 -0
- package/runtime/core/lib/control-state/run-store-inspection.js +65 -0
- package/runtime/core/lib/control-state/run-text.js +8 -0
- package/runtime/core/lib/delivery-continuation/service.js +67 -0
- package/runtime/core/lib/fs-swap.js +26 -0
- package/runtime/core/lib/index.js +14 -0
- package/runtime/core/lib/interaction-catalog-validation.js +26 -0
- package/runtime/core/lib/interaction-catalog.d.ts +2 -0
- package/runtime/core/lib/interaction-catalog.js +98 -0
- package/{lib → runtime/core/lib}/interaction-presentation.js +437 -33
- package/runtime/core/lib/mcp-resource-contract.js +4 -0
- package/runtime/core/lib/mcp-tool-errors.js +176 -0
- package/runtime/core/lib/repository-context-reader.js +87 -0
- package/runtime/core/lib/resources/artefact-templates.js +72 -0
- package/runtime/core/lib/resources/binding.js +26 -0
- package/runtime/core/lib/resources/context.js +70 -0
- package/runtime/core/lib/resources/contracts.js +23 -0
- package/runtime/core/lib/runtime/distribution-profile-history.js +173 -0
- package/runtime/core/lib/runtime/host-installation.js +200 -0
- package/runtime/core/lib/runtime/plugin-provenance.js +496 -0
- package/runtime/core/lib/skill-dispatch/binding.js +66 -0
- package/runtime/core/lib/skill-dispatch/compact-continuation.js +76 -0
- package/runtime/core/lib/skill-dispatch/contract.js +430 -0
- package/runtime/core/lib/skill-dispatch/delivery-intake.js +80 -0
- package/runtime/core/lib/skill-dispatch/delivery-run-assignment.js +74 -0
- package/runtime/core/lib/skill-dispatch/prd-definition.js +39 -0
- package/runtime/core/lib/skill-dispatch/sd-definition.js +39 -0
- package/runtime/core/lib/skill-dispatch/service.js +833 -0
- package/runtime/core/lib/skill-dispatch/tp-definition.js +41 -0
- package/runtime/core/lib/task-target-resolution.js +202 -0
- package/runtime/core/node_modules/entities/LICENSE +11 -0
- package/runtime/core/node_modules/entities/decode.js +3 -0
- package/runtime/core/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
- package/runtime/core/node_modules/entities/dist/commonjs/decode.js +511 -0
- package/runtime/core/node_modules/entities/dist/commonjs/encode.js +73 -0
- package/runtime/core/node_modules/entities/dist/commonjs/escape.js +121 -0
- package/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-html.js +10 -0
- package/runtime/core/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +10 -0
- package/runtime/core/node_modules/entities/dist/commonjs/generated/encode-html.js +13 -0
- package/runtime/core/node_modules/entities/dist/commonjs/index.js +131 -0
- package/runtime/core/node_modules/entities/dist/commonjs/package.json +3 -0
- package/runtime/core/node_modules/entities/dist/esm/decode-codepoint.js +72 -0
- package/runtime/core/node_modules/entities/dist/esm/decode.js +497 -0
- package/runtime/core/node_modules/entities/dist/esm/encode.js +69 -0
- package/runtime/core/node_modules/entities/dist/esm/escape.js +117 -0
- package/runtime/core/node_modules/entities/dist/esm/generated/decode-data-html.js +7 -0
- package/runtime/core/node_modules/entities/dist/esm/generated/decode-data-xml.js +7 -0
- package/runtime/core/node_modules/entities/dist/esm/generated/encode-html.js +10 -0
- package/runtime/core/node_modules/entities/dist/esm/index.js +107 -0
- package/runtime/core/node_modules/entities/dist/esm/package.json +3 -0
- package/runtime/core/node_modules/entities/escape.js +3 -0
- package/runtime/core/node_modules/entities/package.json +118 -0
- package/runtime/core/node_modules/entities/src/generated/.eslintrc.json +10 -0
- package/runtime/core/node_modules/nanoid/LICENSE +20 -0
- package/runtime/core/node_modules/nanoid/async/index.browser.cjs +43 -0
- package/runtime/core/node_modules/nanoid/async/index.browser.js +43 -0
- package/runtime/core/node_modules/nanoid/async/index.cjs +47 -0
- package/runtime/core/node_modules/nanoid/async/index.js +47 -0
- package/runtime/core/node_modules/nanoid/async/index.native.js +38 -0
- package/runtime/core/node_modules/nanoid/async/package.json +12 -0
- package/runtime/core/node_modules/nanoid/bin/nanoid.cjs +55 -0
- package/runtime/core/node_modules/nanoid/index.browser.cjs +45 -0
- package/runtime/core/node_modules/nanoid/index.browser.js +45 -0
- package/runtime/core/node_modules/nanoid/index.cjs +63 -0
- package/runtime/core/node_modules/nanoid/index.js +63 -0
- package/runtime/core/node_modules/nanoid/nanoid.js +1 -0
- package/runtime/core/node_modules/nanoid/non-secure/index.cjs +24 -0
- package/runtime/core/node_modules/nanoid/non-secure/index.js +24 -0
- package/runtime/core/node_modules/nanoid/non-secure/package.json +6 -0
- package/runtime/core/node_modules/nanoid/package.json +89 -0
- package/runtime/core/node_modules/nanoid/url-alphabet/index.cjs +4 -0
- package/runtime/core/node_modules/nanoid/url-alphabet/index.js +4 -0
- package/runtime/core/node_modules/nanoid/url-alphabet/package.json +6 -0
- package/runtime/core/node_modules/parse5/LICENSE +19 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/doctype.js +118 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/error-codes.js +66 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/foreign-content.js +237 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/html.js +528 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/token.js +24 -0
- package/runtime/core/node_modules/parse5/dist/cjs/common/unicode.js +70 -0
- package/runtime/core/node_modules/parse5/dist/cjs/index.js +54 -0
- package/runtime/core/node_modules/parse5/dist/cjs/package.json +1 -0
- package/runtime/core/node_modules/parse5/dist/cjs/parser/formatting-element-list.js +114 -0
- package/runtime/core/node_modules/parse5/dist/cjs/parser/index.js +3240 -0
- package/runtime/core/node_modules/parse5/dist/cjs/parser/open-element-stack.js +328 -0
- package/runtime/core/node_modules/parse5/dist/cjs/serializer/index.js +172 -0
- package/runtime/core/node_modules/parse5/dist/cjs/tokenizer/index.js +2714 -0
- package/runtime/core/node_modules/parse5/dist/cjs/tokenizer/preprocessor.js +200 -0
- package/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/default.js +176 -0
- package/runtime/core/node_modules/parse5/dist/cjs/tree-adapters/interface.js +2 -0
- package/runtime/core/node_modules/parse5/dist/common/doctype.js +114 -0
- package/runtime/core/node_modules/parse5/dist/common/error-codes.js +63 -0
- package/runtime/core/node_modules/parse5/dist/common/foreign-content.js +228 -0
- package/runtime/core/node_modules/parse5/dist/common/html.js +523 -0
- package/runtime/core/node_modules/parse5/dist/common/token.js +20 -0
- package/runtime/core/node_modules/parse5/dist/common/unicode.js +62 -0
- package/runtime/core/node_modules/parse5/dist/index.js +42 -0
- package/runtime/core/node_modules/parse5/dist/parser/formatting-element-list.js +110 -0
- package/runtime/core/node_modules/parse5/dist/parser/index.js +3245 -0
- package/runtime/core/node_modules/parse5/dist/parser/open-element-stack.js +324 -0
- package/runtime/core/node_modules/parse5/dist/serializer/index.js +168 -0
- package/runtime/core/node_modules/parse5/dist/tokenizer/index.js +2710 -0
- package/runtime/core/node_modules/parse5/dist/tokenizer/preprocessor.js +196 -0
- package/runtime/core/node_modules/parse5/dist/tree-adapters/default.js +173 -0
- package/runtime/core/node_modules/parse5/dist/tree-adapters/interface.js +1 -0
- package/runtime/core/node_modules/parse5/package.json +50 -0
- package/runtime/core/node_modules/picocolors/LICENSE +15 -0
- package/runtime/core/node_modules/picocolors/package.json +25 -0
- package/runtime/core/node_modules/picocolors/picocolors.browser.js +4 -0
- package/runtime/core/node_modules/picocolors/picocolors.js +75 -0
- package/runtime/core/node_modules/postcss/LICENSE +20 -0
- package/runtime/core/node_modules/postcss/lib/at-rule.js +25 -0
- package/runtime/core/node_modules/postcss/lib/comment.js +13 -0
- package/runtime/core/node_modules/postcss/lib/container.js +494 -0
- package/runtime/core/node_modules/postcss/lib/css-syntax-error.js +133 -0
- package/runtime/core/node_modules/postcss/lib/declaration.js +24 -0
- package/runtime/core/node_modules/postcss/lib/document.js +33 -0
- package/runtime/core/node_modules/postcss/lib/fromJSON.js +107 -0
- package/runtime/core/node_modules/postcss/lib/input.js +282 -0
- package/runtime/core/node_modules/postcss/lib/lazy-result.js +626 -0
- package/runtime/core/node_modules/postcss/lib/list.js +79 -0
- package/runtime/core/node_modules/postcss/lib/map-generator.js +383 -0
- package/runtime/core/node_modules/postcss/lib/no-work-result.js +137 -0
- package/runtime/core/node_modules/postcss/lib/node.js +494 -0
- package/runtime/core/node_modules/postcss/lib/parse.js +42 -0
- package/runtime/core/node_modules/postcss/lib/parser.js +626 -0
- package/runtime/core/node_modules/postcss/lib/postcss.js +101 -0
- package/runtime/core/node_modules/postcss/lib/postcss.mjs +30 -0
- package/runtime/core/node_modules/postcss/lib/previous-map.js +176 -0
- package/runtime/core/node_modules/postcss/lib/processor.js +67 -0
- package/runtime/core/node_modules/postcss/lib/result.js +42 -0
- package/runtime/core/node_modules/postcss/lib/root.js +76 -0
- package/runtime/core/node_modules/postcss/lib/rule.js +27 -0
- package/runtime/core/node_modules/postcss/lib/stringifier.js +457 -0
- package/runtime/core/node_modules/postcss/lib/stringify.js +69 -0
- package/runtime/core/node_modules/postcss/lib/symbols.js +5 -0
- package/runtime/core/node_modules/postcss/lib/terminal-highlight.js +70 -0
- package/runtime/core/node_modules/postcss/lib/tokenize.js +270 -0
- package/runtime/core/node_modules/postcss/lib/warn-once.js +13 -0
- package/runtime/core/node_modules/postcss/lib/warning.js +47 -0
- package/runtime/core/node_modules/postcss/package.json +88 -0
- package/runtime/core/node_modules/source-map-js/LICENSE +28 -0
- package/runtime/core/node_modules/source-map-js/lib/array-set.js +121 -0
- package/runtime/core/node_modules/source-map-js/lib/base64-vlq.js +140 -0
- package/runtime/core/node_modules/source-map-js/lib/base64.js +67 -0
- package/runtime/core/node_modules/source-map-js/lib/binary-search.js +111 -0
- package/runtime/core/node_modules/source-map-js/lib/mapping-list.js +79 -0
- package/runtime/core/node_modules/source-map-js/lib/quick-sort.js +141 -0
- package/runtime/core/node_modules/source-map-js/lib/source-map-consumer.js +1236 -0
- package/runtime/core/node_modules/source-map-js/lib/source-map-generator.js +446 -0
- package/runtime/core/node_modules/source-map-js/lib/source-node.js +420 -0
- package/runtime/core/node_modules/source-map-js/lib/util.js +594 -0
- package/runtime/core/node_modules/source-map-js/package.json +71 -0
- package/runtime/core/node_modules/source-map-js/source-map.js +8 -0
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-evaluation/gate-check.js +0 -506
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-state/run-state-repository.js +0 -68
- package/generated/plugins/agdf/runtime/create-agdf/lib/control-state/run-state-writer.js +0 -97
- package/generated/plugins/copilot/agdf/copilot-skills/agdf-gate-check/SKILL.md +0 -240
- package/generated/plugins/copilot/agdf/copilot-skills/agdf-interaction-locales.json +0 -512
- package/generated/plugins/copilot/agdf/copilot-skills/agdf-qa-gate/SKILL.md +0 -137
- package/generated/plugins/copilot/agdf/copilot-skills/agdf-runtime-contract.md +0 -16
- package/generated/plugins/copilot/agdf/copilot-skills/agdf-ux-intent-definition/SKILL.md +0 -94
- package/generated/plugins/copilot/agdf/copilot-skills/contracts/interaction.md +0 -487
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-evaluation/gate-check.js +0 -506
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-state/run-state-repository.js +0 -68
- package/generated/plugins/copilot/agdf/runtime/create-agdf/lib/control-state/run-state-writer.js +0 -97
- package/lib/control-evaluation/gate-check.js +0 -506
- package/lib/control-state/run-state-repository.js +0 -68
- package/lib/control-state/run-state-writer.js +0 -97
- package/lib/proportionality-benchmark/blind-prompt.js +0 -38
- package/lib/proportionality-benchmark/contracts.js +0 -129
- package/lib/proportionality-benchmark/corpus-loader.js +0 -221
- package/lib/proportionality-benchmark/evaluator.js +0 -260
- package/lib/proportionality-benchmark/index.js +0 -8
- package/lib/proportionality-benchmark/live-recorder.js +0 -122
- package/lib/proportionality-benchmark/profiles.js +0 -102
- package/lib/proportionality-benchmark/report.js +0 -60
- package/lib/proportionality-benchmark/source-fingerprint.js +0 -34
- package/lib/public-plugin/builder.js +0 -83
- package/lib/public-plugin/contract.js +0 -102
- package/lib/public-plugin/copilot-profile.js +0 -126
- package/lib/public-plugin/manifest.js +0 -104
- package/lib/public-plugin/report.js +0 -33
- package/lib/public-plugin/validator.js +0 -101
- package/lib/release/profile-history.js +0 -222
- package/lib/release/version-bump.js +0 -549
- package/lib/release/version-coherence.js +0 -137
- package/lib/skill-evals/artefact-quality.js +0 -36
- package/lib/skill-evals/index.js +0 -105
- package/lib/skill-evals/live-recorder.js +0 -85
- package/lib/skill-evals/workspace.js +0 -97
- /package/generated/plugins/{copilot/agdf/copilot-skills → agdf/runtime/create-agdf/generated/plugins/agdf/meta}/contracts/context-graph.md +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/parent-reconciliation.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/required-files.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/aggregate.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/gate-approval-validator.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/candidate-policy.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/contracts.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/persistence.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/scoring.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/search-engine.js +0 -0
- /package/generated/plugins/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/state-adapter.js +0 -0
- /package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/fs-swap.js +0 -0
- /package/{lib → generated/plugins/agdf/runtime/create-agdf/runtime/core/lib}/runtime/distribution-profile-history.js +0 -0
- /package/generated/plugins/copilot/agdf/{hooks/copilot-hooks.json → com.github.copilot/hooks/hooks.json} +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/parent-reconciliation.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-evaluation/required-files.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/aggregate.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/control-state/gate-approval-validator.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/candidate-policy.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/contracts.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/persistence.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/scoring.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/search-engine.js +0 -0
- /package/generated/plugins/copilot/agdf/runtime/create-agdf/{lib → runtime/core/lib}/delivery-path-search/state-adapter.js +0 -0
- /package/{lib → runtime/core/lib}/control-evaluation/parent-reconciliation.js +0 -0
- /package/{lib → runtime/core/lib}/control-evaluation/required-files.js +0 -0
- /package/{lib → runtime/core/lib}/control-state/aggregate.js +0 -0
- /package/{lib → runtime/core/lib}/control-state/gate-approval-validator.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/candidate-policy.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/contracts.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/persistence.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/scoring.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/search-engine.js +0 -0
- /package/{lib → runtime/core/lib}/delivery-path-search/state-adapter.js +0 -0
package/generated/plugins/agdf/runtime/create-agdf/runtime/core/lib/control-state/run-revision.js
ADDED
|
@@ -0,0 +1,458 @@
|
|
|
1
|
+
import { assertRunOperationIdentity } from "./run-operation-identity.js";
|
|
2
|
+
import { prepareRunContentState } from "../control-evaluation/run-state.js";
|
|
3
|
+
import { parseControlState, parseRunState } from "./run-state-parser.js";
|
|
4
|
+
import { appendTableRow, firstSection, guardedWrite, readRun, rejected, replaceFirstScalar, replaceSectionScalar, removeTableRows, tableCells, tableLine, tableLineIndexes, upsertTableRow } from "./run-state-edits.js";
|
|
5
|
+
import { APPROVAL_GATES, artefactFileDigest, listedArtefactPaths, pendingArtefactPaths, canonicalRunText, runSealState } from "./run-seal.js";
|
|
6
|
+
import { transitionDecisionForRunState } from "../control-evaluation/gate-policy.js";
|
|
7
|
+
import { withOwnedFileLock } from "./run-state-writer.js";
|
|
8
|
+
import { writeRunWithBacklog } from "./run-backlog-writer.js";
|
|
9
|
+
import { backlogStatusForSummary } from "./run-backlog.js";
|
|
10
|
+
import { runWorkSummary, assertSummarySources } from "../control-evaluation/run-work-summary.js";
|
|
11
|
+
import { recordBacklogSummary } from "./backlog-summary.js";
|
|
12
|
+
import { canonicalJson, digest, exactObject, resolveControlCommandTarget } from "./approval-command-contract.js";
|
|
13
|
+
import { randomUUID } from "node:crypto";
|
|
14
|
+
import { REVISION_PROPOSAL_FIELDS, REVISION_PROPOSAL_V2_FIELDS, REVISION_IMPACT_FIELDS, REVISION_UPSTREAM_FIELDS, REVISION_ANALYSIS_FIELDS } from './recording-formats.js';
|
|
15
|
+
import { existsSync, readFileSync, readdirSync } from "node:fs";
|
|
16
|
+
import { join } from "node:path";
|
|
17
|
+
import { runPath } from "./run-state-reader.js";
|
|
18
|
+
import { readArtefactBindings } from "./artefact-bindings.js";
|
|
19
|
+
import { exactApprovedArtefacts, readContainedJson, validateBindingProof } from "./artefact-binding-proof.js";
|
|
20
|
+
import { SOURCE_GATES, appendSourceRevision, readSourceRevisions, revisionHistoryPrefix, sourceRevisionImpact, sourceRevisionConfirmation, validExpandedRevisionProof } from "./run-source-revisions.js";
|
|
21
|
+
import { collectRevisionHistory, byteDigest, inspectRevisionHistory, readHistoryBytes } from "./run-revision-history.js";
|
|
22
|
+
import { commitRunStepLocked, recoverPendingRunStepLocked, readPendingSourceRevisionJournal } from "./run-step-transaction.js";
|
|
23
|
+
import { pendingRunStepIds, pendingRunStepPath } from "./run-step-pending.js";
|
|
24
|
+
import { REVISION_ID_PATTERN, RUN_ID_PATTERN } from "./run-identity.js";
|
|
25
|
+
import { internalStepArtefacts } from "../control-evaluation/run-state.js";
|
|
26
|
+
import { containedRegularFile, hasSymlinkComponent } from "./contained-file.js";
|
|
27
|
+
import { sourceRevisionBoundary } from "./run-revision-boundary.js";
|
|
28
|
+
import { readOperationSource } from './run-operation-proof.js';
|
|
29
|
+
import { COOPERATIVE_ASSURANCE } from './approval-command-contract.js';
|
|
30
|
+
import { appendRunOperation, readRunOperations, earlyPrdConfirmation } from './run-operations.js';
|
|
31
|
+
import { operationReceipt } from './run-operation-proof.js';
|
|
32
|
+
import { readPendingRunStepJournal } from './run-step-transaction.js';
|
|
33
|
+
import { earlyPrdRevisionBoundary } from './run-revision-boundary.js';
|
|
34
|
+
import { prepareRunBacklogOrSkip } from './run-backlog.js';
|
|
35
|
+
import { validateRunPresentationEnvelope } from './run-presentation.js';
|
|
36
|
+
|
|
37
|
+
export { sourceRevisionConfirmation } from './run-source-revisions.js';
|
|
38
|
+
|
|
39
|
+
const revisionError = (reason, recovery = "Inspect the exact current run, correct the facts and prepare a fresh reviewed preview.") => Object.assign(Error(reason), { revision_reason: reason, recovery });
|
|
40
|
+
const nonempty = value => typeof value === "string" && value.trim().length > 0 && value.length <= 4096;
|
|
41
|
+
function validateRevisionIdentity({ runId, operationId, revisionId }) {
|
|
42
|
+
if (!RUN_ID_PATTERN.test(runId ?? "") || ![operationId, revisionId].every(value => typeof value === "string" && REVISION_ID_PATTERN.test(value)))
|
|
43
|
+
throw revisionError("revision_input_invalid");
|
|
44
|
+
}
|
|
45
|
+
function withRevisionLocks(root, input, work) {
|
|
46
|
+
validateRevisionIdentity(input);
|
|
47
|
+
const paths = [`.agdf/control/runs/${input.runId}/RUN_STATE.md`, ".agdf/control/MASTER_BACKLOG.md"];
|
|
48
|
+
const check = () => {
|
|
49
|
+
if (paths.some(path => hasSymlinkComponent(root, path) || containedRegularFile(root, path).status !== "valid"))
|
|
50
|
+
throw revisionError("revision_path_invalid");
|
|
51
|
+
};
|
|
52
|
+
check();
|
|
53
|
+
return withOwnedFileLock(runPath(root, input.runId), () => withOwnedFileLock(join(root, paths[1]), () => { check(); return work(); }));
|
|
54
|
+
}
|
|
55
|
+
const commandResult = (runId, work) => {
|
|
56
|
+
try { return work(); } catch (error) {
|
|
57
|
+
if (error.revision_reason) return { ...rejected(runId, error.revision_reason, { recovery: error.recovery }), authorizes: false,
|
|
58
|
+
...(error.revision_reason === "run_step_recovery_required" ? { outcome: "recovery_required" } : {}) };
|
|
59
|
+
const result = guardedWrite(runId, () => { throw error; });
|
|
60
|
+
return { ...result.rejection, authorizes: false,
|
|
61
|
+
...(result.rejection.reason === "run_step_recovery_required" ? { outcome: "recovery_required" } : {}) };
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
function collectRunRevisionClosure(root, run, state, operationId, approvedGates, extra = []) {
|
|
66
|
+
const runId = run.meta.run_id;
|
|
67
|
+
const pendingPaths = pendingArtefactPaths(run.content);
|
|
68
|
+
const paths = [...listedArtefactPaths(run.content).filter(path => !pendingPaths.includes(path) || existsSync(join(root, path))),
|
|
69
|
+
`.agdf/control/runs/${runId}/RUN_STATE.md`, ...extra];
|
|
70
|
+
for (const binding of readArtefactBindings(run.content).active) paths.push(binding.review.path, binding.destination.path, binding.source.path);
|
|
71
|
+
// Closure includes the exact presentation envelopes and current reviewed mapping proofs.
|
|
72
|
+
for (const gate of approvedGates) {
|
|
73
|
+
const id = state.approvals.get(gate).evidence.match(/presentation ([0-9a-f-]{36}) /u)?.[1];
|
|
74
|
+
if (!id) throw revisionError("approved_source_proof_invalid");
|
|
75
|
+
paths.push(`.agdf/control/runs/${runId}/presentations/${id}.json`);
|
|
76
|
+
}
|
|
77
|
+
// Pending and superseded decision presentations remain exact historical evidence
|
|
78
|
+
// too. In particular an unapproved SD card must not be lost on early UR reopening.
|
|
79
|
+
const presentations = `.agdf/control/runs/${runId}/presentations`;
|
|
80
|
+
if (hasSymlinkComponent(root, presentations)) throw revisionError("revision_path_invalid");
|
|
81
|
+
for (const name of readdirSync(join(root, presentations))) {
|
|
82
|
+
if (!name.endsWith(".json") || !REVISION_ID_PATTERN.test(name.slice(0, -5))) continue;
|
|
83
|
+
const path = `${presentations}/${name}`;
|
|
84
|
+
paths.push(path);
|
|
85
|
+
let envelope;
|
|
86
|
+
try { envelope = JSON.parse(readHistoryBytes(root, path).toString('utf8')); } catch { continue; }
|
|
87
|
+
if ([3, 4, 5].includes(envelope.record?.schema_version)) {
|
|
88
|
+
const record = envelope.record;
|
|
89
|
+
if (!APPROVAL_GATES.includes(record.gate) || validateRunPresentationEnvelope(envelope,
|
|
90
|
+
{ runId, gate: record.gate, revisionId: record.revision_id, presentationId: name.slice(0, -5) }).reason) throw revisionError('presentation_binding_invalid');
|
|
91
|
+
const documentPath = `${presentations}/${record.presentation_id}.document`, bytes = readHistoryBytes(root, documentPath);
|
|
92
|
+
if (bytes.length !== record.document_bytes || byteDigest(bytes) !== record.document_digest) throw revisionError('presentation_document_digest_mismatch');
|
|
93
|
+
paths.push(documentPath);
|
|
94
|
+
if (record.schema_version === 5) {
|
|
95
|
+
for (const file of [...record.preview_review.files, ...record.preview_review.chunks]) {
|
|
96
|
+
const bytes = readHistoryBytes(root, file.snapshot);
|
|
97
|
+
if (bytes.length !== file.bytes || byteDigest(bytes) !== file.digest) throw revisionError('preview_snapshot_changed');
|
|
98
|
+
paths.push(file.snapshot);
|
|
99
|
+
if (file.path) {
|
|
100
|
+
const original = readHistoryBytes(root, file.path);
|
|
101
|
+
if (original.length !== file.bytes || byteDigest(original) !== file.digest) throw revisionError('preview_file_changed');
|
|
102
|
+
paths.push(file.path);
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
return collectRevisionHistory(root, runId, operationId, paths);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
function prepareSourceRevision(root, input) {
|
|
112
|
+
const { runId, revisionId, operationId, sourceGate, evidence } = input;
|
|
113
|
+
validateRevisionIdentity(input);
|
|
114
|
+
if (!REVISION_ID_PATTERN.test(operationId ?? "") || !SOURCE_GATES.includes(sourceGate)) throw revisionError("revision_input_invalid");
|
|
115
|
+
if (pendingRunStepIds(root).length) throw revisionError("run_step_recovery_required");
|
|
116
|
+
const run = readRun(root, runId);
|
|
117
|
+
if (run.rejection) throw revisionError(run.rejection.reason);
|
|
118
|
+
assertRunOperationIdentity(root, run, operationId, "source_revision.apply");
|
|
119
|
+
if (run.meta.revision_id !== revisionId) throw revisionError("stale_revision");
|
|
120
|
+
if (runSealState(root, run.content).status !== "valid") throw revisionError("seal_invalid");
|
|
121
|
+
const state = { ...prepareRunContentState(root, run.content, run.path), meta: run.meta };
|
|
122
|
+
const proposal = readContainedJson(root, evidence), requestDigest = digest(canonicalJson(proposal));
|
|
123
|
+
if (!['1', '2'].includes(proposal.schema_version)) throw revisionError('revision_version_unsupported');
|
|
124
|
+
const expanded = proposal.schema_version === '2';
|
|
125
|
+
if (expanded && !input.commandContext) throw revisionError('revision_command_required', 'Use the existing bound source_revision command with exact proposal and deliberate confirmation.');
|
|
126
|
+
const boundary = sourceRevisionBoundary(state, sourceGate, expanded ? 2 : 1);
|
|
127
|
+
if (!boundary) throw revisionError("late_revision_boundary_invalid", expanded
|
|
128
|
+
? 'Use an actually approved source in the declared active structured pre-UAT matrix; deliberate UAT, completed OR, integrity or lifecycle blockers prohibit revision.'
|
|
129
|
+
: "Use active structured CD+Tests, or revise UR at SD with approved UR/PRD and linked draft SD before TP or implementation. Other lifecycle cases are unsupported.");
|
|
130
|
+
if (!exactApprovedArtefacts(root, state)) throw revisionError("approved_source_proof_invalid");
|
|
131
|
+
const bindings = readArtefactBindings(run.content);
|
|
132
|
+
if (!bindings.valid || !boundary.bindings.every(type => bindings.active.some(row => row.destination.type === type && validateBindingProof(root, row)))) throw revisionError("current_source_binding_invalid");
|
|
133
|
+
const sources = boundary.sources.map(type => ({ type, path: state.artefacts.get(type)?.path, digest: artefactFileDigest(root, state.artefacts.get(type)?.path) }));
|
|
134
|
+
if (sources.some(row => row.path !== `.agdf/control/artefacts/${runId}/${row.type}.md`
|
|
135
|
+
|| boundary.approved.includes(row.type) && state.approvals.get(row.type)?.status !== "approved")) throw revisionError("approved_source_invalid");
|
|
136
|
+
if (input.commandContext && input.proposalBinding?.path !== evidence) throw revisionError('revision_source_binding_invalid');
|
|
137
|
+
const boundProposal = input.proposalBinding ? readOperationSource(root, runId, input.proposalBinding) : null;
|
|
138
|
+
if (!exactObject(proposal, expanded ? REVISION_PROPOSAL_V2_FIELDS : REVISION_PROPOSAL_FIELDS)
|
|
139
|
+
|| proposal.target_id !== resolveControlCommandTarget(root).target_id
|
|
140
|
+
|| proposal.run_id !== runId || proposal.expected_revision_id !== revisionId || proposal.operation_id !== operationId
|
|
141
|
+
|| proposal.source_gate !== sourceGate || !nonempty(proposal.reason) || !nonempty(proposal.intended_change)
|
|
142
|
+
|| canonicalJson(proposal.sources) !== canonicalJson(sources)) throw revisionError("revision_proposal_invalid");
|
|
143
|
+
const assessment = proposal.impact_assessment, index = SOURCE_GATES.indexOf(sourceGate);
|
|
144
|
+
if (!exactObject(assessment, REVISION_IMPACT_FIELDS)
|
|
145
|
+
|| !nonempty(assessment.reviewer) || assessment.earliest_source !== sourceGate || !nonempty(assessment.implementation_evidence)
|
|
146
|
+
|| !Array.isArray(assessment.unresolved) || assessment.unresolved.length
|
|
147
|
+
|| !Array.isArray(assessment.upstream) || assessment.upstream.length !== index
|
|
148
|
+
|| !assessment.upstream.every((row, i) => exactObject(row, REVISION_UPSTREAM_FIELDS)
|
|
149
|
+
&& nonempty(row.rationale) && canonicalJson({ type: row.type, path: row.path, digest: row.digest }) === canonicalJson(sources[i]))) throw revisionError("source_impact_unresolved", "Resolve the earliest changed source and unchanged upstream rationale with its owner; then regenerate the proposal.");
|
|
150
|
+
const analyticalTypes = ["Brownfield Review", "UX Intent Definition"].filter(type => state.artefacts.get(type)?.path);
|
|
151
|
+
if (!Array.isArray(assessment.analyses) || assessment.analyses.length !== analyticalTypes.length
|
|
152
|
+
|| !assessment.analyses.every((row, i) => exactObject(row, REVISION_ANALYSIS_FIELDS)
|
|
153
|
+
&& row.type === analyticalTypes[i] && row.path === state.artefacts.get(row.type).path
|
|
154
|
+
&& row.digest === artefactFileDigest(root, row.path) && nonempty(row.reason)
|
|
155
|
+
&& ["retain", "reassess"].includes(row.disposition) && (sourceGate !== "UR" || row.disposition === "reassess"))) throw revisionError("analysis_applicability_unresolved");
|
|
156
|
+
const readArtefact = path => { try { return readHistoryBytes(root, path).toString('utf8'); } catch { return undefined; } };
|
|
157
|
+
if (expanded && !validExpandedRevisionProof(proposal, state, readArtefact, boundary.initiating_phase))
|
|
158
|
+
throw revisionError('revision_impact_proof_invalid', 'Bind concrete changed statements, earliest source, actual phase and every exact quality record; unknown or affected associations require reassessment.');
|
|
159
|
+
const affected = SOURCE_GATES.slice(index);
|
|
160
|
+
const qualityPaths = expanded ? proposal.quality_assessment.map(row => row.record.path).filter(Boolean) : [];
|
|
161
|
+
const history = collectRunRevisionClosure(root, run, state, operationId, boundary.approved, [evidence, ...qualityPaths]);
|
|
162
|
+
const impact = sourceRevisionImpact(proposal, bindings.active);
|
|
163
|
+
const preview = { schema_version: expanded ? "2" : "1", target_id: proposal.target_id, run_id: runId, expected_revision_id: revisionId,
|
|
164
|
+
operation_id: operationId, request_digest: requestDigest, reason: proposal.reason, intended_change: proposal.intended_change,
|
|
165
|
+
sources, impact, archive_digest: history.digest, current_run_digest: byteDigest(Buffer.from(run.content)) };
|
|
166
|
+
return { run, state, proposal, requestDigest, preview, previewDigest: digest(canonicalJson(preview)), history, affected, boundProposal };
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
export function previewSourceRevision(root, input) {
|
|
170
|
+
return commandResult(input.runId, () => { const work = prepareSourceRevision(root, input);
|
|
171
|
+
return { outcome: "preview", authority: "proposed_only", authorizes: false, ...work.preview, preview_digest: work.previewDigest,
|
|
172
|
+
confirmation_selector: sourceRevisionConfirmation({ ...input, previewDigest: work.previewDigest }),
|
|
173
|
+
next_action: "Review the bound impact; explicitly apply it or cancel without mutation." }; });
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
function revisedRun(root, work, receipt) {
|
|
177
|
+
let next = work.run.content;
|
|
178
|
+
for (const gate of work.affected) {
|
|
179
|
+
for (const section of ["Approvals", "Gate Checklist"]) next = replaceGateRow(next, section, gate, cells => [gate, "missing", "", ...cells.slice(3)]);
|
|
180
|
+
next = upsertTableRow(next, "Artefacts", 0, gate, [gate, "", "missing", "Previous content is historical; fresh recording and approval required"]);
|
|
181
|
+
next = removeTableRows(next, "Artefact Chain", 0, gate) ?? next;
|
|
182
|
+
}
|
|
183
|
+
for (const id of receipt.invalidated_bindings) next = removeTableRows(next, "Artefacts", 0, `Binding proof ${id}`) ?? next;
|
|
184
|
+
const invalidAnalyses = [...new Set([...receipt.analyses.filter(row => row.disposition === "reassess").map(row => row.type),
|
|
185
|
+
...(receipt.source_gate === "UR" ? ["Brownfield Review"] : [])])];
|
|
186
|
+
for (const type of [...invalidAnalyses, "Brownfield Analysis", "CD+Tests", "CR", "Code Review", "TP Review", "Clean Review", "Clean Implementation Review", "QA"]) {
|
|
187
|
+
if (work.state.artefacts.has(type) || ["Brownfield Analysis", "CD+Tests", "CR"].includes(type))
|
|
188
|
+
next = upsertTableRow(next, "Artefacts", 0, type, [type, "", "missing", "Renewed evidence required after source revision"]);
|
|
189
|
+
}
|
|
190
|
+
if (receipt.schema_version === '3') {
|
|
191
|
+
for (const gate of ['QA', 'UAT']) {
|
|
192
|
+
for (const section of ['Approvals', 'Gate Checklist']) next = replaceGateRow(next, section, gate, cells => [gate, 'missing', '', ...cells.slice(3)]);
|
|
193
|
+
if (work.state.artefacts.has(gate)) next = upsertTableRow(next, 'Artefacts', 0, gate, [gate, '', 'missing', 'Renewed decision and evidence required after source revision']);
|
|
194
|
+
}
|
|
195
|
+
next = removeTableRows(next, 'Artefact Chain', 0, 'QA_REPORT') ?? next;
|
|
196
|
+
next = removeTableRows(next, 'Artefact Chain', 0, 'QA') ?? next;
|
|
197
|
+
next = removeTableRows(next, 'Artefact Chain', 0, 'UAT') ?? next;
|
|
198
|
+
next = removeTableRows(next, 'Artefacts', 0, 'QA_REPORT') ?? next;
|
|
199
|
+
}
|
|
200
|
+
if (invalidAnalyses.includes("Brownfield Review")) {
|
|
201
|
+
const heading = firstSection(next.split("\n"), "Mode/Slice Decision") ? "Mode/Slice Decision" : "Mode / Slice Decision";
|
|
202
|
+
next = replaceSectionScalar(next, heading, "decision", "undecided");
|
|
203
|
+
if (!next) throw revisionError("run_layout_unsupported");
|
|
204
|
+
next = replaceSectionScalar(next, heading, "scope_reason", "Source revision requires a fresh analytical route");
|
|
205
|
+
if (!next) throw revisionError("run_layout_unsupported");
|
|
206
|
+
next = replaceSectionScalar(next, heading, "evidence", receipt.archive.path);
|
|
207
|
+
}
|
|
208
|
+
if (!next) throw revisionError("run_layout_unsupported");
|
|
209
|
+
next = appendSourceRevision(next, receipt);
|
|
210
|
+
const after = transitionDecisionForRunState(prepareRunContentState(root, next, work.run.path));
|
|
211
|
+
// Later-source reassessment can be the required internal next step before its gate.
|
|
212
|
+
next = replaceFirstScalar(next, "current_gate", after.current_gate) ?? next;
|
|
213
|
+
next = replaceFirstScalar(next, "next_allowed_action", after.next_allowed_action) ?? next;
|
|
214
|
+
for (const [question, answer] of [["What is known?", `Source revision reopened ${receipt.source_gate}; previous evidence is historical.`],
|
|
215
|
+
["What is approved?", work.preview.impact.retained.map(gate => `Approval: ${gate}`).join(", ") || "Nothing yet."],
|
|
216
|
+
["What is missing?", after.missing_approval], ["What is the next allowed action?", after.next_allowed_action],
|
|
217
|
+
["What is explicitly forbidden right now?", after.forbidden.join("; ")]]) next = upsertTableRow(next, "Current Control State", 0, question, [question, answer]) ?? next;
|
|
218
|
+
return { next, after };
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
export function inspectSourceRevision(root, { runId, operationId, revisionId }) {
|
|
222
|
+
return commandResult(runId, () => {
|
|
223
|
+
validateRevisionIdentity({ runId, operationId, revisionId });
|
|
224
|
+
const pending = pendingRunStepPath(root, runId), content = readHistoryBytes(root, `.agdf/control/runs/${runId}/RUN_STATE.md`).toString("utf8");
|
|
225
|
+
const parsed = parseRunState(content, runId);
|
|
226
|
+
if (!parsed.valid || !REVISION_ID_PATTERN.test(operationId ?? "")) throw revisionError("revision_input_invalid");
|
|
227
|
+
if (existsSync(pending)) {
|
|
228
|
+
const journal = readPendingSourceRevisionJournal(root, runId);
|
|
229
|
+
if (journal.schema_version !== 2 || journal.operation_id !== operationId
|
|
230
|
+
|| journal.target_id !== resolveControlCommandTarget(root).target_id) throw revisionError("revision_recovery_binding_invalid");
|
|
231
|
+
return { outcome: "recovery_required", run_id: runId, operation_id: operationId, revision_id: parsed.meta.revision_id, authorizes: false,
|
|
232
|
+
next_action: "Inspect the exact pending operation and use explicit recovery; do not blindly repeat apply." };
|
|
233
|
+
}
|
|
234
|
+
if (runSealState(root, content).status !== "valid") throw revisionError("seal_invalid");
|
|
235
|
+
const row = readSourceRevisions(content).receipts.find(item => item.operation_id === operationId);
|
|
236
|
+
return { outcome: row ? "historical" : "not_found", run_id: runId, revision_id: parsed.meta.revision_id,
|
|
237
|
+
stale_observation: revisionId !== parsed.meta.revision_id, authorizes: false,
|
|
238
|
+
...(row ? { history: inspectRevisionHistory(root, row) } : {}) };
|
|
239
|
+
});
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
export function applySourceRevision(root, input, { afterWrite } = {}) {
|
|
243
|
+
return commandResult(input.runId, () => withRevisionLocks(root, input, () => {
|
|
244
|
+
const { runId, revisionId, operationId } = input;
|
|
245
|
+
if (pendingRunStepIds(root).length) throw revisionError("run_step_recovery_required");
|
|
246
|
+
const run = readRun(root, runId); if (run.rejection) throw revisionError(run.rejection.reason);
|
|
247
|
+
const prior = readSourceRevisions(run.content).receipts.find(row => row.operation_id === operationId);
|
|
248
|
+
if (prior) {
|
|
249
|
+
if (runSealState(root, run.content).status !== "valid") throw revisionError("seal_invalid");
|
|
250
|
+
if (input.commandContext) {
|
|
251
|
+
if (!['2', '3'].includes(prior.schema_version) || prior.command_digest !== input.commandContext.request_digest) throw revisionError('revision_operation_conflict');
|
|
252
|
+
return { outcome: 'replayed', authorizes: false, historical_effect: true, receipt: prior, run_id: runId,
|
|
253
|
+
operation_id: operationId, resulting_revision_id: prior.resulting_revision_id, current_revision_id: run.meta.revision_id };
|
|
254
|
+
}
|
|
255
|
+
const proposal = readContainedJson(root, input.evidence);
|
|
256
|
+
if (prior.request_digest !== digest(canonicalJson(proposal)) || prior.preview_digest !== input.previewDigest
|
|
257
|
+
|| prior.previous_revision_id !== revisionId || prior.source_gate !== input.sourceGate
|
|
258
|
+
|| prior.target_id !== resolveControlCommandTarget(root).target_id) throw revisionError("revision_operation_conflict");
|
|
259
|
+
return { outcome: "replayed", authorizes: false, run_id: runId, operation_id: operationId,
|
|
260
|
+
resulting_revision_id: prior.resulting_revision_id, current_revision_id: run.meta.revision_id, historical_effect: true };
|
|
261
|
+
}
|
|
262
|
+
const work = prepareSourceRevision(root, input);
|
|
263
|
+
if (input.previewDigest !== work.previewDigest) throw revisionError("revision_preview_stale");
|
|
264
|
+
if (input.commandContext && input.confirmation !== sourceRevisionConfirmation(input)) throw revisionError('confirmation_required', 'Obtain a deliberate confirmation of the exact current preview selector; host tool consent alone is insufficient.');
|
|
265
|
+
const receipt = { schema_version: work.proposal.schema_version === '2' ? '3' : input.commandContext ? '2' : "1", operation_id: operationId, target_id: work.proposal.target_id, run_id: runId,
|
|
266
|
+
source_gate: input.sourceGate, request_digest: work.requestDigest, preview_digest: work.previewDigest,
|
|
267
|
+
previous_revision_id: revisionId, resulting_revision_id: randomUUID(), revision: Number(run.meta.revision) + 1,
|
|
268
|
+
invalidated_bindings: work.preview.impact.invalidated_bindings, analyses: work.proposal.impact_assessment.analyses,
|
|
269
|
+
retained_sources: work.proposal.impact_assessment.upstream,
|
|
270
|
+
archive: { path: `${revisionHistoryPrefix(runId, operationId)}manifest.json`, digest: work.history.digest }, reason: work.proposal.reason };
|
|
271
|
+
if (input.commandContext) Object.assign(receipt, { command_digest: input.commandContext.request_digest, confirmation_digest: digest(input.confirmation),
|
|
272
|
+
proposal_reference: input.proposalBinding, producer: { contract: 'run-command/1', package_version: input.packageVersion }, assurance: COOPERATIVE_ASSURANCE });
|
|
273
|
+
if (receipt.schema_version === '3') Object.assign(receipt, { policy_version: 2, initiating_phase: work.proposal.initiating_phase,
|
|
274
|
+
impact_digest: digest(canonicalJson(work.preview.impact)), quality_digest: digest(canonicalJson(work.proposal.quality_assessment)) });
|
|
275
|
+
const { next, after } = revisedRun(root, work, receipt);
|
|
276
|
+
const backlogPath = join(root, ".agdf/control/MASTER_BACKLOG.md");
|
|
277
|
+
if (hasSymlinkComponent(root, ".agdf/control/MASTER_BACKLOG.md") || containedRegularFile(root, ".agdf/control/MASTER_BACKLOG.md").status !== "valid") throw revisionError("backlog_path_invalid");
|
|
278
|
+
const oldBacklog = readFileSync(backlogPath, "utf8");
|
|
279
|
+
const lines = oldBacklog.split("\n"), section = firstSection(lines, "Active Backlog");
|
|
280
|
+
const priorRow = section && tableLineIndexes(lines, section).slice(2).map(i => tableCells(lines[i])).find(cells => cells[1]?.replaceAll("`", "").trim() === runId);
|
|
281
|
+
const summary = runWorkSummary(root, next, run.path, after);
|
|
282
|
+
let nextBacklog = upsertTableRow(oldBacklog, "Active Backlog", 1, priorRow?.[1] ?? runId, [priorRow?.[0] || "P1", priorRow?.[1] ?? runId, priorRow?.[2] || runId, backlogStatusForSummary(summary, after),
|
|
283
|
+
SOURCE_GATES.filter(type => work.preview.impact.retained.includes(type)).map(type => `[${type}](artefacts/${runId}/${type}.md)`).join(" · "),
|
|
284
|
+
`[Revision history](${receipt.archive.path.slice(".agdf/control/".length)})`, summary.display_action]);
|
|
285
|
+
if (!nextBacklog) throw revisionError("backlog_layout_unsupported");
|
|
286
|
+
nextBacklog = recordBacklogSummary(root, nextBacklog, runId, "Active Backlog", summary, receipt.resulting_revision_id);
|
|
287
|
+
const written = commitRunStepLocked(root, { runId, runPath: run.path, content: next, revisionId, expectedContent: run.content,
|
|
288
|
+
backlog: { old: oldBacklog, next: nextBacklog }, or: null, history: work.history, afterWrite,
|
|
289
|
+
nextRevisionId: receipt.resulting_revision_id, writeOptions: { allowApprovalChange: true, appendedRevision: receipt,
|
|
290
|
+
validateBeforeWrite: () => { work.boundProposal?.validate(); assertSummarySources(root, summary); const checked = prepareSourceRevisionIgnoringPending(root, input); if (checked.previewDigest !== work.previewDigest) throw Error("AGDF_STALE_RUN_REVISION"); } } });
|
|
291
|
+
return { outcome: "reopened", authorizes: false, run_id: runId, operation_id: operationId, gate: after.current_gate,
|
|
292
|
+
revision_id: written.meta.revision_id, revision: written.meta.revision, impact: work.preview.impact, next_action: after.next_allowed_action };
|
|
293
|
+
}));
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
function prepareSourceRevisionIgnoringPending(root, input) {
|
|
297
|
+
// The exact pending operation is owned by the caller under both locks. Revalidation reads
|
|
298
|
+
// the unchanged pre-commit state without allowing ordinary readRun to bypass a pending write.
|
|
299
|
+
const pending = readPendingSourceRevisionJournal(root, input.runId);
|
|
300
|
+
if (pending.schema_version !== 2 || pending.operation_id !== input.operationId) throw Error("AGDF_RUN_STEP_RECOVERY_REQUIRED");
|
|
301
|
+
const proposal = readContainedJson(root, input.evidence);
|
|
302
|
+
const text = readHistoryBytes(root, `.agdf/control/runs/${input.runId}/RUN_STATE.md`).toString("utf8");
|
|
303
|
+
if (parseRunState(text).meta.revision_id !== input.revisionId || runSealState(root, text).status !== "valid") throw Error("AGDF_STALE_RUN_REVISION");
|
|
304
|
+
const paths = readContainedJson(root, pending.archive.path).files;
|
|
305
|
+
if (paths.some(row => byteDigest(readHistoryBytes(root, row.path)) !== row.digest)) throw Error("AGDF_STALE_RUN_REVISION");
|
|
306
|
+
return { previewDigest: digest(canonicalJson(proposal)) === pending.request_digest ? pending.preview_digest : null };
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
export function recoverSourceRevision(root, input) {
|
|
310
|
+
return commandResult(input.runId, () => withRevisionLocks(root, input, () => {
|
|
311
|
+
const path = pendingRunStepPath(root, input.runId);
|
|
312
|
+
if (!existsSync(path)) {
|
|
313
|
+
const inspected = inspectSourceRevision(root, input);
|
|
314
|
+
return inspected.outcome === "historical" ? { ...inspected, outcome: "recovered", status: "already_completed" } : inspected;
|
|
315
|
+
}
|
|
316
|
+
const pending = readPendingSourceRevisionJournal(root, input.runId);
|
|
317
|
+
if (pending.schema_version !== 2 || pending.operation_id !== input.operationId
|
|
318
|
+
|| pending.target_id !== resolveControlCommandTarget(root).target_id
|
|
319
|
+
|| ![pending.old_revision_id, pending.next_revision_id].includes(input.revisionId)) throw revisionError("revision_recovery_binding_invalid");
|
|
320
|
+
if (input.pendingDigest) {
|
|
321
|
+
const current = parseRunState(readHistoryBytes(root, `.agdf/control/runs/${input.runId}/RUN_STATE.md`).toString('utf8'));
|
|
322
|
+
if (!current.valid || current.meta.revision_id !== input.revisionId || digest(canonicalJson(pending)) !== input.pendingDigest
|
|
323
|
+
|| input.recoveryRevisionId !== input.revisionId) throw revisionError('revision_recovery_binding_invalid');
|
|
324
|
+
if (current.meta.revision_id === pending.next_revision_id) {
|
|
325
|
+
// Once the Run committed, its sealed receipt owns the effect. The proposal
|
|
326
|
+
// is mutable authoring input and cannot veto forward backlog recovery.
|
|
327
|
+
const receipt = readSourceRevisions(current.content).receipts.find(row => row.operation_id === input.operationId);
|
|
328
|
+
if (!['2', '3'].includes(receipt?.schema_version) || receipt.source_gate !== input.sourceGate
|
|
329
|
+
|| canonicalJson(receipt.proposal_reference) !== canonicalJson(input.proposalBinding)
|
|
330
|
+
|| receipt.request_digest !== pending.request_digest || receipt.preview_digest !== pending.preview_digest) throw revisionError('revision_recovery_binding_invalid');
|
|
331
|
+
} else {
|
|
332
|
+
const source = readOperationSource(root, input.runId, input.proposalBinding), proposal = JSON.parse(source.content);
|
|
333
|
+
if (digest(canonicalJson(proposal)) !== pending.request_digest || proposal.source_gate !== input.sourceGate) throw revisionError('revision_recovery_binding_invalid');
|
|
334
|
+
}
|
|
335
|
+
}
|
|
336
|
+
return { outcome: "recovered", authorizes: false, run_id: input.runId, ...recoverPendingRunStepLocked(root, input.runId, { sourceRevision: true }) };
|
|
337
|
+
}));
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
function replaceGateRow(text, heading, gate, update) {
|
|
341
|
+
const lines = text.split("\n");
|
|
342
|
+
const section = firstSection(lines, heading);
|
|
343
|
+
if (!section) return text;
|
|
344
|
+
for (const index of tableLineIndexes(lines, section).slice(2)) {
|
|
345
|
+
const cells = tableCells(lines[index]);
|
|
346
|
+
if (cells[0] === gate) lines[index] = tableLine(update(cells));
|
|
347
|
+
}
|
|
348
|
+
return lines.join("\n");
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
// A material product clarification supersedes the exact PRD approval. This deliberately
|
|
352
|
+
// supports only the PRD->SD boundary, before any downstream artefact is linked or approved.
|
|
353
|
+
function earlyPrdReopenCandidate(root, run) {
|
|
354
|
+
const runId = run.meta.run_id;
|
|
355
|
+
const state = prepareRunContentState(root, run.content, run.path);
|
|
356
|
+
if (!earlyPrdRevisionBoundary(state)) {
|
|
357
|
+
return rejected(runId, "prd_revision_boundary_invalid", {
|
|
358
|
+
recovery: "PRD revision is available only at SD before later artefacts are linked or approved.",
|
|
359
|
+
});
|
|
360
|
+
}
|
|
361
|
+
const previousApproval = state.approvals.get("PRD")?.evidence ?? "";
|
|
362
|
+
if (!previousApproval) return rejected(runId, "prd_approval_evidence_missing");
|
|
363
|
+
let next = canonicalRunText(run.content);
|
|
364
|
+
for (const heading of ["Approvals", "Gate Checklist"]) {
|
|
365
|
+
next = replaceGateRow(next, heading, "PRD", (cells) => ["PRD", "missing", "", ...cells.slice(3)]);
|
|
366
|
+
}
|
|
367
|
+
next = replaceGateRow(next, "Artefacts", "PRD", (cells) => ["PRD", cells[1], "draft", ...cells.slice(3)]);
|
|
368
|
+
const withHistory = appendTableRow(next, "Evidence", ["Superseded PRD approval", previousApproval, "Prior PRD revision only; renewed Approval: PRD required", "direct"]);
|
|
369
|
+
if (!withHistory) return rejected(runId, "prd_revision_history_unavailable");
|
|
370
|
+
next = withHistory;
|
|
371
|
+
const afterState = prepareRunContentState(root, next, run.path);
|
|
372
|
+
const after = transitionDecisionForRunState({ ...afterState, content: next });
|
|
373
|
+
if (after.current_gate !== "PRD" || after.missing_approval !== "Approval: PRD") return rejected(runId, "prd_revision_transition_invalid");
|
|
374
|
+
next = replaceFirstScalar(next, "current_gate", "PRD") ?? next;
|
|
375
|
+
next = replaceFirstScalar(next, "next_allowed_action", after.next_allowed_action) ?? next;
|
|
376
|
+
for (const [question, answer] of [
|
|
377
|
+
["What is known?", "The previous PRD approval was superseded; renewed PRD approval is required."],
|
|
378
|
+
["What is approved?", "Approval: UR"],
|
|
379
|
+
["What is missing?", "Exact Approval: PRD for the new revision."],
|
|
380
|
+
["What is the next allowed action?", after.next_allowed_action],
|
|
381
|
+
["What is explicitly forbidden right now?", after.forbidden.join("; ") || "none"],
|
|
382
|
+
]) next = upsertTableRow(next, "Current Control State", 0, question, [question, answer]) ?? next;
|
|
383
|
+
return { text: next, state, after };
|
|
384
|
+
}
|
|
385
|
+
|
|
386
|
+
export function reopenPrdRevision(root, input, { afterWrite = () => {} } = {}) {
|
|
387
|
+
if (!input.commandContext) return reopenPrdRevisionLegacy(root, input);
|
|
388
|
+
return commandResult(input.runId, () => withRevisionLocks(root, input, () => {
|
|
389
|
+
const { runId, revisionId, operationId, commandContext } = input;
|
|
390
|
+
if (commandContext.kind !== 'prd_revision.reopen' || commandContext.operation_id !== operationId
|
|
391
|
+
|| commandContext.target_id !== resolveControlCommandTarget(root).target_id) throw revisionError('revision_input_invalid');
|
|
392
|
+
if (pendingRunStepIds(root).some(id => id !== runId)) throw revisionError('run_step_recovery_required');
|
|
393
|
+
if (existsSync(pendingRunStepPath(root, runId))) {
|
|
394
|
+
const pending = readPendingRunStepJournal(root, runId);
|
|
395
|
+
if (pending.schema_version !== 3 || pending.kind !== commandContext.kind || pending.operation_id !== operationId
|
|
396
|
+
|| pending.target_id !== commandContext.target_id || pending.request_digest !== commandContext.request_digest
|
|
397
|
+
|| pending.old_revision_id !== revisionId) throw revisionError('run_step_recovery_required');
|
|
398
|
+
recoverPendingRunStepLocked(root, runId);
|
|
399
|
+
}
|
|
400
|
+
const run = readRun(root, runId);
|
|
401
|
+
if (run.rejection) throw revisionError(run.rejection.reason);
|
|
402
|
+
assertRunOperationIdentity(root, run, operationId, commandContext.kind);
|
|
403
|
+
const previous = readRunOperations(run.content).receipts.find(row => row.operation_id === operationId);
|
|
404
|
+
if (previous) {
|
|
405
|
+
if (previous.request_digest !== commandContext.request_digest) throw revisionError('operation_payload_conflict');
|
|
406
|
+
return { schema_version: '1', outcome: 'replayed', run_id: runId, receipt: previous, historical_effect: true, authorizes: false };
|
|
407
|
+
}
|
|
408
|
+
if (run.meta.revision_id !== revisionId) throw revisionError('stale_revision');
|
|
409
|
+
if (runSealState(root, run.content).status !== 'valid') throw revisionError('seal_invalid');
|
|
410
|
+
const prepared = earlyPrdReopenCandidate(root, run);
|
|
411
|
+
if (prepared.outcome === 'rejected') return prepared;
|
|
412
|
+
const prd = prepared.state.artefacts.get('PRD');
|
|
413
|
+
if (input.prdBinding?.path !== prd?.path || input.prdBinding.digest !== artefactFileDigest(root, prd.path)
|
|
414
|
+
|| !exactApprovedArtefacts(root, prepared.state)) throw revisionError('approved_source_proof_invalid');
|
|
415
|
+
const boundPrd = readOperationSource(root, runId, input.prdBinding);
|
|
416
|
+
const confirmation = earlyPrdConfirmation(runId, revisionId, operationId, input.prdBinding.digest);
|
|
417
|
+
if (input.confirmation !== confirmation) return rejected(runId, 'revision_confirmation_required', { confirmation_selector: confirmation });
|
|
418
|
+
const history = collectRunRevisionClosure(root, run, prepared.state, operationId, ['UR', 'PRD']);
|
|
419
|
+
const nextRevisionId = randomUUID();
|
|
420
|
+
const receipt = operationReceipt(root, run, commandContext, nextRevisionId, { prd: input.prdBinding,
|
|
421
|
+
archive: { path: `${revisionHistoryPrefix(runId, operationId)}manifest.json`, digest: history.digest }, confirmation_digest: digest(confirmation) }, input.packageVersion ?? '0.14.5');
|
|
422
|
+
const next = appendRunOperation(prepared.text, receipt);
|
|
423
|
+
const plan = prepareRunBacklogOrSkip(root, runId, next, run.path, nextRevisionId);
|
|
424
|
+
const validate = () => {
|
|
425
|
+
boundPrd.validate();
|
|
426
|
+
if (!exactApprovedArtefacts(root, prepared.state) || history.files.some(row => byteDigest(readHistoryBytes(root, row.path)) !== row.digest)) throw revisionError('stale_revision');
|
|
427
|
+
if (plan.summary) assertSummarySources(root, plan.summary);
|
|
428
|
+
};
|
|
429
|
+
validate();
|
|
430
|
+
const written = commitRunStepLocked(root, { runId, runPath: run.path, content: next, revisionId, expectedContent: run.content,
|
|
431
|
+
backlog: plan.update, or: null, nextRevisionId, operationContext: commandContext, history, afterWrite,
|
|
432
|
+
writeOptions: { allowApprovalChange: true, appendedOperation: receipt, validateBeforeWrite: validate } });
|
|
433
|
+
return { schema_version: '1', outcome: 'reopened', run_id: runId, gate: 'PRD', receipt, previous_revision_id: revisionId,
|
|
434
|
+
revision_id: written.meta.revision_id, revision: Number(written.meta.revision), authorizes: false };
|
|
435
|
+
}));
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
function reopenPrdRevisionLegacy(root, { runId, revisionId }) {
|
|
439
|
+
const run = readRun(root, runId);
|
|
440
|
+
if (run.rejection) return run.rejection;
|
|
441
|
+
if (run.meta.revision_id !== revisionId) return rejected(runId, "stale_revision");
|
|
442
|
+
if (runSealState(root, run.content).status !== "valid") return rejected(runId, "seal_invalid");
|
|
443
|
+
const prepared = earlyPrdReopenCandidate(root, run);
|
|
444
|
+
if (prepared.outcome === "rejected") return prepared;
|
|
445
|
+
const next = prepared.text;
|
|
446
|
+
const written = guardedWrite(runId, () => writeRunWithBacklog(root, run.path, next, revisionId, {
|
|
447
|
+
allowApprovalChange: true, expectedContent: run.content,
|
|
448
|
+
validateBeforeWrite: () => {
|
|
449
|
+
// Recomputes the artefact digests on disk under the write lock.
|
|
450
|
+
if (runSealState(root, run.content).status !== "valid") throw new Error("AGDF_STALE_RUN_REVISION");
|
|
451
|
+
},
|
|
452
|
+
}));
|
|
453
|
+
if (written.rejection) return written.rejection;
|
|
454
|
+
return Object.freeze({ schema_version: "1", outcome: "reopened", run_id: runId, gate: "PRD",
|
|
455
|
+
previous_revision_id: revisionId, revision: written.state.meta.revision,
|
|
456
|
+
revision_id: written.state.meta.revision_id,
|
|
457
|
+
next_action: "Revise the PRD, record it with run-update, then prepare a new run-present. A new deliberate Approval: PRD is required." });
|
|
458
|
+
}
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import { canonicalRunText } from "./run-text.js";
|
|
2
|
+
export { canonicalRunText } from "./run-text.js";
|
|
3
|
+
import { APPROVAL_GATES } from "./run-identity.js";
|
|
4
|
+
import { approvalOperationsRecord } from "./approval-operations.js";
|
|
5
|
+
import { readSourceRevisions } from "./run-source-revisions.js";
|
|
6
|
+
import { canonicalJson } from "./approval-command-contract.js";
|
|
7
|
+
import { createHash } from "node:crypto";
|
|
8
|
+
import { readFileSync, memoizeControlRead } from "../control-read/fs.js";
|
|
9
|
+
import { basename, dirname } from "node:path";
|
|
10
|
+
import { parseArtefactPathCell, scalarFields, sectionTableRows } from "./run-state-document.js";
|
|
11
|
+
import { containedRegularFile, isSafeControlRelativePath } from "./contained-file.js";
|
|
12
|
+
|
|
13
|
+
// The seal makes unrecorded edits visible: content_seal covers the run state and every file listed
|
|
14
|
+
// under Artefacts, approval_seal covers only the recorded gate approvals. It detects changes made
|
|
15
|
+
// outside run-update, run-revise and run-approve; it is not a signature and does not resist deliberate tampering.
|
|
16
|
+
export { APPROVAL_GATES } from "./run-identity.js";
|
|
17
|
+
export const APPROVAL_SECTIONS = Object.freeze(["Approvals", "Gate Checklist"]);
|
|
18
|
+
const REVISION_META_LINE = /^- (?:revision|revision_id|content_seal|approval_seal):/u;
|
|
19
|
+
const SEAL_META_LINE = /^- (?:content_seal|approval_seal):/u;
|
|
20
|
+
|
|
21
|
+
const sha256 = (text) => `sha256:${createHash("sha256").update(text, "utf8").digest("hex")}`;
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
function runMetaRange(lines) {
|
|
25
|
+
const start = lines.findIndex((line) => /^## Run Meta\s*$/u.test(line));
|
|
26
|
+
if (start < 0) return null;
|
|
27
|
+
let end = start + 1;
|
|
28
|
+
while (end < lines.length && !lines[end].startsWith("## ")) end += 1;
|
|
29
|
+
return { start, end };
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
function withoutMetaLines(text, pattern) {
|
|
33
|
+
const lines = text.split("\n");
|
|
34
|
+
const range = runMetaRange(lines);
|
|
35
|
+
if (!range) return text;
|
|
36
|
+
return [
|
|
37
|
+
...lines.slice(0, range.start + 1),
|
|
38
|
+
...lines.slice(range.start + 1, range.end).filter((line) => !pattern.test(line)),
|
|
39
|
+
...lines.slice(range.end),
|
|
40
|
+
].join("\n");
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export function runRootFromStatePath(path) {
|
|
44
|
+
const runsDirectory = dirname(dirname(path));
|
|
45
|
+
const controlDirectory = dirname(runsDirectory);
|
|
46
|
+
const agdfDirectory = dirname(controlDirectory);
|
|
47
|
+
if (basename(path) !== "RUN_STATE.md" || basename(runsDirectory) !== "runs"
|
|
48
|
+
|| basename(controlDirectory) !== "control" || basename(agdfDirectory) !== ".agdf") {
|
|
49
|
+
throw new Error("AGDF_RUN_PATH_INVALID");
|
|
50
|
+
}
|
|
51
|
+
return dirname(agdfDirectory);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function artefactFileDigest(root, rawPath) {
|
|
55
|
+
return memoizeControlRead(`artefactDigest:${root}:${rawPath}`, () => capturedArtefactDigest(root, rawPath));
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function capturedArtefactDigest(root, rawPath) {
|
|
59
|
+
const path = String(rawPath ?? "").trim();
|
|
60
|
+
const result = containedRegularFile(root, path);
|
|
61
|
+
if (result.status !== "valid") return result.status === "missing" ? "missing" : "unresolved";
|
|
62
|
+
return sha256(canonicalRunText(readFileSync(result.path, "utf8")));
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function listedArtefactPaths(text) {
|
|
66
|
+
const paths = [];
|
|
67
|
+
for (const [, cell = ""] of sectionTableRows(text, "Artefacts")) {
|
|
68
|
+
const parsed = parseArtefactPathCell(cell);
|
|
69
|
+
const path = parsed.format === "invalid" ? parsed.raw : parsed.path;
|
|
70
|
+
if (!path || /^path$/iu.test(path) || paths.includes(path)) continue;
|
|
71
|
+
paths.push(path);
|
|
72
|
+
}
|
|
73
|
+
return paths;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
// A declared future output is not lost evidence. Keep its path in the seal/snapshot so
|
|
77
|
+
// creating or changing it remains visible; only recovery's existence check may defer it.
|
|
78
|
+
export function pendingArtefactPaths(text) {
|
|
79
|
+
const rows = sectionTableRows(text, "Artefacts");
|
|
80
|
+
const runId = scalarFields(text).values.get("run_id");
|
|
81
|
+
return listedArtefactPaths(text).filter((path) => {
|
|
82
|
+
if (!path.startsWith(`.agdf/control/artefacts/${runId}/`) || !isSafeControlRelativePath(path)) return false;
|
|
83
|
+
const references = rows.filter(([, cell = ""]) => {
|
|
84
|
+
const parsed = parseArtefactPathCell(cell);
|
|
85
|
+
return parsed.format !== "invalid" && parsed.path === path;
|
|
86
|
+
});
|
|
87
|
+
return references.length > 0 && references.every(([, , status = ""]) =>
|
|
88
|
+
["missing", "pending"].includes(status.replace(/^`|`$/gu, "").trim()));
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function approvalRecord(content) {
|
|
93
|
+
const text = canonicalRunText(content);
|
|
94
|
+
const approvals = new Map();
|
|
95
|
+
for (const heading of APPROVAL_SECTIONS) {
|
|
96
|
+
for (const [gate, status = "", evidence = ""] of sectionTableRows(text, heading)) {
|
|
97
|
+
if (APPROVAL_GATES.includes(gate)) {
|
|
98
|
+
approvals.set(gate, [status.replace(/^`|`$/gu, "").trim() || "missing", evidence.trim()]);
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
return APPROVAL_GATES.map((gate) => [gate, ...(approvals.get(gate) ?? ["missing", ""])].join("\t")).join("\n");
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
export function approvalSeal(content) {
|
|
106
|
+
const operations = approvalOperationsRecord(content);
|
|
107
|
+
const revisions = readSourceRevisions(content);
|
|
108
|
+
if (revisions.present) return sha256(["agdf-approval-seal/3", approvalRecord(content), operations ?? "", canonicalJson(revisions.receipts)].join("\n"));
|
|
109
|
+
return sha256(operations === null
|
|
110
|
+
? ["agdf-approval-seal/1", approvalRecord(content)].join("\n")
|
|
111
|
+
: ["agdf-approval-seal/2", approvalRecord(content), operations].join("\n"));
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export function computeRunSeals(root, content, { selfReferenceDigest = "self", artefactDigests = new Map() } = {}) {
|
|
115
|
+
const text = canonicalRunText(content);
|
|
116
|
+
const runId = scalarFields(text).values.get("run_id");
|
|
117
|
+
const selfPath = `.agdf/control/runs/${runId}/RUN_STATE.md`;
|
|
118
|
+
// The run body is already covered above. Hashing its on-disk copy as an artefact creates
|
|
119
|
+
// a circular dependency and invalidates the seal immediately after every atomic write.
|
|
120
|
+
const artefacts = listedArtefactPaths(text).map((path) => `${path}\t${path === selfPath ? selfReferenceDigest : artefactDigests.get(path) ?? artefactFileDigest(root, path)}`);
|
|
121
|
+
return Object.freeze({
|
|
122
|
+
content_seal: sha256(["agdf-run-seal/1", withoutMetaLines(text, REVISION_META_LINE), "\0artefacts", ...artefacts].join("\n")),
|
|
123
|
+
approval_seal: approvalSeal(text),
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export function applyRunSeals(content, seals) {
|
|
128
|
+
const lines = withoutMetaLines(canonicalRunText(content), SEAL_META_LINE).split("\n");
|
|
129
|
+
const range = runMetaRange(lines);
|
|
130
|
+
if (!range) throw new Error("AGDF_RUN_STATE_INVALID");
|
|
131
|
+
const revisionLine = lines.findIndex((line, index) => index > range.start && index < range.end && line.startsWith("- revision_id:"));
|
|
132
|
+
lines.splice(revisionLine >= 0 ? revisionLine + 1 : range.start + 1, 0,
|
|
133
|
+
`- content_seal: ${seals.content_seal}`,
|
|
134
|
+
`- approval_seal: ${seals.approval_seal}`);
|
|
135
|
+
return lines.join("\n");
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
export function sealRunState(root, content) {
|
|
139
|
+
return applyRunSeals(content, computeRunSeals(root, content));
|
|
140
|
+
}
|
|
141
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
// Validation composes seal computation with historical and receipt proofs.
|
|
2
|
+
export * from "./run-seal-compute.js";
|
|
3
|
+
import { canonicalRunText, computeRunSeals } from "./run-seal-compute.js";
|
|
4
|
+
import { scalarFields } from "./run-state-document.js";
|
|
5
|
+
import { readApprovalOperations } from "./approval-operations.js";
|
|
6
|
+
import { readArtefactBindings } from "./artefact-bindings.js";
|
|
7
|
+
import { validSourceRevisionHistories } from "./run-revision-history.js";
|
|
8
|
+
const SEAL_PATTERN = /^sha256:[0-9a-f]{64}$/u;
|
|
9
|
+
|
|
10
|
+
export function runSealState(root, content) {
|
|
11
|
+
const text = canonicalRunText(content);
|
|
12
|
+
const { values } = scalarFields(text);
|
|
13
|
+
const recorded = Object.freeze({ content_seal: values.get("content_seal"), approval_seal: values.get("approval_seal") });
|
|
14
|
+
if (recorded.content_seal === undefined && recorded.approval_seal === undefined) return Object.freeze({ status: "unsealed" });
|
|
15
|
+
if (!SEAL_PATTERN.test(recorded.content_seal ?? "") || !SEAL_PATTERN.test(recorded.approval_seal ?? "")) {
|
|
16
|
+
return Object.freeze({ status: "invalid", recorded });
|
|
17
|
+
}
|
|
18
|
+
if (!readApprovalOperations(text).valid) return Object.freeze({ status: "invalid", recorded });
|
|
19
|
+
if (!readArtefactBindings(text).valid) return Object.freeze({ status: "invalid", recorded });
|
|
20
|
+
if (!validSourceRevisionHistories(root, text)) return Object.freeze({ status: "invalid", recorded });
|
|
21
|
+
const actual = computeRunSeals(root, text);
|
|
22
|
+
const status = actual.approval_seal !== recorded.approval_seal
|
|
23
|
+
? "approvals_changed"
|
|
24
|
+
: actual.content_seal !== recorded.content_seal ? "content_changed" : "valid";
|
|
25
|
+
return Object.freeze({ status, recorded, actual });
|
|
26
|
+
}
|