@wirecat/mail-cli 0.32.0 → 0.34.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 (135) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/contracts/wirecat.json +2 -2
  3. package/dist/bin/mail.js +2 -2
  4. package/dist/bundle/{all-profiles-OTCWJSJS.js → all-profiles-2KUKROHY.js} +10 -10
  5. package/dist/bundle/{anthropic-GUXHDK32.js → anthropic-E5KRCEVC.js} +8 -8
  6. package/dist/bundle/{app-server-GX7DOE4O.js → app-server-HIQ3QO5K.js} +60 -52
  7. package/dist/bundle/{bun-V5QLYBZU.js → bun-KARJPE5D.js} +2 -2
  8. package/dist/bundle/{bun-sqlite-AXD5CCO3.js → bun-sqlite-NHGX6ZUN.js} +6 -6
  9. package/dist/bundle/{chunk-4YNUQGDP.js → chunk-26DYRMXE.js} +1 -1
  10. package/dist/bundle/{chunk-3URYKAJP.js → chunk-2GDLJKPT.js} +1 -1
  11. package/dist/bundle/{chunk-JUS4Y4BW.js → chunk-2SCQ7Z4I.js} +4 -4
  12. package/dist/bundle/{chunk-LVJWN2PR.js → chunk-2VBEBPGX.js} +21 -11
  13. package/dist/bundle/{chunk-OUM4ZO53.js → chunk-4SKE5GYA.js} +1 -1
  14. package/dist/bundle/{chunk-WNGMI6AZ.js → chunk-4URI6EAV.js} +3 -3
  15. package/dist/bundle/chunk-4VHK5UBM.js +170 -0
  16. package/dist/bundle/{chunk-O7OP5NQO.js → chunk-4VM3UCSO.js} +2 -2
  17. package/dist/bundle/chunk-5GANGHQI.js +721 -0
  18. package/dist/bundle/{chunk-SWXKS7JK.js → chunk-6G4VQFVX.js} +19 -19
  19. package/dist/bundle/{chunk-TDTCCHAI.js → chunk-6GGMFL7J.js} +3 -3
  20. package/dist/bundle/{chunk-6XNTELM5.js → chunk-6LFRZDPV.js} +1 -1
  21. package/dist/bundle/{chunk-CD3TAITM.js → chunk-A2Y2RFNW.js} +75 -11
  22. package/dist/bundle/{chunk-M4OP5ASJ.js → chunk-AGZ7SNFF.js} +1 -1
  23. package/dist/bundle/chunk-CKVWAUBW.js +787 -0
  24. package/dist/bundle/{chunk-SZZJOSIS.js → chunk-DYQGEZA2.js} +3 -3
  25. package/dist/bundle/{chunk-JRGPPS6H.js → chunk-DZRP4UCK.js} +13 -13
  26. package/dist/bundle/{chunk-7GW4D3OW.js → chunk-EGQJDEFY.js} +85 -39
  27. package/dist/bundle/{chunk-7MEVD5PI.js → chunk-EZAX77SM.js} +20 -20
  28. package/dist/bundle/{chunk-2IYAZRTC.js → chunk-FNYWC6A3.js} +2 -2
  29. package/dist/bundle/chunk-FORAOCZ3.js +334 -0
  30. package/dist/bundle/{chunk-IX3GUNGV.js → chunk-H77ALM2Y.js} +4 -4
  31. package/dist/bundle/{chunk-MENP3FF5.js → chunk-HH647UBC.js} +23 -23
  32. package/dist/bundle/{chunk-HUWQ7LXZ.js → chunk-HRDCH2VB.js} +947 -953
  33. package/dist/bundle/{chunk-ZDP6A2VL.js → chunk-I3MS74OF.js} +4 -4
  34. package/dist/bundle/{chunk-TWHIZJAZ.js → chunk-IMQ4CVZJ.js} +2 -2
  35. package/dist/bundle/{chunk-NMN5JUYL.js → chunk-JVGVLRBA.js} +5 -5
  36. package/dist/bundle/{chunk-U57QRUP7.js → chunk-KF6O4RZO.js} +3 -3
  37. package/dist/bundle/{chunk-LVFI3TCG.js → chunk-KGYK3OI3.js} +6 -6
  38. package/dist/bundle/{chunk-PALY5PGE.js → chunk-KLI5FKZ2.js} +7 -7
  39. package/dist/bundle/chunk-KNVTBDTE.js +72 -0
  40. package/dist/bundle/{chunk-PCWAZVAD.js → chunk-LKTDW5LH.js} +7 -7
  41. package/dist/bundle/{chunk-ECZSYLSL.js → chunk-LOSYDRJU.js} +45 -8
  42. package/dist/bundle/{chunk-HFA6AZWA.js → chunk-MDISZMK4.js} +4 -4
  43. package/dist/bundle/{chunk-GPOTPA3S.js → chunk-MGXYIVVJ.js} +14 -13
  44. package/dist/bundle/{chunk-KLGZX6QT.js → chunk-NAENYLIO.js} +2 -2
  45. package/dist/bundle/{chunk-SDAYOJLL.js → chunk-NHD5BOJU.js} +6 -6
  46. package/dist/bundle/{chunk-FA3B2DHZ.js → chunk-NI4GCP2T.js} +2 -2
  47. package/dist/bundle/{chunk-ZAD7K4TI.js → chunk-NJVJH5MH.js} +8053 -8240
  48. package/dist/bundle/{chunk-IVD3JTN5.js → chunk-NWD7AFOR.js} +2 -2
  49. package/dist/bundle/{chunk-U346WBJ5.js → chunk-NXERDBEK.js} +4 -4
  50. package/dist/bundle/{chunk-AJY2IT25.js → chunk-OG5QO5RR.js} +8 -8
  51. package/dist/bundle/{chunk-RNBG75HW.js → chunk-OJ3BI2U4.js} +29 -30
  52. package/dist/bundle/chunk-OOYRMTX5.js +374 -0
  53. package/dist/bundle/{chunk-GSXCMQWV.js → chunk-OX5MCGXL.js} +40 -40
  54. package/dist/bundle/{chunk-T577U52I.js → chunk-PA4GEJXQ.js} +9 -9
  55. package/dist/bundle/{chunk-2UMEZY6D.js → chunk-PC3N3LH3.js} +3 -3
  56. package/dist/bundle/{chunk-WQOGHND4.js → chunk-PRDKEVUL.js} +1 -1
  57. package/dist/bundle/{chunk-Z6OKVD3R.js → chunk-PVZMN3UZ.js} +8 -8
  58. package/dist/bundle/{chunk-SEJBS7SI.js → chunk-QFJC6POK.js} +1 -1
  59. package/dist/bundle/{chunk-MVMNZ3Q3.js → chunk-QOQF2TX3.js} +893 -1491
  60. package/dist/bundle/{chunk-7KCBPAQS.js → chunk-QQGPV3QN.js} +2 -2
  61. package/dist/bundle/{chunk-6SJ7HHAE.js → chunk-QXLYLVEC.js} +1 -1
  62. package/dist/bundle/chunk-QXYNDMA6.js +259 -0
  63. package/dist/bundle/{chunk-QHXOXYAT.js → chunk-R2GS3GBJ.js} +61 -59
  64. package/dist/bundle/{chunk-6TRKNME5.js → chunk-RPNQXWRS.js} +4 -4
  65. package/dist/bundle/{chunk-7C6FGWDH.js → chunk-SK3N4CK5.js} +4 -4
  66. package/dist/bundle/{chunk-GDDCKTBR.js → chunk-T2EE5M7O.js} +5 -5
  67. package/dist/bundle/{chunk-U7RLFLTM.js → chunk-TZJC4AOK.js} +30 -29
  68. package/dist/bundle/{chunk-PCMQYGEM.js → chunk-V43KEZYA.js} +9 -9
  69. package/dist/bundle/{chunk-MSK7RNOM.js → chunk-VBVR6JRC.js} +283 -515
  70. package/dist/bundle/{chunk-KLFF54AF.js → chunk-VRGEDK4T.js} +8 -8
  71. package/dist/bundle/{chunk-ANYADN3S.js → chunk-WYGDALB3.js} +31 -85
  72. package/dist/bundle/{chunk-IBCGCYRU.js → chunk-X6IGETU6.js} +2 -2
  73. package/dist/bundle/{chunk-CAQ5GW3A.js → chunk-XIF75Z7D.js} +1 -1
  74. package/dist/bundle/chunk-XWU3A7H6.js +29 -0
  75. package/dist/bundle/{chunk-XXXVVNGI.js → chunk-YWX5X5RI.js} +19 -117
  76. package/dist/bundle/{chunk-FIVFP53N.js → chunk-Z6A6QPPW.js} +1 -1
  77. package/dist/bundle/{chunk-MHXZ62CU.js → chunk-ZGZADWD7.js} +1 -1
  78. package/dist/bundle/{chunk-MT2WDBG2.js → chunk-ZZEWQR43.js} +18 -14
  79. package/dist/bundle/command-contract-PZ7VOOXP.js +39 -0
  80. package/dist/bundle/{command-server-entry-BVXOPKXH.js → command-server-entry-NF45UPEV.js} +28 -25
  81. package/dist/bundle/decode-DUZA3EHC.js +296 -0
  82. package/dist/bundle/{dispatch-DSVN7MNG.js → dispatch-CDJZAMVP.js} +8 -8
  83. package/dist/bundle/{dist-B2JWWTNN.js → dist-RH7EMC4J.js} +29 -24
  84. package/dist/bundle/{echarts-QIXLXS3G.js → echarts-GZHZBNRA.js} +2 -2
  85. package/dist/bundle/{embed-4NC4ELYP.js → embed-VE3CSJN4.js} +6 -6
  86. package/dist/bundle/{embedder-HBRDIFQC.js → embedder-DSJ77DX5.js} +9 -9
  87. package/dist/bundle/{failure-COTPFUP4.js → failure-YH6HAGFT.js} +2 -2
  88. package/dist/bundle/{first-run-6QF67AAZ.js → first-run-3L7HLYTI.js} +12 -12
  89. package/dist/bundle/first-screen-MY5KID77.js +37 -0
  90. package/dist/bundle/{instructions-MD2RZT5Z.js → instructions-OZK3BLIO.js} +1 -1
  91. package/dist/bundle/mail.js +12 -12
  92. package/dist/bundle/{mcp-TDKGDB4V.js → mcp-YUG4YR4R.js} +2 -2
  93. package/dist/bundle/meeting-combined-RYMUPY54.js +24 -0
  94. package/dist/bundle/meeting-model-U7LW5WEN.js +24 -0
  95. package/dist/bundle/meeting-semantic-64IOIQRR.js +21 -0
  96. package/dist/bundle/{node-IEVT2FSJ.js → node-OS3VWBUZ.js} +2 -2
  97. package/dist/bundle/{node-sqlite-EOTTDMOG.js → node-sqlite-RQ623VFA.js} +7 -7
  98. package/dist/bundle/{oauth-A5BEFGCI.js → oauth-CBPAG734.js} +7 -7
  99. package/dist/bundle/{open-HWN2EZYG.js → open-H4DGOMBC.js} +5 -5
  100. package/dist/bundle/{openai-PJKJ4CIU.js → openai-EMWRGR54.js} +28 -26
  101. package/dist/bundle/{process-6Q23D3TO.js → process-3TOIYASI.js} +1 -1
  102. package/dist/bundle/{program-WR43NPAV.js → program-WA6RGAJL.js} +3151 -2105
  103. package/dist/bundle/{prompt-E7Q2662O.js → prompt-22KNCMBI.js} +5 -5
  104. package/dist/bundle/{recognize-4F4PIL4B.js → recognize-UWD4RSCZ.js} +4 -4
  105. package/dist/bundle/{remote-RGJXO7XK.js → remote-LJY7MF2E.js} +9 -9
  106. package/dist/bundle/{rerank-EDY7PHMG.js → rerank-JJ6KNJFB.js} +7 -7
  107. package/dist/bundle/{serve-Q4XF6ID2.js → serve-3EPLJYVZ.js} +9 -9
  108. package/dist/bundle/{server-5I72DSDF.js → server-5JOFO4V4.js} +52 -44
  109. package/dist/bundle/server-EOQNS7B7.js +75 -0
  110. package/dist/bundle/{sqlite-runtime-PU3Z2H7C.js → sqlite-runtime-MGJA5E27.js} +6 -6
  111. package/dist/bundle/{state-CWSXJBU2.js → state-UCRDOWOP.js} +6 -6
  112. package/dist/bundle/{store-KQPKS3PX.js → store-265VRRQV.js} +25 -20
  113. package/dist/bundle/{store-ZAMKKM2A.js → store-HS272YSA.js} +21 -17
  114. package/dist/bundle/store-maintenance-command-IKZM5NRP.js +66 -0
  115. package/dist/commands/messages.js +1 -1
  116. package/dist/commands/messages.js.map +1 -1
  117. package/dist/config.d.ts +1 -0
  118. package/dist/config.d.ts.map +1 -1
  119. package/dist/identity.d.ts.map +1 -1
  120. package/dist/identity.js +2 -2
  121. package/dist/identity.js.map +1 -1
  122. package/dist/mail/cleanup.d.ts.map +1 -1
  123. package/dist/mail/cleanup.js +4 -3
  124. package/dist/mail/cleanup.js.map +1 -1
  125. package/dist/mail/rules/apply.js +1 -1
  126. package/dist/mail/rules/apply.js.map +1 -1
  127. package/dist/version.d.ts +1 -1
  128. package/dist/version.js +1 -1
  129. package/package.json +3 -3
  130. package/dist/bundle/command-contract-DZ6XRIOI.js +0 -36
  131. package/dist/bundle/decode-STN3EHT7.js +0 -162
  132. package/dist/bundle/first-screen-LXSZMK2P.js +0 -34
  133. package/dist/bundle/server-2Y5NSP2U.js +0 -67
  134. package/dist/bundle/store-maintenance-command-PMTTDR6J.js +0 -58
  135. /package/dist/bundle/{chunk-XWBPP2HX.js → chunk-FEBUZHU3.js} +0 -0
@@ -2,15 +2,15 @@ import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  normalize
5
- } from "./chunk-4YNUQGDP.js";
5
+ } from "./chunk-26DYRMXE.js";
6
6
  import {
7
7
  CliError
8
- } from "./chunk-7KCBPAQS.js";
8
+ } from "./chunk-QQGPV3QN.js";
9
9
  import {
10
10
  __name
11
11
  } from "./chunk-ZVVMGPBJ.js";
12
12
 
13
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/languages.js
13
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/languages.js
14
14
  var LANGUAGES = [
15
15
  { name: "russian", code: "ru", label: "Russian", script: "cyrillic", dictionary: "dictionary-ru" },
16
16
  { name: "english", code: "en", label: "English", script: "latin", dictionary: "dictionary-en" },
@@ -18,7 +18,7 @@ var LANGUAGES = [
18
18
  ];
19
19
  var languagesOf = /* @__PURE__ */ __name((script) => LANGUAGES.filter((one) => one.script === script).map(({ name }) => name), "languagesOf");
20
20
 
21
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/snowball/base-stemmer.js
21
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/snowball/base-stemmer.js
22
22
  var BaseStemmer = class {
23
23
  static {
24
24
  __name(this, "BaseStemmer");
@@ -393,7 +393,7 @@ var BaseStemmer = class {
393
393
  }
394
394
  };
395
395
 
396
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/snowball/english-stemmer.js
396
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/snowball/english-stemmer.js
397
397
  var a_0 = [
398
398
  ["arsen", -1],
399
399
  ["commun", -1],
@@ -1094,7 +1094,7 @@ var english_stemmer_default = class extends BaseStemmer {
1094
1094
  stemWord = this.stem;
1095
1095
  };
1096
1096
 
1097
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/snowball/russian-stemmer.js
1097
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/snowball/russian-stemmer.js
1098
1098
  var a_02 = [
1099
1099
  ["\u0432", 1],
1100
1100
  ["\u0438\u0432", 2, 1],
@@ -1517,7 +1517,7 @@ var russian_stemmer_default = class extends BaseStemmer {
1517
1517
  stemWord = this.stem;
1518
1518
  };
1519
1519
 
1520
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/snowball/spanish-stemmer.js
1520
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/snowball/spanish-stemmer.js
1521
1521
  var a_03 = [
1522
1522
  ["", 6],
1523
1523
  ["\xE1", 1, 1],
@@ -2193,7 +2193,7 @@ var spanish_stemmer_default = class extends BaseStemmer {
2193
2193
  stemWord = this.stem;
2194
2194
  };
2195
2195
 
2196
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/stem.js
2196
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/stem.js
2197
2197
  var SNOWBALL_VERSION = "3.1.1";
2198
2198
  var CYRILLIC_STEMMERS = [...languagesOf("cyrillic"), "none"];
2199
2199
  var LATIN_STEMMERS = [...languagesOf("latin"), "none"];
@@ -1,5 +1,13 @@
1
1
  import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ QUERY_LIMITS,
5
+ exhausted,
6
+ searchError
7
+ } from "./chunk-KNVTBDTE.js";
8
+ import {
9
+ fold
10
+ } from "./chunk-26DYRMXE.js";
3
11
  import {
4
12
  CATALOG_KINDS,
5
13
  CONTRACT_KINDS,
@@ -11,29 +19,23 @@ import {
11
19
  ORDER_DIRECTIONS,
12
20
  ORDER_PURPOSES,
13
21
  ORDER_STATUSES,
14
- QUERY_LIMITS,
15
22
  SUBSCRIPTION_STATUSES,
16
23
  TRANSACTION_STATUSES,
17
24
  WALLET_KINDS,
18
25
  looksLikeReference,
19
26
  parseReference,
20
27
  providerLabel,
21
- providerNamed,
22
- queryError
23
- } from "./chunk-MVMNZ3Q3.js";
24
- import {
25
- fold
26
- } from "./chunk-4YNUQGDP.js";
28
+ providerNamed
29
+ } from "./chunk-CKVWAUBW.js";
27
30
  import {
28
31
  CliError,
29
- isCliError,
30
32
  singleLine
31
- } from "./chunk-7KCBPAQS.js";
33
+ } from "./chunk-QQGPV3QN.js";
32
34
  import {
33
35
  __name
34
36
  } from "./chunk-ZVVMGPBJ.js";
35
37
 
36
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/phone-plans.generated.js
38
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/phone-plans.generated.js
37
39
  var PHONE_PLANS = [
38
40
  {
39
41
  country: "us",
@@ -413,7 +415,7 @@ var PHONE_PLANS = [
413
415
  }
414
416
  ];
415
417
 
416
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/phones.js
418
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/phones.js
417
419
  var PHONE_COUNTRIES = PHONE_PLANS.map((plan) => plan.country);
418
420
  var DEFAULT_PHONE_COUNTRIES = ["ru"];
419
421
  var parsePhoneCountries = /* @__PURE__ */ __name((value) => {
@@ -488,7 +490,7 @@ var storedPhone = /* @__PURE__ */ __name((raw, provider) => {
488
490
  return found ? `+${found[1]}` : void 0;
489
491
  }, "storedPhone");
490
492
 
491
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/record-fields.js
493
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/record-fields.js
492
494
  var DECIMAL_PATTERN = "^[0-9]{1,16}(\\.[0-9]{1,6})?$";
493
495
  var SIGNED_DECIMAL = "^-?[0-9]{1,16}(\\.[0-9]{1,6})?$";
494
496
  var DAY = "^[0-9]{4}-[0-9]{2}-[0-9]{2}$";
@@ -538,7 +540,7 @@ var arrayOf = /* @__PURE__ */ __name((item, maxItems, description) => ({
538
540
  }), "arrayOf");
539
541
  var isObject = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isObject");
540
542
 
541
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/record-types.js
543
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/record-types.js
542
544
  var kept = /* @__PURE__ */ __name((description) => ({ description }), "kept");
543
545
  var PARTY = ["person", "organization"];
544
546
  var ORGANIZATION = ["organization"];
@@ -933,7 +935,7 @@ var hasV1Roles = /* @__PURE__ */ __name((type) => rolesOf(type).some(([, role])
933
935
  var IDENTITY_TYPES = RECORD_ENTITY_TYPES.filter((type) => RECORD_TYPES[type].review === "identity");
934
936
  var article = /* @__PURE__ */ __name((word) => /^[aeiou]/.test(word) ? "an" : "a", "article");
935
937
 
936
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/ref-arguments.js
938
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/ref-arguments.js
937
939
  var TAKES = {
938
940
  chat: "a chat: chat:<provider>/<account>/<chat>, its id or its title",
939
941
  message: "a message: msg:<provider>/<account>/<chat>/<message>, or a chat and the message's id"
@@ -993,52 +995,7 @@ var ensureAccount = /* @__PURE__ */ __name(async (reference, scope, profilesOn)
993
995
  throw wrongAccount(reference, scope, profiles);
994
996
  }, "ensureAccount");
995
997
 
996
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/lucene/types.js
997
- var QUERY_VERSION = 1;
998
- var QUERY_LIMITS2 = {
999
- ...QUERY_LIMITS,
1000
- pattern: 1024,
1001
- states: 1e4,
1002
- expansions: 1e4,
1003
- candidates: 5e4,
1004
- bodyBytes: 8388608,
1005
- milliseconds: 2e3,
1006
- work: 1e7
1007
- };
1008
- var SEARCH_QUERY = {
1009
- command: "search",
1010
- guide: "https://github.com/WireCatLabs/cli-core/blob/main/docs/search/query-language.md"
1011
- };
1012
- var MESSAGE_PARSING = { ...SEARCH_QUERY, proximity: true };
1013
- var MOST_WORDS_APART = 50;
1014
- function searchError(reason, span, alternative) {
1015
- queryError(reason, span, alternative, SEARCH_QUERY);
1016
- }
1017
- __name(searchError, "searchError");
1018
- var ANSWER_MS = 1e3;
1019
- var searchTimeLimit = /* @__PURE__ */ __name((deadline, now = Date.now()) => deadline?.explicit ? Math.max(QUERY_LIMITS2.milliseconds, deadline.endsAt - now - ANSWER_MS) : void 0, "searchTimeLimit");
1020
- function outOfTime(limitMs = QUERY_LIMITS2.milliseconds) {
1021
- throw new CliError("timeout", `search stopped at its time limit of ${limitMs / 1e3}s \u2014 the query is valid; add chat: or date: to search less of the store`, { reason: "query.time-limit", budget: "time", limit_ms: limitMs, complete: false });
1022
- }
1023
- __name(outOfTime, "outOfTime");
1024
- var isQueryLimit = /* @__PURE__ */ __name((error) => isCliError(error) && (error.details.reason === "query.too-large" || error.details.reason === "query.time-limit"), "isQueryLimit");
1025
- function exhausted(budget) {
1026
- throw new CliError("validation_error", `search exceeded its ${budget} budget \u2014 narrow the chat or date range`, {
1027
- reason: "query.too-large",
1028
- budget,
1029
- complete: false
1030
- });
1031
- }
1032
- __name(exhausted, "exhausted");
1033
- function tooWideTerm([term], budget) {
1034
- if (term === void 0)
1035
- exhausted(budget);
1036
- const part = term.replace(/[*?]+/gu, " ").trim().split(/\s+/u).sort((a, b) => b.length - a.length)[0] ?? term;
1037
- throw new CliError("validation_error", `search exceeded its ${budget} budget: ${term} is checked word by word, and too many messages hold it \u2014 write *${part}* (any word holding it, read from the index), more of the word, or add chat: or date:`, { reason: "query.too-large", budget, term, complete: false });
1038
- }
1039
- __name(tooWideTerm, "tooWideTerm");
1040
-
1041
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/lucene/automaton.js
998
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/lucene/automaton.js
1042
999
  var any = { kind: "char", ranges: [[0, 1114111]], negate: false };
1043
1000
  var literal = /* @__PURE__ */ __name((c) => ({
1044
1001
  kind: "char",
@@ -1046,10 +1003,10 @@ var literal = /* @__PURE__ */ __name((c) => ({
1046
1003
  negate: false
1047
1004
  }), "literal");
1048
1005
  var compileAutomaton = /* @__PURE__ */ __name((pattern, span = { start: 0, end: pattern.length }) => {
1049
- if (pattern.length > QUERY_LIMITS2.pattern * 2)
1006
+ if (pattern.length > QUERY_LIMITS.pattern * 2)
1050
1007
  exhausted("pattern");
1051
1008
  const chars = [...pattern];
1052
- if (chars.length > QUERY_LIMITS2.pattern)
1009
+ if (chars.length > QUERY_LIMITS.pattern)
1053
1010
  exhausted("pattern");
1054
1011
  let at = 0, depth = 0;
1055
1012
  const failure = /* @__PURE__ */ __name(() => searchError("query.invalid-regex", span, "use the supported Lucene regex subset"), "failure");
@@ -1092,7 +1049,7 @@ var compileAutomaton = /* @__PURE__ */ __name((pattern, span = { start: 0, end:
1092
1049
  return character();
1093
1050
  }, "escaped");
1094
1051
  const union = /* @__PURE__ */ __name(() => {
1095
- if (++depth > QUERY_LIMITS2.depth)
1052
+ if (++depth > QUERY_LIMITS.depth)
1096
1053
  exhausted("pattern depth");
1097
1054
  const children = [concat()];
1098
1055
  while (chars[at] === "|") {
@@ -1134,7 +1091,7 @@ var compileAutomaton = /* @__PURE__ */ __name((pattern, span = { start: 0, end:
1134
1091
  if (character() !== "}" || max !== null && max < min)
1135
1092
  return failure();
1136
1093
  }
1137
- if (min > QUERY_LIMITS2.states || max !== null && max > QUERY_LIMITS2.states)
1094
+ if (min > QUERY_LIMITS.states || max !== null && max > QUERY_LIMITS.states)
1138
1095
  exhausted("automaton states");
1139
1096
  child = { kind: "repeat", child, min, max };
1140
1097
  }
@@ -1214,7 +1171,7 @@ var compileAutomaton = /* @__PURE__ */ __name((pattern, span = { start: 0, end:
1214
1171
  return failure();
1215
1172
  const states = [];
1216
1173
  const state = /* @__PURE__ */ __name(() => {
1217
- if (states.length >= QUERY_LIMITS2.states)
1174
+ if (states.length >= QUERY_LIMITS.states)
1218
1175
  exhausted("automaton states");
1219
1176
  states.push({ epsilon: [], edges: [] });
1220
1177
  return states.length - 1;
@@ -1278,7 +1235,7 @@ var compileAutomaton = /* @__PURE__ */ __name((pattern, span = { start: 0, end:
1278
1235
  states: states.length,
1279
1236
  test: /* @__PURE__ */ __name((text2, budget = { work: 0 }) => {
1280
1237
  const spend = /* @__PURE__ */ __name(() => {
1281
- if (++budget.work > (budget.maxWork ?? QUERY_LIMITS2.work))
1238
+ if (++budget.work > (budget.maxWork ?? QUERY_LIMITS.work))
1282
1239
  exhausted("automaton work");
1283
1240
  }, "spend");
1284
1241
  const closure = /* @__PURE__ */ __name((initial) => {
@@ -1438,7 +1395,7 @@ var foldRegex = /* @__PURE__ */ __name((pattern, span) => {
1438
1395
  return out;
1439
1396
  }, "foldRegex");
1440
1397
 
1441
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/search/trigrams.js
1398
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/search/trigrams.js
1442
1399
  var trigrams = /* @__PURE__ */ __name((term) => {
1443
1400
  const padded = ` ${term} `;
1444
1401
  const pieces = /* @__PURE__ */ new Set();
@@ -1447,7 +1404,7 @@ var trigrams = /* @__PURE__ */ __name((term) => {
1447
1404
  return [...pieces];
1448
1405
  }, "trigrams");
1449
1406
 
1450
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/resolve.js
1407
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/resolve.js
1451
1408
  var isId = /* @__PURE__ */ __name((reference) => /^-?\d+$/.test(reference.trim()), "isId");
1452
1409
  var foldName = /* @__PURE__ */ __name((name) => name.normalize("NFC").replace(/[\uFE0E\uFE0F\u200D]/g, "").toLowerCase().replaceAll("\u0451", "\u0435"), "foldName");
1453
1410
  var pickChat = /* @__PURE__ */ __name((reference, chats) => {
@@ -1518,7 +1475,7 @@ ${lines}`, { candidates });
1518
1475
  }, "ambiguous");
1519
1476
  var isPresent = /* @__PURE__ */ __name((value) => value !== null && value !== void 0, "isPresent");
1520
1477
 
1521
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/addresses.js
1478
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/addresses.js
1522
1479
  var EMAIL_ADDRESS = /^[^\s@]+@[^\s@]+\.[^\s@]+$/u;
1523
1480
  var isEmailAddress = /* @__PURE__ */ __name((value) => EMAIL_ADDRESS.test(value), "isEmailAddress");
1524
1481
  var ROLE_ADDRESS_WORDS = {
@@ -1580,7 +1537,7 @@ var PERSON_LIKE = /* @__PURE__ */ new Set(["hr"]);
1580
1537
  var isPersonLikeRoleAddress = /* @__PURE__ */ __name((address) => PERSON_LIKE.has(localWord(address)), "isPersonLikeRoleAddress");
1581
1538
  var isNoReplyAddress = /* @__PURE__ */ __name((address) => NO_REPLY.has(localWord(address)), "isNoReplyAddress");
1582
1539
 
1583
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/display-names.js
1540
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/display-names.js
1584
1541
  var QUOTES = [
1585
1542
  ['"', '"'],
1586
1543
  ["'", "'"],
@@ -1638,7 +1595,7 @@ var nameKey = /* @__PURE__ */ __name((name) => {
1638
1595
  }, "nameKey");
1639
1596
  var isReadable = /* @__PURE__ */ __name((shown) => shown !== null && READABLE.test(shown), "isReadable");
1640
1597
 
1641
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/counters.js
1598
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/counters.js
1642
1599
  var COUNTER_FIELDS = ["views", "reactions", "comments"];
1643
1600
  var validCounter = /* @__PURE__ */ __name((value) => typeof value === "number" && Number.isFinite(value) && value >= 0, "validCounter");
1644
1601
  var counterValue = /* @__PURE__ */ __name((message, field) => {
@@ -1675,7 +1632,7 @@ var counterFreshness = /* @__PURE__ */ __name((states) => {
1675
1632
  return states.some((one) => one.freshness === "stale") ? "stale" : "fresh";
1676
1633
  }, "counterFreshness");
1677
1634
 
1678
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/rankings-options.js
1635
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/rankings-options.js
1679
1636
  var MESSAGE_MEASURES = ["views", "reactions", "forwards", "comments", "replies", "thread-size"];
1680
1637
  var AUTHOR_MEASURES = [
1681
1638
  "messages",
@@ -1815,7 +1772,7 @@ var withoutUrls = /* @__PURE__ */ __name((text2) => text2.replace(/\S+/gu, (toke
1815
1772
  var rankingWords = /* @__PURE__ */ __name((text2) => withoutUrls(text2).match(/[\p{L}\p{N}]+/gu)?.length ?? 0, "rankingWords");
1816
1773
  var rankingQuestion = /* @__PURE__ */ __name((text2) => withoutUrls(text2).includes("?"), "rankingQuestion");
1817
1774
 
1818
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/records.js
1775
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/records.js
1819
1776
  import { createHash } from "node:crypto";
1820
1777
  var RECORDS_SCHEMA_VERSION = 1;
1821
1778
  var RECORD_OPERATIONS = ["upsert", "delete"];
@@ -1987,7 +1944,7 @@ var fieldReferences = /* @__PURE__ */ __name((record, options = {}) => {
1987
1944
  return found;
1988
1945
  }, "fieldReferences");
1989
1946
 
1990
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/domain/relation-role-labels.js
1947
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/relation-role-labels.js
1991
1948
  var label = /* @__PURE__ */ __name((en, ru, es) => ({ en, ru, es }), "label");
1992
1949
  var ROLE_LABELS = {
1993
1950
  organization: {
@@ -2038,17 +1995,6 @@ export {
2038
1995
  isMobilePhone,
2039
1996
  BARE_INTERNATIONAL_PROVIDERS,
2040
1997
  storedPhone,
2041
- QUERY_VERSION,
2042
- QUERY_LIMITS2 as QUERY_LIMITS,
2043
- SEARCH_QUERY,
2044
- MESSAGE_PARSING,
2045
- MOST_WORDS_APART,
2046
- searchError,
2047
- searchTimeLimit,
2048
- outOfTime,
2049
- isQueryLimit,
2050
- exhausted,
2051
- tooWideTerm,
2052
1998
  compileAutomaton,
2053
1999
  wildcardPattern,
2054
2000
  foldRegex,
@@ -5,12 +5,12 @@ import {
5
5
  } from "./chunk-Y5E2WNWB.js";
6
6
  import {
7
7
  CliError
8
- } from "./chunk-7KCBPAQS.js";
8
+ } from "./chunk-QQGPV3QN.js";
9
9
  import {
10
10
  __name
11
11
  } from "./chunk-ZVVMGPBJ.js";
12
12
 
13
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/store/vector-extension.js
13
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/store/vector-extension.js
14
14
  import { readFileSync } from "node:fs";
15
15
  var musl = /* @__PURE__ */ __name(() => {
16
16
  if (process.platform !== "linux")
@@ -4,7 +4,7 @@ import {
4
4
  __name
5
5
  } from "./chunk-ZVVMGPBJ.js";
6
6
 
7
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/mcp/instructions.js
7
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/mcp/instructions.js
8
8
  var instructions = /* @__PURE__ */ __name(({ command, name, profile, writes, skill }) => {
9
9
  const all = typeof profile !== "string";
10
10
  const offers = /* @__PURE__ */ __name((key) => all || writes.includes(key), "offers");
@@ -0,0 +1,29 @@
1
+ import { createRequire as __bundleRequire } from "node:module";
2
+ const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ CliError,
5
+ singleLine
6
+ } from "./chunk-QQGPV3QN.js";
7
+ import {
8
+ __name
9
+ } from "./chunk-ZVVMGPBJ.js";
10
+
11
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/domain/tags.js
12
+ var TAG_TYPES = ["chat", "contact", "message", "task"];
13
+ var TAG = /^[a-z0-9-]{1,32}$/;
14
+ var tagOf = /* @__PURE__ */ __name((value) => {
15
+ const tag = value.trim().toLowerCase();
16
+ return TAG.test(tag) ? tag : void 0;
17
+ }, "tagOf");
18
+ var normalizeTag = /* @__PURE__ */ __name((value) => {
19
+ const tag = tagOf(value);
20
+ if (tag === void 0)
21
+ throw new CliError("validation_error", `"${singleLine(value)}" is not a tag \u2014 use 1\u201332 letters a\u2013z, digits and hyphens`, { reason: "tag.invalid" });
22
+ return tag;
23
+ }, "normalizeTag");
24
+
25
+ export {
26
+ TAG_TYPES,
27
+ tagOf,
28
+ normalizeTag
29
+ };
@@ -1,8 +1,10 @@
1
1
  import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
+ DEFAULT_PACE,
4
5
  FloodMemory,
5
6
  OFFLINE,
7
+ Pacer,
6
8
  RecipientList,
7
9
  capability,
8
10
  ceilingRefusal,
@@ -10,16 +12,17 @@ import {
10
12
  floodPathFor,
11
13
  guardFor,
12
14
  holdEnd,
15
+ pacePathFor,
13
16
  profilesOnAccount,
14
17
  recipientsPathFor,
15
18
  refuseLacking,
16
19
  servicesFor,
17
20
  throughWrapper,
18
- withFileLockAsync
19
- } from "./chunk-HUWQ7LXZ.js";
21
+ waitForTurn
22
+ } from "./chunk-HRDCH2VB.js";
20
23
  import {
21
24
  servingProfiles
22
- } from "./chunk-2UMEZY6D.js";
25
+ } from "./chunk-PC3N3LH3.js";
23
26
  import {
24
27
  asFirstWord,
25
28
  baseContext,
@@ -33,7 +36,7 @@ import {
33
36
  recalledAccount,
34
37
  rememberAccount,
35
38
  rootOf2 as rootOf
36
- } from "./chunk-MSK7RNOM.js";
39
+ } from "./chunk-VBVR6JRC.js";
37
40
  import {
38
41
  AUTHORITY_KEY,
39
42
  CEILING_KEY,
@@ -45,34 +48,31 @@ import {
45
48
  levelFor,
46
49
  readKeysForCommand,
47
50
  skipFlagFor
48
- } from "./chunk-PCWAZVAD.js";
51
+ } from "./chunk-LKTDW5LH.js";
49
52
  import {
50
53
  providerErrorKey
51
- } from "./chunk-Z6OKVD3R.js";
54
+ } from "./chunk-PVZMN3UZ.js";
52
55
  import {
53
56
  openStore
54
- } from "./chunk-ZAD7K4TI.js";
57
+ } from "./chunk-NJVJH5MH.js";
55
58
  import {
56
59
  chatReferenceOf,
57
60
  ensureAccount,
58
61
  foldName,
59
62
  isId,
60
63
  pickPerson
61
- } from "./chunk-ANYADN3S.js";
64
+ } from "./chunk-WYGDALB3.js";
62
65
  import {
63
66
  isCliFailure
64
- } from "./chunk-O7OP5NQO.js";
65
- import {
66
- resolvePaths
67
- } from "./chunk-7MEVD5PI.js";
67
+ } from "./chunk-4VM3UCSO.js";
68
68
  import {
69
69
  CliError
70
- } from "./chunk-7KCBPAQS.js";
70
+ } from "./chunk-QQGPV3QN.js";
71
71
  import {
72
72
  __name
73
73
  } from "./chunk-ZVVMGPBJ.js";
74
74
 
75
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/messenger/ask.js
75
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/messenger/ask.js
76
76
  import { openSync } from "node:fs";
77
77
  import { createInterface } from "node:readline";
78
78
  import { ReadStream } from "node:tty";
@@ -127,102 +127,7 @@ var terminalAsker = /* @__PURE__ */ __name((command) => async (key, request) =>
127
127
  throw new CliError("cancelled", `${key}: not done \u2014 the answer was no`);
128
128
  }, "terminalAsker");
129
129
 
130
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/sends/pace.js
131
- import { readFileSync, renameSync, writeFileSync } from "node:fs";
132
- import { join } from "node:path";
133
- var DEFAULT_PACE = { perMinute: 60, burst: 20 };
134
- var pacePathFor = /* @__PURE__ */ __name((app, profile, env = process.env) => join(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "pace", `${profile}.json`), "pacePathFor");
135
- var Pacer = class {
136
- static {
137
- __name(this, "Pacer");
138
- }
139
- path;
140
- rate;
141
- now;
142
- constructor(path, rate, now = Date.now) {
143
- this.path = path;
144
- this.rate = rate;
145
- this.now = now;
146
- }
147
- get interval() {
148
- return this.rate.perMinute > 0 ? 6e4 / this.rate.perMinute : 0;
149
- }
150
- /** When this call may go; reserved at once, so the next caller in any process lines up behind it. */
151
- async reserve() {
152
- if (this.interval === 0)
153
- return this.now();
154
- return withFileLockAsync(this.path, "the request pace", () => {
155
- const now = this.now();
156
- const tat = Math.max(this.read(now), now);
157
- this.write(tat + this.interval, now);
158
- return Math.max(now, tat - this.rate.burst * this.interval);
159
- });
160
- }
161
- /** The messenger asked every caller to wait: nothing goes before `now + waitMs`, in any process. */
162
- async holdFor(waitMs) {
163
- if (this.interval === 0)
164
- return;
165
- await withFileLockAsync(this.path, "the request pace", () => {
166
- const now = this.now();
167
- const hold = now + waitMs + this.rate.burst * this.interval;
168
- this.write(Math.max(this.read(now), hold), now);
169
- });
170
- }
171
- /** The owner's `flood clear`: every process may go again at once. */
172
- async reset() {
173
- await withFileLockAsync(this.path, "the request pace", () => this.write(0, this.now()));
174
- }
175
- read(now) {
176
- try {
177
- const file = JSON.parse(readFileSync(this.path, "utf8"));
178
- const tat = Number(file.tat);
179
- if (!Number.isFinite(tat))
180
- return 0;
181
- const at = Number(file.at);
182
- return Number.isFinite(at) && at > now ? now + Math.max(0, tat - at) : tat;
183
- } catch {
184
- return 0;
185
- }
186
- }
187
- write(tat, at) {
188
- const temporary = `${this.path}.${process.pid}.tmp`;
189
- writeFileSync(temporary, JSON.stringify({ tat, at }), { mode: 384 });
190
- renameSync(temporary, this.path);
191
- }
192
- };
193
- var ANNOUNCE_WAIT_MS = 5e3;
194
- var LONGEST_PACE_WAIT_MS = 5 * 6e4;
195
- var waitForTurn = /* @__PURE__ */ __name(async (pacer, options) => {
196
- const { name, operation, warn } = options;
197
- const now = options.now ?? Date.now;
198
- let at = now();
199
- try {
200
- at = await pacer.reserve();
201
- } catch (error) {
202
- warn?.(`could not remember ${name}'s wait (${error instanceof Error ? error.message : String(error)})`, {
203
- event: "warning",
204
- code: "wait_not_remembered",
205
- operation
206
- });
207
- }
208
- const waitMs = at - now();
209
- if (waitMs <= 0)
210
- return;
211
- if (waitMs > (options.longestWaitMs ?? LONGEST_PACE_WAIT_MS))
212
- throw new CliError("rate_limited", `this profile's next request to ${name} has to wait ${Math.ceil(waitMs / 1e3)} s more \u2014 nothing was sent to ${name}`, { retry_after_ms: waitMs, retry_at: new Date(at).toISOString(), remembered: true });
213
- if (waitMs >= ANNOUNCE_WAIT_MS) {
214
- const seconds = Math.ceil(waitMs / 1e3);
215
- warn?.(`waiting ${seconds} s to keep this profile's pace with ${name}`, {
216
- event: "warning",
217
- code: "pace_wait",
218
- operation,
219
- counts: { seconds }
220
- });
221
- }
222
- await (options.sleep ?? ((ms) => new Promise((resolve) => setTimeout(resolve, ms))))(waitMs);
223
- }, "waitForTurn");
224
-
225
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/permission-keys.js
130
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/permission-keys.js
226
131
  var HOUSEKEEPING = /* @__PURE__ */ new Set([
227
132
  "help",
228
133
  "guide",
@@ -302,7 +207,7 @@ var refuseUnknownPermissionKeys = /* @__PURE__ */ __name((command, settings, too
302
207
  throw new CliError("validation_error", `--permission ${key} names no command`, { permission: key });
303
208
  }, "refuseUnknownPermissionKeys");
304
209
 
305
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
210
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
306
211
  var LONG_LIVED = /* @__PURE__ */ new Set(["self", "newSendId", "close", "formatMarkdown", "formatHtml", "storedChats"]);
307
212
  var LISTENING = /* @__PURE__ */ new Set(["watch", "feed", "listen", "listenHistory"]);
308
213
  var BLOCKING = /* @__PURE__ */ new Set(["frozen", "limited", "banned"]);
@@ -399,7 +304,7 @@ var flooded = /* @__PURE__ */ __name((messenger, memory, { name, warn, pacer })
399
304
  });
400
305
  }, "flooded");
401
306
 
402
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/messenger/observed.js
307
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/messenger/observed.js
403
308
  var observed = /* @__PURE__ */ __name((messenger, events) => {
404
309
  const timed = /* @__PURE__ */ __name(async (operation, named, work, after) => {
405
310
  const write = currentOperation();
@@ -498,7 +403,7 @@ var byPart = /* @__PURE__ */ __name((batch, counts) => {
498
403
  counts[part] = (counts[part] ?? 0) + items.length;
499
404
  }, "byPart");
500
405
 
501
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/messenger/stored.js
406
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/messenger/stored.js
502
407
  var REKEY_PACING = { lockMs: 50, pauseMs: 25 };
503
408
  var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events, pending, announcing, deletedWithoutChat, profile, rekeyed, rekeyPacing = REKEY_PACING, closing, namesFromStore, recipientIds, countsUnread = false, historyLimits, command = "cli" }) => {
504
409
  let warned = false;
@@ -1074,7 +979,7 @@ var keep = /* @__PURE__ */ __name(async (store, account, event, seenAt, among, c
1074
979
  }
1075
980
  }, "keep");
1076
981
 
1077
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/messenger/context.js
982
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/messenger/context.js
1078
983
  var lazyStore = /* @__PURE__ */ __name((env, command, version) => {
1079
984
  let opened;
1080
985
  return {
@@ -1477,9 +1382,6 @@ var messengerContext = /* @__PURE__ */ __name((command, messenger, resolving = {
1477
1382
  export {
1478
1383
  answerOf,
1479
1384
  terminalAsker,
1480
- DEFAULT_PACE,
1481
- pacePathFor,
1482
- Pacer,
1483
1385
  commandPermissions,
1484
1386
  knownPermissionKeys,
1485
1387
  knownBeside,
@@ -4,7 +4,7 @@ import {
4
4
  __name
5
5
  } from "./chunk-ZVVMGPBJ.js";
6
6
 
7
- // node_modules/.pnpm/@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/executable.js
7
+ // node_modules/.pnpm/@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/executable.js
8
8
  import { existsSync } from "node:fs";
9
9
  import { win32 } from "node:path";
10
10
  var variable = /* @__PURE__ */ __name((env, name) => Object.entries(env).find(([key]) => key.toUpperCase() === name)?.[1], "variable");
@@ -4,7 +4,7 @@ import {
4
4
  __name
5
5
  } from "./chunk-ZVVMGPBJ.js";
6
6
 
7
- // node_modules/.pnpm/@wirecat+cli-core@0.662.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_b96f03b0a44798bffec19d0b8a7273db/node_modules/@wirecat/cli-core/dist/cli/stdin-field.js
7
+ // node_modules/.pnpm/@wirecat+cli-core@0.674.0_@wirecat+cli-base@0.103.0_commander@15.0.0_esbuild@0.28.2_typ_fc1e3fbb1256d0776f2342adda6f86ff/node_modules/@wirecat/cli-core/dist/cli/stdin-field.js
8
8
  var fields = /* @__PURE__ */ new WeakMap();
9
9
  var readsStdin = /* @__PURE__ */ __name((command, field) => {
10
10
  fields.set(command, field);