@warpgogol/forge 9.0.0 → 9.1.1
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 +36 -0
- package/README.md +15 -8
- package/README.uk.md +15 -8
- package/bin/cli.ts +3 -2
- package/dist/bin/cli.js +3 -2
- package/dist/bin/cli.js.map +1 -1
- package/dist/os/agent/handlers/agent-tiers-validate.d.ts.map +1 -1
- package/dist/os/agent/handlers/agent-tiers-validate.js +5 -1
- package/dist/os/agent/handlers/agent-tiers-validate.js.map +1 -1
- package/dist/os/agent/index.d.ts.map +1 -1
- package/dist/os/agent/index.js +4 -0
- package/dist/os/agent/index.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.map +1 -1
- package/dist/os/checks/checks.module.js +5 -1
- package/dist/os/checks/checks.module.js.map +1 -1
- package/dist/os/checks/handlers/contribution-report.d.ts.map +1 -1
- package/dist/os/checks/handlers/contribution-report.js +5 -4
- package/dist/os/checks/handlers/contribution-report.js.map +1 -1
- package/dist/os/checks/handlers/counters-export.d.ts.map +1 -1
- package/dist/os/checks/handlers/counters-export.js +4 -0
- package/dist/os/checks/handlers/counters-export.js.map +1 -1
- package/dist/os/checks/handlers/counters-journal.d.ts.map +1 -1
- package/dist/os/checks/handlers/counters-journal.js +2 -1
- package/dist/os/checks/handlers/counters-journal.js.map +1 -1
- package/dist/os/checks/handlers/counters-validate.d.ts.map +1 -1
- package/dist/os/checks/handlers/counters-validate.js +5 -1
- package/dist/os/checks/handlers/counters-validate.js.map +1 -1
- package/dist/os/checks/index.d.ts.map +1 -1
- package/dist/os/checks/index.js +11 -0
- package/dist/os/checks/index.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 +6 -1
- package/dist/os/compass/handlers/compass-header-scaffold.js.map +1 -1
- package/dist/os/compass/handlers/compass-invariants-generate.d.ts.map +1 -1
- package/dist/os/compass/handlers/compass-invariants-generate.js +3 -2
- package/dist/os/compass/handlers/compass-invariants-generate.js.map +1 -1
- package/dist/os/context/context.module.d.ts.map +1 -1
- package/dist/os/context/context.module.js +6 -1
- package/dist/os/context/context.module.js.map +1 -1
- package/dist/os/context/handlers/context-assemble.d.ts.map +1 -1
- package/dist/os/context/handlers/context-assemble.js +5 -1
- package/dist/os/context/handlers/context-assemble.js.map +1 -1
- package/dist/os/context/handlers/context-slate-eval.d.ts.map +1 -1
- package/dist/os/context/handlers/context-slate-eval.js +4 -0
- package/dist/os/context/handlers/context-slate-eval.js.map +1 -1
- package/dist/os/context/handlers/index-build.d.ts.map +1 -1
- package/dist/os/context/handlers/index-build.js +8 -5
- package/dist/os/context/handlers/index-build.js.map +1 -1
- package/dist/os/context/index.d.ts.map +1 -1
- package/dist/os/context/index.js +11 -0
- package/dist/os/context/index.js.map +1 -1
- package/dist/os/gate/handlers/gate-probe-catalog.d.ts.map +1 -1
- package/dist/os/gate/handlers/gate-probe-catalog.js +4 -0
- package/dist/os/gate/handlers/gate-probe-catalog.js.map +1 -1
- package/dist/os/gate/handlers/gate-probe.d.ts.map +1 -1
- package/dist/os/gate/handlers/gate-probe.js +4 -0
- package/dist/os/gate/handlers/gate-probe.js.map +1 -1
- package/dist/os/gate/index.d.ts.map +1 -1
- package/dist/os/gate/index.js +11 -0
- package/dist/os/gate/index.js.map +1 -1
- package/dist/os/instructions/instructions.module.d.ts.map +1 -1
- package/dist/os/instructions/instructions.module.js +2 -1
- package/dist/os/instructions/instructions.module.js.map +1 -1
- package/dist/os/knowledge/handlers/knowledge-authz-probe.d.ts.map +1 -1
- package/dist/os/knowledge/handlers/knowledge-authz-probe.js +7 -3
- package/dist/os/knowledge/handlers/knowledge-authz-probe.js.map +1 -1
- 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.map +1 -1
- package/dist/os/knowledge/handlers/knowledge-rebuild.js +4 -0
- package/dist/os/knowledge/handlers/knowledge-rebuild.js.map +1 -1
- package/dist/os/knowledge/index.d.ts +1 -0
- package/dist/os/knowledge/index.d.ts.map +1 -1
- package/dist/os/knowledge/index.js +13 -0
- package/dist/os/knowledge/index.js.map +1 -1
- package/dist/os/knowledge/knowledge.module.d.ts.map +1 -1
- package/dist/os/knowledge/knowledge.module.js +35 -1
- package/dist/os/knowledge/knowledge.module.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/resolver/resolver.module.d.ts.map +1 -1
- package/dist/os/resolver/resolver.module.js +2 -1
- package/dist/os/resolver/resolver.module.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts +1 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-deviations.js +3 -0
- package/dist/os/rfc/handlers/implement-stamp-deviations.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-origin.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-origin.js +10 -2
- package/dist/os/rfc/handlers/implement-stamp-origin.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts +2 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp-outcome.js +2 -0
- package/dist/os/rfc/handlers/implement-stamp-outcome.js.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp.d.ts.map +1 -1
- package/dist/os/rfc/handlers/implement-stamp.js +176 -59
- package/dist/os/rfc/handlers/implement-stamp.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 +28 -2
- package/dist/os/rfc/handlers/list-create.js.map +1 -1
- package/dist/os/rfc/reachable-symbol.d.ts.map +1 -1
- package/dist/os/rfc/reachable-symbol.js +4 -2
- 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 +23 -7
- package/dist/os/rfc/rfc.module.js.map +1 -1
- package/dist/os/rfc/types.d.ts +22 -2
- package/dist/os/rfc/types.d.ts.map +1 -1
- package/dist/os/rfc/types.js +18 -2
- package/dist/os/rfc/types.js.map +1 -1
- package/dist/os/rfc/verifier/rfc-1391/support.d.ts.map +1 -1
- package/dist/os/rfc/verifier/rfc-1391/support.js +4 -0
- package/dist/os/rfc/verifier/rfc-1391/support.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.map +1 -1
- package/dist/os/session/handlers/session-audit-report.js +4 -0
- package/dist/os/session/handlers/session-audit-report.js.map +1 -1
- package/dist/os/session/handlers/session-audit.d.ts.map +1 -1
- package/dist/os/session/handlers/session-audit.js +4 -0
- package/dist/os/session/handlers/session-audit.js.map +1 -1
- package/dist/os/trajectory/handlers/journal-io.d.ts +9 -0
- package/dist/os/trajectory/handlers/journal-io.d.ts.map +1 -1
- package/dist/os/trajectory/handlers/journal-io.js +20 -2
- package/dist/os/trajectory/handlers/journal-io.js.map +1 -1
- package/dist/os/trajectory/handlers/outcome-record.d.ts.map +1 -1
- package/dist/os/trajectory/handlers/outcome-record.js +4 -1
- package/dist/os/trajectory/handlers/outcome-record.js.map +1 -1
- package/dist/os/trajectory/handlers/trajectory-index.d.ts.map +1 -1
- package/dist/os/trajectory/handlers/trajectory-index.js +30 -8
- package/dist/os/trajectory/handlers/trajectory-index.js.map +1 -1
- package/dist/os/trajectory/handlers/trajectory-recall.d.ts.map +1 -1
- package/dist/os/trajectory/handlers/trajectory-recall.js +7 -4
- package/dist/os/trajectory/handlers/trajectory-recall.js.map +1 -1
- package/dist/os/trajectory/index.d.ts.map +1 -1
- package/dist/os/trajectory/index.js +11 -0
- package/dist/os/trajectory/index.js.map +1 -1
- package/dist/os/trajectory/trajectory.module.d.ts.map +1 -1
- package/dist/os/trajectory/trajectory.module.js +16 -9
- package/dist/os/trajectory/trajectory.module.js.map +1 -1
- package/dist/os/werkstatt/handlers/session-close.d.ts.map +1 -1
- package/dist/os/werkstatt/handlers/session-close.js +3 -0
- package/dist/os/werkstatt/handlers/session-close.js.map +1 -1
- package/dist/os/werkstatt/handlers/session-engine.d.ts.map +1 -1
- package/dist/os/werkstatt/handlers/session-engine.js +3 -0
- package/dist/os/werkstatt/handlers/session-engine.js.map +1 -1
- package/dist/os/werkstatt/handlers/session-open.d.ts.map +1 -1
- package/dist/os/werkstatt/handlers/session-open.js +3 -0
- package/dist/os/werkstatt/handlers/session-open.js.map +1 -1
- package/dist/os/werkstatt/handlers/session-status.d.ts.map +1 -1
- package/dist/os/werkstatt/handlers/session-status.js +3 -0
- package/dist/os/werkstatt/handlers/session-status.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.map +1 -1
- package/dist/src/authority/delegations.js +5 -4
- 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 +1 -5
- package/dist/src/cli-flags.js.map +1 -1
- package/dist/src/compass/invariant-parser.d.ts.map +1 -1
- package/dist/src/compass/invariant-parser.js +2 -1
- package/dist/src/compass/invariant-parser.js.map +1 -1
- package/dist/src/config/forge-config.d.ts +17 -0
- package/dist/src/config/forge-config.d.ts.map +1 -1
- package/dist/src/config/forge-config.js +33 -10
- package/dist/src/config/forge-config.js.map +1 -1
- package/dist/src/formal/exhaustive.d.ts.map +1 -1
- package/dist/src/formal/exhaustive.js +3 -2
- package/dist/src/formal/exhaustive.js.map +1 -1
- package/dist/src/formal/index.d.ts.map +1 -1
- package/dist/src/formal/index.js +4 -0
- package/dist/src/formal/index.js.map +1 -1
- package/dist/src/formal/proof-runner.d.ts.map +1 -1
- package/dist/src/formal/proof-runner.js +4 -3
- package/dist/src/formal/proof-runner.js.map +1 -1
- package/dist/src/formal/proof-spec.d.ts.map +1 -1
- package/dist/src/formal/proof-spec.js +3 -2
- package/dist/src/formal/proof-spec.js.map +1 -1
- 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.map +1 -1
- package/dist/src/knowledge/schema.js +5 -4
- package/dist/src/knowledge/schema.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.js +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 +166 -26
- package/dist/src/onboarding/doctor.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/reachability/command-mentions.d.ts.map +1 -1
- package/dist/src/reachability/command-mentions.js +4 -2
- package/dist/src/reachability/command-mentions.js.map +1 -1
- package/dist/src/registry.d.ts +20 -0
- package/dist/src/registry.d.ts.map +1 -1
- package/dist/src/registry.js +129 -67
- package/dist/src/registry.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/maintainers/publishing.md +11 -5
- package/docs/reference/cli.md +128 -0
- package/docs/reference/profiles.md +1 -0
- package/os/agent/handlers/agent-tiers-validate.ts +5 -1
- package/os/agent/index.ts +4 -0
- package/os/authority/handlers/delegate.ts +2 -1
- package/os/authority/index.ts +2 -1
- package/os/checks/checks.module.ts +5 -1
- package/os/checks/handlers/contribution-report.test.ts +6 -0
- package/os/checks/handlers/contribution-report.ts +5 -4
- package/os/checks/handlers/counters-export.test.ts +6 -0
- package/os/checks/handlers/counters-export.ts +4 -0
- package/os/checks/handlers/counters-journal.test.ts +6 -0
- package/os/checks/handlers/counters-journal.ts +2 -1
- package/os/checks/handlers/counters-validate.test.ts +6 -0
- package/os/checks/handlers/counters-validate.ts +5 -1
- package/os/checks/handlers/variant-candidates.test.ts +6 -0
- package/os/checks/index.ts +12 -0
- package/os/compass/handlers/compass-docs-scaffold.ts +1 -1
- package/os/compass/handlers/compass-header-scaffold.ts +6 -1
- package/os/compass/handlers/compass-invariants-generate.ts +3 -2
- package/os/context/context.module.ts +6 -1
- package/os/context/handlers/context-assemble.test.ts +6 -0
- package/os/context/handlers/context-assemble.ts +5 -1
- package/os/context/handlers/context-slate-eval.test.ts +6 -0
- package/os/context/handlers/context-slate-eval.ts +4 -0
- package/os/context/handlers/index-build.test.ts +33 -0
- package/os/context/handlers/index-build.ts +8 -5
- package/os/context/handlers/no-model-deps.test.ts +6 -0
- package/os/context/handlers/slate-fill.test.ts +6 -0
- package/os/context/index.ts +12 -0
- package/os/gate/handlers/gate-probe-catalog.test.ts +6 -0
- package/os/gate/handlers/gate-probe-catalog.ts +4 -0
- package/os/gate/handlers/gate-probe.test.ts +6 -0
- package/os/gate/handlers/gate-probe.ts +4 -0
- package/os/gate/index.ts +12 -0
- package/os/instructions/budget.test.ts +6 -0
- package/os/instructions/instructions.module.ts +2 -1
- package/os/knowledge/handlers/knowledge-authz-probe.test.ts +21 -0
- package/os/knowledge/handlers/knowledge-authz-probe.ts +7 -3
- package/os/knowledge/handlers/knowledge-conflicts-resolve.ts +571 -0
- package/os/knowledge/handlers/knowledge-rebuild.test.ts +6 -0
- package/os/knowledge/handlers/knowledge-rebuild.ts +4 -0
- package/os/knowledge/index.ts +14 -0
- package/os/knowledge/knowledge.module.ts +36 -1
- package/os/queue/decision-ledger.test.ts +32 -1
- package/os/queue/manifest.ts +8 -7
- package/os/resolver/handlers/resolver-doors-audit.test.ts +3 -0
- package/os/resolver/resolver.module.ts +2 -1
- package/os/rfc/handlers/implement-stamp-deviations.ts +4 -1
- package/os/rfc/handlers/implement-stamp-origin.ts +10 -2
- package/os/rfc/handlers/implement-stamp-outcome.ts +4 -2
- package/os/rfc/handlers/implement-stamp-stale.test.ts +2 -1
- package/os/rfc/handlers/implement-stamp.ts +188 -58
- 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 +81 -0
- package/os/rfc/handlers/list-create.ts +34 -2
- package/os/rfc/handlers/validate-rules-rfc1334.test.ts +2 -1
- package/os/rfc/handlers/validate-rules-rfc1453.test.ts +2 -1
- package/os/rfc/handlers/validate-rules-rfc1454.test.ts +2 -1
- package/os/rfc/handlers/validate-rules-rfc1455.test.ts +2 -1
- package/os/rfc/reachable-symbol.ts +4 -2
- package/os/rfc/rfc-0000-template.md +16 -0
- package/os/rfc/rfc.module.ts +26 -7
- package/os/rfc/types.ts +32 -2
- 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/fixtures/no-report.proof.test.ts +4 -0
- package/os/rfc/verifier/rfc-1391/fixtures/small-domain.proof.test.ts +4 -0
- package/os/rfc/verifier/rfc-1391/support.ts +4 -0
- package/os/session/handlers/save.ts +5 -2
- package/os/session/handlers/session-audit-detectors.test.ts +6 -0
- package/os/session/handlers/session-audit-report.test.ts +6 -0
- package/os/session/handlers/session-audit-report.ts +4 -0
- package/os/session/handlers/session-audit.test.ts +6 -0
- package/os/session/handlers/session-audit.ts +4 -0
- package/os/trajectory/handlers/extract-units.test.ts +7 -1
- package/os/trajectory/handlers/journal-io.ts +20 -2
- package/os/trajectory/handlers/outcome-record.test.ts +6 -0
- package/os/trajectory/handlers/outcome-record.ts +4 -1
- package/os/trajectory/handlers/producer-trust.test.ts +6 -0
- package/os/trajectory/handlers/trajectory-index.test.ts +29 -0
- package/os/trajectory/handlers/trajectory-index.ts +31 -8
- package/os/trajectory/handlers/trajectory-recall.test.ts +27 -0
- package/os/trajectory/handlers/trajectory-recall.ts +7 -4
- package/os/trajectory/handlers/trajectory.test.ts +6 -0
- package/os/trajectory/handlers/verdict-binding.test.ts +40 -0
- package/os/trajectory/index.ts +12 -0
- package/os/trajectory/trajectory.module.ts +16 -9
- package/os/werkstatt/handlers/session-close.ts +3 -0
- package/os/werkstatt/handlers/session-engine.ts +3 -0
- package/os/werkstatt/handlers/session-open.ts +3 -0
- package/os/werkstatt/handlers/session-status.ts +3 -0
- 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 +17 -1
- package/skills/fo/fo-knowledge-distill/SKILL.md +6 -5
- package/skills/fo/fo-memory-sync/SKILL.md +3 -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-session-save/SKILL.md +2 -0
- package/skills/shared/grilling/SKILL.md +3 -0
- package/skills/shared/writing-great-skills/SKILL.md +12 -9
- package/src/authority/delegations.ts +5 -4
- package/src/cli-flags.ts +1 -5
- package/src/compass/invariant-parser.ts +2 -1
- package/src/config/forge-config.ts +40 -14
- package/src/formal/exhaustive.ts +3 -2
- package/src/formal/index.ts +4 -0
- package/src/formal/proof-runner.ts +4 -3
- package/src/formal/proof-spec.ts +3 -2
- 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 +5 -4
- package/src/knowledge/sync.ts +281 -7
- package/src/onboarding/agents-generate.ts +1 -1
- package/src/onboarding/compass-docs/semantic-layer-block.ts +1 -1
- package/src/onboarding/doctor.ts +184 -26
- package/src/onboarding/nested-agents-generate.ts +1 -1
- package/src/onboarding/nested-agents-templates.ts +1 -1
- package/src/onboarding/upgrade.ts +18 -10
- package/src/reachability/command-mentions.ts +4 -2
- package/src/registry.ts +153 -74
- package/src/tests/cli-flags.test.ts +1 -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/implement-stamp.test.ts +191 -8
- 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/session-handlers.test.ts +47 -0
- package/src/tests/skill-validate-knowledge.test.ts +93 -2
- package/src/tests/upgrade.test.ts +38 -0
- package/src/validators/skill-validate.ts +37 -9
|
@@ -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
|
|
|
@@ -11,13 +11,19 @@ with candidates listed.
|
|
|
11
11
|
<item>Not a template-content contract — fixtures carry the minimal template shape the handler rewrites.</item>
|
|
12
12
|
</non-goals>
|
|
13
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>
|
|
14
18
|
*/
|
|
15
19
|
|
|
16
20
|
import { test, expect, describe, beforeEach, afterEach } from "vitest";
|
|
17
21
|
import { mkdtemp, mkdir, writeFile, rm, readFile } from "node:fs/promises";
|
|
18
22
|
import { join } from "node:path";
|
|
19
23
|
import { tmpdir } from "node:os";
|
|
24
|
+
import { fileURLToPath } from "node:url";
|
|
20
25
|
import { runRfcCreate } from "./list-create.ts";
|
|
26
|
+
import { runRfcValidate } from "./validate.ts";
|
|
21
27
|
|
|
22
28
|
const TEMPLATE = `id: RFC-0000
|
|
23
29
|
title: "Template"
|
|
@@ -140,3 +146,78 @@ describe("RFC-1467 rfc.create near-duplicate gate", () => {
|
|
|
140
146
|
expect(result.data?.colliding).toBeUndefined();
|
|
141
147
|
});
|
|
142
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
|
+
});
|
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
</non-goals>
|
|
7
7
|
</MODULE_CONTRACT>
|
|
8
8
|
<CHANGE_SUMMARY>
|
|
9
|
-
<item>RFC-1139: CLI hint accuracy and agent-safety hygiene — rfc.create hint, EC-14-PARTIAL, amend delegation, ledger scope, sync footer, mission.open remnants</item>
|
|
10
9
|
<item>RFC-1139: second hint fix (rfc.list empty-state) + read-only test fix</item>
|
|
11
10
|
<item>RFC-1364: robust rfc index generation — bounded retry, RFC-IDX-04, atomic writes</item>
|
|
12
11
|
<item>RFC-1467: block rfc.create on terminal-kind near-duplicates until --revisit acknowledges + V-52 validate mirror</item>
|
|
13
12
|
<item>RFC-1467: address review r1 findings — object-shaped colliding payload, cite all colliding siblings, reviewBand field, supersede.propose escalation, flag-shape guard</item>
|
|
14
|
-
<
|
|
13
|
+
<item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
|
|
14
|
+
<history>RFC-0303, RFC-1097, RFC-1138, RFC-1139</history>
|
|
15
15
|
</CHANGE_SUMMARY>
|
|
16
16
|
*/
|
|
17
17
|
|
|
@@ -173,6 +173,11 @@ export async function runRfcCreate(
|
|
|
173
173
|
const kind = (input.flags["kind"] as string | undefined) ?? "architecture";
|
|
174
174
|
const scope = (input.flags["scope"] as string | undefined) ?? "workspace";
|
|
175
175
|
const satisfies = parseSatisfiesFlag(input.flags["satisfies"]);
|
|
176
|
+
// RFC-1482: seed commands.proposed/commands.added at authoring time so the
|
|
177
|
+
// draft's acceptance block can carry reachable-probe stubs (V-45) instead of
|
|
178
|
+
// discovering the breach on the first validate cycle.
|
|
179
|
+
const proposed = parseSatisfiesFlag(input.flags["proposed"]);
|
|
180
|
+
const added = parseSatisfiesFlag(input.flags["added"]);
|
|
176
181
|
|
|
177
182
|
if (!RFC_KINDS.includes(kind as RfcKind)) {
|
|
178
183
|
throw new Error(`Invalid kind: ${kind}. Must be one of: ${RFC_KINDS.join(", ")}`);
|
|
@@ -371,6 +376,33 @@ export async function runRfcCreate(
|
|
|
371
376
|
`satisfies:\n${satisfies.map((id) => ` - ${id}`).join("\n")}`,
|
|
372
377
|
);
|
|
373
378
|
}
|
|
379
|
+
if (proposed.length > 0) {
|
|
380
|
+
content = content.replace(
|
|
381
|
+
/^ proposed: \[\]$/m,
|
|
382
|
+
` proposed:\n${proposed.map((name) => ` - ${name}`).join("\n")}`,
|
|
383
|
+
);
|
|
384
|
+
}
|
|
385
|
+
if (added.length > 0) {
|
|
386
|
+
content = content.replace(
|
|
387
|
+
/^ added: \[\]$/m,
|
|
388
|
+
` added:\n${added.map((name) => ` - ${name}`).join("\n")}`,
|
|
389
|
+
);
|
|
390
|
+
}
|
|
391
|
+
// RFC-1482: one reachable-probe stub per seeded command — V-45 covered at
|
|
392
|
+
// emission; with both buckets empty the commented template shape stays.
|
|
393
|
+
const probeSeeds = [...proposed, ...added];
|
|
394
|
+
if (probeSeeds.length > 0) {
|
|
395
|
+
const stubs = probeSeeds
|
|
396
|
+
.map((name) => ` - probe: reachable\n criterion: AC-1\n command: "${name}"`)
|
|
397
|
+
.join("\n");
|
|
398
|
+
const closing = content.indexOf("\n---\n");
|
|
399
|
+
if (closing !== -1) {
|
|
400
|
+
content =
|
|
401
|
+
content.slice(0, closing + 1) +
|
|
402
|
+
`acceptance:\n${stubs}\n` +
|
|
403
|
+
content.slice(closing + 1);
|
|
404
|
+
}
|
|
405
|
+
}
|
|
374
406
|
// RFC-1467: cite the acknowledged/review-band precedents in `related`
|
|
375
407
|
// and leave a NEEDS CLARIFICATION marker in the Decision section.
|
|
376
408
|
if (citedIds.length > 0) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
|
-
<purpose>RFC-1334
|
|
3
|
+
<purpose>validate-rules-rfc1334 coverage — RFC-1334 V-45: post-cutoff proposed/added commands without a command-mode reachable probe warn.</purpose>
|
|
4
4
|
<non-goals>
|
|
5
5
|
<item>Not a probe-execution suite.</item>
|
|
6
6
|
</non-goals>
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
<CHANGE_SUMMARY>
|
|
9
9
|
<item>RFC-1334: tests for AC-8.</item>
|
|
10
10
|
<item>RFC-1334: step 4 — reachable acceptance probe (symbol and command modes) and V-45</item>
|
|
11
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
11
12
|
</CHANGE_SUMMARY>
|
|
12
13
|
*/
|
|
13
14
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
3
|
<purpose>
|
|
4
|
-
RFC-1453: V-47/V-48 tests — `page` probes require `target` on non-archived
|
|
4
|
+
RFC-1453: validate-rules-rfc1453 V-47/V-48 tests — `page` probes require `target` on non-archived
|
|
5
5
|
files (error), archived files exempt; V-48 warns when packagesImpacted
|
|
6
6
|
touches an outcomeSurfaces glob without a declared outcome probe (AC-8).
|
|
7
7
|
</purpose>
|
|
@@ -12,6 +12,7 @@ touches an outcomeSurfaces glob without a declared outcome probe (AC-8).
|
|
|
12
12
|
<CHANGE_SUMMARY>
|
|
13
13
|
<item>RFC-1453: V-47 page-target + V-48 outcome-surface validation tests.</item>
|
|
14
14
|
<item>RFC-1453: executed outcome probes, IMP-14 surface gate, outcome.serve + V-47/V-48</item>
|
|
15
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
15
16
|
</CHANGE_SUMMARY>
|
|
16
17
|
*/
|
|
17
18
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
3
|
<purpose>
|
|
4
|
-
RFC-1454: V-49 tests — every `## Deviations` entry's `(review <reviewId>)`
|
|
4
|
+
RFC-1454: validate-rules-rfc1454 V-49 tests — every `## Deviations` entry's `(review <reviewId>)`
|
|
5
5
|
provenance must resolve to a committed review report under the configured
|
|
6
6
|
reviewsDir at HEAD (AC-4). Covers dangling review ids, resolvable entries,
|
|
7
7
|
malformed section lines, and the no-entries fast path. Uses a real tmp git
|
|
@@ -14,6 +14,7 @@ repo because the committed-report index reads `git ls-tree`/`git show`.
|
|
|
14
14
|
<CHANGE_SUMMARY>
|
|
15
15
|
<item>RFC-1454: V-49 deviation-provenance validation tests.</item>
|
|
16
16
|
<item>RFC-1454: review deviations recorded in the RFC — IMP-15 gate, V-49 provenance, skill contract</item>
|
|
17
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
17
18
|
</CHANGE_SUMMARY>
|
|
18
19
|
*/
|
|
19
20
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
3
|
<purpose>
|
|
4
|
-
RFC-1455: V-50/V-51 tests — `## Fixed inputs` rows must bind exactly one
|
|
4
|
+
RFC-1455: validate-rules-rfc1455 V-50/V-51 tests — `## Fixed inputs` rows must bind exactly one
|
|
5
5
|
existing AC-N whose outcome probe (page or file-contains) contains the
|
|
6
6
|
declared value (V-50 error); verbatim prose without the section earns a
|
|
7
7
|
V-51 warning. Covers fence-stripped parsing, escaped pipes, header-row
|
|
@@ -14,6 +14,7 @@ location, marked-literal extraction, and the createdAt cutoff.
|
|
|
14
14
|
<CHANGE_SUMMARY>
|
|
15
15
|
<item>RFC-1455: V-50/V-51 fixed-inputs binding validation tests.</item>
|
|
16
16
|
<item>RFC-1455: fixed inputs bound to outcome probes — V-50/V-51 + skills</item>
|
|
17
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
17
18
|
</CHANGE_SUMMARY>
|
|
18
19
|
*/
|
|
19
20
|
|
|
@@ -18,16 +18,18 @@ manifest's `reachableVia` edges and unions them with live doc-mention edges
|
|
|
18
18
|
<item>Type-only imports and re-exports alone never count as usage.</item>
|
|
19
19
|
<item>Barrel re-exports are followed to depth 5; bare specifiers resolve through workspace package.json exports.</item>
|
|
20
20
|
<item>The tracked-file scan is memoized per workspace so several probes in one run share it.</item>
|
|
21
|
-
<item>Command mode unions manifest edges with doc-mention edges
|
|
21
|
+
<item>Command mode unions manifest edges with live doc-mention edges; mentions under frozen trees never count.</item>
|
|
22
|
+
<item>Mention enumeration is `git ls-files --cached --others --exclude-standard`; a git failure surfaces in the probe detail.</item>
|
|
22
23
|
</KEY_DECISIONS>
|
|
23
24
|
<CHANGE_SUMMARY>
|
|
24
|
-
<item>RFC-1334: initial implementation.</item>
|
|
25
25
|
<item>RFC-1334: step 4 — reachable acceptance probe (symbol and command modes) and V-45</item>
|
|
26
26
|
<item>RFC-1351: step 1 — command mode unions reachableVia with live doc-mention edges via @warpgogol/forge/reachability (Q-1/A; manifest stays structural-only)</item>
|
|
27
27
|
<item>RFC-1351: review F-1/F-2 — doc-scan fs.glob parity + surfaced scan failure + guarded-initializer note</item>
|
|
28
28
|
<item>RFC-1351: review report persisted + KEY_DECISIONS enumeration note
|
|
29
29
|
|
|
30
30
|
fo-review REVIEW-CODE-2026-10-20-01 (subagent isolation, blockLevel warning) — F-1/F-2 fixed in the previous commit; reachable-symbol KEY_DECISIONS item now records the doc-mention enumeration contract.</item>
|
|
31
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
32
|
+
<history>RFC-1334</history>
|
|
31
33
|
</CHANGE_SUMMARY>
|
|
32
34
|
*/
|
|
33
35
|
|
|
@@ -60,6 +60,10 @@ nonGoals: []
|
|
|
60
60
|
# OPTIONAL machine-checkable acceptance probes, executed on-demand
|
|
61
61
|
# via `pnpm exec forge rfc.acceptance.run --id <this-rfc-id>` (never
|
|
62
62
|
# automatically inside build pipelines).
|
|
63
|
+
# This skeleton satisfies V-45 (reachable probe per proposed/added command),
|
|
64
|
+
# V-48 (outcome probe per outcome-surface package), and V-50 (`## Fixed
|
|
65
|
+
# inputs` header schema, no unbound rows) by construction — commands seeded
|
|
66
|
+
# via --proposed/--added gain a reachable stub automatically.
|
|
63
67
|
# RFC-1271: a probe MAY declare `expectationSource` — who authored the
|
|
64
68
|
# expected result: self | requirement | independent | external — and
|
|
65
69
|
# `limitations`, a free-text caveat about coverage gaps. Both optional.
|
|
@@ -226,6 +230,18 @@ interface ExampleResult {
|
|
|
226
230
|
- [ ] DR-3: The RFC states whether the decision is reversible and at what cost
|
|
227
231
|
-->
|
|
228
232
|
|
|
233
|
+
## Fixed inputs
|
|
234
|
+
|
|
235
|
+
<!-- V-50 contract (RFC-1455): every value this RFC pins for the shipped
|
|
236
|
+
result (verbatim copy, labels, names, decided option values) is a row
|
|
237
|
+
bound to exactly one AC-N criterion whose probes observe the value.
|
|
238
|
+
Emit the header schema only — a live placeholder row would itself trip
|
|
239
|
+
V-50. Add rows only when the draft fixes real inputs; delete this
|
|
240
|
+
section's table when none exist. -->
|
|
241
|
+
|
|
242
|
+
| ID | Value | Source | Checked by |
|
|
243
|
+
| --- | --- | --- | --- |
|
|
244
|
+
|
|
229
245
|
## Acceptance criteria
|
|
230
246
|
|
|
231
247
|
<!-- Authoring standard: see packages/forge/skills/fo/fo-idea-create-rfc/acceptance-criteria-standard.md (RFC-0996).
|
package/os/rfc/rfc.module.ts
CHANGED
|
@@ -7,14 +7,14 @@
|
|
|
7
7
|
</non-goals>
|
|
8
8
|
</MODULE_CONTRACT>
|
|
9
9
|
<CHANGE_SUMMARY>
|
|
10
|
-
<item>RFC-1461: declare rules[] severity via CommandRuleDecl workspace-wide (RFC-1461)</item>
|
|
11
|
-
<item>RFC-1463: composite gates report complete violation sets and self-ensure prerequisites — ensure/compositeGate metadata, executor ensure runner, blockedBy skip tracking, ENSURE-01..04 + GATE-CMP-01, runCompositeGate</item>
|
|
12
10
|
<item>RFC-1467: block rfc.create on terminal-kind near-duplicates until --revisit acknowledges + V-52 validate mirror</item>
|
|
13
11
|
<item>RFC-1474: per-rule check-execution counters
|
|
14
12
|
|
|
15
13
|
Append-only counters.jsonl journaled per evaluated rule ({runId, ruleId, contract, outcome, at}; runId = commandInvocationId; outcomes pass|diagnostic|skipped|ensured; dry-run suppressed; append failures warn never fail). checks.counters.validate audits the journal against the validator inventory (COUNT-01/02); checks.counters.export projects deterministic per-rule totals (COUNT-03, generatedAt = max journal at; producer-tail tolerated). checks.contribution.report joins counters as the canonical firing source (CONTRIB-03 on absent/empty journal; coverage none|partial|complete; live effectiveCoverage positive). Validator inventory now includes every rules[]-declaring command — fail-closed gate surfaced 9 contract-declaration defects, fixed with domain contracts.</item>
|
|
16
14
|
<item>RFC-1474: check-execution counters — apply re-review findings (structural skip flag, violations extraction, Date.parse ordering, DEV-5/6)</item>
|
|
17
|
-
<
|
|
15
|
+
<item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
|
|
16
|
+
<item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
|
|
17
|
+
<history>RFC-0260, RFC-0795, RFC-1097, RFC-1173, RFC-1231, RFC-1237, RFC-1249, RFC-1271, RFC-1306, RFC-1322, RFC-1333, RFC-1351, RFC-1354, RFC-1364, RFC-1453, RFC-1458, RFC-1461, RFC-1463</history>
|
|
18
18
|
</CHANGE_SUMMARY>
|
|
19
19
|
*/
|
|
20
20
|
|
|
@@ -115,6 +115,16 @@ export async function createForgeRfcModule(): Promise<ForgeModule> {
|
|
|
115
115
|
description:
|
|
116
116
|
"RFC-1467: acknowledge a rejected/superseded precedent colliding with this title — required when a terminal-kind decision-log hit scores at or above the reproposal threshold.",
|
|
117
117
|
},
|
|
118
|
+
proposed: {
|
|
119
|
+
kind: "string",
|
|
120
|
+
description:
|
|
121
|
+
"RFC-1482: comma-separated command names seeded into commands.proposed; each name gets one `probe: reachable` acceptance stub.",
|
|
122
|
+
},
|
|
123
|
+
added: {
|
|
124
|
+
kind: "string",
|
|
125
|
+
description:
|
|
126
|
+
"RFC-1482: comma-separated command names seeded into commands.added; each name gets one `probe: reachable` acceptance stub.",
|
|
127
|
+
},
|
|
118
128
|
},
|
|
119
129
|
execute: runRfcCreate,
|
|
120
130
|
},
|
|
@@ -525,9 +535,11 @@ export async function createForgeRfcModule(): Promise<ForgeModule> {
|
|
|
525
535
|
"RFC-IMP-09 stale-evidence gate from RFC-1271) then atomically sets " +
|
|
526
536
|
"status: implemented, implementedAt, and updatedAt. For probe-bearing RFCs the " +
|
|
527
537
|
"evidence envelope is re-emitted post-mutation so it binds the implemented-state " +
|
|
528
|
-
"file (RFC-1271).
|
|
529
|
-
"
|
|
530
|
-
"(RFC-1322
|
|
538
|
+
"file (RFC-1271). Self-repairing by default (RFC-1483): unchecked-but-evidenced " +
|
|
539
|
+
"criteria flip and a missing/stale envelope re-emits inside the same atomic " +
|
|
540
|
+
"write (the RFC-1322 --check-criteria machinery, now the default); --no-repair " +
|
|
541
|
+
"restores fail-fast gating, and unrepairable failures print the ordered " +
|
|
542
|
+
"remediation checklist. Use --dry-run to preview. Required flags: `--id`.",
|
|
531
543
|
scope: "workspace",
|
|
532
544
|
mutatesState: true,
|
|
533
545
|
writes: ["docs/rfcs/**/*.md", "docs/rfcs/verification/*.generated.yaml"],
|
|
@@ -572,7 +584,14 @@ export async function createForgeRfcModule(): Promise<ForgeModule> {
|
|
|
572
584
|
"RFC-1322: auto-check unchecked acceptance criteria whose (evidence: ...) " +
|
|
573
585
|
"annotation resolves (test:/file:/<path>:<line> exists; probe:AC-N passes in " +
|
|
574
586
|
"the evidence envelope), refreshing a missing/stale envelope in-process first. " +
|
|
575
|
-
"Unresolvable annotations abort with STAMP-CHECK-01 before any RFC mutation."
|
|
587
|
+
"Unresolvable annotations abort with STAMP-CHECK-01 before any RFC mutation. " +
|
|
588
|
+
"RFC-1483: retained as an accepted alias — this repair path is the default.",
|
|
589
|
+
},
|
|
590
|
+
"no-repair": {
|
|
591
|
+
kind: "boolean",
|
|
592
|
+
description:
|
|
593
|
+
"RFC-1483: restore the pre-self-repair blocking behavior — no criteria flips, " +
|
|
594
|
+
"no in-process envelope emit; the first prerequisite defect fails the run.",
|
|
576
595
|
},
|
|
577
596
|
},
|
|
578
597
|
execute: runRfcImplementStamp,
|
package/os/rfc/types.ts
CHANGED
|
@@ -12,12 +12,12 @@
|
|
|
12
12
|
* </non-goals>
|
|
13
13
|
* </MODULE_CONTRACT>
|
|
14
14
|
* * <CHANGE_SUMMARY>
|
|
15
|
-
<item>RFC-1445: run-probe timeoutMs + RFC-1445 outcome probe AC-9 (RFC-1445)</item>
|
|
16
15
|
<item>RFC-1458: emit requirement-mapped verdict events from deploy.smoke.run</item>
|
|
17
16
|
<item>RFC-1467: block rfc.create on terminal-kind near-duplicates until --revisit acknowledges + V-52 validate mirror</item>
|
|
18
17
|
<item>RFC-1467: address review r1 findings — object-shaped colliding payload, cite all colliding siblings, reviewBand field, supersede.propose escalation, flag-shape guard</item>
|
|
19
18
|
<item>RFC-1467: declare supersede.propose escalation fields + repair dead related-injector regex</item>
|
|
20
|
-
<
|
|
19
|
+
<item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
|
|
20
|
+
<history>RFC-0465, RFC-0478, RFC-0480, RFC-0795, RFC-0998, RFC-0999, RFC-1097, RFC-1249, RFC-1271, RFC-1306, RFC-1310, RFC-1320, RFC-1322, RFC-1330, RFC-1333, RFC-1334, RFC-1336, RFC-1364, RFC-1383, RFC-1391, RFC-1401, RFC-1445, RFC-1453, RFC-1454, RFC-1455</history>
|
|
21
21
|
</CHANGE_SUMMARY>
|
|
22
22
|
***************************************************************/
|
|
23
23
|
|
|
@@ -755,6 +755,17 @@ export interface RfcImplementStampData {
|
|
|
755
755
|
evidencePath?: string;
|
|
756
756
|
evidenceReEmitted?: boolean;
|
|
757
757
|
metricsPath?: string;
|
|
758
|
+
/** RFC-1483: prerequisite repairs applied (or, under --dry-run, computed) in-flight. */
|
|
759
|
+
repaired?: StampRepair[];
|
|
760
|
+
/** RFC-1483: true when the result is a dry-run projection — repaired[] then lists computed-not-written repairs. */
|
|
761
|
+
dryRun?: boolean;
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
/** RFC-1483: one prerequisite repair applied inside the atomic stamp write. */
|
|
765
|
+
export interface StampRepair {
|
|
766
|
+
kind: "criteria-checked" | "envelope-emitted";
|
|
767
|
+
/** e.g. "AC-3,AC-7" for flipped criteria, or the regenerated envelope path. */
|
|
768
|
+
detail: string;
|
|
758
769
|
}
|
|
759
770
|
|
|
760
771
|
export type RfcImplementStampRule =
|
|
@@ -799,8 +810,27 @@ export type RfcImplementStampRule =
|
|
|
799
810
|
export interface RfcImplementStampViolation {
|
|
800
811
|
rule: RfcImplementStampRule;
|
|
801
812
|
message: string;
|
|
813
|
+
/** RFC-1483: the satisfying command or edit — printed as part of the ordered remediation checklist. */
|
|
814
|
+
fixHint?: string;
|
|
802
815
|
}
|
|
803
816
|
|
|
817
|
+
/**
|
|
818
|
+
* RFC-1483: the prerequisite chain order — emit envelope → check/annotate
|
|
819
|
+
* criteria → clean tree → implementation commit → provenance → hash tail.
|
|
820
|
+
* violations[] are sorted by this list before the report prints: the printed
|
|
821
|
+
* list IS the ordered remediation checklist. Unlisted rules keep their
|
|
822
|
+
* original relative order, appended after the listed ones.
|
|
823
|
+
*/
|
|
824
|
+
export const PREREQUISITE_ORDER: readonly RfcImplementStampRule[] = [
|
|
825
|
+
"RFC-IMP-06",
|
|
826
|
+
"RFC-IMP-02",
|
|
827
|
+
"STAMP-CHECK-01",
|
|
828
|
+
"RFC-IMP-04",
|
|
829
|
+
"RFC-IMP-03",
|
|
830
|
+
"STAMP-GOV-01",
|
|
831
|
+
"RFC-IMP-09",
|
|
832
|
+
];
|
|
833
|
+
|
|
804
834
|
export interface RfcImplementStampResult {
|
|
805
835
|
command: "rfc.implement.stamp";
|
|
806
836
|
status: "pass" | "fail";
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>Unit tests for RFC-IMP-12 candidate binding — covers the imp12 binding acceptance suite surface and its observable contract.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
7
|
+
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
11
|
+
*/
|
|
12
|
+
|
|
1
13
|
// RFC-1333 Design "Stamp gate RFC-IMP-12" — candidate binding: descendants of
|
|
2
14
|
// candidateSha up to the implementation commit may touch only verifier-trailer
|
|
3
15
|
// commits and docs/**.
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>Unit tests for RFC-IMP-12 — covers the imp12 gate acceptance suite surface and its observable contract.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
7
|
+
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
11
|
+
*/
|
|
12
|
+
|
|
1
13
|
// RFC-1333 AC-5, AC-6 — RFC-IMP-12 gate (pure evaluator).
|
|
2
14
|
import { describe, expect, it } from "vitest";
|
|
3
15
|
import { evaluateAcceptanceVerificationGate } from "../../handlers/implement-stamp-origin.ts";
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>Unit tests for RFC-1333 skills/types — covers the skills and types acceptance suite surface and its observable contract.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
7
|
+
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
11
|
+
*/
|
|
12
|
+
|
|
1
13
|
// RFC-1333 AC-3, AC-4, AC-7, AC-8, AC-9.
|
|
2
14
|
import { readFileSync } from "node:fs";
|
|
3
15
|
import { describe, expect, expectTypeOf, it } from "vitest";
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
/*
|
|
2
|
+
<MODULE_CONTRACT>
|
|
3
|
+
<purpose>Unit tests for RFC-1333 rfc.verify.workspace — covers the verify workspace acceptance suite surface and its observable contract.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
7
|
+
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
11
|
+
*/
|
|
12
|
+
|
|
1
13
|
// RFC-1333 AC-1, AC-2, AC-10, Design step 2/3 — rfc.verify.workspace export.
|
|
2
14
|
import { execFileSync } from "node:child_process";
|
|
3
15
|
import { existsSync, mkdirSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
@@ -5,6 +5,9 @@ no-report.proof.test.ts — RFC-1391 verifier fixture: a proof entry that never
|
|
|
5
5
|
calls exhaustive(), so the run produces no report and the verdict must be
|
|
6
6
|
`error` (never `proved`, never `refuted`).
|
|
7
7
|
</purpose>
|
|
8
|
+
<non-goals>
|
|
9
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
10
|
+
</non-goals>
|
|
8
11
|
</MODULE_CONTRACT>
|
|
9
12
|
<CHANGE_SUMMARY>
|
|
10
13
|
<item>RFC-1391 r1 verification: shared verifier support module.</item>
|
|
@@ -22,6 +25,7 @@ config is error not unavailable, and both surfaces share one path; {entry} is
|
|
|
22
25
|
required in formal.tools.command; spec/entry paths are confined to the
|
|
23
26
|
workspace; the exhaustive entry dispatches per packageManager; proved runs
|
|
24
27
|
record log, counterexample stays the refuted-path record.</item>
|
|
28
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
25
29
|
</CHANGE_SUMMARY>
|
|
26
30
|
*/
|
|
27
31
|
|
|
@@ -5,6 +5,9 @@ small-domain.proof.test.ts — RFC-1391 verifier fixture: a proof entry
|
|
|
5
5
|
enumerating exactly 3 inputs through exhaustive(), used to exercise the
|
|
6
6
|
proved path and the cardinality gate.
|
|
7
7
|
</purpose>
|
|
8
|
+
<non-goals>
|
|
9
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
10
|
+
</non-goals>
|
|
8
11
|
</MODULE_CONTRACT>
|
|
9
12
|
<CHANGE_SUMMARY>
|
|
10
13
|
<item>RFC-1391 r1 verification: shared verifier support module.</item>
|
|
@@ -22,6 +25,7 @@ config is error not unavailable, and both surfaces share one path; {entry} is
|
|
|
22
25
|
required in formal.tools.command; spec/entry paths are confined to the
|
|
23
26
|
workspace; the exhaustive entry dispatches per packageManager; proved runs
|
|
24
27
|
record log, counterexample stays the refuted-path record.</item>
|
|
28
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
25
29
|
</CHANGE_SUMMARY>
|
|
26
30
|
*/
|
|
27
31
|
|
|
@@ -5,6 +5,9 @@ Shared fixture builders for the RFC-1391 independent verifier checks —
|
|
|
5
5
|
tmp-workspace and runtime-context helpers only. Nothing here re-implements
|
|
6
6
|
production logic; expectations live in the *.acceptance.test.ts files.
|
|
7
7
|
</purpose>
|
|
8
|
+
<non-goals>
|
|
9
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
10
|
+
</non-goals>
|
|
8
11
|
</MODULE_CONTRACT>
|
|
9
12
|
<CHANGE_SUMMARY>
|
|
10
13
|
<item>RFC-1391 r1 verification: shared verifier support module.</item>
|
|
@@ -22,6 +25,7 @@ config is error not unavailable, and both surfaces share one path; {entry} is
|
|
|
22
25
|
required in formal.tools.command; spec/entry paths are confined to the
|
|
23
26
|
workspace; the exhaustive entry dispatches per packageManager; proved runs
|
|
24
27
|
record log, counterexample stays the refuted-path record.</item>
|
|
28
|
+
<item>RFC-1485: sweep compass headers — forge-os-rfc</item>
|
|
25
29
|
</CHANGE_SUMMARY>
|
|
26
30
|
*/
|
|
27
31
|
|
|
@@ -85,8 +85,11 @@ function extractFilePaths(content: string): string[] {
|
|
|
85
85
|
async function extractCommitHashes(content: string, cwd: string): Promise<string[]> {
|
|
86
86
|
const matches = content.match(COMMIT_HASH_PATTERN);
|
|
87
87
|
if (!matches) return [];
|
|
88
|
-
//
|
|
89
|
-
|
|
88
|
+
// 7-40 hex candidates; all-digit tokens are NOT pre-filtered — a
|
|
89
|
+
// digit-only sha-prefix is a valid commit and `git cat-file` below
|
|
90
|
+
// is the authority on what resolves (digit tokens that are dates or
|
|
91
|
+
// ids simply report `missing` there).
|
|
92
|
+
const candidates = [...new Set(matches)];
|
|
90
93
|
if (candidates.length === 0) return [];
|
|
91
94
|
|
|
92
95
|
// A hex token is recorded as a commit only when it resolves to a commit
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
3
|
<purpose>RFC-1471 session.audit detector tests — AUDIT-10..14 fire on their seeded session shapes; clean session produces zero findings.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
4
7
|
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-tail</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
5
11
|
*/
|
|
6
12
|
|
|
7
13
|
import { test, expect, describe } from "vitest";
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
/*
|
|
2
2
|
<MODULE_CONTRACT>
|
|
3
3
|
<purpose>RFC-1471 session.audit.report tests — sidecar aggregation into docs/metrics/session-audit.generated.yaml, --window filter, unlinked finding classes.</purpose>
|
|
4
|
+
<non-goals>
|
|
5
|
+
<item>TODO(compass): record the boundary this file must not take on.</item>
|
|
6
|
+
</non-goals>
|
|
4
7
|
</MODULE_CONTRACT>
|
|
8
|
+
<CHANGE_SUMMARY>
|
|
9
|
+
<item>RFC-1485: sweep compass headers — forge-os-tail</item>
|
|
10
|
+
</CHANGE_SUMMARY>
|
|
5
11
|
*/
|
|
6
12
|
|
|
7
13
|
import { test, expect, describe, beforeEach, afterEach } from "vitest";
|