@alexkroman1/aai-cli 6.10.1 → 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (162) hide show
  1. package/dist/{_agent-DpH2pBJd.mjs → _agent-BTwZJu4P.mjs} +2 -2
  2. package/dist/{_bundler-C2BDwU7r.mjs → _bundler-B4RqNF5Z.mjs} +2 -2
  3. package/dist/_dev-env.d.ts +22 -2
  4. package/dist/{_dev-server-LLLWnFBs.mjs → _dev-server-CiKFH9qw.mjs} +38 -47
  5. package/dist/_dev-server.d.ts +0 -17
  6. package/dist/{_init-C57bWAQ8.mjs → _init-CE4HKdgV.mjs} +3 -2
  7. package/dist/{_preflight-BtfaYtbE.mjs → _preflight-Co1G9Jww.mjs} +1 -1
  8. package/dist/_preflight.d.ts +1 -1
  9. package/dist/{_slug-api-BxrsJXVI.mjs → _slug-api-nRFaBEPJ.mjs} +2 -2
  10. package/dist/{_studio-U3jhKlA3.mjs → _studio-DR5yzZ1T.mjs} +2 -1
  11. package/dist/{_templates-Dxb_P2Wz.mjs → _templates-FI3xPEMj.mjs} +1 -1
  12. package/dist/_workflow-scan.d.ts +108 -0
  13. package/dist/{build-Dfza2pRI.mjs → build-6jfaakgc.mjs} +5 -2
  14. package/dist/cli.mjs +30 -25
  15. package/dist/{client-bundler-BEIqgOtd.mjs → client-bundler-CWnG42cU.mjs} +2 -1
  16. package/dist/client-bundler.mjs +1 -1
  17. package/dist/{delete-vbpjGzqs.mjs → delete-Dl_LSfvI.mjs} +3 -3
  18. package/dist/{deploy-B8lubiRT.mjs → deploy-DvYeD8ia.mjs} +5 -5
  19. package/dist/{dev-Uq5ujP8a.mjs → dev-B59JIfWO.mjs} +1 -1
  20. package/dist/{eject-31gjtaHF.mjs → eject-C9WJyyr2.mjs} +1 -1
  21. package/dist/{init-l6xfU4xX.mjs → init-CpJVjEg0.mjs} +3 -3
  22. package/dist/{login-C71-qz8F.mjs → login-BBuM1sxH.mjs} +3 -4
  23. package/dist/{logs-BWVGSjLR.mjs → logs-9q-psa4q.mjs} +2 -2
  24. package/dist/project-config.mjs +1 -1
  25. package/dist/scaffold/CLAUDE.md +93 -14
  26. package/dist/scaffold/package.json +5 -3
  27. package/dist/scaffold/server.mjs +13 -4
  28. package/dist/scaffold/vite.config.ts +1 -1
  29. package/dist/{secret-BuMuFR4B.mjs → secret-CVvSLIDV.mjs} +2 -2
  30. package/dist/{storage-DzRZ-eCw.mjs → storage-BvUrnvM3.mjs} +2 -2
  31. package/dist/{studio-BCNUpDgP.mjs → studio--MUV0cid.mjs} +4 -4
  32. package/dist/templates/call-audit/agent.test.ts +818 -0
  33. package/dist/templates/call-audit/agent.ts +171 -0
  34. package/dist/templates/call-audit/client.tsx +198 -0
  35. package/dist/templates/call-audit/workflows/audit.ts +298 -0
  36. package/dist/templates/call-audit/workflows/ingest.ts +251 -0
  37. package/dist/templates/call-audit/workflows/media.ts +637 -0
  38. package/dist/templates/call-audit/workflows/summarize.ts +201 -0
  39. package/dist/templates/call-audit/workflows/sync-api.ts +44 -0
  40. package/dist/templates/dispatch-center/agent.test.ts +149 -25
  41. package/dist/templates/dispatch-center/client.tsx +239 -129
  42. package/dist/templates/dispatch-center/shared.ts +99 -1
  43. package/dist/templates/dispatch-center/system-prompt.md +3 -1
  44. package/dist/templates/dispatch-center/tools/incident_add_note.ts +16 -13
  45. package/dist/templates/dispatch-center/tools/incident_create.ts +19 -1
  46. package/dist/templates/dispatch-center/tools/incident_escalate.ts +68 -59
  47. package/dist/templates/dispatch-center/tools/incident_triage.ts +57 -43
  48. package/dist/templates/dispatch-center/tools/incident_update_status.ts +49 -40
  49. package/dist/templates/dispatch-center/tools/ops_run_scenario.ts +8 -2
  50. package/dist/templates/dispatch-center/tools/resources_dispatch.ts +69 -52
  51. package/dist/templates/dispatch-center/tools/resources_update_status.ts +45 -41
  52. package/dist/templates/embedded-assets/agent.test.ts +17 -14
  53. package/dist/templates/health-assistant/agent.test.ts +22 -4
  54. package/dist/templates/infocom-adventure/agent.test.ts +4 -6
  55. package/dist/templates/infocom-adventure/client.tsx +246 -164
  56. package/dist/templates/link-digest/agent.test.ts +24 -19
  57. package/dist/templates/link-digest/client.tsx +47 -61
  58. package/dist/templates/link-digest/workflows/digest.ts +19 -31
  59. package/dist/templates/night-owl/agent.test.ts +70 -19
  60. package/dist/templates/night-owl/agent.ts +5 -0
  61. package/dist/templates/night-owl/client.tsx +56 -56
  62. package/dist/templates/night-owl/shared.ts +24 -0
  63. package/dist/templates/night-owl/tools/recommend.ts +18 -6
  64. package/dist/templates/pizza-ordering/agent.test.ts +27 -27
  65. package/dist/templates/pizza-ordering/client.tsx +9 -26
  66. package/dist/templates/plan-and-execute/agent.test.ts +99 -58
  67. package/dist/templates/plan-and-execute/agent.ts +1 -1
  68. package/dist/templates/plan-and-execute/client.tsx +12 -15
  69. package/dist/templates/plan-and-execute/shared.ts +71 -2
  70. package/dist/templates/plan-and-execute/tools/plan_status.ts +18 -6
  71. package/dist/templates/plan-and-execute/tools/revise_plan.ts +18 -10
  72. package/dist/templates/plan-and-execute/tools/start_plan.ts +13 -2
  73. package/dist/templates/plan-and-execute/tools/work_next_step.ts +70 -22
  74. package/dist/templates/podcast-digest/agent.test.ts +746 -0
  75. package/dist/templates/podcast-digest/agent.ts +139 -0
  76. package/dist/templates/podcast-digest/client.tsx +154 -0
  77. package/dist/templates/podcast-digest/workflows/digest.ts +411 -0
  78. package/dist/templates/podcast-digest/workflows/feeds.ts +507 -0
  79. package/dist/templates/podcast-digest/workflows/slack.ts +209 -0
  80. package/dist/templates/recap-workflow/agent.test.ts +107 -96
  81. package/dist/templates/recap-workflow/tools/recap_progress.ts +9 -12
  82. package/dist/templates/recap-workflow/tools/recap_status.ts +8 -9
  83. package/dist/templates/recap-workflow/tools/request_recap.ts +2 -1
  84. package/dist/templates/recap-workflow/workflows/recap.ts +48 -41
  85. package/dist/templates/redline/agent.test.ts +17 -15
  86. package/dist/templates/redline/client.tsx +12 -12
  87. package/dist/templates/redline/workflows/redline.ts +19 -31
  88. package/dist/templates/research-workflow/agent.test.ts +60 -59
  89. package/dist/templates/research-workflow/tools/research_progress.ts +9 -12
  90. package/dist/templates/research-workflow/tools/research_status.ts +9 -11
  91. package/dist/templates/research-workflow/workflows/research.ts +44 -61
  92. package/dist/templates/retail/agent.test.ts +26 -23
  93. package/dist/templates/retail/client.tsx +226 -117
  94. package/dist/templates/retail/registry.test.ts +38 -6
  95. package/dist/templates/retail/store.test.ts +82 -15
  96. package/dist/templates/retail/store.ts +174 -47
  97. package/dist/templates/retail/system-prompt.md +11 -2
  98. package/dist/templates/retail/tools/cancel_pending_order.ts +2 -2
  99. package/dist/templates/retail/tools/exchange_delivered_order_items.ts +2 -2
  100. package/dist/templates/retail/tools/find_user_id_by_email.ts +8 -5
  101. package/dist/templates/retail/tools/find_user_id_by_name_zip.ts +4 -5
  102. package/dist/templates/retail/tools/get_item_details.ts +3 -4
  103. package/dist/templates/retail/tools/get_order_details.ts +3 -4
  104. package/dist/templates/retail/tools/get_product_details.ts +3 -4
  105. package/dist/templates/retail/tools/get_user_details.ts +2 -2
  106. package/dist/templates/retail/tools/list_all_product_types.ts +5 -5
  107. package/dist/templates/retail/tools/modify_pending_order_address.ts +2 -2
  108. package/dist/templates/retail/tools/modify_pending_order_items.ts +2 -3
  109. package/dist/templates/retail/tools/modify_pending_order_payment.ts +2 -2
  110. package/dist/templates/retail/tools/modify_user_address.ts +2 -2
  111. package/dist/templates/retail/tools/return_delivered_order_items.ts +2 -2
  112. package/dist/templates/retail/tools/transfer_to_human_agents.ts +8 -4
  113. package/dist/templates/solo-rpg/agent.test.ts +227 -48
  114. package/dist/templates/solo-rpg/client.tsx +38 -37
  115. package/dist/templates/solo-rpg/shared.ts +145 -19
  116. package/dist/templates/solo-rpg/system-prompt.md +3 -2
  117. package/dist/templates/solo-rpg/tools/action_roll.ts +82 -63
  118. package/dist/templates/solo-rpg/tools/burn_momentum.ts +85 -50
  119. package/dist/templates/solo-rpg/tools/check_state.ts +24 -7
  120. package/dist/templates/solo-rpg/tools/load_game.ts +13 -1
  121. package/dist/templates/solo-rpg/tools/save_game.ts +16 -7
  122. package/dist/templates/solo-rpg/tools/setup_character.ts +22 -2
  123. package/dist/templates/solo-rpg/tools/update_state.ts +113 -100
  124. package/dist/templates/spoken-summary/agent.test.ts +314 -0
  125. package/dist/templates/spoken-summary/agent.ts +155 -0
  126. package/dist/templates/spoken-summary/client.tsx +185 -0
  127. package/dist/templates/spoken-summary/workflows/summarize.ts +237 -0
  128. package/dist/templates/spoken-summary/workflows/transcribe.ts +138 -0
  129. package/dist/templates/support-line/agent.test.ts +11 -16
  130. package/dist/templates/support-line/agent.ts +1 -1
  131. package/dist/templates/support-line/client.tsx +9 -9
  132. package/dist/templates/support-line/nodes.ts +100 -0
  133. package/dist/templates/support-line/procedure.ts +407 -0
  134. package/dist/templates/support-line/tools/answer_question.ts +17 -4
  135. package/dist/templates/transcription-workflow/agent.test.ts +246 -123
  136. package/dist/templates/transcription-workflow/agent.ts +21 -7
  137. package/dist/templates/transcription-workflow/client.tsx +17 -42
  138. package/dist/templates/transcription-workflow/workflows/batch.ts +79 -180
  139. package/dist/templates/transcription-workflow/workflows/normalize.ts +247 -0
  140. package/dist/templates/transcription-workflow/workflows/stitch.ts +0 -11
  141. package/dist/templates/transcription-workflow/workflows/stream.ts +10 -9
  142. package/dist/templates/transcription-workflow/workflows/sync-api.ts +26 -94
  143. package/dist/templates/transcription-workflow/workflows/transcribe.ts +55 -40
  144. package/dist/templates/transcription-workflow/workflows/wav.ts +31 -31
  145. package/dist/templates/travel-concierge/agent.test.ts +64 -33
  146. package/dist/templates/travel-concierge/client.tsx +11 -23
  147. package/dist/templates/travel-concierge/routing.ts +34 -15
  148. package/dist/templates/travel-concierge/shared.ts +70 -3
  149. package/dist/templates/travel-concierge/tools/book_car_rental.ts +2 -2
  150. package/dist/templates/travel-concierge/tools/book_excursion.ts +2 -2
  151. package/dist/templates/travel-concierge/tools/book_hotel.ts +2 -2
  152. package/dist/templates/travel-concierge/tools/cancel_ticket.ts +2 -2
  153. package/dist/templates/travel-concierge/tools/update_ticket.ts +2 -2
  154. package/dist/{worker-bundler-CGD4r8Kc.mjs → worker-bundler-COxnqstQ.mjs} +221 -3
  155. package/dist/worker-bundler.mjs +1 -1
  156. package/dist/{workflow-CFpxOFfQ.mjs → workflow-D2AQf2Pl.mjs} +28 -1
  157. package/dist/workflow-bundler.d.ts +6 -1
  158. package/dist/workflow.d.ts +1 -1
  159. package/package.json +5 -4
  160. package/dist/templates/support-line/graph.ts +0 -224
  161. package/dist/{_config-D_s09e7g.mjs → _config-CmJOFsAP.mjs} +1 -1
  162. /package/dist/templates/plan-and-execute/{graph.ts → procedure.ts} +0 -0
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
- import { a as serverOrigin, i as readProjectConfig, n as ensureApiKey, r as readGlobalConfig, t as approveServer } from "./_config-D_s09e7g.mjs";
2
+ import { a as serverOrigin, i as readProjectConfig, n as ensureApiKey, r as readGlobalConfig, t as approveServer } from "./_config-CmJOFsAP.mjs";
3
3
  import { existsSync } from "node:fs";
4
4
  import path from "node:path";
5
5
  import { fileURLToPath } from "node:url";
6
- import { VALID_SLUG_RE } from "@alexkroman1/aai/utils";
6
+ import { VALID_SLUG_RE } from "@alexkroman1/aai/internal";
7
7
  //#region _agent.ts
8
8
  const DEFAULT_SERVER = "https://alexkroman--aai-server-web-server.modal.run";
9
9
  const DEFAULT_DEV_SERVER = "http://localhost:8080";
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { f as validateAgentExport } from "./_utils-B8QmtFhK.mjs";
3
- import { t as buildClient } from "./client-bundler-BEIqgOtd.mjs";
4
- import { n as buildWorkflows, t as buildWorker } from "./worker-bundler-CGD4r8Kc.mjs";
3
+ import { t as buildClient } from "./client-bundler-CWnG42cU.mjs";
4
+ import { n as buildWorkflows, t as buildWorker } from "./worker-bundler-COxnqstQ.mjs";
5
5
  import path from "node:path";
6
6
  import { pathToFileURL } from "node:url";
7
7
  import { omitUndefined } from "@alexkroman1/aai/utils";
@@ -9,9 +9,13 @@
9
9
  * (who may connect, where it binds, whether it restarts), so they are read from
10
10
  * the environment on purpose and must never leak into `ctx.env`.
11
11
  *
12
- * Split out of `_dev-server.ts` purely to keep that module under the
13
- * file-length cap; it is the only consumer.
12
+ * `createDevLogger` sits here for the second half of that reason rather than
13
+ * the first: it is not a control variable, it READS one — the same auto-
14
+ * detected JSON mode — to decide where the runtime's diagnostics go. Both
15
+ * were split out of `_dev-server.ts` to keep it under the file-length cap,
16
+ * and `_dev-server.ts` is the only consumer of either.
14
17
  */
18
+ import type { Logger } from "@alexkroman1/aai-runtime";
15
19
  /**
16
20
  * The env handed to `createServer` for host-mode connections: provider
17
21
  * credentials plus the `AAI_ALLOW_HOST` gate read straight from the shell
@@ -36,3 +40,19 @@ export declare function devBindHost(): string | undefined;
36
40
  * as a provider failure several records deep.
37
41
  */
38
42
  export declare function devWatchEnabled(): boolean;
43
+ /**
44
+ * The logger the dev server's runtime writes through.
45
+ *
46
+ * The SDK's default logger is console-backed and `console.log` is STDOUT, so
47
+ * in JSON mode the runtime's own diagnostics — the multi-line "Session mode
48
+ * resolved" dump at startup, every later warning — landed on stdout ahead of
49
+ * the single result line `aai dev` promises there. JSON mode is AUTO-DETECTED
50
+ * on a pipe, so that is the normal case rather than an opt-in one:
51
+ * `aai dev > dev.log`, a process supervisor, a container. It is the same
52
+ * hazard `notify` exists for, one layer down: `silenceOutput()` only reaches
53
+ * this CLI's own `log`, and the runtime is not using it.
54
+ *
55
+ * Human mode keeps the console logger exactly as it was — a TTY has nothing
56
+ * to parse, and stdout is where people are already reading these.
57
+ */
58
+ export declare function createDevLogger(silenced: boolean): Logger;
@@ -1,37 +1,25 @@
1
1
  #!/usr/bin/env node
2
2
  import { i as outputSilenced, r as notify } from "./_ui-u7T4YooX.mjs";
3
3
  import { i as errorCode, o as errorMessage$1 } from "./_utils-B8QmtFhK.mjs";
4
- import { n as fallbackHtmlPlugin } from "./client-bundler-BEIqgOtd.mjs";
4
+ import { n as fallbackHtmlPlugin } from "./client-bundler-CWnG42cU.mjs";
5
5
  import { t as DEDUPED_PEERS } from "./_vite-env-BNveawd1.mjs";
6
- import { n as buildWorkflows, t as buildWorker } from "./worker-bundler-CGD4r8Kc.mjs";
7
- import { n as ensureApiKey } from "./_config-D_s09e7g.mjs";
8
- import { n as createWorkerEvaluator } from "./_bundler-C2BDwU7r.mjs";
6
+ import { n as buildWorkflows, t as buildWorker } from "./worker-bundler-COxnqstQ.mjs";
7
+ import { n as ensureApiKey } from "./_config-CmJOFsAP.mjs";
8
+ import { n as createWorkerEvaluator } from "./_bundler-B4RqNF5Z.mjs";
9
9
  import { t as resolveServerEnv } from "./_server-common-6e0QI4mq.mjs";
10
10
  import { existsSync } from "node:fs";
11
11
  import path from "node:path";
12
12
  import { omitUndefined } from "@alexkroman1/aai/utils";
13
13
  import { createCoalescingRunner, sleep } from "@alexkroman1/aai/internal";
14
- import { WORKFLOW_API_PREFIX, configureWorkflowWorld, consoleLogger, createRuntime, createServer, createWorkflowSurface, handleWorkflowRequest, publishStepEnv, requiredProviderEnvVars, startWorkflowWorldIfDeclared, withHostCredentialFallback } from "@alexkroman1/aai/runtime";
14
+ import { agentConfigWarnings } from "@alexkroman1/aai/manifest";
15
+ import { WORKFLOW_API_PREFIX, createRuntime, createServer, requiredProviderEnvVars, withHostCredentialFallback } from "@alexkroman1/aai-runtime";
16
+ import { configureWorkflowWorld, consoleLogger, createWorkflowSurface, handleWorkflowRequest, publishStepEnv, startWorkflowWorldIfDeclared } from "@alexkroman1/aai-runtime/internal";
15
17
  import { defaultClientDir } from "@alexkroman1/aai-ui/client-dir";
16
18
  import { watch } from "chokidar";
17
19
  import getPort, { portNumbers } from "get-port";
18
20
  import pDebounce from "p-debounce";
19
21
  //#region _dev-env.ts
20
22
  /**
21
- * The dev server's CONTROL variables — the three things read straight from the
22
- * shell rather than from the agent's `.env`.
23
- *
24
- * That distinction is the reason these live together. `resolveServerEnv` builds
25
- * `ctx.env` from `.env`-declared keys only, deliberately, so an agent cannot
26
- * come to depend on a shell variable that will not exist after deploy. These
27
- * three are not agent config at all — they configure the *dev server process*
28
- * (who may connect, where it binds, whether it restarts), so they are read from
29
- * the environment on purpose and must never leak into `ctx.env`.
30
- *
31
- * Split out of `_dev-server.ts` purely to keep that module under the
32
- * file-length cap; it is the only consumer.
33
- */
34
- /**
35
23
  * The env handed to `createServer` for host-mode connections: provider
36
24
  * credentials plus the `AAI_ALLOW_HOST` gate read straight from the shell
37
25
  * (it is a control variable, not something an agent declares in `.env`).
@@ -66,6 +54,33 @@ function devBindHost() {
66
54
  function devWatchEnabled() {
67
55
  return /^(1|true|yes|on)$/i.test(process.env.AAI_DEV_WATCH?.trim() ?? "");
68
56
  }
57
+ /**
58
+ * The logger the dev server's runtime writes through.
59
+ *
60
+ * The SDK's default logger is console-backed and `console.log` is STDOUT, so
61
+ * in JSON mode the runtime's own diagnostics — the multi-line "Session mode
62
+ * resolved" dump at startup, every later warning — landed on stdout ahead of
63
+ * the single result line `aai dev` promises there. JSON mode is AUTO-DETECTED
64
+ * on a pipe, so that is the normal case rather than an opt-in one:
65
+ * `aai dev > dev.log`, a process supervisor, a container. It is the same
66
+ * hazard `notify` exists for, one layer down: `silenceOutput()` only reaches
67
+ * this CLI's own `log`, and the runtime is not using it.
68
+ *
69
+ * Human mode keeps the console logger exactly as it was — a TTY has nothing
70
+ * to parse, and stdout is where people are already reading these.
71
+ */
72
+ function createDevLogger(silenced) {
73
+ if (!silenced) return consoleLogger;
74
+ const write = (msg, ctx) => {
75
+ process.stderr.write(`${msg}${ctx === void 0 ? "" : ` ${JSON.stringify(ctx)}`}\n`);
76
+ };
77
+ return {
78
+ info: write,
79
+ warn: write,
80
+ error: write,
81
+ debug: () => void 0
82
+ };
83
+ }
69
84
  //#endregion
70
85
  //#region _dev-restart.ts
71
86
  /**
@@ -237,6 +252,7 @@ async function resolveAgentEnv(root, agentDef) {
237
252
  const hasShellKey = Boolean(process.env.ASSEMBLYAI_API_KEY);
238
253
  if (required.includes("ASSEMBLYAI_API_KEY") && !env.ASSEMBLYAI_API_KEY && !hasShellKey) env.ASSEMBLYAI_API_KEY = await ensureApiKey();
239
254
  for (const warning of agentEnvWarnings(agentDef, env)) notify("warn", warning);
255
+ for (const warning of agentConfigWarnings(agentDef)) notify("warn", warning);
240
256
  return env;
241
257
  }
242
258
  /**
@@ -260,9 +276,11 @@ async function resolveAgentEnv(root, agentDef) {
260
276
  * without starting a builder.
261
277
  */
262
278
  async function loadWorker(cwd, evaluate) {
279
+ const workflows = await buildWorkflows(cwd);
280
+ for (const warning of workflows?.warnings ?? []) notify("warn", warning);
263
281
  return evaluate(await buildWorker(cwd, {
264
282
  runtime: false,
265
- workflows: await buildWorkflows(cwd)
283
+ workflows
266
284
  }));
267
285
  }
268
286
  /**
@@ -284,33 +302,6 @@ function isIgnoredPath(dir, filePath) {
284
302
  });
285
303
  }
286
304
  /**
287
- * The logger the dev server's runtime writes through.
288
- *
289
- * The SDK's default logger is console-backed and `console.log` is STDOUT, so
290
- * in JSON mode the runtime's own diagnostics — the multi-line "Session mode
291
- * resolved" dump at startup, every later warning — landed on stdout ahead of
292
- * the single result line `aai dev` promises there. JSON mode is AUTO-DETECTED
293
- * on a pipe, so that is the normal case rather than an opt-in one:
294
- * `aai dev > dev.log`, a process supervisor, a container. It is the same
295
- * hazard `notify` exists for, one layer down: `silenceOutput()` only reaches
296
- * this CLI's own `log`, and the runtime is not using it.
297
- *
298
- * Human mode keeps the console logger exactly as it was — a TTY has nothing
299
- * to parse, and stdout is where people are already reading these.
300
- */
301
- function createDevLogger(silenced) {
302
- if (!silenced) return consoleLogger;
303
- const write = (msg, ctx) => {
304
- process.stderr.write(`${msg}${ctx === void 0 ? "" : ` ${JSON.stringify(ctx)}`}\n`);
305
- };
306
- return {
307
- info: write,
308
- warn: write,
309
- error: write,
310
- debug: () => void 0
311
- };
312
- }
313
- /**
314
305
  * Watch the agent directory for changes and call `onChange` when detected.
315
306
  * Debounces to avoid rapid restarts. Uses chokidar for reliable recursive
316
307
  * watching across platforms (raw `fs.watch` misses events on Linux).
@@ -7,7 +7,6 @@
7
7
  * client SPA HMR.
8
8
  */
9
9
  import type { AgentDef } from "@alexkroman1/aai";
10
- import { type Logger } from "@alexkroman1/aai/runtime";
11
10
  import { type FSWatcher } from "chokidar";
12
11
  import { type EvaluatedWorker } from "./_bundler.ts";
13
12
  /**
@@ -55,22 +54,6 @@ export declare function loadWorker(cwd: string, evaluate: (code: string) => Prom
55
54
  * restart the server with the new values.
56
55
  */
57
56
  export declare function isIgnoredPath(dir: string, filePath: string): boolean;
58
- /**
59
- * The logger the dev server's runtime writes through.
60
- *
61
- * The SDK's default logger is console-backed and `console.log` is STDOUT, so
62
- * in JSON mode the runtime's own diagnostics — the multi-line "Session mode
63
- * resolved" dump at startup, every later warning — landed on stdout ahead of
64
- * the single result line `aai dev` promises there. JSON mode is AUTO-DETECTED
65
- * on a pipe, so that is the normal case rather than an opt-in one:
66
- * `aai dev > dev.log`, a process supervisor, a container. It is the same
67
- * hazard `notify` exists for, one layer down: `silenceOutput()` only reaches
68
- * this CLI's own `log`, and the runtime is not using it.
69
- *
70
- * Human mode keeps the console logger exactly as it was — a TTY has nothing
71
- * to parse, and stdout is where people are already reading these.
72
- */
73
- export declare function createDevLogger(silenced: boolean): Logger;
74
57
  /**
75
58
  * Watch the agent directory for changes and call `onChange` when detected.
76
59
  * Debounces to avoid rapid restarts. Uses chokidar for reliable recursive
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { c as isEexist, l as readJson, p as writeJson } from "./_utils-B8QmtFhK.mjs";
3
- import { r as isDevMode, t as getMonorepoRoot } from "./_agent-DpH2pBJd.mjs";
4
- import { REPO_URL, downloadAndMergeTemplate } from "./_templates-Dxb_P2Wz.mjs";
3
+ import { r as isDevMode, t as getMonorepoRoot } from "./_agent-BTwZJu4P.mjs";
4
+ import { REPO_URL, downloadAndMergeTemplate } from "./_templates-FI3xPEMj.mjs";
5
5
  import path from "node:path";
6
6
  import fs from "node:fs/promises";
7
7
  //#region _init.ts
@@ -46,6 +46,7 @@ aai secret delete MY_KEY # Remove a secret
46
46
  const WORKSPACE_PKG_DIRS = {
47
47
  "@alexkroman1/aai": "aai",
48
48
  "@alexkroman1/aai-cli": "aai-cli",
49
+ "@alexkroman1/aai-runtime": "aai-runtime",
49
50
  "@alexkroman1/aai-ui": "aai-ui"
50
51
  };
51
52
  /** Rewrite workspace deps to link: paths so pnpm links to local source. */
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { requiredProviderEnvVars } from "@alexkroman1/aai/runtime";
2
+ import { requiredProviderEnvVars } from "@alexkroman1/aai-runtime";
3
3
  //#region _preflight.ts
4
4
  /**
5
5
  * The deploy-time credential preflight — the classic dev/prod failure, caught
@@ -22,7 +22,7 @@
22
22
  * accuracy, and a false rejection is worse than a false warning: it blocks a
23
23
  * deploy that would have worked.
24
24
  */
25
- import { requiredProviderEnvVars } from "@alexkroman1/aai/runtime";
25
+ import { requiredProviderEnvVars } from "@alexkroman1/aai-runtime";
26
26
  /**
27
27
  * The config shape read out of a bundle's `__aaiConfig` export: the provider
28
28
  * descriptors the credential derivation needs, plus the agent's declared
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
- import { n as getServerInfo } from "./_agent-DpH2pBJd.mjs";
3
- import { l as HINT_NOT_DEPLOYED, s as studioProjectApiUrl, u as apiRequest } from "./_studio-U3jhKlA3.mjs";
2
+ import { n as getServerInfo } from "./_agent-BTwZJu4P.mjs";
3
+ import { l as HINT_NOT_DEPLOYED, s as studioProjectApiUrl, u as apiRequest } from "./_studio-DR5yzZ1T.mjs";
4
4
  //#region _slug-api.ts
5
5
  /**
6
6
  * Authenticated request against a deployed agent's slug-scoped resource
@@ -1,7 +1,8 @@
1
1
  #!/usr/bin/env node
2
2
  import { t as CliError } from "./_output-CKkmWs7i.mjs";
3
3
  import path from "node:path";
4
- import { MAX_SLUG_LENGTH, PREVIEW_SLUG_SUFFIX, VALID_SLUG_RE, isRecord, omitUndefined } from "@alexkroman1/aai/utils";
4
+ import { isRecord, omitUndefined } from "@alexkroman1/aai/utils";
5
+ import { MAX_SLUG_LENGTH, PREVIEW_SLUG_SUFFIX, VALID_SLUG_RE } from "@alexkroman1/aai/internal";
5
6
  import { FetchError, ofetch } from "ofetch";
6
7
  import { slugifyName } from "@alexkroman1/aai/slugify";
7
8
  import { isLocalOnlyFile, snapshotWorkspaceFiles } from "@alexkroman1/aai/workspace-files";
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
  import { o as errorMessage$1 } from "./_utils-B8QmtFhK.mjs";
3
- import { t as getMonorepoRoot } from "./_agent-DpH2pBJd.mjs";
3
+ import { t as getMonorepoRoot } from "./_agent-BTwZJu4P.mjs";
4
4
  import { existsSync } from "node:fs";
5
5
  import path from "node:path";
6
6
  import { isRecord } from "@alexkroman1/aai/utils";
@@ -0,0 +1,108 @@
1
+ /**
2
+ * What the BUILT flow bundle carries — the two scans that read it, and the
3
+ * checks over them.
4
+ *
5
+ * Split out of `workflow-bundler.ts` when that file crossed the 500-line cap,
6
+ * along the seam the two scans already share: both read the same artifact after
7
+ * the builder has written it, both attribute a line to a module through
8
+ * esbuild's `// <path>` headers, and neither has anything to do with
9
+ * CONFIGURING the build. One of them fails the build (a `require` the workflow
10
+ * VM cannot answer) and the other warns (a call that replays differently), which
11
+ * is the only real difference between them.
12
+ *
13
+ * Internal: `workflow-bundler.ts` is the surface the studio and the CLI's own
14
+ * build call, and it re-exports nothing from here that they need.
15
+ *
16
+ * @module _workflow-scan
17
+ */
18
+ /** One `require` the workflow VM cannot answer, and the module it was written for. */
19
+ export type VmRequireSite = {
20
+ /** The module specifier — `node:child_process`. */
21
+ specifier: string;
22
+ /** The bundled file esbuild attributed it to, or `undefined` when it said none. */
23
+ module: string | undefined;
24
+ };
25
+ /**
26
+ * Find the Node builtins a flow bundle would `require` at load.
27
+ *
28
+ * The flow bundle is compiled in a `node:vm` `Script` whose context has
29
+ * `module` and `exports` and **no `require`**, so one of these is a run that
30
+ * dies at replay with `ReferenceError: require is not defined` — never a build
31
+ * failure, and never a symptom before the first run. The WDK's own builder
32
+ * bundles everything for exactly this reason and carries
33
+ * `createNodeModuleErrorPlugin` to reject a builtin import at build time.
34
+ *
35
+ * That plugin has two blind spots this scan covers, and both are the DEPLOYED
36
+ * shape rather than an exotic one:
37
+ *
38
+ * - It reports a violation only when it can point at the import LINE in a
39
+ * first-party file, matched with a single-line regex — so a multi-line
40
+ * `import {\n x,\n} from "pkg"` finds nothing and the builtin is marked
41
+ * external in silence.
42
+ * - It resolves that file against `process.cwd()`, which is not the project
43
+ * being built when the studio builds a workspace, so the read fails and the
44
+ * same silent path is taken.
45
+ *
46
+ * Both were reproduced. What reaches the VM either way is
47
+ * `var import_node_child_process = require("node:child_process");` at the top
48
+ * of the bundle, i.e. every run of every workflow in the project fails, and the
49
+ * stack names a line of generated code inside a dependency.
50
+ *
51
+ * Restricted to builtin specifiers deliberately: those are the only ones this
52
+ * builder leaves external (it marks nothing else so, precisely so nothing can
53
+ * need a `require`), and a narrow set is what keeps the scan from reading the
54
+ * text of a prompt as a violation.
55
+ *
56
+ * @internal
57
+ */
58
+ export declare function findVmRequires(workflowCode: string): VmRequireSite[];
59
+ /** One replay-unsafe call the flow bundle carries, and where it came from. */
60
+ export type ReplayUnsafeSite = {
61
+ /** The call, as written — `Date.now(`. */
62
+ call: string;
63
+ /** What it does on a replay, and what to do instead. */
64
+ fix: string;
65
+ /** The project file esbuild attributed it to. */
66
+ module: string;
67
+ };
68
+ /**
69
+ * Replay-unsafe calls the flow bundle carries, attributed to the project's OWN
70
+ * `workflows/` files.
71
+ *
72
+ * Attribution is the whole design. The bundle inlines every non-external
73
+ * dependency a workflow module imports — zod, a markdown parser, whatever — and
74
+ * third-party code is full of `Date.now()` on paths a workflow never reaches, so
75
+ * a scan of the bundle's text reports a library and blocks a correct project.
76
+ * esbuild writes a `// <path>` header per module (the same one
77
+ * {@link findVmRequires} reads), so lines can be charged to the file they were
78
+ * written in, and only the project's own workflow sources are read.
79
+ *
80
+ * Scanning the BUNDLE rather than the sources is what makes a `"use step"` body
81
+ * exempt for free: the workflow-mode transform has already removed them, so
82
+ * what is left is the part that really does replay.
83
+ *
84
+ * @internal
85
+ */
86
+ export declare function findReplayUnsafeCalls(workflowCode: string): ReplayUnsafeSite[];
87
+ /**
88
+ * The warning `aai build` and `aai dev` print for a replay-unsafe call.
89
+ *
90
+ * A WARNING and not a build failure, deliberately. The attribution above makes
91
+ * the scan accurate about which FILE a call is in, and it cannot know whether a
92
+ * plain function in a `workflows/` module is reached from a body (where the
93
+ * rule bites) or only from a step (where it does not) — so the one thing it
94
+ * must not do is refuse a correct project. A silent build was the actual
95
+ * problem; a line naming the file solves it without that risk.
96
+ */
97
+ export declare function replayWarnings(workflowCode: string): string[];
98
+ /**
99
+ * Fail the build when the flow bundle carries a `require` — see
100
+ * {@link findVmRequires} for what that means and why nothing upstream catches it.
101
+ *
102
+ * The message has to name the MODULE as well as the specifier, because the
103
+ * import that caused it is not in the file an author is looking at: only a
104
+ * `"use step"` body is stripped from this bundle, so a value a `workflows/`
105
+ * module holds at module scope — an exported helper, a constant — keeps its
106
+ * import, and that import's whole graph rides into the VM.
107
+ */
108
+ export declare function assertNoVmRequires(workflowCode: string): void;
@@ -1,11 +1,12 @@
1
1
  #!/usr/bin/env node
2
2
  import { a as ok, t as CliError } from "./_output-CKkmWs7i.mjs";
3
- import { n as log } from "./_ui-u7T4YooX.mjs";
4
- import { r as evalWorkerBundle, t as buildAgentBundle } from "./_bundler-C2BDwU7r.mjs";
3
+ import { n as log, r as notify } from "./_ui-u7T4YooX.mjs";
4
+ import { r as evalWorkerBundle, t as buildAgentBundle } from "./_bundler-B4RqNF5Z.mjs";
5
5
  import { assertTypechecks } from "./_typecheck-gate-BXvUNnfs.mjs";
6
6
  import { classifyVitestError, runVitest } from "./test-9kPKJI-w.mjs";
7
7
  import path from "node:path";
8
8
  import fs from "node:fs/promises";
9
+ import { agentConfigWarnings } from "@alexkroman1/aai/manifest";
9
10
  //#region build.ts
10
11
  /**
11
12
  * `aai build` — bundle the agent without deploying, behind the same gates
@@ -47,7 +48,9 @@ async function executeBuild(opts) {
47
48
  }
48
49
  if (!opts.skipTypecheck) await assertTypechecks(cwd);
49
50
  const bundle = await buildAgentBundle(cwd, { minify: true });
51
+ for (const warning of bundle.workflows?.warnings ?? []) notify("warn", warning);
50
52
  const agentDef = await evalWorkerBundle(bundle.worker);
53
+ for (const warning of agentConfigWarnings(agentDef)) notify("warn", warning);
51
54
  const worker = path.join(cwd, WORKER_ARTIFACT_REL);
52
55
  await fs.mkdir(path.dirname(worker), { recursive: true });
53
56
  await fs.writeFile(worker, bundle.worker, "utf-8");
package/dist/cli.mjs CHANGED
@@ -250,7 +250,7 @@ const list = defineExec({
250
250
  },
251
251
  cwd: "any",
252
252
  async run({ args, cwd }) {
253
- const { executeList } = await import("./studio-BCNUpDgP.mjs");
253
+ const { executeList } = await import("./studio--MUV0cid.mjs");
254
254
  return executeList({
255
255
  cwd,
256
256
  server: args.server
@@ -283,7 +283,7 @@ const pull = defineExec({
283
283
  },
284
284
  cwd: "any",
285
285
  async run({ args, cwd }) {
286
- const { executePull } = await import("./studio-BCNUpDgP.mjs");
286
+ const { executePull } = await import("./studio--MUV0cid.mjs");
287
287
  return executePull({
288
288
  cwd,
289
289
  project: args.project,
@@ -309,7 +309,7 @@ const push = defineExec({
309
309
  },
310
310
  cwd: "agent",
311
311
  async run({ args, cwd }) {
312
- const { executePush } = await import("./studio-BCNUpDgP.mjs");
312
+ const { executePush } = await import("./studio--MUV0cid.mjs");
313
313
  return executePush({
314
314
  cwd,
315
315
  server: args.server,
@@ -337,7 +337,7 @@ const publish = defineExec({
337
337
  },
338
338
  cwd: "agent",
339
339
  async run({ args, cwd }) {
340
- const { executePublish } = await import("./studio-BCNUpDgP.mjs");
340
+ const { executePublish } = await import("./studio--MUV0cid.mjs");
341
341
  return executePublish({
342
342
  cwd,
343
343
  server: args.server,
@@ -404,7 +404,7 @@ const workflow = defineCommand({
404
404
  args: workflowArgs,
405
405
  cwd: WORKFLOW_CWD,
406
406
  async run({ args, cwd }) {
407
- const { executeWorkflowList } = await import("./workflow-CFpxOFfQ.mjs");
407
+ const { executeWorkflowList } = await import("./workflow-D2AQf2Pl.mjs");
408
408
  return executeWorkflowList(cwd, {
409
409
  server: args.server,
410
410
  token: args.token
@@ -430,7 +430,7 @@ const workflow = defineCommand({
430
430
  },
431
431
  cwd: WORKFLOW_CWD,
432
432
  async run({ args, cwd }) {
433
- const { executeWorkflowRuns } = await import("./workflow-CFpxOFfQ.mjs");
433
+ const { executeWorkflowRuns } = await import("./workflow-D2AQf2Pl.mjs");
434
434
  const limit = args.limit === void 0 ? void 0 : Number(args.limit);
435
435
  if (limit !== void 0 && !Number.isFinite(limit)) throw new CliError("bad_limit", "--limit must be a number");
436
436
  return executeWorkflowRuns(cwd, args.workflow, {
@@ -451,7 +451,7 @@ const workflow = defineCommand({
451
451
  },
452
452
  cwd: WORKFLOW_CWD,
453
453
  async run({ args, cwd }) {
454
- const { executeWorkflowShow } = await import("./workflow-CFpxOFfQ.mjs");
454
+ const { executeWorkflowShow } = await import("./workflow-D2AQf2Pl.mjs");
455
455
  return executeWorkflowShow(cwd, args.runId, {
456
456
  server: args.server,
457
457
  token: args.token
@@ -469,7 +469,7 @@ const workflow = defineCommand({
469
469
  },
470
470
  cwd: WORKFLOW_CWD,
471
471
  async run({ args, cwd }) {
472
- const { executeWorkflowCancel } = await import("./workflow-CFpxOFfQ.mjs");
472
+ const { executeWorkflowCancel } = await import("./workflow-D2AQf2Pl.mjs");
473
473
  return executeWorkflowCancel(cwd, args.runId, {
474
474
  server: args.server,
475
475
  token: args.token
@@ -545,7 +545,7 @@ const init = defineExec({
545
545
  },
546
546
  cwd: "none",
547
547
  async run({ args, mode }) {
548
- const { executeInit } = await import("./init-l6xfU4xX.mjs");
548
+ const { executeInit } = await import("./init-CpJVjEg0.mjs");
549
549
  return executeInit({
550
550
  dir: args.dir,
551
551
  force: args.force,
@@ -572,7 +572,7 @@ const dev = defineExec({
572
572
  },
573
573
  cwd: "agent",
574
574
  async run({ args, cwd }) {
575
- const { executeDev } = await import("./dev-Uq5ujP8a.mjs");
575
+ const { executeDev } = await import("./dev-B59JIfWO.mjs");
576
576
  return executeDev({
577
577
  cwd,
578
578
  port: args.port
@@ -609,7 +609,7 @@ const build = defineExec({
609
609
  },
610
610
  cwd: "agent",
611
611
  async run({ args, cwd }) {
612
- const { executeBuild } = await import("./build-Dfza2pRI.mjs");
612
+ const { executeBuild } = await import("./build-6jfaakgc.mjs");
613
613
  return executeBuild({
614
614
  cwd,
615
615
  skipTests: args.skipTests,
@@ -632,7 +632,7 @@ const eject = defineExec({
632
632
  },
633
633
  cwd: "agent",
634
634
  async run({ args, cwd }) {
635
- const { executeEject } = await import("./eject-31gjtaHF.mjs");
635
+ const { executeEject } = await import("./eject-C9WJyyr2.mjs");
636
636
  return executeEject({
637
637
  cwd,
638
638
  force: args.force
@@ -659,7 +659,7 @@ const deploy = defineExec({
659
659
  },
660
660
  cwd: "agent",
661
661
  async run({ args, cwd }) {
662
- const { executeDeploy } = await import("./deploy-B8lubiRT.mjs");
662
+ const { executeDeploy } = await import("./deploy-DvYeD8ia.mjs");
663
663
  return executeDeploy({
664
664
  cwd,
665
665
  server: args.server,
@@ -679,7 +679,7 @@ const del = defineExec({
679
679
  },
680
680
  cwd: "any",
681
681
  async run({ args, cwd }) {
682
- const { executeDelete } = await import("./delete-vbpjGzqs.mjs");
682
+ const { executeDelete } = await import("./delete-Dl_LSfvI.mjs");
683
683
  return executeDelete({
684
684
  cwd,
685
685
  server: args.server
@@ -708,7 +708,7 @@ const secret = defineCommand({
708
708
  },
709
709
  cwd: "any",
710
710
  async run({ args, mode, cwd }) {
711
- const { executeSecretPut, NO_INPUT, readStdin } = await import("./secret-BuMuFR4B.mjs");
711
+ const { executeSecretPut, NO_INPUT, readStdin } = await import("./secret-CVvSLIDV.mjs");
712
712
  const value = mode === "json" ? await readStdin() : void 0;
713
713
  if (mode === "json" && !value) throw new CliError(...NO_INPUT);
714
714
  return executeSecretPut(cwd, args.name, value, args.server);
@@ -730,7 +730,7 @@ const secret = defineCommand({
730
730
  },
731
731
  cwd: "any",
732
732
  async run({ args, cwd }) {
733
- const { executeSecretDelete } = await import("./secret-BuMuFR4B.mjs");
733
+ const { executeSecretDelete } = await import("./secret-CVvSLIDV.mjs");
734
734
  return executeSecretDelete(cwd, args.name, args.server);
735
735
  }
736
736
  }),
@@ -745,7 +745,7 @@ const secret = defineCommand({
745
745
  },
746
746
  cwd: "any",
747
747
  async run({ args, cwd }) {
748
- const { executeSecretList } = await import("./secret-BuMuFR4B.mjs");
748
+ const { executeSecretList } = await import("./secret-CVvSLIDV.mjs");
749
749
  return executeSecretList(cwd, args.server);
750
750
  }
751
751
  })
@@ -772,7 +772,7 @@ const storageStatus = defineExec({
772
772
  },
773
773
  cwd: "any",
774
774
  async run({ args, cwd }) {
775
- const { executeStorageStatus } = await import("./storage-DzRZ-eCw.mjs");
775
+ const { executeStorageStatus } = await import("./storage-BvUrnvM3.mjs");
776
776
  return executeStorageStatus(resolveStorageCwd(cwd, args.dir), args.server);
777
777
  }
778
778
  });
@@ -788,7 +788,7 @@ const storageEnable = defineExec({
788
788
  },
789
789
  cwd: "any",
790
790
  async run({ args, cwd }) {
791
- const { executeStorageEnable } = await import("./storage-DzRZ-eCw.mjs");
791
+ const { executeStorageEnable } = await import("./storage-BvUrnvM3.mjs");
792
792
  return executeStorageEnable(resolveStorageCwd(cwd, args.dir), args.server);
793
793
  }
794
794
  });
@@ -809,7 +809,7 @@ const storageDisable = defineExec({
809
809
  },
810
810
  cwd: "any",
811
811
  async run({ args, cwd }) {
812
- const { executeStorageDisable } = await import("./storage-DzRZ-eCw.mjs");
812
+ const { executeStorageDisable } = await import("./storage-BvUrnvM3.mjs");
813
813
  return executeStorageDisable(resolveStorageCwd(cwd, args.dir), {
814
814
  server: args.server,
815
815
  force: args.force
@@ -833,7 +833,7 @@ const logs = defineExec({
833
833
  },
834
834
  cwd: "any",
835
835
  async run({ args, cwd }) {
836
- const { executeLogs } = await import("./logs-BWVGSjLR.mjs");
836
+ const { executeLogs } = await import("./logs-9q-psa4q.mjs");
837
837
  return executeLogs(resolveStorageCwd(cwd, args.dir), {
838
838
  server: args.server,
839
839
  follow: args.follow
@@ -876,7 +876,7 @@ const mainCommand = defineCommand({
876
876
  },
877
877
  cwd: "none",
878
878
  async run({ args }) {
879
- const { executeLogin } = await import("./login-C71-qz8F.mjs");
879
+ const { executeLogin } = await import("./login-BBuM1sxH.mjs");
880
880
  return executeLogin({ server: args.server });
881
881
  }
882
882
  }),
@@ -892,7 +892,7 @@ const mainCommand = defineCommand({
892
892
  args: { json: sharedArgs.json },
893
893
  cwd: "none",
894
894
  async run({ mode }) {
895
- const { listTemplates } = await import("./_templates-Dxb_P2Wz.mjs");
895
+ const { listTemplates } = await import("./_templates-FI3xPEMj.mjs");
896
896
  const names = await listTemplates();
897
897
  if (mode === "human") {
898
898
  for (const name of names) log.message(name);
@@ -958,8 +958,13 @@ if (process.env.VITEST !== "true") {
958
958
  const assertKnownFlags = async () => {
959
959
  const unknown = await unknownFlagsForArgv(mainCommand, process.argv.slice(2));
960
960
  if (unknown.length === 0) return;
961
- log.error(`Unknown ${unknown.length === 1 ? "option" : "options"}: ${unknown.join(", ")}`);
962
- log.info("Run `aai <command> --help` to see the options it accepts.");
961
+ const label = `Unknown ${unknown.length === 1 ? "option" : "options"}: ${unknown.join(", ")}`;
962
+ const hint = "Run `aai <command> --help` to see the options it accepts.";
963
+ if (getOutputMode({}) === "json") await writeLine(`${JSON.stringify(fail("usage", label, hint))}\n`);
964
+ else {
965
+ log.error(label);
966
+ log.info(hint);
967
+ }
963
968
  process.exit(1);
964
969
  };
965
970
  runDefault().then(assertKnownFlags).then(() => runMain(mainCommand, { showUsage: usageForMode })).catch((err) => {
@@ -3,8 +3,9 @@ import { o as errorMessage$1, s as fileExists } from "./_utils-B8QmtFhK.mjs";
3
3
  import { n as withPreservedNodeEnv, t as DEDUPED_PEERS } from "./_vite-env-BNveawd1.mjs";
4
4
  import { existsSync, unlinkSync, writeFileSync } from "node:fs";
5
5
  import path from "node:path";
6
- import { isTextAssetPath, omitUndefined } from "@alexkroman1/aai/utils";
6
+ import { omitUndefined } from "@alexkroman1/aai/utils";
7
7
  import fs from "node:fs/promises";
8
+ import { isTextAssetPath } from "@alexkroman1/aai/internal";
8
9
  import { build } from "vite";
9
10
  //#region _default-html.ts
10
11
  /**
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import { t as buildClient } from "./client-bundler-BEIqgOtd.mjs";
2
+ import { t as buildClient } from "./client-bundler-CWnG42cU.mjs";
3
3
  export { buildClient };