@interf/compiler 0.21.0 → 0.22.2

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 (367) hide show
  1. package/README.md +65 -63
  2. package/dist/cli/commands/build-plan.d.ts +2 -0
  3. package/dist/cli/commands/{method.js → build-plan.js} +89 -72
  4. package/dist/cli/commands/{compile.d.ts → build.d.ts} +2 -2
  5. package/dist/cli/commands/{compile.js → build.js} +18 -18
  6. package/dist/cli/commands/doctor.js +2 -2
  7. package/dist/cli/commands/mcp.js +48 -48
  8. package/dist/cli/commands/prep.js +16 -29
  9. package/dist/cli/commands/reset.d.ts +1 -1
  10. package/dist/cli/commands/reset.js +6 -6
  11. package/dist/cli/commands/runs.js +6 -28
  12. package/dist/cli/commands/status.js +1 -1
  13. package/dist/cli/commands/test.d.ts +1 -1
  14. package/dist/cli/commands/test.js +8 -8
  15. package/dist/cli/commands/web.js +3 -3
  16. package/dist/cli/commands/wizard.js +38 -38
  17. package/dist/cli/index.d.ts +3 -3
  18. package/dist/cli/index.js +5 -5
  19. package/dist/interf-ui/404.html +1 -0
  20. package/dist/interf-ui/__next.__PAGE__.txt +10 -0
  21. package/dist/interf-ui/__next._full.txt +20 -0
  22. package/dist/interf-ui/__next._head.txt +5 -0
  23. package/dist/interf-ui/__next._index.txt +5 -0
  24. package/dist/{compiler-ui → interf-ui}/__next._tree.txt +3 -4
  25. package/dist/interf-ui/_next/static/chunks/0.tjb6f4golw..css +3 -0
  26. package/dist/interf-ui/_next/static/chunks/085-n_jv2ng_q.css +1 -0
  27. package/dist/interf-ui/_next/static/chunks/0dn41fa_zvgsl.js +1 -0
  28. package/dist/interf-ui/_next/static/chunks/0g-ea0zj5d-0k.js +1 -0
  29. package/dist/interf-ui/_next/static/chunks/0gwqglc4iz583.js +1 -0
  30. package/dist/interf-ui/_next/static/chunks/0haldgm65ve6l.js +1 -0
  31. package/dist/interf-ui/_next/static/chunks/0nv3am99vjzn4.js +1 -0
  32. package/dist/{compiler-ui/_next/static/chunks/02f_.8.ebn556.js → interf-ui/_next/static/chunks/0s77gt_o4jwtx.js} +1 -1
  33. package/dist/interf-ui/_next/static/chunks/0~a36ujuzpaz..js +116 -0
  34. package/dist/interf-ui/_next/static/chunks/10jeodxe4nkgj.js +31 -0
  35. package/dist/interf-ui/_next/static/chunks/119h2rouych2t.js +1 -0
  36. package/dist/interf-ui/_next/static/chunks/13c8b~m8knjsf.js +1 -0
  37. package/dist/interf-ui/_next/static/chunks/14dznb2qpt-ho.js +91 -0
  38. package/dist/interf-ui/_next/static/chunks/15z_en80lrq-3.js +5 -0
  39. package/dist/{compiler-ui/_next/static/chunks/turbopack-0apv8vb-nczuy.js → interf-ui/_next/static/chunks/turbopack-0p.pvcjrtq-jh.js} +1 -1
  40. package/dist/interf-ui/_next/static/chunks/turbopack-0usj_75.8frlw.js +1 -0
  41. package/dist/interf-ui/_not-found/__next._full.txt +15 -0
  42. package/dist/interf-ui/_not-found/__next._head.txt +5 -0
  43. package/dist/interf-ui/_not-found/__next._index.txt +5 -0
  44. package/dist/{compiler-ui → interf-ui}/_not-found/__next._not-found.__PAGE__.txt +2 -2
  45. package/dist/interf-ui/_not-found/__next._not-found.txt +5 -0
  46. package/dist/{compiler-ui → interf-ui}/_not-found/__next._tree.txt +2 -3
  47. package/dist/interf-ui/_not-found.html +1 -0
  48. package/dist/interf-ui/_not-found.txt +15 -0
  49. package/dist/interf-ui/index.html +1 -0
  50. package/dist/interf-ui/index.txt +20 -0
  51. package/dist/packages/build-plans/authoring/build-plan-authoring.d.ts +36 -0
  52. package/dist/packages/{methods/authoring/method-authoring.js → build-plans/authoring/build-plan-authoring.js} +52 -52
  53. package/dist/packages/build-plans/authoring/build-plan-edit-session.d.ts +18 -0
  54. package/dist/packages/{methods/authoring/method-edit-session.js → build-plans/authoring/build-plan-edit-session.js} +34 -34
  55. package/dist/packages/build-plans/authoring/build-plan-improvement.d.ts +23 -0
  56. package/dist/packages/build-plans/authoring/build-plan-improvement.js +216 -0
  57. package/dist/packages/build-plans/authoring/index.d.ts +4 -0
  58. package/dist/packages/build-plans/authoring/index.js +4 -0
  59. package/dist/packages/{methods/authoring/lib/method-edit-utils.d.ts → build-plans/authoring/lib/build-plan-edit-utils.d.ts} +3 -3
  60. package/dist/packages/build-plans/build-plan-resolution.d.ts +6 -0
  61. package/dist/packages/build-plans/build-plan-resolution.js +7 -0
  62. package/dist/packages/build-plans/index.d.ts +2 -0
  63. package/dist/packages/build-plans/index.js +2 -0
  64. package/dist/packages/build-plans/package/build-plan-definitions.d.ts +61 -0
  65. package/dist/packages/build-plans/package/build-plan-definitions.js +214 -0
  66. package/dist/packages/{methods/package/method-helpers.d.ts → build-plans/package/build-plan-helpers.d.ts} +7 -7
  67. package/dist/packages/{methods/package/method-helpers.js → build-plans/package/build-plan-helpers.js} +20 -20
  68. package/dist/packages/build-plans/package/build-plan-review-paths.d.ts +10 -0
  69. package/dist/packages/build-plans/package/build-plan-review-paths.js +31 -0
  70. package/dist/packages/{methods/package/method-stage-runner.d.ts → build-plans/package/build-plan-stage-runner.d.ts} +12 -12
  71. package/dist/packages/{methods/package/method-stage-runner.js → build-plans/package/build-plan-stage-runner.js} +10 -10
  72. package/dist/packages/build-plans/package/builtin-build-plan.d.ts +37 -0
  73. package/dist/packages/build-plans/package/builtin-build-plan.js +91 -0
  74. package/dist/packages/{methods → build-plans}/package/context-interface.d.ts +11 -11
  75. package/dist/packages/{methods → build-plans}/package/context-interface.js +23 -23
  76. package/dist/packages/build-plans/package/interf-build-plan-package.d.ts +31 -0
  77. package/dist/packages/build-plans/package/interf-build-plan-package.js +466 -0
  78. package/dist/packages/{methods → build-plans}/package/lib/package-root.js +1 -1
  79. package/dist/packages/build-plans/package/local-build-plans.d.ts +74 -0
  80. package/dist/packages/{methods/package/local-methods.js → build-plans/package/local-build-plans.js} +152 -152
  81. package/dist/packages/build-plans/package/user-build-plans.d.ts +17 -0
  82. package/dist/packages/build-plans/package/user-build-plans.js +77 -0
  83. package/dist/packages/contracts/index.d.ts +1 -1
  84. package/dist/packages/contracts/lib/preparation-paths.d.ts +37 -37
  85. package/dist/packages/contracts/lib/preparation-paths.js +43 -43
  86. package/dist/packages/contracts/lib/schema.d.ts +34 -41
  87. package/dist/packages/contracts/lib/schema.js +42 -34
  88. package/dist/packages/engine/action-definitions.d.ts +60 -60
  89. package/dist/packages/engine/action-definitions.js +198 -197
  90. package/dist/packages/engine/action-planner.d.ts +2 -2
  91. package/dist/packages/engine/action-planner.js +5 -5
  92. package/dist/packages/engine/action-values.d.ts +1 -1
  93. package/dist/packages/engine/action-values.js +1 -1
  94. package/dist/packages/engine/agents/index.d.ts +2 -2
  95. package/dist/packages/engine/agents/index.js +1 -1
  96. package/dist/packages/engine/agents/lib/args.d.ts +2 -2
  97. package/dist/packages/engine/agents/lib/args.js +1 -1
  98. package/dist/packages/engine/agents/lib/constants.js +1 -1
  99. package/dist/packages/engine/agents/lib/execution-profile.d.ts +5 -5
  100. package/dist/packages/engine/agents/lib/execution-profile.js +3 -3
  101. package/dist/packages/engine/agents/lib/executors.d.ts +11 -11
  102. package/dist/packages/engine/agents/lib/render.js +4 -4
  103. package/dist/packages/engine/agents/lib/shells.d.ts +30 -30
  104. package/dist/packages/engine/agents/lib/shells.js +248 -248
  105. package/dist/packages/engine/agents/lib/types.d.ts +2 -2
  106. package/dist/packages/engine/agents/lib/verifiable-context-bootstrap.d.ts +3 -0
  107. package/dist/packages/engine/agents/lib/verifiable-context-bootstrap.js +19 -0
  108. package/dist/packages/engine/agents/role-executors.d.ts +7 -7
  109. package/dist/packages/engine/agents/role-executors.js +2 -2
  110. package/dist/packages/engine/agents/role-router.d.ts +2 -2
  111. package/dist/packages/engine/agents/role-router.js +1 -1
  112. package/dist/packages/engine/build/artifact-counts.d.ts +1 -0
  113. package/dist/packages/engine/{compile → build}/artifact-counts.js +7 -7
  114. package/dist/packages/engine/{compile → build}/artifact-status.d.ts +8 -8
  115. package/dist/packages/engine/{compile → build}/artifact-status.js +19 -19
  116. package/dist/packages/engine/{compile → build}/billing-events.d.ts +4 -4
  117. package/dist/packages/engine/{compile → build}/billing-events.js +4 -4
  118. package/dist/packages/engine/build/build-execution.d.ts +4 -0
  119. package/dist/packages/engine/build/build-execution.js +4 -0
  120. package/dist/packages/engine/build/build-pipeline.d.ts +56 -0
  121. package/dist/packages/engine/{compile/compiled-pipeline.js → build/build-pipeline.js} +55 -55
  122. package/dist/packages/engine/build/build-plan-primitives.d.ts +2 -0
  123. package/dist/packages/engine/{compile/method-primitives.js → build/build-plan-primitives.js} +1 -1
  124. package/dist/packages/engine/build/build-plan-runs.d.ts +14 -0
  125. package/dist/packages/engine/build/build-plan-runs.js +31 -0
  126. package/dist/packages/engine/build/build-stage-plan.d.ts +16 -0
  127. package/dist/packages/engine/build/build-stage-plan.js +100 -0
  128. package/dist/packages/engine/build/build-stage-runner.d.ts +15 -0
  129. package/dist/packages/engine/{compile/compiled-stage-runner.js → build/build-stage-runner.js} +21 -21
  130. package/dist/packages/engine/build/build-target.d.ts +11 -0
  131. package/dist/packages/engine/build/build-target.js +16 -0
  132. package/dist/packages/engine/{compile → build}/check-evaluator.d.ts +4 -4
  133. package/dist/packages/engine/{compile → build}/check-evaluator.js +1 -1
  134. package/dist/packages/engine/{compile → build}/discovery.d.ts +2 -2
  135. package/dist/packages/engine/{compile → build}/discovery.js +4 -4
  136. package/dist/packages/engine/{compile → build}/index.d.ts +6 -6
  137. package/dist/packages/engine/{compile → build}/index.js +5 -5
  138. package/dist/packages/engine/{compile → build}/lib/schema.d.ts +79 -79
  139. package/dist/packages/engine/{compile → build}/lib/schema.js +71 -71
  140. package/dist/packages/engine/build/reset.d.ts +2 -0
  141. package/dist/packages/engine/build/reset.js +74 -0
  142. package/dist/packages/engine/{compile → build}/runtime-contracts.js +8 -8
  143. package/dist/packages/engine/build/runtime-inventory.d.ts +7 -0
  144. package/dist/packages/engine/{compile → build}/runtime-inventory.js +8 -8
  145. package/dist/packages/engine/{compile → build}/runtime-paths.js +6 -6
  146. package/dist/packages/engine/{compile → build}/runtime-prompt.js +11 -11
  147. package/dist/packages/engine/build/runtime-reconcile.d.ts +2 -0
  148. package/dist/packages/engine/{compile → build}/runtime-reconcile.js +18 -18
  149. package/dist/packages/engine/{compile → build}/runtime-runs.js +27 -27
  150. package/dist/packages/engine/{compile → build}/runtime-types.d.ts +10 -10
  151. package/dist/packages/engine/build/source-files.d.ts +46 -0
  152. package/dist/packages/engine/{compile → build}/source-files.js +32 -32
  153. package/dist/packages/engine/build/state-artifacts.d.ts +9 -0
  154. package/dist/packages/engine/build/state-artifacts.js +14 -0
  155. package/dist/packages/engine/build/state-health.d.ts +4 -0
  156. package/dist/packages/engine/{compile → build}/state-health.js +40 -40
  157. package/dist/packages/engine/build/state-io.d.ts +11 -0
  158. package/dist/packages/engine/{compile → build}/state-io.js +22 -22
  159. package/dist/packages/engine/build/state-paths.js +16 -0
  160. package/dist/packages/engine/build/state-view.d.ts +5 -0
  161. package/dist/packages/engine/{compile → build}/state-view.js +29 -29
  162. package/dist/packages/engine/build/state.d.ts +7 -0
  163. package/dist/packages/engine/build/state.js +12 -0
  164. package/dist/packages/engine/build/validate-verifiable-context.d.ts +27 -0
  165. package/dist/packages/engine/{compile/validate-compiled.js → build/validate-verifiable-context.js} +73 -73
  166. package/dist/packages/engine/{compile → build}/validate.d.ts +4 -4
  167. package/dist/packages/engine/{compile → build}/validate.js +27 -27
  168. package/dist/packages/engine/build/verifiable-context-paths.d.ts +47 -0
  169. package/dist/packages/engine/build/verifiable-context-paths.js +121 -0
  170. package/dist/packages/engine/build/verifiable-context-schema.d.ts +21 -0
  171. package/dist/packages/engine/build/verifiable-context-schema.js +126 -0
  172. package/dist/packages/engine/client.d.ts +16 -16
  173. package/dist/packages/engine/client.js +21 -21
  174. package/dist/packages/engine/cloud-seams.d.ts +3 -3
  175. package/dist/packages/engine/execution/index.d.ts +2 -2
  176. package/dist/packages/engine/execution/index.js +1 -1
  177. package/dist/packages/engine/execution/lib/schema.d.ts +90 -95
  178. package/dist/packages/engine/execution/lib/schema.js +31 -31
  179. package/dist/packages/engine/index.d.ts +7 -7
  180. package/dist/packages/engine/index.js +3 -3
  181. package/dist/packages/engine/instance-paths.d.ts +39 -39
  182. package/dist/packages/engine/instance-paths.js +48 -48
  183. package/dist/packages/engine/lib/schema.d.ts +900 -472
  184. package/dist/packages/engine/lib/schema.js +137 -153
  185. package/dist/packages/engine/native-run-handlers.d.ts +12 -12
  186. package/dist/packages/engine/native-run-handlers.js +135 -135
  187. package/dist/packages/engine/preparation-store.d.ts +22 -23
  188. package/dist/packages/engine/preparation-store.js +30 -31
  189. package/dist/packages/engine/readiness-check-draft.d.ts +2 -2
  190. package/dist/packages/engine/readiness-check-draft.js +1 -1
  191. package/dist/packages/engine/requested-artifacts.d.ts +2 -2
  192. package/dist/packages/engine/routes.d.ts +18 -17
  193. package/dist/packages/engine/routes.js +20 -19
  194. package/dist/packages/engine/run-observability.d.ts +5 -3
  195. package/dist/packages/engine/run-observability.js +101 -89
  196. package/dist/packages/engine/runtime-caches.d.ts +16 -16
  197. package/dist/packages/engine/runtime-caches.js +26 -26
  198. package/dist/packages/engine/runtime-event-applier.d.ts +2 -2
  199. package/dist/packages/engine/runtime-event-applier.js +1 -1
  200. package/dist/packages/engine/runtime-persistence.d.ts +9 -9
  201. package/dist/packages/engine/runtime-persistence.js +16 -16
  202. package/dist/packages/engine/runtime-proposal-helpers.d.ts +14 -14
  203. package/dist/packages/engine/runtime-proposal-helpers.js +78 -80
  204. package/dist/packages/engine/runtime-resource-builders.d.ts +12 -12
  205. package/dist/packages/engine/runtime-resource-builders.js +19 -19
  206. package/dist/packages/engine/runtime.d.ts +52 -61
  207. package/dist/packages/engine/runtime.js +440 -463
  208. package/dist/packages/engine/server.d.ts +2 -2
  209. package/dist/packages/engine/server.js +147 -116
  210. package/dist/packages/engine/service-registry.d.ts +5 -17
  211. package/dist/packages/engine/service-registry.js +5 -20
  212. package/dist/packages/engine/verify/lib/schema.d.ts +19 -19
  213. package/dist/packages/engine/verify/lib/schema.js +36 -8
  214. package/dist/packages/engine/verify/readiness-check-run.d.ts +15 -16
  215. package/dist/packages/engine/verify/readiness-check-run.js +46 -46
  216. package/dist/packages/engine/verify/verify-execution.d.ts +3 -3
  217. package/dist/packages/engine/verify/verify-execution.js +10 -10
  218. package/dist/packages/engine/verify/verify-paths.d.ts +4 -4
  219. package/dist/packages/engine/verify/verify-paths.js +17 -17
  220. package/dist/packages/engine/verify/verify-sandbox.d.ts +1 -1
  221. package/dist/packages/engine/verify/verify-sandbox.js +26 -26
  222. package/dist/packages/engine/verify/verify-targets.d.ts +2 -2
  223. package/dist/packages/engine/verify/verify-targets.js +17 -17
  224. package/dist/packages/engine/verify/verify-types.d.ts +2 -2
  225. package/dist/packages/engine/verify/verify.d.ts +1 -1
  226. package/dist/packages/engine/verify/verify.js +1 -1
  227. package/dist/packages/engine/wire-schemas.d.ts +38 -40
  228. package/dist/packages/engine/wire-schemas.js +13 -13
  229. package/dist/packages/project/index.d.ts +1 -1
  230. package/dist/packages/project/interf-bootstrap.d.ts +1 -1
  231. package/dist/packages/project/interf-bootstrap.js +1 -1
  232. package/dist/packages/project/interf-detect.d.ts +11 -11
  233. package/dist/packages/project/interf-detect.js +30 -30
  234. package/dist/packages/project/interf-scaffold.d.ts +3 -3
  235. package/dist/packages/project/interf-scaffold.js +72 -72
  236. package/dist/packages/project/interf.d.ts +4 -4
  237. package/dist/packages/project/interf.js +3 -3
  238. package/dist/packages/project/lib/schema.d.ts +12 -12
  239. package/dist/packages/project/lib/schema.js +14 -14
  240. package/dist/packages/project/preparation-entries.d.ts +3 -3
  241. package/dist/packages/project/preparation-entries.js +19 -19
  242. package/dist/packages/project/source-config.d.ts +10 -10
  243. package/dist/packages/project/source-config.js +58 -58
  244. package/package.json +15 -15
  245. package/public-repo/CONTRIBUTING.md +12 -12
  246. package/public-repo/README.md +65 -63
  247. package/public-repo/SECURITY.md +3 -3
  248. package/public-repo/build-plans/interf-default/README.md +33 -0
  249. package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/shape/SKILL.md +10 -10
  250. package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/structure/SKILL.md +2 -2
  251. package/public-repo/{methods/interf-default/compile → build-plans/interf-default/build}/stages/summarize/SKILL.md +1 -1
  252. package/public-repo/{methods/interf-default/method.json → build-plans/interf-default/build-plan.json} +15 -15
  253. package/public-repo/{methods/interf-default/method.schema.json → build-plans/interf-default/build-plan.schema.json} +4 -4
  254. package/public-repo/build-plans/interf-default/improve/SKILL.md +18 -0
  255. package/public-repo/{methods → build-plans}/interf-default/use/query/SKILL.md +6 -6
  256. package/public-repo/plugins/README.md +1 -1
  257. package/public-repo/plugins/interf/.claude-plugin/plugin.json +3 -3
  258. package/public-repo/plugins/interf/README.md +4 -1
  259. package/public-repo/plugins/interf/skills/interf/SKILL.md +189 -290
  260. package/public-repo/skills/interf/SKILL.md +189 -290
  261. package/LICENSE.md +0 -1
  262. package/TRADEMARKS.md +0 -8
  263. package/dist/cli/commands/method.d.ts +0 -2
  264. package/dist/compiler-ui/404.html +0 -1
  265. package/dist/compiler-ui/__next.__PAGE__.txt +0 -10
  266. package/dist/compiler-ui/__next._full.txt +0 -21
  267. package/dist/compiler-ui/__next._head.txt +0 -5
  268. package/dist/compiler-ui/__next._index.txt +0 -6
  269. package/dist/compiler-ui/_next/static/chunks/01646j7yi.w5a.css +0 -1
  270. package/dist/compiler-ui/_next/static/chunks/02r7siaw-_p5w.js +0 -1
  271. package/dist/compiler-ui/_next/static/chunks/04d0ly-7xb~-j.js +0 -91
  272. package/dist/compiler-ui/_next/static/chunks/0fhs9psnxqd8s.js +0 -1
  273. package/dist/compiler-ui/_next/static/chunks/0mssmhpbifj15.css +0 -2
  274. package/dist/compiler-ui/_next/static/chunks/0nypu~ddwxari.js +0 -116
  275. package/dist/compiler-ui/_next/static/chunks/0p3s8iyhgcww2.js +0 -31
  276. package/dist/compiler-ui/_next/static/chunks/0tjf-vu_rz8s0.css +0 -1
  277. package/dist/compiler-ui/_next/static/chunks/0u6p3fpbbfgtl.js +0 -1
  278. package/dist/compiler-ui/_next/static/chunks/0wpx5..8dnh0w.js +0 -1
  279. package/dist/compiler-ui/_next/static/chunks/0y0uj160p0ts~.js +0 -1
  280. package/dist/compiler-ui/_next/static/chunks/10t8l~_oenf.c.js +0 -1
  281. package/dist/compiler-ui/_next/static/chunks/13gz9e7z~imx1.js +0 -5
  282. package/dist/compiler-ui/_next/static/chunks/156xed-b6czaw.js +0 -1
  283. package/dist/compiler-ui/_next/static/chunks/turbopack-02-3e_c-yz~5g.js +0 -1
  284. package/dist/compiler-ui/_not-found/__next._full.txt +0 -16
  285. package/dist/compiler-ui/_not-found/__next._head.txt +0 -5
  286. package/dist/compiler-ui/_not-found/__next._index.txt +0 -6
  287. package/dist/compiler-ui/_not-found/__next._not-found.txt +0 -5
  288. package/dist/compiler-ui/_not-found.html +0 -1
  289. package/dist/compiler-ui/_not-found.txt +0 -16
  290. package/dist/compiler-ui/index.html +0 -1
  291. package/dist/compiler-ui/index.txt +0 -21
  292. package/dist/packages/engine/agents/lib/compiled-bootstrap.d.ts +0 -3
  293. package/dist/packages/engine/agents/lib/compiled-bootstrap.js +0 -19
  294. package/dist/packages/engine/compile/artifact-counts.d.ts +0 -1
  295. package/dist/packages/engine/compile/compiled-compile.d.ts +0 -4
  296. package/dist/packages/engine/compile/compiled-compile.js +0 -4
  297. package/dist/packages/engine/compile/compiled-paths.d.ts +0 -47
  298. package/dist/packages/engine/compile/compiled-paths.js +0 -121
  299. package/dist/packages/engine/compile/compiled-pipeline.d.ts +0 -56
  300. package/dist/packages/engine/compile/compiled-schema.d.ts +0 -21
  301. package/dist/packages/engine/compile/compiled-schema.js +0 -126
  302. package/dist/packages/engine/compile/compiled-stage-plan.d.ts +0 -16
  303. package/dist/packages/engine/compile/compiled-stage-plan.js +0 -100
  304. package/dist/packages/engine/compile/compiled-stage-runner.d.ts +0 -15
  305. package/dist/packages/engine/compile/compiled-target.d.ts +0 -11
  306. package/dist/packages/engine/compile/compiled-target.js +0 -16
  307. package/dist/packages/engine/compile/method-primitives.d.ts +0 -2
  308. package/dist/packages/engine/compile/method-runs.d.ts +0 -14
  309. package/dist/packages/engine/compile/method-runs.js +0 -31
  310. package/dist/packages/engine/compile/reset.d.ts +0 -2
  311. package/dist/packages/engine/compile/reset.js +0 -74
  312. package/dist/packages/engine/compile/runtime-inventory.d.ts +0 -7
  313. package/dist/packages/engine/compile/runtime-reconcile.d.ts +0 -2
  314. package/dist/packages/engine/compile/source-files.d.ts +0 -46
  315. package/dist/packages/engine/compile/state-artifacts.d.ts +0 -9
  316. package/dist/packages/engine/compile/state-artifacts.js +0 -14
  317. package/dist/packages/engine/compile/state-health.d.ts +0 -4
  318. package/dist/packages/engine/compile/state-io.d.ts +0 -11
  319. package/dist/packages/engine/compile/state-paths.js +0 -16
  320. package/dist/packages/engine/compile/state-view.d.ts +0 -5
  321. package/dist/packages/engine/compile/state.d.ts +0 -7
  322. package/dist/packages/engine/compile/state.js +0 -12
  323. package/dist/packages/engine/compile/validate-compiled.d.ts +0 -27
  324. package/dist/packages/methods/authoring/index.d.ts +0 -4
  325. package/dist/packages/methods/authoring/index.js +0 -4
  326. package/dist/packages/methods/authoring/method-authoring.d.ts +0 -36
  327. package/dist/packages/methods/authoring/method-edit-session.d.ts +0 -18
  328. package/dist/packages/methods/authoring/method-improvement.d.ts +0 -23
  329. package/dist/packages/methods/authoring/method-improvement.js +0 -217
  330. package/dist/packages/methods/index.d.ts +0 -2
  331. package/dist/packages/methods/index.js +0 -2
  332. package/dist/packages/methods/method-resolution.d.ts +0 -6
  333. package/dist/packages/methods/method-resolution.js +0 -7
  334. package/dist/packages/methods/package/builtin-compiled-method.d.ts +0 -37
  335. package/dist/packages/methods/package/builtin-compiled-method.js +0 -91
  336. package/dist/packages/methods/package/interf-method-package.d.ts +0 -31
  337. package/dist/packages/methods/package/interf-method-package.js +0 -466
  338. package/dist/packages/methods/package/local-methods.d.ts +0 -74
  339. package/dist/packages/methods/package/method-definitions.d.ts +0 -61
  340. package/dist/packages/methods/package/method-definitions.js +0 -214
  341. package/dist/packages/methods/package/method-review-paths.d.ts +0 -10
  342. package/dist/packages/methods/package/method-review-paths.js +0 -31
  343. package/dist/packages/methods/package/user-methods.d.ts +0 -17
  344. package/dist/packages/methods/package/user-methods.js +0 -77
  345. package/public-repo/methods/interf-default/README.md +0 -33
  346. package/public-repo/methods/interf-default/improve/SKILL.md +0 -18
  347. /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_buildManifest.js +0 -0
  348. /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_clientMiddlewareManifest.js +0 -0
  349. /package/dist/{compiler-ui/_next/static/tYHMLL9oKds1yDoNYgkPV → interf-ui/_next/static/--reS3xBzM5zc6QxNjZd6}/_ssgManifest.js +0 -0
  350. /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/03~yq9q893hmn.js +0 -0
  351. /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/0y5z3t-z1c8ks.js.map +0 -0
  352. /package/dist/{compiler-ui → interf-ui}/_next/static/chunks/turbopack-worker-0sjn--fhq~1cg.js +0 -0
  353. /package/dist/{compiler-ui → interf-ui}/_next/static/media/GeistMono_Variable.p.17jn9btb_52pq.woff2 +0 -0
  354. /package/dist/{compiler-ui → interf-ui}/_next/static/media/Geist_Variable-s.p.0-te~ja_gpvcf.woff2 +0 -0
  355. /package/dist/{compiler-ui → interf-ui}/_next/static/media/worker.102zas1s52_pf.js +0 -0
  356. /package/dist/packages/{methods/authoring/lib/method-edit-utils.js → build-plans/authoring/lib/build-plan-edit-utils.js} +0 -0
  357. /package/dist/packages/{methods → build-plans}/package/lib/package-root.d.ts +0 -0
  358. /package/dist/packages/engine/{compile → build}/runtime-contracts.d.ts +0 -0
  359. /package/dist/packages/engine/{compile → build}/runtime-paths.d.ts +0 -0
  360. /package/dist/packages/engine/{compile → build}/runtime-prompt.d.ts +0 -0
  361. /package/dist/packages/engine/{compile → build}/runtime-runs.d.ts +0 -0
  362. /package/dist/packages/engine/{compile → build}/runtime-types.js +0 -0
  363. /package/dist/packages/engine/{compile → build}/runtime.d.ts +0 -0
  364. /package/dist/packages/engine/{compile → build}/runtime.js +0 -0
  365. /package/dist/packages/engine/{compile → build}/state-paths.d.ts +0 -0
  366. /package/dist/packages/engine/{compile → build}/validate-helpers.d.ts +0 -0
  367. /package/dist/packages/engine/{compile → build}/validate-helpers.js +0 -0
@@ -1,4 +1,4 @@
1
- import type { MethodExecutionProfile } from "./executors.js";
1
+ import type { AgentExecutionProfile } from "./executors.js";
2
2
  export interface Agent {
3
3
  name: string;
4
4
  displayName: string;
@@ -25,7 +25,7 @@ export interface AgentAutomationReadiness {
25
25
  export interface SpawnAgentOptions {
26
26
  eventLogPath?: string | null;
27
27
  statusLogPath?: string | null;
28
- executionProfile?: MethodExecutionProfile;
28
+ executionProfile?: AgentExecutionProfile;
29
29
  completionCheck?: (() => boolean) | null;
30
30
  onStatus?: (line: string) => void;
31
31
  }
@@ -0,0 +1,3 @@
1
+ import { renderClaudeBootstrap } from "./shells.js";
2
+ export { renderClaudeBootstrap };
3
+ export declare function refreshVerifiableContextBootstrapGuidance(dirPath: string): boolean;
@@ -0,0 +1,19 @@
1
+ import { basename } from "node:path";
2
+ import { readInterfConfig } from "../../../project/interf-detect.js";
3
+ import { resolveBuildPlanId } from "../../../build-plans/build-plan-resolution.js";
4
+ import { projectVerifiableContextQueryShell, renderClaudeBootstrap } from "./shells.js";
5
+ export { renderClaudeBootstrap };
6
+ export function refreshVerifiableContextBootstrapGuidance(dirPath) {
7
+ const config = readInterfConfig(dirPath);
8
+ if (!config)
9
+ return false;
10
+ const verifiableContextName = config.name ?? basename(dirPath);
11
+ const buildPlanId = resolveBuildPlanId(config);
12
+ const buildPlanOriginSelected = config.build_plan_origin?.selected ?? buildPlanId;
13
+ const buildPlanLocalDraft = config.build_plan_origin?.local_draft === true;
14
+ const about = typeof config.about === "string" && config.about.length > 0 ? config.about : undefined;
15
+ return projectVerifiableContextQueryShell(dirPath, verifiableContextName, buildPlanId, about, {
16
+ buildPlanOriginSelected,
17
+ buildPlanLocalDraft,
18
+ });
19
+ }
@@ -1,11 +1,11 @@
1
1
  import type { AgentRecord, RoleMap } from "../../contracts/lib/schema.js";
2
- import type { MethodExecutionProfile, MethodExecutor } from "./lib/executors.js";
2
+ import type { AgentExecutionProfile, AgentExecutor } from "./lib/executors.js";
3
3
  import { type ResolvedAgent, type RoleResolutionContext } from "./role-router.js";
4
4
  export interface RoleExecutorBundle {
5
- /** Map agent name method executor. */
6
- executors: Map<string, MethodExecutor>;
5
+ /** Map agent name to Build Plan executor. */
6
+ executors: Map<string, AgentExecutor>;
7
7
  /** Default fallback executor — usually the active agent. */
8
- defaultExecutor: MethodExecutor;
8
+ defaultExecutor: AgentExecutor;
9
9
  /** The registry context we built this bundle from. */
10
10
  context: RoleResolutionContext;
11
11
  /**
@@ -13,7 +13,7 @@ export interface RoleExecutorBundle {
13
13
  * through `general` and the default executor before raising.
14
14
  */
15
15
  resolveExecutorForRole(role: string): {
16
- executor: MethodExecutor;
16
+ executor: AgentExecutor;
17
17
  resolved: ResolvedAgent;
18
18
  };
19
19
  }
@@ -23,8 +23,8 @@ export interface BuildRoleExecutorBundleInput {
23
23
  /** The agent the role-map's `general` row points at, or fallback. */
24
24
  activeAgent: AgentRecord | null;
25
25
  /** The fallback executor — used when role resolution yields the active. */
26
- defaultExecutor: MethodExecutor;
27
- executionProfile?: MethodExecutionProfile;
26
+ defaultExecutor: AgentExecutor;
27
+ executionProfile?: AgentExecutionProfile;
28
28
  }
29
29
  /**
30
30
  * Build a per-role executor bundle from a registry snapshot. The
@@ -2,9 +2,9 @@
2
2
  * Role-aware executor factory.
3
3
  *
4
4
  * Bridges the registry layer (`AgentRecord` / `RoleMap`) to the runtime
5
- * layer (`MethodExecutor`). Builds a per-agent-name `MethodExecutor`
5
+ * layer (`AgentExecutor`). Builds a per-agent-name `AgentExecutor`
6
6
  * map up front and exposes a `resolveExecutorForRole(role)` helper that
7
- * the compile / readiness-check pipelines can call per-stage.
7
+ * the build / readiness-check pipelines can call per-stage.
8
8
  *
9
9
  * Falls back gracefully: when a role isn't mapped, or the mapped agent
10
10
  * is missing, we fall through to `general` and ultimately to the
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Role router — picks which connected agent runs a given stage role.
3
3
  *
4
- * The compile pipeline calls `resolveAgentForRole` for each agent-typed
4
+ * The build pipeline calls `resolveAgentForRole` for each agent-typed
5
5
  * stage, passing the stage's declared role and the current registry +
6
6
  * active agent. The verify pipeline always passes role `"verifier"`.
7
7
  *
@@ -48,7 +48,7 @@ export type RoleResolutionError = {
48
48
  */
49
49
  export declare function resolveAgentForRole(role: string, context: RoleResolutionContext): ResolvedAgent | RoleResolutionError;
50
50
  /**
51
- * Resolve every role declared by a Method's stages. Useful for
51
+ * Resolve every role declared by a Build Plan's stages. Useful for
52
52
  * pre-flight: returns either `{ resolutions }` (one entry per stage)
53
53
  * or `{ error, role }` if any stage cannot resolve.
54
54
  */
@@ -56,7 +56,7 @@ export function resolveAgentForRole(role, context) {
56
56
  };
57
57
  }
58
58
  /**
59
- * Resolve every role declared by a Method's stages. Useful for
59
+ * Resolve every role declared by a Build Plan's stages. Useful for
60
60
  * pre-flight: returns either `{ resolutions }` (one entry per stage)
61
61
  * or `{ error, role }` if any stage cannot resolve.
62
62
  */
@@ -0,0 +1 @@
1
+ export declare function countBuildArtifactsAtPath(verifiableContextPath: string, artifactPath: string, kind: "directory" | "file" | "runtime"): number;
@@ -1,11 +1,11 @@
1
1
  import { existsSync, readFileSync } from "node:fs";
2
2
  import { listFilesRecursive } from "../../contracts/utils/filesystem.js";
3
- import { compiledArtifactAbsolutePath } from "./compiled-schema.js";
3
+ import { verifiableContextArtifactAbsolutePath } from "./verifiable-context-schema.js";
4
4
  const SCAFFOLD_PLACEHOLDER_SNIPPETS = [
5
- "Not yet compiled. Run `interf compile` to build the portable context.",
6
- "Not yet compiled. Run `interf compile` to build this portable context.",
7
- "Not yet compiled. Run `interf compile` to build the portable context.",
8
- "Not yet compiled. Run `interf compile` to build this portable context.",
5
+ "Not yet built. Run `interf build` to build the verifiable context.",
6
+ "Not yet built. Run `interf build` to build this verifiable context.",
7
+ "Not yet built. Run `interf build` to build the verifiable context.",
8
+ "Not yet built. Run `interf build` to build this verifiable context.",
9
9
  ];
10
10
  function isScaffoldPlaceholderFile(filePath) {
11
11
  try {
@@ -16,8 +16,8 @@ function isScaffoldPlaceholderFile(filePath) {
16
16
  return false;
17
17
  }
18
18
  }
19
- export function countCompiledArtifactsAtPath(compiledPath, artifactPath, kind) {
20
- const absolutePath = compiledArtifactAbsolutePath(compiledPath, { path: artifactPath });
19
+ export function countBuildArtifactsAtPath(verifiableContextPath, artifactPath, kind) {
20
+ const absolutePath = verifiableContextArtifactAbsolutePath(verifiableContextPath, { path: artifactPath });
21
21
  if (!existsSync(absolutePath))
22
22
  return 0;
23
23
  if (kind === "file")
@@ -1,18 +1,18 @@
1
1
  import type { ArtifactStatus } from "../../contracts/lib/schema.js";
2
- import type { MethodDefinition } from "../../methods/package/method-definitions.js";
2
+ import type { BuildPlanDefinition } from "../../build-plans/package/build-plan-definitions.js";
3
3
  import type { StageRun } from "../execution/lib/schema.js";
4
4
  /**
5
- * 0.17 — compute per-Artifact status for a compile run.
5
+ * 0.17 — compute per-Artifact status for a Build run.
6
6
  *
7
- * Walks the Method's declared `artifacts[]` and decides
7
+ * Walks the Build Plan's declared `artifacts[]` and decides
8
8
  * `ready | not_ready | failed | skipped` for each.
9
9
  *
10
10
  * Mapping rules:
11
11
  * - **shape kind = "path"**: the artifact is `ready` when the declared
12
- * path exists inside `compiledPath` with the declared artifact kind,
12
+ * path exists inside `verifiableContextPath` with the declared artifact kind,
13
13
  * `not_ready` otherwise. Future shape kinds (value, remote-handle,
14
14
  * confirmation) slot in here.
15
- * - **`built_by_stages`** is preserved from the Method declaration when
15
+ * - **`built_by_stages`** is preserved from the Build Plan declaration when
16
16
  * present, otherwise inferred from stage `writes` that match the
17
17
  * artifact's path.
18
18
  * - **proofs** carries structured evidence from the shared check
@@ -23,12 +23,12 @@ import type { StageRun } from "../execution/lib/schema.js";
23
23
  * the run record carries the real causal signal.
24
24
  */
25
25
  export declare function computeArtifactStatuses(options: {
26
- method: Pick<MethodDefinition<string>, "stages" | "contextInterface" | "schema">;
27
- compiledPath: string;
26
+ buildPlan: Pick<BuildPlanDefinition<string>, "stages" | "contextInterface" | "schema">;
27
+ verifiableContextPath: string;
28
28
  stageRuns: StageRun[];
29
29
  /**
30
30
  * Optional runtime counts (e.g. `source_total`) passed to checks
31
- * that compare against source. Threaded through from the compile
31
+ * that compare against source. Threaded through from the build
32
32
  * runtime; absent for ad-hoc evaluations.
33
33
  */
34
34
  counts?: Record<string, number>;
@@ -2,17 +2,17 @@ import { existsSync, statSync } from "node:fs";
2
2
  import { resolve } from "node:path";
3
3
  import { evaluateChecks } from "./check-evaluator.js";
4
4
  /**
5
- * 0.17 — compute per-Artifact status for a compile run.
5
+ * 0.17 — compute per-Artifact status for a Build run.
6
6
  *
7
- * Walks the Method's declared `artifacts[]` and decides
7
+ * Walks the Build Plan's declared `artifacts[]` and decides
8
8
  * `ready | not_ready | failed | skipped` for each.
9
9
  *
10
10
  * Mapping rules:
11
11
  * - **shape kind = "path"**: the artifact is `ready` when the declared
12
- * path exists inside `compiledPath` with the declared artifact kind,
12
+ * path exists inside `verifiableContextPath` with the declared artifact kind,
13
13
  * `not_ready` otherwise. Future shape kinds (value, remote-handle,
14
14
  * confirmation) slot in here.
15
- * - **`built_by_stages`** is preserved from the Method declaration when
15
+ * - **`built_by_stages`** is preserved from the Build Plan declaration when
16
16
  * present, otherwise inferred from stage `writes` that match the
17
17
  * artifact's path.
18
18
  * - **proofs** carries structured evidence from the shared check
@@ -23,22 +23,22 @@ import { evaluateChecks } from "./check-evaluator.js";
23
23
  * the run record carries the real causal signal.
24
24
  */
25
25
  export function computeArtifactStatuses(options) {
26
- const schema = pickContextInterface(options.method);
26
+ const schema = pickContextInterface(options.buildPlan);
27
27
  const artifacts = schema?.artifacts ?? [];
28
28
  if (artifacts.length === 0)
29
29
  return [];
30
- const stageWriteIndex = buildStageWriteIndex(options.method.stages);
30
+ const stageWriteIndex = buildStageWriteIndex(options.buildPlan.stages);
31
31
  const anyStageFailed = options.stageRuns.some((stage) => stage.status === "failed");
32
32
  return artifacts.map((artifact) => buildArtifactStatus({
33
33
  artifact,
34
- compiledPath: options.compiledPath,
34
+ verifiableContextPath: options.verifiableContextPath,
35
35
  stageWriteIndex,
36
36
  anyStageFailed,
37
37
  counts: options.counts,
38
38
  }));
39
39
  }
40
- function pickContextInterface(method) {
41
- return method.contextInterface ?? method.schema;
40
+ function pickContextInterface(buildPlan) {
41
+ return buildPlan.contextInterface ?? buildPlan.schema;
42
42
  }
43
43
  function buildStageWriteIndex(stages) {
44
44
  const index = new Map();
@@ -53,13 +53,13 @@ function buildStageWriteIndex(stages) {
53
53
  return index;
54
54
  }
55
55
  function buildArtifactStatus(options) {
56
- const { artifact, compiledPath, stageWriteIndex, anyStageFailed, counts } = options;
56
+ const { artifact, verifiableContextPath, stageWriteIndex, anyStageFailed, counts } = options;
57
57
  const builtBy = artifact.built_by_stages.length > 0
58
58
  ? artifact.built_by_stages
59
59
  : inferBuiltByStages(artifact, stageWriteIndex);
60
60
  const shapeStatus = resolveStatusValue({
61
61
  artifact,
62
- compiledPath,
62
+ verifiableContextPath,
63
63
  anyStageFailed,
64
64
  });
65
65
  // Run the locked CheckKind evaluator against artifact.checks. Proofs
@@ -68,12 +68,12 @@ function buildArtifactStatus(options) {
68
68
  // shape itself isn't built yet).
69
69
  const targetPath = artifact.shape.kind === "path" ? artifact.shape.path : undefined;
70
70
  // `artifact.checks` is `default([])` in the schema, but raw objects
71
- // (test fixtures, hand-edited Methods loaded without parsing) may
71
+ // (test fixtures, hand-edited Build Plans loaded without parsing) may
72
72
  // omit the field entirely.
73
73
  const declaredChecks = artifact.checks ?? [];
74
74
  const checkResult = declaredChecks.length > 0
75
75
  ? evaluateChecks(declaredChecks, {
76
- rootPath: compiledPath,
76
+ rootPath: verifiableContextPath,
77
77
  targetPath,
78
78
  counts,
79
79
  })
@@ -116,17 +116,17 @@ function inferBuiltByStages(artifact, stageWriteIndex) {
116
116
  return pathOwners ?? [];
117
117
  }
118
118
  function resolveStatusValue(options) {
119
- const { artifact, compiledPath, anyStageFailed } = options;
119
+ const { artifact, verifiableContextPath, anyStageFailed } = options;
120
120
  if (artifact.shape.kind !== "path")
121
121
  return "skipped";
122
- const compiledRoot = resolve(compiledPath);
123
- const absolutePath = resolve(compiledRoot, artifact.shape.path);
122
+ const verifiableContextRoot = resolve(verifiableContextPath);
123
+ const absolutePath = resolve(verifiableContextRoot, artifact.shape.path);
124
124
  // Defense in depth: the schema-level `isInterfRelativePath` refine
125
125
  // already rejects `..` and absolute paths in `ArtifactPathShape.path`,
126
- // but Method packages can land on disk before the schema validates
126
+ // but Build Plan packages can land on disk before the schema validates
127
127
  // (hand-edited drafts can still bypass normal package validation).
128
- // Reject any resolved path that escapes the portable-context root.
129
- if (absolutePath !== compiledRoot && !absolutePath.startsWith(`${compiledRoot}/`)) {
128
+ // Reject any resolved path that escapes the verifiable-context root.
129
+ if (absolutePath !== verifiableContextRoot && !absolutePath.startsWith(`${verifiableContextRoot}/`)) {
130
130
  return "failed";
131
131
  }
132
132
  if (!existsSync(absolutePath)) {
@@ -3,7 +3,7 @@ import type { ArtifactStatus } from "../../contracts/lib/schema.js";
3
3
  /**
4
4
  * 0.17 — per-Artifact billing event record.
5
5
  *
6
- * Emitted once per Artifact each time a compile run produces it.
6
+ * Emitted once per Artifact each time a Build run produces it.
7
7
  * `account_id` is `null` for loopback (no auth); the cloud variant
8
8
  * fills it from the `tokenValidator` (B4.3) result.
9
9
  *
@@ -22,7 +22,7 @@ export declare const CompilationEventSchema: z.ZodObject<{
22
22
  run_id: z.ZodString;
23
23
  preparation: z.ZodString;
24
24
  artifact_id: z.ZodString;
25
- method_id: z.ZodString;
25
+ build_plan_id: z.ZodString;
26
26
  account_id: z.ZodNullable<z.ZodString>;
27
27
  event_kind: z.ZodEnum<{
28
28
  fresh: "fresh";
@@ -61,7 +61,7 @@ export declare class JsonlBillingEventSink implements BillingEventSink {
61
61
  emit(event: CompilationEvent): void;
62
62
  }
63
63
  /**
64
- * Default sink path for a run. Each compile run gets its own JSONL
64
+ * Default sink path for a run. Each Build run gets its own JSONL
65
65
  * file alongside its other on-disk artifacts.
66
66
  */
67
67
  export declare function defaultBillingEventLogPath(options: {
@@ -80,7 +80,7 @@ export declare function defaultBillingEventLogPath(options: {
80
80
  export declare function buildCompilationEventsForRun(options: {
81
81
  runId: string;
82
82
  preparation: string;
83
- methodId: string;
83
+ buildPlanId: string;
84
84
  accountId: string | null;
85
85
  artifacts: readonly ArtifactStatus[];
86
86
  startedAt?: string | null;
@@ -4,7 +4,7 @@ import { z } from "zod";
4
4
  /**
5
5
  * 0.17 — per-Artifact billing event record.
6
6
  *
7
- * Emitted once per Artifact each time a compile run produces it.
7
+ * Emitted once per Artifact each time a Build run produces it.
8
8
  * `account_id` is `null` for loopback (no auth); the cloud variant
9
9
  * fills it from the `tokenValidator` (B4.3) result.
10
10
  *
@@ -20,7 +20,7 @@ export const CompilationEventSchema = z.object({
20
20
  run_id: z.string().min(1),
21
21
  preparation: z.string().min(1),
22
22
  artifact_id: z.string().min(1),
23
- method_id: z.string().min(1),
23
+ build_plan_id: z.string().min(1),
24
24
  account_id: z.string().min(1).nullable(),
25
25
  event_kind: BillingEventKindSchema,
26
26
  size_class: z.enum(["small", "medium", "large"]).optional(),
@@ -38,7 +38,7 @@ export class JsonlBillingEventSink {
38
38
  }
39
39
  }
40
40
  /**
41
- * Default sink path for a run. Each compile run gets its own JSONL
41
+ * Default sink path for a run. Each Build run gets its own JSONL
42
42
  * file alongside its other on-disk artifacts.
43
43
  */
44
44
  export function defaultBillingEventLogPath(options) {
@@ -66,7 +66,7 @@ export function buildCompilationEventsForRun(options) {
66
66
  run_id: options.runId,
67
67
  preparation: options.preparation,
68
68
  artifact_id: status.artifact_id,
69
- method_id: options.methodId,
69
+ build_plan_id: options.buildPlanId,
70
70
  account_id: options.accountId,
71
71
  event_kind: "fresh",
72
72
  ...(durationMs !== undefined ? { duration_ms: durationMs } : {}),
@@ -0,0 +1,4 @@
1
+ export * from "./build-target.js";
2
+ export * from "./build-stage-plan.js";
3
+ export * from "./build-stage-runner.js";
4
+ export * from "./build-pipeline.js";
@@ -0,0 +1,4 @@
1
+ export * from "./build-target.js";
2
+ export * from "./build-stage-plan.js";
3
+ export * from "./build-stage-runner.js";
4
+ export * from "./build-pipeline.js";
@@ -0,0 +1,56 @@
1
+ import { type AgentExecutor } from "../agents/lib/executors.js";
2
+ import { type BuildPlanReporter, type BuildPlanStageResult } from "../../build-plans/package/build-plan-helpers.js";
3
+ import { type BuildStageExecutionDefinition } from "./build-target.js";
4
+ import type { RunEventSink } from "../execution/events.js";
5
+ export interface BuildSummarizeResult extends BuildPlanStageResult {
6
+ plan: {
7
+ sourceCount: number;
8
+ summaryCount: number;
9
+ targetCount: number;
10
+ };
11
+ }
12
+ export interface BuildResult {
13
+ ok: boolean;
14
+ stageResults: Record<string, BuildPlanStageResult>;
15
+ failedStage: string | null;
16
+ }
17
+ export type StageShellRetentionMode = "on-failure" | "always";
18
+ /**
19
+ * Per-stage executor resolver. When provided, the pipeline calls this
20
+ * for each stage and uses the returned executor instead of the
21
+ * top-level `executor`. The top-level `executor` stays as the default
22
+ * fallback so single-active-agent setups keep working without any
23
+ * resolver wired up.
24
+ */
25
+ export type ResolveStageExecutor = (stage: BuildStageExecutionDefinition) => AgentExecutor;
26
+ export declare function runBuildSummarize(options: {
27
+ executor: AgentExecutor;
28
+ resolveStageExecutor?: ResolveStageExecutor;
29
+ verifiableContextPath: string;
30
+ reporter?: BuildPlanReporter;
31
+ reportSummary?: boolean;
32
+ reportStep?: boolean;
33
+ stageDefinition?: BuildStageExecutionDefinition;
34
+ fullPass?: boolean;
35
+ runId?: string;
36
+ events?: RunEventSink;
37
+ }): Promise<BuildSummarizeResult>;
38
+ export declare function runBuildStages(options: {
39
+ executor: AgentExecutor;
40
+ resolveStageExecutor?: ResolveStageExecutor;
41
+ verifiableContextPath: string;
42
+ reporter?: BuildPlanReporter;
43
+ reportStep?: boolean;
44
+ preserveStageShells?: StageShellRetentionMode;
45
+ runId?: string;
46
+ events?: RunEventSink;
47
+ }): Promise<BuildPlanStageResult>;
48
+ export declare function buildVerifiableContext(options: {
49
+ executor: AgentExecutor;
50
+ resolveStageExecutor?: ResolveStageExecutor;
51
+ verifiableContextPath: string;
52
+ reporter?: BuildPlanReporter;
53
+ preserveStageShells?: StageShellRetentionMode;
54
+ runId?: string;
55
+ events?: RunEventSink;
56
+ }): Promise<BuildResult>;
@@ -1,15 +1,15 @@
1
- import { refreshCompiledBootstrapGuidance, } from "../agents/lib/compiled-bootstrap.js";
2
- import { validateMethodPackage } from "../../methods/package/local-methods.js";
3
- import { reportValidationFailure, } from "../../methods/package/method-helpers.js";
4
- import { validateCompiledMethod, } from "./validate.js";
1
+ import { refreshVerifiableContextBootstrapGuidance, } from "../agents/lib/verifiable-context-bootstrap.js";
2
+ import { validateBuildPlanPackage } from "../../build-plans/package/local-build-plans.js";
3
+ import { reportValidationFailure, } from "../../build-plans/package/build-plan-helpers.js";
4
+ import { validateVerifiableContext, } from "./validate.js";
5
5
  import { pruneStageExecutionShells, } from "../agents/lib/shells.js";
6
- import { resetCompiledGeneratedState } from "./reset.js";
7
- import { compiledExecutionStages, resolveCompiledContext, } from "./compiled-target.js";
6
+ import { resetBuildGeneratedState } from "./reset.js";
7
+ import { buildExecutionStages, resolveBuildContext, } from "./build-target.js";
8
8
  import { discoverSourceFiles } from "./discovery.js";
9
- import { runCompiledStage } from "./compiled-stage-runner.js";
9
+ import { runBuildStage } from "./build-stage-runner.js";
10
10
  import { resolveSourceInputPath } from "../../project/interf-detect.js";
11
- import { methodPackagePathForCompiled } from "./compiled-paths.js";
12
- import { writeCompiledSourceRuntime } from "./source-files.js";
11
+ import { buildPlanPackagePathForVerifiableContext } from "./verifiable-context-paths.js";
12
+ import { writeBuildSourceRuntime } from "./source-files.js";
13
13
  function pickStageExecutor(fallback, stage, resolve) {
14
14
  if (!resolve)
15
15
  return fallback;
@@ -20,29 +20,29 @@ function pickStageExecutor(fallback, stage, resolve) {
20
20
  return fallback;
21
21
  }
22
22
  }
23
- export async function runCompiledSummarize(options) {
24
- const context = resolveCompiledContext(options.compiledPath);
23
+ export async function runBuildSummarize(options) {
24
+ const context = resolveBuildContext(options.verifiableContextPath);
25
25
  const stageDefinition = options.stageDefinition
26
- ?? compiledExecutionStages(context.methodId, options.compiledPath).find((stage) => stage.id === "summarize");
26
+ ?? buildExecutionStages(context.buildPlanId, options.verifiableContextPath).find((stage) => stage.id === "summarize");
27
27
  if (!stageDefinition) {
28
28
  return {
29
29
  ok: false,
30
30
  code: 1,
31
31
  plan: { sourceCount: 0, summaryCount: 0, targetCount: 0 },
32
- summary: "Method does not declare a summarize stage.",
32
+ summary: "Build Plan does not declare a summarize stage.",
33
33
  };
34
34
  }
35
- const sourceCount = discoverSourceFiles(context.sourcePath, options.compiledPath).totalCount;
36
- writeCompiledSourceRuntime({
37
- compiledPath: options.compiledPath,
38
- methodId: context.methodId,
35
+ const sourceCount = discoverSourceFiles(context.sourcePath, options.verifiableContextPath).totalCount;
36
+ writeBuildSourceRuntime({
37
+ verifiableContextPath: options.verifiableContextPath,
38
+ buildPlanId: context.buildPlanId,
39
39
  stageIds: [stageDefinition.id],
40
40
  sourcePath: context.sourcePath,
41
41
  runId: options.runId ?? null,
42
42
  });
43
- const result = await runCompiledStage({
43
+ const result = await runBuildStage({
44
44
  executor: pickStageExecutor(options.executor, stageDefinition, options.resolveStageExecutor),
45
- compiledPath: options.compiledPath,
45
+ verifiableContextPath: options.verifiableContextPath,
46
46
  reporter: options.reporter,
47
47
  reportStep: options.reportStep,
48
48
  stageDefinition,
@@ -58,26 +58,26 @@ export async function runCompiledSummarize(options) {
58
58
  },
59
59
  };
60
60
  }
61
- export async function runCompiledCompile(options) {
61
+ export async function runBuildStages(options) {
62
62
  const preserveMode = options.preserveStageShells ?? "on-failure";
63
63
  if (preserveMode !== "always") {
64
- pruneStageExecutionShells(options.compiledPath);
64
+ pruneStageExecutionShells(options.verifiableContextPath);
65
65
  }
66
66
  let lastResult = { ok: true, code: 0 };
67
67
  try {
68
- const context = resolveCompiledContext(options.compiledPath);
69
- const stages = compiledExecutionStages(context.methodId, options.compiledPath);
70
- writeCompiledSourceRuntime({
71
- compiledPath: options.compiledPath,
72
- methodId: context.methodId,
68
+ const context = resolveBuildContext(options.verifiableContextPath);
69
+ const stages = buildExecutionStages(context.buildPlanId, options.verifiableContextPath);
70
+ writeBuildSourceRuntime({
71
+ verifiableContextPath: options.verifiableContextPath,
72
+ buildPlanId: context.buildPlanId,
73
73
  stageIds: stages.map((stage) => stage.id),
74
74
  sourcePath: context.sourcePath,
75
75
  runId: options.runId ?? null,
76
76
  });
77
77
  for (const [index, stageDefinition] of stages.entries()) {
78
- const result = await runCompiledStage({
78
+ const result = await runBuildStage({
79
79
  executor: pickStageExecutor(options.executor, stageDefinition, options.resolveStageExecutor),
80
- compiledPath: options.compiledPath,
80
+ verifiableContextPath: options.verifiableContextPath,
81
81
  reporter: options.reporter,
82
82
  reportStep: options.reportStep,
83
83
  stageDefinition,
@@ -94,15 +94,15 @@ export async function runCompiledCompile(options) {
94
94
  }
95
95
  finally {
96
96
  if (preserveMode !== "always" && lastResult.ok) {
97
- pruneStageExecutionShells(options.compiledPath);
97
+ pruneStageExecutionShells(options.verifiableContextPath);
98
98
  }
99
99
  }
100
100
  }
101
- export async function compileCompiled(options) {
101
+ export async function buildVerifiableContext(options) {
102
102
  const preserveMode = options.preserveStageShells ?? "on-failure";
103
- resetCompiledGeneratedState(options.compiledPath, "compile");
103
+ resetBuildGeneratedState(options.verifiableContextPath, "build");
104
104
  if (preserveMode !== "always") {
105
- pruneStageExecutionShells(options.compiledPath);
105
+ pruneStageExecutionShells(options.verifiableContextPath);
106
106
  }
107
107
  let result = {
108
108
  ok: true,
@@ -110,38 +110,38 @@ export async function compileCompiled(options) {
110
110
  failedStage: null,
111
111
  };
112
112
  try {
113
- refreshCompiledBootstrapGuidance(options.compiledPath);
114
- const methodValidation = validateMethodPackage(methodPackagePathForCompiled(options.compiledPath));
115
- if (!methodValidation.ok) {
116
- reportValidationFailure(options.reporter, methodValidation.summary, methodValidation.errors);
113
+ refreshVerifiableContextBootstrapGuidance(options.verifiableContextPath);
114
+ const buildPlanValidation = validateBuildPlanPackage(buildPlanPackagePathForVerifiableContext(options.verifiableContextPath));
115
+ if (!buildPlanValidation.ok) {
116
+ reportValidationFailure(options.reporter, buildPlanValidation.summary, buildPlanValidation.errors);
117
117
  return {
118
118
  ...result,
119
119
  ok: false,
120
- failedStage: "method",
120
+ failedStage: "build-plan",
121
121
  stageResults: {
122
122
  ...result.stageResults,
123
- method: {
123
+ "build-plan": {
124
124
  ok: false,
125
125
  code: 1,
126
- summary: methodValidation.summary,
126
+ summary: buildPlanValidation.summary,
127
127
  },
128
128
  },
129
129
  };
130
130
  }
131
- const context = resolveCompiledContext(options.compiledPath);
132
- const sourceInputPath = resolveSourceInputPath(options.compiledPath);
133
- const stages = compiledExecutionStages(context.methodId, options.compiledPath);
134
- writeCompiledSourceRuntime({
135
- compiledPath: options.compiledPath,
136
- methodId: context.methodId,
131
+ const context = resolveBuildContext(options.verifiableContextPath);
132
+ const sourceInputPath = resolveSourceInputPath(options.verifiableContextPath);
133
+ const stages = buildExecutionStages(context.buildPlanId, options.verifiableContextPath);
134
+ writeBuildSourceRuntime({
135
+ verifiableContextPath: options.verifiableContextPath,
136
+ buildPlanId: context.buildPlanId,
137
137
  stageIds: stages.map((stage) => stage.id),
138
138
  sourcePath: sourceInputPath,
139
139
  runId: options.runId ?? null,
140
140
  });
141
141
  for (const [index, stageDefinition] of stages.entries()) {
142
- const stageResult = await runCompiledStage({
142
+ const stageResult = await runBuildStage({
143
143
  executor: pickStageExecutor(options.executor, stageDefinition, options.resolveStageExecutor),
144
- compiledPath: options.compiledPath,
144
+ verifiableContextPath: options.verifiableContextPath,
145
145
  reporter: options.reporter,
146
146
  reportStep: true,
147
147
  stageDefinition,
@@ -157,19 +157,19 @@ export async function compileCompiled(options) {
157
157
  return result;
158
158
  }
159
159
  }
160
- const methodValidationResult = validateCompiledMethod(options.compiledPath);
161
- result.ok = methodValidationResult.ok;
162
- result.failedStage = methodValidationResult.ok ? null : methodValidationResult.stage;
163
- result.stageResults.compiled = {
164
- ok: methodValidationResult.ok,
165
- code: methodValidationResult.ok ? 0 : 1,
166
- summary: methodValidationResult.summary,
160
+ const buildPlanValidationResult = validateVerifiableContext(options.verifiableContextPath);
161
+ result.ok = buildPlanValidationResult.ok;
162
+ result.failedStage = buildPlanValidationResult.ok ? null : buildPlanValidationResult.stage;
163
+ result.stageResults["verifiable-context"] = {
164
+ ok: buildPlanValidationResult.ok,
165
+ code: buildPlanValidationResult.ok ? 0 : 1,
166
+ summary: buildPlanValidationResult.summary,
167
167
  };
168
168
  return result;
169
169
  }
170
170
  finally {
171
171
  if (preserveMode !== "always" && result.ok) {
172
- pruneStageExecutionShells(options.compiledPath);
172
+ pruneStageExecutionShells(options.verifiableContextPath);
173
173
  }
174
174
  }
175
175
  }
@@ -0,0 +1,2 @@
1
+ export declare const BUILD_PLAN_ARTIFACT_KINDS: readonly ["directory", "file", "runtime"];
2
+ export type BuildPlanArtifactKind = typeof BUILD_PLAN_ARTIFACT_KINDS[number];