opensip-cli 0.1.6 → 0.1.7

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 (213) hide show
  1. package/dist/bootstrap/admit-tool-package.d.ts.map +1 -1
  2. package/dist/bootstrap/admit-tool-package.js +8 -3
  3. package/dist/bootstrap/admit-tool-package.js.map +1 -1
  4. package/dist/bootstrap/bind-tool-context.d.ts.map +1 -1
  5. package/dist/bootstrap/bind-tool-context.js +5 -3
  6. package/dist/bootstrap/bind-tool-context.js.map +1 -1
  7. package/dist/bootstrap/build-command-registration-input.d.ts +7 -0
  8. package/dist/bootstrap/build-command-registration-input.d.ts.map +1 -1
  9. package/dist/bootstrap/build-command-registration-input.js +11 -4
  10. package/dist/bootstrap/build-command-registration-input.js.map +1 -1
  11. package/dist/bootstrap/build-per-run-scope.d.ts +12 -0
  12. package/dist/bootstrap/build-per-run-scope.d.ts.map +1 -1
  13. package/dist/bootstrap/build-per-run-scope.js +84 -9
  14. package/dist/bootstrap/build-per-run-scope.js.map +1 -1
  15. package/dist/bootstrap/bundled-manifest.d.ts +5 -0
  16. package/dist/bootstrap/bundled-manifest.d.ts.map +1 -0
  17. package/dist/bootstrap/bundled-manifest.js +13 -0
  18. package/dist/bootstrap/bundled-manifest.js.map +1 -0
  19. package/dist/bootstrap/bundled-tools.manifest.json +19 -1
  20. package/dist/bootstrap/config-and-capabilities.d.ts.map +1 -1
  21. package/dist/bootstrap/config-and-capabilities.js +5 -4
  22. package/dist/bootstrap/config-and-capabilities.js.map +1 -1
  23. package/dist/bootstrap/constants.d.ts +3 -0
  24. package/dist/bootstrap/constants.d.ts.map +1 -0
  25. package/dist/bootstrap/constants.js +3 -0
  26. package/dist/bootstrap/constants.js.map +1 -0
  27. package/dist/bootstrap/decorate-tool-primary.d.ts +50 -0
  28. package/dist/bootstrap/decorate-tool-primary.d.ts.map +1 -0
  29. package/dist/bootstrap/decorate-tool-primary.js +111 -0
  30. package/dist/bootstrap/decorate-tool-primary.js.map +1 -0
  31. package/dist/bootstrap/execute-post-bailout-bootstrap.d.ts.map +1 -1
  32. package/dist/bootstrap/execute-post-bailout-bootstrap.js +10 -0
  33. package/dist/bootstrap/execute-post-bailout-bootstrap.js.map +1 -1
  34. package/dist/bootstrap/index.d.ts +1 -1
  35. package/dist/bootstrap/index.d.ts.map +1 -1
  36. package/dist/bootstrap/index.js +1 -4
  37. package/dist/bootstrap/index.js.map +1 -1
  38. package/dist/bootstrap/io-plane.d.ts +47 -0
  39. package/dist/bootstrap/io-plane.d.ts.map +1 -0
  40. package/dist/bootstrap/io-plane.js +73 -0
  41. package/dist/bootstrap/io-plane.js.map +1 -0
  42. package/dist/bootstrap/load-tool-capabilities.d.ts.map +1 -1
  43. package/dist/bootstrap/load-tool-capabilities.js +18 -2
  44. package/dist/bootstrap/load-tool-capabilities.js.map +1 -1
  45. package/dist/bootstrap/owning-tool-init.d.ts.map +1 -1
  46. package/dist/bootstrap/owning-tool-init.js +7 -4
  47. package/dist/bootstrap/owning-tool-init.js.map +1 -1
  48. package/dist/bootstrap/phase-map.d.ts +20 -0
  49. package/dist/bootstrap/phase-map.d.ts.map +1 -0
  50. package/dist/bootstrap/phase-map.js +108 -0
  51. package/dist/bootstrap/phase-map.js.map +1 -0
  52. package/dist/bootstrap/pre-action-hook.d.ts.map +1 -1
  53. package/dist/bootstrap/pre-action-hook.js +19 -2
  54. package/dist/bootstrap/pre-action-hook.js.map +1 -1
  55. package/dist/bootstrap/register-tools-discovery.d.ts +38 -39
  56. package/dist/bootstrap/register-tools-discovery.d.ts.map +1 -1
  57. package/dist/bootstrap/register-tools-discovery.js +132 -83
  58. package/dist/bootstrap/register-tools-discovery.js.map +1 -1
  59. package/dist/bootstrap/register-tools-mount.d.ts +18 -1
  60. package/dist/bootstrap/register-tools-mount.d.ts.map +1 -1
  61. package/dist/bootstrap/register-tools-mount.js +118 -18
  62. package/dist/bootstrap/register-tools-mount.js.map +1 -1
  63. package/dist/bootstrap/register-tools.d.ts +58 -14
  64. package/dist/bootstrap/register-tools.d.ts.map +1 -1
  65. package/dist/bootstrap/register-tools.js +185 -14
  66. package/dist/bootstrap/register-tools.js.map +1 -1
  67. package/dist/bootstrap/root-version.d.ts +26 -0
  68. package/dist/bootstrap/root-version.d.ts.map +1 -0
  69. package/dist/bootstrap/root-version.js +36 -0
  70. package/dist/bootstrap/root-version.js.map +1 -0
  71. package/dist/bootstrap/scope-access.d.ts +11 -0
  72. package/dist/bootstrap/scope-access.d.ts.map +1 -1
  73. package/dist/bootstrap/scope-access.js +26 -0
  74. package/dist/bootstrap/scope-access.js.map +1 -1
  75. package/dist/bootstrap/tool-lifecycle.d.ts +0 -22
  76. package/dist/bootstrap/tool-lifecycle.d.ts.map +1 -1
  77. package/dist/bootstrap/tool-lifecycle.js +0 -23
  78. package/dist/bootstrap/tool-lifecycle.js.map +1 -1
  79. package/dist/bootstrap/validate-tool.d.ts +10 -4
  80. package/dist/bootstrap/validate-tool.d.ts.map +1 -1
  81. package/dist/bootstrap/validate-tool.js +76 -22
  82. package/dist/bootstrap/validate-tool.js.map +1 -1
  83. package/dist/cli-context.d.ts +2 -2
  84. package/dist/cli-context.d.ts.map +1 -1
  85. package/dist/cli-context.js +20 -35
  86. package/dist/cli-context.js.map +1 -1
  87. package/dist/commands/agent-catalog.d.ts +29 -0
  88. package/dist/commands/agent-catalog.d.ts.map +1 -1
  89. package/dist/commands/agent-catalog.js +77 -36
  90. package/dist/commands/agent-catalog.js.map +1 -1
  91. package/dist/commands/clear.d.ts.map +1 -1
  92. package/dist/commands/clear.js +0 -1
  93. package/dist/commands/clear.js.map +1 -1
  94. package/dist/commands/command-scope-index.d.ts +15 -1
  95. package/dist/commands/command-scope-index.d.ts.map +1 -1
  96. package/dist/commands/command-scope-index.js +10 -1
  97. package/dist/commands/command-scope-index.js.map +1 -1
  98. package/dist/commands/completion.d.ts +67 -6
  99. package/dist/commands/completion.d.ts.map +1 -1
  100. package/dist/commands/completion.js +84 -12
  101. package/dist/commands/completion.js.map +1 -1
  102. package/dist/commands/configure.d.ts.map +1 -1
  103. package/dist/commands/configure.js +0 -1
  104. package/dist/commands/configure.js.map +1 -1
  105. package/dist/commands/host-command-specs.d.ts +16 -9
  106. package/dist/commands/host-command-specs.d.ts.map +1 -1
  107. package/dist/commands/host-command-specs.js +45 -19
  108. package/dist/commands/host-command-specs.js.map +1 -1
  109. package/dist/commands/host-config-flag.d.ts +21 -0
  110. package/dist/commands/host-config-flag.d.ts.map +1 -0
  111. package/dist/commands/host-config-flag.js +21 -0
  112. package/dist/commands/host-config-flag.js.map +1 -0
  113. package/dist/commands/host-subcommand-groups.d.ts +46 -5
  114. package/dist/commands/host-subcommand-groups.d.ts.map +1 -1
  115. package/dist/commands/host-subcommand-groups.js +97 -65
  116. package/dist/commands/host-subcommand-groups.js.map +1 -1
  117. package/dist/commands/index.d.ts +1 -1
  118. package/dist/commands/index.js +1 -1
  119. package/dist/commands/internal-command-visibility.d.ts +42 -0
  120. package/dist/commands/internal-command-visibility.d.ts.map +1 -0
  121. package/dist/commands/internal-command-visibility.js +54 -0
  122. package/dist/commands/internal-command-visibility.js.map +1 -0
  123. package/dist/commands/mount-command-action.d.ts +5 -0
  124. package/dist/commands/mount-command-action.d.ts.map +1 -1
  125. package/dist/commands/mount-command-action.js +26 -2
  126. package/dist/commands/mount-command-action.js.map +1 -1
  127. package/dist/commands/mount-command-spec.d.ts +9 -2
  128. package/dist/commands/mount-command-spec.d.ts.map +1 -1
  129. package/dist/commands/mount-command-spec.js +9 -1
  130. package/dist/commands/mount-command-spec.js.map +1 -1
  131. package/dist/commands/plugin/domain-resolution.d.ts +12 -13
  132. package/dist/commands/plugin/domain-resolution.d.ts.map +1 -1
  133. package/dist/commands/plugin/domain-resolution.js +12 -58
  134. package/dist/commands/plugin/domain-resolution.js.map +1 -1
  135. package/dist/commands/plugin/host-dir.d.ts +0 -1
  136. package/dist/commands/plugin/host-dir.d.ts.map +1 -1
  137. package/dist/commands/plugin/host-dir.js +1 -1
  138. package/dist/commands/plugin/host-dir.js.map +1 -1
  139. package/dist/commands/plugin.d.ts +20 -14
  140. package/dist/commands/plugin.d.ts.map +1 -1
  141. package/dist/commands/plugin.js +39 -47
  142. package/dist/commands/plugin.js.map +1 -1
  143. package/dist/commands/render-outcome.d.ts.map +1 -1
  144. package/dist/commands/render-outcome.js.map +1 -1
  145. package/dist/commands/shared.d.ts +9 -0
  146. package/dist/commands/shared.d.ts.map +1 -1
  147. package/dist/commands/tools/create.d.ts +11 -0
  148. package/dist/commands/tools/create.d.ts.map +1 -0
  149. package/dist/commands/tools/create.js +84 -0
  150. package/dist/commands/tools/create.js.map +1 -0
  151. package/dist/commands/tools/index.d.ts.map +1 -1
  152. package/dist/commands/tools/index.js +31 -0
  153. package/dist/commands/tools/index.js.map +1 -1
  154. package/dist/commands/tools/runtime-probe-entry.d.ts.map +1 -1
  155. package/dist/commands/tools/runtime-probe-entry.js +4 -2
  156. package/dist/commands/tools/runtime-probe-entry.js.map +1 -1
  157. package/dist/commands/tools/validate.d.ts.map +1 -1
  158. package/dist/commands/tools/validate.js +12 -5
  159. package/dist/commands/tools/validate.js.map +1 -1
  160. package/dist/commands/uninstall.d.ts.map +1 -1
  161. package/dist/commands/uninstall.js +0 -1
  162. package/dist/commands/uninstall.js.map +1 -1
  163. package/dist/env/host-env-specs.d.ts +18 -0
  164. package/dist/env/host-env-specs.d.ts.map +1 -1
  165. package/dist/env/host-env-specs.js +36 -2
  166. package/dist/env/host-env-specs.js.map +1 -1
  167. package/dist/index.d.ts +1 -1
  168. package/dist/index.d.ts.map +1 -1
  169. package/dist/index.js +24 -6
  170. package/dist/index.js.map +1 -1
  171. package/dist/report-compose.d.ts.map +1 -1
  172. package/dist/report-compose.js +2 -2
  173. package/dist/report-compose.js.map +1 -1
  174. package/dist/session-replay-registry.d.ts +1 -1
  175. package/dist/session-replay-registry.d.ts.map +1 -1
  176. package/dist/session-replay-registry.js +3 -1
  177. package/dist/session-replay-registry.js.map +1 -1
  178. package/dist/ui/result-to-view.d.ts +27 -7
  179. package/dist/ui/result-to-view.d.ts.map +1 -1
  180. package/dist/ui/result-to-view.js +68 -75
  181. package/dist/ui/result-to-view.js.map +1 -1
  182. package/dist/ui/views/misc-views.d.ts.map +1 -1
  183. package/dist/ui/views/misc-views.js +3 -1
  184. package/dist/ui/views/misc-views.js.map +1 -1
  185. package/dist/ui/views/tools-views.d.ts +2 -1
  186. package/dist/ui/views/tools-views.d.ts.map +1 -1
  187. package/dist/ui/views/tools-views.js +21 -0
  188. package/dist/ui/views/tools-views.js.map +1 -1
  189. package/package.json +32 -32
  190. package/dist/bootstrap/authored-tool-admission.d.ts +0 -23
  191. package/dist/bootstrap/authored-tool-admission.d.ts.map +0 -1
  192. package/dist/bootstrap/authored-tool-admission.js +0 -54
  193. package/dist/bootstrap/authored-tool-admission.js.map +0 -1
  194. package/dist/bootstrap/egress-plane.d.ts +0 -22
  195. package/dist/bootstrap/egress-plane.d.ts.map +0 -1
  196. package/dist/bootstrap/egress-plane.js +0 -37
  197. package/dist/bootstrap/egress-plane.js.map +0 -1
  198. package/dist/bootstrap/installed-tool-admission.d.ts +0 -20
  199. package/dist/bootstrap/installed-tool-admission.d.ts.map +0 -1
  200. package/dist/bootstrap/installed-tool-admission.js +0 -60
  201. package/dist/bootstrap/installed-tool-admission.js.map +0 -1
  202. package/dist/bootstrap/live-plane.d.ts +0 -51
  203. package/dist/bootstrap/live-plane.d.ts.map +0 -1
  204. package/dist/bootstrap/live-plane.js +0 -72
  205. package/dist/bootstrap/live-plane.js.map +0 -1
  206. package/dist/bootstrap/register-tools-bundled.d.ts +0 -28
  207. package/dist/bootstrap/register-tools-bundled.d.ts.map +0 -1
  208. package/dist/bootstrap/register-tools-bundled.js +0 -107
  209. package/dist/bootstrap/register-tools-bundled.js.map +0 -1
  210. package/dist/bootstrap/register-tools-shared.d.ts +0 -40
  211. package/dist/bootstrap/register-tools-shared.d.ts.map +0 -1
  212. package/dist/bootstrap/register-tools-shared.js +0 -98
  213. package/dist/bootstrap/register-tools-shared.js.map +0 -1
@@ -48,8 +48,6 @@
48
48
  * one ordered entry point. The driver is intentionally THIN: it sequences the
49
49
  * pre-existing helpers, it does not reimplement them.
50
50
  */
51
- import type { CliProgram } from '@opensip-cli/contracts';
52
- import type { ToolCliContext, ToolRegistry } from '@opensip-cli/core';
53
51
  /**
54
52
  * Canonical, ordered tool-lifecycle steps (launch, §5.4). The numeric
55
53
  * values are the step ordinals used in the JSDoc above and in
@@ -79,24 +77,4 @@ export declare const TOOL_LIFECYCLE_STEPS: {
79
77
  /** 10 — Commander dispatches the action body through the mount pipeline. */
80
78
  readonly dispatch: 10;
81
79
  };
82
- /**
83
- * Drive the STARTUP-phase command-mount step (step 8) for every registered
84
- * tool. By the time this runs, steps 1-4 have already populated `registry`
85
- * inside {@link bootstrapCli} (provenance no longer matters — bundled and
86
- * installed tools mount identically). This is the single ordered entry point
87
- * the composition root calls for step 8, replacing the bare
88
- * `mountAllToolCommands(...)` call so the lifecycle has one named seam.
89
- *
90
- * Kept THIN deliberately: it delegates straight to
91
- * {@link mountAllToolCommands}, which mounts each tool's declared `commandSpecs`
92
- * (the one command surface, launch) with per-tool failure isolation. The naming +
93
- * ordering is the value here, not new logic.
94
- *
95
- * @param registry The per-invocation tool registry, already populated by
96
- * steps 1-4.
97
- * @param program The root Commander program (host-owned; passed in since the tool
98
- * context no longer carries it, §8).
99
- * @param ctx The per-invocation handler context handed to each mounted command.
100
- */
101
- export declare function mountToolCommands(registry: ToolRegistry, program: CliProgram, ctx: ToolCliContext): void;
102
80
  //# sourceMappingURL=tool-lifecycle.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"tool-lifecycle.d.ts","sourceRoot":"","sources":["../../src/bootstrap/tool-lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AAIH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACzD,OAAO,KAAK,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEtE;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;IAC/B,oDAAoD;;IAEpD,mEAAmE;;IAEnE,0EAA0E;;IAE1E,uEAAuE;;IAEvE,+DAA+D;;IAE/D,sDAAsD;;IAEtD,gFAAgF;;IAEhF,mDAAmD;;IAEnD,0EAA0E;;IAE1E,4EAA4E;;CAEpE,CAAC;AAEX;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,iBAAiB,CAC/B,QAAQ,EAAE,YAAY,EACtB,OAAO,EAAE,UAAU,EACnB,GAAG,EAAE,cAAc,GAClB,IAAI,CAEN"}
1
+ {"version":3,"file":"tool-lifecycle.d.ts","sourceRoot":"","sources":["../../src/bootstrap/tool-lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AAEH;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;IAC/B,oDAAoD;;IAEpD,mEAAmE;;IAEnE,0EAA0E;;IAE1E,uEAAuE;;IAEvE,+DAA+D;;IAE/D,sDAAsD;;IAEtD,gFAAgF;;IAEhF,mDAAmD;;IAEnD,0EAA0E;;IAE1E,4EAA4E;;CAEpE,CAAC"}
@@ -48,7 +48,6 @@
48
48
  * one ordered entry point. The driver is intentionally THIN: it sequences the
49
49
  * pre-existing helpers, it does not reimplement them.
50
50
  */
51
- import { mountAllToolCommands } from './register-tools.js';
52
51
  /**
53
52
  * Canonical, ordered tool-lifecycle steps (launch, §5.4). The numeric
54
53
  * values are the step ordinals used in the JSDoc above and in
@@ -78,26 +77,4 @@ export const TOOL_LIFECYCLE_STEPS = {
78
77
  /** 10 — Commander dispatches the action body through the mount pipeline. */
79
78
  dispatch: 10,
80
79
  };
81
- /**
82
- * Drive the STARTUP-phase command-mount step (step 8) for every registered
83
- * tool. By the time this runs, steps 1-4 have already populated `registry`
84
- * inside {@link bootstrapCli} (provenance no longer matters — bundled and
85
- * installed tools mount identically). This is the single ordered entry point
86
- * the composition root calls for step 8, replacing the bare
87
- * `mountAllToolCommands(...)` call so the lifecycle has one named seam.
88
- *
89
- * Kept THIN deliberately: it delegates straight to
90
- * {@link mountAllToolCommands}, which mounts each tool's declared `commandSpecs`
91
- * (the one command surface, launch) with per-tool failure isolation. The naming +
92
- * ordering is the value here, not new logic.
93
- *
94
- * @param registry The per-invocation tool registry, already populated by
95
- * steps 1-4.
96
- * @param program The root Commander program (host-owned; passed in since the tool
97
- * context no longer carries it, §8).
98
- * @param ctx The per-invocation handler context handed to each mounted command.
99
- */
100
- export function mountToolCommands(registry, program, ctx) {
101
- mountAllToolCommands(registry, program, ctx);
102
- }
103
80
  //# sourceMappingURL=tool-lifecycle.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tool-lifecycle.js","sourceRoot":"","sources":["../../src/bootstrap/tool-lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AAEH,OAAO,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAK3D;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,oDAAoD;IACpD,QAAQ,EAAE,CAAC;IACX,mEAAmE;IACnE,MAAM,EAAE,CAAC;IACT,0EAA0E;IAC1E,KAAK,EAAE,CAAC;IACR,uEAAuE;IACvE,MAAM,EAAE,CAAC;IACT,+DAA+D;IAC/D,MAAM,EAAE,CAAC;IACT,sDAAsD;IACtD,KAAK,EAAE,CAAC;IACR,gFAAgF;IAChF,YAAY,EAAE,CAAC;IACf,mDAAmD;IACnD,KAAK,EAAE,CAAC;IACR,0EAA0E;IAC1E,UAAU,EAAE,CAAC;IACb,4EAA4E;IAC5E,QAAQ,EAAE,EAAE;CACJ,CAAC;AAEX;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,UAAU,iBAAiB,CAC/B,QAAsB,EACtB,OAAmB,EACnB,GAAmB;IAEnB,oBAAoB,CAAC,QAAQ,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC;AAC/C,CAAC"}
1
+ {"version":3,"file":"tool-lifecycle.js","sourceRoot":"","sources":["../../src/bootstrap/tool-lifecycle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiDG;AAEH;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,oDAAoD;IACpD,QAAQ,EAAE,CAAC;IACX,mEAAmE;IACnE,MAAM,EAAE,CAAC;IACT,0EAA0E;IAC1E,KAAK,EAAE,CAAC;IACR,uEAAuE;IACvE,MAAM,EAAE,CAAC;IACT,+DAA+D;IAC/D,MAAM,EAAE,CAAC;IACT,sDAAsD;IACtD,KAAK,EAAE,CAAC;IACR,gFAAgF;IAChF,YAAY,EAAE,CAAC;IACf,mDAAmD;IACnD,KAAK,EAAE,CAAC;IACR,0EAA0E;IAC1E,UAAU,EAAE,CAAC;IACb,4EAA4E;IAC5E,QAAQ,EAAE,EAAE;CACJ,CAAC"}
@@ -4,11 +4,12 @@
4
4
  * an arbitrary npm package and inspects whatever it exports.
5
5
  *
6
6
  * Verifies the minimal contract the registry depends on: a
7
- * `metadata.id` string (used for dedupe + listing), a `commands` array,
8
- * and a command surface — a non-empty `commandSpecs` array (the one command
7
+ * `metadata.id` string (used for dedupe + listing), and a command surface —
8
+ * a non-empty `commandSpecs` array (the one command
9
9
  * surface as of launch; `register()` was removed). A tool with no `commandSpecs`
10
- * cannot mount any command, so it fails the shape check. `initialize` and
11
- * `contributeScope` stay optional per the Tool interface.
10
+ * cannot mount any command, so it fails the shape check. Lifecycle hooks belong
11
+ * under `extensionPoints` only top-level hooks are rejected with an actionable
12
+ * diagnostic.
12
13
  *
13
14
  * Ordering vs. the admission gate: this shape check runs AFTER a
14
15
  * tool's module is imported. The compatibility gate (`admitTool`) and the
@@ -18,5 +19,10 @@
18
19
  * and never reaches `isValidTool`.
19
20
  */
20
21
  import { type Tool } from '@opensip-cli/core';
22
+ /**
23
+ * Human-readable rejection reason for an exported `tool` value.
24
+ * `undefined` means the export satisfies {@link isValidTool}.
25
+ */
26
+ export declare function toolValidationFailure(value: unknown): string | undefined;
21
27
  export declare function isValidTool(value: unknown): value is Tool;
22
28
  //# sourceMappingURL=validate-tool.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"validate-tool.d.ts","sourceRoot":"","sources":["../../src/bootstrap/validate-tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAuB,KAAK,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEnE,wBAAgB,WAAW,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,IAAI,CAkBzD"}
1
+ {"version":3,"file":"validate-tool.d.ts","sourceRoot":"","sources":["../../src/bootstrap/validate-tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAuB,KAAK,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAuDnE;;;GAGG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAqBxE;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,IAAI,CAEzD"}
@@ -4,11 +4,12 @@
4
4
  * an arbitrary npm package and inspects whatever it exports.
5
5
  *
6
6
  * Verifies the minimal contract the registry depends on: a
7
- * `metadata.id` string (used for dedupe + listing), a `commands` array,
8
- * and a command surface — a non-empty `commandSpecs` array (the one command
7
+ * `metadata.id` string (used for dedupe + listing), and a command surface —
8
+ * a non-empty `commandSpecs` array (the one command
9
9
  * surface as of launch; `register()` was removed). A tool with no `commandSpecs`
10
- * cannot mount any command, so it fails the shape check. `initialize` and
11
- * `contributeScope` stay optional per the Tool interface.
10
+ * cannot mount any command, so it fails the shape check. Lifecycle hooks belong
11
+ * under `extensionPoints` only top-level hooks are rejected with an actionable
12
+ * diagnostic.
12
13
  *
13
14
  * Ordering vs. the admission gate: this shape check runs AFTER a
14
15
  * tool's module is imported. The compatibility gate (`admitTool`) and the
@@ -18,25 +19,78 @@
18
19
  * and never reaches `isValidTool`.
19
20
  */
20
21
  import { validateCommandSpec } from '@opensip-cli/core';
21
- export function isValidTool(value) {
22
- if (typeof value !== 'object' || value === null)
23
- return false;
22
+ /** Top-level hook keys removed in the tool-author-simplify contract. */
23
+ const LEGACY_TOP_LEVEL_HOOK_KEYS = [
24
+ 'initialize',
25
+ 'contributeScope',
26
+ 'collectReportData',
27
+ 'sessionReplay',
28
+ 'config',
29
+ 'capabilityRegistrars',
30
+ 'fingerprintStrategy',
31
+ 'scaffoldExamples',
32
+ 'stableExampleIds',
33
+ 'scaffoldConfigBlock',
34
+ ];
35
+ function legacyTopLevelHookKeys(candidate) {
36
+ return LEGACY_TOP_LEVEL_HOOK_KEYS.filter((key) => candidate[key] !== undefined);
37
+ }
38
+ function metadataValidationFailure(metadata) {
39
+ if (typeof metadata !== 'object' || metadata === null) {
40
+ return 'tool.metadata is missing or not an object';
41
+ }
42
+ if (typeof metadata.id !== 'string') {
43
+ return 'tool.metadata.id must be a string';
44
+ }
45
+ return undefined;
46
+ }
47
+ function commandSpecsValidationFailure(commandSpecs) {
48
+ if (!Array.isArray(commandSpecs) || commandSpecs.length === 0) {
49
+ return 'tool.commandSpecs must be a non-empty array (the declarative command surface)';
50
+ }
51
+ for (const spec of commandSpecs) {
52
+ if (!validateCommandSpec(spec)) {
53
+ return 'tool.commandSpecs contains an invalid CommandSpec';
54
+ }
55
+ }
56
+ return undefined;
57
+ }
58
+ function optionalCommandsValidationFailure(commands) {
59
+ if (!Array.isArray(commands))
60
+ return undefined;
61
+ for (const cmd of commands) {
62
+ if (typeof cmd !== 'object' || cmd === null) {
63
+ return 'tool.commands contains a non-object entry';
64
+ }
65
+ if (typeof cmd.name !== 'string') {
66
+ return 'tool.commands entries must include a string name';
67
+ }
68
+ }
69
+ return undefined;
70
+ }
71
+ /**
72
+ * Human-readable rejection reason for an exported `tool` value.
73
+ * `undefined` means the export satisfies {@link isValidTool}.
74
+ */
75
+ export function toolValidationFailure(value) {
76
+ if (typeof value !== 'object' || value === null) {
77
+ return 'tool export is not an object';
78
+ }
24
79
  const candidate = value;
25
- if (typeof candidate.metadata !== 'object' || candidate.metadata === null)
26
- return false;
27
- if (typeof candidate.metadata.id !== 'string')
28
- return false;
29
- if (!Array.isArray(candidate.commands))
30
- return false;
31
- // A tool must expose a command surface: a non-empty declarative `commandSpecs`
32
- // array (the one command surface, launch — `register()` was removed). A tool
33
- // with no commandSpecs cannot contribute any command and is rejected.
34
- if (!Array.isArray(candidate.commandSpecs) || candidate.commandSpecs.length === 0)
35
- return false;
36
- for (const spec of candidate.commandSpecs) {
37
- if (!validateCommandSpec(spec))
38
- return false;
80
+ const metadataFailure = metadataValidationFailure(candidate.metadata);
81
+ if (metadataFailure !== undefined)
82
+ return metadataFailure;
83
+ const legacy = legacyTopLevelHookKeys(candidate);
84
+ if (legacy.length > 0) {
85
+ return (`tool declares deprecated top-level hooks [${legacy.join(', ')}]; ` +
86
+ 'move them under extensionPoints (see opensip tool authoring docs)');
39
87
  }
40
- return true;
88
+ const specsFailure = commandSpecsValidationFailure(candidate.commandSpecs);
89
+ if (specsFailure !== undefined)
90
+ return specsFailure;
91
+ return optionalCommandsValidationFailure(candidate.commands);
92
+ }
93
+ export function isValidTool(value) {
94
+ return toolValidationFailure(value) === undefined;
41
95
  }
42
96
  //# sourceMappingURL=validate-tool.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"validate-tool.js","sourceRoot":"","sources":["../../src/bootstrap/validate-tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,mBAAmB,EAAa,MAAM,mBAAmB,CAAC;AAE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AAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QAChD,OAAO,8BAA8B,CAAC;IACxC,CAAC;IACD,MAAM,SAAS,GAAG,KAAgC,CAAC;IAEnD,MAAM,eAAe,GAAG,yBAAyB,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;IACtE,IAAI,eAAe,KAAK,SAAS;QAAE,OAAO,eAAe,CAAC;IAE1D,MAAM,MAAM,GAAG,sBAAsB,CAAC,SAAS,CAAC,CAAC;IACjD,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACtB,OAAO,CACL,6CAA6C,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK;YACnE,mEAAmE,CACpE,CAAC;IACJ,CAAC;IAED,MAAM,YAAY,GAAG,6BAA6B,CAAC,SAAS,CAAC,YAAY,CAAC,CAAC;IAC3E,IAAI,YAAY,KAAK,SAAS;QAAE,OAAO,YAAY,CAAC;IAEpD,OAAO,iCAAiC,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;AAC/D,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,KAAc;IACxC,OAAO,qBAAqB,CAAC,KAAK,CAAC,KAAK,SAAS,CAAC;AACpD,CAAC"}
@@ -17,10 +17,10 @@
17
17
  * `.runtime/datastore.sqlite`.
18
18
  */
19
19
  import { type Logger, type ToolCliContext } from '@opensip-cli/core';
20
- import { type LiveViewRegistry } from './bootstrap/live-plane.js';
20
+ import { type LiveViewRegistry } from './bootstrap/io-plane.js';
21
21
  import type { CommandResult } from '@opensip-cli/contracts';
22
22
  export { buildDatastoreThunk, getCurrentProjectRoot, getOrOpenDatastore, } from './bootstrap/scope-access.js';
23
- export { createLiveViewRegistry, type LiveViewRegistry } from './bootstrap/live-plane.js';
23
+ export { createLiveViewRegistry, type LiveViewRegistry } from './bootstrap/io-plane.js';
24
24
  export interface BuildToolCliContextOptions {
25
25
  readonly render: (result: CommandResult) => Promise<void>;
26
26
  readonly liveViews: LiveViewRegistry;
@@ -1 +1 @@
1
- {"version":3,"file":"cli-context.d.ts","sourceRoot":"","sources":["../src/cli-context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAGL,KAAK,MAAM,EACX,KAAK,cAAc,EACpB,MAAM,mBAAmB,CAAC;AAM3B,OAAO,EAAmB,KAAK,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAWnF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAsB5D,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,GACnB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,sBAAsB,EAAE,KAAK,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAE1F,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,aAAa,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,QAAQ,CAAC,SAAS,EAAE,gBAAgB,CAAC;IACrC,QAAQ,CAAC,eAAe,EAAE,CAAC,IAAI,EAAE;QAC/B,aAAa,EAAE,OAAO,CAAC;QACvB,UAAU,EAAE,OAAO,CAAC;KACrB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACpB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,GAAG,EAAE,cAAc,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,MAAM,MAAM,GAAG,SAAS,CAAC;CAChD;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,0BAA0B,GAAG,oBAAoB,CA2F1F"}
1
+ {"version":3,"file":"cli-context.d.ts","sourceRoot":"","sources":["../src/cli-context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAGL,KAAK,MAAM,EACX,KAAK,cAAc,EACpB,MAAM,mBAAmB,CAAC;AAI3B,OAAO,EAAiB,KAAK,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAW/E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAmB5D,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,GACnB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,sBAAsB,EAAE,KAAK,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAExF,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,aAAa,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,QAAQ,CAAC,SAAS,EAAE,gBAAgB,CAAC;IACrC,QAAQ,CAAC,eAAe,EAAE,CAAC,IAAI,EAAE;QAC/B,aAAa,EAAE,OAAO,CAAC;QACvB,UAAU,EAAE,OAAO,CAAC;KACrB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACpB,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,GAAG,EAAE,cAAc,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,MAAM,MAAM,GAAG,SAAS,CAAC;CAChD;AAED,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,0BAA0B,GAAG,oBAAoB,CAgF1F"}
@@ -18,15 +18,12 @@
18
18
  */
19
19
  import { logger as defaultLogger, } from '@opensip-cli/core';
20
20
  import { buildBaselineSeams } from './bootstrap/baseline-seams.js';
21
- import { createEgressPlane } from './bootstrap/egress-plane.js';
22
21
  import { buildHostPlanes } from './bootstrap/host-planes.js';
23
- import { createLivePlane } from './bootstrap/live-plane.js';
22
+ import { createIoPlane } from './bootstrap/io-plane.js';
24
23
  import { createOutputPlane } from './bootstrap/output-plane.js';
25
24
  import { createRunActionHooks, createRunPlaneFactory, createRunSessionSeam, } from './bootstrap/run-plane.js';
26
- import { getProjectDatastore, readScope } from './bootstrap/scope-access.js';
25
+ import { createDatastoreResolver, readScope } from './bootstrap/scope-access.js';
27
26
  import { buildStateSeams } from './bootstrap/state-seams.js';
28
- /** Structured-log `module` tag for this composition-root module. */
29
- const MODULE_TAG = 'cli:context';
30
27
  // ---------------------------------------------------------------------------
31
28
  // No module-global bootstrap-handoff bag.
32
29
  //
@@ -40,11 +37,11 @@ const MODULE_TAG = 'cli:context';
40
37
  // `currentScope()?.toolProvenance` / `?.toolManifests`.
41
38
  // ---------------------------------------------------------------------------
42
39
  // Per-run scope + datastore readers live in `bootstrap/scope-access.ts`; the
43
- // live-view registry lives in `bootstrap/live-plane.ts`. Both are re-exported
40
+ // live-view registry lives in `bootstrap/io-plane.ts`. Both are re-exported
44
41
  // here so existing importers (`main()` + the dynamic-import tests) keep their
45
42
  // stable `cli-context.js` entry point while this module focuses on assembly.
46
43
  export { buildDatastoreThunk, getCurrentProjectRoot, getOrOpenDatastore, } from './bootstrap/scope-access.js';
47
- export { createLiveViewRegistry } from './bootstrap/live-plane.js';
44
+ export { createLiveViewRegistry } from './bootstrap/io-plane.js';
48
45
  export function buildToolCliContext(opts) {
49
46
  const log = opts.logger ?? defaultLogger;
50
47
  // Output plane owns the single `process.exitCode` write path + the four
@@ -56,34 +53,16 @@ export function buildToolCliContext(opts) {
56
53
  // - durable per-tool keyed JSON state (ADR-0042);
57
54
  // - governance / entitlements / audit (H1-H3);
58
55
  // - effectful egress (cloud sync + `--report-to` + SARIF file sink).
59
- const baselineSeams = buildBaselineSeams({ getDatastore: getProjectDatastore, logger: log });
60
- const stateSeams = buildStateSeams({ getDatastore: getProjectDatastore });
61
- const hostPlanes = buildHostPlanes({ getDatastore: getProjectDatastore, logger: log });
62
- const egressPlane = createEgressPlane({ setExitCode: outputPlane.setExitCode, logger: log });
56
+ const projectDatastore = createDatastoreResolver('project-seam', log);
57
+ const baselineSeams = buildBaselineSeams({ getDatastore: projectDatastore, logger: log });
58
+ const stateSeams = buildStateSeams({ getDatastore: projectDatastore });
59
+ const hostPlanes = buildHostPlanes({ getDatastore: projectDatastore, logger: log });
63
60
  // Host run-lifecycle plane (host-owned-run-timing Phase 1). The FACTORY holds
64
61
  // stable deps only — it must NOT start a lifecycle here. The lifecycle is
65
62
  // created inside the command action (mount-command-spec calls `beginRun()`
66
63
  // after RunScope entry, before the handler) or lazily on first `timing` read.
67
64
  const runPlane = createRunPlaneFactory({
68
- // Best-effort datastore resolver via the entered scope thunk (no direct /
69
- // global access). Returns undefined when no project/datastore is in scope.
70
- getDatastore: () => {
71
- try {
72
- const thunk = readScope().datastore;
73
- return thunk ? thunk() : undefined;
74
- }
75
- catch (error) {
76
- // @swallow-ok no entered scope / no datastore in scope is normal for
77
- // non-project commands and tests; degrade to "no datastore" (the run
78
- // plane then no-ops). Debug-log for diagnosability.
79
- log.debug?.({
80
- evt: 'cli.context.datastore_unavailable',
81
- module: MODULE_TAG,
82
- error: error instanceof Error ? error.message : String(error),
83
- });
84
- return;
85
- }
86
- },
65
+ getDatastore: createDatastoreResolver('best-effort', log),
87
66
  logger: log,
88
67
  });
89
68
  // Public run seam (display-only timing) + internal action hooks (the mount
@@ -95,7 +74,13 @@ export function buildToolCliContext(opts) {
95
74
  // Live plane binds the per-invocation registry (built in `main()`) to the run
96
75
  // plane so `renderLive` owns the live run lifecycle: it times the TTY
97
76
  // occupancy and persists the renderer's returned `session` contribution.
98
- const livePlane = createLivePlane({ liveViews: opts.liveViews, runPlane, runSession });
77
+ const ioPlane = createIoPlane({
78
+ setExitCode: outputPlane.setExitCode,
79
+ logger: log,
80
+ liveViews: opts.liveViews,
81
+ runPlane,
82
+ runSession,
83
+ });
99
84
  const ctx = {
100
85
  get scope() {
101
86
  // The pre-action-hook (or explicit runWithScope in tests) enters the
@@ -105,14 +90,14 @@ export function buildToolCliContext(opts) {
105
90
  return readScope();
106
91
  },
107
92
  render: (result) => opts.render(result),
108
- registerLiveView: livePlane.register,
109
- renderLive: livePlane.renderLive,
93
+ registerLiveView: ioPlane.register,
94
+ renderLive: ioPlane.renderLive,
110
95
  maybeOpenReport: opts.maybeOpenReport,
111
96
  logger: log,
112
97
  setExitCode: outputPlane.setExitCode,
113
98
  ...outputPlane.emits, // emitJson / emitEnvelope / emitError / emitRaw
114
- deliverSignals: egressPlane.deliverSignals,
115
- writeSarif: egressPlane.writeSarif,
99
+ deliverSignals: ioPlane.deliverSignals,
100
+ writeSarif: ioPlane.writeSarif,
116
101
  // Host baseline/ratchet plane seams (ADR-0036) — persistence + diff + exports.
117
102
  saveBaseline: baselineSeams.saveBaseline,
118
103
  compareBaseline: baselineSeams.compareBaseline,
@@ -1 +1 @@
1
- {"version":3,"file":"cli-context.js","sourceRoot":"","sources":["../src/cli-context.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAEL,MAAM,IAAI,aAAa,GAGxB,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,EAAE,eAAe,EAAyB,MAAM,2BAA2B,CAAC;AACnF,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EACrB,oBAAoB,GAErB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAI7D,oEAAoE;AACpE,MAAM,UAAU,GAAG,aAAa,CAAC;AAEjC,8EAA8E;AAC9E,0CAA0C;AAC1C,EAAE;AACF,gFAAgF;AAChF,iFAAiF;AACjF,kFAAkF;AAClF,iFAAiF;AACjF,gFAAgF;AAChF,8EAA8E;AAC9E,qEAA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
@@ -7,7 +7,28 @@
7
7
  *
8
8
  * Future: can be made more dynamic by introspecting live CommandSpecs
9
9
  * (see completion.ts for precedent).
10
+ *
11
+ * Command taxonomy (tool-command-surface-taxonomy):
12
+ * - Entry points are keyed by the PUBLIC command path. A `parent`-nested tool
13
+ * verb (the `<tool> <verb>` grammar enabled by `CommandSpec.parent` — e.g.
14
+ * `graph export`, `fit list`) is catalogued UNDER its tool's entry point
15
+ * (the `<tool> <verb>` form), NOT as a separate root entry point.
16
+ * - Tier-3 `visibility: 'internal'` commands (`*-run-worker`, `*-shard-worker`,
17
+ * `*-equivalence-check`) are NEVER catalogued here — the agent-catalog
18
+ * primary surface excludes internal workers (the host-owned tiering pass
19
+ * formalized in Phase 1 filters them when this surface becomes spec-derived).
20
+ * In Phase 0 no tool declares `parent`/`visibility`, so the static catalog below
21
+ * already satisfies both rules (no nested verb, no internal worker is listed).
22
+ */
23
+ /**
24
+ * The command-taxonomy tier an entry point belongs to
25
+ * (tool-command-surface-taxonomy). `'platform'` = host-owned Tier-1 commands
26
+ * (`init`, `sessions`, `agent-catalog`, …); `'tool'` = a Tier-2 tool verb
27
+ * (`fit`, `graph`, `sim`, and their `<tool> <verb>` sub-verbs). `'internal'`
28
+ * (Tier-3 workers) is part of the union for completeness ONLY — the agent-catalog
29
+ * NEVER emits an `internal` entry point (its primary surface excludes Tier-3).
10
30
  */
31
+ export type CommandTier = 'platform' | 'tool' | 'internal';
11
32
  export interface AgentCatalog {
12
33
  readonly version: string;
13
34
  readonly description: string;
@@ -15,6 +36,14 @@ export interface AgentCatalog {
15
36
  readonly command: string;
16
37
  readonly description: string;
17
38
  readonly examples: readonly string[];
39
+ /**
40
+ * Taxonomy tier of this entry point (tool-command-surface-taxonomy). Additive
41
+ * (optional) so existing consumers of the `entryPoints` shape are unaffected;
42
+ * present on every entry the catalog ships so an agent sees the predictable
43
+ * Tier-1/Tier-2 structure. NEVER `'internal'` — Tier-3 is excluded from this
44
+ * surface by construction (see {@link assertNoInternalEntryPoints}).
45
+ */
46
+ readonly tier?: CommandTier;
18
47
  }[];
19
48
  readonly commonPatterns: readonly {
20
49
  readonly name: string;
@@ -1 +1 @@
1
- {"version":3,"file":"agent-catalog.d.ts","sourceRoot":"","sources":["../../src/commands/agent-catalog.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,SAAS;QAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QACzB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;KACtC,EAAE,CAAC;IACJ,QAAQ,CAAC,cAAc,EAAE,SAAS;QAChC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;KAC1B,EAAE,CAAC;IACJ,QAAQ,CAAC,YAAY,EAAE;QACrB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;QAChC,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;QAC/B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;KAC1B,CAAC;IACF,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;CACnC;AAED,wBAAgB,iBAAiB,IAAI,YAAY,CA8FhD;AAED,wBAAgB,mBAAmB,CAAC,IAAI,GAAE;IAAE,IAAI,CAAC,EAAE,OAAO,CAAA;CAAO;;;;;;;;;;EA8BhE"}
1
+ {"version":3,"file":"agent-catalog.d.ts","sourceRoot":"","sources":["../../src/commands/agent-catalog.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH;;;;;;;GAOG;AACH,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,MAAM,GAAG,UAAU,CAAC;AAE3D,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,SAAS;QAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QACzB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;QACrC;;;;;;WAMG;QACH,QAAQ,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC;KAC7B,EAAE,CAAC;IACJ,QAAQ,CAAC,cAAc,EAAE,SAAS;QAChC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;QAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;KAC1B,EAAE,CAAC;IACJ,QAAQ,CAAC,YAAY,EAAE;QACrB,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;QAChC,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;QAC/B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;KAC1B,CAAC;IACF,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;CACnC;AAkCD,wBAAgB,iBAAiB,IAAI,YAAY,CA8GhD;AAED,wBAAgB,mBAAmB,CAAC,IAAI,GAAE;IAAE,IAAI,CAAC,EAAE,OAAO,CAAA;CAAO;;;;;;;;;;EA8BhE"}
@@ -1,45 +1,82 @@
1
+ /**
2
+ * Internal (Tier-3) command-name shapes the agent-catalog must NEVER surface:
3
+ * the IPC/CI workers and the equivalence gate. The guard checks both the name
4
+ * shape AND an explicit `tier: 'internal'` so a future edit can't slip one in by
5
+ * either route. This is the by-construction complement to the Phase 4 test.
6
+ */
7
+ const INTERNAL_COMMAND_NAME_RE = /(?:-run-worker|-shard-worker|-equivalence-check)\b/;
8
+ /**
9
+ * Throw if any entry point is a Tier-3 internal command (by name shape or by an
10
+ * explicit `tier: 'internal'`). Called at catalog-build time so a regression that
11
+ * pastes an internal command into `entryPoints` fails loudly the first time the
12
+ * catalog is built, not silently at the agent boundary.
13
+ *
14
+ * @throws {Error} When an entry point is a Tier-3 internal command — by an
15
+ * explicit `tier: 'internal'` or by an internal command-name shape
16
+ * (`*-run-worker` / `*-shard-worker` / `*-equivalence-check`).
17
+ */
18
+ function assertNoInternalEntryPoints(entryPoints) {
19
+ const leaked = entryPoints.find((e) => e.tier === 'internal' || INTERNAL_COMMAND_NAME_RE.test(e.command));
20
+ if (leaked !== undefined) {
21
+ throw new Error(`agent-catalog: Tier-3 internal command '${leaked.command}' must not appear in the ` +
22
+ 'agent-catalog primary surface (tool-command-surface-taxonomy). Remove it from entryPoints.');
23
+ }
24
+ }
1
25
  export function buildAgentCatalog() {
26
+ // tool-command-surface-taxonomy Task 1.4: every entry point is annotated with
27
+ // its taxonomy `tier` so an agent sees the predictable Tier-1/Tier-2 shape, and
28
+ // NO Tier-3 internal worker is catalogued. The static list below is the
29
+ // primary surface; `assertNoInternalEntryPoints` guards (by construction)
30
+ // against a future edit pasting an internal command in (the Phase 4 test
31
+ // also asserts this).
32
+ const entryPoints = [
33
+ {
34
+ command: 'fit',
35
+ description: 'Run fitness checks. Use --json for machine output (SignalEnvelope).',
36
+ examples: ['opensip fit --recipe default --json', 'opensip fit --check some-check --json'],
37
+ tier: 'tool',
38
+ },
39
+ {
40
+ command: 'graph',
41
+ description: 'Build static call graph + rules. --json yields SignalEnvelope.',
42
+ examples: ['opensip graph --json', 'opensip graph --sarif out.sarif'],
43
+ tier: 'tool',
44
+ },
45
+ {
46
+ command: 'sessions list',
47
+ description: 'List stored sessions. --summary-only is agent-friendly (omits heavy payloads).',
48
+ examples: [
49
+ 'opensip sessions list --json --summary-only',
50
+ 'opensip sessions list --json --tool fit --limit 5',
51
+ ],
52
+ tier: 'platform',
53
+ },
54
+ {
55
+ command: 'sessions show',
56
+ description: 'Retrieve a prior run as SessionReplayResult (includes projected SignalEnvelope). ' +
57
+ 'Supports latest + --tool and rich filtering.',
58
+ examples: [
59
+ 'opensip sessions show latest --tool fit --json',
60
+ 'opensip sessions show latest --tool fit --json --filter errors-only --filter top:20',
61
+ 'opensip sessions show GRAPH_01... --json --raw',
62
+ 'opensip sessions show previous --tool graph --json',
63
+ ],
64
+ tier: 'platform',
65
+ },
66
+ {
67
+ command: 'agent-catalog',
68
+ description: 'This command. Self-describing catalog for agents (JSON preferred).',
69
+ examples: ['opensip agent-catalog --json'],
70
+ tier: 'platform',
71
+ },
72
+ ];
73
+ assertNoInternalEntryPoints(entryPoints);
2
74
  return {
3
75
  version: '1.0.0',
4
76
  description: 'Stable, machine-oriented surface for AI agents using OpenSIP CLI. ' +
5
77
  'Focus on --json paths, sessions for historical results, and composable filters. ' +
6
78
  'Human UX (tables, banners) is preserved unchanged.',
7
- entryPoints: [
8
- {
9
- command: 'fit',
10
- description: 'Run fitness checks. Use --json for machine output (SignalEnvelope).',
11
- examples: ['opensip fit --recipe default --json', 'opensip fit --check some-check --json'],
12
- },
13
- {
14
- command: 'graph',
15
- description: 'Build static call graph + rules. --json yields SignalEnvelope.',
16
- examples: ['opensip graph --json', 'opensip graph --sarif out.sarif'],
17
- },
18
- {
19
- command: 'sessions list',
20
- description: 'List stored sessions. --summary-only is agent-friendly (omits heavy payloads).',
21
- examples: [
22
- 'opensip sessions list --json --summary-only',
23
- 'opensip sessions list --json --tool fit --limit 5',
24
- ],
25
- },
26
- {
27
- command: 'sessions show',
28
- description: 'Retrieve a prior run as SessionReplayResult (includes projected SignalEnvelope). ' +
29
- 'Supports latest + --tool and rich filtering.',
30
- examples: [
31
- 'opensip sessions show latest --tool fit --json',
32
- 'opensip sessions show latest --tool fit --json --filter errors-only --filter top:20',
33
- 'opensip sessions show GRAPH_01... --json --raw',
34
- 'opensip sessions show previous --tool graph --json',
35
- ],
36
- },
37
- {
38
- command: 'agent-catalog',
39
- description: 'This command. Self-describing catalog for agents (JSON preferred).',
40
- examples: ['opensip agent-catalog --json'],
41
- },
42
- ],
79
+ entryPoints,
43
80
  commonPatterns: [
44
81
  {
45
82
  name: 'Inspect latest fit with focus on errors',
@@ -73,6 +110,10 @@ export function buildAgentCatalog() {
73
110
  'filtersApplied, originalSignalCount, returnedSignalCount appear when --filter is used.',
74
111
  'The fidelity field on replays is always "projection" (rebuilt from persisted data).',
75
112
  'Human-readable output (no --json) uses the same tables/banners as before — unchanged.',
113
+ // Uniform tool-primary surface (host-guaranteed; decorateToolPrimary).
114
+ 'Every tool primary (fit/graph/sim and any third-party tool) accepts `<tool> --version` ' +
115
+ '(prints the TOOL version, e.g. `fit 0.1.6`; distinct from `opensip --version`, the CLI), ' +
116
+ 'plus the guaranteed baseline flags --cwd, --json, --config, --quiet, --verbose.',
76
117
  'Dogfood gate requires 0 errors + 0 warnings on fit:ci and graph:ci after any change.',
77
118
  // Hygiene invariant (host-planes-scope-seams-hygiene Phases 2-4): everything runs inside an
78
119
  // entered RunScope; the only sanctioned seams for output, delivery, baselines, toolState,
@@ -1 +1 @@
1
- {"version":3,"file":"agent-catalog.js","sourceRoot":"","sources":["../../src/commands/agent-catalog.ts"],"names":[],"mappings":"AA+BA,MAAM,UAAU,iBAAiB;IAC/B,OAAO;QACL,OAAO,EAAE,OAAO;QAChB,WAAW,EACT,oEAAoE;YACpE,kFAAkF;YAClF,oDAAoD;QACtD,WAAW,EAAE;YACX;gBACE,OAAO,EAAE,KAAK;gBACd,WAAW,EAAE,qEAAqE;gBAClF,QAAQ,EAAE,CAAC,qCAAqC,EAAE,uCAAuC,CAAC;aAC3F;YACD;gBACE,OAAO,EAAE,OAAO;gBAChB,WAAW,EAAE,gEAAgE;gBAC7E,QAAQ,EAAE,CAAC,sBAAsB,EAAE,iCAAiC,CAAC;aACtE;YACD;gBACE,OAAO,EAAE,eAAe;gBACxB,WAAW,EACT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@@ -1 +1 @@
1
- {"version":3,"file":"clear.d.ts","sourceRoot":"","sources":["../../src/commands/clear.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAQH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,WAAW,YAAY;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE,OAAO,CAAC;IACb,SAAS,EAAE,SAAS,CAAC;CACtB;AAYD;;;;;;;;;GASG;AACH,wBAAsB,YAAY,CAAC,IAAI,EAAE,YAAY,GAAG,OAAO,CAAC,eAAe,CAAC,CAyC/E"}
1
+ {"version":3,"file":"clear.d.ts","sourceRoot":"","sources":["../../src/commands/clear.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAMH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAExD,MAAM,WAAW,YAAY;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE,OAAO,CAAC;IACb,SAAS,EAAE,SAAS,CAAC;CACtB;AAYD;;;;;;;;;GASG;AACH,wBAAsB,YAAY,CAAC,IAAI,EAAE,YAAY,GAAG,OAAO,CAAC,eAAe,CAAC,CAyC/E"}
@@ -11,7 +11,6 @@
11
11
  * Banners and result lines route through the Ink renderer via the
12
12
  * `clear-done` `CommandResult` shape — no raw ANSI escapes here.
13
13
  */
14
- // @fitness-ignore-file only-documented-toolcli-seams -- interactive TTY confirmation: the pre-prompt notes printed before "Continue? (y/n)" are human-readable readline UX, not machine run output through a ToolCliContext seam (mirrors the ESLint exemption for this file). Result lines route through the Ink `clear-done` CommandResult. (Architecture review finding 5.)
15
14
  import { createInterface } from 'node:readline';
16
15
  import { SessionRepo } from '@opensip-cli/session-store';
17
16
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