@warpgogol/forge 8.0.4 → 9.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +56 -0
- package/bin/cli.ts +26 -13
- package/dist/bin/cli.js +18 -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 +209 -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 +18 -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/authority/handlers/delegate.d.ts.map +1 -1
- package/dist/os/authority/handlers/delegate.js +2 -1
- package/dist/os/authority/handlers/delegate.js.map +1 -1
- package/dist/os/authority/index.d.ts.map +1 -1
- package/dist/os/authority/index.js +2 -1
- package/dist/os/authority/index.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 +94 -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 +265 -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 +126 -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 +155 -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 +135 -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 +17 -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-docs-scaffold.js +1 -1
- package/dist/os/compass/handlers/compass-header-scaffold.d.ts.map +1 -1
- package/dist/os/compass/handlers/compass-header-scaffold.js +10 -3
- 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 +209 -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 +73 -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 +146 -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 +74 -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 +191 -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 +16 -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 +70 -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 +232 -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 +15 -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 +75 -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 +202 -0
- package/dist/os/knowledge/handlers/knowledge-authz-probe.js.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.d.ts +11 -0
- package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.d.ts.map +1 -0
- package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.js +428 -0
- package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.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 +141 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.js.map +1 -0
- package/dist/os/knowledge/index.d.ts +5 -0
- package/dist/os/knowledge/index.d.ts.map +1 -0
- package/dist/os/knowledge/index.js +17 -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 +95 -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/manifest.d.ts.map +1 -1
- package/dist/os/queue/manifest.js +8 -7
- package/dist/os/queue/manifest.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 +41 -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 +48 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.js +148 -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 +67 -7
- package/dist/os/rfc/handlers/implement-stamp-origin.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts +44 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts.map +1 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.js +104 -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 +262 -56
- 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/lifecycle.d.ts.map +1 -1
- package/dist/os/rfc/handlers/lifecycle.js +13 -6
- package/dist/os/rfc/handlers/lifecycle.js.map +1 -1
- package/dist/os/rfc/handlers/list-create.d.ts.map +1 -1
- package/dist/os/rfc/handlers/list-create.js +144 -13
- 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 +54 -13
- 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 +68 -15
- package/dist/os/rfc/rfc.module.js.map +1 -1
- package/dist/os/rfc/types.d.ts +110 -12
- package/dist/os/rfc/types.d.ts.map +1 -1
- package/dist/os/rfc/types.js +24 -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 +188 -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/save.d.ts.map +1 -1
- package/dist/os/session/handlers/save.js +5 -2
- package/dist/os/session/handlers/save.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 +82 -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 +269 -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 +60 -0
- package/dist/os/trajectory/handlers/journal-io.d.ts.map +1 -0
- package/dist/os/trajectory/handlers/journal-io.js +179 -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 +145 -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 +449 -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 +179 -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 +16 -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 +98 -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 +56 -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 +28 -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 +46 -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 +34 -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/os/yaml/handlers/scalars-validate.d.ts +28 -0
- package/dist/os/yaml/handlers/scalars-validate.d.ts.map +1 -0
- package/dist/os/yaml/handlers/scalars-validate.js +311 -0
- package/dist/os/yaml/handlers/scalars-validate.js.map +1 -0
- package/dist/os/yaml/index.d.ts +4 -0
- package/dist/os/yaml/index.d.ts.map +1 -0
- package/dist/os/yaml/index.js +15 -0
- package/dist/os/yaml/index.js.map +1 -0
- package/dist/os/yaml/yaml.module.d.ts +3 -0
- package/dist/os/yaml/yaml.module.d.ts.map +1 -0
- package/dist/os/yaml/yaml.module.js +58 -0
- package/dist/os/yaml/yaml.module.js.map +1 -0
- 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 +6 -3
- 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 +91 -16
- 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 +219 -0
- package/dist/src/compass/invariant-parser.js.map +1 -0
- package/dist/src/config/forge-config.d.ts +125 -0
- package/dist/src/config/forge-config.d.ts.map +1 -1
- package/dist/src/config/forge-config.js +110 -17
- 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 +141 -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 +17 -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 +451 -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 +97 -0
- package/dist/src/formal/proof-spec.js.map +1 -0
- package/dist/src/index.d.ts +1 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +1 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/knowledge/index.d.ts +2 -2
- package/dist/src/knowledge/index.d.ts.map +1 -1
- package/dist/src/knowledge/index.js +4 -3
- package/dist/src/knowledge/index.js.map +1 -1
- package/dist/src/knowledge/parse.d.ts +1 -0
- package/dist/src/knowledge/parse.d.ts.map +1 -1
- package/dist/src/knowledge/parse.js +20 -18
- package/dist/src/knowledge/parse.js.map +1 -1
- 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 +10 -4
- 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/knowledge/sync.d.ts +61 -0
- package/dist/src/knowledge/sync.d.ts.map +1 -1
- package/dist/src/knowledge/sync.js +202 -7
- package/dist/src/knowledge/sync.js.map +1 -1
- package/dist/src/onboarding/agents-generate.d.ts.map +1 -1
- package/dist/src/onboarding/agents-generate.js +18 -3
- package/dist/src/onboarding/agents-generate.js.map +1 -1
- package/dist/src/onboarding/compass-docs/semantic-layer-block.js +1 -1
- package/dist/src/onboarding/doctor.d.ts +2 -0
- package/dist/src/onboarding/doctor.d.ts.map +1 -1
- package/dist/src/onboarding/doctor.js +253 -27
- 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/onboarding/nested-agents-generate.js +1 -1
- package/dist/src/onboarding/nested-agents-templates.js +1 -1
- package/dist/src/onboarding/upgrade.d.ts.map +1 -1
- package/dist/src/onboarding/upgrade.js +18 -10
- package/dist/src/onboarding/upgrade.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 +83 -0
- package/dist/src/reachability/command-mentions.js.map +1 -0
- package/dist/src/registry.d.ts +30 -0
- package/dist/src/registry.d.ts.map +1 -1
- package/dist/src/registry.js +168 -68
- 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/dist/src/validators/skill-validate.d.ts +5 -0
- package/dist/src/validators/skill-validate.d.ts.map +1 -1
- package/dist/src/validators/skill-validate.js +34 -8
- package/dist/src/validators/skill-validate.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 +232 -0
- package/os/agent/index.ts +18 -0
- package/os/agent/invoke-adapter.ts +119 -0
- package/os/authority/authority.module.ts +2 -10
- package/os/authority/handlers/delegate.ts +2 -1
- package/os/authority/index.ts +2 -1
- package/os/checks/checks.module.ts +99 -0
- package/os/checks/handlers/contribution-report.test.ts +250 -0
- package/os/checks/handlers/contribution-report.ts +317 -0
- package/os/checks/handlers/counters-export.test.ts +181 -0
- package/os/checks/handlers/counters-export.ts +174 -0
- package/os/checks/handlers/counters-journal.test.ts +193 -0
- package/os/checks/handlers/counters-journal.ts +180 -0
- package/os/checks/handlers/counters-validate.test.ts +182 -0
- package/os/checks/handlers/counters-validate.ts +163 -0
- package/os/checks/handlers/variant-candidates.test.ts +71 -0
- package/os/checks/index.ts +27 -0
- package/os/compass/compass.module.ts +58 -20
- package/os/compass/handlers/compass-docs-scaffold.ts +1 -1
- package/os/compass/handlers/compass-header-scaffold.ts +10 -3
- package/os/compass/handlers/compass-invariants-generate.ts +294 -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 +78 -0
- package/os/context/handlers/context-assemble.test.ts +95 -0
- package/os/context/handlers/context-assemble.ts +175 -0
- package/os/context/handlers/context-slate-eval.test.ts +70 -0
- package/os/context/handlers/context-slate-eval.ts +90 -0
- package/os/context/handlers/index-build.test.ts +101 -0
- package/os/context/handlers/index-build.ts +214 -0
- package/os/context/handlers/no-model-deps.test.ts +38 -0
- package/os/context/handlers/slate-fill.test.ts +37 -0
- package/os/context/index.ts +16 -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 +82 -0
- package/os/gate/handlers/gate-probe-catalog.ts +89 -0
- package/os/gate/handlers/gate-probe.test.ts +114 -0
- package/os/gate/handlers/gate-probe.ts +256 -0
- package/os/gate/index.ts +15 -0
- package/os/instructions/budget.test.ts +131 -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 +79 -0
- package/os/knowledge/handlers/knowledge-authz-probe.test.ts +107 -0
- package/os/knowledge/handlers/knowledge-authz-probe.ts +240 -0
- package/os/knowledge/handlers/knowledge-conflicts-resolve.ts +571 -0
- package/os/knowledge/handlers/knowledge-rebuild.test.ts +82 -0
- package/os/knowledge/handlers/knowledge-rebuild.ts +167 -0
- package/os/knowledge/index.ts +17 -0
- package/os/knowledge/knowledge.module.ts +100 -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 +71 -1
- package/os/queue/handlers/queue-validate.ts +132 -5
- package/os/queue/manifest.ts +8 -7
- 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 +150 -0
- package/os/resolver/handlers/resolver-doors-audit.ts +281 -0
- package/os/resolver/resolver.module.ts +44 -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 +186 -0
- package/os/rfc/handlers/implement-stamp-formal.test.ts +168 -0
- package/os/rfc/handlers/implement-stamp-origin.ts +97 -13
- package/os/rfc/handlers/implement-stamp-outcome.test.ts +193 -0
- package/os/rfc/handlers/implement-stamp-outcome.ts +148 -0
- package/os/rfc/handlers/implement-stamp-stale.test.ts +2 -1
- package/os/rfc/handlers/implement-stamp.ts +280 -53
- package/os/rfc/handlers/index-graph.ts +66 -4
- package/os/rfc/handlers/lifecycle.test.ts +59 -1
- package/os/rfc/handlers/lifecycle.ts +25 -15
- package/os/rfc/handlers/list-create.test.ts +223 -0
- package/os/rfc/handlers/list-create.ts +173 -13
- 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-rfc1334.test.ts +2 -1
- package/os/rfc/handlers/validate-rules-rfc1453.test.ts +164 -0
- package/os/rfc/handlers/validate-rules-rfc1454.test.ts +137 -0
- package/os/rfc/handlers/validate-rules-rfc1455.test.ts +283 -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 +67 -17
- package/os/rfc/rfc-0000-template.md +20 -0
- package/os/rfc/rfc.module.ts +74 -15
- package/os/rfc/types.ts +139 -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-1333/imp12-binding.acceptance.test.ts +12 -0
- package/os/rfc/verifier/rfc-1333/imp12-gate.acceptance.test.ts +12 -0
- package/os/rfc/verifier/rfc-1333/skills-and-types.acceptance.test.ts +12 -0
- package/os/rfc/verifier/rfc-1333/verify-workspace.acceptance.test.ts +12 -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 +39 -0
- package/os/rfc/verifier/rfc-1391/fixtures/small-domain.proof.test.ts +45 -0
- package/os/rfc/verifier/rfc-1391/origin-proof-spec-entry.acceptance.test.ts +175 -0
- package/os/rfc/verifier/rfc-1391/support.ts +209 -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/save.ts +5 -2
- package/os/session/handlers/session-audit-detectors.test.ts +97 -0
- package/os/session/handlers/session-audit-report.test.ts +70 -0
- package/os/session/handlers/session-audit-report.ts +97 -0
- package/os/session/handlers/session-audit.test.ts +86 -0
- package/os/session/handlers/session-audit.ts +321 -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 +75 -0
- package/os/trajectory/handlers/journal-io.ts +229 -0
- package/os/trajectory/handlers/outcome-record.test.ts +198 -0
- package/os/trajectory/handlers/outcome-record.ts +165 -0
- package/os/trajectory/handlers/producer-trust.test.ts +169 -0
- package/os/trajectory/handlers/trajectory-index.test.ts +275 -0
- package/os/trajectory/handlers/trajectory-index.ts +493 -0
- package/os/trajectory/handlers/trajectory-recall.test.ts +254 -0
- package/os/trajectory/handlers/trajectory-recall.ts +201 -0
- package/os/trajectory/handlers/trajectory.test.ts +100 -0
- package/os/trajectory/handlers/verdict-binding.test.ts +249 -0
- package/os/trajectory/index.ts +16 -0
- package/os/trajectory/trajectory.module.ts +103 -0
- package/os/werkstatt/handlers/session-close.ts +82 -0
- package/os/werkstatt/handlers/session-engine.ts +34 -0
- package/os/werkstatt/handlers/session-open.ts +68 -0
- package/os/werkstatt/handlers/session-status.ts +55 -0
- package/os/werkstatt/werkstatt.module.ts +101 -3
- package/os/yaml/handlers/scalars-validate.ts +343 -0
- package/os/yaml/index.ts +23 -0
- package/os/yaml/scalars.test.ts +152 -0
- package/os/yaml/yaml.module.ts +61 -0
- package/package.json +210 -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 +13 -5
- package/skills/fo/fo-memory-sync/SKILL.md +9 -0
- package/skills/fo/fo-memory-sync/fix-patterns.md +65 -0
- package/skills/fo/fo-memory-sync/learned-principles.md +10 -0
- package/skills/fo/fo-memory-sync/qa-log.md +30 -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-session-save/SKILL.md +2 -0
- 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 +7 -0
- package/skills/shared/grilling/learned-principles.md +7 -0
- package/skills/shared/grilling/qa-log.md +39 -0
- package/skills/shared/writing-great-skills/SKILL.md +12 -9
- package/src/authority/delegations.ts +6 -3
- package/src/cli-flags.ts +111 -16
- package/src/compass/index.ts +37 -0
- package/src/compass/invariant-parser.ts +254 -0
- package/src/config/forge-config.ts +150 -22
- package/src/conformance/index.ts +281 -0
- package/src/formal/exhaustive.test.ts +117 -0
- package/src/formal/exhaustive.ts +183 -0
- package/src/formal/index.ts +27 -0
- package/src/formal/proof-runner.test.ts +310 -0
- package/src/formal/proof-runner.ts +563 -0
- package/src/formal/proof-spec.test.ts +70 -0
- package/src/formal/proof-spec.ts +132 -0
- package/src/index.ts +1 -0
- package/src/knowledge/index.ts +11 -2
- package/src/knowledge/parse.ts +20 -17
- package/src/knowledge/schema.ts +14 -4
- package/src/knowledge/serialize.ts +3 -0
- package/src/knowledge/sync.ts +281 -7
- package/src/onboarding/agents-generate.ts +19 -3
- package/src/onboarding/compass-docs/semantic-layer-block.ts +1 -1
- package/src/onboarding/doctor.ts +277 -27
- package/src/onboarding/init.ts +3 -3
- package/src/onboarding/nested-agents-generate.ts +1 -1
- package/src/onboarding/nested-agents-templates.ts +1 -1
- package/src/onboarding/templates/behavioral-layer-core.md +1 -1
- package/src/onboarding/upgrade.ts +18 -10
- package/src/profiles/profile-schema.ts +10 -2
- package/src/reachability/command-mentions.ts +89 -0
- package/src/registry.ts +197 -76
- package/src/tests/bindings-schema.test.ts +4 -0
- package/src/tests/cli-flags.test.ts +226 -1
- package/src/tests/discover-pack-skills.test.ts +26 -0
- package/src/tests/doctor-autonomy.test.ts +144 -0
- package/src/tests/doctor-dist-freshness.test.ts +24 -0
- package/src/tests/doctor-knowledge-conflicts.test.ts +135 -0
- package/src/tests/doctor-nested-agents.test.ts +30 -1
- 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 +238 -4
- package/src/tests/knowledge-conflicts-resolve.pbt.test.ts +38 -0
- package/src/tests/knowledge-conflicts-resolve.test.ts +648 -0
- package/src/tests/knowledge-parse.test.ts +26 -1
- package/src/tests/rfc-verification-verdict-ingest.test.ts +244 -0
- package/src/tests/session-handlers.test.ts +47 -0
- package/src/tests/session-retro.test.ts +47 -0
- package/src/tests/skill-validate-knowledge.test.ts +93 -2
- package/src/tests/upgrade.test.ts +38 -0
- package/src/types.ts +59 -18
- package/src/utils/sync-fs.ts +2 -0
- package/src/validators/skill-validate.ts +37 -9
|
@@ -13,6 +13,7 @@ Mechanical v1 to v2 header migration across the workspace: 942 files rewritten
|
|
|
13
13
|
<item>RFC-1097: sweep — werkstatt-engine clean
|
|
14
14
|
|
|
15
15
|
Sweep batch 4: 73 Compass headers on headerless engine files (certification, component-runtime, isolation, evolution, testing), real KEY_DECISIONS on 75 files (kernel, cache, dht, swim, gitmesh, runtime), ~80 purpose expansions (CONTRACT-02/PURPOSE-02), non-goals on 13 CONTRACT-03 files, CS-07 history literal fix repo-wide (253 files). Policy: .template.ts/.template.astro excludedPaths. werkstatt-engine now 0 diagnostics.</item>
|
|
16
|
+
<item>RFC-1364: robust rfc index generation — bounded retry, RFC-IDX-04, atomic writes</item>
|
|
16
17
|
</CHANGE_SUMMARY>
|
|
17
18
|
*/
|
|
18
19
|
|
|
@@ -26,28 +27,66 @@ import type {
|
|
|
26
27
|
ForgeCommandResult,
|
|
27
28
|
ForgeRuntimeContext,
|
|
28
29
|
} from "../../../src/types.ts";
|
|
30
|
+
import { writeFileAtomic } from "../../../src/utils/fs-atomic.ts";
|
|
29
31
|
import type {
|
|
30
32
|
RfcStatus,
|
|
31
33
|
RfcKind,
|
|
32
34
|
RfcIndexEntry,
|
|
33
35
|
RfcIndexResult,
|
|
36
|
+
RfcIndexFailure,
|
|
34
37
|
RfcGraphResult,
|
|
35
38
|
} from "../types.ts";
|
|
36
39
|
import { RFC_DIR } from "../types.ts";
|
|
37
40
|
import { toIsoDate } from "./shared.ts";
|
|
38
41
|
|
|
42
|
+
// RFC-1364: injected reader seam — tests simulate a partial file that parses
|
|
43
|
+
// only on a later read; no real concurrency in tests.
|
|
44
|
+
let parseRfcImpl: typeof readAndParseRfc = readAndParseRfc;
|
|
45
|
+
export function __setParseRfcImplForTests(impl: typeof readAndParseRfc | undefined): void {
|
|
46
|
+
parseRfcImpl = impl ?? readAndParseRfc;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
const INDEX_PARSE_READS = 3;
|
|
50
|
+
const INDEX_RETRY_DELAY_MS = 100;
|
|
51
|
+
|
|
52
|
+
function sleep(ms: number): Promise<void> {
|
|
53
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
54
|
+
}
|
|
55
|
+
|
|
39
56
|
export async function runRfcIndexGenerate(
|
|
40
57
|
input: ForgeCommandInput,
|
|
41
58
|
context: ForgeRuntimeContext,
|
|
42
|
-
): Promise<ForgeCommandResult<RfcIndexResult>> {
|
|
59
|
+
): Promise<ForgeCommandResult<RfcIndexResult | RfcIndexFailure>> {
|
|
43
60
|
const { workspaceRoot, logger, outputFormat } = context;
|
|
44
61
|
const rfcDirPath = path.join(workspaceRoot, RFC_DIR);
|
|
45
62
|
|
|
46
63
|
const files = await listRfcFiles(rfcDirPath);
|
|
47
64
|
const entries: RfcIndexEntry[] = [];
|
|
65
|
+
const parseFailures: RfcIndexFailure["violations"] = [];
|
|
48
66
|
for (const fileName of files) {
|
|
49
|
-
|
|
50
|
-
|
|
67
|
+
// RFC-1364: retry a file that fails to parse — a concurrent writer may
|
|
68
|
+
// still be mid-rename. Up to 3 reads, 100 ms apart.
|
|
69
|
+
let result = await parseRfcImpl(rfcDirPath, fileName);
|
|
70
|
+
for (let attempt = 1; attempt < INDEX_PARSE_READS && result && "error" in result; attempt++) {
|
|
71
|
+
await sleep(INDEX_RETRY_DELAY_MS);
|
|
72
|
+
result = await parseRfcImpl(rfcDirPath, fileName);
|
|
73
|
+
}
|
|
74
|
+
if (!result) {
|
|
75
|
+
parseFailures.push({
|
|
76
|
+
rule: "RFC-IDX-04",
|
|
77
|
+
file: path.join(RFC_DIR, fileName),
|
|
78
|
+
message: "file not readable",
|
|
79
|
+
});
|
|
80
|
+
continue;
|
|
81
|
+
}
|
|
82
|
+
if ("error" in result) {
|
|
83
|
+
parseFailures.push({
|
|
84
|
+
rule: "RFC-IDX-04",
|
|
85
|
+
file: path.join(RFC_DIR, fileName),
|
|
86
|
+
message: result.error,
|
|
87
|
+
});
|
|
88
|
+
continue;
|
|
89
|
+
}
|
|
51
90
|
const fm = result.parsed.frontmatter;
|
|
52
91
|
const arr = (k: string): string[] =>
|
|
53
92
|
Array.isArray(fm[k]) ? (fm[k] as unknown[]).map(String) : [];
|
|
@@ -69,6 +108,29 @@ export async function runRfcIndexGenerate(
|
|
|
69
108
|
}
|
|
70
109
|
entries.sort((a, b) => a.id.localeCompare(b.id));
|
|
71
110
|
|
|
111
|
+
// RFC-1364: a persistent parse failure fails the run without writing —
|
|
112
|
+
// a partial index built over unreadable sources is worse than a stale one.
|
|
113
|
+
if (parseFailures.length > 0) {
|
|
114
|
+
const failure: RfcIndexFailure = {
|
|
115
|
+
command: "rfc.index.generate",
|
|
116
|
+
status: "fail",
|
|
117
|
+
violations: parseFailures,
|
|
118
|
+
};
|
|
119
|
+
if (outputFormat === "pretty") {
|
|
120
|
+
for (const v of parseFailures) {
|
|
121
|
+
logger.error(`RFC-IDX-04: ${v.file}: ${v.message}`);
|
|
122
|
+
}
|
|
123
|
+
logger.error(
|
|
124
|
+
`${parseFailures.length} RFC file(s) unparseable after ${INDEX_PARSE_READS} reads — index not written.`,
|
|
125
|
+
);
|
|
126
|
+
}
|
|
127
|
+
return {
|
|
128
|
+
data: failure,
|
|
129
|
+
exitCode: 1,
|
|
130
|
+
summary: `${parseFailures.length} unparseable RFC file(s) after ${INDEX_PARSE_READS} reads — index not written`,
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
|
|
72
134
|
let written: string | undefined;
|
|
73
135
|
if (input.flags["write"] === true) {
|
|
74
136
|
const outRel = path.join(RFC_DIR, "index.yaml");
|
|
@@ -78,7 +140,7 @@ export async function runRfcIndexGenerate(
|
|
|
78
140
|
count: entries.length,
|
|
79
141
|
entries,
|
|
80
142
|
};
|
|
81
|
-
await
|
|
143
|
+
await writeFileAtomic(path.join(workspaceRoot, outRel), `${yamlStringify(payload)}`);
|
|
82
144
|
written = outRel;
|
|
83
145
|
}
|
|
84
146
|
|
|
@@ -9,6 +9,7 @@ Unit tests for lifecycle covering RFC-CMD-02/03 cutoff behavior. It also guards
|
|
|
9
9
|
</MODULE_CONTRACT>
|
|
10
10
|
<CHANGE_SUMMARY>
|
|
11
11
|
<item>RFC-1311: Compass header sweep — declares the lifecycle suite's contract for test-file scaffold coverage.</item>
|
|
12
|
+
<item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
|
|
12
13
|
</CHANGE_SUMMARY>
|
|
13
14
|
*/
|
|
14
15
|
|
|
@@ -24,7 +25,7 @@ const testWorkspaceRoot = join(tmpdir(), "test");
|
|
|
24
25
|
function makeParsed(
|
|
25
26
|
status: string,
|
|
26
27
|
createdAt: string,
|
|
27
|
-
commands: { added?: string[]; changed?: string[] },
|
|
28
|
+
commands: { added?: string[]; changed?: string[]; removed?: string[] },
|
|
28
29
|
): ParsedRfc {
|
|
29
30
|
return {
|
|
30
31
|
frontmatter: {
|
|
@@ -139,3 +140,60 @@ describe("RFC-CMD-02/03 cutoff behavior", () => {
|
|
|
139
140
|
expect(cmd02).toHaveLength(0);
|
|
140
141
|
});
|
|
141
142
|
});
|
|
143
|
+
|
|
144
|
+
describe("RFC-1482 RFC-CMD-03 early warning on commands.changed", () => {
|
|
145
|
+
async function collect(status: string, createdAt: string, commands: { changed?: string[]; removed?: string[] }, registry: string[] = []) {
|
|
146
|
+
const parsed = makeParsed(status, createdAt, commands);
|
|
147
|
+
const preParsed = new Map([["rfc-9999-test.md", { fileName: "rfc-9999-test.md", parsed }]]);
|
|
148
|
+
const { violations } = await collectRfcCommandLifecycleViolations(
|
|
149
|
+
testWorkspaceRoot,
|
|
150
|
+
["rfc-9999-test.md"],
|
|
151
|
+
preParsed,
|
|
152
|
+
mockRegistry(registry),
|
|
153
|
+
);
|
|
154
|
+
return violations.filter((v) => v.rule === "RFC-CMD-03");
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
test("draft + unregistered changed name → warning (surfaced early)", async () => {
|
|
158
|
+
const cmd03 = await collect("draft", "2026-07-08", { changed: ["nonexistent.command"] });
|
|
159
|
+
expect(cmd03).toHaveLength(1);
|
|
160
|
+
expect(cmd03[0]?.severity).toBe("warning");
|
|
161
|
+
});
|
|
162
|
+
|
|
163
|
+
test("accepted + unregistered changed name → warning", async () => {
|
|
164
|
+
const cmd03 = await collect("accepted", "2026-07-08", { changed: ["nonexistent.command"] });
|
|
165
|
+
expect(cmd03).toHaveLength(1);
|
|
166
|
+
expect(cmd03[0]?.severity).toBe("warning");
|
|
167
|
+
});
|
|
168
|
+
|
|
169
|
+
test("implemented + unregistered changed name → error (blocking gate preserved)", async () => {
|
|
170
|
+
const cmd03 = await collect("implemented", "2026-07-08", { changed: ["nonexistent.command"] });
|
|
171
|
+
expect(cmd03).toHaveLength(1);
|
|
172
|
+
expect(cmd03[0]?.severity).toBe("error");
|
|
173
|
+
expect(cmd03[0]?.message).toContain(
|
|
174
|
+
'implemented RFC lists "nonexistent.command" under commands.changed, but no live command is registered',
|
|
175
|
+
);
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
test("changed name present in commands.removed → no violation at any status", async () => {
|
|
179
|
+
for (const status of ["draft", "accepted", "implemented"]) {
|
|
180
|
+
const cmd03 = await collect(status, "2026-07-08", {
|
|
181
|
+
changed: ["nonexistent.command"],
|
|
182
|
+
removed: ["nonexistent.command"],
|
|
183
|
+
});
|
|
184
|
+
expect(cmd03, `status ${status}`).toHaveLength(0);
|
|
185
|
+
}
|
|
186
|
+
});
|
|
187
|
+
|
|
188
|
+
test("registered changed name → no violation", async () => {
|
|
189
|
+
for (const status of ["draft", "accepted", "implemented"]) {
|
|
190
|
+
const cmd03 = await collect(status, "2026-07-08", { changed: ["live.command"] }, ["live.command"]);
|
|
191
|
+
expect(cmd03, `status ${status}`).toHaveLength(0);
|
|
192
|
+
}
|
|
193
|
+
});
|
|
194
|
+
|
|
195
|
+
test("pre-cutoff draft → no warning", async () => {
|
|
196
|
+
const cmd03 = await collect("draft", "2026-01-01", { changed: ["nonexistent.command"] });
|
|
197
|
+
expect(cmd03).toHaveLength(0);
|
|
198
|
+
});
|
|
199
|
+
});
|
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
</non-goals>
|
|
7
7
|
</MODULE_CONTRACT>
|
|
8
8
|
<CHANGE_SUMMARY>
|
|
9
|
-
<item>RFC-0303: extracted lifecycle logic from handlers.ts into handlers/lifecycle.ts.</item>
|
|
10
9
|
<item>RFC-0465: added RFC_METADATA_CUTOFF check to RFC-CMD-02 and RFC-CMD-03 rules — pre-cutoff RFCs are exempt from command registration checks.</item>
|
|
11
10
|
<item>RFC-0465 fix: added manifest-based fallback in getLiveCommands — reads docs/command-manifest.generated.yaml when commandRegistry returns empty (site-kernel mode).</item>
|
|
12
11
|
<item>RFC-1097: step 6 — compass.migrate codemod run
|
|
@@ -15,6 +14,8 @@ Mechanical v1 to v2 header migration across the workspace: 942 files rewritten
|
|
|
15
14
|
<item>RFC-1097: sweep — werkstatt-engine clean
|
|
16
15
|
|
|
17
16
|
Sweep batch 4: 73 Compass headers on headerless engine files (certification, component-runtime, isolation, evolution, testing), real KEY_DECISIONS on 75 files (kernel, cache, dht, swim, gitmesh, runtime), ~80 purpose expansions (CONTRACT-02/PURPOSE-02), non-goals on 13 CONTRACT-03 files, CS-07 history literal fix repo-wide (253 files). Policy: .template.ts/.template.astro excludedPaths. werkstatt-engine now 0 diagnostics.</item>
|
|
17
|
+
<item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
|
|
18
|
+
<history>RFC-0303</history>
|
|
18
19
|
</CHANGE_SUMMARY>
|
|
19
20
|
*/
|
|
20
21
|
|
|
@@ -158,20 +159,29 @@ export async function collectRfcCommandLifecycleViolations(
|
|
|
158
159
|
}
|
|
159
160
|
|
|
160
161
|
for (const command of buckets.changed) {
|
|
161
|
-
if (
|
|
162
|
-
|
|
163
|
-
status === "implemented"
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
162
|
+
if (!isPostCutoff || removed.has(command)) continue;
|
|
163
|
+
if (!(await getLiveCommands()).has(command)) {
|
|
164
|
+
if (status === "implemented") {
|
|
165
|
+
addViolation(
|
|
166
|
+
rfcId,
|
|
167
|
+
relFile,
|
|
168
|
+
"RFC-CMD-03",
|
|
169
|
+
`implemented RFC lists "${command}" under commands.changed, but no live command is registered`,
|
|
170
|
+
"error",
|
|
171
|
+
{ rfcId, command, status, bucket: "changed" },
|
|
172
|
+
);
|
|
173
|
+
} else if (status === "draft" || status === "reviewing" || status === "accepted") {
|
|
174
|
+
// RFC-1482: the registered-name contract surfaces at authoring
|
|
175
|
+
// time — same rule id, warning below the implemented gate.
|
|
176
|
+
addViolation(
|
|
177
|
+
rfcId,
|
|
178
|
+
relFile,
|
|
179
|
+
"RFC-CMD-03",
|
|
180
|
+
`${status} RFC lists "${command}" under commands.changed, but no live command is registered (surfaced early per RFC-1482; becomes an error at implemented)`,
|
|
181
|
+
"warning",
|
|
182
|
+
{ rfcId, command, status, bucket: "changed" },
|
|
183
|
+
);
|
|
184
|
+
}
|
|
175
185
|
}
|
|
176
186
|
}
|
|
177
187
|
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>
|
|
4
|
+
RFC-1467 near-duplicate gate tests — AC-1/2/3/5/8: terminal-kind
|
|
5
|
+
(rejected/superseded) decision-log hits at the reproposal threshold block
|
|
6
|
+
rfc.create until --revisit acknowledges a colliding id; the review band cites
|
|
7
|
+
hits via related + NEEDS CLARIFICATION; a non-colliding --revisit is refused
|
|
8
|
+
with candidates listed.
|
|
9
|
+
</purpose>
|
|
10
|
+
<non-goals>
|
|
11
|
+
<item>Not a template-content contract — fixtures carry the minimal template shape the handler rewrites.</item>
|
|
12
|
+
</non-goals>
|
|
13
|
+
</MODULE_CONTRACT>
|
|
14
|
+
<CHANGE_SUMMARY>
|
|
15
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
16
|
+
<item>RFC-1482: extract-safe RFC-1482 template path + changelog for 9.1.0</item>
|
|
17
|
+
</CHANGE_SUMMARY>
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
import { test, expect, describe, beforeEach, afterEach } from "vitest";
|
|
21
|
+
import { mkdtemp, mkdir, writeFile, rm, readFile } from "node:fs/promises";
|
|
22
|
+
import { join } from "node:path";
|
|
23
|
+
import { tmpdir } from "node:os";
|
|
24
|
+
import { fileURLToPath } from "node:url";
|
|
25
|
+
import { runRfcCreate } from "./list-create.ts";
|
|
26
|
+
import { runRfcValidate } from "./validate.ts";
|
|
27
|
+
|
|
28
|
+
const TEMPLATE = `id: RFC-0000
|
|
29
|
+
title: "Template"
|
|
30
|
+
status: draft
|
|
31
|
+
kind: command
|
|
32
|
+
scope: workspace
|
|
33
|
+
owners: [architecture]
|
|
34
|
+
createdAt: YYYY-MM-DD
|
|
35
|
+
updatedAt: YYYY-MM-DD
|
|
36
|
+
satisfies: []
|
|
37
|
+
related:
|
|
38
|
+
|
|
39
|
+
# RFC-0000: Template
|
|
40
|
+
|
|
41
|
+
## Decision
|
|
42
|
+
`;
|
|
43
|
+
|
|
44
|
+
const REJECTED_BODY = `---
|
|
45
|
+
id: RFC-1312
|
|
46
|
+
title: "Isolate parallel agent sessions in per-session worktrees"
|
|
47
|
+
status: rejected
|
|
48
|
+
kind: architecture
|
|
49
|
+
scope: workspace
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
# RFC-1312: rejected
|
|
53
|
+
|
|
54
|
+
## Decision
|
|
55
|
+
|
|
56
|
+
Rejected — isolation belongs to the scheduler, not the worktree.
|
|
57
|
+
`;
|
|
58
|
+
|
|
59
|
+
const REJECTED_TITLE = "Isolate parallel agent sessions in per-session worktrees";
|
|
60
|
+
|
|
61
|
+
let root: string;
|
|
62
|
+
const context = () => ({
|
|
63
|
+
workspaceRoot: root,
|
|
64
|
+
dryRun: false,
|
|
65
|
+
logger: {
|
|
66
|
+
info: () => {},
|
|
67
|
+
warn: () => {},
|
|
68
|
+
error: () => {},
|
|
69
|
+
success: () => {},
|
|
70
|
+
section: () => {},
|
|
71
|
+
getEvents: () => [],
|
|
72
|
+
},
|
|
73
|
+
outputFormat: "json" as const,
|
|
74
|
+
io: undefined as never,
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
async function seed(opts: { rejected?: boolean } = {}) {
|
|
78
|
+
root = await mkdtemp(join(tmpdir(), "rfc1467-create-"));
|
|
79
|
+
const rfcDir = join(root, "docs", "rfcs");
|
|
80
|
+
await mkdir(join(rfcDir, "archive", "rejected"), { recursive: true });
|
|
81
|
+
await writeFile(join(rfcDir, "rfc-0000-template.md"), TEMPLATE);
|
|
82
|
+
if (opts.rejected !== false) {
|
|
83
|
+
await writeFile(join(rfcDir, "archive", "rejected", "rfc-1312-test.md"), REJECTED_BODY);
|
|
84
|
+
}
|
|
85
|
+
return root;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
const flags = (extra: Record<string, unknown> = {}) => ({
|
|
89
|
+
title: REJECTED_TITLE,
|
|
90
|
+
kind: "command",
|
|
91
|
+
scope: "workspace",
|
|
92
|
+
...extra,
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
describe("RFC-1467 rfc.create near-duplicate gate", () => {
|
|
96
|
+
beforeEach(async () => {
|
|
97
|
+
await seed();
|
|
98
|
+
});
|
|
99
|
+
afterEach(async () => {
|
|
100
|
+
await rm(root, { recursive: true, force: true });
|
|
101
|
+
});
|
|
102
|
+
|
|
103
|
+
test("AC-2: a terminal hit at the reproposal threshold blocks without --revisit", async () => {
|
|
104
|
+
const result = await runRfcCreate({ flags: flags() } as never, context());
|
|
105
|
+
expect(result.exitCode).toBe(1);
|
|
106
|
+
expect(result.data?.blocked).toBe(true);
|
|
107
|
+
expect(result.data?.status).toBe("blocked");
|
|
108
|
+
expect(result.data?.colliding?.map((d) => d.rfcId)).toEqual(["RFC-1312"]);
|
|
109
|
+
expect(result.data?.colliding?.[0]?.kind).toBe("rejected-rfc");
|
|
110
|
+
expect(result.data?.colliding?.[0]?.score).toBeGreaterThanOrEqual(12);
|
|
111
|
+
expect(result.data?.remedy).toContain("--revisit RFC-1312");
|
|
112
|
+
// AC-1: the escalation payload accompanies consultedDecisions in JSON.
|
|
113
|
+
expect(Array.isArray(result.data?.consultedDecisions)).toBe(true);
|
|
114
|
+
});
|
|
115
|
+
|
|
116
|
+
test("AC-3: --revisit scaffolds with related + NEEDS CLARIFICATION marker", async () => {
|
|
117
|
+
const result = await runRfcCreate(
|
|
118
|
+
{ flags: flags({ revisit: "RFC-1312" }) } as never,
|
|
119
|
+
context(),
|
|
120
|
+
);
|
|
121
|
+
expect(result.exitCode ?? 0).toBe(0);
|
|
122
|
+
expect(result.data?.status).toBe("ok");
|
|
123
|
+
const body = await readFile(join(root, result.data!.file!), "utf8");
|
|
124
|
+
expect(body).toContain(" - RFC-1312");
|
|
125
|
+
expect(body).toContain("> NEEDS CLARIFICATION:");
|
|
126
|
+
expect(body).toContain("RFC-1312 is a rejected/superseded precedent");
|
|
127
|
+
});
|
|
128
|
+
|
|
129
|
+
test("AC-8: --revisit naming a non-colliding id refuses and lists candidates", async () => {
|
|
130
|
+
const result = await runRfcCreate(
|
|
131
|
+
{ flags: flags({ revisit: "RFC-9999" }) } as never,
|
|
132
|
+
context(),
|
|
133
|
+
);
|
|
134
|
+
expect(result.exitCode).toBe(1);
|
|
135
|
+
expect(result.data?.blocked).toBe(true);
|
|
136
|
+
expect(result.data?.remedy).toContain("RFC-1312");
|
|
137
|
+
});
|
|
138
|
+
|
|
139
|
+
test("AC-5: sub-threshold titles scaffold normally carrying consultedDecisions", async () => {
|
|
140
|
+
const result = await runRfcCreate(
|
|
141
|
+
{ flags: flags({ title: "Rotate the cache eviction cadence" }) } as never,
|
|
142
|
+
context(),
|
|
143
|
+
);
|
|
144
|
+
expect(result.exitCode ?? 0).toBe(0);
|
|
145
|
+
expect(result.data?.status).toBe("ok");
|
|
146
|
+
expect(result.data?.colliding).toBeUndefined();
|
|
147
|
+
});
|
|
148
|
+
});
|
|
149
|
+
|
|
150
|
+
// RFC-1482: the emitted skeleton must satisfy the contracts that gates enforce —
|
|
151
|
+
// seed the REAL canonical template so the assertions bind the shipped skeleton,
|
|
152
|
+
// not a fixture twin. `os/rfc/` carries the canonical template forge ships to
|
|
153
|
+
// consumers — the path must stay inside the package so the test also resolves
|
|
154
|
+
// in the standalone extracted layout (RFC-1252).
|
|
155
|
+
const REAL_TEMPLATE = fileURLToPath(new URL("../rfc-0000-template.md", import.meta.url));
|
|
156
|
+
|
|
157
|
+
async function seedRealTemplate() {
|
|
158
|
+
root = await mkdtemp(join(tmpdir(), "rfc1482-create-"));
|
|
159
|
+
const rfcDir = join(root, "docs", "rfcs");
|
|
160
|
+
await mkdir(rfcDir, { recursive: true });
|
|
161
|
+
const realTemplate = await readFile(REAL_TEMPLATE, "utf8");
|
|
162
|
+
await writeFile(join(rfcDir, "rfc-0000-template.md"), realTemplate);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
describe("RFC-1482 validation-compliant skeleton", () => {
|
|
166
|
+
beforeEach(async () => {
|
|
167
|
+
await seedRealTemplate();
|
|
168
|
+
});
|
|
169
|
+
afterEach(async () => {
|
|
170
|
+
await rm(root, { recursive: true, force: true });
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
test("AC-1: emitted draft passes rfc.validate with zero V-45/V-48/V-50 violations", async () => {
|
|
174
|
+
const result = await runRfcCreate(
|
|
175
|
+
{ flags: flags({ title: "Rotate the cache eviction cadence" }) } as never,
|
|
176
|
+
context(),
|
|
177
|
+
);
|
|
178
|
+
expect(result.data?.status).toBe("ok");
|
|
179
|
+
const id = result.data!.id!;
|
|
180
|
+
const v = await runRfcValidate({ argv: [], flags: { id } } as never, context());
|
|
181
|
+
const violations = v.data?.violations ?? [];
|
|
182
|
+
const named = violations.filter((x) => ["V-45", "V-48", "V-50"].includes(x.rule));
|
|
183
|
+
expect(named, JSON.stringify(violations, null, 1)).toEqual([]);
|
|
184
|
+
expect(v.data?.status, JSON.stringify(violations, null, 1)).toBe("pass");
|
|
185
|
+
});
|
|
186
|
+
|
|
187
|
+
test("AC-2: --proposed/--added seed commands.* and emit one reachable stub each", async () => {
|
|
188
|
+
const result = await runRfcCreate(
|
|
189
|
+
{ flags: flags({ title: "Tame the registry loader", proposed: "foo.bar,baz.qux", added: "foo.new" }) } as never,
|
|
190
|
+
context(),
|
|
191
|
+
);
|
|
192
|
+
expect(result.data?.status).toBe("ok");
|
|
193
|
+
const body = await readFile(join(root, result.data!.file!), "utf8");
|
|
194
|
+
expect(body).toContain(" proposed:\n - foo.bar\n - baz.qux");
|
|
195
|
+
expect(body).toContain(" added:\n - foo.new");
|
|
196
|
+
const reachable = body.match(/^ - probe: reachable$/gm) ?? [];
|
|
197
|
+
expect(reachable).toHaveLength(3);
|
|
198
|
+
expect(body).toContain('command: "foo.bar"');
|
|
199
|
+
expect(body).toContain('command: "baz.qux"');
|
|
200
|
+
expect(body).toContain('command: "foo.new"');
|
|
201
|
+
});
|
|
202
|
+
|
|
203
|
+
test("AC-3: emitted skeleton carries '## Fixed inputs' header schema and no FI rows", async () => {
|
|
204
|
+
const result = await runRfcCreate(
|
|
205
|
+
{ flags: flags({ title: "Rotate the cache eviction cadence" }) } as never,
|
|
206
|
+
context(),
|
|
207
|
+
);
|
|
208
|
+
const body = await readFile(join(root, result.data!.file!), "utf8");
|
|
209
|
+
expect(body).toContain("## Fixed inputs");
|
|
210
|
+
expect(body).toContain("| ID | Value | Source | Checked by |");
|
|
211
|
+
expect(body).not.toMatch(/^\|\s*FI-/m);
|
|
212
|
+
});
|
|
213
|
+
|
|
214
|
+
test("AC-6: no flags → zero reachable probe stubs in acceptance:", async () => {
|
|
215
|
+
const result = await runRfcCreate(
|
|
216
|
+
{ flags: flags({ title: "Rotate the cache eviction cadence" }) } as never,
|
|
217
|
+
context(),
|
|
218
|
+
);
|
|
219
|
+
const body = await readFile(join(root, result.data!.file!), "utf8");
|
|
220
|
+
expect(body).not.toMatch(/^ - probe: reachable$/gm);
|
|
221
|
+
expect(body).not.toMatch(/^acceptance:/m);
|
|
222
|
+
});
|
|
223
|
+
});
|