@warpgogol/forge 8.0.4 → 9.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/bin/cli.ts +25 -13
- package/dist/bin/cli.js +17 -13
- package/dist/bin/cli.js.map +1 -1
- package/dist/os/adr/handlers/implement-stamp.d.ts.map +1 -1
- package/dist/os/adr/handlers/implement-stamp.js +1 -0
- package/dist/os/adr/handlers/implement-stamp.js.map +1 -1
- package/dist/os/adr/types.d.ts +2 -0
- package/dist/os/adr/types.d.ts.map +1 -1
- package/dist/os/agent/agent.module.d.ts +3 -0
- package/dist/os/agent/agent.module.d.ts.map +1 -0
- package/dist/os/agent/agent.module.js +60 -0
- package/dist/os/agent/agent.module.js.map +1 -0
- package/dist/os/agent/handlers/agent-delegate.d.ts +29 -0
- package/dist/os/agent/handlers/agent-delegate.d.ts.map +1 -0
- package/dist/os/agent/handlers/agent-delegate.js +187 -0
- package/dist/os/agent/handlers/agent-delegate.js.map +1 -0
- package/dist/os/agent/handlers/agent-tiers-validate.d.ts +15 -0
- package/dist/os/agent/handlers/agent-tiers-validate.d.ts.map +1 -0
- package/dist/os/agent/handlers/agent-tiers-validate.js +205 -0
- package/dist/os/agent/handlers/agent-tiers-validate.js.map +1 -0
- package/dist/os/agent/index.d.ts +5 -0
- package/dist/os/agent/index.d.ts.map +1 -0
- package/dist/os/agent/index.js +14 -0
- package/dist/os/agent/index.js.map +1 -0
- package/dist/os/agent/invoke-adapter.d.ts +43 -0
- package/dist/os/agent/invoke-adapter.d.ts.map +1 -0
- package/dist/os/agent/invoke-adapter.js +83 -0
- package/dist/os/agent/invoke-adapter.js.map +1 -0
- package/dist/os/authority/authority.module.d.ts.map +1 -1
- package/dist/os/authority/authority.module.js +2 -10
- package/dist/os/authority/authority.module.js.map +1 -1
- package/dist/os/checks/checks.module.d.ts +3 -0
- package/dist/os/checks/checks.module.d.ts.map +1 -0
- package/dist/os/checks/checks.module.js +90 -0
- package/dist/os/checks/checks.module.js.map +1 -0
- package/dist/os/checks/handlers/contribution-report.d.ts +35 -0
- package/dist/os/checks/handlers/contribution-report.d.ts.map +1 -0
- package/dist/os/checks/handlers/contribution-report.js +264 -0
- package/dist/os/checks/handlers/contribution-report.js.map +1 -0
- package/dist/os/checks/handlers/counters-export.d.ts +19 -0
- package/dist/os/checks/handlers/counters-export.d.ts.map +1 -0
- package/dist/os/checks/handlers/counters-export.js +122 -0
- package/dist/os/checks/handlers/counters-export.js.map +1 -0
- package/dist/os/checks/handlers/counters-journal.d.ts +67 -0
- package/dist/os/checks/handlers/counters-journal.d.ts.map +1 -0
- package/dist/os/checks/handlers/counters-journal.js +154 -0
- package/dist/os/checks/handlers/counters-journal.js.map +1 -0
- package/dist/os/checks/handlers/counters-validate.d.ts +11 -0
- package/dist/os/checks/handlers/counters-validate.d.ts.map +1 -0
- package/dist/os/checks/handlers/counters-validate.js +131 -0
- package/dist/os/checks/handlers/counters-validate.js.map +1 -0
- package/dist/os/checks/index.d.ts +6 -0
- package/dist/os/checks/index.d.ts.map +1 -0
- package/dist/os/checks/index.js +6 -0
- package/dist/os/checks/index.js.map +1 -0
- package/dist/os/compass/compass.module.d.ts.map +1 -1
- package/dist/os/compass/compass.module.js +55 -20
- package/dist/os/compass/compass.module.js.map +1 -1
- package/dist/os/compass/handlers/compass-header-scaffold.d.ts.map +1 -1
- package/dist/os/compass/handlers/compass-header-scaffold.js +4 -2
- package/dist/os/compass/handlers/compass-header-scaffold.js.map +1 -1
- package/dist/os/compass/handlers/compass-invariants-generate.d.ts +15 -0
- package/dist/os/compass/handlers/compass-invariants-generate.d.ts.map +1 -0
- package/dist/os/compass/handlers/compass-invariants-generate.js +208 -0
- package/dist/os/compass/handlers/compass-invariants-generate.js.map +1 -0
- package/dist/os/compass/handlers/compass-inventory-handler.d.ts.map +1 -1
- package/dist/os/compass/handlers/compass-inventory-handler.js +46 -4
- package/dist/os/compass/handlers/compass-inventory-handler.js.map +1 -1
- package/dist/os/compass/handlers/invariant-bindings.d.ts +85 -0
- package/dist/os/compass/handlers/invariant-bindings.d.ts.map +1 -0
- package/dist/os/compass/handlers/invariant-bindings.js +390 -0
- package/dist/os/compass/handlers/invariant-bindings.js.map +1 -0
- package/dist/os/conformance/conformance.module.d.ts +3 -0
- package/dist/os/conformance/conformance.module.d.ts.map +1 -0
- package/dist/os/conformance/conformance.module.js +96 -0
- package/dist/os/conformance/conformance.module.js.map +1 -0
- package/dist/os/conformance/handlers/conformance-run.d.ts +14 -0
- package/dist/os/conformance/handlers/conformance-run.d.ts.map +1 -0
- package/dist/os/conformance/handlers/conformance-run.js +149 -0
- package/dist/os/conformance/handlers/conformance-run.js.map +1 -0
- package/dist/os/conformance/handlers/conformance-validate.d.ts +14 -0
- package/dist/os/conformance/handlers/conformance-validate.d.ts.map +1 -0
- package/dist/os/conformance/handlers/conformance-validate.js +216 -0
- package/dist/os/conformance/handlers/conformance-validate.js.map +1 -0
- package/dist/os/conformance/index.d.ts +6 -0
- package/dist/os/conformance/index.d.ts.map +1 -0
- package/dist/os/conformance/index.js +17 -0
- package/dist/os/conformance/index.js.map +1 -0
- package/dist/os/context/context.module.d.ts +3 -0
- package/dist/os/context/context.module.d.ts.map +1 -0
- package/dist/os/context/context.module.js +68 -0
- package/dist/os/context/context.module.js.map +1 -0
- package/dist/os/context/handlers/context-assemble.d.ts +28 -0
- package/dist/os/context/handlers/context-assemble.d.ts.map +1 -0
- package/dist/os/context/handlers/context-assemble.js +142 -0
- package/dist/os/context/handlers/context-assemble.js.map +1 -0
- package/dist/os/context/handlers/context-slate-eval.d.ts +15 -0
- package/dist/os/context/handlers/context-slate-eval.d.ts.map +1 -0
- package/dist/os/context/handlers/context-slate-eval.js +70 -0
- package/dist/os/context/handlers/context-slate-eval.js.map +1 -0
- package/dist/os/context/handlers/index-build.d.ts +19 -0
- package/dist/os/context/handlers/index-build.d.ts.map +1 -0
- package/dist/os/context/handlers/index-build.js +188 -0
- package/dist/os/context/handlers/index-build.js.map +1 -0
- package/dist/os/context/index.d.ts +5 -0
- package/dist/os/context/index.d.ts.map +1 -0
- package/dist/os/context/index.js +5 -0
- package/dist/os/context/index.js.map +1 -0
- package/dist/os/core/core.module.d.ts.map +1 -1
- package/dist/os/core/core.module.js +34 -11
- package/dist/os/core/core.module.js.map +1 -1
- package/dist/os/formal/formal.module.d.ts +3 -0
- package/dist/os/formal/formal.module.d.ts.map +1 -0
- package/dist/os/formal/formal.module.js +63 -0
- package/dist/os/formal/formal.module.js.map +1 -0
- package/dist/os/formal/handlers/proof-check.d.ts +10 -0
- package/dist/os/formal/handlers/proof-check.d.ts.map +1 -0
- package/dist/os/formal/handlers/proof-check.js +82 -0
- package/dist/os/formal/handlers/proof-check.js.map +1 -0
- package/dist/os/formal/index.d.ts +4 -0
- package/dist/os/formal/index.d.ts.map +1 -0
- package/dist/os/formal/index.js +16 -0
- package/dist/os/formal/index.js.map +1 -0
- package/dist/os/friction/friction.module.d.ts +3 -0
- package/dist/os/friction/friction.module.d.ts.map +1 -0
- package/dist/os/friction/friction.module.js +71 -0
- package/dist/os/friction/friction.module.js.map +1 -0
- package/dist/os/friction/handlers/friction-validate.d.ts +4 -0
- package/dist/os/friction/handlers/friction-validate.d.ts.map +1 -0
- package/dist/os/friction/handlers/friction-validate.js +228 -0
- package/dist/os/friction/handlers/friction-validate.js.map +1 -0
- package/dist/os/friction/index.d.ts +4 -0
- package/dist/os/friction/index.d.ts.map +1 -0
- package/dist/os/friction/index.js +23 -0
- package/dist/os/friction/index.js.map +1 -0
- package/dist/os/friction/types.d.ts +97 -0
- package/dist/os/friction/types.d.ts.map +1 -0
- package/dist/os/friction/types.js +78 -0
- package/dist/os/friction/types.js.map +1 -0
- package/dist/os/gate/gate.module.d.ts +3 -0
- package/dist/os/gate/gate.module.d.ts.map +1 -0
- package/dist/os/gate/gate.module.js +65 -0
- package/dist/os/gate/gate.module.js.map +1 -0
- package/dist/os/gate/handlers/gate-probe-catalog.d.ts +18 -0
- package/dist/os/gate/handlers/gate-probe-catalog.d.ts.map +1 -0
- package/dist/os/gate/handlers/gate-probe-catalog.js +66 -0
- package/dist/os/gate/handlers/gate-probe-catalog.js.map +1 -0
- package/dist/os/gate/handlers/gate-probe.d.ts +32 -0
- package/dist/os/gate/handlers/gate-probe.d.ts.map +1 -0
- package/dist/os/gate/handlers/gate-probe.js +228 -0
- package/dist/os/gate/handlers/gate-probe.js.map +1 -0
- package/dist/os/gate/index.d.ts +4 -0
- package/dist/os/gate/index.d.ts.map +1 -0
- package/dist/os/gate/index.js +4 -0
- package/dist/os/gate/index.js.map +1 -0
- package/dist/os/instructions/handlers/budget-validate.d.ts +29 -0
- package/dist/os/instructions/handlers/budget-validate.d.ts.map +1 -0
- package/dist/os/instructions/handlers/budget-validate.js +164 -0
- package/dist/os/instructions/handlers/budget-validate.js.map +1 -0
- package/dist/os/instructions/handlers/scar-migrate.d.ts +13 -0
- package/dist/os/instructions/handlers/scar-migrate.d.ts.map +1 -0
- package/dist/os/instructions/handlers/scar-migrate.js +270 -0
- package/dist/os/instructions/handlers/scar-migrate.js.map +1 -0
- package/dist/os/instructions/instructions.module.d.ts +3 -0
- package/dist/os/instructions/instructions.module.d.ts.map +1 -0
- package/dist/os/instructions/instructions.module.js +74 -0
- package/dist/os/instructions/instructions.module.js.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-authz-probe.d.ts +16 -0
- package/dist/os/knowledge/handlers/knowledge-authz-probe.d.ts.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-authz-probe.js +198 -0
- package/dist/os/knowledge/handlers/knowledge-authz-probe.js.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.d.ts +15 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.d.ts.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.js +137 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.js.map +1 -0
- package/dist/os/knowledge/index.d.ts +4 -0
- package/dist/os/knowledge/index.d.ts.map +1 -0
- package/dist/os/knowledge/index.js +4 -0
- package/dist/os/knowledge/index.js.map +1 -0
- package/dist/os/knowledge/knowledge.module.d.ts +3 -0
- package/dist/os/knowledge/knowledge.module.d.ts.map +1 -0
- package/dist/os/knowledge/knowledge.module.js +61 -0
- package/dist/os/knowledge/knowledge.module.js.map +1 -0
- package/dist/os/mission/handlers/archive.d.ts.map +1 -1
- package/dist/os/mission/handlers/archive.js +102 -6
- package/dist/os/mission/handlers/archive.js.map +1 -1
- package/dist/os/mission/mission.module.d.ts.map +1 -1
- package/dist/os/mission/mission.module.js +7 -0
- package/dist/os/mission/mission.module.js.map +1 -1
- package/dist/os/naming/naming-convention.d.ts.map +1 -1
- package/dist/os/naming/naming-convention.js +2 -1
- package/dist/os/naming/naming-convention.js.map +1 -1
- package/dist/os/program/schemas.d.ts +5 -5
- package/dist/os/queue/handlers/queue-validate.d.ts.map +1 -1
- package/dist/os/queue/handlers/queue-validate.js +129 -5
- package/dist/os/queue/handlers/queue-validate.js.map +1 -1
- package/dist/os/queue/queue.module.d.ts.map +1 -1
- package/dist/os/queue/queue.module.js +12 -31
- package/dist/os/queue/queue.module.js.map +1 -1
- package/dist/os/queue/types.d.ts +23 -0
- package/dist/os/queue/types.d.ts.map +1 -1
- package/dist/os/queue/types.js +24 -3
- package/dist/os/queue/types.js.map +1 -1
- package/dist/os/resolver/handlers/resolver-doors-audit.d.ts +22 -0
- package/dist/os/resolver/handlers/resolver-doors-audit.d.ts.map +1 -0
- package/dist/os/resolver/handlers/resolver-doors-audit.js +238 -0
- package/dist/os/resolver/handlers/resolver-doors-audit.js.map +1 -0
- package/dist/os/resolver/resolver.module.d.ts +3 -0
- package/dist/os/resolver/resolver.module.d.ts.map +1 -0
- package/dist/os/resolver/resolver.module.js +40 -0
- package/dist/os/resolver/resolver.module.js.map +1 -0
- package/dist/os/rfc/acceptance.d.ts +2 -1
- package/dist/os/rfc/acceptance.d.ts.map +1 -1
- package/dist/os/rfc/acceptance.js +158 -82
- package/dist/os/rfc/acceptance.js.map +1 -1
- package/dist/os/rfc/decision-log.d.ts +10 -0
- package/dist/os/rfc/decision-log.d.ts.map +1 -1
- package/dist/os/rfc/decision-log.js +14 -0
- package/dist/os/rfc/decision-log.js.map +1 -1
- package/dist/os/rfc/handlers/fixed-inputs.d.ts +29 -0
- package/dist/os/rfc/handlers/fixed-inputs.d.ts.map +1 -0
- package/dist/os/rfc/handlers/fixed-inputs.js +214 -0
- package/dist/os/rfc/handlers/fixed-inputs.js.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts +47 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.js +145 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.js.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-origin.d.ts +15 -1
- package/dist/os/rfc/handlers/implement-stamp-origin.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-origin.js +57 -5
- package/dist/os/rfc/handlers/implement-stamp-origin.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts +42 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.js +102 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.js.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp.js +101 -12
- package/dist/os/rfc/handlers/implement-stamp.js.map +1 -1
- package/dist/os/rfc/handlers/index-graph.d.ts +4 -2
- package/dist/os/rfc/handlers/index-graph.d.ts.map +1 -1
- package/dist/os/rfc/handlers/index-graph.js +57 -3
- package/dist/os/rfc/handlers/index-graph.js.map +1 -1
- package/dist/os/rfc/handlers/list-create.d.ts.map +1 -1
- package/dist/os/rfc/handlers/list-create.js +117 -12
- package/dist/os/rfc/handlers/list-create.js.map +1 -1
- package/dist/os/rfc/handlers/supersede-propose.d.ts.map +1 -1
- package/dist/os/rfc/handlers/supersede-propose.js +34 -7
- package/dist/os/rfc/handlers/supersede-propose.js.map +1 -1
- package/dist/os/rfc/handlers/validate-rules.d.ts +4 -1
- package/dist/os/rfc/handlers/validate-rules.d.ts.map +1 -1
- package/dist/os/rfc/handlers/validate-rules.js +159 -11
- package/dist/os/rfc/handlers/validate-rules.js.map +1 -1
- package/dist/os/rfc/handlers/validate.d.ts.map +1 -1
- package/dist/os/rfc/handlers/validate.js +10 -1
- package/dist/os/rfc/handlers/validate.js.map +1 -1
- package/dist/os/rfc/outcome-probe.d.ts +20 -0
- package/dist/os/rfc/outcome-probe.d.ts.map +1 -0
- package/dist/os/rfc/outcome-probe.js +315 -0
- package/dist/os/rfc/outcome-probe.js.map +1 -0
- package/dist/os/rfc/reachable-symbol.d.ts.map +1 -1
- package/dist/os/rfc/reachable-symbol.js +51 -12
- package/dist/os/rfc/reachable-symbol.js.map +1 -1
- package/dist/os/rfc/rfc.module.d.ts.map +1 -1
- package/dist/os/rfc/rfc.module.js +48 -11
- package/dist/os/rfc/rfc.module.js.map +1 -1
- package/dist/os/rfc/types.d.ts +90 -12
- package/dist/os/rfc/types.d.ts.map +1 -1
- package/dist/os/rfc/types.js +8 -7
- package/dist/os/rfc/types.js.map +1 -1
- package/dist/os/rfc/verification-evidence.d.ts +4 -1
- package/dist/os/rfc/verification-evidence.d.ts.map +1 -1
- package/dist/os/rfc/verification-evidence.js +69 -17
- package/dist/os/rfc/verification-evidence.js.map +1 -1
- package/dist/os/rfc/verification-origin.d.ts +8 -0
- package/dist/os/rfc/verification-origin.d.ts.map +1 -1
- package/dist/os/rfc/verification-origin.js +48 -1
- package/dist/os/rfc/verification-origin.js.map +1 -1
- package/dist/os/rfc/verification-refresh.d.ts.map +1 -1
- package/dist/os/rfc/verification-refresh.js +19 -2
- package/dist/os/rfc/verification-refresh.js.map +1 -1
- package/dist/os/rfc/verification-verdicts.d.ts +14 -0
- package/dist/os/rfc/verification-verdicts.d.ts.map +1 -0
- package/dist/os/rfc/verification-verdicts.js +104 -0
- package/dist/os/rfc/verification-verdicts.js.map +1 -0
- package/dist/os/rfc/verifier/rfc-1391/support.d.ts +34 -0
- package/dist/os/rfc/verifier/rfc-1391/support.d.ts.map +1 -0
- package/dist/os/rfc/verifier/rfc-1391/support.js +184 -0
- package/dist/os/rfc/verifier/rfc-1391/support.js.map +1 -0
- package/dist/os/session/frontmatter-io.d.ts +3 -1
- package/dist/os/session/frontmatter-io.d.ts.map +1 -1
- package/dist/os/session/frontmatter-io.js +3 -1
- package/dist/os/session/frontmatter-io.js.map +1 -1
- package/dist/os/session/handlers/session-audit-report.d.ts +20 -0
- package/dist/os/session/handlers/session-audit-report.d.ts.map +1 -0
- package/dist/os/session/handlers/session-audit-report.js +78 -0
- package/dist/os/session/handlers/session-audit-report.js.map +1 -0
- package/dist/os/session/handlers/session-audit.d.ts +25 -0
- package/dist/os/session/handlers/session-audit.d.ts.map +1 -0
- package/dist/os/session/handlers/session-audit.js +265 -0
- package/dist/os/session/handlers/session-audit.js.map +1 -0
- package/dist/os/session/session.module.d.ts.map +1 -1
- package/dist/os/session/session.module.js +49 -2
- package/dist/os/session/session.module.js.map +1 -1
- package/dist/os/spec/spec-amendments.d.ts +7 -0
- package/dist/os/spec/spec-amendments.d.ts.map +1 -0
- package/dist/os/spec/spec-amendments.js +86 -0
- package/dist/os/spec/spec-amendments.js.map +1 -0
- package/dist/os/spec/spec-materialize.d.ts.map +1 -1
- package/dist/os/spec/spec-materialize.js +22 -24
- package/dist/os/spec/spec-materialize.js.map +1 -1
- package/dist/os/spec/spec-status.d.ts.map +1 -1
- package/dist/os/spec/spec-status.js +25 -29
- package/dist/os/spec/spec-status.js.map +1 -1
- package/dist/os/spec/spec-validate.d.ts.map +1 -1
- package/dist/os/spec/spec-validate.js +9 -29
- package/dist/os/spec/spec-validate.js.map +1 -1
- package/dist/os/spec/spec.module.d.ts.map +1 -1
- package/dist/os/spec/spec.module.js +7 -36
- package/dist/os/spec/spec.module.js.map +1 -1
- package/dist/os/trajectory/handlers/journal-io.d.ts +51 -0
- package/dist/os/trajectory/handlers/journal-io.d.ts.map +1 -0
- package/dist/os/trajectory/handlers/journal-io.js +161 -0
- package/dist/os/trajectory/handlers/journal-io.js.map +1 -0
- package/dist/os/trajectory/handlers/outcome-record.d.ts +16 -0
- package/dist/os/trajectory/handlers/outcome-record.d.ts.map +1 -0
- package/dist/os/trajectory/handlers/outcome-record.js +142 -0
- package/dist/os/trajectory/handlers/outcome-record.js.map +1 -0
- package/dist/os/trajectory/handlers/trajectory-index.d.ts +59 -0
- package/dist/os/trajectory/handlers/trajectory-index.d.ts.map +1 -0
- package/dist/os/trajectory/handlers/trajectory-index.js +427 -0
- package/dist/os/trajectory/handlers/trajectory-index.js.map +1 -0
- package/dist/os/trajectory/handlers/trajectory-recall.d.ts +21 -0
- package/dist/os/trajectory/handlers/trajectory-recall.d.ts.map +1 -0
- package/dist/os/trajectory/handlers/trajectory-recall.js +176 -0
- package/dist/os/trajectory/handlers/trajectory-recall.js.map +1 -0
- package/dist/os/trajectory/index.d.ts +5 -0
- package/dist/os/trajectory/index.d.ts.map +1 -0
- package/dist/os/trajectory/index.js +5 -0
- package/dist/os/trajectory/index.js.map +1 -0
- package/dist/os/trajectory/trajectory.module.d.ts +3 -0
- package/dist/os/trajectory/trajectory.module.d.ts.map +1 -0
- package/dist/os/trajectory/trajectory.module.js +91 -0
- package/dist/os/trajectory/trajectory.module.js.map +1 -0
- package/dist/os/werkstatt/handlers/session-close.d.ts +13 -0
- package/dist/os/werkstatt/handlers/session-close.d.ts.map +1 -0
- package/dist/os/werkstatt/handlers/session-close.js +53 -0
- package/dist/os/werkstatt/handlers/session-close.js.map +1 -0
- package/dist/os/werkstatt/handlers/session-engine.d.ts +3 -0
- package/dist/os/werkstatt/handlers/session-engine.d.ts.map +1 -0
- package/dist/os/werkstatt/handlers/session-engine.js +25 -0
- package/dist/os/werkstatt/handlers/session-engine.js.map +1 -0
- package/dist/os/werkstatt/handlers/session-open.d.ts +10 -0
- package/dist/os/werkstatt/handlers/session-open.d.ts.map +1 -0
- package/dist/os/werkstatt/handlers/session-open.js +43 -0
- package/dist/os/werkstatt/handlers/session-open.js.map +1 -0
- package/dist/os/werkstatt/handlers/session-status.d.ts +9 -0
- package/dist/os/werkstatt/handlers/session-status.d.ts.map +1 -0
- package/dist/os/werkstatt/handlers/session-status.js +31 -0
- package/dist/os/werkstatt/handlers/session-status.js.map +1 -0
- package/dist/os/werkstatt/werkstatt.module.d.ts.map +1 -1
- package/dist/os/werkstatt/werkstatt.module.js +98 -3
- package/dist/os/werkstatt/werkstatt.module.js.map +1 -1
- package/dist/src/authority/delegations.d.ts +1 -1
- package/dist/src/authority/delegations.d.ts.map +1 -1
- package/dist/src/authority/delegations.js +2 -0
- package/dist/src/authority/delegations.js.map +1 -1
- package/dist/src/cli-flags.d.ts.map +1 -1
- package/dist/src/cli-flags.js +90 -11
- package/dist/src/cli-flags.js.map +1 -1
- package/dist/src/compass/index.d.ts +2 -0
- package/dist/src/compass/index.d.ts.map +1 -0
- package/dist/src/compass/index.js +26 -0
- package/dist/src/compass/index.js.map +1 -0
- package/dist/src/compass/invariant-parser.d.ts +37 -0
- package/dist/src/compass/invariant-parser.d.ts.map +1 -0
- package/dist/src/compass/invariant-parser.js +218 -0
- package/dist/src/compass/invariant-parser.js.map +1 -0
- package/dist/src/config/forge-config.d.ts +108 -0
- package/dist/src/config/forge-config.d.ts.map +1 -1
- package/dist/src/config/forge-config.js +79 -9
- package/dist/src/config/forge-config.js.map +1 -1
- package/dist/src/conformance/index.d.ts +42 -0
- package/dist/src/conformance/index.d.ts.map +1 -0
- package/dist/src/conformance/index.js +193 -0
- package/dist/src/conformance/index.js.map +1 -0
- package/dist/src/formal/exhaustive.d.ts +40 -0
- package/dist/src/formal/exhaustive.d.ts.map +1 -0
- package/dist/src/formal/exhaustive.js +140 -0
- package/dist/src/formal/exhaustive.js.map +1 -0
- package/dist/src/formal/index.d.ts +7 -0
- package/dist/src/formal/index.d.ts.map +1 -0
- package/dist/src/formal/index.js +13 -0
- package/dist/src/formal/index.js.map +1 -0
- package/dist/src/formal/proof-runner.d.ts +51 -0
- package/dist/src/formal/proof-runner.d.ts.map +1 -0
- package/dist/src/formal/proof-runner.js +450 -0
- package/dist/src/formal/proof-runner.js.map +1 -0
- package/dist/src/formal/proof-spec.d.ts +69 -0
- package/dist/src/formal/proof-spec.d.ts.map +1 -0
- package/dist/src/formal/proof-spec.js +96 -0
- package/dist/src/formal/proof-spec.js.map +1 -0
- package/dist/src/knowledge/schema.d.ts +8 -0
- package/dist/src/knowledge/schema.d.ts.map +1 -1
- package/dist/src/knowledge/schema.js +5 -0
- package/dist/src/knowledge/schema.js.map +1 -1
- package/dist/src/knowledge/serialize.d.ts.map +1 -1
- package/dist/src/knowledge/serialize.js +3 -0
- package/dist/src/knowledge/serialize.js.map +1 -1
- package/dist/src/onboarding/agents-generate.d.ts.map +1 -1
- package/dist/src/onboarding/agents-generate.js +17 -2
- package/dist/src/onboarding/agents-generate.js.map +1 -1
- package/dist/src/onboarding/doctor.d.ts.map +1 -1
- package/dist/src/onboarding/doctor.js +87 -1
- package/dist/src/onboarding/doctor.js.map +1 -1
- package/dist/src/onboarding/init.js +3 -3
- package/dist/src/onboarding/init.js.map +1 -1
- package/dist/src/profiles/profile-schema.d.ts +8 -0
- package/dist/src/profiles/profile-schema.d.ts.map +1 -1
- package/dist/src/profiles/profile-schema.js +10 -2
- package/dist/src/profiles/profile-schema.js.map +1 -1
- package/dist/src/profiles/stack-profile.d.ts +4 -0
- package/dist/src/profiles/stack-profile.d.ts.map +1 -1
- package/dist/src/reachability/command-mentions.d.ts +17 -0
- package/dist/src/reachability/command-mentions.d.ts.map +1 -0
- package/dist/src/reachability/command-mentions.js +81 -0
- package/dist/src/reachability/command-mentions.js.map +1 -0
- package/dist/src/registry.d.ts +10 -0
- package/dist/src/registry.d.ts.map +1 -1
- package/dist/src/registry.js +40 -2
- package/dist/src/registry.js.map +1 -1
- package/dist/src/types.d.ts +51 -3
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/types.js +11 -14
- package/dist/src/types.js.map +1 -1
- package/dist/src/utils/sync-fs.d.ts +1 -1
- package/dist/src/utils/sync-fs.d.ts.map +1 -1
- package/dist/src/utils/sync-fs.js +2 -1
- package/dist/src/utils/sync-fs.js.map +1 -1
- package/docs/reference/forge-yaml.md +20 -0
- package/os/adr/handlers/implement-stamp.ts +2 -0
- package/os/adr/types.ts +2 -0
- package/os/agent/agent.module.ts +64 -0
- package/os/agent/handlers/agent-delegate.ts +227 -0
- package/os/agent/handlers/agent-tiers-validate.ts +228 -0
- package/os/agent/index.ts +14 -0
- package/os/agent/invoke-adapter.ts +119 -0
- package/os/authority/authority.module.ts +2 -10
- package/os/checks/checks.module.ts +95 -0
- package/os/checks/handlers/contribution-report.test.ts +244 -0
- package/os/checks/handlers/contribution-report.ts +316 -0
- package/os/checks/handlers/counters-export.test.ts +175 -0
- package/os/checks/handlers/counters-export.ts +170 -0
- package/os/checks/handlers/counters-journal.test.ts +187 -0
- package/os/checks/handlers/counters-journal.ts +179 -0
- package/os/checks/handlers/counters-validate.test.ts +176 -0
- package/os/checks/handlers/counters-validate.ts +159 -0
- package/os/checks/handlers/variant-candidates.test.ts +65 -0
- package/os/checks/index.ts +15 -0
- package/os/compass/compass.module.ts +58 -20
- package/os/compass/handlers/compass-header-scaffold.ts +4 -2
- package/os/compass/handlers/compass-invariants-generate.ts +293 -0
- package/os/compass/handlers/compass-inventory-handler.ts +59 -4
- package/os/compass/handlers/invariant-bindings.ts +526 -0
- package/os/compass/handlers/tests/compass-invariant-binding.test.ts +500 -0
- package/os/compass/handlers/tests/compass-invariants-generate.test.ts +235 -0
- package/os/compass/handlers/tests/compass-migrate.test.ts +5 -3
- package/os/conformance/conformance.module.ts +105 -0
- package/os/conformance/handlers/conformance-run.ts +175 -0
- package/os/conformance/handlers/conformance-validate.ts +334 -0
- package/os/conformance/handlers/tests/conformance.test.ts +657 -0
- package/os/conformance/index.ts +19 -0
- package/os/context/context.module.ts +73 -0
- package/os/context/handlers/context-assemble.test.ts +89 -0
- package/os/context/handlers/context-assemble.ts +171 -0
- package/os/context/handlers/context-slate-eval.test.ts +64 -0
- package/os/context/handlers/context-slate-eval.ts +86 -0
- package/os/context/handlers/index-build.test.ts +68 -0
- package/os/context/handlers/index-build.ts +211 -0
- package/os/context/handlers/no-model-deps.test.ts +32 -0
- package/os/context/handlers/slate-fill.test.ts +31 -0
- package/os/context/index.ts +4 -0
- package/os/core/core.module.ts +34 -11
- package/os/formal/formal.module.ts +67 -0
- package/os/formal/handlers/proof-check.test.ts +337 -0
- package/os/formal/handlers/proof-check.ts +100 -0
- package/os/formal/index.ts +17 -0
- package/os/friction/friction-validate.test.ts +442 -0
- package/os/friction/friction.module.ts +74 -0
- package/os/friction/handlers/friction-validate.ts +349 -0
- package/os/friction/index.ts +30 -0
- package/os/friction/types.ts +113 -0
- package/os/gate/gate.module.ts +69 -0
- package/os/gate/handlers/gate-probe-catalog.test.ts +76 -0
- package/os/gate/handlers/gate-probe-catalog.ts +85 -0
- package/os/gate/handlers/gate-probe.test.ts +108 -0
- package/os/gate/handlers/gate-probe.ts +252 -0
- package/os/gate/index.ts +3 -0
- package/os/instructions/budget.test.ts +125 -0
- package/os/instructions/handlers/budget-validate.ts +197 -0
- package/os/instructions/handlers/scar-migrate.ts +292 -0
- package/os/instructions/instructions.module.ts +78 -0
- package/os/knowledge/handlers/knowledge-authz-probe.test.ts +86 -0
- package/os/knowledge/handlers/knowledge-authz-probe.ts +236 -0
- package/os/knowledge/handlers/knowledge-rebuild.test.ts +76 -0
- package/os/knowledge/handlers/knowledge-rebuild.ts +163 -0
- package/os/knowledge/index.ts +3 -0
- package/os/knowledge/knowledge.module.ts +65 -0
- package/os/mission/handlers/archive.ts +113 -6
- package/os/mission/handlers/ship-inflight-degraded.test.ts +105 -0
- package/os/mission/mission.module.ts +8 -0
- package/os/naming/naming-convention.ts +2 -1
- package/os/queue/decision-ledger.test.ts +39 -0
- package/os/queue/handlers/queue-validate.ts +132 -5
- package/os/queue/queue-validate.test.ts +194 -0
- package/os/queue/queue.module.ts +12 -31
- package/os/queue/types.ts +26 -3
- package/os/resolver/handlers/resolver-doors-audit.test.ts +147 -0
- package/os/resolver/handlers/resolver-doors-audit.ts +281 -0
- package/os/resolver/resolver.module.ts +43 -0
- package/os/rfc/acceptance-reachable.test.ts +78 -0
- package/os/rfc/acceptance.test.ts +229 -1
- package/os/rfc/acceptance.ts +141 -45
- package/os/rfc/decision-log.ts +15 -0
- package/os/rfc/handlers/fixed-inputs.ts +252 -0
- package/os/rfc/handlers/implement-stamp-deviations.test.ts +140 -0
- package/os/rfc/handlers/implement-stamp-deviations.ts +183 -0
- package/os/rfc/handlers/implement-stamp-formal.test.ts +168 -0
- package/os/rfc/handlers/implement-stamp-origin.ts +87 -11
- package/os/rfc/handlers/implement-stamp-outcome.test.ts +193 -0
- package/os/rfc/handlers/implement-stamp-outcome.ts +146 -0
- package/os/rfc/handlers/implement-stamp.ts +107 -10
- package/os/rfc/handlers/index-graph.ts +66 -4
- package/os/rfc/handlers/list-create.test.ts +142 -0
- package/os/rfc/handlers/list-create.ts +140 -12
- package/os/rfc/handlers/supersede-propose.ts +50 -7
- package/os/rfc/handlers/tests/index-graph.test.ts +165 -0
- package/os/rfc/handlers/validate-rules-rfc1453.test.ts +163 -0
- package/os/rfc/handlers/validate-rules-rfc1454.test.ts +136 -0
- package/os/rfc/handlers/validate-rules-rfc1455.test.ts +282 -0
- package/os/rfc/handlers/validate-rules.test.ts +129 -2
- package/os/rfc/handlers/validate-rules.ts +233 -9
- package/os/rfc/handlers/validate.ts +11 -0
- package/os/rfc/outcome-probe.ts +326 -0
- package/os/rfc/reachable-symbol.ts +64 -16
- package/os/rfc/rfc-0000-template.md +4 -0
- package/os/rfc/rfc.module.ts +51 -11
- package/os/rfc/types.ts +109 -14
- package/os/rfc/verification-evidence.ts +74 -14
- package/os/rfc/verification-origin.ts +61 -1
- package/os/rfc/verification-refresh.test.ts +63 -0
- package/os/rfc/verification-refresh.ts +24 -2
- package/os/rfc/verification-verdicts.ts +123 -0
- package/os/rfc/verifier/rfc-1391/ac1-proved-exit-0.acceptance.test.ts +151 -0
- package/os/rfc/verifier/rfc-1391/ac2-unavailable-nonzero.acceptance.test.ts +111 -0
- package/os/rfc/verifier/rfc-1391/ac3-version-mismatch-error.acceptance.test.ts +97 -0
- package/os/rfc/verifier/rfc-1391/ac4-cardinality-mismatch-error.acceptance.test.ts +179 -0
- package/os/rfc/verifier/rfc-1391/ac5-imp13-formal-stamp-block.acceptance.test.ts +295 -0
- package/os/rfc/verifier/rfc-1391/ac6-formal-high-tier-gates.acceptance.test.ts +203 -0
- package/os/rfc/verifier/rfc-1391/ac7-v46-empty-assumptions.acceptance.test.ts +126 -0
- package/os/rfc/verifier/rfc-1391/cx1-emit-proof-envelope.acceptance.test.ts +130 -0
- package/os/rfc/verifier/rfc-1391/fixtures/no-report.proof.test.ts +35 -0
- package/os/rfc/verifier/rfc-1391/fixtures/small-domain.proof.test.ts +41 -0
- package/os/rfc/verifier/rfc-1391/origin-proof-spec-entry.acceptance.test.ts +175 -0
- package/os/rfc/verifier/rfc-1391/support.ts +205 -0
- package/os/session/fixtures/audit/clean.md +7 -0
- package/os/session/fixtures/audit/denied-retry.md +10 -0
- package/os/session/frontmatter-io.ts +3 -1
- package/os/session/handlers/session-audit-detectors.test.ts +91 -0
- package/os/session/handlers/session-audit-report.test.ts +64 -0
- package/os/session/handlers/session-audit-report.ts +93 -0
- package/os/session/handlers/session-audit.test.ts +80 -0
- package/os/session/handlers/session-audit.ts +317 -0
- package/os/session/session.module.ts +51 -2
- package/os/spec/spec-amendments.ts +91 -0
- package/os/spec/spec-materialize.ts +20 -22
- package/os/spec/spec-status.test.ts +17 -1
- package/os/spec/spec-status.ts +23 -29
- package/os/spec/spec-validate.test.ts +45 -0
- package/os/spec/spec-validate.ts +9 -29
- package/os/spec/spec.module.ts +7 -36
- package/os/trajectory/handlers/extract-units.test.ts +69 -0
- package/os/trajectory/handlers/journal-io.ts +211 -0
- package/os/trajectory/handlers/outcome-record.test.ts +192 -0
- package/os/trajectory/handlers/outcome-record.ts +162 -0
- package/os/trajectory/handlers/producer-trust.test.ts +163 -0
- package/os/trajectory/handlers/trajectory-index.test.ts +246 -0
- package/os/trajectory/handlers/trajectory-index.ts +470 -0
- package/os/trajectory/handlers/trajectory-recall.test.ts +227 -0
- package/os/trajectory/handlers/trajectory-recall.ts +198 -0
- package/os/trajectory/handlers/trajectory.test.ts +94 -0
- package/os/trajectory/handlers/verdict-binding.test.ts +209 -0
- package/os/trajectory/index.ts +4 -0
- package/os/trajectory/trajectory.module.ts +96 -0
- package/os/werkstatt/handlers/session-close.ts +79 -0
- package/os/werkstatt/handlers/session-engine.ts +31 -0
- package/os/werkstatt/handlers/session-open.ts +65 -0
- package/os/werkstatt/handlers/session-status.ts +52 -0
- package/os/werkstatt/werkstatt.module.ts +101 -3
- package/package.json +194 -1
- package/profiles/forge-shell.yaml +3 -1
- package/profiles/godot-game.yaml +3 -1
- package/profiles/knowledge.yaml +3 -1
- package/profiles/phaser-game.yaml +3 -1
- package/profiles/site-workshop.yaml +3 -1
- package/profiles/typescript.yaml +3 -1
- package/skills/_shared/agent-operating-model.md +1 -1
- package/skills/_shared/fo-pipeline-conventions.md +5 -1
- package/skills/fo/fo-add-tests/SKILL.md +9 -1
- package/skills/fo/fo-add-tests/pbt-guide.md +1 -0
- package/skills/fo/fo-compass-annotate/SKILL.md +18 -0
- package/skills/fo/fo-compass-annotate/templates/header-format.md +3 -2
- package/skills/fo/fo-fix/SKILL.md +14 -8
- package/skills/fo/fo-idea-create-adr/SKILL.md +5 -3
- package/skills/fo/fo-idea-create-rfc/SKILL.md +20 -8
- package/skills/fo/fo-idea-create-rfc/acceptance-criteria-standard.md +20 -0
- package/skills/fo/fo-idea-i-just-want-to-see-the-result/SKILL.md +31 -13
- package/skills/fo/fo-idea-implement/SKILL.md +20 -14
- package/skills/fo/fo-idea-plan/SKILL.md +1 -1
- package/skills/fo/fo-knowledge-distill/SKILL.md +7 -0
- package/skills/fo/fo-memory-sync/SKILL.md +6 -0
- package/skills/fo/fo-reproduce/SKILL.md +116 -0
- package/skills/fo/fo-review/SKILL.md +11 -5
- package/skills/fo/fo-session-retro/SKILL.md +134 -49
- package/skills/fo/fo-step-commit/SKILL.md +4 -3
- package/skills/fo/fo-triage/SKILL.md +9 -0
- package/skills/shared/grilling/SKILL.md +4 -0
- package/skills/shared/grilling/learned-principles.md +7 -0
- package/skills/shared/grilling/qa-log.md +39 -0
- package/src/authority/delegations.ts +2 -0
- package/src/cli-flags.ts +110 -11
- package/src/compass/index.ts +37 -0
- package/src/compass/invariant-parser.ts +253 -0
- package/src/config/forge-config.ts +111 -9
- package/src/conformance/index.ts +281 -0
- package/src/formal/exhaustive.test.ts +117 -0
- package/src/formal/exhaustive.ts +182 -0
- package/src/formal/index.ts +23 -0
- package/src/formal/proof-runner.test.ts +310 -0
- package/src/formal/proof-runner.ts +562 -0
- package/src/formal/proof-spec.test.ts +70 -0
- package/src/formal/proof-spec.ts +131 -0
- package/src/knowledge/schema.ts +9 -0
- package/src/knowledge/serialize.ts +3 -0
- package/src/onboarding/agents-generate.ts +18 -2
- package/src/onboarding/doctor.ts +93 -1
- package/src/onboarding/init.ts +3 -3
- package/src/onboarding/templates/behavioral-layer-core.md +1 -1
- package/src/profiles/profile-schema.ts +10 -2
- package/src/reachability/command-mentions.ts +87 -0
- package/src/registry.ts +44 -2
- package/src/tests/bindings-schema.test.ts +4 -0
- package/src/tests/cli-flags.test.ts +225 -0
- package/src/tests/fixtures/agents-generate-business-before.txt +4 -2
- package/src/tests/forge-config.test.ts +5 -2
- package/src/tests/implement-stamp.test.ts +51 -0
- package/src/tests/rfc-verification-verdict-ingest.test.ts +244 -0
- package/src/tests/session-retro.test.ts +47 -0
- package/src/types.ts +59 -18
- package/src/utils/sync-fs.ts +2 -0
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>
|
|
4
|
+
RFC-1453: RFC-IMP-14 gate tests — outcome-surface diffs require a passing
|
|
5
|
+
outcome probe (AC-5), untouched surfaces skip the gate (AC-6), and
|
|
6
|
+
--waive-outcome converts the block into a recorded warning (AC-7). Covers
|
|
7
|
+
the run-probe/outcomeBuild normalization and the unresolved-range fallback
|
|
8
|
+
to the implementation commit's own changed file set.
|
|
9
|
+
</purpose>
|
|
10
|
+
<non-goals>
|
|
11
|
+
<item>Do not exercise real git — OriginGit is stubbed; diff derivation is covered by verification-origin tests.</item>
|
|
12
|
+
</non-goals>
|
|
13
|
+
</MODULE_CONTRACT>
|
|
14
|
+
<CHANGE_SUMMARY>
|
|
15
|
+
<item>RFC-1453: RFC-IMP-14 outcome gate unit tests.</item>
|
|
16
|
+
<item>RFC-1453: executed outcome probes, IMP-14 surface gate, outcome.serve + V-47/V-48</item>
|
|
17
|
+
</CHANGE_SUMMARY>
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
import { describe, expect, it } from "vitest";
|
|
21
|
+
import {
|
|
22
|
+
evaluateOutcomeGate,
|
|
23
|
+
normalizeOutcomeBuildCommand,
|
|
24
|
+
runProbeMatchesOutcomeBuild,
|
|
25
|
+
} from "./implement-stamp-outcome.ts";
|
|
26
|
+
import type { OriginGit } from "../verification-origin.ts";
|
|
27
|
+
import type { AcceptanceProbe, VerificationEvidenceProbeRecord } from "../types.ts";
|
|
28
|
+
|
|
29
|
+
const SURFACES = ["packages/ui/**"];
|
|
30
|
+
|
|
31
|
+
const pageProbe: AcceptanceProbe = {
|
|
32
|
+
probe: "page",
|
|
33
|
+
target: "site-a",
|
|
34
|
+
path: "/",
|
|
35
|
+
selector: "header .lang-switcher__link",
|
|
36
|
+
criterion: "AC-1",
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
const runProbe: AcceptanceProbe = {
|
|
40
|
+
probe: "run",
|
|
41
|
+
command: "werkstatt run mission.validate --site site-a --json",
|
|
42
|
+
expect: { exitCode: 0 },
|
|
43
|
+
criterion: "AC-2",
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
const record = (
|
|
47
|
+
probe: AcceptanceProbe,
|
|
48
|
+
verdict: "pass" | "fail" | "unverified",
|
|
49
|
+
): VerificationEvidenceProbeRecord => ({
|
|
50
|
+
probe,
|
|
51
|
+
ok: verdict === "pass",
|
|
52
|
+
verdict,
|
|
53
|
+
detail: "fixture",
|
|
54
|
+
durationMs: 0,
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
/** Fake OriginGit — resolves the range from `base`, serves `files` for diff/show. */
|
|
58
|
+
function fakeGit(opts: { base?: string | null; files: string[] }): OriginGit {
|
|
59
|
+
return {
|
|
60
|
+
run: async (args: string[]) => {
|
|
61
|
+
if (args[0] === "rev-parse") return "headsha\n";
|
|
62
|
+
if (args[0] === "log") return opts.base ? `${opts.base}\n` : "";
|
|
63
|
+
if (args[0] === "diff") return opts.files.join("\n") + "\n";
|
|
64
|
+
if (args[0] === "show") return opts.files.join("\n") + "\n";
|
|
65
|
+
return null;
|
|
66
|
+
},
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
const gate = (over: Partial<Parameters<typeof evaluateOutcomeGate>[0]> = {}) =>
|
|
71
|
+
evaluateOutcomeGate({
|
|
72
|
+
targetId: "RFC-9001",
|
|
73
|
+
probes: [pageProbe],
|
|
74
|
+
evidenceRecords: [record(pageProbe, "pass")],
|
|
75
|
+
git: fakeGit({ base: "basesha", files: ["packages/ui/button.ts"] }),
|
|
76
|
+
rfcRelPath: "docs/rfcs/rfc-9001-x.md",
|
|
77
|
+
implementationCommit: "implsha",
|
|
78
|
+
outcomeSurfaces: SURFACES,
|
|
79
|
+
outcomeBuild: "pnpm exec werkstatt run mission.validate --site {target} --json",
|
|
80
|
+
...over,
|
|
81
|
+
});
|
|
82
|
+
|
|
83
|
+
describe("RFC-IMP-14 outcome gate (AC-5)", () => {
|
|
84
|
+
it("blocks when the diff touches an outcome surface and no outcome probe passed", async () => {
|
|
85
|
+
const res = await gate({ evidenceRecords: [record(pageProbe, "fail")] });
|
|
86
|
+
expect(res.errors).toHaveLength(1);
|
|
87
|
+
expect(res.errors[0]?.rule).toBe("RFC-IMP-14");
|
|
88
|
+
expect(res.errors[0]?.message).toContain("packages/ui/button.ts");
|
|
89
|
+
});
|
|
90
|
+
|
|
91
|
+
it("blocks when the only page probe is unverified — unverified is not pass", async () => {
|
|
92
|
+
const res = await gate({ evidenceRecords: [record(pageProbe, "unverified")] });
|
|
93
|
+
expect(res.errors).toHaveLength(1);
|
|
94
|
+
expect(res.errors[0]?.rule).toBe("RFC-IMP-14");
|
|
95
|
+
});
|
|
96
|
+
|
|
97
|
+
it("passes when a page probe passed", async () => {
|
|
98
|
+
const res = await gate();
|
|
99
|
+
expect(res.errors).toEqual([]);
|
|
100
|
+
expect(res.warnings).toEqual([]);
|
|
101
|
+
expect(res.waived).toBe(false);
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
it("passes on a `run` probe equal to the normalized outcomeBuild binding", async () => {
|
|
105
|
+
const res = await gate({
|
|
106
|
+
probes: [runProbe],
|
|
107
|
+
evidenceRecords: [record(runProbe, "pass")],
|
|
108
|
+
});
|
|
109
|
+
expect(res.errors).toEqual([]);
|
|
110
|
+
});
|
|
111
|
+
|
|
112
|
+
it("a `run` probe that is not the outcomeBuild binding does not satisfy the gate", async () => {
|
|
113
|
+
const otherRun: AcceptanceProbe = {
|
|
114
|
+
probe: "run",
|
|
115
|
+
command: "werkstatt run some.other --site site-a",
|
|
116
|
+
expect: { exitCode: 0 },
|
|
117
|
+
criterion: "AC-2",
|
|
118
|
+
};
|
|
119
|
+
const res = await gate({
|
|
120
|
+
probes: [otherRun],
|
|
121
|
+
evidenceRecords: [record(otherRun, "pass")],
|
|
122
|
+
});
|
|
123
|
+
expect(res.errors).toHaveLength(1);
|
|
124
|
+
});
|
|
125
|
+
|
|
126
|
+
it("uses the implementation commit's file set when no accepted base resolves", async () => {
|
|
127
|
+
const res = await gate({
|
|
128
|
+
git: fakeGit({ base: null, files: ["packages/ui/x.ts"] }),
|
|
129
|
+
evidenceRecords: [record(pageProbe, "unverified")],
|
|
130
|
+
});
|
|
131
|
+
expect(res.errors).toHaveLength(1);
|
|
132
|
+
expect(res.errors[0]?.rule).toBe("RFC-IMP-14");
|
|
133
|
+
});
|
|
134
|
+
});
|
|
135
|
+
|
|
136
|
+
describe("RFC-IMP-14 outcome gate (AC-6)", () => {
|
|
137
|
+
it("does not evaluate when no outcomeSurfaces are declared", async () => {
|
|
138
|
+
const res = await gate({ outcomeSurfaces: [], evidenceRecords: [] });
|
|
139
|
+
expect(res.errors).toEqual([]);
|
|
140
|
+
expect(res.warnings).toEqual([]);
|
|
141
|
+
});
|
|
142
|
+
|
|
143
|
+
it("does not evaluate when the diff touches no surface", async () => {
|
|
144
|
+
const res = await gate({
|
|
145
|
+
git: fakeGit({ base: "basesha", files: ["packages/core/x.ts", "docs/rfcs/rfc-9001-x.md"] }),
|
|
146
|
+
evidenceRecords: [],
|
|
147
|
+
});
|
|
148
|
+
expect(res.errors).toEqual([]);
|
|
149
|
+
});
|
|
150
|
+
});
|
|
151
|
+
|
|
152
|
+
describe("RFC-IMP-14 outcome gate (AC-7)", () => {
|
|
153
|
+
it("converts the block into a recorded warning under --waive-outcome", async () => {
|
|
154
|
+
const res = await gate({
|
|
155
|
+
evidenceRecords: [record(pageProbe, "fail")],
|
|
156
|
+
waiveOutcome: "pilot dist rebuild pending — operator approved",
|
|
157
|
+
});
|
|
158
|
+
expect(res.errors).toEqual([]);
|
|
159
|
+
expect(res.warnings).toHaveLength(1);
|
|
160
|
+
expect(res.warnings[0]?.rule).toBe("RFC-IMP-14");
|
|
161
|
+
expect(res.warnings[0]?.message).toContain("X-Outcome-Waiver");
|
|
162
|
+
expect(res.waived).toBe(true);
|
|
163
|
+
});
|
|
164
|
+
});
|
|
165
|
+
|
|
166
|
+
describe("runProbeMatchesOutcomeBuild / normalizeOutcomeBuildCommand", () => {
|
|
167
|
+
const binding = "pnpm exec werkstatt run mission.validate --site {target} --json";
|
|
168
|
+
|
|
169
|
+
it("strips the pnpm exec prefix and substitutes {target}", () => {
|
|
170
|
+
expect(normalizeOutcomeBuildCommand(binding)).toBe(
|
|
171
|
+
"werkstatt run mission.validate --site {target} --json",
|
|
172
|
+
);
|
|
173
|
+
expect(runProbeMatchesOutcomeBuild("werkstatt run mission.validate --site dp7 --json", binding)).toBe(
|
|
174
|
+
true,
|
|
175
|
+
);
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
it("collapses whitespace differences", () => {
|
|
179
|
+
expect(
|
|
180
|
+
runProbeMatchesOutcomeBuild("werkstatt run mission.validate --site dp7 --json", binding),
|
|
181
|
+
).toBe(true);
|
|
182
|
+
});
|
|
183
|
+
|
|
184
|
+
it("rejects a different command", () => {
|
|
185
|
+
expect(runProbeMatchesOutcomeBuild("werkstatt run other.cmd --site dp7", binding)).toBe(false);
|
|
186
|
+
});
|
|
187
|
+
|
|
188
|
+
it("rejects when the binding is absent", () => {
|
|
189
|
+
expect(runProbeMatchesOutcomeBuild("werkstatt run mission.validate --site dp7 --json", null)).toBe(
|
|
190
|
+
false,
|
|
191
|
+
);
|
|
192
|
+
});
|
|
193
|
+
});
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>
|
|
4
|
+
RFC-1453: RFC-IMP-14 outcome gate — when an RFC's implementation diff touches
|
|
5
|
+
a declared `outcomeSurfaces` glob (forge.yaml), the stamp requires at least
|
|
6
|
+
one executed, passing outcome probe: a `page` probe, or a `run` probe whose
|
|
7
|
+
command equals the normalized `outcomeBuild` binding. The diff reuses the
|
|
8
|
+
RFC-1330 implementation-range machinery; an unresolved range falls back to
|
|
9
|
+
the implementation commit's own changed file set so the gate always
|
|
10
|
+
evaluates a deterministic file set.
|
|
11
|
+
</purpose>
|
|
12
|
+
<non-goals>
|
|
13
|
+
<item>Do not re-execute probes at stamp time — the gate reads the committed envelope's recorded verdicts.</item>
|
|
14
|
+
<item>Do not evaluate when no outcome surfaces are declared or no diff path matches — projects without surfaces are unaffected.</item>
|
|
15
|
+
</non-goals>
|
|
16
|
+
</MODULE_CONTRACT>
|
|
17
|
+
<CHANGE_SUMMARY>
|
|
18
|
+
<item>RFC-1453: outcome gate evaluator — diff/surface match, outcome-probe satisfaction, --waive-outcome warning path.</item>
|
|
19
|
+
<item>RFC-1453: executed outcome probes, IMP-14 surface gate, outcome.serve + V-47/V-48</item>
|
|
20
|
+
</CHANGE_SUMMARY>
|
|
21
|
+
*/
|
|
22
|
+
|
|
23
|
+
import picomatch from "picomatch";
|
|
24
|
+
import type {
|
|
25
|
+
AcceptanceProbe,
|
|
26
|
+
VerificationEvidenceProbeRecord,
|
|
27
|
+
} from "../types.ts";
|
|
28
|
+
import {
|
|
29
|
+
createOriginGit,
|
|
30
|
+
resolveImplementationRange,
|
|
31
|
+
type OriginGit,
|
|
32
|
+
} from "../verification-origin.ts";
|
|
33
|
+
|
|
34
|
+
export interface OutcomeGateInput {
|
|
35
|
+
targetId: string;
|
|
36
|
+
/** The RFC's declared acceptance probes. */
|
|
37
|
+
probes: AcceptanceProbe[];
|
|
38
|
+
/** Committed envelope probe records (verdicts read here, not re-executed). */
|
|
39
|
+
evidenceRecords: VerificationEvidenceProbeRecord[] | undefined;
|
|
40
|
+
git: OriginGit;
|
|
41
|
+
rfcRelPath: string;
|
|
42
|
+
/** Validated implementation commit (RFC-IMP-03) — fallback diff source when the accepted-transition base is unresolved. */
|
|
43
|
+
implementationCommit?: string;
|
|
44
|
+
/** forge.yaml `outcomeSurfaces` globs (repo-root-relative). */
|
|
45
|
+
outcomeSurfaces: string[];
|
|
46
|
+
/** forge.yaml `bindings.commands.outcomeBuild` — for `run`-probe normalization. */
|
|
47
|
+
outcomeBuild: string | null;
|
|
48
|
+
/** Operator waiver reason (operator-directed only — never agent-initiated). */
|
|
49
|
+
waiveOutcome?: string;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export interface OutcomeGateResult {
|
|
53
|
+
errors: Array<{ rule: "RFC-IMP-14"; message: string }>;
|
|
54
|
+
warnings: Array<{ rule: "RFC-IMP-14"; message: string }>;
|
|
55
|
+
/** True when a touched surface + waived gate fired — the caller records the waiver in the envelope. */
|
|
56
|
+
waived: boolean;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** Strips a leading `pnpm exec ` and collapses whitespace — the comparison form for `run`-probe equality. */
|
|
60
|
+
export function normalizeOutcomeBuildCommand(binding: string): string {
|
|
61
|
+
return binding.replace(/^pnpm exec\s+/, "").replace(/\s+/g, " ").trim();
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* True when a `run` probe's command equals the normalized outcomeBuild
|
|
66
|
+
* binding for some target. `{target}` in the binding matches one non-space
|
|
67
|
+
* token (e.g. `--site {target}` matches `--site dp7`).
|
|
68
|
+
*/
|
|
69
|
+
export function runProbeMatchesOutcomeBuild(command: string, outcomeBuild: string | null): boolean {
|
|
70
|
+
if (!outcomeBuild) return false;
|
|
71
|
+
const normalized = normalizeOutcomeBuildCommand(outcomeBuild);
|
|
72
|
+
const probeCommand = command.replace(/\s+/g, " ").trim();
|
|
73
|
+
if (!normalized.includes("{target}")) {
|
|
74
|
+
return probeCommand === normalized;
|
|
75
|
+
}
|
|
76
|
+
const [prefix, suffix] = normalized.split("{target}", 2).map((s) => s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"));
|
|
77
|
+
return new RegExp(`^${prefix}\\S+${suffix}$`).test(probeCommand);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
async function diffFiles(
|
|
81
|
+
git: OriginGit,
|
|
82
|
+
rfcRelPath: string,
|
|
83
|
+
implementationCommit?: string,
|
|
84
|
+
): Promise<string[]> {
|
|
85
|
+
const range = await resolveImplementationRange(git, rfcRelPath);
|
|
86
|
+
if (range.base) {
|
|
87
|
+
const out = await git.run(["diff", "--name-only", `${range.base}..${range.head}`]);
|
|
88
|
+
return (out ?? "").split("\n").map((l) => l.trim()).filter(Boolean);
|
|
89
|
+
}
|
|
90
|
+
if (implementationCommit) {
|
|
91
|
+
const out = await git.run(["show", "--name-only", "--format=", implementationCommit]);
|
|
92
|
+
return (out ?? "").split("\n").map((l) => l.trim()).filter(Boolean);
|
|
93
|
+
}
|
|
94
|
+
return [];
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
function recordVerdict(rec: VerificationEvidenceProbeRecord): "pass" | "fail" | "unverified" {
|
|
98
|
+
return rec.verdict ?? (rec.ok ? "pass" : "fail");
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export async function evaluateOutcomeGate(input: OutcomeGateInput): Promise<OutcomeGateResult> {
|
|
102
|
+
const errors: OutcomeGateResult["errors"] = [];
|
|
103
|
+
const warnings: OutcomeGateResult["warnings"] = [];
|
|
104
|
+
const empty = { errors, warnings, waived: false };
|
|
105
|
+
|
|
106
|
+
if (input.outcomeSurfaces.length === 0) return empty;
|
|
107
|
+
|
|
108
|
+
const files = await diffFiles(input.git, input.rfcRelPath, input.implementationCommit);
|
|
109
|
+
if (files.length === 0) return empty;
|
|
110
|
+
|
|
111
|
+
const matches = picomatch(input.outcomeSurfaces, { dot: true });
|
|
112
|
+
const touched = files.filter((f) => matches(f));
|
|
113
|
+
if (touched.length === 0) return empty;
|
|
114
|
+
|
|
115
|
+
const satisfied = (input.evidenceRecords ?? []).some((rec) => {
|
|
116
|
+
if (recordVerdict(rec) !== "pass") return false;
|
|
117
|
+
if (rec.probe.probe === "page") return true;
|
|
118
|
+
if (rec.probe.probe === "run") {
|
|
119
|
+
return runProbeMatchesOutcomeBuild(rec.probe.command, input.outcomeBuild);
|
|
120
|
+
}
|
|
121
|
+
return false;
|
|
122
|
+
});
|
|
123
|
+
if (satisfied) return empty;
|
|
124
|
+
|
|
125
|
+
const detail =
|
|
126
|
+
`${input.targetId}: implementation diff touches ${touched.length} outcome-surface file(s) ` +
|
|
127
|
+
`(e.g. ${touched.slice(0, 3).join(", ")}) but no outcome probe passed — ` +
|
|
128
|
+
`record a passing \`page\` probe or a \`run\` probe equal to the outcomeBuild binding in the evidence envelope.`;
|
|
129
|
+
|
|
130
|
+
if (input.waiveOutcome) {
|
|
131
|
+
warnings.push({
|
|
132
|
+
rule: "RFC-IMP-14",
|
|
133
|
+
message:
|
|
134
|
+
`${detail} Waived by operator: "${input.waiveOutcome}" — the waiver is recorded in the verification envelope ` +
|
|
135
|
+
`and the stamp commit must carry an \`X-Outcome-Waiver:\` trailer.`,
|
|
136
|
+
});
|
|
137
|
+
return { errors, warnings, waived: true };
|
|
138
|
+
}
|
|
139
|
+
errors.push({
|
|
140
|
+
rule: "RFC-IMP-14",
|
|
141
|
+
message: `${detail} Operator override: re-run with --waive-outcome "<reason>" (operator-directed only).`,
|
|
142
|
+
});
|
|
143
|
+
return { errors, warnings, waived: false };
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export { createOriginGit };
|
|
@@ -12,12 +12,12 @@ verification evidence, and atomically mutates RFC frontmatter.
|
|
|
12
12
|
</non-goals>
|
|
13
13
|
</MODULE_CONTRACT>
|
|
14
14
|
<CHANGE_SUMMARY>
|
|
15
|
-
<item>RFC-1322: fo-review fix pass — io-injected resolver hardening (empty/dir/escape paths fail closed, line-range strip, probes-less envelope guard), shared IMP-06/09 evaluator, dry-run JSON fields, helpers exported per plan</item>
|
|
16
|
-
<item>RFC-1322: evidence annotation extraction takes the last occurrence — prose mentions no longer shadow the annotation</item>
|
|
17
|
-
<item>RFC-1330: origin gates wired into the shared evidence evaluator; non-blocking warnings surfaced in results.</item>
|
|
18
15
|
<item>RFC-1333: steps 1-3 — report contract, rfc.verify.workspace export, RFC-IMP-12 gate, RFC-IMP-11 blocking</item>
|
|
19
16
|
<item>RFC-1333: CX-1/CX-2 fixes — docs/** binding, waiver covers a missing report, IMP-12 for probe-less RFCs; merge-aware fail-closed binding.</item>
|
|
20
|
-
<
|
|
17
|
+
<item>RFC-1391: make the formal verification tier checker-bound (RFC-1391)</item>
|
|
18
|
+
<item>RFC-1453: executed outcome probes, IMP-14 surface gate, outcome.serve + V-47/V-48</item>
|
|
19
|
+
<item>RFC-1454: review deviations recorded in the RFC — IMP-15 gate, V-49 provenance, skill contract</item>
|
|
20
|
+
<history>RFC-0268, RFC-0476, RFC-0756, RFC-0795, RFC-0997, RFC-1053, RFC-1097, RFC-1249, RFC-1271, RFC-1306, RFC-1310, RFC-1321, RFC-1322, RFC-1330, RFC-1383, RFC-IMP-07</history>
|
|
21
21
|
</CHANGE_SUMMARY>
|
|
22
22
|
*/
|
|
23
23
|
|
|
@@ -36,7 +36,8 @@ import {
|
|
|
36
36
|
rfcFileMatchesId,
|
|
37
37
|
loadRfcStatusMap,
|
|
38
38
|
} from "../frontmatter-io.ts";
|
|
39
|
-
import { evaluateAcceptanceCriteria } from "./validate-rules.ts";
|
|
39
|
+
import { evaluateAcceptanceCriteria, stripFencedCodeBlocks } from "./validate-rules.ts";
|
|
40
|
+
import { evaluateDeviationGate } from "./implement-stamp-deviations.ts";
|
|
40
41
|
import { toIsoDate } from "./shared.ts";
|
|
41
42
|
import { byteHashHex, normalizeProbes, runRfcVerificationEmit } from "../verification-evidence.ts";
|
|
42
43
|
import {
|
|
@@ -47,6 +48,7 @@ import {
|
|
|
47
48
|
} from "../types.ts";
|
|
48
49
|
import {
|
|
49
50
|
createOriginGit,
|
|
51
|
+
createProofEntryResolver,
|
|
50
52
|
deriveProbeOrigins,
|
|
51
53
|
gitEnvForCwd,
|
|
52
54
|
hasVerifierTrailers,
|
|
@@ -54,8 +56,11 @@ import {
|
|
|
54
56
|
import {
|
|
55
57
|
ACCEPTANCE_REPORTS_DIR,
|
|
56
58
|
evaluateAcceptanceVerificationGate,
|
|
59
|
+
evaluateFormalProofGate,
|
|
57
60
|
evaluateOriginGates,
|
|
58
61
|
} from "./implement-stamp-origin.ts";
|
|
62
|
+
import { evaluateOutcomeGate } from "./implement-stamp-outcome.ts";
|
|
63
|
+
import { loadForgeConfig } from "../../../src/config/forge-config.ts";
|
|
59
64
|
import type {
|
|
60
65
|
RfcStatus,
|
|
61
66
|
RfcImplementStampViolation,
|
|
@@ -513,6 +518,10 @@ async function evaluateStampEvidenceGates(opts: {
|
|
|
513
518
|
workspaceRoot: string;
|
|
514
519
|
/** RFC-1333: operator waiver for a missing report or non-subagent isolation. */
|
|
515
520
|
waiverReason?: string;
|
|
521
|
+
/** RFC-1453: validated implementation commit — fallback diff source for RFC-IMP-14. */
|
|
522
|
+
implementationCommit?: string;
|
|
523
|
+
/** RFC-1453: operator waiver for the outcome gate (--waive-outcome). */
|
|
524
|
+
waiveOutcome?: string;
|
|
516
525
|
}): Promise<{
|
|
517
526
|
violations: RfcImplementStampViolation[];
|
|
518
527
|
warnings: RfcImplementStampViolation[];
|
|
@@ -533,6 +542,7 @@ async function evaluateStampEvidenceGates(opts: {
|
|
|
533
542
|
rfcRelPath: relative(opts.workspaceRoot, rfcFilePath),
|
|
534
543
|
frontmatter: opts.frontmatter,
|
|
535
544
|
probes,
|
|
545
|
+
resolveProofEntry: createProofEntryResolver(opts.workspaceRoot),
|
|
536
546
|
});
|
|
537
547
|
const gate = evaluateOriginGates({
|
|
538
548
|
targetId,
|
|
@@ -557,6 +567,64 @@ async function evaluateStampEvidenceGates(opts: {
|
|
|
557
567
|
violations.push(...acc.errors);
|
|
558
568
|
warnings.push(...acc.warnings);
|
|
559
569
|
|
|
570
|
+
// ── RFC-IMP-13: formal tier requires proved proof probes (RFC-1391) ────────
|
|
571
|
+
// No waiver path — formal evidence is a mechanical checker verdict by
|
|
572
|
+
// definition. Reads the committed envelope's proof verdicts.
|
|
573
|
+
const formal = evaluateFormalProofGate({
|
|
574
|
+
targetId,
|
|
575
|
+
frontmatter: opts.frontmatter,
|
|
576
|
+
probes: (Array.isArray(acceptance) ? acceptance : []) as AcceptanceProbe[],
|
|
577
|
+
evidenceRecords: evidenceCheck.envelope?.probes,
|
|
578
|
+
});
|
|
579
|
+
violations.push(...formal.errors);
|
|
580
|
+
warnings.push(...formal.warnings);
|
|
581
|
+
|
|
582
|
+
// ── RFC-IMP-14: outcome-surface diffs need a passing outcome probe (RFC-1453) ──
|
|
583
|
+
// Evaluates the committed envelope's recorded verdicts — never re-executes.
|
|
584
|
+
{
|
|
585
|
+
let outcomeSurfaces: string[] = [];
|
|
586
|
+
let outcomeBuild: string | null = null;
|
|
587
|
+
try {
|
|
588
|
+
const cfg = loadForgeConfig(opts.workspaceRoot);
|
|
589
|
+
outcomeSurfaces = cfg.outcomeSurfaces ?? [];
|
|
590
|
+
outcomeBuild = cfg.bindings?.commands.outcomeBuild ?? null;
|
|
591
|
+
} catch {
|
|
592
|
+
// No readable forge.yaml → no declared surfaces → gate not evaluated.
|
|
593
|
+
}
|
|
594
|
+
if (outcomeSurfaces.length > 0) {
|
|
595
|
+
const outcome = await evaluateOutcomeGate({
|
|
596
|
+
targetId,
|
|
597
|
+
probes: (Array.isArray(acceptance) ? acceptance : []) as AcceptanceProbe[],
|
|
598
|
+
evidenceRecords: evidenceCheck.envelope?.probes,
|
|
599
|
+
git: createOriginGit(opts.workspaceRoot),
|
|
600
|
+
rfcRelPath: relative(opts.workspaceRoot, rfcFilePath),
|
|
601
|
+
implementationCommit: opts.implementationCommit,
|
|
602
|
+
outcomeSurfaces,
|
|
603
|
+
outcomeBuild,
|
|
604
|
+
waiveOutcome: opts.waiveOutcome,
|
|
605
|
+
});
|
|
606
|
+
violations.push(...outcome.errors);
|
|
607
|
+
warnings.push(...outcome.warnings);
|
|
608
|
+
}
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
// ── RFC-IMP-15: amend review deviations recorded in ## Deviations (RFC-1454) ──
|
|
612
|
+
{
|
|
613
|
+
let reviewsDir: string | null = null;
|
|
614
|
+
try {
|
|
615
|
+
reviewsDir = loadForgeConfig(opts.workspaceRoot).bindings?.paths?.reviewsDir ?? null;
|
|
616
|
+
} catch {
|
|
617
|
+
// No readable forge.yaml → null reviewsDir → gate passes.
|
|
618
|
+
}
|
|
619
|
+
const deviations = await evaluateDeviationGate({
|
|
620
|
+
rfcId: targetId,
|
|
621
|
+
strippedRfcBody: stripFencedCodeBlocks(await opts.io.readFile(rfcFilePath)),
|
|
622
|
+
git: createOriginGit(opts.workspaceRoot),
|
|
623
|
+
reviewsDir,
|
|
624
|
+
});
|
|
625
|
+
violations.push(...deviations.errors);
|
|
626
|
+
}
|
|
627
|
+
|
|
560
628
|
// ── RFC-IMP-06: probe-bearing post-cutoff RFCs need a passing envelope ────
|
|
561
629
|
if (requiresEvidence) {
|
|
562
630
|
if (!evidenceCheck.exists || evidenceCheck.overall !== "pass") {
|
|
@@ -815,10 +883,14 @@ export async function runRfcImplementStamp(
|
|
|
815
883
|
// candidates for the auto-check pass, and checkedWithoutEvidence re-runs on
|
|
816
884
|
// the post-flip body — a flipped line always keeps its annotation.
|
|
817
885
|
const criteriaEval = evaluateAcceptanceCriteria(body);
|
|
886
|
+
// RFC-1383: the unchecked violation names the remedy — --check-criteria
|
|
887
|
+
// auto-verifies resolvable criteria in-place. This branch only runs when
|
|
888
|
+
// the flag was NOT passed, so the hint can never offer a no-op.
|
|
889
|
+
const criteriaTotal = criteriaEval.totalChecked + criteriaEval.totalUnchecked;
|
|
818
890
|
if (!checkCriteria && criteriaEval.totalUnchecked > 0) {
|
|
819
891
|
violations.push({
|
|
820
892
|
rule: "RFC-IMP-02",
|
|
821
|
-
message: `${criteriaEval.totalUnchecked} acceptance criteria are unchecked. All criteria must be checked before stamping: ${criteriaEval.uncheckedLines.join("; ")}
|
|
893
|
+
message: `${criteriaEval.totalUnchecked} acceptance criteria are unchecked. All criteria must be checked before stamping: ${criteriaEval.uncheckedLines.join("; ")}. Re-run with --check-criteria to auto-verify resolvable criteria, or annotate evidence on each criterion and re-run.`,
|
|
822
894
|
});
|
|
823
895
|
}
|
|
824
896
|
if (!checkCriteria && criteriaEval.checkedWithoutEvidence.length > 0) {
|
|
@@ -970,6 +1042,13 @@ export async function runRfcImplementStamp(
|
|
|
970
1042
|
const waiverFlag = input.flags["waive-independent-verification"];
|
|
971
1043
|
const waiverReason =
|
|
972
1044
|
typeof waiverFlag === "string" && waiverFlag.trim() ? waiverFlag.trim() : undefined;
|
|
1045
|
+
// RFC-1453: operator-only waiver for the outcome gate — agents MUST NOT
|
|
1046
|
+
// pass it unless the operator directed it in the current request.
|
|
1047
|
+
const outcomeWaiverFlag = input.flags["waive-outcome"];
|
|
1048
|
+
const waiveOutcome =
|
|
1049
|
+
typeof outcomeWaiverFlag === "string" && outcomeWaiverFlag.trim()
|
|
1050
|
+
? outcomeWaiverFlag.trim()
|
|
1051
|
+
: undefined;
|
|
973
1052
|
|
|
974
1053
|
// RFC-1271: the envelope is fetched unconditionally — a committed envelope
|
|
975
1054
|
// must also be evaluated when hasProbes is now false, because probe
|
|
@@ -993,6 +1072,8 @@ export async function runRfcImplementStamp(
|
|
|
993
1072
|
frontmatter: fm,
|
|
994
1073
|
workspaceRoot,
|
|
995
1074
|
waiverReason,
|
|
1075
|
+
implementationCommit,
|
|
1076
|
+
waiveOutcome,
|
|
996
1077
|
});
|
|
997
1078
|
violations.push(...gates.violations);
|
|
998
1079
|
stampWarnings.push(...gates.warnings);
|
|
@@ -1054,7 +1135,13 @@ export async function runRfcImplementStamp(
|
|
|
1054
1135
|
let emitSummary = "";
|
|
1055
1136
|
try {
|
|
1056
1137
|
const emitResult = await runRfcVerificationEmit(
|
|
1057
|
-
{
|
|
1138
|
+
{
|
|
1139
|
+
argv: [],
|
|
1140
|
+
flags: {
|
|
1141
|
+
id: targetId,
|
|
1142
|
+
...(waiveOutcome ? { "waive-outcome": waiveOutcome } : {}),
|
|
1143
|
+
},
|
|
1144
|
+
},
|
|
1058
1145
|
context,
|
|
1059
1146
|
);
|
|
1060
1147
|
emitOk = emitResult.exitCode === 0;
|
|
@@ -1143,6 +1230,8 @@ export async function runRfcImplementStamp(
|
|
|
1143
1230
|
frontmatter: fm,
|
|
1144
1231
|
workspaceRoot,
|
|
1145
1232
|
waiverReason,
|
|
1233
|
+
implementationCommit,
|
|
1234
|
+
waiveOutcome,
|
|
1146
1235
|
});
|
|
1147
1236
|
violations.push(...gates.violations);
|
|
1148
1237
|
stampWarnings.push(...gates.warnings);
|
|
@@ -1163,7 +1252,7 @@ export async function runRfcImplementStamp(
|
|
|
1163
1252
|
if (outputFormat === "pretty") {
|
|
1164
1253
|
logger.success(`[dry-run] ${targetId} would be stamped as implemented`);
|
|
1165
1254
|
logger.info(` implementation commit: ${implementationCommit}`);
|
|
1166
|
-
logger.info(` criteria checked: ${effectiveCriteriaChecked}`);
|
|
1255
|
+
logger.info(` criteria checked: ${effectiveCriteriaChecked} of ${criteriaTotal}`);
|
|
1167
1256
|
if (criteriaAutoChecked && criteriaAutoChecked.length > 0) {
|
|
1168
1257
|
logger.info(` criteria auto-checked: ${criteriaAutoChecked.join(", ")}`);
|
|
1169
1258
|
}
|
|
@@ -1187,6 +1276,7 @@ export async function runRfcImplementStamp(
|
|
|
1187
1276
|
implementationCommit: implementationCommit!,
|
|
1188
1277
|
stampedAt,
|
|
1189
1278
|
criteriaChecked: effectiveCriteriaChecked,
|
|
1279
|
+
criteriaTotal,
|
|
1190
1280
|
...(checkCriteria
|
|
1191
1281
|
? {
|
|
1192
1282
|
criteriaAutoChecked: criteriaAutoChecked ?? [],
|
|
@@ -1230,7 +1320,13 @@ export async function runRfcImplementStamp(
|
|
|
1230
1320
|
if (hasProbes) {
|
|
1231
1321
|
try {
|
|
1232
1322
|
const emitResult = await runRfcVerificationEmit(
|
|
1233
|
-
{
|
|
1323
|
+
{
|
|
1324
|
+
argv: [],
|
|
1325
|
+
flags: {
|
|
1326
|
+
id: targetId,
|
|
1327
|
+
...(waiveOutcome ? { "waive-outcome": waiveOutcome } : {}),
|
|
1328
|
+
},
|
|
1329
|
+
},
|
|
1234
1330
|
context,
|
|
1235
1331
|
);
|
|
1236
1332
|
evidenceReEmitted = emitResult.exitCode === 0;
|
|
@@ -1251,7 +1347,7 @@ export async function runRfcImplementStamp(
|
|
|
1251
1347
|
if (outputFormat === "pretty") {
|
|
1252
1348
|
logger.success(`${targetId} stamped as implemented`);
|
|
1253
1349
|
logger.info(` implementation commit: ${implementationCommit}`);
|
|
1254
|
-
logger.info(` criteria checked: ${effectiveCriteriaChecked}`);
|
|
1350
|
+
logger.info(` criteria checked: ${effectiveCriteriaChecked} of ${criteriaTotal}`);
|
|
1255
1351
|
if (criteriaAutoChecked && criteriaAutoChecked.length > 0) {
|
|
1256
1352
|
logger.info(` criteria auto-checked: ${criteriaAutoChecked.join(", ")}`);
|
|
1257
1353
|
}
|
|
@@ -1271,6 +1367,7 @@ export async function runRfcImplementStamp(
|
|
|
1271
1367
|
implementationCommit: implementationCommit!,
|
|
1272
1368
|
stampedAt,
|
|
1273
1369
|
criteriaChecked: effectiveCriteriaChecked,
|
|
1370
|
+
criteriaTotal,
|
|
1274
1371
|
...(checkCriteria ? { criteriaAutoChecked: criteriaAutoChecked ?? [] } : {}),
|
|
1275
1372
|
...(evidenceRelPath ? { evidencePath: evidenceRelPath } : {}),
|
|
1276
1373
|
...(hasProbes ? { evidenceReEmitted } : {}),
|