@warpgogol/forge 9.0.0 → 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.
Files changed (383) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/bin/cli.ts +3 -2
  3. package/dist/bin/cli.js +3 -2
  4. package/dist/bin/cli.js.map +1 -1
  5. package/dist/os/agent/handlers/agent-tiers-validate.d.ts.map +1 -1
  6. package/dist/os/agent/handlers/agent-tiers-validate.js +5 -1
  7. package/dist/os/agent/handlers/agent-tiers-validate.js.map +1 -1
  8. package/dist/os/agent/index.d.ts.map +1 -1
  9. package/dist/os/agent/index.js +4 -0
  10. package/dist/os/agent/index.js.map +1 -1
  11. package/dist/os/authority/handlers/delegate.d.ts.map +1 -1
  12. package/dist/os/authority/handlers/delegate.js +2 -1
  13. package/dist/os/authority/handlers/delegate.js.map +1 -1
  14. package/dist/os/authority/index.d.ts.map +1 -1
  15. package/dist/os/authority/index.js +2 -1
  16. package/dist/os/authority/index.js.map +1 -1
  17. package/dist/os/checks/checks.module.d.ts.map +1 -1
  18. package/dist/os/checks/checks.module.js +5 -1
  19. package/dist/os/checks/checks.module.js.map +1 -1
  20. package/dist/os/checks/handlers/contribution-report.d.ts.map +1 -1
  21. package/dist/os/checks/handlers/contribution-report.js +5 -4
  22. package/dist/os/checks/handlers/contribution-report.js.map +1 -1
  23. package/dist/os/checks/handlers/counters-export.d.ts.map +1 -1
  24. package/dist/os/checks/handlers/counters-export.js +4 -0
  25. package/dist/os/checks/handlers/counters-export.js.map +1 -1
  26. package/dist/os/checks/handlers/counters-journal.d.ts.map +1 -1
  27. package/dist/os/checks/handlers/counters-journal.js +2 -1
  28. package/dist/os/checks/handlers/counters-journal.js.map +1 -1
  29. package/dist/os/checks/handlers/counters-validate.d.ts.map +1 -1
  30. package/dist/os/checks/handlers/counters-validate.js +5 -1
  31. package/dist/os/checks/handlers/counters-validate.js.map +1 -1
  32. package/dist/os/checks/index.d.ts.map +1 -1
  33. package/dist/os/checks/index.js +11 -0
  34. package/dist/os/checks/index.js.map +1 -1
  35. package/dist/os/compass/handlers/compass-docs-scaffold.js +1 -1
  36. package/dist/os/compass/handlers/compass-header-scaffold.d.ts.map +1 -1
  37. package/dist/os/compass/handlers/compass-header-scaffold.js +6 -1
  38. package/dist/os/compass/handlers/compass-header-scaffold.js.map +1 -1
  39. package/dist/os/compass/handlers/compass-invariants-generate.d.ts.map +1 -1
  40. package/dist/os/compass/handlers/compass-invariants-generate.js +3 -2
  41. package/dist/os/compass/handlers/compass-invariants-generate.js.map +1 -1
  42. package/dist/os/context/context.module.d.ts.map +1 -1
  43. package/dist/os/context/context.module.js +6 -1
  44. package/dist/os/context/context.module.js.map +1 -1
  45. package/dist/os/context/handlers/context-assemble.d.ts.map +1 -1
  46. package/dist/os/context/handlers/context-assemble.js +5 -1
  47. package/dist/os/context/handlers/context-assemble.js.map +1 -1
  48. package/dist/os/context/handlers/context-slate-eval.d.ts.map +1 -1
  49. package/dist/os/context/handlers/context-slate-eval.js +4 -0
  50. package/dist/os/context/handlers/context-slate-eval.js.map +1 -1
  51. package/dist/os/context/handlers/index-build.d.ts.map +1 -1
  52. package/dist/os/context/handlers/index-build.js +8 -5
  53. package/dist/os/context/handlers/index-build.js.map +1 -1
  54. package/dist/os/context/index.d.ts.map +1 -1
  55. package/dist/os/context/index.js +11 -0
  56. package/dist/os/context/index.js.map +1 -1
  57. package/dist/os/gate/handlers/gate-probe-catalog.d.ts.map +1 -1
  58. package/dist/os/gate/handlers/gate-probe-catalog.js +4 -0
  59. package/dist/os/gate/handlers/gate-probe-catalog.js.map +1 -1
  60. package/dist/os/gate/handlers/gate-probe.d.ts.map +1 -1
  61. package/dist/os/gate/handlers/gate-probe.js +4 -0
  62. package/dist/os/gate/handlers/gate-probe.js.map +1 -1
  63. package/dist/os/gate/index.d.ts.map +1 -1
  64. package/dist/os/gate/index.js +11 -0
  65. package/dist/os/gate/index.js.map +1 -1
  66. package/dist/os/instructions/instructions.module.d.ts.map +1 -1
  67. package/dist/os/instructions/instructions.module.js +2 -1
  68. package/dist/os/instructions/instructions.module.js.map +1 -1
  69. package/dist/os/knowledge/handlers/knowledge-authz-probe.d.ts.map +1 -1
  70. package/dist/os/knowledge/handlers/knowledge-authz-probe.js +7 -3
  71. package/dist/os/knowledge/handlers/knowledge-authz-probe.js.map +1 -1
  72. package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.d.ts +11 -0
  73. package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.d.ts.map +1 -0
  74. package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.js +428 -0
  75. package/dist/os/knowledge/handlers/knowledge-conflicts-resolve.js.map +1 -0
  76. package/dist/os/knowledge/handlers/knowledge-rebuild.d.ts.map +1 -1
  77. package/dist/os/knowledge/handlers/knowledge-rebuild.js +4 -0
  78. package/dist/os/knowledge/handlers/knowledge-rebuild.js.map +1 -1
  79. package/dist/os/knowledge/index.d.ts +1 -0
  80. package/dist/os/knowledge/index.d.ts.map +1 -1
  81. package/dist/os/knowledge/index.js +13 -0
  82. package/dist/os/knowledge/index.js.map +1 -1
  83. package/dist/os/knowledge/knowledge.module.d.ts.map +1 -1
  84. package/dist/os/knowledge/knowledge.module.js +35 -1
  85. package/dist/os/knowledge/knowledge.module.js.map +1 -1
  86. package/dist/os/queue/manifest.d.ts.map +1 -1
  87. package/dist/os/queue/manifest.js +8 -7
  88. package/dist/os/queue/manifest.js.map +1 -1
  89. package/dist/os/resolver/resolver.module.d.ts.map +1 -1
  90. package/dist/os/resolver/resolver.module.js +2 -1
  91. package/dist/os/resolver/resolver.module.js.map +1 -1
  92. package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts +1 -0
  93. package/dist/os/rfc/handlers/implement-stamp-deviations.d.ts.map +1 -1
  94. package/dist/os/rfc/handlers/implement-stamp-deviations.js +3 -0
  95. package/dist/os/rfc/handlers/implement-stamp-deviations.js.map +1 -1
  96. package/dist/os/rfc/handlers/implement-stamp-origin.d.ts.map +1 -1
  97. package/dist/os/rfc/handlers/implement-stamp-origin.js +10 -2
  98. package/dist/os/rfc/handlers/implement-stamp-origin.js.map +1 -1
  99. package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts +2 -0
  100. package/dist/os/rfc/handlers/implement-stamp-outcome.d.ts.map +1 -1
  101. package/dist/os/rfc/handlers/implement-stamp-outcome.js +2 -0
  102. package/dist/os/rfc/handlers/implement-stamp-outcome.js.map +1 -1
  103. package/dist/os/rfc/handlers/implement-stamp.d.ts.map +1 -1
  104. package/dist/os/rfc/handlers/implement-stamp.js +176 -59
  105. package/dist/os/rfc/handlers/implement-stamp.js.map +1 -1
  106. package/dist/os/rfc/handlers/lifecycle.d.ts.map +1 -1
  107. package/dist/os/rfc/handlers/lifecycle.js +13 -6
  108. package/dist/os/rfc/handlers/lifecycle.js.map +1 -1
  109. package/dist/os/rfc/handlers/list-create.d.ts.map +1 -1
  110. package/dist/os/rfc/handlers/list-create.js +28 -2
  111. package/dist/os/rfc/handlers/list-create.js.map +1 -1
  112. package/dist/os/rfc/reachable-symbol.d.ts.map +1 -1
  113. package/dist/os/rfc/reachable-symbol.js +4 -2
  114. package/dist/os/rfc/reachable-symbol.js.map +1 -1
  115. package/dist/os/rfc/rfc.module.d.ts.map +1 -1
  116. package/dist/os/rfc/rfc.module.js +23 -7
  117. package/dist/os/rfc/rfc.module.js.map +1 -1
  118. package/dist/os/rfc/types.d.ts +22 -2
  119. package/dist/os/rfc/types.d.ts.map +1 -1
  120. package/dist/os/rfc/types.js +18 -2
  121. package/dist/os/rfc/types.js.map +1 -1
  122. package/dist/os/rfc/verifier/rfc-1391/support.d.ts.map +1 -1
  123. package/dist/os/rfc/verifier/rfc-1391/support.js +4 -0
  124. package/dist/os/rfc/verifier/rfc-1391/support.js.map +1 -1
  125. package/dist/os/session/handlers/save.d.ts.map +1 -1
  126. package/dist/os/session/handlers/save.js +5 -2
  127. package/dist/os/session/handlers/save.js.map +1 -1
  128. package/dist/os/session/handlers/session-audit-report.d.ts.map +1 -1
  129. package/dist/os/session/handlers/session-audit-report.js +4 -0
  130. package/dist/os/session/handlers/session-audit-report.js.map +1 -1
  131. package/dist/os/session/handlers/session-audit.d.ts.map +1 -1
  132. package/dist/os/session/handlers/session-audit.js +4 -0
  133. package/dist/os/session/handlers/session-audit.js.map +1 -1
  134. package/dist/os/trajectory/handlers/journal-io.d.ts +9 -0
  135. package/dist/os/trajectory/handlers/journal-io.d.ts.map +1 -1
  136. package/dist/os/trajectory/handlers/journal-io.js +20 -2
  137. package/dist/os/trajectory/handlers/journal-io.js.map +1 -1
  138. package/dist/os/trajectory/handlers/outcome-record.d.ts.map +1 -1
  139. package/dist/os/trajectory/handlers/outcome-record.js +4 -1
  140. package/dist/os/trajectory/handlers/outcome-record.js.map +1 -1
  141. package/dist/os/trajectory/handlers/trajectory-index.d.ts.map +1 -1
  142. package/dist/os/trajectory/handlers/trajectory-index.js +30 -8
  143. package/dist/os/trajectory/handlers/trajectory-index.js.map +1 -1
  144. package/dist/os/trajectory/handlers/trajectory-recall.d.ts.map +1 -1
  145. package/dist/os/trajectory/handlers/trajectory-recall.js +7 -4
  146. package/dist/os/trajectory/handlers/trajectory-recall.js.map +1 -1
  147. package/dist/os/trajectory/index.d.ts.map +1 -1
  148. package/dist/os/trajectory/index.js +11 -0
  149. package/dist/os/trajectory/index.js.map +1 -1
  150. package/dist/os/trajectory/trajectory.module.d.ts.map +1 -1
  151. package/dist/os/trajectory/trajectory.module.js +16 -9
  152. package/dist/os/trajectory/trajectory.module.js.map +1 -1
  153. package/dist/os/werkstatt/handlers/session-close.d.ts.map +1 -1
  154. package/dist/os/werkstatt/handlers/session-close.js +3 -0
  155. package/dist/os/werkstatt/handlers/session-close.js.map +1 -1
  156. package/dist/os/werkstatt/handlers/session-engine.d.ts.map +1 -1
  157. package/dist/os/werkstatt/handlers/session-engine.js +3 -0
  158. package/dist/os/werkstatt/handlers/session-engine.js.map +1 -1
  159. package/dist/os/werkstatt/handlers/session-open.d.ts.map +1 -1
  160. package/dist/os/werkstatt/handlers/session-open.js +3 -0
  161. package/dist/os/werkstatt/handlers/session-open.js.map +1 -1
  162. package/dist/os/werkstatt/handlers/session-status.d.ts.map +1 -1
  163. package/dist/os/werkstatt/handlers/session-status.js +3 -0
  164. package/dist/os/werkstatt/handlers/session-status.js.map +1 -1
  165. package/dist/os/yaml/handlers/scalars-validate.d.ts +28 -0
  166. package/dist/os/yaml/handlers/scalars-validate.d.ts.map +1 -0
  167. package/dist/os/yaml/handlers/scalars-validate.js +311 -0
  168. package/dist/os/yaml/handlers/scalars-validate.js.map +1 -0
  169. package/dist/os/yaml/index.d.ts +4 -0
  170. package/dist/os/yaml/index.d.ts.map +1 -0
  171. package/dist/os/yaml/index.js +15 -0
  172. package/dist/os/yaml/index.js.map +1 -0
  173. package/dist/os/yaml/yaml.module.d.ts +3 -0
  174. package/dist/os/yaml/yaml.module.d.ts.map +1 -0
  175. package/dist/os/yaml/yaml.module.js +58 -0
  176. package/dist/os/yaml/yaml.module.js.map +1 -0
  177. package/dist/src/authority/delegations.d.ts.map +1 -1
  178. package/dist/src/authority/delegations.js +5 -4
  179. package/dist/src/authority/delegations.js.map +1 -1
  180. package/dist/src/cli-flags.d.ts.map +1 -1
  181. package/dist/src/cli-flags.js +1 -5
  182. package/dist/src/cli-flags.js.map +1 -1
  183. package/dist/src/compass/invariant-parser.d.ts.map +1 -1
  184. package/dist/src/compass/invariant-parser.js +2 -1
  185. package/dist/src/compass/invariant-parser.js.map +1 -1
  186. package/dist/src/config/forge-config.d.ts +17 -0
  187. package/dist/src/config/forge-config.d.ts.map +1 -1
  188. package/dist/src/config/forge-config.js +33 -10
  189. package/dist/src/config/forge-config.js.map +1 -1
  190. package/dist/src/formal/exhaustive.d.ts.map +1 -1
  191. package/dist/src/formal/exhaustive.js +3 -2
  192. package/dist/src/formal/exhaustive.js.map +1 -1
  193. package/dist/src/formal/index.d.ts.map +1 -1
  194. package/dist/src/formal/index.js +4 -0
  195. package/dist/src/formal/index.js.map +1 -1
  196. package/dist/src/formal/proof-runner.d.ts.map +1 -1
  197. package/dist/src/formal/proof-runner.js +4 -3
  198. package/dist/src/formal/proof-runner.js.map +1 -1
  199. package/dist/src/formal/proof-spec.d.ts.map +1 -1
  200. package/dist/src/formal/proof-spec.js +3 -2
  201. package/dist/src/formal/proof-spec.js.map +1 -1
  202. package/dist/src/index.d.ts +1 -1
  203. package/dist/src/index.d.ts.map +1 -1
  204. package/dist/src/index.js +1 -1
  205. package/dist/src/index.js.map +1 -1
  206. package/dist/src/knowledge/index.d.ts +2 -2
  207. package/dist/src/knowledge/index.d.ts.map +1 -1
  208. package/dist/src/knowledge/index.js +4 -3
  209. package/dist/src/knowledge/index.js.map +1 -1
  210. package/dist/src/knowledge/parse.d.ts +1 -0
  211. package/dist/src/knowledge/parse.d.ts.map +1 -1
  212. package/dist/src/knowledge/parse.js +20 -18
  213. package/dist/src/knowledge/parse.js.map +1 -1
  214. package/dist/src/knowledge/schema.d.ts.map +1 -1
  215. package/dist/src/knowledge/schema.js +5 -4
  216. package/dist/src/knowledge/schema.js.map +1 -1
  217. package/dist/src/knowledge/sync.d.ts +61 -0
  218. package/dist/src/knowledge/sync.d.ts.map +1 -1
  219. package/dist/src/knowledge/sync.js +202 -7
  220. package/dist/src/knowledge/sync.js.map +1 -1
  221. package/dist/src/onboarding/agents-generate.js +1 -1
  222. package/dist/src/onboarding/compass-docs/semantic-layer-block.js +1 -1
  223. package/dist/src/onboarding/doctor.d.ts +2 -0
  224. package/dist/src/onboarding/doctor.d.ts.map +1 -1
  225. package/dist/src/onboarding/doctor.js +166 -26
  226. package/dist/src/onboarding/doctor.js.map +1 -1
  227. package/dist/src/onboarding/nested-agents-generate.js +1 -1
  228. package/dist/src/onboarding/nested-agents-templates.js +1 -1
  229. package/dist/src/onboarding/upgrade.d.ts.map +1 -1
  230. package/dist/src/onboarding/upgrade.js +18 -10
  231. package/dist/src/onboarding/upgrade.js.map +1 -1
  232. package/dist/src/reachability/command-mentions.d.ts.map +1 -1
  233. package/dist/src/reachability/command-mentions.js +4 -2
  234. package/dist/src/reachability/command-mentions.js.map +1 -1
  235. package/dist/src/registry.d.ts +20 -0
  236. package/dist/src/registry.d.ts.map +1 -1
  237. package/dist/src/registry.js +129 -67
  238. package/dist/src/registry.js.map +1 -1
  239. package/dist/src/validators/skill-validate.d.ts +5 -0
  240. package/dist/src/validators/skill-validate.d.ts.map +1 -1
  241. package/dist/src/validators/skill-validate.js +34 -8
  242. package/dist/src/validators/skill-validate.js.map +1 -1
  243. package/os/agent/handlers/agent-tiers-validate.ts +5 -1
  244. package/os/agent/index.ts +4 -0
  245. package/os/authority/handlers/delegate.ts +2 -1
  246. package/os/authority/index.ts +2 -1
  247. package/os/checks/checks.module.ts +5 -1
  248. package/os/checks/handlers/contribution-report.test.ts +6 -0
  249. package/os/checks/handlers/contribution-report.ts +5 -4
  250. package/os/checks/handlers/counters-export.test.ts +6 -0
  251. package/os/checks/handlers/counters-export.ts +4 -0
  252. package/os/checks/handlers/counters-journal.test.ts +6 -0
  253. package/os/checks/handlers/counters-journal.ts +2 -1
  254. package/os/checks/handlers/counters-validate.test.ts +6 -0
  255. package/os/checks/handlers/counters-validate.ts +5 -1
  256. package/os/checks/handlers/variant-candidates.test.ts +6 -0
  257. package/os/checks/index.ts +12 -0
  258. package/os/compass/handlers/compass-docs-scaffold.ts +1 -1
  259. package/os/compass/handlers/compass-header-scaffold.ts +6 -1
  260. package/os/compass/handlers/compass-invariants-generate.ts +3 -2
  261. package/os/context/context.module.ts +6 -1
  262. package/os/context/handlers/context-assemble.test.ts +6 -0
  263. package/os/context/handlers/context-assemble.ts +5 -1
  264. package/os/context/handlers/context-slate-eval.test.ts +6 -0
  265. package/os/context/handlers/context-slate-eval.ts +4 -0
  266. package/os/context/handlers/index-build.test.ts +33 -0
  267. package/os/context/handlers/index-build.ts +8 -5
  268. package/os/context/handlers/no-model-deps.test.ts +6 -0
  269. package/os/context/handlers/slate-fill.test.ts +6 -0
  270. package/os/context/index.ts +12 -0
  271. package/os/gate/handlers/gate-probe-catalog.test.ts +6 -0
  272. package/os/gate/handlers/gate-probe-catalog.ts +4 -0
  273. package/os/gate/handlers/gate-probe.test.ts +6 -0
  274. package/os/gate/handlers/gate-probe.ts +4 -0
  275. package/os/gate/index.ts +12 -0
  276. package/os/instructions/budget.test.ts +6 -0
  277. package/os/instructions/instructions.module.ts +2 -1
  278. package/os/knowledge/handlers/knowledge-authz-probe.test.ts +21 -0
  279. package/os/knowledge/handlers/knowledge-authz-probe.ts +7 -3
  280. package/os/knowledge/handlers/knowledge-conflicts-resolve.ts +571 -0
  281. package/os/knowledge/handlers/knowledge-rebuild.test.ts +6 -0
  282. package/os/knowledge/handlers/knowledge-rebuild.ts +4 -0
  283. package/os/knowledge/index.ts +14 -0
  284. package/os/knowledge/knowledge.module.ts +36 -1
  285. package/os/queue/decision-ledger.test.ts +32 -1
  286. package/os/queue/manifest.ts +8 -7
  287. package/os/resolver/handlers/resolver-doors-audit.test.ts +3 -0
  288. package/os/resolver/resolver.module.ts +2 -1
  289. package/os/rfc/handlers/implement-stamp-deviations.ts +4 -1
  290. package/os/rfc/handlers/implement-stamp-origin.ts +10 -2
  291. package/os/rfc/handlers/implement-stamp-outcome.ts +4 -2
  292. package/os/rfc/handlers/implement-stamp-stale.test.ts +2 -1
  293. package/os/rfc/handlers/implement-stamp.ts +188 -58
  294. package/os/rfc/handlers/lifecycle.test.ts +59 -1
  295. package/os/rfc/handlers/lifecycle.ts +25 -15
  296. package/os/rfc/handlers/list-create.test.ts +81 -0
  297. package/os/rfc/handlers/list-create.ts +34 -2
  298. package/os/rfc/handlers/validate-rules-rfc1334.test.ts +2 -1
  299. package/os/rfc/handlers/validate-rules-rfc1453.test.ts +2 -1
  300. package/os/rfc/handlers/validate-rules-rfc1454.test.ts +2 -1
  301. package/os/rfc/handlers/validate-rules-rfc1455.test.ts +2 -1
  302. package/os/rfc/reachable-symbol.ts +4 -2
  303. package/os/rfc/rfc-0000-template.md +16 -0
  304. package/os/rfc/rfc.module.ts +26 -7
  305. package/os/rfc/types.ts +32 -2
  306. package/os/rfc/verifier/rfc-1333/imp12-binding.acceptance.test.ts +12 -0
  307. package/os/rfc/verifier/rfc-1333/imp12-gate.acceptance.test.ts +12 -0
  308. package/os/rfc/verifier/rfc-1333/skills-and-types.acceptance.test.ts +12 -0
  309. package/os/rfc/verifier/rfc-1333/verify-workspace.acceptance.test.ts +12 -0
  310. package/os/rfc/verifier/rfc-1391/fixtures/no-report.proof.test.ts +4 -0
  311. package/os/rfc/verifier/rfc-1391/fixtures/small-domain.proof.test.ts +4 -0
  312. package/os/rfc/verifier/rfc-1391/support.ts +4 -0
  313. package/os/session/handlers/save.ts +5 -2
  314. package/os/session/handlers/session-audit-detectors.test.ts +6 -0
  315. package/os/session/handlers/session-audit-report.test.ts +6 -0
  316. package/os/session/handlers/session-audit-report.ts +4 -0
  317. package/os/session/handlers/session-audit.test.ts +6 -0
  318. package/os/session/handlers/session-audit.ts +4 -0
  319. package/os/trajectory/handlers/extract-units.test.ts +7 -1
  320. package/os/trajectory/handlers/journal-io.ts +20 -2
  321. package/os/trajectory/handlers/outcome-record.test.ts +6 -0
  322. package/os/trajectory/handlers/outcome-record.ts +4 -1
  323. package/os/trajectory/handlers/producer-trust.test.ts +6 -0
  324. package/os/trajectory/handlers/trajectory-index.test.ts +29 -0
  325. package/os/trajectory/handlers/trajectory-index.ts +31 -8
  326. package/os/trajectory/handlers/trajectory-recall.test.ts +27 -0
  327. package/os/trajectory/handlers/trajectory-recall.ts +7 -4
  328. package/os/trajectory/handlers/trajectory.test.ts +6 -0
  329. package/os/trajectory/handlers/verdict-binding.test.ts +40 -0
  330. package/os/trajectory/index.ts +12 -0
  331. package/os/trajectory/trajectory.module.ts +16 -9
  332. package/os/werkstatt/handlers/session-close.ts +3 -0
  333. package/os/werkstatt/handlers/session-engine.ts +3 -0
  334. package/os/werkstatt/handlers/session-open.ts +3 -0
  335. package/os/werkstatt/handlers/session-status.ts +3 -0
  336. package/os/yaml/handlers/scalars-validate.ts +343 -0
  337. package/os/yaml/index.ts +23 -0
  338. package/os/yaml/scalars.test.ts +152 -0
  339. package/os/yaml/yaml.module.ts +61 -0
  340. package/package.json +17 -1
  341. package/skills/fo/fo-knowledge-distill/SKILL.md +6 -5
  342. package/skills/fo/fo-memory-sync/SKILL.md +3 -0
  343. package/skills/fo/fo-memory-sync/fix-patterns.md +65 -0
  344. package/skills/fo/fo-memory-sync/learned-principles.md +10 -0
  345. package/skills/fo/fo-memory-sync/qa-log.md +30 -0
  346. package/skills/fo/fo-session-save/SKILL.md +2 -0
  347. package/skills/shared/grilling/SKILL.md +3 -0
  348. package/skills/shared/writing-great-skills/SKILL.md +12 -9
  349. package/src/authority/delegations.ts +5 -4
  350. package/src/cli-flags.ts +1 -5
  351. package/src/compass/invariant-parser.ts +2 -1
  352. package/src/config/forge-config.ts +40 -14
  353. package/src/formal/exhaustive.ts +3 -2
  354. package/src/formal/index.ts +4 -0
  355. package/src/formal/proof-runner.ts +4 -3
  356. package/src/formal/proof-spec.ts +3 -2
  357. package/src/index.ts +1 -0
  358. package/src/knowledge/index.ts +11 -2
  359. package/src/knowledge/parse.ts +20 -17
  360. package/src/knowledge/schema.ts +5 -4
  361. package/src/knowledge/sync.ts +281 -7
  362. package/src/onboarding/agents-generate.ts +1 -1
  363. package/src/onboarding/compass-docs/semantic-layer-block.ts +1 -1
  364. package/src/onboarding/doctor.ts +184 -26
  365. package/src/onboarding/nested-agents-generate.ts +1 -1
  366. package/src/onboarding/nested-agents-templates.ts +1 -1
  367. package/src/onboarding/upgrade.ts +18 -10
  368. package/src/reachability/command-mentions.ts +4 -2
  369. package/src/registry.ts +153 -74
  370. package/src/tests/cli-flags.test.ts +1 -1
  371. package/src/tests/discover-pack-skills.test.ts +26 -0
  372. package/src/tests/doctor-autonomy.test.ts +144 -0
  373. package/src/tests/doctor-dist-freshness.test.ts +24 -0
  374. package/src/tests/doctor-knowledge-conflicts.test.ts +135 -0
  375. package/src/tests/doctor-nested-agents.test.ts +30 -1
  376. package/src/tests/implement-stamp.test.ts +191 -8
  377. package/src/tests/knowledge-conflicts-resolve.pbt.test.ts +38 -0
  378. package/src/tests/knowledge-conflicts-resolve.test.ts +648 -0
  379. package/src/tests/knowledge-parse.test.ts +26 -1
  380. package/src/tests/session-handlers.test.ts +47 -0
  381. package/src/tests/skill-validate-knowledge.test.ts +93 -2
  382. package/src/tests/upgrade.test.ts +38 -0
  383. package/src/validators/skill-validate.ts +37 -9
@@ -10,6 +10,7 @@ Unit tests for decision ledger covering decisionLedgerSchema (RFC-1250); decisio
10
10
  <CHANGE_SUMMARY>
11
11
  <item>RFC-1311: Compass header sweep — declares the decision suite's contract for test-file scaffold coverage.</item>
12
12
  <item>RFC-1350: queue-batch hardening — ledger baseline field, manifest packagesImpacted + QUEUE-09, COMMIT-GOV-02 manifest scope, test-first policy</item>
13
+ <item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
13
14
  </CHANGE_SUMMARY>
14
15
  */
15
16
 
@@ -18,7 +19,7 @@ import fs from "node:fs/promises";
18
19
  import path from "node:path";
19
20
  import os from "node:os";
20
21
 
21
- import { decisionLedgerPath, loadDecisionLedger } from "./manifest.ts";
22
+ import { decisionLedgerPath, loadDecisionLedger, loadQueueManifest } from "./manifest.ts";
22
23
  import { decisionLedgerSchema } from "./types.ts";
23
24
 
24
25
  let tmpDir: string;
@@ -222,4 +223,34 @@ describe("decisionLedgerPath / loadDecisionLedger (RFC-1250)", () => {
222
223
  expect(errors.some((e) => e.ruleId === "QUEUE-01")).toBe(true);
223
224
  expect(errors[0]?.file).toBe("docs/queues/block-c.decisions.yaml");
224
225
  });
226
+
227
+ // RFC-1482 AC-5: QUEUE-01 on the decisions-ledger path prints the minimal
228
+ // satisfying shape so the fix is readable from the diagnostic, not code.
229
+ test("schema violation carries the minimal required shape (AC-5)", async () => {
230
+ await fs.writeFile(
231
+ path.join(tmpDir, "docs/queues/block-d.decisions.yaml"),
232
+ "id: block-d.decisions\nqueue: block-d\nitems: []\n", // missing createdAt
233
+ );
234
+ const { ledger, errors } = await loadDecisionLedger(tmpDir, "docs/queues/block-d.yaml");
235
+ expect(ledger).toBeNull();
236
+ const queue01 = errors.filter((e) => e.ruleId === "QUEUE-01");
237
+ expect(queue01.length).toBeGreaterThan(0);
238
+ for (const e of queue01) {
239
+ expect(e.message).toContain("id:");
240
+ expect(e.message).toContain("queue:");
241
+ expect(e.message).toContain("createdAt:");
242
+ expect(e.message).toContain("items:");
243
+ }
244
+ });
245
+
246
+ test("manifest-side QUEUE-01 does not gain the ledger hint (scope check)", async () => {
247
+ await fs.writeFile(
248
+ path.join(tmpDir, "docs/queues/block-e.yaml"),
249
+ "items: not-a-list\n", // manifest schema violation — not a ledger
250
+ );
251
+ const { errors } = await loadQueueManifest(tmpDir, "docs/queues/block-e.yaml");
252
+ const queue01 = errors.filter((e) => e.ruleId === "QUEUE-01");
253
+ expect(queue01.length).toBeGreaterThan(0);
254
+ expect(queue01.every((e) => !e.message.includes("minimal shape"))).toBe(true);
255
+ });
225
256
  });
@@ -10,12 +10,6 @@ Also loads the decision-ledger sibling (RFC-1250).</purpose>
10
10
  </non-goals>
11
11
  </MODULE_CONTRACT>
12
12
  <CHANGE_SUMMARY>
13
- <item>RFC-1250: loadDecisionLedger — sibling stem.decisions.yaml resolution,
14
- ENOENT-only absence (other read errors are QUEUE-01 blocking), schema check,
15
- ledger↔manifest binding (queue/id stem QUEUE-02, duplicate Q-N QUEUE-05),
16
- hygiene warnings QUEUE-08 (missing answers, foreign doc ids);
17
- LoadedQueueManifest exposes resolved dependsOn edges for the parking
18
- cascade.</item>
19
13
  <item>RFC-1140: initial manifest loader and validator.</item>
20
14
  <item>RFC-1140: steps 1-4 — shared resolver, queue module, registration
21
15
 
@@ -33,6 +27,8 @@ QUEUE-07 as the window agenda — structural errors still stop the batch;
33
27
  maturation skips parked/deferred items; uncovered imperative ask sites
34
28
  gain collect riders (ADR code-trace, NC markers, audit-verdict guard).</item>
35
29
  <item>RFC-1250: re-review wave — blocked dependsOn cascade, manifest-failure gating, generated artifacts</item>
30
+ <item>RFC-1482: emit validation-compliant RFC skeletons and surface contract breaches at authoring time</item>
31
+ <history>RFC-1250</history>
36
32
  </CHANGE_SUMMARY>
37
33
  */
38
34
 
@@ -294,12 +290,17 @@ export async function loadDecisionLedger(
294
290
 
295
291
  const parsed = decisionLedgerSchema.safeParse(raw);
296
292
  if (!parsed.success) {
293
+ // RFC-1482 AC-5: the diagnostic prints the minimal satisfying shape —
294
+ // the fix is readable from the message, not mined from the schema.
295
+ const ledgerStem = path.basename(absolutePath).replace(/\.(ya?ml)$/i, "");
296
+ const queueId = manifest?.id ?? ledgerStem.replace(/\.decisions$/, "");
297
+ const hint = `; minimal shape — id: ${ledgerStem}; queue: ${queueId}; createdAt: <ISO-8601>; items: []`;
297
298
  for (const issue of parsed.error.issues) {
298
299
  errors.push(
299
300
  diag(
300
301
  "QUEUE-01",
301
302
  "error",
302
- `Decision ledger schema violation at ${issue.path.join(".") || "<root>"}: ${issue.message}`,
303
+ `Decision ledger schema violation at ${issue.path.join(".") || "<root>"}: ${issue.message}${hint}`,
303
304
  displayPath,
304
305
  ),
305
306
  );
@@ -5,6 +5,9 @@
5
5
  <item>Not a contract source of truth — fixtures are minimal scaffolding only.</item>
6
6
  </non-goals>
7
7
  </MODULE_CONTRACT>
8
+ <CHANGE_SUMMARY>
9
+ <item>RFC-1485: sweep compass headers — forge-os-tail</item>
10
+ </CHANGE_SUMMARY>
8
11
  */
9
12
 
10
13
  import { test, expect, describe, beforeEach, afterEach } from "vitest";
@@ -1,6 +1,6 @@
1
1
  /*
2
2
  <MODULE_CONTRACT>
3
- <purpose>Register forgeResolverModule — the canonical-reader parity audit surface (RFC-1465).</purpose>
3
+ <purpose>Registers forgeResolverModule in the resolver module — the canonical-reader parity audit surface exposing resolver.doors.audit.</purpose>
4
4
  <non-goals>
5
5
  <item>Autonomous module — no engine imports (FORGE-AUTONOMY-01).</item>
6
6
  </non-goals>
@@ -8,6 +8,7 @@
8
8
  <CHANGE_SUMMARY>
9
9
  <item>RFC-1465: forgeResolverModule registering resolver.doors.audit</item>
10
10
  <item>RFC-1465: canonical-reader parity audit — resolver.doors.audit with DOOR-01/02/03 over forge.yaml registry</item>
11
+ <item>RFC-1485: sweep compass headers — forge-os-tail</item>
11
12
  </CHANGE_SUMMARY>
12
13
  */
13
14
 
@@ -19,6 +19,7 @@ provenance in `## Deviations` entries.
19
19
  <CHANGE_SUMMARY>
20
20
  <item>RFC-1454: deviation gate — committed-review index, RFC-IMP-15, deviations-section parser for V-49.</item>
21
21
  <item>RFC-1454: review deviations recorded in the RFC — IMP-15 gate, V-49 provenance, skill contract</item>
22
+ <item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
22
23
  </CHANGE_SUMMARY>
23
24
  */
24
25
 
@@ -131,7 +132,7 @@ export interface DeviationGateInput {
131
132
  }
132
133
 
133
134
  export interface DeviationGateResult {
134
- errors: Array<{ rule: "RFC-IMP-15"; message: string }>;
135
+ errors: Array<{ rule: "RFC-IMP-15"; message: string; fixHint?: string }>;
135
136
  }
136
137
 
137
138
  export async function evaluateDeviationGate(
@@ -164,6 +165,7 @@ export async function evaluateDeviationGate(
164
165
  message:
165
166
  `${input.rfcId}: review ${review.reviewId} (${review.path}) carries a malformed designDeviations ` +
166
167
  `entry (id + resolution ∈ {fix, amend} required) — a corrupt record grants nothing (RFC-1454).`,
168
+ fixHint: `fix the designDeviations entry in ${review.path} — every entry needs id + resolution ∈ {fix, amend}`,
167
169
  });
168
170
  continue;
169
171
  }
@@ -175,6 +177,7 @@ export async function evaluateDeviationGate(
175
177
  `${input.rfcId}: review ${review.reviewId} (${review.path}) records amend deviation ${dev.id} ` +
176
178
  `absent from "## Deviations" — add "- ${dev.id} (review ${review.reviewId}): <what changed>" ` +
177
179
  `and edit the affected criterion/probe in the same change (RFC-1454).`,
180
+ fixHint: `add "- ${dev.id} (review ${review.reviewId}): <what changed>" to the RFC's "## Deviations" section and edit the affected criterion/probe in the same change`,
178
181
  });
179
182
  }
180
183
  }
@@ -14,13 +14,15 @@ verificationTier: high RFC.
14
14
  <KEY_DECISIONS>
15
15
  <item>Origins are derived fresh at stamp time (head = HEAD), never read from the committed envelope.</item>
16
16
  <item>`unresolved` never fires RFC-IMP-10 — no contradiction is proven without history.</item>
17
- <item>RFC-IMP-11 severity is a module constant until RFC-1333 provides non-self evidence.</item>
17
+ <item>The high-tier evidence gate severity stays a module constant until the acceptance-report layer lands non-self evidence.</item>
18
18
  </KEY_DECISIONS>
19
19
  <CHANGE_SUMMARY>
20
- <item>RFC-1330: RFC-IMP-10 (blocking) and RFC-IMP-11 (warning until RFC-1333) origin gates.</item>
21
20
  <item>RFC-1333: steps 1-3 — report contract, rfc.verify.workspace export, RFC-IMP-12 gate, RFC-IMP-11 blocking</item>
22
21
  <item>RFC-1333: CX-1/CX-2 fixes — docs/** binding, waiver covers a missing report, IMP-12 for probe-less RFCs; merge-aware fail-closed binding.</item>
23
22
  <item>RFC-1391: make the formal verification tier checker-bound (RFC-1391)</item>
23
+ <item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
24
+ <item>RFC-1485: sweep compass headers — forge-os-rfc</item>
25
+ <history>RFC-1330</history>
24
26
  </CHANGE_SUMMARY>
25
27
  */
26
28
 
@@ -87,6 +89,7 @@ export function evaluateOriginGates(input: OriginGateInput): OriginGateResult {
87
89
  message:
88
90
  `${input.targetId} ${describeProbe(probe, i)} declares expectationSource "${origin.declared}" but git derives it self ` +
89
91
  `(${origin.reason.join("; ")}). Correct the declaration to "self", or obtain non-self evidence — never rewrite history.`,
92
+ fixHint: `correct the expectationSource declaration to "self", or bind genuinely non-self evidence — never rewrite history`,
90
93
  });
91
94
  }
92
95
  });
@@ -102,6 +105,7 @@ export function evaluateOriginGates(input: OriginGateInput): OriginGateResult {
102
105
  const violation: RfcImplementStampViolation = {
103
106
  rule: "RFC-IMP-11",
104
107
  message: `${input.targetId} is verificationTier: ${tier} but ${id} (WHEN/IF) has no bound probe with a non-self effective origin. Obtain independent evidence (post-commitment verification) for ${id}.`,
108
+ fixHint: `bind a probe with a non-self effective origin to ${id}, or lower the declared verificationTier`,
105
109
  };
106
110
  (blocking ? errors : warnings).push(violation);
107
111
  }
@@ -154,6 +158,7 @@ export async function evaluateAcceptanceVerificationGate(
154
158
  errors.push({
155
159
  rule: "RFC-IMP-12",
156
160
  message: `${input.targetId} is verificationTier: ${tier} but has no committed verdict: pass acceptance report in ${ACCEPTANCE_REPORTS_DIR}/${input.targetId.toLowerCase()}/ bound to the current code (only verifier-trailer or docs commits may follow the candidate). Run the independent acceptance verification step.`,
161
+ fixHint: `run the independent acceptance verification step and commit the verdict: pass report — or the operator may pass --waive-independent-verification "<reason>"`,
157
162
  });
158
163
  return { errors, warnings };
159
164
  }
@@ -161,6 +166,7 @@ export async function evaluateAcceptanceVerificationGate(
161
166
  const v: RfcImplementStampViolation = {
162
167
  rule: "RFC-IMP-12",
163
168
  message: `${input.targetId} acceptance report ${bound[0]!.path} records isolation "${String(bound[0]!.frontmatter["isolation"])}", not subagent.`,
169
+ fixHint: `re-run the acceptance verification in a clean-context subagent, or the operator may waive with --waive-independent-verification "<reason>"`,
164
170
  };
165
171
  if (input.waiverReason) {
166
172
  warnings.push({ ...v, message: `${v.message} Waived by operator: ${input.waiverReason}` });
@@ -205,6 +211,7 @@ export function evaluateFormalProofGate(input: FormalProofGateInput): OriginGate
205
211
  `${input.targetId} is verificationTier: formal but declares no proof probe — ` +
206
212
  `formal-tier evidence exists only as a mechanical checker verdict. Add a ` +
207
213
  `\`probe: proof\` binding a forge/proof-spec@1 file.`,
214
+ fixHint: `add a \`probe: proof\` binding a forge/proof-spec@1 file — formal tier has no waiver`,
208
215
  });
209
216
  return { errors, warnings };
210
217
  }
@@ -223,6 +230,7 @@ export function evaluateFormalProofGate(input: FormalProofGateInput): OriginGate
223
230
  `envelope verdict is "${verdict ?? "missing"}". Run \`proof.check --spec ` +
224
231
  `${(p as { spec: string }).spec}\` then \`rfc.verification.emit --id ${input.targetId}\` ` +
225
232
  `until the checker reports proved.`,
233
+ fixHint: `run \`proof.check\` on the bound spec, then \`rfc.verification.emit --id ${input.targetId}\` until the verdict is proved`,
226
234
  });
227
235
  }
228
236
  }
@@ -17,6 +17,7 @@ evaluates a deterministic file set.
17
17
  <CHANGE_SUMMARY>
18
18
  <item>RFC-1453: outcome gate evaluator — diff/surface match, outcome-probe satisfaction, --waive-outcome warning path.</item>
19
19
  <item>RFC-1453: executed outcome probes, IMP-14 surface gate, outcome.serve + V-47/V-48</item>
20
+ <item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
20
21
  </CHANGE_SUMMARY>
21
22
  */
22
23
 
@@ -50,8 +51,8 @@ export interface OutcomeGateInput {
50
51
  }
51
52
 
52
53
  export interface OutcomeGateResult {
53
- errors: Array<{ rule: "RFC-IMP-14"; message: string }>;
54
- warnings: Array<{ rule: "RFC-IMP-14"; message: string }>;
54
+ errors: Array<{ rule: "RFC-IMP-14"; message: string; fixHint?: string }>;
55
+ warnings: Array<{ rule: "RFC-IMP-14"; message: string; fixHint?: string }>;
55
56
  /** True when a touched surface + waived gate fired — the caller records the waiver in the envelope. */
56
57
  waived: boolean;
57
58
  }
@@ -139,6 +140,7 @@ export async function evaluateOutcomeGate(input: OutcomeGateInput): Promise<Outc
139
140
  errors.push({
140
141
  rule: "RFC-IMP-14",
141
142
  message: `${detail} Operator override: re-run with --waive-outcome "<reason>" (operator-directed only).`,
143
+ fixHint: `run the outcome probe for the touched surface and re-emit the envelope — or the operator may pass --waive-outcome "<reason>"`,
142
144
  });
143
145
  return { errors, warnings, waived: false };
144
146
  }
@@ -10,6 +10,7 @@ Unit tests for implement stamp stale covering rfc.implement.stamp — RFC-IMP-09
10
10
  <CHANGE_SUMMARY>
11
11
  <item>RFC-1311: Compass header sweep — declares the implement suite's contract for test-file scaffold coverage.</item>
12
12
  <item>RFC-1310: governance-id parity guards on ecosystem.commit and rfc.implement.stamp</item>
13
+ <item>RFC-1483: self-sufficient implement stamp — default repair pass, ordered remediation checklist, --no-repair</item>
13
14
  </CHANGE_SUMMARY>
14
15
  */
15
16
 
@@ -95,7 +96,7 @@ async function emitEnvelope(dir: string) {
95
96
  const stamp = (dir: string, commit: string) =>
96
97
  runRfcImplementStamp(
97
98
  {
98
- flags: { id: "RFC-0100", "implementation-commit": commit },
99
+ flags: { id: "RFC-0100", "implementation-commit": commit, "no-repair": true },
99
100
  } as unknown as ForgeCommandInput,
100
101
  makeContext(dir),
101
102
  );