@deftai/directive-runtime 0.126.0-beta.3 → 0.128.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 (430) hide show
  1. package/.agents/skills/deft-directive-release/SKILL.md +428 -7
  2. package/.githooks/_directive-run.sh +30 -0
  3. package/.githooks/pre-commit +4 -24
  4. package/.githooks/pre-push +11 -17
  5. package/Taskfile.yml +17 -16
  6. package/contracts/design-critique.md +5 -0
  7. package/dist/cli-router/route-argv.js +1 -0
  8. package/dist/contract-entry.js +2 -4
  9. package/dist/coverage-hotspots.js +2 -2
  10. package/dist/dispatch.d.ts +1 -1
  11. package/dist/dispatch.js +8 -6
  12. package/dist/doctor-diagnose.js +10 -7
  13. package/dist/hook-dispatch.d.ts +1 -1
  14. package/dist/hook-dispatch.js +1 -1
  15. package/dist/install-cli/coverage-map.d.ts +1 -5
  16. package/dist/install-cli/coverage-map.js +28 -22
  17. package/dist/installer-output-inventory.js +1 -4
  18. package/dist/lifecycle-cli/coverage-map.js +37 -35
  19. package/dist/migrate.js +12 -7
  20. package/dist/policy.d.ts +4 -2
  21. package/dist/policy.js +101 -2
  22. package/dist/pre-pr-run.d.ts +2 -0
  23. package/dist/pre-pr-run.js +40 -0
  24. package/dist/removal-steps/index.d.ts +2 -2
  25. package/dist/removal-steps/steps.js +6 -9
  26. package/dist/removal-steps/strategies.js +1 -1
  27. package/dist/render-cli/capability-map-cli.d.ts +3 -0
  28. package/dist/render-cli/capability-map-cli.js +6 -0
  29. package/dist/setup-wiring.d.ts +6 -0
  30. package/dist/setup-wiring.js +20 -7
  31. package/dist/setup.js +12 -14
  32. package/dist/uninstall.js +1 -1
  33. package/dist/vbrief-preflight-fixtures.js +1 -1
  34. package/dist/verify-intent-constraint.d.ts +2 -0
  35. package/dist/verify-intent-constraint.js +24 -0
  36. package/dist/verify-observable-scope.d.ts +2 -0
  37. package/dist/verify-observable-scope.js +24 -0
  38. package/docs/getting-started.md +2 -0
  39. package/docs/intent-constraint.md +7 -1
  40. package/docs/known-limitations.md +1 -0
  41. package/docs/launcher.md +10 -0
  42. package/docs/observable-scope.md +6 -0
  43. package/package.json +1 -1
  44. package/packs/skills/skills-pack-0.1.json +3 -3
  45. package/scm/github.md +1 -0
  46. package/skills/deft-directive-feedback/SKILL.md +9 -20
  47. package/skills/deft-directive-pre-pr/SKILL.md +13 -3
  48. package/skills/deft-directive-release/SKILL.md +4 -4
  49. package/skills/deft-directive-review-cycle/SKILL.md +2 -2
  50. package/skills/deft-directive-setup/SKILL.md +17 -41
  51. package/skills/deft-directive-swarm/references/host-cursor.md +18 -1
  52. package/skills/deft-directive-swarm/references/host-grok-build.md +3 -3
  53. package/skills/deft-directive-sync/SKILL.md +2 -2
  54. package/skills/deft-directive-tutorial/SKILL.md +1 -1
  55. package/tasks/agent.yml +0 -2
  56. package/tasks/cache.yml +0 -16
  57. package/tasks/capacity.yml +0 -4
  58. package/tasks/change.yml +0 -4
  59. package/tasks/codebase.yml +0 -10
  60. package/tasks/commit.yml +0 -2
  61. package/tasks/coverage.yml +0 -2
  62. package/tasks/decision.yml +0 -4
  63. package/tasks/directive.yml +0 -1
  64. package/tasks/docs.yml +6 -10
  65. package/tasks/engine-invoke.cjs +79 -0
  66. package/tasks/engine-invoke.test.cjs +84 -0
  67. package/tasks/engine.yml +27 -81
  68. package/tasks/eval.yml +0 -8
  69. package/tasks/feedback.yml +0 -2
  70. package/tasks/install.yml +0 -4
  71. package/tasks/issue.yml +0 -3
  72. package/tasks/lifecycle.yml +0 -1
  73. package/tasks/materialize.cjs +246 -0
  74. package/tasks/materialize.test.cjs +103 -0
  75. package/tasks/materialize.yml +13 -0
  76. package/tasks/migrate.yml +0 -6
  77. package/tasks/packs.yml +0 -16
  78. package/tasks/plan-sequence.yml +0 -8
  79. package/tasks/policy.yml +0 -24
  80. package/tasks/pr.yml +0 -6
  81. package/tasks/prd.yml +0 -2
  82. package/tasks/product-signal.yml +0 -10
  83. package/tasks/project.yml +0 -8
  84. package/tasks/reconcile.yml +0 -2
  85. package/tasks/review-monitor.yml +0 -4
  86. package/tasks/roadmap.yml +0 -4
  87. package/tasks/scm.yml +0 -32
  88. package/tasks/scope.yml +0 -30
  89. package/tasks/slice.yml +0 -4
  90. package/tasks/spec.yml +0 -6
  91. package/tasks/subagent.yml +0 -4
  92. package/tasks/swarm.yml +0 -7
  93. package/tasks/toolchain.yml +0 -4
  94. package/tasks/triage-actions.yml +0 -8
  95. package/tasks/triage-bootstrap.yml +0 -1
  96. package/tasks/triage-bulk.yml +0 -5
  97. package/tasks/triage-classify.yml +0 -2
  98. package/tasks/triage-evaluate.yml +0 -1
  99. package/tasks/triage-metrics.yml +0 -2
  100. package/tasks/triage-queue.yml +0 -3
  101. package/tasks/triage-reconcile.yml +0 -1
  102. package/tasks/triage-scope-drift.yml +0 -1
  103. package/tasks/triage-scope.yml +0 -1
  104. package/tasks/triage-smoketest.yml +0 -1
  105. package/tasks/triage-subscribe.yml +0 -2
  106. package/tasks/tutorial.yml +0 -20
  107. package/tasks/umbrella.yml +0 -2
  108. package/tasks/value.yml +0 -2
  109. package/tasks/vbrief.yml +0 -12
  110. package/tasks/verify.yml +0 -140
  111. package/tasks/xbrief.yml +0 -6
  112. package/templates/agents-entry.md +1 -0
  113. package/templates/design-critique-brief.md +3 -0
  114. package/vendor/directive-content/.agents/skills/deft-directive-release/SKILL.md +428 -7
  115. package/vendor/directive-content/.githooks/_directive-run.sh +30 -0
  116. package/vendor/directive-content/.githooks/pre-commit +4 -24
  117. package/vendor/directive-content/.githooks/pre-push +11 -17
  118. package/vendor/directive-content/Taskfile.yml +17 -16
  119. package/vendor/directive-content/contracts/design-critique.md +5 -0
  120. package/vendor/directive-content/docs/getting-started.md +2 -0
  121. package/vendor/directive-content/docs/intent-constraint.md +7 -1
  122. package/vendor/directive-content/docs/known-limitations.md +1 -0
  123. package/vendor/directive-content/docs/launcher.md +10 -0
  124. package/vendor/directive-content/docs/observable-scope.md +6 -0
  125. package/vendor/directive-content/packs/skills/skills-pack-0.1.json +3 -3
  126. package/vendor/directive-content/scm/github.md +1 -0
  127. package/vendor/directive-content/skills/deft-directive-feedback/SKILL.md +9 -20
  128. package/vendor/directive-content/skills/deft-directive-pre-pr/SKILL.md +13 -3
  129. package/vendor/directive-content/skills/deft-directive-release/SKILL.md +4 -4
  130. package/vendor/directive-content/skills/deft-directive-review-cycle/SKILL.md +2 -2
  131. package/vendor/directive-content/skills/deft-directive-setup/SKILL.md +17 -41
  132. package/vendor/directive-content/skills/deft-directive-swarm/references/host-cursor.md +18 -1
  133. package/vendor/directive-content/skills/deft-directive-swarm/references/host-grok-build.md +3 -3
  134. package/vendor/directive-content/skills/deft-directive-sync/SKILL.md +2 -2
  135. package/vendor/directive-content/skills/deft-directive-tutorial/SKILL.md +1 -1
  136. package/vendor/directive-content/tasks/agent.yml +0 -2
  137. package/vendor/directive-content/tasks/cache.yml +0 -16
  138. package/vendor/directive-content/tasks/capacity.yml +0 -4
  139. package/vendor/directive-content/tasks/change.yml +0 -4
  140. package/vendor/directive-content/tasks/codebase.yml +0 -10
  141. package/vendor/directive-content/tasks/commit.yml +0 -2
  142. package/vendor/directive-content/tasks/coverage.yml +0 -2
  143. package/vendor/directive-content/tasks/decision.yml +0 -4
  144. package/vendor/directive-content/tasks/directive.yml +0 -1
  145. package/vendor/directive-content/tasks/docs.yml +6 -10
  146. package/vendor/directive-content/tasks/engine-invoke.cjs +79 -0
  147. package/vendor/directive-content/tasks/engine-invoke.test.cjs +84 -0
  148. package/vendor/directive-content/tasks/engine.yml +27 -81
  149. package/vendor/directive-content/tasks/eval.yml +0 -8
  150. package/vendor/directive-content/tasks/feedback.yml +0 -2
  151. package/vendor/directive-content/tasks/install.yml +0 -4
  152. package/vendor/directive-content/tasks/issue.yml +0 -3
  153. package/vendor/directive-content/tasks/lifecycle.yml +0 -1
  154. package/vendor/directive-content/tasks/materialize.cjs +246 -0
  155. package/vendor/directive-content/tasks/materialize.test.cjs +103 -0
  156. package/vendor/directive-content/tasks/materialize.yml +13 -0
  157. package/vendor/directive-content/tasks/migrate.yml +0 -6
  158. package/vendor/directive-content/tasks/packs.yml +0 -16
  159. package/vendor/directive-content/tasks/plan-sequence.yml +0 -8
  160. package/vendor/directive-content/tasks/policy.yml +0 -24
  161. package/vendor/directive-content/tasks/pr.yml +0 -6
  162. package/vendor/directive-content/tasks/prd.yml +0 -2
  163. package/vendor/directive-content/tasks/product-signal.yml +0 -10
  164. package/vendor/directive-content/tasks/project.yml +0 -8
  165. package/vendor/directive-content/tasks/reconcile.yml +0 -2
  166. package/vendor/directive-content/tasks/review-monitor.yml +0 -4
  167. package/vendor/directive-content/tasks/roadmap.yml +0 -4
  168. package/vendor/directive-content/tasks/scm.yml +0 -32
  169. package/vendor/directive-content/tasks/scope.yml +0 -30
  170. package/vendor/directive-content/tasks/slice.yml +0 -4
  171. package/vendor/directive-content/tasks/spec.yml +0 -6
  172. package/vendor/directive-content/tasks/subagent.yml +0 -4
  173. package/vendor/directive-content/tasks/swarm.yml +0 -7
  174. package/vendor/directive-content/tasks/toolchain.yml +0 -4
  175. package/vendor/directive-content/tasks/triage-actions.yml +0 -8
  176. package/vendor/directive-content/tasks/triage-bootstrap.yml +0 -1
  177. package/vendor/directive-content/tasks/triage-bulk.yml +0 -5
  178. package/vendor/directive-content/tasks/triage-classify.yml +0 -2
  179. package/vendor/directive-content/tasks/triage-evaluate.yml +0 -1
  180. package/vendor/directive-content/tasks/triage-metrics.yml +0 -2
  181. package/vendor/directive-content/tasks/triage-queue.yml +0 -3
  182. package/vendor/directive-content/tasks/triage-reconcile.yml +0 -1
  183. package/vendor/directive-content/tasks/triage-scope-drift.yml +0 -1
  184. package/vendor/directive-content/tasks/triage-scope.yml +0 -1
  185. package/vendor/directive-content/tasks/triage-smoketest.yml +0 -1
  186. package/vendor/directive-content/tasks/triage-subscribe.yml +0 -2
  187. package/vendor/directive-content/tasks/tutorial.yml +0 -20
  188. package/vendor/directive-content/tasks/umbrella.yml +0 -2
  189. package/vendor/directive-content/tasks/value.yml +0 -2
  190. package/vendor/directive-content/tasks/vbrief.yml +0 -12
  191. package/vendor/directive-content/tasks/verify.yml +0 -140
  192. package/vendor/directive-content/tasks/xbrief.yml +0 -6
  193. package/vendor/directive-content/templates/agents-entry.md +1 -0
  194. package/vendor/directive-content/templates/design-critique-brief.md +3 -0
  195. package/vendor/directive-core/dist/.tsbuildinfo +1 -1
  196. package/vendor/directive-core/dist/consumer-check-contract/evaluate.d.ts +3 -2
  197. package/vendor/directive-core/dist/consumer-check-contract/evaluate.d.ts.map +1 -1
  198. package/vendor/directive-core/dist/consumer-check-contract/evaluate.js +7 -6
  199. package/vendor/directive-core/dist/consumer-check-contract/evaluate.js.map +1 -1
  200. package/vendor/directive-core/dist/content-contracts/skills/greptile-detector.d.ts +6 -0
  201. package/vendor/directive-core/dist/content-contracts/skills/greptile-detector.d.ts.map +1 -1
  202. package/vendor/directive-core/dist/content-contracts/skills/greptile-detector.js +97 -3
  203. package/vendor/directive-core/dist/content-contracts/skills/greptile-detector.js.map +1 -1
  204. package/vendor/directive-core/dist/content-root.d.ts.map +1 -1
  205. package/vendor/directive-core/dist/content-root.js +8 -1
  206. package/vendor/directive-core/dist/content-root.js.map +1 -1
  207. package/vendor/directive-core/dist/coverage-applicability/evaluate.d.ts.map +1 -1
  208. package/vendor/directive-core/dist/coverage-applicability/evaluate.js +406 -11
  209. package/vendor/directive-core/dist/coverage-applicability/evaluate.js.map +1 -1
  210. package/vendor/directive-core/dist/coverage-hotspots/evaluate.d.ts +13 -5
  211. package/vendor/directive-core/dist/coverage-hotspots/evaluate.d.ts.map +1 -1
  212. package/vendor/directive-core/dist/coverage-hotspots/evaluate.js +60 -2
  213. package/vendor/directive-core/dist/coverage-hotspots/evaluate.js.map +1 -1
  214. package/vendor/directive-core/dist/deposit/live-procedure-targets.d.ts.map +1 -1
  215. package/vendor/directive-core/dist/deposit/live-procedure-targets.js.map +1 -1
  216. package/vendor/directive-core/dist/deposit/python-free.d.ts +2 -0
  217. package/vendor/directive-core/dist/deposit/python-free.d.ts.map +1 -1
  218. package/vendor/directive-core/dist/deposit/python-free.js +5 -1
  219. package/vendor/directive-core/dist/deposit/python-free.js.map +1 -1
  220. package/vendor/directive-core/dist/doctor/checks.d.ts.map +1 -1
  221. package/vendor/directive-core/dist/doctor/checks.js +8 -10
  222. package/vendor/directive-core/dist/doctor/checks.js.map +1 -1
  223. package/vendor/directive-core/dist/doctor/main.d.ts.map +1 -1
  224. package/vendor/directive-core/dist/doctor/main.js +6 -0
  225. package/vendor/directive-core/dist/doctor/main.js.map +1 -1
  226. package/vendor/directive-core/dist/doctor/manifest.d.ts.map +1 -1
  227. package/vendor/directive-core/dist/doctor/manifest.js +3 -2
  228. package/vendor/directive-core/dist/doctor/manifest.js.map +1 -1
  229. package/vendor/directive-core/dist/doctor/paths.d.ts.map +1 -1
  230. package/vendor/directive-core/dist/doctor/paths.js +11 -0
  231. package/vendor/directive-core/dist/doctor/paths.js.map +1 -1
  232. package/vendor/directive-core/dist/engine-version.d.ts.map +1 -1
  233. package/vendor/directive-core/dist/engine-version.js +1 -4
  234. package/vendor/directive-core/dist/engine-version.js.map +1 -1
  235. package/vendor/directive-core/dist/hooks/dispatcher.d.ts +2 -0
  236. package/vendor/directive-core/dist/hooks/dispatcher.d.ts.map +1 -1
  237. package/vendor/directive-core/dist/hooks/dispatcher.js +5 -1
  238. package/vendor/directive-core/dist/hooks/dispatcher.js.map +1 -1
  239. package/vendor/directive-core/dist/index.d.ts +1 -0
  240. package/vendor/directive-core/dist/index.d.ts.map +1 -1
  241. package/vendor/directive-core/dist/index.js +1 -0
  242. package/vendor/directive-core/dist/index.js.map +1 -1
  243. package/vendor/directive-core/dist/init-deposit/agent-hooks.d.ts.map +1 -1
  244. package/vendor/directive-core/dist/init-deposit/agent-hooks.js.map +1 -1
  245. package/vendor/directive-core/dist/init-deposit/scaffold.d.ts +4 -0
  246. package/vendor/directive-core/dist/init-deposit/scaffold.d.ts.map +1 -1
  247. package/vendor/directive-core/dist/init-deposit/scaffold.js +4 -2
  248. package/vendor/directive-core/dist/init-deposit/scaffold.js.map +1 -1
  249. package/vendor/directive-core/dist/install-contract/constants.d.ts.map +1 -1
  250. package/vendor/directive-core/dist/install-contract/constants.js +9 -1
  251. package/vendor/directive-core/dist/install-contract/constants.js.map +1 -1
  252. package/vendor/directive-core/dist/install-contract/data-status.d.ts.map +1 -1
  253. package/vendor/directive-core/dist/install-contract/data-status.js.map +1 -1
  254. package/vendor/directive-core/dist/install-contract/index.d.ts +1 -1
  255. package/vendor/directive-core/dist/install-contract/index.d.ts.map +1 -1
  256. package/vendor/directive-core/dist/install-contract/index.js.map +1 -1
  257. package/vendor/directive-core/dist/install-contract/package-meta.d.ts.map +1 -1
  258. package/vendor/directive-core/dist/install-contract/package-meta.js.map +1 -1
  259. package/vendor/directive-core/dist/install-health/cheap.d.ts.map +1 -1
  260. package/vendor/directive-core/dist/install-health/cheap.js +2 -6
  261. package/vendor/directive-core/dist/install-health/cheap.js.map +1 -1
  262. package/vendor/directive-core/dist/install-health/in-sync.d.ts.map +1 -1
  263. package/vendor/directive-core/dist/install-health/in-sync.js.map +1 -1
  264. package/vendor/directive-core/dist/install-health/index.d.ts +6 -6
  265. package/vendor/directive-core/dist/install-health/index.d.ts.map +1 -1
  266. package/vendor/directive-core/dist/install-health/index.js +3 -3
  267. package/vendor/directive-core/dist/install-health/index.js.map +1 -1
  268. package/vendor/directive-core/dist/install-health/ownership.d.ts.map +1 -1
  269. package/vendor/directive-core/dist/install-health/ownership.js +2 -6
  270. package/vendor/directive-core/dist/install-health/ownership.js.map +1 -1
  271. package/vendor/directive-core/dist/install-health/readers.d.ts.map +1 -1
  272. package/vendor/directive-core/dist/install-health/readers.js.map +1 -1
  273. package/vendor/directive-core/dist/install-health/wiring.d.ts.map +1 -1
  274. package/vendor/directive-core/dist/install-health/wiring.js +2 -3
  275. package/vendor/directive-core/dist/install-health/wiring.js.map +1 -1
  276. package/vendor/directive-core/dist/intent-constraint/evaluate.d.ts +7 -0
  277. package/vendor/directive-core/dist/intent-constraint/evaluate.d.ts.map +1 -1
  278. package/vendor/directive-core/dist/intent-constraint/evaluate.js +26 -5
  279. package/vendor/directive-core/dist/intent-constraint/evaluate.js.map +1 -1
  280. package/vendor/directive-core/dist/intent-constraint/plan-id-adopter.d.ts +76 -0
  281. package/vendor/directive-core/dist/intent-constraint/plan-id-adopter.d.ts.map +1 -0
  282. package/vendor/directive-core/dist/intent-constraint/plan-id-adopter.js +239 -0
  283. package/vendor/directive-core/dist/intent-constraint/plan-id-adopter.js.map +1 -0
  284. package/vendor/directive-core/dist/observable-scope/evaluate.d.ts +7 -0
  285. package/vendor/directive-core/dist/observable-scope/evaluate.d.ts.map +1 -1
  286. package/vendor/directive-core/dist/observable-scope/evaluate.js +51 -7
  287. package/vendor/directive-core/dist/observable-scope/evaluate.js.map +1 -1
  288. package/vendor/directive-core/dist/policy/coverage-mode.d.ts +84 -0
  289. package/vendor/directive-core/dist/policy/coverage-mode.d.ts.map +1 -0
  290. package/vendor/directive-core/dist/policy/coverage-mode.js +226 -0
  291. package/vendor/directive-core/dist/policy/coverage-mode.js.map +1 -0
  292. package/vendor/directive-core/dist/policy/index.d.ts +2 -0
  293. package/vendor/directive-core/dist/policy/index.d.ts.map +1 -1
  294. package/vendor/directive-core/dist/policy/index.js +60 -40
  295. package/vendor/directive-core/dist/policy/index.js.map +1 -1
  296. package/vendor/directive-core/dist/pr-closing-keywords/main.d.ts +2 -0
  297. package/vendor/directive-core/dist/pr-closing-keywords/main.d.ts.map +1 -1
  298. package/vendor/directive-core/dist/pr-closing-keywords/main.js +143 -9
  299. package/vendor/directive-core/dist/pr-closing-keywords/main.js.map +1 -1
  300. package/vendor/directive-core/dist/pre-pr-controller/controller.d.ts +2 -0
  301. package/vendor/directive-core/dist/pre-pr-controller/controller.d.ts.map +1 -1
  302. package/vendor/directive-core/dist/pre-pr-controller/controller.js +109 -14
  303. package/vendor/directive-core/dist/pre-pr-controller/controller.js.map +1 -1
  304. package/vendor/directive-core/dist/pre-pr-controller/evaluate.d.ts +2 -0
  305. package/vendor/directive-core/dist/pre-pr-controller/evaluate.d.ts.map +1 -1
  306. package/vendor/directive-core/dist/pre-pr-controller/evaluate.js +11 -1
  307. package/vendor/directive-core/dist/pre-pr-controller/evaluate.js.map +1 -1
  308. package/vendor/directive-core/dist/pre-pr-controller/index.d.ts +1 -1
  309. package/vendor/directive-core/dist/pre-pr-controller/index.d.ts.map +1 -1
  310. package/vendor/directive-core/dist/pre-pr-controller/index.js +1 -1
  311. package/vendor/directive-core/dist/pre-pr-controller/index.js.map +1 -1
  312. package/vendor/directive-core/dist/pre-pr-controller/phases.d.ts +10 -0
  313. package/vendor/directive-core/dist/pre-pr-controller/phases.d.ts.map +1 -1
  314. package/vendor/directive-core/dist/pre-pr-controller/phases.js +15 -1
  315. package/vendor/directive-core/dist/pre-pr-controller/phases.js.map +1 -1
  316. package/vendor/directive-core/dist/pre-pr-controller/types.d.ts +20 -1
  317. package/vendor/directive-core/dist/pre-pr-controller/types.d.ts.map +1 -1
  318. package/vendor/directive-core/dist/pre-pr-controller/types.js +2 -0
  319. package/vendor/directive-core/dist/pre-pr-controller/types.js.map +1 -1
  320. package/vendor/directive-core/dist/preflight-gh/pre-push.d.ts +40 -3
  321. package/vendor/directive-core/dist/preflight-gh/pre-push.d.ts.map +1 -1
  322. package/vendor/directive-core/dist/preflight-gh/pre-push.js +340 -27
  323. package/vendor/directive-core/dist/preflight-gh/pre-push.js.map +1 -1
  324. package/vendor/directive-core/dist/release/cli-drift-report.d.ts +4 -4
  325. package/vendor/directive-core/dist/release/cli-drift-report.d.ts.map +1 -1
  326. package/vendor/directive-core/dist/release/cli-drift-report.js +6 -11
  327. package/vendor/directive-core/dist/release/cli-drift-report.js.map +1 -1
  328. package/vendor/directive-core/dist/release-e2e/constants.d.ts +4 -3
  329. package/vendor/directive-core/dist/release-e2e/constants.d.ts.map +1 -1
  330. package/vendor/directive-core/dist/release-e2e/constants.js +4 -3
  331. package/vendor/directive-core/dist/release-e2e/constants.js.map +1 -1
  332. package/vendor/directive-core/dist/release-e2e/greenfield-python-free-smoke.d.ts.map +1 -1
  333. package/vendor/directive-core/dist/release-e2e/greenfield-python-free-smoke.js +87 -28
  334. package/vendor/directive-core/dist/release-e2e/greenfield-python-free-smoke.js.map +1 -1
  335. package/vendor/directive-core/dist/release-e2e/legacy-bridge-leg.d.ts.map +1 -1
  336. package/vendor/directive-core/dist/release-e2e/legacy-bridge-leg.js +13 -2
  337. package/vendor/directive-core/dist/release-e2e/legacy-bridge-leg.js.map +1 -1
  338. package/vendor/directive-core/dist/release-e2e/main.js +1 -1
  339. package/vendor/directive-core/dist/release-e2e/npm-ops.d.ts +11 -5
  340. package/vendor/directive-core/dist/release-e2e/npm-ops.d.ts.map +1 -1
  341. package/vendor/directive-core/dist/release-e2e/npm-ops.js +90 -45
  342. package/vendor/directive-core/dist/release-e2e/npm-ops.js.map +1 -1
  343. package/vendor/directive-core/dist/render/project-render.d.ts.map +1 -1
  344. package/vendor/directive-core/dist/render/project-render.js +1 -0
  345. package/vendor/directive-core/dist/render/project-render.js.map +1 -1
  346. package/vendor/directive-core/dist/resolution/engine-resolve.d.ts.map +1 -1
  347. package/vendor/directive-core/dist/resolution/engine-resolve.js.map +1 -1
  348. package/vendor/directive-core/dist/resolution/pin.d.ts +11 -5
  349. package/vendor/directive-core/dist/resolution/pin.d.ts.map +1 -1
  350. package/vendor/directive-core/dist/resolution/pin.js +20 -11
  351. package/vendor/directive-core/dist/resolution/pin.js.map +1 -1
  352. package/vendor/directive-core/dist/resolution/plan.d.ts.map +1 -1
  353. package/vendor/directive-core/dist/resolution/plan.js +5 -3
  354. package/vendor/directive-core/dist/resolution/plan.js.map +1 -1
  355. package/vendor/directive-core/dist/review-monitor/bounded-pr-watch-deny.d.ts +54 -3
  356. package/vendor/directive-core/dist/review-monitor/bounded-pr-watch-deny.d.ts.map +1 -1
  357. package/vendor/directive-core/dist/review-monitor/bounded-pr-watch-deny.js +142 -0
  358. package/vendor/directive-core/dist/review-monitor/bounded-pr-watch-deny.js.map +1 -1
  359. package/vendor/directive-core/dist/scope/file-scope-coverage-warn.d.ts +21 -0
  360. package/vendor/directive-core/dist/scope/file-scope-coverage-warn.d.ts.map +1 -0
  361. package/vendor/directive-core/dist/scope/file-scope-coverage-warn.js +95 -0
  362. package/vendor/directive-core/dist/scope/file-scope-coverage-warn.js.map +1 -0
  363. package/vendor/directive-core/dist/session/spawn-occupancy.d.ts +7 -0
  364. package/vendor/directive-core/dist/session/spawn-occupancy.d.ts.map +1 -1
  365. package/vendor/directive-core/dist/session/spawn-occupancy.js +28 -0
  366. package/vendor/directive-core/dist/session/spawn-occupancy.js.map +1 -1
  367. package/vendor/directive-core/dist/staleness-tickler/run.d.ts.map +1 -1
  368. package/vendor/directive-core/dist/staleness-tickler/run.js.map +1 -1
  369. package/vendor/directive-core/dist/swarm/approach1-babysitter.d.ts +19 -6
  370. package/vendor/directive-core/dist/swarm/approach1-babysitter.d.ts.map +1 -1
  371. package/vendor/directive-core/dist/swarm/approach1-babysitter.js +69 -9
  372. package/vendor/directive-core/dist/swarm/approach1-babysitter.js.map +1 -1
  373. package/vendor/directive-core/dist/swarm/dest-place.d.ts +1 -1
  374. package/vendor/directive-core/dist/swarm/dest-place.d.ts.map +1 -1
  375. package/vendor/directive-core/dist/swarm/dest-place.js +1 -1
  376. package/vendor/directive-core/dist/swarm/dest-place.js.map +1 -1
  377. package/vendor/directive-core/dist/swarm/launch-cli.d.ts.map +1 -1
  378. package/vendor/directive-core/dist/swarm/launch-cli.js +12 -0
  379. package/vendor/directive-core/dist/swarm/launch-cli.js.map +1 -1
  380. package/vendor/directive-core/dist/swarm/launch.d.ts +6 -0
  381. package/vendor/directive-core/dist/swarm/launch.d.ts.map +1 -1
  382. package/vendor/directive-core/dist/swarm/launch.js +11 -0
  383. package/vendor/directive-core/dist/swarm/launch.js.map +1 -1
  384. package/vendor/directive-core/dist/swarm/leftover-before-activation.d.ts +27 -0
  385. package/vendor/directive-core/dist/swarm/leftover-before-activation.d.ts.map +1 -0
  386. package/vendor/directive-core/dist/swarm/leftover-before-activation.js +31 -0
  387. package/vendor/directive-core/dist/swarm/leftover-before-activation.js.map +1 -0
  388. package/vendor/directive-core/dist/swarm/worktree-pm-install.d.ts +5 -0
  389. package/vendor/directive-core/dist/swarm/worktree-pm-install.d.ts.map +1 -1
  390. package/vendor/directive-core/dist/swarm/worktree-pm-install.js +16 -6
  391. package/vendor/directive-core/dist/swarm/worktree-pm-install.js.map +1 -1
  392. package/vendor/directive-core/dist/swarm/worktrees.d.ts.map +1 -1
  393. package/vendor/directive-core/dist/swarm/worktrees.js.map +1 -1
  394. package/vendor/directive-core/dist/text/redos-safe.d.ts.map +1 -1
  395. package/vendor/directive-core/dist/text/redos-safe.js +2 -1
  396. package/vendor/directive-core/dist/text/redos-safe.js.map +1 -1
  397. package/vendor/directive-core/dist/triage/evaluate/worktrees.d.ts.map +1 -1
  398. package/vendor/directive-core/dist/triage/evaluate/worktrees.js +6 -6
  399. package/vendor/directive-core/dist/triage/evaluate/worktrees.js.map +1 -1
  400. package/vendor/directive-core/dist/vbrief-validate/conformance.d.ts.map +1 -1
  401. package/vendor/directive-core/dist/vbrief-validate/conformance.js +5 -0
  402. package/vendor/directive-core/dist/vbrief-validate/conformance.js.map +1 -1
  403. package/vendor/directive-core/dist/verify-env/agent-hooks-live-probe.js +1 -1
  404. package/vendor/directive-core/dist/verify-env/agent-hooks-live-probe.js.map +1 -1
  405. package/vendor/directive-core/dist/verify-env/verify-hooks-installed.d.ts +3 -3
  406. package/vendor/directive-core/dist/verify-env/verify-hooks-installed.d.ts.map +1 -1
  407. package/vendor/directive-core/dist/verify-env/verify-hooks-installed.js +7 -11
  408. package/vendor/directive-core/dist/verify-env/verify-hooks-installed.js.map +1 -1
  409. package/vendor/directive-core/dist/verify-source/project-definition-mutation-boundary.d.ts.map +1 -1
  410. package/vendor/directive-core/dist/verify-source/project-definition-mutation-boundary.js +1 -0
  411. package/vendor/directive-core/dist/verify-source/project-definition-mutation-boundary.js.map +1 -1
  412. package/vendor/directive-core/dist/xbrief/paths.d.ts.map +1 -1
  413. package/vendor/directive-core/dist/xbrief/paths.js +15 -12
  414. package/vendor/directive-core/dist/xbrief/paths.js.map +1 -1
  415. package/vendor/directive-core/dist/xbrief-migrate/constants.d.ts +7 -0
  416. package/vendor/directive-core/dist/xbrief-migrate/constants.d.ts.map +1 -1
  417. package/vendor/directive-core/dist/xbrief-migrate/constants.js +7 -0
  418. package/vendor/directive-core/dist/xbrief-migrate/constants.js.map +1 -1
  419. package/vendor/directive-core/dist/xbrief-migrate/detect.d.ts +9 -1
  420. package/vendor/directive-core/dist/xbrief-migrate/detect.d.ts.map +1 -1
  421. package/vendor/directive-core/dist/xbrief-migrate/detect.js +14 -7
  422. package/vendor/directive-core/dist/xbrief-migrate/detect.js.map +1 -1
  423. package/vendor/directive-core/dist/xbrief-migrate/migrate-project.d.ts.map +1 -1
  424. package/vendor/directive-core/dist/xbrief-migrate/migrate-project.js +118 -57
  425. package/vendor/directive-core/dist/xbrief-migrate/migrate-project.js.map +1 -1
  426. package/vendor/directive-core/dist/xbrief-migrate/transforms.d.ts.map +1 -1
  427. package/vendor/directive-core/dist/xbrief-migrate/transforms.js +8 -1
  428. package/vendor/directive-core/dist/xbrief-migrate/transforms.js.map +1 -1
  429. package/.githooks/_deft-run.sh +0 -47
  430. package/vendor/directive-content/.githooks/_deft-run.sh +0 -47
@@ -0,0 +1,3 @@
1
+ /** Thin dispatch wrapper for `capability-map` (#5841); mirrors rule-map-cli. */
2
+ export declare function runCapabilityMapCli(argv: readonly string[]): number;
3
+ //# sourceMappingURL=capability-map-cli.d.ts.map
@@ -0,0 +1,6 @@
1
+ import { capabilityMapMain } from "../../vendor/directive-core/dist/docs/capability-map.js";
2
+ /** Thin dispatch wrapper for `capability-map` (#5841); mirrors rule-map-cli. */
3
+ export function runCapabilityMapCli(argv) {
4
+ return capabilityMapMain(argv);
5
+ }
6
+ //# sourceMappingURL=capability-map-cli.js.map
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Package-relative wiring writers for Contract 1 setup (Wave 2c / R9 / AC13.1).
3
+ * All managed pointers target node_modules/@deftai/directive-runtime/ — never .deft/core.
4
+ */
1
5
  import { type HostHooksPolicy } from "@deftai/directive-core/dist/policy/host-hooks.js";
2
6
  export declare const RUNTIME_PREFIX = "node_modules/@deftai/directive-runtime/";
3
7
  export declare const HOOK_BIN_COMMAND = "node node_modules/@deftai/directive-runtime/dist/hook-bin.js";
@@ -76,6 +80,8 @@ export declare function ensureHostHooks(projectRoot: string, hostHooksPolicy?: H
76
80
  created: string[];
77
81
  modified: string[];
78
82
  };
83
+ /** Monotonic refuse-to-downgrade marker for marker-aware ensureGitHooks (#5804). */
84
+ export declare const PRE_PUSH_BOUND_PRE_PR_MARKER = "deft:pre-pr-bound-push-v1";
79
85
  /** AC8.6 / AC2.5 / F-008 — disclosed when hooks files exist but core.hooksPath cannot activate. */
80
86
  export declare const GIT_HOOKS_INACTIVE_NO_GIT = "Git hooks inactive until git init + eligible repair/self-complete (core.hooksPath not set)";
81
87
  export declare function ensureGitHooks(projectRoot: string): {
@@ -2,9 +2,9 @@
2
2
  * Package-relative wiring writers for Contract 1 setup (Wave 2c / R9 / AC13.1).
3
3
  * All managed pointers target node_modules/@deftai/directive-runtime/ — never .deft/core.
4
4
  */
5
+ import { execFileSync } from "node:child_process";
5
6
  import { existsSync, readdirSync, readFileSync } from "node:fs";
6
7
  import { dirname, join } from "node:path";
7
- import { execFileSync } from "node:child_process";
8
8
  import { fileURLToPath } from "node:url";
9
9
  import { containedChmod, containedRemove, containedWrite, } from "../vendor/directive-core/dist/fs/contained-write.js";
10
10
  import { DIRECT_WRITE_HOOK_MATCHER, KILL_HOOK_MATCHER, MCP_HOOK_MATCHER, SHELL_HOOK_MATCHER, SPAWN_HOOK_MATCHER, } from "../vendor/directive-core/dist/hooks/tools.js";
@@ -555,7 +555,9 @@ function mergeNestedHost(existing, host, options) {
555
555
  }
556
556
  function mergeCursorHost(existing) {
557
557
  const hooks = object(existing.hooks) ?? {};
558
- const keep = (key) => Array.isArray(hooks[key]) ? hooks[key].filter((e) => !cursorManagedEntry(e)) : [];
558
+ const keep = (key) => Array.isArray(hooks[key])
559
+ ? hooks[key].filter((e) => !cursorManagedEntry(e))
560
+ : [];
559
561
  return {
560
562
  ...existing,
561
563
  version: 1,
@@ -703,11 +705,16 @@ REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null)" || exit 1
703
705
  run_directive verify:encoding --staged --project-root "$REPO_ROOT" || exit $?
704
706
  `;
705
707
  const PRE_PUSH = `#!/usr/bin/env sh
708
+ # deft:pre-pr-bound-push-v1 — refuse-to-downgrade marker (#5804); marker-aware ensureGitHooks only
706
709
  REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null)" || exit 1
707
710
  # shellcheck source=/dev/null
708
711
  . "$REPO_ROOT/.githooks/_directive-run.sh"
709
712
  run_directive verify:branch --project-root "$REPO_ROOT" || exit $?
713
+ # Enrolled bound pre-PR arm: sole-stdin (do not redirect shared run_directive to /dev/null)
714
+ run_directive pre-pr:run --push-admit --project-root "$REPO_ROOT" || exit $?
710
715
  `;
716
+ /** Monotonic refuse-to-downgrade marker for marker-aware ensureGitHooks (#5804). */
717
+ export const PRE_PUSH_BOUND_PRE_PR_MARKER = "deft:pre-pr-bound-push-v1";
711
718
  /**
712
719
  * Current OVPR helpers plus supported latest-legacy Directive git hooks
713
720
  * (`_deft-run.sh` / `run_deft` / copied-core era). True third-party hooks
@@ -749,6 +756,15 @@ export function ensureGitHooks(projectRoot) {
749
756
  conflicts.push(`${file.rel}: existing hook is not Directive-managed; refusing to overwrite (chain or remove manually)`);
750
757
  continue;
751
758
  }
759
+ // Refuse-to-downgrade: marker-aware installer will not replace a newer enrolled
760
+ // pre-push arm with an older body that lacks the monotonic marker (#5804).
761
+ if (file.rel === ".githooks/pre-push" &&
762
+ prior !== null &&
763
+ prior.includes(PRE_PUSH_BOUND_PRE_PR_MARKER) &&
764
+ !next.includes(PRE_PUSH_BOUND_PRE_PR_MARKER)) {
765
+ conflicts.push(`${file.rel}: refuse-to-downgrade enrolled bound pre-PR arm (${PRE_PUSH_BOUND_PRE_PR_MARKER}); keeping newer hook`);
766
+ continue;
767
+ }
752
768
  const change = trackChange(projectRoot, file.rel, next);
753
769
  if (change.created)
754
770
  created.push(file.rel);
@@ -820,8 +836,7 @@ export function ensureGitHooks(projectRoot) {
820
836
  hooksPathActive = true;
821
837
  }
822
838
  catch {
823
- inactiveDisclosure =
824
- "Git hooks inactive: could not set core.hooksPath=.githooks";
839
+ inactiveDisclosure = "Git hooks inactive: could not set core.hooksPath=.githooks";
825
840
  }
826
841
  }
827
842
  else if (current === ".githooks" || current === ".githooks/") {
@@ -842,9 +857,7 @@ includes:
842
857
  ${RUNTIME_TASKFILE_INCLUDE}
843
858
  optional: true
844
859
  `;
845
- const DEFT_INCLUDE_BLOCK = ` deft:\n` +
846
- ` taskfile: ./${RUNTIME_PREFIX}Taskfile.yml\n` +
847
- ` optional: true\n`;
860
+ const DEFT_INCLUDE_BLOCK = ` deft:\n` + ` taskfile: ./${RUNTIME_PREFIX}Taskfile.yml\n` + ` optional: true\n`;
848
861
  /**
849
862
  * Merge the Directive `deft:` include into an existing Taskfile without
850
863
  * duplicating top-level `includes:` keys or an occupied `deft` child.
package/dist/setup.js CHANGED
@@ -10,10 +10,10 @@ import { dirname, join } from "node:path";
10
10
  import { fileURLToPath } from "node:url";
11
11
  import { ContainedWriteError, containedRemove, containedWrite, } from "../vendor/directive-core/dist/fs/contained-write.js";
12
12
  import { buildOwnershipRecord, fingerprintContent, ownershipRecordsEqual, readEvidenceGenerationNumber, readOwnershipRecord, writeOwnershipRecord, } from "../vendor/directive-core/dist/install-health/index.js";
13
- import { CURRENT_DATA_SCHEMA_VERSION, DATA_SCHEMA_MARKER_REL, } from "./migrate.js";
14
- import { isConvertStrategyFrom, runStrategy, } from "./removal-steps/index.js";
15
- import { ensureAgentsManagedSection, ensureGitHooks, ensureHostHooks, ensureOpenClawIntegrations, ensureSkillPointers, ensureSlashCommands, ensureTaskfileInclude, listSkillPointerPaths, listVerifiedManagedSlashCommandPaths, RUNTIME_PREFIX, } from "./setup-wiring.js";
16
13
  import { assertInventoryCompleteness } from "./installer-output-inventory.js";
14
+ import { CURRENT_DATA_SCHEMA_VERSION, DATA_SCHEMA_MARKER_REL } from "./migrate.js";
15
+ import { isConvertStrategyFrom, runStrategy } from "./removal-steps/index.js";
16
+ import { ensureAgentsManagedSection, ensureGitHooks, ensureHostHooks, ensureOpenClawIntegrations, ensureSkillPointers, ensureSlashCommands, ensureTaskfileInclude, listSkillPointerPaths, listVerifiedManagedSlashCommandPaths, RUNTIME_PREFIX, } from "./setup-wiring.js";
17
17
  const SEED_PLACEHOLDER_REL = "xbrief/.directive-seed-placeholder";
18
18
  const GEN_REL = ".deft/GENERATION.json";
19
19
  const WIRING_READY_DIR_REL = ".deft/directive";
@@ -174,11 +174,7 @@ function buildOwnershipArtifacts(projectRoot) {
174
174
  });
175
175
  }
176
176
  }
177
- for (const rel of [
178
- ".githooks/pre-commit",
179
- ".githooks/pre-push",
180
- ".githooks/_directive-run.sh",
181
- ]) {
177
+ for (const rel of [".githooks/pre-commit", ".githooks/pre-push", ".githooks/_directive-run.sh"]) {
182
178
  const body = readText(join(projectRoot, rel));
183
179
  if (body !== null) {
184
180
  artifacts.push({
@@ -311,16 +307,18 @@ export function runSetup(options) {
311
307
  conflicts.push(taskfile.conflictReason ?? "Taskfile.yml: include conflict");
312
308
  }
313
309
  // Seeds only on first-time install (AC8.4); repair/upgrade never create them.
314
- // AC6.2: also leave data-schema current for empty/seeded install. Repair must
315
- // not migrate; upgrade still migrates when data is truly behind.
310
+ // AC6.2: leave data-schema current for empty/seeded install. Repair may write a
311
+ // missing marker (not a migration); upgrade still migrates when data is behind.
316
312
  if (operation === "install" && conflicts.length === 0) {
317
313
  const seed = createSeedPlaceholder(root);
318
314
  if (seed !== null)
319
315
  created.push(seed);
320
- if (!existsSync(join(root, DATA_SCHEMA_MARKER_REL))) {
321
- writeContained(root, DATA_SCHEMA_MARKER_REL, `${JSON.stringify({ schemaVersion: CURRENT_DATA_SCHEMA_VERSION }, null, 2)}\n`);
322
- created.push(DATA_SCHEMA_MARKER_REL);
323
- }
316
+ }
317
+ if ((operation === "install" || operation === "repair") &&
318
+ conflicts.length === 0 &&
319
+ !existsSync(join(root, DATA_SCHEMA_MARKER_REL))) {
320
+ writeContained(root, DATA_SCHEMA_MARKER_REL, `${JSON.stringify({ schemaVersion: CURRENT_DATA_SCHEMA_VERSION }, null, 2)}\n`);
321
+ created.push(DATA_SCHEMA_MARKER_REL);
324
322
  }
325
323
  // AC13.1: never materialize a content copy under .deft/core.
326
324
  const desired = buildOwnershipRecord({
package/dist/uninstall.js CHANGED
@@ -9,7 +9,7 @@ import { join } from "node:path";
9
9
  import { containedRemove } from "../vendor/directive-core/dist/fs/contained-write.js";
10
10
  import { inspectOwnershipRecord, MANAGED_SECTION_CLOSE, MANAGED_SECTION_OPEN_PREFIX, } from "../vendor/directive-core/dist/install-health/index.js";
11
11
  import { pruneEmptyAncestors, removeSoleAuthorHusks } from "./removal-steps/steps.js";
12
- import { HOOK_BIN_COMMAND, RUNTIME_PREFIX, SKILL_POINTER_INVENTORY, } from "./setup-wiring.js";
12
+ import { HOOK_BIN_COMMAND, RUNTIME_PREFIX, SKILL_POINTER_INVENTORY } from "./setup-wiring.js";
13
13
  const SKILL_HOST_ROOTS = [
14
14
  ".agents/skills",
15
15
  ".claude/skills",
@@ -59,7 +59,7 @@ export function buildFixtures(root) {
59
59
  /** Render a human-readable parity report (exported for unit tests). */
60
60
  export function renderReport(result) {
61
61
  if (result.ok) {
62
- return `vbrief_preflight parity: CLEAN -- Python and TS agree on ${result.cases.length} fixture(s).`;
62
+ return `vbrief_preflight parity: CLEAN -- Python and TS agree on ${result.cases.length} fixtures.`;
63
63
  }
64
64
  const lines = ["vbrief_preflight parity: DIVERGENCE"];
65
65
  for (const c of result.cases.filter((x) => !x.ok)) {
@@ -5,6 +5,8 @@ interface ParsedArgs {
5
5
  staged: boolean;
6
6
  quiet: boolean;
7
7
  planId?: string;
8
+ pr?: string;
9
+ repo?: string;
8
10
  error?: string;
9
11
  }
10
12
  /** Parse verify-intent-constraint CLI args. */
@@ -46,6 +46,28 @@ export function parseArgs(argv) {
46
46
  else if (arg?.startsWith("--plan-id=")) {
47
47
  parsed.planId = arg.slice("--plan-id=".length);
48
48
  }
49
+ else if (arg === "--pr") {
50
+ const value = argv[i + 1];
51
+ if (value === undefined) {
52
+ return { ...parsed, error: "argument --pr: expected one argument" };
53
+ }
54
+ parsed.pr = value;
55
+ i += 1;
56
+ }
57
+ else if (arg?.startsWith("--pr=")) {
58
+ parsed.pr = arg.slice("--pr=".length);
59
+ }
60
+ else if (arg === "--repo") {
61
+ const value = argv[i + 1];
62
+ if (value === undefined) {
63
+ return { ...parsed, error: "argument --repo: expected one argument" };
64
+ }
65
+ parsed.repo = value;
66
+ i += 1;
67
+ }
68
+ else if (arg?.startsWith("--repo=")) {
69
+ parsed.repo = arg.slice("--repo=".length);
70
+ }
49
71
  else if (arg === "--base-ref") {
50
72
  return {
51
73
  ...parsed,
@@ -71,6 +93,8 @@ export function run(argv) {
71
93
  staged: args.staged,
72
94
  quiet: args.quiet,
73
95
  planId: args.planId,
96
+ pr: args.pr,
97
+ repo: args.repo,
74
98
  });
75
99
  if (result.message.length > 0) {
76
100
  if (result.stream === "stdout")
@@ -5,6 +5,8 @@ interface ParsedArgs {
5
5
  staged: boolean;
6
6
  quiet: boolean;
7
7
  planId?: string;
8
+ pr?: string;
9
+ repo?: string;
8
10
  error?: string;
9
11
  }
10
12
  /** Parse verify-observable-scope CLI args. */
@@ -46,6 +46,28 @@ export function parseArgs(argv) {
46
46
  else if (arg?.startsWith("--plan-id=")) {
47
47
  parsed.planId = arg.slice("--plan-id=".length);
48
48
  }
49
+ else if (arg === "--pr") {
50
+ const value = argv[i + 1];
51
+ if (value === undefined) {
52
+ return { ...parsed, error: "argument --pr: expected one argument" };
53
+ }
54
+ parsed.pr = value;
55
+ i += 1;
56
+ }
57
+ else if (arg?.startsWith("--pr=")) {
58
+ parsed.pr = arg.slice("--pr=".length);
59
+ }
60
+ else if (arg === "--repo") {
61
+ const value = argv[i + 1];
62
+ if (value === undefined) {
63
+ return { ...parsed, error: "argument --repo: expected one argument" };
64
+ }
65
+ parsed.repo = value;
66
+ i += 1;
67
+ }
68
+ else if (arg?.startsWith("--repo=")) {
69
+ parsed.repo = arg.slice("--repo=".length);
70
+ }
49
71
  else if (arg === "--base-ref") {
50
72
  return {
51
73
  ...parsed,
@@ -71,6 +93,8 @@ export function run(argv) {
71
93
  staged: args.staged,
72
94
  quiet: args.quiet,
73
95
  planId: args.planId,
96
+ pr: args.pr,
97
+ repo: args.repo,
74
98
  });
75
99
  if (result.message.length > 0) {
76
100
  if (result.stream === "stdout")
@@ -39,6 +39,8 @@ Two published packages: global **`@deftai/directive`** (launcher) and project-pi
39
39
 
40
40
  Framework maintainers of this repository use a separate Node 24 pin; see [CONTRIBUTING.md](../../CONTRIBUTING.md).
41
41
 
42
+ Maintainer execution on this repo: after `git pull` / FF, hooks and ordinary `task <verb>` use the pin under `node_modules/@deftai/directive-runtime`. Tip dogfood without publishing is an explicit `task materialize:runtime` into **this** checkout only (each worktree installs/materializes its own pin). See [launcher.md](./launcher.md).
43
+
42
44
  ---
43
45
 
44
46
  ## Installation
@@ -11,7 +11,13 @@ First ship is a merge-base snapshot of throw/reject/abort sites and new numeric
11
11
  3. Numeric-const peel is a while-unwrap of `AsExpression` (any asserted type), `SatisfiesExpression`, unary `+`/`-`, `ParenthesizedExpression`, and angle-bracket `TypeAssertion` until `NumericLiteral`. Do not `forEachChild`-harvest `NumericLiteral` (`Number(1024)`, `{ max: 1024 }`). Do not treat a numeric literal anywhere in an if-condition as a hard constraint.
12
12
  4. Same-file helper extract of a posted throw plus same-file const is in the snapshot. Cross-file composition is a recorded first-ship miss.
13
13
  5. Leftover is skip/filter/return-error that add neither a new numeric-const nor a throw/reject/abort site. Skip plus a new numeric const is not leftover.
14
- 6. Durable authority is still the merge-base JSON under `.deft/intent-constraint/<plan-id>.json` with `humanApproval` (`isHumanApprovalStamp`). Author `plan["x-directive/intentConstraint"]` when `value` / `unit` / `rejectionScope` already exist, before the implementation PR that introduces the facts -- not at record-approved-scope. File-scope can be named at allocation. Throw values usually cannot. Authority read is `git show <merge-base>` only. Same-PR rewrite fails. Multiple merge-base mints require `--plan-id`, `DEFT_ACTIVE_SCOPE`, or dest unique running xBRIEF. Each mint row covers at most one new numeric-const of that value and at most one new throw/reject/abort site. Do not invent a second snapshot or fill speculative value/unit/rejectionScope so a mint succeeds at park. Chat text is never the evaluate input.
14
+ 6. Durable authority is still the merge-base JSON under `.deft/intent-constraint/<plan-id>.json` with `humanApproval` (`isHumanApprovalStamp`). Author `plan["x-directive/intentConstraint"]` when `value` / `unit` / `rejectionScope` already exist, before the implementation PR that introduces the facts -- not at record-approved-scope. File-scope can be named at allocation. Throw values usually cannot. Authority read is `git show <merge-base>` only. Same-PR rewrite fails. Multiple merge-base mints require `--plan-id`, `DEFT_ACTIVE_SCOPE`, dest unique running xBRIEF, or demand-site PR `deft-story: N` adoption (#5782). Each mint row covers at most one new numeric-const of that value and at most one new throw/reject/abort site. Do not invent a second snapshot or fill speculative value/unit/rejectionScope so a mint succeeds at park. Chat text is never the evaluate input.
15
+
16
+ ### PR deft-story plan-id adoption (#5782)
17
+
18
+ On multi-running or multi-mint tips, when plan-id is unresolved, the gate may adopt the running brief `plan.id` owned by a sole distinct `deft-story: N` mark on the PR body (`GITHUB_PR_NUMBER` or `--pr`, plus `GITHUB_REPOSITORY` / `--repo`). Empty or non-digit PR env is no-PR-context (master push / local check keep dest-unique-running). REST null is config/exit 2. Sole means exactly one distinct issue number after dedupe (duplicate identical lines are sole). Unparseable mark values (including plan-id shaped strings) refuse. Explicit `--plan-id` and a valid `DEFT_ACTIVE_SCOPE` still win.
19
+
20
+ A `deft-story: N` mark asserts #4864 delivery bind (`metadata.productPullRequest` must equal this PR before leftover finalize). Satisfying that bind closes the whole story at cohort finalize (stamp path is mark-independent). Only put the mark on the PR that is the delivery for #N. Adoption is a multi-active tiebreak; it does not alter finalize-cohort bind semantics and is not an override of sole-running.
15
21
  7. Collection UX (#5010 / #5574 Prefer-A): classify the condition, not the API name. Expected operational deny → returned-failure / filter (free). Invariant / corruption / impossible-if-healthy → fail-fast throw (or language-equivalent) + attended mint; rewrite solely to clear the gate is forbidden. Attended harness → detect the hard fact and ask the human in the parent chat; on yes the **human** lands the same merge-base record on a real TTY with `mintedVia: in-harness-ask` (attestation is not an agent-shell bypass). Commit that record on the delivery-branch merge base first, then rebase the implementation branch onto it — same-PR working-tree-only records are not authoritative. Unattended / C1 / operator-gone → operational may rewrite or park; invariant requiring a new hard fact must park pending a human mint — do not ask an empty room and do not treat leave-harness TTY `scope:record-intent-constraint` as the primary path. The legacy verb may remain for repair when a human is on a real TTY. Parent-agent auto-approve is out of scope. Agent/CI markers still refuse. Numeric-const and the four `FACT_KINDS` stay on the human decision / park path; a free rewrite introduces none of them. Language-equivalent fail-fast guidance does not imply new panic/assert extraction beyond production TS/JS.
16
22
  8. Site ids are compact statement text, not source offsets. Inserting unrelated text above an existing site does not mint a new fact.
17
23
  9. P2 (literal acceptance preservation) is not this first ship. The verb is not `semantic-*`.
@@ -20,6 +20,7 @@ Accepted product decisions for the launcher + pinned-runtime install model. Docu
20
20
  | **Only package/readiness ignore entries change** | Ignore updates cover `node_modules` and `.deft/directive/wiring-ready.*.json`; `GENERATION.json` stays committed | Broader housekeeping stays where it is |
21
21
  | **Node 20 is best-effort** | Warning on Node 20; gates test 22 and 24 | Broad compatibility without blocking |
22
22
  | **`@deftai/directive` is the launcher** | Adding it locally does not activate a project; meaning changes from “the product” to “the launcher” at the split | Pin `@deftai/directive-runtime` via `directive install` |
23
+ | **FF alone is not tip dogfood** | On the maintainer monorepo, ordinary `task` and hooks stay on the checkout pin; workspace `packages/runtime/dist` is not a silent ordinary-verb fallback (#5805) | Run `task materialize:runtime` in the checkout that should dogfood tip; dest worktrees do not inherit primary materialize |
23
24
  | **Hooks cannot run while their runtime package is absent** | Host may block edits until packages are restored | No fallback to another version; recover with `npm i -g @deftai/directive`, then `directive install --repair` |
24
25
  | **No `--force`** | Conflicts are named and left | Destructive bypass is out of scope |
25
26
  | **Three private packages are not consumable** | `directive-core`, `directive-content`, and `directive-types` are not on npm for external use | Bundled into the runtime; loose ranges were part of the bug |
package/docs/launcher.md CHANGED
@@ -32,6 +32,16 @@ npm i -g @deftai/directive
32
32
  directive install --repair
33
33
  ```
34
34
 
35
+ ## Maintainer dogfood (this repository)
36
+
37
+ On the Directive monorepo, ordinary unprefixed `task <verb>` paths and Git hooks both execute the **checkout pin** at `node_modules/@deftai/directive-runtime/dist/bin.js` (#5805 / AC9.9). Fast-forwarding `master` alone does not run tip source. Tip without a public publish:
38
+
39
+ ```bash
40
+ task materialize:runtime
41
+ ```
42
+
43
+ That stages and packs tip via `packages/runtime/scripts/stage-bundle.mjs` + `pack-staged-runtime.mjs`, then replaces **this checkout's** pin only (no `package.json` / lockfile location-spec rewrite; primary materialize does not update dest worktree pins). CI tip probes that call `packages/runtime/dist/bin.js` directly stay carved out.
44
+
35
45
  ## Related
36
46
 
37
47
  - [Known limitations](./known-limitations.md)
@@ -30,3 +30,9 @@ One remediation: restore the baseline markup structure, or ask in the parent cha
30
30
  The verb is composed on `task check` (`FRAMEWORK_CHECK_GATES`, `CONSUMER_CHECK_GATES`, and required consumer enforcement). Missing, stale, invalid, or changed provider material fails; there is no generic fallback. Dependency delta versus master is two pure parser packages (`parse5` and `entities`). The JSX path trades a bundled pinned parser for one resolved from the consumer project, recorded per artifact and never compared against the mint. Truncated or incomplete HTML is refused (parse5 onParseError into anomalies). jsdom is not a dependency.
31
31
 
32
32
  Three-state exit: `0` skip, warn-findings, or pass / `1` missing mint or unlisted delta / `2` invalid configuration.
33
+
34
+ ### PR deft-story plan-id adoption (#5782)
35
+
36
+ Same demand-site adopter as `verify:intent-constraint`: on multi-running or multi-mint tips with unresolved plan-id, adopt the unique running `plan.id` for a sole distinct `deft-story: N` on the PR body. Explicit `--plan-id` and a valid `DEFT_ACTIVE_SCOPE` win. Empty/non-digit PR env is no-PR-context. When `DEFT_ACTIVE_SCOPE` is set but not a running xBRIEF **and** PR context is present, adoption is suppressed with a named refuse (pass `--plan-id` or clear the pin) — without PR context the tip fall-through is unchanged. REST null is config/exit 2. No YAML planId pre-export.
37
+
38
+ A `deft-story: N` mark asserts #4864 delivery bind and whole-story close at cohort finalize — only use it on the PR that is the delivery for #N. Adoption does not change finalize bind semantics.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deftai/directive-runtime",
3
- "version": "0.126.0-beta.3",
3
+ "version": "0.128.0",
4
4
  "description": "Directive runtime — pinned product commands, hooks, content, and engine.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://deftai.github.io/directive/",