@cleocode/core 2026.10.18 → 2026.10.19

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 (259) hide show
  1. package/dist/build-provenance.json +2 -2
  2. package/dist/check/pr-gate.js +1 -1
  3. package/dist/check/pr-gate.js.map +1 -1
  4. package/dist/cloud/nexus-vault.d.ts +4 -3
  5. package/dist/cloud/nexus-vault.d.ts.map +1 -1
  6. package/dist/cloud/nexus-vault.js +62 -22
  7. package/dist/cloud/nexus-vault.js.map +1 -1
  8. package/dist/config.d.ts.map +1 -1
  9. package/dist/config.js +11 -0
  10. package/dist/config.js.map +1 -1
  11. package/dist/docs/conduit-history-backfill.d.ts +210 -0
  12. package/dist/docs/conduit-history-backfill.d.ts.map +1 -0
  13. package/dist/docs/conduit-history-backfill.js +451 -0
  14. package/dist/docs/conduit-history-backfill.js.map +1 -0
  15. package/dist/docs/docs-ops.d.ts +33 -0
  16. package/dist/docs/docs-ops.d.ts.map +1 -1
  17. package/dist/docs/docs-ops.js +72 -0
  18. package/dist/docs/docs-ops.js.map +1 -1
  19. package/dist/docs/docs-update.d.ts.map +1 -1
  20. package/dist/docs/docs-update.js +71 -0
  21. package/dist/docs/docs-update.js.map +1 -1
  22. package/dist/docs/doctor.d.ts +18 -4
  23. package/dist/docs/doctor.d.ts.map +1 -1
  24. package/dist/docs/doctor.js +124 -3
  25. package/dist/docs/doctor.js.map +1 -1
  26. package/dist/docs/section-merge.d.ts +70 -9
  27. package/dist/docs/section-merge.d.ts.map +1 -1
  28. package/dist/docs/section-merge.js +167 -10
  29. package/dist/docs/section-merge.js.map +1 -1
  30. package/dist/docs/section-write-path.d.ts.map +1 -1
  31. package/dist/docs/section-write-path.js +23 -8
  32. package/dist/docs/section-write-path.js.map +1 -1
  33. package/dist/gateway-client/generated/types.gen.d.ts +4 -0
  34. package/dist/gateway-client/generated/types.gen.d.ts.map +1 -1
  35. package/dist/go/driver.d.ts +29 -145
  36. package/dist/go/driver.d.ts.map +1 -1
  37. package/dist/go/driver.js +75 -168
  38. package/dist/go/driver.js.map +1 -1
  39. package/dist/go/index.d.ts +1 -1
  40. package/dist/go/index.d.ts.map +1 -1
  41. package/dist/go/index.js +1 -1
  42. package/dist/go/index.js.map +1 -1
  43. package/dist/goal/close.d.ts +1 -1
  44. package/dist/goal/close.js +2 -2
  45. package/dist/goal/close.js.map +1 -1
  46. package/dist/goal/draft.d.ts +10 -3
  47. package/dist/goal/draft.d.ts.map +1 -1
  48. package/dist/goal/draft.js +14 -9
  49. package/dist/goal/draft.js.map +1 -1
  50. package/dist/goal/index.d.ts +9 -12
  51. package/dist/goal/index.d.ts.map +1 -1
  52. package/dist/goal/index.js +9 -12
  53. package/dist/goal/index.js.map +1 -1
  54. package/dist/goal/runtime.d.ts +126 -0
  55. package/dist/goal/runtime.d.ts.map +1 -0
  56. package/dist/goal/runtime.js +289 -0
  57. package/dist/goal/runtime.js.map +1 -0
  58. package/dist/goal/status.d.ts +39 -0
  59. package/dist/goal/status.d.ts.map +1 -0
  60. package/dist/goal/status.js +101 -0
  61. package/dist/goal/status.js.map +1 -0
  62. package/dist/hooks/project-runner.d.ts +8 -3
  63. package/dist/hooks/project-runner.d.ts.map +1 -1
  64. package/dist/hooks/project-runner.js +104 -14
  65. package/dist/hooks/project-runner.js.map +1 -1
  66. package/dist/hooks/project-state.js +1 -1
  67. package/dist/hooks/project-state.js.map +1 -1
  68. package/dist/internal.d.ts +7 -3
  69. package/dist/internal.d.ts.map +1 -1
  70. package/dist/internal.js +5 -3
  71. package/dist/internal.js.map +1 -1
  72. package/dist/lifecycle/engine-ops.d.ts.map +1 -1
  73. package/dist/lifecycle/engine-ops.js +9 -6
  74. package/dist/lifecycle/engine-ops.js.map +1 -1
  75. package/dist/memory/retrieval/observe.d.ts.map +1 -1
  76. package/dist/memory/retrieval/observe.js +4 -8
  77. package/dist/memory/retrieval/observe.js.map +1 -1
  78. package/dist/paths.d.ts.map +1 -1
  79. package/dist/paths.js +4 -1
  80. package/dist/paths.js.map +1 -1
  81. package/dist/playbooks/cantbook-profile.d.ts +3 -3
  82. package/dist/playbooks/cantbook-profile.js +3 -3
  83. package/dist/playbooks/pi-runner-wiring.d.ts +3 -3
  84. package/dist/playbooks/pi-runner-wiring.js +3 -3
  85. package/dist/release/ci-evidence.d.ts +28 -0
  86. package/dist/release/ci-evidence.d.ts.map +1 -1
  87. package/dist/release/ci-evidence.js +76 -20
  88. package/dist/release/ci-evidence.js.map +1 -1
  89. package/dist/release/open.d.ts +11 -0
  90. package/dist/release/open.d.ts.map +1 -1
  91. package/dist/release/open.js +49 -10
  92. package/dist/release/open.js.map +1 -1
  93. package/dist/release/preflight-skip.d.ts +50 -0
  94. package/dist/release/preflight-skip.d.ts.map +1 -1
  95. package/dist/release/preflight-skip.js +151 -34
  96. package/dist/release/preflight-skip.js.map +1 -1
  97. package/dist/release/reconcile.d.ts.map +1 -1
  98. package/dist/release/reconcile.js +6 -3
  99. package/dist/release/reconcile.js.map +1 -1
  100. package/dist/scaffold/ensure-config.d.ts +1 -1
  101. package/dist/scaffold/ensure-config.d.ts.map +1 -1
  102. package/dist/scaffold/ensure-config.js +2 -0
  103. package/dist/scaffold/ensure-config.js.map +1 -1
  104. package/dist/security/index.d.ts +1 -1
  105. package/dist/security/index.d.ts.map +1 -1
  106. package/dist/security/index.js +1 -1
  107. package/dist/security/index.js.map +1 -1
  108. package/dist/security/override-cap-setting.d.ts +180 -0
  109. package/dist/security/override-cap-setting.d.ts.map +1 -0
  110. package/dist/security/override-cap-setting.js +657 -0
  111. package/dist/security/override-cap-setting.js.map +1 -0
  112. package/dist/security/override-cap.d.ts +20 -29
  113. package/dist/security/override-cap.d.ts.map +1 -1
  114. package/dist/security/override-cap.js +47 -71
  115. package/dist/security/override-cap.js.map +1 -1
  116. package/dist/security/owner-override-auth.d.ts +58 -0
  117. package/dist/security/owner-override-auth.d.ts.map +1 -1
  118. package/dist/security/owner-override-auth.js +82 -1
  119. package/dist/security/owner-override-auth.js.map +1 -1
  120. package/dist/security/owner-override-authority.d.ts +67 -0
  121. package/dist/security/owner-override-authority.d.ts.map +1 -0
  122. package/dist/security/owner-override-authority.js +100 -0
  123. package/dist/security/owner-override-authority.js.map +1 -0
  124. package/dist/sessions/handoff.d.ts.map +1 -1
  125. package/dist/sessions/handoff.js +4 -5
  126. package/dist/sessions/handoff.js.map +1 -1
  127. package/dist/sessions/index.d.ts.map +1 -1
  128. package/dist/sessions/index.js +22 -25
  129. package/dist/sessions/index.js.map +1 -1
  130. package/dist/store/conduit-doc-history.d.ts +39 -7
  131. package/dist/store/conduit-doc-history.d.ts.map +1 -1
  132. package/dist/store/conduit-doc-history.js +62 -12
  133. package/dist/store/conduit-doc-history.js.map +1 -1
  134. package/dist/store/data-safety-central.d.ts.map +1 -1
  135. package/dist/store/data-safety-central.js +3 -2
  136. package/dist/store/data-safety-central.js.map +1 -1
  137. package/dist/store/json.d.ts.map +1 -1
  138. package/dist/store/json.js +7 -7
  139. package/dist/store/json.js.map +1 -1
  140. package/dist/store/portable-bundle-scan.d.ts +23 -1
  141. package/dist/store/portable-bundle-scan.d.ts.map +1 -1
  142. package/dist/store/portable-bundle-scan.js +85 -3
  143. package/dist/store/portable-bundle-scan.js.map +1 -1
  144. package/dist/store/portable-bundle.d.ts.map +1 -1
  145. package/dist/store/portable-bundle.js +6 -1
  146. package/dist/store/portable-bundle.js.map +1 -1
  147. package/dist/store/row-identity-registry.d.ts +5 -3
  148. package/dist/store/row-identity-registry.d.ts.map +1 -1
  149. package/dist/store/row-identity-registry.js +54 -38
  150. package/dist/store/row-identity-registry.js.map +1 -1
  151. package/dist/store/schema/cleo-project/conduit.d.ts.map +1 -1
  152. package/dist/store/schema/cleo-project/conduit.js +4 -3
  153. package/dist/store/schema/cleo-project/conduit.js.map +1 -1
  154. package/dist/store/schema/cleo-project/runtime.d.ts +32 -0
  155. package/dist/store/schema/cleo-project/runtime.d.ts.map +1 -1
  156. package/dist/store/schema/cleo-project/runtime.js +7 -3
  157. package/dist/store/schema/cleo-project/runtime.js.map +1 -1
  158. package/dist/store/session-store.d.ts +45 -0
  159. package/dist/store/session-store.d.ts.map +1 -1
  160. package/dist/store/session-store.js +96 -1
  161. package/dist/store/session-store.js.map +1 -1
  162. package/dist/store/sqlite.d.ts +2 -0
  163. package/dist/store/sqlite.d.ts.map +1 -1
  164. package/dist/store/sqlite.js +12 -0
  165. package/dist/store/sqlite.js.map +1 -1
  166. package/dist/store/sync/merge/rules.d.ts.map +1 -1
  167. package/dist/store/sync/merge/rules.js +0 -16
  168. package/dist/store/sync/merge/rules.js.map +1 -1
  169. package/dist/store/sync/sealer.d.ts.map +1 -1
  170. package/dist/store/sync/sealer.js +27 -1
  171. package/dist/store/sync/sealer.js.map +1 -1
  172. package/dist/store/sync/sequencing.d.ts +3 -1
  173. package/dist/store/sync/sequencing.d.ts.map +1 -1
  174. package/dist/store/sync/sequencing.js +5 -3
  175. package/dist/store/sync/sequencing.js.map +1 -1
  176. package/dist/store/sync/timestamp-canon.d.ts.map +1 -1
  177. package/dist/store/sync/timestamp-canon.js +4 -0
  178. package/dist/store/sync/timestamp-canon.js.map +1 -1
  179. package/dist/store/table-classification.d.ts.map +1 -1
  180. package/dist/store/table-classification.js +12 -8
  181. package/dist/store/table-classification.js.map +1 -1
  182. package/dist/store/twin-collapse.d.ts +21 -0
  183. package/dist/store/twin-collapse.d.ts.map +1 -1
  184. package/dist/store/twin-collapse.js +235 -18
  185. package/dist/store/twin-collapse.js.map +1 -1
  186. package/dist/system/health.d.ts +17 -0
  187. package/dist/system/health.d.ts.map +1 -1
  188. package/dist/system/health.js +96 -0
  189. package/dist/system/health.js.map +1 -1
  190. package/dist/tasks/affected-packages.d.ts +67 -2
  191. package/dist/tasks/affected-packages.d.ts.map +1 -1
  192. package/dist/tasks/affected-packages.js +149 -21
  193. package/dist/tasks/affected-packages.js.map +1 -1
  194. package/dist/tasks/affected-scope.d.ts.map +1 -1
  195. package/dist/tasks/affected-scope.js +91 -5
  196. package/dist/tasks/affected-scope.js.map +1 -1
  197. package/dist/tasks/changeset-plan.d.ts +33 -0
  198. package/dist/tasks/changeset-plan.d.ts.map +1 -0
  199. package/dist/tasks/changeset-plan.js +152 -0
  200. package/dist/tasks/changeset-plan.js.map +1 -0
  201. package/dist/tasks/complete.d.ts.map +1 -1
  202. package/dist/tasks/complete.js +9 -1
  203. package/dist/tasks/complete.js.map +1 -1
  204. package/dist/tasks/done-plan.d.ts.map +1 -1
  205. package/dist/tasks/done-plan.js +28 -14
  206. package/dist/tasks/done-plan.js.map +1 -1
  207. package/dist/tasks/done-record.d.ts.map +1 -1
  208. package/dist/tasks/done-record.js +5 -1
  209. package/dist/tasks/done-record.js.map +1 -1
  210. package/dist/tasks/evidence.d.ts.map +1 -1
  211. package/dist/tasks/evidence.js +149 -18
  212. package/dist/tasks/evidence.js.map +1 -1
  213. package/dist/tasks/gate-runner.d.ts.map +1 -1
  214. package/dist/tasks/gate-runner.js +76 -4
  215. package/dist/tasks/gate-runner.js.map +1 -1
  216. package/dist/tasks/qa-run-binding.d.ts +18 -0
  217. package/dist/tasks/qa-run-binding.d.ts.map +1 -1
  218. package/dist/tasks/qa-run-binding.js +41 -1
  219. package/dist/tasks/qa-run-binding.js.map +1 -1
  220. package/dist/tasks/test-run-binding.d.ts +62 -0
  221. package/dist/tasks/test-run-binding.d.ts.map +1 -1
  222. package/dist/tasks/test-run-binding.js +126 -21
  223. package/dist/tasks/test-run-binding.js.map +1 -1
  224. package/dist/tasks/tool-resolver.d.ts +7 -0
  225. package/dist/tasks/tool-resolver.d.ts.map +1 -1
  226. package/dist/tasks/tool-resolver.js +3 -1
  227. package/dist/tasks/tool-resolver.js.map +1 -1
  228. package/dist/validation/engine-ops.d.ts.map +1 -1
  229. package/dist/validation/engine-ops.js +24 -29
  230. package/dist/validation/engine-ops.js.map +1 -1
  231. package/migrations/drizzle-cleo-project/20261016120000_t12535-playbook-row-uids/migration.sql +24 -0
  232. package/package.json +13 -13
  233. package/schemas/project-context.schema.json +5 -0
  234. package/templates/CLEO-INJECTION.md +1 -1
  235. package/templates/CLEO-REFERENCE.md +42 -1
  236. package/templates/cleo-gitignore +3 -0
  237. package/templates/git-hooks/legacy-hashes.json +1 -0
  238. package/templates/git-hooks/pre-push +35 -7
  239. package/templates/workflows/release-prepare.yml.tmpl +82 -4
  240. package/dist/goal/advance-with-persist.d.ts +0 -80
  241. package/dist/goal/advance-with-persist.d.ts.map +0 -1
  242. package/dist/goal/advance-with-persist.js +0 -105
  243. package/dist/goal/advance-with-persist.js.map +0 -1
  244. package/dist/goal/arm.d.ts +0 -61
  245. package/dist/goal/arm.d.ts.map +0 -1
  246. package/dist/goal/arm.js +0 -65
  247. package/dist/goal/arm.js.map +0 -1
  248. package/dist/goal/continuation.d.ts +0 -66
  249. package/dist/goal/continuation.d.ts.map +0 -1
  250. package/dist/goal/continuation.js +0 -111
  251. package/dist/goal/continuation.js.map +0 -1
  252. package/dist/goal/judge.d.ts +0 -113
  253. package/dist/goal/judge.d.ts.map +0 -1
  254. package/dist/goal/judge.js +0 -193
  255. package/dist/goal/judge.js.map +0 -1
  256. package/dist/goal/loop.d.ts +0 -75
  257. package/dist/goal/loop.d.ts.map +0 -1
  258. package/dist/goal/loop.js +0 -132
  259. package/dist/goal/loop.js.map +0 -1
@@ -5,11 +5,10 @@
5
5
  * It is PURE GLUE: it sequences existing core engines without adding new
6
6
  * orchestration math.
7
7
  *
8
- * ## Pipeline (AC1)
8
+ * ## Pipeline
9
9
  *
10
10
  * ```
11
- * briefing (optional context anchor)
12
- * → sagaNext() — pick highest-priority non-terminal saga
11
+ * sagaNext() — pick highest-priority non-terminal saga
13
12
  * → orchestrateReady(sagaId) — fetch readyFrontier
14
13
  * → branch on pipelineStage of the active epic:
15
14
  * AC-only (no children, research stage)
@@ -17,36 +16,20 @@
17
16
  * research | specification | decomposition
18
17
  * → { action: 'lifecycleHop', sagaId, epicId, currentStage }
19
18
  * implementation | validation | testing | release | contribution
20
- * → fan-out the injected IVTR runner over readyFrontier tasks
21
- * → { action: 'ivtrFanOut', sagaId, epicId, tasks: string[], runIds: string[] }
19
+ * → draft a goal/v1 contract for the ready wave and hand it to the
20
+ * goal runtime (CLEO Goal) in the current harness
21
+ * → { action: 'goalHandoff', sagaId, epicId, tasks, goal, runtime }
22
22
  * → return ONE LAFS-compatible EngineResult envelope
23
23
  * ```
24
24
  *
25
- * ## IVTR seam (T11805 · T11896 · E-ORCH-STATE-MACHINE-COLLAPSE / T11764)
25
+ * ## Goal handoff (T13821 · owner decision 2026-10-16 · ADR-097)
26
26
  *
27
- * The implementation+ branch is gated by {@link CLEO_GO_VIA_PLAYBOOK_ENV}, which
28
- * now defaults **ON** (T11896): the cantbook runtime is the shipped survivor
29
- * state machine and `cleo go` drives IVTR through it. The flag is retained for
30
- * **one deprecation cycle** as an opt-OUT kill-switch — set
31
- * `CLEO_GO_VIA_PLAYBOOK=0` (or `false`/`no`/`off`) to restore the legacy
32
- * `ivtr_state` seed (`seedIvtrForPlaybook`, byte-identical to the retired
33
- * `startIvtr`) for a single release if a cantbook-path regression surfaces.
34
- *
35
- * - **Flag ON (default)** — fan out an injected {@link IvtrRunner} — supplied
36
- * by the CLI `cleo go` handler — that drives each task through
37
- * `executePlaybook(ivtr.cantbook)` (the cantbook runtime, the survivor state
38
- * machine) AND mirrors the run's terminal status back into `ivtr_state`
39
- * (`finalizeIvtrFromPlaybook`) so the strict `E_IVTR_INCOMPLETE` completion
40
- * gate reflects the cantbook run. The runtime's
41
- * `on_failure.inject_into: implement` edge reproduces the IVTR loop-back walk.
42
- * - **Flag OFF (opt-out kill-switch)** OR **no runner injected** — seed each
43
- * ready task's `ivtr_state` via `seedIvtrForPlaybook` (byte-identical to the
44
- * retired `startIvtr` seed); the seam is a no-op. This fallback is retained
45
- * for one release so a cantbook-path regression can never strand autopilot.
46
- *
47
- * The driver stays in `@cleocode/core` and must NOT import `@cleocode/playbooks`
48
- * (that would invert the package dependency), so the runtime call is injected
49
- * as a callback rather than referenced directly.
27
+ * CLEO owns the goal protocol; CLEO Goal is the goal runtime. `cleo go`
28
+ * no longer drives an IVTR loop itself: for implementation-stage work it runs
29
+ * `cleo goal draft` over the ready wave (reusing a draft that already exists,
30
+ * never overwriting it) and returns the exact next step: `/goal start <slug>`
31
+ * when the CLEO Goal bin (`cleo-goal`, then `ocg`) resolves, otherwise the
32
+ * commands that install it (project-scoped; never user-global harness config).
50
33
  *
51
34
  * ## Design constraints
52
35
  *
@@ -61,81 +44,8 @@
61
44
  * @task T11494 — E2-CLEO-GO
62
45
  * @saga T11492 — SG-AUTOPILOT
63
46
  */
64
- import type { TaskViewPipelineStage } from '@cleocode/contracts';
47
+ import type { GoalRuntimeHandoff, TaskViewPipelineStage } from '@cleocode/contracts';
65
48
  import { type EngineResult } from '../engine-result.js';
66
- /**
67
- * Feature-flag env var gating the cantbook IVTR seam (T11805 · T11896 ·
68
- * collapse-plan Risk Register §7 row #1).
69
- *
70
- * As of T11896 the cantbook runtime is the **shipped default** — the flag now
71
- * defaults **ON** and is retained for one deprecation cycle purely as an
72
- * opt-OUT kill-switch. When unset (or any truthy value) the implementation-stage
73
- * branch drives the injected {@link IvtrRunner}
74
- * (`executePlaybook(ivtr.cantbook)`). Set `CLEO_GO_VIA_PLAYBOOK=0` (or
75
- * `false`/`no`/`off`) to restore the legacy `seedIvtrForPlaybook` seed
76
- * (byte-identical to the retired `startIvtr`) for a single release if a
77
- * cantbook-path regression surfaces. The kill-switch is removed in a follow-up
78
- * once the cantbook path has baked.
79
- */
80
- export declare const CLEO_GO_VIA_PLAYBOOK_ENV: "CLEO_GO_VIA_PLAYBOOK";
81
- /**
82
- * Outcome of a single IVTR playbook run started by the seam (T11805).
83
- *
84
- * Returned by {@link IvtrRunner} so the driver can both report the started
85
- * task and surface the `playbook_runs.run_id` for resume-on-next-turn.
86
- *
87
- * @task T11805 — E-ORCH-STATE-MACHINE-COLLAPSE / T11764
88
- */
89
- export interface IvtrRunResult {
90
- /** The task whose `ivtr.cantbook` run was started. */
91
- taskId: string;
92
- /**
93
- * The `playbook_runs.run_id` of the started run, when the runtime created
94
- * one. Absent only when the runner cannot reach a run id (e.g. a pre-flight
95
- * failure before the run row is written).
96
- */
97
- runId?: string;
98
- /**
99
- * Terminal status reported by the cantbook runtime for this turn, when the
100
- * run reached a terminal node (`completed | failed | pending_approval |
101
- * exceeded_iteration_cap`). Absent when the runner only seeded the run.
102
- */
103
- terminalStatus?: string;
104
- }
105
- /**
106
- * Options handed to an {@link IvtrRunner} for a single task.
107
- *
108
- * @task T11805
109
- */
110
- export interface IvtrRunnerOptions {
111
- /** Resolved project root for playbook resolution + audit writes. */
112
- projectRoot: string;
113
- /**
114
- * Session id persisted onto `playbook_runs.session_id` (evidence/provenance
115
- * gate parameter). Absent when no session is active.
116
- */
117
- sessionId?: string;
118
- /** Parent epic id persisted onto `playbook_runs.epic_id` for dashboards. */
119
- epicId?: string;
120
- }
121
- /**
122
- * Injected callback that drives one task's IVTR loop through the cantbook
123
- * runtime (`executePlaybook(ivtr.cantbook)`).
124
- *
125
- * The driver lives in `@cleocode/core`, which must not depend on
126
- * `@cleocode/playbooks`; the runtime call is therefore injected by the CLI
127
- * `cleo go` handler (which already imports `@cleocode/playbooks`). The runner
128
- * is responsible for:
129
- * - resolving + parsing `ivtr.cantbook`,
130
- * - seeding `initialContext = { taskId }`,
131
- * - calling `executePlaybook` with `taskId` (via context) + `sessionId` +
132
- * the evidence-gate parameters the cantbook encodes,
133
- * - keeping `tasks.ivtr_state` populated so the strict `E_IVTR_INCOMPLETE`
134
- * completion gate stays load-bearing (collapse-plan §3 item 4).
135
- *
136
- * @task T11805
137
- */
138
- export type IvtrRunner = (taskId: string, options: IvtrRunnerOptions) => Promise<IvtrRunResult>;
139
49
  /**
140
50
  * Input parameters for {@link cleoGo}.
141
51
  *
@@ -154,30 +64,16 @@ export interface CleoGoParams {
154
64
  headless?: boolean;
155
65
  /** Override project root (useful in tests). */
156
66
  projectRoot?: string;
157
- /**
158
- * Drives each ready task through `executePlaybook(ivtr.cantbook)` — the
159
- * shipped default path (T11896) gated by {@link CLEO_GO_VIA_PLAYBOOK_ENV}.
160
- * Injected by the CLI handler so the core driver never imports the playbooks
161
- * runtime. When the kill-switch is set (`CLEO_GO_VIA_PLAYBOOK=0`) or this is
162
- * omitted, the driver falls back to the legacy `seedIvtrForPlaybook` seed for
163
- * the implementation+ branch (no behaviour is silently skipped).
164
- */
165
- ivtrRunner?: IvtrRunner;
166
- /**
167
- * Session id forwarded to {@link IvtrRunner} for `playbook_runs.session_id`
168
- * provenance. Best-effort; absent when no session is active.
169
- */
170
- sessionId?: string;
171
67
  }
172
68
  /**
173
- * Discriminated union of the four action outcomes `cleoGo` can produce.
69
+ * Discriminated union of the action outcomes `cleoGo` can produce.
174
70
  *
175
71
  * Consumers pattern-match on `action` to route further processing.
176
72
  *
177
73
  * @task T11494
178
74
  */
179
75
  export type CleoGoAction = {
180
- /** No children + research stage — the epic needs decomposition before IVTR. */
76
+ /** No children + research stage — the epic needs decomposition first. */
181
77
  action: 'needsDecomposition';
182
78
  sagaId: string;
183
79
  /** The AC-only epic that needs task children added. */
@@ -194,24 +90,23 @@ export type CleoGoAction = {
194
90
  readyFrontier: string[];
195
91
  } | {
196
92
  /**
197
- * Fan-out: an IVTR cantbook run was started for each task on the ready
198
- * frontier (T11805 — `executePlaybook(ivtr.cantbook)`, no longer
199
- * `startIvtr`).
93
+ * Implementation-stage work handed to the goal runtime: a goal/v1
94
+ * contract drafted for the ready wave (T13821).
200
95
  */
201
- action: 'ivtrFanOut';
96
+ action: 'goalHandoff';
202
97
  sagaId: string;
203
98
  epicId: string;
204
99
  currentStage: TaskViewPipelineStage;
205
- /** Task IDs for which an IVTR playbook run was initiated. */
100
+ /** The ready wave the goal serves. */
206
101
  tasks: string[];
207
- /**
208
- * `playbook_runs.run_id` for each started run, positionally aligned to
209
- * the tasks that produced one. Lets the autopilot resume paused runs on
210
- * the next turn.
211
- *
212
- * @task T11805
213
- */
214
- runIds: string[];
102
+ /** The drafted (or already drafted) goal, or null when none could be drafted. */
103
+ goal: {
104
+ slug: string;
105
+ path: string;
106
+ reused: boolean;
107
+ } | null;
108
+ /** The goal runtime and the exact next step in the current harness. */
109
+ runtime: GoalRuntimeHandoff;
215
110
  } | {
216
111
  /** No non-terminal sagas remain — the workgraph is complete. */
217
112
  action: 'complete';
@@ -220,7 +115,6 @@ export type CleoGoAction = {
220
115
  * Result payload for {@link cleoGo}.
221
116
  *
222
117
  * @task T11494
223
- * @task T11496 E4-GOAL-LOOP
224
118
  */
225
119
  export interface CleoGoResult {
226
120
  /** The action taken by the driver in this turn. */
@@ -229,23 +123,13 @@ export interface CleoGoResult {
229
123
  * Structured diagnostics for display / logging. Always present; may be empty.
230
124
  */
231
125
  diagnostics: string[];
232
- /**
233
- * The id of the goal that was armed (or reused) for the Stop-hook loop.
234
- *
235
- * `null` when no saga was selected (workgraph `complete` action) — there is
236
- * nothing to arm when the workgraph is already done.
237
- *
238
- * @task T11496
239
- */
240
- armedGoalId: string | null;
241
126
  }
242
127
  /**
243
128
  * Run one turn of the `cleo go` autopilot pipeline.
244
129
  *
245
130
  * Returns a single LAFS-compatible {@link EngineResult} wrapping a
246
- * {@link CleoGoResult}. Each call is stateless (side effects — IVTR cantbook
247
- * runs via the injected {@link IvtrRunner}, lifecycle progression — happen
248
- * inside the called engines); the driver itself carries no mutable state.
131
+ * {@link CleoGoResult}. Its only side effect is drafting a goal/v1 contract for
132
+ * the ready wave (never overwriting one); the driver carries no mutable state.
249
133
  *
250
134
  * @param params - Input parameters controlling the saga scope and mode.
251
135
  * @returns EngineResult with {@link CleoGoResult}.
@@ -1 +1 @@
1
- {"version":3,"file":"driver.d.ts","sourceRoot":"","sources":["../../src/go/driver.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8DG;AAEH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,qBAA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core engines without adding new
6
6
  * orchestration math.
7
7
  *
8
- * ## Pipeline (AC1)
8
+ * ## Pipeline
9
9
  *
10
10
  * ```
11
- * briefing (optional context anchor)
12
- * → sagaNext() — pick highest-priority non-terminal saga
11
+ * sagaNext() — pick highest-priority non-terminal saga
13
12
  * → orchestrateReady(sagaId) — fetch readyFrontier
14
13
  * → branch on pipelineStage of the active epic:
15
14
  * AC-only (no children, research stage)
@@ -17,36 +16,20 @@
17
16
  * research | specification | decomposition
18
17
  * → { action: 'lifecycleHop', sagaId, epicId, currentStage }
19
18
  * implementation | validation | testing | release | contribution
20
- * → fan-out the injected IVTR runner over readyFrontier tasks
21
- * → { action: 'ivtrFanOut', sagaId, epicId, tasks: string[], runIds: string[] }
19
+ * → draft a goal/v1 contract for the ready wave and hand it to the
20
+ * goal runtime (CLEO Goal) in the current harness
21
+ * → { action: 'goalHandoff', sagaId, epicId, tasks, goal, runtime }
22
22
  * → return ONE LAFS-compatible EngineResult envelope
23
23
  * ```
24
24
  *
25
- * ## IVTR seam (T11805 · T11896 · E-ORCH-STATE-MACHINE-COLLAPSE / T11764)
25
+ * ## Goal handoff (T13821 · owner decision 2026-10-16 · ADR-097)
26
26
  *
27
- * The implementation+ branch is gated by {@link CLEO_GO_VIA_PLAYBOOK_ENV}, which
28
- * now defaults **ON** (T11896): the cantbook runtime is the shipped survivor
29
- * state machine and `cleo go` drives IVTR through it. The flag is retained for
30
- * **one deprecation cycle** as an opt-OUT kill-switch — set
31
- * `CLEO_GO_VIA_PLAYBOOK=0` (or `false`/`no`/`off`) to restore the legacy
32
- * `ivtr_state` seed (`seedIvtrForPlaybook`, byte-identical to the retired
33
- * `startIvtr`) for a single release if a cantbook-path regression surfaces.
34
- *
35
- * - **Flag ON (default)** — fan out an injected {@link IvtrRunner} — supplied
36
- * by the CLI `cleo go` handler — that drives each task through
37
- * `executePlaybook(ivtr.cantbook)` (the cantbook runtime, the survivor state
38
- * machine) AND mirrors the run's terminal status back into `ivtr_state`
39
- * (`finalizeIvtrFromPlaybook`) so the strict `E_IVTR_INCOMPLETE` completion
40
- * gate reflects the cantbook run. The runtime's
41
- * `on_failure.inject_into: implement` edge reproduces the IVTR loop-back walk.
42
- * - **Flag OFF (opt-out kill-switch)** OR **no runner injected** — seed each
43
- * ready task's `ivtr_state` via `seedIvtrForPlaybook` (byte-identical to the
44
- * retired `startIvtr` seed); the seam is a no-op. This fallback is retained
45
- * for one release so a cantbook-path regression can never strand autopilot.
46
- *
47
- * The driver stays in `@cleocode/core` and must NOT import `@cleocode/playbooks`
48
- * (that would invert the package dependency), so the runtime call is injected
49
- * as a callback rather than referenced directly.
27
+ * CLEO owns the goal protocol; CLEO Goal is the goal runtime. `cleo go`
28
+ * no longer drives an IVTR loop itself: for implementation-stage work it runs
29
+ * `cleo goal draft` over the ready wave (reusing a draft that already exists,
30
+ * never overwriting it) and returns the exact next step: `/goal start <slug>`
31
+ * when the CLEO Goal bin (`cleo-goal`, then `ocg`) resolves, otherwise the
32
+ * commands that install it (project-scoped; never user-global harness config).
50
33
  *
51
34
  * ## Design constraints
52
35
  *
@@ -61,54 +44,22 @@
61
44
  * @task T11494 — E2-CLEO-GO
62
45
  * @saga T11492 — SG-AUTOPILOT
63
46
  */
47
+ import { existsSync } from 'node:fs';
48
+ import { join } from 'node:path';
64
49
  import { engineError, engineSuccess } from '../engine-result.js';
65
- import { armGoalLoop } from '../goal/arm.js';
66
- import { seedIvtrForPlaybook } from '../lifecycle/ivtr-loop.js';
50
+ import { GOAL_INSTALL_COMMAND, resolveGoalBin } from '../goal/runtime.js';
67
51
  import { orchestrateReady } from '../orchestrate/query-ops.js';
68
52
  import { getProjectRoot } from '../paths.js';
69
53
  import { sagaNext } from '../sagas/next.js';
70
- /**
71
- * Feature-flag env var gating the cantbook IVTR seam (T11805 · T11896 ·
72
- * collapse-plan Risk Register §7 row #1).
73
- *
74
- * As of T11896 the cantbook runtime is the **shipped default** — the flag now
75
- * defaults **ON** and is retained for one deprecation cycle purely as an
76
- * opt-OUT kill-switch. When unset (or any truthy value) the implementation-stage
77
- * branch drives the injected {@link IvtrRunner}
78
- * (`executePlaybook(ivtr.cantbook)`). Set `CLEO_GO_VIA_PLAYBOOK=0` (or
79
- * `false`/`no`/`off`) to restore the legacy `seedIvtrForPlaybook` seed
80
- * (byte-identical to the retired `startIvtr`) for a single release if a
81
- * cantbook-path regression surfaces. The kill-switch is removed in a follow-up
82
- * once the cantbook path has baked.
83
- */
84
- export const CLEO_GO_VIA_PLAYBOOK_ENV = 'CLEO_GO_VIA_PLAYBOOK';
85
- /**
86
- * Resolve whether the cantbook IVTR seam is enabled for this `cleo go` turn.
87
- *
88
- * Defaults **ON** (T11896): the seam is disabled only by an explicit opt-OUT
89
- * kill-switch value of {@link CLEO_GO_VIA_PLAYBOOK_ENV} (`'0'` | `'false'` |
90
- * `'no'` | `'off'`, case-insensitive). Unset — and every other value — keeps
91
- * the cantbook runtime engaged.
92
- *
93
- * @returns `false` only when the env var is an explicit falsy kill-switch
94
- * value; `true` otherwise (including when unset).
95
- */
96
- function isPlaybookSeamEnabled() {
97
- const raw = process.env[CLEO_GO_VIA_PLAYBOOK_ENV];
98
- if (raw === undefined)
99
- return true;
100
- const v = raw.trim().toLowerCase();
101
- return !(v === '0' || v === 'false' || v === 'no' || v === 'off');
102
- }
103
54
  // ---------------------------------------------------------------------------
104
55
  // Pre-implementation stage set
105
56
  // ---------------------------------------------------------------------------
106
57
  /**
107
- * Pipeline stages that require a lifecycle hop before spawning IVTR workers.
58
+ * Pipeline stages that require a lifecycle hop before implementation.
108
59
  *
109
60
  * Tasks whose parent epic is still in one of these stages are not yet
110
- * implementation-ready; the driver signals `lifecycleHop` instead of fanning
111
- * out IVTR.
61
+ * implementation-ready; the driver signals `lifecycleHop` instead of handing
62
+ * a goal to the runtime.
112
63
  */
113
64
  const PRE_IMPLEMENTATION_STAGES = new Set([
114
65
  'research',
@@ -122,9 +73,8 @@ const PRE_IMPLEMENTATION_STAGES = new Set([
122
73
  * Run one turn of the `cleo go` autopilot pipeline.
123
74
  *
124
75
  * Returns a single LAFS-compatible {@link EngineResult} wrapping a
125
- * {@link CleoGoResult}. Each call is stateless (side effects — IVTR cantbook
126
- * runs via the injected {@link IvtrRunner}, lifecycle progression — happen
127
- * inside the called engines); the driver itself carries no mutable state.
76
+ * {@link CleoGoResult}. Its only side effect is drafting a goal/v1 contract for
77
+ * the ready wave (never overwriting one); the driver carries no mutable state.
128
78
  *
129
79
  * @param params - Input parameters controlling the saga scope and mode.
130
80
  * @returns EngineResult with {@link CleoGoResult}.
@@ -146,27 +96,10 @@ export async function cleoGo(params = {}) {
146
96
  return engineSuccess({
147
97
  outcome: { action: 'complete' },
148
98
  diagnostics: ['No non-terminal sagas remain — workgraph is complete.'],
149
- armedGoalId: null,
150
99
  });
151
100
  }
152
101
  const sagaId = next.sagaId;
153
102
  diagnostics.push(`active saga: ${sagaId}${next.sagaTitle ? ` (${next.sagaTitle})` : ''} — ${next.completionPct ?? 0}% complete`);
154
- // 2b. Arm the goal loop (AC3 of T11496): create/reuse a per-saga goal that
155
- // the Stop-hook advances each turn to self-renudge until satisfied.
156
- // Best-effort: failure is non-fatal (diagnostics only).
157
- let armedGoalId = null;
158
- try {
159
- const armedGoal = await armGoalLoop({
160
- sagaId,
161
- sagaTitle: next.sagaTitle,
162
- cwd: root,
163
- });
164
- armedGoalId = armedGoal.id;
165
- diagnostics.push(`goal loop armed: ${armedGoalId}`);
166
- }
167
- catch (err) {
168
- diagnostics.push(`goal loop arm failed (non-fatal): ${err.message}`);
169
- }
170
103
  // 3. orchestrateReady — get the ready frontier for the saga.
171
104
  const readyResult = await orchestrateReady(sagaId, root);
172
105
  if (!readyResult.success) {
@@ -199,12 +132,11 @@ export async function cleoGo(params = {}) {
199
132
  currentStage,
200
133
  },
201
134
  diagnostics,
202
- armedGoalId,
203
135
  });
204
136
  }
205
137
  // 6. Pre-implementation stage check → lifecycle hop signal.
206
138
  if (PRE_IMPLEMENTATION_STAGES.has(currentStage)) {
207
- diagnostics.push(`epic ${epicId} is at stage '${currentStage}' — lifecycle hop required before IVTR`);
139
+ diagnostics.push(`epic ${epicId} is at stage '${currentStage}' — lifecycle hop required before implementation`);
208
140
  return engineSuccess({
209
141
  outcome: {
210
142
  action: 'lifecycleHop',
@@ -214,103 +146,78 @@ export async function cleoGo(params = {}) {
214
146
  readyFrontier,
215
147
  },
216
148
  diagnostics,
217
- armedGoalId,
218
149
  });
219
150
  }
220
- // 7. Implementation+ → fan-out the IVTR loop over the ready frontier.
221
- //
222
- // Two paths, gated by the CLEO_GO_VIA_PLAYBOOK feature flag (T11896 — the
223
- // cantbook runtime is now the shipped default; the flag is retained for one
224
- // cycle as an opt-OUT kill-switch):
225
- //
226
- // - Flag ON (default) AND a runner injected → drive each ready task through
227
- // `executePlaybook(ivtr.cantbook)` via the injected runner, which also
228
- // mirrors the terminal status back into `ivtr_state`. The runner is
229
- // injected by the CLI handler so the core driver never imports
230
- // `@cleocode/playbooks`. This is the shipped autopilot hot path.
231
- // - Flag OFF (kill-switch `CLEO_GO_VIA_PLAYBOOK=0`) OR no runner injected →
232
- // seed each ready task's `ivtr_state` via `seedIvtrForPlaybook`
233
- // (byte-identical to the retired `startIvtr` seed), retained one release.
234
- const ivtrStarted = [];
235
- const ivtrRunIds = [];
236
- const seamEnabled = isPlaybookSeamEnabled();
237
- if (!seamEnabled || !params.ivtrRunner) {
238
- // Fallback path: legacy `ivtr_state` seed (kill-switch set or no runner).
239
- if (params.ivtrRunner && !seamEnabled) {
240
- diagnostics.push(`IVTR cantbook seam disabled (${CLEO_GO_VIA_PLAYBOOK_ENV}=0 kill-switch) — using legacy fallback seed`);
241
- }
242
- else if (!params.ivtrRunner) {
243
- diagnostics.push('IVTR runner not provided — using legacy fallback seed');
244
- }
245
- for (const taskId of readyFrontier) {
246
- try {
247
- // The legacy seed is now `seedIvtrForPlaybook` — byte-identical to the
248
- // retired `startIvtr` (both share `buildInitialIvtrState`), so the
249
- // kill-switch fallback produces the same `ivtr_state` row while the
250
- // hand-rolled `startIvtr` walk function is deleted (T11896 AC3).
251
- await seedIvtrForPlaybook(taskId, { cwd: root });
252
- ivtrStarted.push(taskId);
253
- diagnostics.push(`IVTR seeded for ${taskId} (legacy fallback seed)`);
254
- }
255
- catch (err) {
256
- diagnostics.push(`IVTR seed failed for ${taskId}: ${err.message}`);
257
- }
258
- }
259
- if (ivtrStarted.length === 0 && readyFrontier.length > 0) {
260
- diagnostics.push(`All ${readyFrontier.length} IVTR starts failed — see diagnostics`);
261
- }
262
- else {
263
- diagnostics.push(`IVTR started for ${ivtrStarted.length} task(s): ${ivtrStarted.join(', ')}`);
264
- }
151
+ // 7. Implementation+ → draft a goal for the ready wave and hand it to the runtime.
152
+ const runtime = goalRuntimeHandoff(null);
153
+ if (readyFrontier.length === 0) {
154
+ diagnostics.push(`epic ${epicId} has no ready tasks — nothing to hand to the goal runtime`);
265
155
  return engineSuccess({
266
156
  outcome: {
267
- action: 'ivtrFanOut',
157
+ action: 'goalHandoff',
268
158
  sagaId,
269
159
  epicId,
270
160
  currentStage,
271
- tasks: ivtrStarted,
272
- runIds: ivtrRunIds,
161
+ tasks: [],
162
+ goal: null,
163
+ runtime,
273
164
  },
274
165
  diagnostics,
275
- armedGoalId,
276
166
  });
277
167
  }
278
- // Seam path: drive each ready task through `executePlaybook(ivtr.cantbook)`.
279
- const runnerOptions = { projectRoot: root, epicId };
280
- if (params.sessionId !== undefined)
281
- runnerOptions.sessionId = params.sessionId;
282
- for (const taskId of readyFrontier) {
283
- try {
284
- const runResult = await params.ivtrRunner(taskId, runnerOptions);
285
- ivtrStarted.push(runResult.taskId);
286
- if (runResult.runId !== undefined)
287
- ivtrRunIds.push(runResult.runId);
288
- diagnostics.push(`IVTR cantbook started for ${runResult.taskId}` +
289
- `${runResult.runId ? ` (run ${runResult.runId})` : ''}` +
290
- `${runResult.terminalStatus ? ` → ${runResult.terminalStatus}` : ''}`);
291
- }
292
- catch (err) {
293
- diagnostics.push(`IVTR start failed for ${taskId}: ${err.message}`);
294
- }
295
- }
296
- if (ivtrStarted.length === 0 && readyFrontier.length > 0) {
297
- // All IVTR starts failed — surface the errors but return gracefully.
298
- diagnostics.push(`All ${readyFrontier.length} IVTR starts failed — see diagnostics`);
299
- }
300
- else {
301
- diagnostics.push(`IVTR cantbook started for ${ivtrStarted.length} task(s): ${ivtrStarted.join(', ')}`);
302
- }
168
+ const goal = await draftForWave(readyFrontier, root, diagnostics);
169
+ const handoff = goal ? goalRuntimeHandoff(goal.slug) : runtime;
170
+ diagnostics.push(handoff.next);
303
171
  return engineSuccess({
304
172
  outcome: {
305
- action: 'ivtrFanOut',
173
+ action: 'goalHandoff',
306
174
  sagaId,
307
175
  epicId,
308
176
  currentStage,
309
- tasks: ivtrStarted,
310
- runIds: ivtrRunIds,
177
+ tasks: readyFrontier,
178
+ goal,
179
+ runtime: handoff,
311
180
  },
312
181
  diagnostics,
313
- armedGoalId,
314
182
  });
315
183
  }
184
+ /**
185
+ * The CLEO Goal runtime and the next step: `/goal start <slug>` when its bin
186
+ * resolves, else the install commands (`cleo goal install` writes only the
187
+ * project's harness config).
188
+ */
189
+ function goalRuntimeHandoff(slug) {
190
+ const bin = resolveGoalBin();
191
+ const start = slug ? `/goal start ${slug}` : null;
192
+ if (bin !== null) {
193
+ return {
194
+ installed: true,
195
+ bin,
196
+ next: start ? `In your harness, run: ${start}` : 'CLEO Goal is installed.',
197
+ };
198
+ }
199
+ const install = [GOAL_INSTALL_COMMAND, 'cleo goal install --harness opencode'];
200
+ return {
201
+ installed: false,
202
+ install,
203
+ next: `CLEO Goal is not installed: run ${install.join(', then ')}${start ? `; then in your harness run: ${start}` : ''}`,
204
+ };
205
+ }
206
+ /** Draft the wave's goal, or reuse the draft already there (a draft never overwrites). */
207
+ async function draftForWave(tasks, root, diagnostics) {
208
+ const { draftGoal, goalSlug } = await import('../goal/draft.js');
209
+ const slug = goalSlug(tasks);
210
+ const path = join(root, '.opencode', 'goals', slug, 'goal.yaml');
211
+ if (existsSync(path)) {
212
+ diagnostics.push(`goal ${slug} is already drafted at ${path}`);
213
+ return { slug, path, reused: true };
214
+ }
215
+ const drafted = await draftGoal(tasks, { projectRoot: root });
216
+ if (!drafted.success) {
217
+ diagnostics.push(`goal draft failed for ${tasks.join(', ')}: ${drafted.error.message}`);
218
+ return null;
219
+ }
220
+ diagnostics.push(`goal ${drafted.data.slug} drafted at ${drafted.data.path}`);
221
+ return { slug: drafted.data.slug, path: drafted.data.path, reused: false };
222
+ }
316
223
  //# sourceMappingURL=driver.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"driver.js","sourceRoot":"","sources":["../../src/go/driver.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8DG;AAGH,OAAO,EAAqB,WAAW,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AACpF,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,sBAA+B,CAAC;AAExE;;;;;;;;;;GAUG;AACH,SAAS,qBAAqB;IAC5B,MAAM,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC,wBAAwB,CAAC,CAAC;IAClD,IAAI,GAAG,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACnC,MAAM,CAAC,GAAG,GAAG,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;IACnC,OAAO,CAAC,CAAC,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,OAAO,IAAI,CAAC,KAAK,IAAI,IAAI,C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WAAW,CAAC,IAAI,CAAC,yBAAyB,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,OAAO,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;QACxF,OAAO,IAAI,CAAC;IACd,CAAC;IACD,WAAW,CAAC,IAAI,CAAC,QAAQ,OAAO,CAAC,IAAI,CAAC,IAAI,eAAe,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC;IAC9E,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;AAC7E,CAAC"}
@@ -9,5 +9,5 @@
9
9
  * @task T11494 — E2-CLEO-GO
10
10
  * @saga T11492 — SG-AUTOPILOT
11
11
  */
12
- export { CLEO_GO_VIA_PLAYBOOK_ENV, type CleoGoAction, type CleoGoParams, type CleoGoResult, cleoGo, type IvtrRunner, type IvtrRunnerOptions, type IvtrRunResult, } from './driver.js';
12
+ export { type CleoGoAction, type CleoGoParams, type CleoGoResult, cleoGo } from './driver.js';
13
13
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/go/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EACL,wBAAwB,EACxB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,MAAM,EACN,KAAK,UAAU,EACf,KAAK,iBAAiB,EACtB,KAAK,aAAa,GACnB,MAAM,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/go/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,YAAY,EAAE,KAAK,YAAY,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC"}