@wirecat/amo-cli 0.1.1 → 0.3.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 (182) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/README.md +15 -10
  3. package/contracts/wirecat.json +55 -6
  4. package/dist/amo/button.d.ts +53 -0
  5. package/dist/amo/button.d.ts.map +1 -0
  6. package/dist/amo/button.js +234 -0
  7. package/dist/amo/button.js.map +1 -0
  8. package/dist/amo/oauth.d.ts +12 -3
  9. package/dist/amo/oauth.d.ts.map +1 -1
  10. package/dist/amo/oauth.js +19 -6
  11. package/dist/amo/oauth.js.map +1 -1
  12. package/dist/bin/amo.js +2 -2
  13. package/dist/bundle/agent-FDNP27SW.js +40 -0
  14. package/dist/bundle/{all-profiles-3KQVWDV4.js → all-profiles-PPUN52SP.js} +63 -21
  15. package/dist/bundle/amo.js +28 -26
  16. package/dist/bundle/{anthropic-N5NOX7K7.js → anthropic-RDNDT6ZP.js} +5 -5
  17. package/dist/bundle/{app-server-2MST5EZ5.js → app-server-MMALJDBP.js} +79 -68
  18. package/dist/bundle/{bun-4NHWOFX2.js → bun-Y4FRPURU.js} +2 -2
  19. package/dist/bundle/{bun-sqlite-DRSXPWPR.js → bun-sqlite-7NXJGZCO.js} +6 -6
  20. package/dist/bundle/{chunk-GNTJMB6X.js → chunk-2YEDK2XV.js} +4 -4
  21. package/dist/bundle/chunk-3NDMVXGS.js +80 -0
  22. package/dist/bundle/{chunk-Y37A3232.js → chunk-3RP57VDS.js} +114 -7
  23. package/dist/bundle/{chunk-ODNQU7DH.js → chunk-3YOZTGZ6.js} +43 -64
  24. package/dist/bundle/{chunk-ESZSMZKT.js → chunk-4EYPFFTN.js} +2 -2
  25. package/dist/bundle/{chunk-TZSUZGWM.js → chunk-4MVTSMWP.js} +2 -2
  26. package/dist/bundle/{chunk-LJQUYECN.js → chunk-5DPMNYQT.js} +1 -1
  27. package/dist/bundle/{chunk-7PKFYX7V.js → chunk-5POLHHDZ.js} +8 -8
  28. package/dist/bundle/{chunk-A33TIM5D.js → chunk-5RXH35ZA.js} +225 -225
  29. package/dist/bundle/{chunk-BVMNXI53.js → chunk-77FP6AWC.js} +25 -25
  30. package/dist/bundle/{chunk-L6AFE73L.js → chunk-7E6QSIRQ.js} +1 -1
  31. package/dist/bundle/chunk-7SBAHYZW.js +734 -0
  32. package/dist/bundle/{chunk-GQ7VFIYM.js → chunk-7USADF2W.js} +23 -7
  33. package/dist/bundle/{chunk-AHJ4W2IL.js → chunk-7VSYOMEH.js} +2 -2
  34. package/dist/bundle/chunk-7Z6NYSAN.js +52 -0
  35. package/dist/bundle/chunk-AYR6FIXN.js +30 -0
  36. package/dist/bundle/{chunk-ADEWU4P4.js → chunk-B4ITT55D.js} +1 -1
  37. package/dist/bundle/{chunk-AUBB72VF.js → chunk-BKTLAXUK.js} +41 -10
  38. package/dist/bundle/{chunk-63F65DHU.js → chunk-BYVDMPLX.js} +2 -2
  39. package/dist/bundle/{chunk-V77XNPXG.js → chunk-CQ472K6W.js} +11 -11
  40. package/dist/bundle/{chunk-FKR3M62D.js → chunk-CUZISGWH.js} +13 -13
  41. package/dist/bundle/{chunk-LDEBZ3IX.js → chunk-D6UPCAPD.js} +1 -1
  42. package/dist/bundle/{chunk-P3WQRTYZ.js → chunk-E2DLRLJ5.js} +1 -1
  43. package/dist/bundle/{chunk-NJYAL3UW.js → chunk-EHULZEXQ.js} +1 -1
  44. package/dist/bundle/chunk-EKNP326Q.js +108 -0
  45. package/dist/bundle/{chunk-DJD7TBYG.js → chunk-ELJGALVX.js} +76 -74
  46. package/dist/bundle/{chunk-RPWAJYI6.js → chunk-FI2TP6TY.js} +3 -3
  47. package/dist/bundle/{chunk-CDY2NJFE.js → chunk-FPDTIQOK.js} +2 -2
  48. package/dist/bundle/{chunk-NC76INB2.js → chunk-FPIUFSWK.js} +3099 -2266
  49. package/dist/bundle/{chunk-SZ2V62HB.js → chunk-GCUFGDKE.js} +2 -2
  50. package/dist/bundle/{chunk-LRBPT7LQ.js → chunk-GKP7CKW2.js} +6 -6
  51. package/dist/bundle/chunk-H34RBRS3.js +209 -0
  52. package/dist/bundle/{chunk-O2UCU52O.js → chunk-HQH4YPO5.js} +134 -569
  53. package/dist/bundle/{chunk-TNUFLULO.js → chunk-I4QCJZW7.js} +8 -8
  54. package/dist/bundle/{chunk-DXGGCGRP.js → chunk-IDQ7BNCZ.js} +14 -14
  55. package/dist/bundle/{chunk-JMDLPBXK.js → chunk-IEAPNTHT.js} +17 -17
  56. package/dist/bundle/{chunk-XQL7FEF4.js → chunk-ILUREFWJ.js} +9 -9
  57. package/dist/bundle/{chunk-QRQYUHCZ.js → chunk-IYUWVMGP.js} +12 -12
  58. package/dist/bundle/chunk-JTFAG3BX.js +338 -0
  59. package/dist/bundle/{chunk-CHUKWON6.js → chunk-JZ2AITOE.js} +3 -3
  60. package/dist/bundle/{chunk-JR6TSMFX.js → chunk-KEOKH2OZ.js} +103 -70
  61. package/dist/bundle/{chunk-UMVRT7VQ.js → chunk-KKXF6TSS.js} +1 -1
  62. package/dist/bundle/{chunk-5E5R65CA.js → chunk-KTLCQ7GC.js} +2 -2
  63. package/dist/bundle/{chunk-QDMXZZG4.js → chunk-KZDBO2FT.js} +18 -8
  64. package/dist/bundle/{chunk-VX37MPTJ.js → chunk-L2ZQDTDU.js} +1 -1
  65. package/dist/bundle/{chunk-CUZRHF34.js → chunk-L3JDQNBC.js} +4 -4
  66. package/dist/bundle/{chunk-3IRJDH2U.js → chunk-L72UALL5.js} +2 -100
  67. package/dist/bundle/{chunk-XRTD2GCU.js → chunk-LOSOWTAZ.js} +19 -258
  68. package/dist/bundle/{chunk-LGQXGOPJ.js → chunk-LYRICHEK.js} +2 -2
  69. package/dist/bundle/{chunk-UBRREVLJ.js → chunk-MMOEAH5G.js} +2 -2
  70. package/dist/bundle/{chunk-EQ7A6NA6.js → chunk-MPXKBF37.js} +1 -1
  71. package/dist/bundle/{chunk-SMSTGO2G.js → chunk-MYMBPQPQ.js} +4 -4
  72. package/dist/bundle/chunk-N4A6E2LL.js +559 -0
  73. package/dist/bundle/{chunk-5HGGG3QO.js → chunk-NJ2LJKNH.js} +16 -3
  74. package/dist/bundle/{chunk-TGEQNS6G.js → chunk-OMH3WP7F.js} +1 -1
  75. package/dist/bundle/{chunk-ULXQ5MJM.js → chunk-ORFLQGWH.js} +4 -4
  76. package/dist/bundle/{chunk-DQV2IKCF.js → chunk-PFZ7WG2B.js} +10 -3
  77. package/dist/bundle/{chunk-5D4AEUVA.js → chunk-PL5P7UKW.js} +434 -1
  78. package/dist/bundle/{chunk-6RS7OYTD.js → chunk-Q2YVY7IR.js} +3 -3
  79. package/dist/bundle/{chunk-DOSJONCX.js → chunk-QHA33ZS6.js} +7 -7
  80. package/dist/bundle/{chunk-JH3UOHRE.js → chunk-QQT7WUR4.js} +4 -4
  81. package/dist/bundle/{chunk-EROSAUNP.js → chunk-R23DRW2T.js} +5 -5
  82. package/dist/bundle/{chunk-WCYCUTSK.js → chunk-SBQ5MFHM.js} +7 -7
  83. package/dist/bundle/{chunk-DAY6TSPF.js → chunk-SJYVKR54.js} +62 -50
  84. package/dist/bundle/{chunk-T2UDLX76.js → chunk-SJZ52MZE.js} +6 -6
  85. package/dist/bundle/{chunk-ZM7I52EP.js → chunk-T6D34X5S.js} +3 -4
  86. package/dist/bundle/{chunk-P5LYZRKW.js → chunk-TCDER3G7.js} +1586 -749
  87. package/dist/bundle/{chunk-2I5UVMLW.js → chunk-TWZF7VO6.js} +1726 -1159
  88. package/dist/bundle/{chunk-VVHRQ46X.js → chunk-UA7C57IB.js} +2 -2
  89. package/dist/bundle/{chunk-5SBLU7D7.js → chunk-UM6SDFB6.js} +1 -1
  90. package/dist/bundle/{chunk-7U5HJEPZ.js → chunk-UOPP6ORQ.js} +21 -19
  91. package/dist/bundle/{chunk-U7RLVJ34.js → chunk-UT3ODJMI.js} +4 -4
  92. package/dist/bundle/{chunk-7GTUZY7M.js → chunk-UZLT6VSP.js} +3 -3
  93. package/dist/bundle/{chunk-5RLUHTK6.js → chunk-V3ZWYMXT.js} +1 -1
  94. package/dist/bundle/{chunk-LSND5QYI.js → chunk-VD7HD25M.js} +9 -9
  95. package/dist/bundle/{chunk-PFO76YFP.js → chunk-VEGNZPQU.js} +18 -18
  96. package/dist/bundle/{chunk-5Z5PEEKP.js → chunk-VFU25P57.js} +4 -4
  97. package/dist/bundle/{chunk-4ZAK773N.js → chunk-VJHOBOJR.js} +3 -3
  98. package/dist/bundle/{chunk-PM77PRB6.js → chunk-VPBSZ4HQ.js} +185 -162
  99. package/dist/bundle/{chunk-Q2VNBY4Y.js → chunk-VY27K2SH.js} +746 -1205
  100. package/dist/bundle/{chunk-XEFAMLSD.js → chunk-W4KY5JF5.js} +3 -3
  101. package/dist/bundle/{chunk-73CXFE36.js → chunk-WBWVBEHH.js} +29 -1
  102. package/dist/bundle/{chunk-NHXJYS4R.js → chunk-XDT74W5P.js} +32 -28
  103. package/dist/bundle/{chunk-EPOV5UIO.js → chunk-XI75EKLG.js} +11 -11
  104. package/dist/bundle/{chunk-2B24PDH7.js → chunk-XM2G62YF.js} +8 -6
  105. package/dist/bundle/{chunk-5D4Z2B5B.js → chunk-YSOGGUK3.js} +9 -9
  106. package/dist/bundle/chunk-YVO2YGML.js +353 -0
  107. package/dist/bundle/{chunk-EQUKVVHX.js → chunk-ZIFEIJRK.js} +7 -7
  108. package/dist/bundle/{cli-QVWTXADI.js → cli-GAO7LDDA.js} +150 -103
  109. package/dist/bundle/command-contract-RLIBGIDT.js +39 -0
  110. package/dist/bundle/{command-server-entry-5VL5U5EE.js → command-server-entry-BCDJP7XE.js} +28 -28
  111. package/dist/bundle/{decode-SQ5WGNDX.js → decode-OY2GR442.js} +5 -5
  112. package/dist/bundle/{dispatch-LA4DFXJD.js → dispatch-JWEJCBTF.js} +8 -8
  113. package/dist/bundle/dist-PAKDDIBT.js +191 -0
  114. package/dist/bundle/{echarts-25Z3RINX.js → echarts-AHEPEA5P.js} +2 -2
  115. package/dist/bundle/{embed-BNOTNXMA.js → embed-RVSUV54Z.js} +6 -6
  116. package/dist/bundle/{embedder-BCUT7KKV.js → embedder-GRZXZUXR.js} +9 -9
  117. package/dist/bundle/{failure-PKAC6XCT.js → failure-DDCSR54L.js} +2 -2
  118. package/dist/bundle/{first-run-EO5K5GME.js → first-run-G3WI4DH4.js} +12 -12
  119. package/dist/bundle/first-screen-6MLCMW2U.js +39 -0
  120. package/dist/bundle/{instructions-VLM3QAYB.js → instructions-NWQC5IP4.js} +1 -1
  121. package/dist/bundle/{mcp-7ILNMJH5.js → mcp-KGWT6TGO.js} +2 -2
  122. package/dist/bundle/meeting-combined-SVTFVZNJ.js +24 -0
  123. package/dist/bundle/{meeting-model-GHMMUQ34.js → meeting-model-I6T5HIZ5.js} +11 -11
  124. package/dist/bundle/{meeting-semantic-BMP6323L.js → meeting-semantic-47UA5JBF.js} +6 -6
  125. package/dist/bundle/{node-CT3N3TNL.js → node-7VXN7F4B.js} +2 -2
  126. package/dist/bundle/{node-sqlite-MELD2SBX.js → node-sqlite-BSEON57L.js} +7 -7
  127. package/dist/bundle/{oauth-YBH5OKC2.js → oauth-V6UAT4YD.js} +8 -8
  128. package/dist/bundle/{open-WNSBWTAG.js → open-7LVAY7ZU.js} +5 -5
  129. package/dist/bundle/{openai-XSNMNLW6.js → openai-OIEH342H.js} +15 -15
  130. package/dist/bundle/{process-I2QKOMM7.js → process-PTUCNLZ7.js} +1 -1
  131. package/dist/bundle/{program-DV73CIGP.js → program-S5WY5IZP.js} +643 -852
  132. package/dist/bundle/{prompt-SOG4AKPM.js → prompt-7XWTEQ62.js} +5 -5
  133. package/dist/bundle/{recognize-WMQLWMXH.js → recognize-HGIAJXDR.js} +4 -4
  134. package/dist/bundle/{remote-4BTFOLFY.js → remote-X4SVEMHS.js} +9 -9
  135. package/dist/bundle/{rerank-LJ3TWRNV.js → rerank-QWM3DQMU.js} +7 -7
  136. package/dist/bundle/{serve-B6UANKXN.js → serve-VVG3TXYT.js} +10 -10
  137. package/dist/bundle/{server-YRH6GJ5Z.js → server-EHYK62BJ.js} +73 -61
  138. package/dist/bundle/server-WRPTBVNW.js +86 -0
  139. package/dist/bundle/source-YISMYLBQ.js +44 -0
  140. package/dist/bundle/{sqlite-runtime-R7QFWFE7.js → sqlite-runtime-MCKXDNYC.js} +6 -6
  141. package/dist/bundle/{state-DIJ5YUOE.js → state-MYNYQJCT.js} +6 -6
  142. package/dist/bundle/store-A7R2SZVD.js +34 -0
  143. package/dist/bundle/{store-MYTYDV6A.js → store-B7O3F3QB.js} +28 -21
  144. package/dist/bundle/{store-6WFWW7EC.js → store-FPIU2546.js} +24 -23
  145. package/dist/bundle/store-maintenance-command-D55FRTIK.js +73 -0
  146. package/dist/bundle/surface-3EX6IGHW.js +72 -0
  147. package/dist/bundle/writer-XDHZ54JD.js +46 -0
  148. package/dist/commands/session.d.ts +23 -0
  149. package/dist/commands/session.d.ts.map +1 -1
  150. package/dist/commands/session.js +115 -45
  151. package/dist/commands/session.js.map +1 -1
  152. package/dist/identity.js +1 -1
  153. package/dist/identity.js.map +1 -1
  154. package/dist/program.d.ts.map +1 -1
  155. package/dist/program.js +3 -1
  156. package/dist/program.js.map +1 -1
  157. package/dist/reasons.d.ts.map +1 -1
  158. package/dist/reasons.js +2 -0
  159. package/dist/reasons.js.map +1 -1
  160. package/dist/setup/flow.d.ts.map +1 -1
  161. package/dist/setup/flow.js +74 -4
  162. package/dist/setup/flow.js.map +1 -1
  163. package/dist/setup/texts.en.json +22 -1
  164. package/dist/setup/texts.es.json +22 -1
  165. package/dist/setup/texts.ru.json +22 -1
  166. package/dist/version.d.ts +1 -1
  167. package/dist/version.js +1 -1
  168. package/package.json +5 -3
  169. package/scenarios/first-sync.md +23 -0
  170. package/scenarios/keep-in-sync.md +18 -0
  171. package/scenarios/safe-agent-writes.md +21 -0
  172. package/skills/amo-cli/SKILL.md +1 -1
  173. package/skills/amo-cli/references/mcp.md +1 -1
  174. package/skills/amo-cli/references/setup.md +9 -3
  175. package/dist/bundle/command-contract-QBUQBXH7.js +0 -39
  176. package/dist/bundle/first-screen-GMN3T6RW.js +0 -39
  177. package/dist/bundle/meeting-combined-LAMF7S2B.js +0 -24
  178. package/dist/bundle/server-S6XD6V6E.js +0 -77
  179. package/dist/bundle/source-DGFTA2TN.js +0 -42
  180. package/dist/bundle/store-FJCNZULV.js +0 -32
  181. package/dist/bundle/store-maintenance-command-B5TMKFMG.js +0 -68
  182. package/dist/bundle/writer-GP7VIMAU.js +0 -44
@@ -0,0 +1,108 @@
1
+ import { createRequire as __bundleRequire } from "node:module";
2
+ const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ CLIENT_INFO_META_KEY
5
+ } from "./chunk-PL5P7UKW.js";
6
+ import {
7
+ agentOf,
8
+ clientHash,
9
+ currentCaller
10
+ } from "./chunk-SBQ5MFHM.js";
11
+ import {
12
+ __name
13
+ } from "./chunk-ZVVMGPBJ.js";
14
+
15
+ // node_modules/.pnpm/@wirecat+cli-core@0.720.0_@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typ_891204b7e0cfbcc49dd71e2850e8663f/node_modules/@wirecat/cli-core/dist/mcp/caller.js
16
+ var callingAgent = /* @__PURE__ */ __name((fallback, caller = currentCaller()) => {
17
+ const client = caller?.agent?.client?.name;
18
+ if (client && client !== "unknown")
19
+ return client;
20
+ const kind = caller?.agent?.kind;
21
+ return kind && kind !== "mcp-client" ? kind : fallback;
22
+ }, "callingAgent");
23
+ var CALLER_META_KEY = "wirecat.dev/caller";
24
+ var PROXY_CLIENT_NAME = "all-profiles";
25
+ var NAME = /^[\w .@()/+-]{1,64}$/;
26
+ var plain = /* @__PURE__ */ __name((value) => typeof value === "string" && NAME.test(value.trim()) ? value.trim() : void 0, "plain");
27
+ var clientFrom = /* @__PURE__ */ __name((value) => {
28
+ if (!value || typeof value !== "object")
29
+ return void 0;
30
+ const { name, version } = value;
31
+ const named = plain(name);
32
+ if (!named)
33
+ return void 0;
34
+ const versioned = plain(version);
35
+ return { name: named, ...versioned ? { version: versioned } : {} };
36
+ }, "clientFrom");
37
+ var callerOf = /* @__PURE__ */ __name((ctx, tool, source) => {
38
+ const meta = ctx?.mcpReq?._meta;
39
+ const requestId = ctx?.mcpReq?.id;
40
+ const initialized = source.client?.();
41
+ const proxied = initialized?.name === PROXY_CLIENT_NAME && !ctx?.http ? passedOn(meta?.[CALLER_META_KEY], tool) : void 0;
42
+ if (proxied)
43
+ return proxied;
44
+ const client = clientFrom(meta?.[CLIENT_INFO_META_KEY]) ?? clientFrom(initialized);
45
+ const mcp = /* @__PURE__ */ __name((connection) => ({
46
+ tool,
47
+ ...requestId === void 0 ? {} : { request_id: String(requestId) },
48
+ ...connection ? { connection_id: connection } : {}
49
+ }), "mcp");
50
+ const auth = ctx?.http?.authInfo;
51
+ if (auth) {
52
+ const registered = plain(auth.extra?.clientName);
53
+ return {
54
+ via: "mcp-http",
55
+ agent: {
56
+ kind: "mcp-client",
57
+ session_id: ctx?.sessionId ?? null,
58
+ client: {
59
+ name: registered ?? client?.name ?? "unknown",
60
+ ...client?.version ? { version: client.version } : {},
61
+ id: clientHash(auth.clientId)
62
+ }
63
+ },
64
+ mcp: mcp(ctx?.sessionId)
65
+ };
66
+ }
67
+ const agent = agentOf(source.env) ?? { kind: "mcp-client", session_id: null };
68
+ return { via: "mcp-stdio", agent: { ...agent, ...client ? { client } : {} }, mcp: mcp(source.connectionId) };
69
+ }, "callerOf");
70
+ var passedOn = /* @__PURE__ */ __name((value, tool) => {
71
+ if (!value || typeof value !== "object")
72
+ return void 0;
73
+ const { via, agent, mcp } = value;
74
+ if (via !== "mcp-stdio" && via !== "mcp-http")
75
+ return void 0;
76
+ const a = agent && typeof agent === "object" ? agent : void 0;
77
+ const kind = plain(a?.kind);
78
+ const session = typeof a?.session_id === "string" && /^[A-Za-z0-9._:-]{1,128}$/.test(a.session_id) ? a.session_id : null;
79
+ const client = clientFrom(a?.client);
80
+ const id = a?.client && typeof a.client === "object" ? a.client.id : void 0;
81
+ const m = mcp && typeof mcp === "object" ? mcp : {};
82
+ const request = plain(m.request_id);
83
+ const connection = typeof m.connection_id === "string" && /^[\w-]{1,128}$/.test(m.connection_id) ? m.connection_id : void 0;
84
+ return {
85
+ via,
86
+ ...kind ? {
87
+ agent: {
88
+ kind,
89
+ session_id: session,
90
+ ...a?.from_chat === true ? { from_chat: true } : {},
91
+ ...client ? { client: { ...client, ...typeof id === "string" && /^[0-9a-f]{8}$/.test(id) ? { id } : {} } } : {}
92
+ }
93
+ } : {},
94
+ mcp: {
95
+ tool,
96
+ ...request ? { request_id: request } : {},
97
+ ...connection ? { connection_id: connection } : {},
98
+ proxied: true
99
+ }
100
+ };
101
+ }, "passedOn");
102
+
103
+ export {
104
+ callingAgent,
105
+ CALLER_META_KEY,
106
+ PROXY_CLIENT_NAME,
107
+ callerOf
108
+ };
@@ -19,11 +19,11 @@ import {
19
19
  string,
20
20
  text,
21
21
  unknown
22
- } from "./chunk-AUBB72VF.js";
22
+ } from "./chunk-BKTLAXUK.js";
23
23
  import {
24
24
  CliError,
25
25
  visibleControls
26
- } from "./chunk-SZ2V62HB.js";
26
+ } from "./chunk-GCUFGDKE.js";
27
27
  import {
28
28
  __commonJS,
29
29
  __name,
@@ -1896,7 +1896,7 @@ var require_cli_table3 = __commonJS({
1896
1896
  }
1897
1897
  });
1898
1898
 
1899
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/paths.js
1899
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/paths.js
1900
1900
  import { realpathSync } from "node:fs";
1901
1901
  import { homedir, userInfo } from "node:os";
1902
1902
  import { join, posix, win32 } from "node:path";
@@ -1970,7 +1970,64 @@ var homeIsMoved = /* @__PURE__ */ __name(({ env = process.env, platform = proces
1970
1970
  var isMovedRun = /* @__PURE__ */ __name((options) => pathsAreOverridden(options) || homeIsMoved(options), "isMovedRun");
1971
1971
  var configFilePath = /* @__PURE__ */ __name((configDir, fileName = "config.json") => join(configDir, fileName), "configFilePath");
1972
1972
 
1973
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/retry.js
1973
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/drain.js
1974
+ var waitForDrain = /* @__PURE__ */ __name((stream, signal) => {
1975
+ if (signal?.aborted)
1976
+ return Promise.reject(signal.reason);
1977
+ if (stream.destroyed)
1978
+ return Promise.reject(new Error("output stream closed"));
1979
+ if (!stream.writableNeedDrain)
1980
+ return Promise.resolve();
1981
+ return new Promise((resolve2, reject) => {
1982
+ const cleanup = /* @__PURE__ */ __name(() => {
1983
+ stream.off("drain", drained).off("error", failed).off("close", closed);
1984
+ signal?.removeEventListener("abort", aborted);
1985
+ }, "cleanup");
1986
+ const drained = /* @__PURE__ */ __name(() => {
1987
+ cleanup();
1988
+ resolve2();
1989
+ }, "drained");
1990
+ const failed = /* @__PURE__ */ __name((error) => {
1991
+ cleanup();
1992
+ reject(error);
1993
+ }, "failed");
1994
+ const closed = /* @__PURE__ */ __name(() => failed(new Error("output stream closed before drain")), "closed");
1995
+ const aborted = /* @__PURE__ */ __name(() => failed(signal?.reason), "aborted");
1996
+ stream.once("drain", drained).once("error", failed).once("close", closed);
1997
+ signal?.addEventListener("abort", aborted, { once: true });
1998
+ });
1999
+ }, "waitForDrain");
2000
+
2001
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/streams.js
2002
+ var processStreams = {
2003
+ drain: /* @__PURE__ */ __name(async (signal) => {
2004
+ await Promise.all([waitForDrain(process.stdout, signal), waitForDrain(process.stderr, signal)]);
2005
+ }, "drain"),
2006
+ data: /* @__PURE__ */ __name((text2) => {
2007
+ process.stdout.write(`${text2}
2008
+ `);
2009
+ }, "data"),
2010
+ diagnostic: /* @__PURE__ */ __name((text2) => {
2011
+ process.stderr.write(`${text2}
2012
+ `);
2013
+ }, "diagnostic"),
2014
+ progress: /* @__PURE__ */ __name((text2) => {
2015
+ process.stderr.write(`\r${text2.padEnd(72)}${text2 === "" ? "\r" : ""}`);
2016
+ }, "progress")
2017
+ };
2018
+ var captureStreams = /* @__PURE__ */ __name(() => {
2019
+ const stdout = [];
2020
+ const stderr = [];
2021
+ return {
2022
+ stdout,
2023
+ stderr,
2024
+ data: /* @__PURE__ */ __name((text2) => stdout.push(text2), "data"),
2025
+ diagnostic: /* @__PURE__ */ __name((text2) => stderr.push(text2), "diagnostic"),
2026
+ progress: /* @__PURE__ */ __name((text2) => stderr.push(text2), "progress")
2027
+ };
2028
+ }, "captureStreams");
2029
+
2030
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/retry.js
1974
2031
  var DEFAULT_RETRY = {
1975
2032
  retries: 1,
1976
2033
  baseDelayMs: 250,
@@ -1982,7 +2039,7 @@ var backoffMs = /* @__PURE__ */ __name((attempt, config, random) => {
1982
2039
  return Math.round(random() * ceiling);
1983
2040
  }, "backoffMs");
1984
2041
 
1985
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/result-fields.js
2042
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/result-fields.js
1986
2043
  var forbidden = /* @__PURE__ */ new Set(["__proto__", "prototype", "constructor"]);
1987
2044
  var validate = /* @__PURE__ */ __name((paths) => {
1988
2045
  if (paths.length === 0 || paths.length > 128 || paths.some((path) => path.length > 256 || !/^[A-Za-z][A-Za-z0-9_]*(?:\.[A-Za-z][A-Za-z0-9_]*)*$/.test(path) || path.split(".").some((part) => forbidden.has(part))))
@@ -2047,7 +2104,7 @@ var projectFields = /* @__PURE__ */ __name((value, fields) => {
2047
2104
  return project(value, fields);
2048
2105
  }, "projectFields");
2049
2106
 
2050
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/batch.js
2107
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/batch.js
2051
2108
  var BATCH_LIMITS = Object.freeze({
2052
2109
  requests: 32,
2053
2110
  input_bytes: 262144,
@@ -2174,7 +2231,7 @@ var runBatch = /* @__PURE__ */ __name(async (requests, options = {}) => {
2174
2231
  };
2175
2232
  }, "runBatch");
2176
2233
 
2177
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/config.js
2234
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/config.js
2178
2235
  import { randomBytes } from "node:crypto";
2179
2236
  import { mkdirSync, readFileSync, renameSync, rmSync, writeFileSync } from "node:fs";
2180
2237
  import { dirname, join as join2 } from "node:path";
@@ -2218,16 +2275,16 @@ var saveConfigFile = /* @__PURE__ */ __name((path, config) => {
2218
2275
  `, 384);
2219
2276
  }, "saveConfigFile");
2220
2277
 
2221
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/constants.js
2278
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/constants.js
2222
2279
  var BASE_CONSTANTS = new URL("../constants.json", new URL("constants.js", import.meta.resolve("@wirecat/cli-base")).href);
2223
2280
  var baseConstantsSchema = object({});
2224
2281
  var LayerSchema = record(string(), unknown());
2225
2282
 
2226
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/credentials.js
2283
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/credentials.js
2227
2284
  import { readFileSync as readFileSync2 } from "node:fs";
2228
2285
  import { join as join3, resolve } from "node:path";
2229
2286
 
2230
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/keyring.js
2287
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/keyring.js
2231
2288
  import { createRequire } from "node:module";
2232
2289
  var ENTRY_OPTIONS = { linux: { store: "secret-service" } };
2233
2290
  var require2 = createRequire(new URL("keyring.js", import.meta.resolve("@wirecat/cli-base")).href);
@@ -2253,7 +2310,7 @@ var systemKeyring = {
2253
2310
  delete: /* @__PURE__ */ __name((service, account) => entry(service, account).deletePassword(), "delete")
2254
2311
  };
2255
2312
 
2256
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/credentials.js
2313
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/credentials.js
2257
2314
  var keyringService = /* @__PURE__ */ __name((service, _configDir, _isolated) => service, "keyringService");
2258
2315
  var movedRunService = /* @__PURE__ */ __name((service, configDir) => `${service}:${resolve(configDir)}`, "movedRunService");
2259
2316
  var warnedRuns = /* @__PURE__ */ new WeakSet();
@@ -2398,7 +2455,7 @@ var Credentials = class {
2398
2455
  }
2399
2456
  };
2400
2457
 
2401
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/time.js
2458
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/time.js
2402
2459
  var abortError = /* @__PURE__ */ __name(() => new DOMException("The operation was aborted.", "AbortError"), "abortError");
2403
2460
  var realSleep = /* @__PURE__ */ __name((ms, signal) => new Promise((resolve2, reject) => {
2404
2461
  if (signal?.aborted) {
@@ -2411,12 +2468,13 @@ var realSleep = /* @__PURE__ */ __name((ms, signal) => new Promise((resolve2, re
2411
2468
  reject(abortError());
2412
2469
  }, { once: true });
2413
2470
  }), "realSleep");
2471
+ var monotonic = /* @__PURE__ */ __name(() => performance.now(), "monotonic");
2414
2472
  var wallClock = /* @__PURE__ */ __name(() => /* @__PURE__ */ new Date(), "wallClock");
2415
2473
 
2416
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/logging.js
2474
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/logging.js
2417
2475
  import { appendFileSync } from "node:fs";
2418
2476
 
2419
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/log.js
2477
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/log.js
2420
2478
  var LOG_SEVERITIES = ["trace", "debug", "info", "warn", "error", "fatal"];
2421
2479
  var logRecordSchema = strictObject({
2422
2480
  time: isoTime,
@@ -2494,7 +2552,7 @@ var traceIdOf = /* @__PURE__ */ __name((traceparent) => {
2494
2552
  return traceId;
2495
2553
  }, "traceIdOf");
2496
2554
 
2497
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/logging.js
2555
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/logging.js
2498
2556
  var REDACTED_FIELDS = [
2499
2557
  "authorization",
2500
2558
  "Authorization",
@@ -2588,7 +2646,7 @@ var silent = {
2588
2646
  }, "error")
2589
2647
  };
2590
2648
 
2591
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/pretty.js
2649
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/pretty.js
2592
2650
  var import_cli_table3 = __toESM(require_cli_table3(), 1);
2593
2651
  import { styleText } from "node:util";
2594
2652
  var renderPretty = /* @__PURE__ */ __name((value, options) => {
@@ -2663,64 +2721,7 @@ var BORDERLESS = {
2663
2721
  middle: ""
2664
2722
  };
2665
2723
 
2666
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/drain.js
2667
- var waitForDrain = /* @__PURE__ */ __name((stream, signal) => {
2668
- if (signal?.aborted)
2669
- return Promise.reject(signal.reason);
2670
- if (stream.destroyed)
2671
- return Promise.reject(new Error("output stream closed"));
2672
- if (!stream.writableNeedDrain)
2673
- return Promise.resolve();
2674
- return new Promise((resolve2, reject) => {
2675
- const cleanup = /* @__PURE__ */ __name(() => {
2676
- stream.off("drain", drained).off("error", failed).off("close", closed);
2677
- signal?.removeEventListener("abort", aborted);
2678
- }, "cleanup");
2679
- const drained = /* @__PURE__ */ __name(() => {
2680
- cleanup();
2681
- resolve2();
2682
- }, "drained");
2683
- const failed = /* @__PURE__ */ __name((error) => {
2684
- cleanup();
2685
- reject(error);
2686
- }, "failed");
2687
- const closed = /* @__PURE__ */ __name(() => failed(new Error("output stream closed before drain")), "closed");
2688
- const aborted = /* @__PURE__ */ __name(() => failed(signal?.reason), "aborted");
2689
- stream.once("drain", drained).once("error", failed).once("close", closed);
2690
- signal?.addEventListener("abort", aborted, { once: true });
2691
- });
2692
- }, "waitForDrain");
2693
-
2694
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/streams.js
2695
- var processStreams = {
2696
- drain: /* @__PURE__ */ __name(async (signal) => {
2697
- await Promise.all([waitForDrain(process.stdout, signal), waitForDrain(process.stderr, signal)]);
2698
- }, "drain"),
2699
- data: /* @__PURE__ */ __name((text2) => {
2700
- process.stdout.write(`${text2}
2701
- `);
2702
- }, "data"),
2703
- diagnostic: /* @__PURE__ */ __name((text2) => {
2704
- process.stderr.write(`${text2}
2705
- `);
2706
- }, "diagnostic"),
2707
- progress: /* @__PURE__ */ __name((text2) => {
2708
- process.stderr.write(`\r${text2.padEnd(72)}${text2 === "" ? "\r" : ""}`);
2709
- }, "progress")
2710
- };
2711
- var captureStreams = /* @__PURE__ */ __name(() => {
2712
- const stdout = [];
2713
- const stderr = [];
2714
- return {
2715
- stdout,
2716
- stderr,
2717
- data: /* @__PURE__ */ __name((text2) => stdout.push(text2), "data"),
2718
- diagnostic: /* @__PURE__ */ __name((text2) => stderr.push(text2), "diagnostic"),
2719
- progress: /* @__PURE__ */ __name((text2) => stderr.push(text2), "progress")
2720
- };
2721
- }, "captureStreams");
2722
-
2723
- // node_modules/.pnpm/@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/renderer.js
2724
+ // node_modules/.pnpm/@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/renderer.js
2724
2725
  var createRenderer = /* @__PURE__ */ __name(({ format, color, streams = processStreams, quiet = false }) => {
2725
2726
  const mark = /* @__PURE__ */ __name((symbol, message) => format === "pretty" ? `${symbol} ${visibleControls(message)}` : visibleControls(message), "mark");
2726
2727
  const say = /* @__PURE__ */ __name((symbol) => (message) => {
@@ -2775,6 +2776,7 @@ export {
2775
2776
  keyringService,
2776
2777
  Credentials,
2777
2778
  realSleep,
2779
+ monotonic,
2778
2780
  wallClock,
2779
2781
  defineLogEvents,
2780
2782
  isContentKey,
@@ -9,14 +9,14 @@ import {
9
9
  toPerson,
10
10
  toPipeline,
11
11
  toUser
12
- } from "./chunk-LDEBZ3IX.js";
12
+ } from "./chunk-D6UPCAPD.js";
13
13
  import {
14
14
  values_exports
15
- } from "./chunk-2I5UVMLW.js";
15
+ } from "./chunk-TWZF7VO6.js";
16
16
  import {
17
17
  CliError,
18
18
  isCliError
19
- } from "./chunk-SZ2V62HB.js";
19
+ } from "./chunk-GCUFGDKE.js";
20
20
  import {
21
21
  __name
22
22
  } from "./chunk-ZVVMGPBJ.js";
@@ -2,12 +2,12 @@ import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  parseReference
5
- } from "./chunk-QRQYUHCZ.js";
5
+ } from "./chunk-IYUWVMGP.js";
6
6
  import {
7
7
  __name
8
8
  } from "./chunk-ZVVMGPBJ.js";
9
9
 
10
- // node_modules/.pnpm/@wirecat+cli-core@0.691.0_@wirecat+cli-base@0.113.0_commander@15.0.0_esbuild@0.28.2_typ_9a2e508bb6f63e7e29f0d776540ec8fd/node_modules/@wirecat/cli-core/dist/domain/links.js
10
+ // node_modules/.pnpm/@wirecat+cli-core@0.720.0_@wirecat+cli-base@0.126.1_commander@15.0.0_esbuild@0.28.2_typ_891204b7e0cfbcc49dd71e2850e8663f/node_modules/@wirecat/cli-core/dist/domain/links.js
11
11
  var LINK_VERSION = "v1";
12
12
  var DEFAULT_LINK_CONFIG = { base: "https://wirecat.dev/o", enabled: true };
13
13
  var APP_PREFIX = "wirecat://open";