@wirecat/zoom-cli 0.63.0 → 0.65.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 (147) hide show
  1. package/README.md +3 -0
  2. package/dist/answer-entities.d.ts +13 -0
  3. package/dist/answer-entities.d.ts.map +1 -1
  4. package/dist/answer-entities.js +5 -0
  5. package/dist/answer-entities.js.map +1 -1
  6. package/dist/answers.d.ts +8 -0
  7. package/dist/answers.d.ts.map +1 -1
  8. package/dist/archive-import.d.ts +1 -1
  9. package/dist/archive-import.d.ts.map +1 -1
  10. package/dist/archive-import.js +2 -1
  11. package/dist/archive-import.js.map +1 -1
  12. package/dist/bin/zm.js +6 -2
  13. package/dist/bundle/{all-profiles-CGGNBINU.js → all-profiles-SKMLZJSY.js} +8 -8
  14. package/dist/bundle/answer-policy-BHDNSJWX.js +96 -0
  15. package/dist/bundle/{anthropic-KVWPIHFG.js → anthropic-TVHK7CY2.js} +4 -4
  16. package/dist/bundle/{app-server-NKKFBTQN.js → app-server-44ASFH47.js} +53 -52
  17. package/dist/bundle/{bun-XRO6XJHQ.js → bun-O4WHGL2F.js} +2 -2
  18. package/dist/bundle/{bun-sqlite-FWNCLOAR.js → bun-sqlite-NS32GMM4.js} +3 -3
  19. package/dist/bundle/{chunk-M6FCCVYZ.js → chunk-24F7JBLY.js} +72 -4
  20. package/dist/bundle/{chunk-4OQVRDTG.js → chunk-25IDWPEN.js} +166 -96
  21. package/dist/bundle/{chunk-QLQ7VVLK.js → chunk-266WOOB3.js} +4 -4
  22. package/dist/bundle/{chunk-ECXRRW7J.js → chunk-2H5SXK7K.js} +57 -27
  23. package/dist/bundle/{chunk-YI6ZNDPC.js → chunk-37PHGASE.js} +2 -2
  24. package/dist/bundle/{chunk-URJZK4GX.js → chunk-3CZIWGZ6.js} +1 -1
  25. package/dist/bundle/{chunk-6URISMGR.js → chunk-5NGOP4EZ.js} +125 -35
  26. package/dist/bundle/{chunk-IOUPXUFH.js → chunk-6CS7ETBK.js} +4496 -386
  27. package/dist/bundle/{chunk-FDCGTODC.js → chunk-7SQJCKR6.js} +1 -1
  28. package/dist/bundle/{chunk-EG7HC4EC.js → chunk-A6OA2EH2.js} +2 -2
  29. package/dist/bundle/{chunk-QUWMFBMS.js → chunk-AMMD6YCJ.js} +49 -11
  30. package/dist/bundle/chunk-BLT3LR3U.js +34 -0
  31. package/dist/bundle/{chunk-MI3JK6MW.js → chunk-BNXH73OU.js} +10 -10
  32. package/dist/bundle/{chunk-GOESXUJQ.js → chunk-BWRBALXG.js} +3 -3
  33. package/dist/bundle/{chunk-6SPWQCJF.js → chunk-C6BG57FA.js} +11 -11
  34. package/dist/bundle/{chunk-CXPHUOJR.js → chunk-CNEE6TPE.js} +26 -13
  35. package/dist/bundle/{chunk-RWG44LQD.js → chunk-CVCRQW3A.js} +35 -35
  36. package/dist/bundle/{chunk-FAOLCUKV.js → chunk-DNCKH7CO.js} +17 -17
  37. package/dist/bundle/{chunk-LTE6WH22.js → chunk-DYJXAY7Q.js} +26 -25
  38. package/dist/bundle/{chunk-IOCS5FXW.js → chunk-EA63UGWE.js} +2 -2
  39. package/dist/bundle/{chunk-5LMQTEU5.js → chunk-ERPRAYA7.js} +5 -5
  40. package/dist/bundle/{chunk-KMQUZ4YM.js → chunk-FYJL276J.js} +3 -3
  41. package/dist/bundle/{chunk-AMIIU3UZ.js → chunk-FYM27FCG.js} +32 -9
  42. package/dist/bundle/{chunk-NQCFUYC2.js → chunk-GBZF4IIP.js} +10 -9
  43. package/dist/bundle/{chunk-DIXC56OU.js → chunk-GEX4V5TM.js} +4 -4
  44. package/dist/bundle/{chunk-4OTXE6CF.js → chunk-GMTXCFI7.js} +683 -504
  45. package/dist/bundle/{chunk-TILW3EJY.js → chunk-GXCNCMUY.js} +2865 -924
  46. package/dist/bundle/{chunk-YJN4XYNA.js → chunk-H7762LDA.js} +2 -2
  47. package/dist/bundle/{chunk-JDJDVYGS.js → chunk-IPTI3Y2E.js} +6 -41
  48. package/dist/bundle/{chunk-SB47UAW2.js → chunk-JF7ZEUXU.js} +34 -26
  49. package/dist/bundle/{chunk-7AY3ADNV.js → chunk-K6ATTKQR.js} +13 -6
  50. package/dist/bundle/{chunk-6SK5SHCR.js → chunk-KYLS5QGC.js} +2 -2
  51. package/dist/bundle/{chunk-YF2PT5KA.js → chunk-KZE3G4ZT.js} +38 -36
  52. package/dist/bundle/{chunk-MIUPH3WA.js → chunk-LOL6JYYN.js} +211 -106
  53. package/dist/bundle/{chunk-UIPT6IAU.js → chunk-LPUFOWL3.js} +1 -1
  54. package/dist/bundle/{chunk-5NLFQ644.js → chunk-M6IDHQ7N.js} +6739 -4659
  55. package/dist/bundle/{chunk-M2WQWF3I.js → chunk-MH7AWCB4.js} +179 -50
  56. package/dist/bundle/{chunk-VFJ3MOIR.js → chunk-MIB5X2XW.js} +3 -3
  57. package/dist/bundle/{chunk-SLBMXXOW.js → chunk-MPKKIL3U.js} +15 -12
  58. package/dist/bundle/{chunk-BJPFWPKH.js → chunk-MRWIXUYT.js} +2 -2
  59. package/dist/bundle/{chunk-BNTAQADF.js → chunk-MZ6U6HNJ.js} +12 -3
  60. package/dist/bundle/{chunk-6R3GMSLR.js → chunk-NJSIHMAE.js} +2 -2
  61. package/dist/bundle/{chunk-5MYLM6SU.js → chunk-NNNEVWFF.js} +108 -41
  62. package/dist/bundle/{chunk-2LLNPNMB.js → chunk-NO24PJNW.js} +1 -1
  63. package/dist/bundle/{chunk-HIZQYFY3.js → chunk-OXUHTKO2.js} +8 -2
  64. package/dist/bundle/{chunk-3YBDRVOG.js → chunk-PV3UDPCI.js} +82 -6
  65. package/dist/bundle/{chunk-IK2OSV5C.js → chunk-QI7BZS2G.js} +8 -13
  66. package/dist/bundle/{chunk-2NAM2XQG.js → chunk-QLCYAQ66.js} +2 -2
  67. package/dist/bundle/{chunk-RUJBN7ZP.js → chunk-R5BAF5XE.js} +1 -1
  68. package/dist/bundle/{chunk-IR73ZZY6.js → chunk-RZLNHNSS.js} +8 -8
  69. package/dist/bundle/{chunk-TQFCPUIM.js → chunk-S4GDDO5S.js} +1 -1
  70. package/dist/bundle/{chunk-YFIUXE25.js → chunk-SQWRZZOQ.js} +3 -3
  71. package/dist/bundle/{chunk-EJFSS65P.js → chunk-T3KICUOK.js} +6 -6
  72. package/dist/bundle/{chunk-UD4FKICZ.js → chunk-TC7PD3LH.js} +4 -4
  73. package/dist/bundle/{chunk-YBMOFCY5.js → chunk-TUIEDVI6.js} +2 -2
  74. package/dist/bundle/{chunk-JBBZCTTF.js → chunk-U3ZUT557.js} +1 -1
  75. package/dist/bundle/{chunk-EOEDICIE.js → chunk-U4RVOSX3.js} +1 -1
  76. package/dist/bundle/{chunk-BPMKLWHV.js → chunk-U5ASRBBF.js} +6 -4
  77. package/dist/bundle/{chunk-7CNRZSAV.js → chunk-UKU6MYUI.js} +4 -4
  78. package/dist/bundle/{chunk-72S5TXFN.js → chunk-UMHJZWZU.js} +9 -9
  79. package/dist/bundle/{chunk-TZE6WXID.js → chunk-UPJXN2CO.js} +10651 -9814
  80. package/dist/bundle/{chunk-NVC4VQ2B.js → chunk-VH4F2EK4.js} +1 -1
  81. package/dist/bundle/{chunk-SPJJCD2A.js → chunk-VJTGYBJJ.js} +18 -13
  82. package/dist/bundle/{chunk-MLNC5N7H.js → chunk-VW2SW7ME.js} +3 -3
  83. package/dist/bundle/{chunk-Q4ZE2LXE.js → chunk-WLSF3GCC.js} +2 -2
  84. package/dist/bundle/{chunk-N3KQ7XND.js → chunk-XJQB47IL.js} +4 -4
  85. package/dist/bundle/{chunk-KM7Q67Z3.js → chunk-Y3EIK4XW.js} +1 -1
  86. package/dist/bundle/{chunk-7LQLJ7LW.js → chunk-Z5424QL6.js} +2 -2
  87. package/dist/bundle/{chunk-LXYC75D3.js → chunk-ZFNM3FNI.js} +199 -141
  88. package/dist/bundle/{chunk-D6FTCPXA.js → chunk-ZH743WNV.js} +41 -12
  89. package/dist/bundle/{chunk-XAXXEZZ5.js → chunk-ZOGYTDHG.js} +2 -2
  90. package/dist/bundle/{chunk-SEH7DBAM.js → chunk-ZREFYKUB.js} +7 -7
  91. package/dist/bundle/{chunk-2DPMYUWQ.js → chunk-ZXGRK44F.js} +14 -13
  92. package/dist/bundle/{cli-AHPIESAC.js → cli-FDO6CP6R.js} +124 -60
  93. package/dist/bundle/command-contract-O4FDXM4U.js +37 -0
  94. package/dist/bundle/config-UBHKZG3J.js +78 -0
  95. package/dist/bundle/{decode-ZU7WLMMV.js → decode-7SZI3TGZ.js} +3 -3
  96. package/dist/bundle/{dist-LTS7VI3S.js → dist-5GWUXW27.js} +18 -14
  97. package/dist/bundle/{echarts-YNGCOYHW.js → echarts-FMACRZQC.js} +2 -2
  98. package/dist/bundle/{embed-VWWOW7PP.js → embed-24YSXHLP.js} +4 -4
  99. package/dist/bundle/{embedder-T5GJC7M2.js → embedder-MEXN2TFB.js} +7 -7
  100. package/dist/bundle/{first-run-PX3SHPUU.js → first-run-OCVEJH63.js} +8 -8
  101. package/dist/bundle/first-screen-KJIU25MH.js +35 -0
  102. package/dist/bundle/{folders-VXMDFC2D.js → folders-DBAAMU26.js} +2 -2
  103. package/dist/bundle/{instructions-GJHHFV64.js → instructions-E5FXYCWF.js} +1 -1
  104. package/dist/bundle/{main-APVJXUJE.js → main-EIUCXXDW.js} +17 -16
  105. package/dist/bundle/{mcp-EMNFFY4N.js → mcp-FUSDPAOL.js} +2 -2
  106. package/dist/bundle/{meetings-GHYNIOHG.js → meetings-JDTRGXZJ.js} +16 -6
  107. package/dist/bundle/{node-GFOH6FKP.js → node-4SNKUPXT.js} +2 -2
  108. package/dist/bundle/{node-sqlite-QXKSPHTP.js → node-sqlite-O4BAODFR.js} +9 -3
  109. package/dist/bundle/{oauth-A6I2OMDD.js → oauth-3YLHXGUW.js} +5 -5
  110. package/dist/bundle/{open-TQKCU447.js → open-QGRMSNM2.js} +3 -2
  111. package/dist/bundle/{openai-XE3BJXOI.js → openai-7PSCSTH7.js} +9 -9
  112. package/dist/bundle/{output-file-FQNFCUKE.js → output-file-J26UQKRA.js} +3 -3
  113. package/dist/bundle/{process-XVDX4SPD.js → process-HQZOTT6U.js} +1 -1
  114. package/dist/bundle/{program-QRKEXYDG.js → program-47DT7SHE.js} +75 -75
  115. package/dist/bundle/{prompt-ISYG5RWM.js → prompt-IUD7HCDC.js} +3 -3
  116. package/dist/bundle/{recognize-KENPECLZ.js → recognize-DMJJHHXF.js} +2 -2
  117. package/dist/bundle/{remote-ZP5XTDCC.js → remote-5WFSOVVB.js} +5 -5
  118. package/dist/bundle/{rerank-SG653RHT.js → rerank-UKQ65ECH.js} +5 -5
  119. package/dist/bundle/{run-log-HYKGQ42E.js → run-log-UGYL6NW2.js} +53 -53
  120. package/dist/bundle/{serve-6UJCZD7Z.js → serve-WAOSED3I.js} +9 -8
  121. package/dist/bundle/server-HAXN772R.js +66 -0
  122. package/dist/bundle/{server-ZAYEDPFR.js → server-NWZFNXC5.js} +42 -42
  123. package/dist/bundle/{services-KMH7XZPY.js → services-VPANRE72.js} +101 -28
  124. package/dist/bundle/{speech-LINBLG5E.js → speech-O6UNUDRW.js} +11 -11
  125. package/dist/bundle/{state-4RKZNHE7.js → state-BNE7I65A.js} +4 -4
  126. package/dist/bundle/{store-253N7NUC.js → store-4IIVSCJ4.js} +56 -19
  127. package/dist/bundle/{store-JTBHRQZK.js → store-QQH4FJXJ.js} +16 -13
  128. package/dist/bundle/store-connection-PPEQK2K3.js +76 -0
  129. package/dist/bundle/store-maintenance-command-JZXCT6NY.js +56 -0
  130. package/dist/bundle/{streaming-YW64OKKQ.js → streaming-S4EZB6P2.js} +4 -4
  131. package/dist/bundle/{tokens-DPBC2P3I.js → tokens-VCXIH7WZ.js} +4 -4
  132. package/dist/bundle/zm.js +1 -1
  133. package/dist/local-transcription.d.ts.map +1 -1
  134. package/dist/local-transcription.js +1 -0
  135. package/dist/local-transcription.js.map +1 -1
  136. package/dist/version.d.ts +1 -1
  137. package/dist/version.js +1 -1
  138. package/package.json +3 -3
  139. package/dist/bundle/answer-policy-V2KDPLDO.js +0 -96
  140. package/dist/bundle/chunk-2T7MUSDB.js +0 -3605
  141. package/dist/bundle/command-contract-HVLI3OKU.js +0 -38
  142. package/dist/bundle/config-3SFEGYZO.js +0 -78
  143. package/dist/bundle/first-screen-RAPEZG57.js +0 -36
  144. package/dist/bundle/server-AXE37E6Q.js +0 -66
  145. package/dist/bundle/store-connection-ID2ETC7F.js +0 -76
  146. package/dist/bundle/store-maintenance-command-XRNECVDU.js +0 -55
  147. /package/dist/bundle/{chunk-NPGVOZVK.js → chunk-NUN6OGOV.js} +0 -0
@@ -3,7 +3,7 @@ const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  AUDIT_MIN_SCORE,
5
5
  throughWrapper
6
- } from "./chunk-5NLFQ644.js";
6
+ } from "./chunk-M6IDHQ7N.js";
7
7
  import {
8
8
  Command,
9
9
  InvalidArgumentError,
@@ -16,13 +16,13 @@ import {
16
16
  renderAnswer,
17
17
  sharedCommand,
18
18
  snakeKeys
19
- } from "./chunk-IOUPXUFH.js";
19
+ } from "./chunk-6CS7ETBK.js";
20
20
  import {
21
21
  readOnlyLockOf
22
- } from "./chunk-Q4ZE2LXE.js";
22
+ } from "./chunk-WLSF3GCC.js";
23
23
  import {
24
24
  formatReference
25
- } from "./chunk-MIUPH3WA.js";
25
+ } from "./chunk-LOL6JYYN.js";
26
26
  import {
27
27
  EVENT_QUERY,
28
28
  MEETING_PROJECT_EVIDENCE_QUERY,
@@ -45,7 +45,7 @@ import {
45
45
  readMeetingProjectEvidence,
46
46
  validateMeetingHitSearch,
47
47
  validateMeetingPassage
48
- } from "./chunk-4OTXE6CF.js";
48
+ } from "./chunk-GMTXCFI7.js";
49
49
  import {
50
50
  OPERATORS_BY_TYPE,
51
51
  QUERY_LIMITS,
@@ -54,12 +54,13 @@ import {
54
54
  fieldsHelp,
55
55
  fieldsNamed,
56
56
  parseLucene,
57
+ queryDescription,
57
58
  queryError,
58
59
  queryFieldsOf,
59
60
  timezoneOf,
60
61
  validateQuery,
61
62
  zonedMoment
62
- } from "./chunk-D6FTCPXA.js";
63
+ } from "./chunk-ZH743WNV.js";
63
64
  import {
64
65
  CliError,
65
66
  array,
@@ -73,12 +74,12 @@ import {
73
74
  safeParse,
74
75
  strictObject,
75
76
  string
76
- } from "./chunk-SB47UAW2.js";
77
+ } from "./chunk-JF7ZEUXU.js";
77
78
  import {
78
79
  __name
79
80
  } from "./chunk-ZVVMGPBJ.js";
80
81
 
81
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/lacks.js
82
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/lacks.js
82
83
  var COMMAND_NEEDS = {
83
84
  "account update": ["updateProfile", "change the profile"],
84
85
  "account sessions list": ["sessions", "list the account's sessions"],
@@ -128,7 +129,7 @@ var hideNever = /* @__PURE__ */ __name((messenger, group) => {
128
129
  return group;
129
130
  }, "hideNever");
130
131
 
131
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/meetings/cli/search.js
132
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/meetings/cli/search.js
132
133
  var ZONED = /(?:Z|[+-]\d{2}:?\d{2})$/i;
133
134
  var moment = /* @__PURE__ */ __name((flag, end, readIn) => (value) => {
134
135
  const zone = timezoneOf();
@@ -214,7 +215,7 @@ var addMeetingSearchCommandDefinition = /* @__PURE__ */ __name((program, deps) =
214
215
  var createMeetingSearchCommand = sharedCommand(createMeetingSearchCommandDefinition);
215
216
  var addMeetingSearchCommand = sharedCommand(addMeetingSearchCommandDefinition);
216
217
 
217
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/meetings/cli/query-options.js
218
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/meetings/cli/query-options.js
218
219
  var queryWordsAfterOptions = /* @__PURE__ */ __name((command) => {
219
220
  command.allowUnknownOption();
220
221
  const parse = command.parseOptions.bind(command);
@@ -234,7 +235,7 @@ var queryWordsAfterOptions = /* @__PURE__ */ __name((command) => {
234
235
  return command;
235
236
  }, "queryWordsAfterOptions");
236
237
 
237
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/meetings/cli/passage.js
238
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/meetings/cli/passage.js
238
239
  var count = /* @__PURE__ */ __name((value) => {
239
240
  if (!/^(0|[1-9]\d*)$/.test(value) || !Number.isSafeInteger(Number(value)))
240
241
  throw new CliError("validation_error", "expected a nonnegative safe integer");
@@ -276,7 +277,7 @@ var addMeetingPassageCommandDefinition = /* @__PURE__ */ __name((program, deps)
276
277
  var createMeetingPassageCommand = sharedCommand(createMeetingPassageCommandDefinition);
277
278
  var addMeetingPassageCommand = sharedCommand(addMeetingPassageCommandDefinition);
278
279
 
279
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/meetings/cli/project-evidence.js
280
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/meetings/cli/project-evidence.js
280
281
  var integer2 = /* @__PURE__ */ __name((value) => {
281
282
  if (!/^[1-9]\d*$/.test(value) || !Number.isSafeInteger(Number(value)))
282
283
  throw new CliError("validation_error", "expected a positive safe integer");
@@ -299,7 +300,7 @@ ${fieldsHelp(MEETING_PROJECT_EVIDENCE_QUERY)}`).option("--limit <n>", "hits in o
299
300
  }, "addMeetingProjectEvidenceCommandDefinition");
300
301
  var addMeetingProjectEvidenceCommand = sharedCommand(addMeetingProjectEvidenceCommandDefinition);
301
302
 
302
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/meetings/cli/index.js
303
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/meetings/cli/index.js
303
304
  var integer3 = /* @__PURE__ */ __name((text) => {
304
305
  if (!/^[1-9]\d*$/.test(text) || !Number.isSafeInteger(Number(text)))
305
306
  throw new InvalidArgumentError("expected a positive integer");
@@ -402,6 +403,18 @@ ${deps.importHelp}`);
402
403
  throw new MeetingError("validation_error", "file account differs from selected account");
403
404
  print(await importFiles(files, deps.store, deps.now?.()), command);
404
405
  });
406
+ output(annotate(group.command("repair"), {
407
+ effects: LOCAL_WRITE,
408
+ output: { entity: "meeting_repair" }
409
+ }).description("preview filling in what older builds left out of stored transcripts (their language); --yes stores it")).option("--yes", "store the detected languages; otherwise only preview").action(async (opts, command) => {
410
+ if (!deps.store.fillTranscriptLanguages)
411
+ throw new MeetingError("configuration_error", "this store cannot fill transcript languages");
412
+ print(await deps.store.fillTranscriptLanguages({
413
+ accountId: deps.accountId,
414
+ apply: opts.yes === true,
415
+ now: deps.now?.() ?? Date.now()
416
+ }), command);
417
+ });
405
418
  const eventList = queryWordsAfterOptions(annotate(program.command("events").description("the owner's stored events"), {
406
419
  effects: { remote: "none", local: "none" }
407
420
  }).command("list")).description("list stored events").argument("[query...]", "event id, origin or time fields that narrow the list").addHelpText("after", `
@@ -419,13 +432,14 @@ ${fieldsHelp(EVENT_QUERY, MEETING_QUERY_GUIDE)}`);
419
432
  }, "addMeetingCommandsDefinition");
420
433
  var addMeetingCommands = sharedCommand(addMeetingCommandsDefinition);
421
434
 
422
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/list-query.js
435
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/list-query.js
423
436
  var LIST_QUERY_GUIDE = "https://github.com/WireCatLabs/cli-core/blob/main/docs/search/query-language.md";
437
+ var QUERY_ARGUMENT = "field:value terms that narrow the list \u2014 the fields are below";
424
438
  var withQuery = /* @__PURE__ */ __name((command, registry) => {
425
439
  const query = defineQuery(registry);
426
440
  annotate(command, { query, output: { entity: registry.entity } });
427
441
  const shown = askable(query);
428
- queryWordsAfterOptions(command).argument("[query...]", shown.length > 0 ? "field:value terms that narrow the list \u2014 the fields are below" : "field:value terms; this list filters by none yet");
442
+ queryWordsAfterOptions(command).argument("[query...]", shown.length > 0 ? QUERY_ARGUMENT : "field:value terms; this list filters by none yet");
429
443
  if (shown.length > 0)
430
444
  command.addHelpText("after", `
431
445
  ${fieldsHelp({ ...query, fields: shown }, LIST_QUERY_GUIDE)}`);
@@ -442,9 +456,19 @@ var commandPath = /* @__PURE__ */ __name((command) => {
442
456
  words.unshift(at.name());
443
457
  return words.join(" ");
444
458
  }, "commandPath");
445
- var listQuery = /* @__PURE__ */ __name((text, registry, command) => {
459
+ var withTomorrow = /* @__PURE__ */ __name((query, registry, zone = timezoneOf(), now = Date.now()) => {
460
+ const times = new Set(registry.fields.filter(({ type }) => type === "time").map(({ name }) => name));
461
+ const date2 = /* @__PURE__ */ new Date(`${new Intl.DateTimeFormat("en-CA", { timeZone: zone }).format(now)}T00:00:00Z`);
462
+ date2.setUTCDate(date2.getUTCDate() + 1);
463
+ const tomorrow = date2.toISOString().slice(0, 10);
464
+ const day = /* @__PURE__ */ __name((value) => value.toLowerCase() === "tomorrow" ? tomorrow : value, "day");
465
+ const map = /* @__PURE__ */ __name((node) => node.kind === "predicate" ? times.has(node.field) ? { ...node, value: day(node.value), ...node.upper === void 0 ? {} : { upper: day(node.upper) } } : node : { ...node, clauses: node.clauses.map((clause) => ({ ...clause, node: map(clause.node) })) }, "map");
466
+ return { ...query, root: map(query.root) };
467
+ }, "withTomorrow");
468
+ var listQuery = /* @__PURE__ */ __name((text, registry, command, { defaultField = "none" } = {}) => {
446
469
  const context = { command, guide: LIST_QUERY_GUIDE };
447
- const typed = text.trim() === "" ? void 0 : parseLucene(text, { defaultField: "none", ...context });
470
+ const parsed = text.trim() === "" ? void 0 : parseLucene(text, { defaultField, ...context });
471
+ const typed = parsed && withTomorrow(parsed, registry);
448
472
  if (typed)
449
473
  validateQuery(typed, registry, context);
450
474
  const named = typed ? fieldsNamed(typed) : /* @__PURE__ */ new Set();
@@ -475,12 +499,10 @@ var pagedList = /* @__PURE__ */ __name((command, { limit, page, all }, { items,
475
499
  page
476
500
  }), "pagedList");
477
501
  var askable = /* @__PURE__ */ __name((registry) => registry.backend === "native" ? registry.fields.filter((field) => field.native) : registry.fields, "askable");
478
- var queryArgument = /* @__PURE__ */ __name((registry) => {
479
- const fields = askable(registry);
480
- return optional(pipe(string(), maxLength(QUERY_LIMITS.bytes), description(fields.length === 0 ? "field:value terms; this list filters by none yet, so any term is refused" : `${registry.backend === "native" ? "field:value terms joined by AND that narrow the list" : "field:value terms that narrow the list (Lucene: AND OR NOT, [a TO b], > <)"}; fields: ${fields.map((field) => field.name).join(", ")}; e.g. ${fields[0]?.example ?? ""}`)));
481
- }, "queryArgument");
502
+ var queryArgument = /* @__PURE__ */ __name((registry) => optional(pipe(string(), maxLength(QUERY_LIMITS.bytes), description(queryDescription(registry)))), "queryArgument");
503
+ var negatableOf = /* @__PURE__ */ __name((registry) => askable(registry).filter((field) => field.negatable).map((field) => field.name), "negatableOf");
482
504
  var nativeTerms = /* @__PURE__ */ __name((ast, command) => new Map([...nativeTermLists(ast, command)].map(([field, [node]]) => [field, node])), "nativeTerms");
483
- var nativeTermLists = /* @__PURE__ */ __name((ast, command, repeatable = []) => {
505
+ var nativeTermLists = /* @__PURE__ */ __name((ast, command, repeatable = [], negatable = []) => {
484
506
  const terms = /* @__PURE__ */ new Map();
485
507
  if (!ast)
486
508
  return terms;
@@ -488,8 +510,14 @@ var nativeTermLists = /* @__PURE__ */ __name((ast, command, repeatable = []) =>
488
510
  const add = /* @__PURE__ */ __name((node) => {
489
511
  if (node.kind === "boolean") {
490
512
  for (const clause of node.clauses) {
513
+ const excluded = clause.occur === "must_not" && clause.node.kind === "predicate" && negatable.includes(clause.node.field);
514
+ if (excluded && clause.node.kind === "predicate") {
515
+ const key = `-${clause.node.field}`;
516
+ terms.set(key, [...terms.get(key) ?? [], clause.node]);
517
+ continue;
518
+ }
491
519
  if (clause.occur !== "must")
492
- queryError("query.unsupported-placement", clause.node.span, "this list takes only field:value terms joined by AND", context);
520
+ queryError("query.unsupported-placement", clause.node.span, negatable.length ? `this list takes only field:value terms joined by AND, and -field:value for ${negatable.join(", ")}` : "this list takes only field:value terms joined by AND", context);
493
521
  add(clause.node);
494
522
  }
495
523
  return;
@@ -545,7 +573,7 @@ var termField = /* @__PURE__ */ __name((name, type, example, more = {}) => nativ
545
573
  var queryHelp = /* @__PURE__ */ __name((registry) => `
546
574
  ${fieldsHelp(registry, LIST_QUERY_GUIDE)}`, "queryHelp");
547
575
 
548
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/paging.js
576
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/paging.js
549
577
  var positiveCount = /* @__PURE__ */ __name((flag) => (value) => {
550
578
  if (!/^\d+$/.test(value.trim()) || Number(value) < 1)
551
579
  throw new CliError("validation_error", `${flag} takes a whole number from 1 upwards, not "${value}"`);
@@ -554,7 +582,7 @@ var positiveCount = /* @__PURE__ */ __name((flag) => (value) => {
554
582
  var withPaging = /* @__PURE__ */ __name((command) => command.option("--limit <n>", "how many to show", positiveCount("--limit")).option("--page <n>", "which page, starting at 1", positiveCount("--page")).option("--all", "every row, no paging"), "withPaging");
555
583
  var window = /* @__PURE__ */ __name(({ limit, page, all }) => all ? { offset: 0 } : { limit, offset: (page - 1) * limit }, "window");
556
584
 
557
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/chat-answers.js
585
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/chat-answers.js
558
586
  var defined = /* @__PURE__ */ __name((record2) => Object.fromEntries(Object.entries(record2).filter(([, value]) => value !== void 0)), "defined");
559
587
  var chatRef = /* @__PURE__ */ __name((account, chat) => formatReference({ type: "chat", provider: account.provider, account: account.account, chat }), "chatRef");
560
588
  var settingsOf = /* @__PURE__ */ __name((settings) => defined({
@@ -816,7 +844,7 @@ var sessionAnswer = /* @__PURE__ */ __name(({ current, client, device, location,
816
844
  ...createdAt === void 0 ? {} : { created_at: createdAt }
817
845
  }), "sessionAnswer");
818
846
 
819
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/background/relay.js
847
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/background/relay.js
820
848
  import { createHash } from "node:crypto";
821
849
  import { chmodSync, lstatSync, mkdirSync, rmSync } from "node:fs";
822
850
  import { createConnection, createServer } from "node:net";
@@ -1037,7 +1065,7 @@ var relayCommand = /* @__PURE__ */ __name((path, request, options) => new Promis
1037
1065
  }, () => finish({ error: stopped() }));
1038
1066
  }), "relayCommand");
1039
1067
 
1040
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-relay.js
1068
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-relay.js
1041
1069
  var lentConnection = /* @__PURE__ */ __name((connection, watchers) => throughWrapper(connection, {
1042
1070
  close: /* @__PURE__ */ __name(async () => {
1043
1071
  }, "close"),
@@ -1141,6 +1169,7 @@ export {
1141
1169
  createMeetingSearchCommand,
1142
1170
  addMeetingCommands,
1143
1171
  LIST_QUERY_GUIDE,
1172
+ QUERY_ARGUMENT,
1144
1173
  withQuery,
1145
1174
  unfilteredQuery,
1146
1175
  commandPath,
@@ -1149,6 +1178,7 @@ export {
1149
1178
  pageOf,
1150
1179
  pagedList,
1151
1180
  queryArgument,
1181
+ negatableOf,
1152
1182
  nativeTerms,
1153
1183
  nativeTermLists,
1154
1184
  queryTerms,
@@ -3,12 +3,12 @@ const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  checkCancelled,
5
5
  object
6
- } from "./chunk-IOCS5FXW.js";
6
+ } from "./chunk-EA63UGWE.js";
7
7
  import {
8
8
  CliError,
9
9
  Credentials,
10
10
  isCliError
11
- } from "./chunk-SB47UAW2.js";
11
+ } from "./chunk-JF7ZEUXU.js";
12
12
  import {
13
13
  __name
14
14
  } from "./chunk-ZVVMGPBJ.js";
@@ -2,7 +2,7 @@ import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  resolvePaths
5
- } from "./chunk-SB47UAW2.js";
5
+ } from "./chunk-JF7ZEUXU.js";
6
6
  import {
7
7
  __name
8
8
  } from "./chunk-ZVVMGPBJ.js";
@@ -2,17 +2,18 @@ import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  refuseLacking
5
- } from "./chunk-ECXRRW7J.js";
5
+ } from "./chunk-2H5SXK7K.js";
6
6
  import {
7
7
  servingProfiles
8
- } from "./chunk-GOESXUJQ.js";
8
+ } from "./chunk-BWRBALXG.js";
9
9
  import {
10
10
  OFFLINE,
11
11
  capability,
12
12
  chatIdIn,
13
+ profilesOnAccount,
13
14
  servicesFor,
14
15
  throughWrapper
15
- } from "./chunk-5NLFQ644.js";
16
+ } from "./chunk-M6IDHQ7N.js";
16
17
  import {
17
18
  asFirstWord,
18
19
  baseContext,
@@ -23,30 +24,33 @@ import {
23
24
  recalledAccount,
24
25
  rememberAccount,
25
26
  rootOf2 as rootOf
26
- } from "./chunk-IOUPXUFH.js";
27
+ } from "./chunk-6CS7ETBK.js";
27
28
  import {
28
29
  MESSENGER_CHANGE_REFUSAL,
29
30
  readOnlyRefusal
30
- } from "./chunk-Q4ZE2LXE.js";
31
+ } from "./chunk-WLSF3GCC.js";
31
32
  import {
32
33
  providerErrorKey
33
- } from "./chunk-NQCFUYC2.js";
34
+ } from "./chunk-GBZF4IIP.js";
34
35
  import {
35
36
  LOG_ATTRIBUTES,
36
37
  codeOf,
37
38
  currentOperation,
38
39
  currentRun,
39
40
  fromLogAttributes,
41
+ limitBatch,
40
42
  logAttributes
41
- } from "./chunk-4OQVRDTG.js";
43
+ } from "./chunk-25IDWPEN.js";
42
44
  import {
43
45
  isCliFailure
44
- } from "./chunk-7LQLJ7LW.js";
46
+ } from "./chunk-Z5424QL6.js";
45
47
  import {
48
+ chatReferenceOf,
49
+ ensureAccount,
46
50
  foldName,
47
51
  isId,
48
52
  pickPerson
49
- } from "./chunk-3YBDRVOG.js";
53
+ } from "./chunk-PV3UDPCI.js";
50
54
  import {
51
55
  AUTHORITY_KEY,
52
56
  CEILING_KEY,
@@ -57,22 +61,22 @@ import {
57
61
  levelFor,
58
62
  readKeysForCommand,
59
63
  skipFlagFor
60
- } from "./chunk-HIZQYFY3.js";
64
+ } from "./chunk-OXUHTKO2.js";
61
65
  import {
62
66
  openStore
63
- } from "./chunk-TILW3EJY.js";
67
+ } from "./chunk-GXCNCMUY.js";
64
68
  import {
65
69
  CliError,
66
70
  logRecordOf,
67
71
  realSleep,
68
72
  resolvePaths,
69
73
  writeSecurely
70
- } from "./chunk-SB47UAW2.js";
74
+ } from "./chunk-JF7ZEUXU.js";
71
75
  import {
72
76
  __name
73
77
  } from "./chunk-ZVVMGPBJ.js";
74
78
 
75
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/ask.js
79
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/ask.js
76
80
  import { openSync } from "node:fs";
77
81
  import { createInterface } from "node:readline";
78
82
  import { ReadStream } from "node:tty";
@@ -127,10 +131,10 @@ var terminalAsker = /* @__PURE__ */ __name((command) => async (key, request) =>
127
131
  throw new CliError("cancelled", `${key}: not done \u2014 the answer was no`);
128
132
  }, "terminalAsker");
129
133
 
130
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/guard.js
134
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/guard.js
131
135
  import { randomUUID } from "node:crypto";
132
136
 
133
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/flood.js
137
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/flood.js
134
138
  import { mkdirSync, readFileSync, renameSync, writeFileSync } from "node:fs";
135
139
  import { dirname, join } from "node:path";
136
140
  var MOST_DEADLINES = 50;
@@ -214,11 +218,11 @@ var FloodMemory = class {
214
218
  }
215
219
  };
216
220
 
217
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/journal.js
221
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/journal.js
218
222
  import { appendFileSync, mkdirSync as mkdirSync3, readFileSync as readFileSync2 } from "node:fs";
219
223
  import { dirname as dirname3, join as join2 } from "node:path";
220
224
 
221
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/file-lock.js
225
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/file-lock.js
222
226
  import { closeSync, mkdirSync as mkdirSync2, openSync as openSync2, statSync, unlinkSync } from "node:fs";
223
227
  import { dirname as dirname2 } from "node:path";
224
228
  var LOCK_WAIT_MS = 5e3;
@@ -285,7 +289,7 @@ var lockTime = /* @__PURE__ */ __name((lock) => {
285
289
  }
286
290
  }, "lockTime");
287
291
 
288
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/journal.js
292
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/journal.js
289
293
  var sendsPathFor = /* @__PURE__ */ __name((app, profile, env = process.env) => join2(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "sends", `${profile}.jsonl`), "sendsPathFor");
290
294
  var SendJournal = class {
291
295
  static {
@@ -362,7 +366,7 @@ var withSendId = /* @__PURE__ */ __name((entry) => {
362
366
  return cid === void 0 || rest.sendId !== void 0 ? rest : { ...rest, sendId: String(cid) };
363
367
  }, "withSendId");
364
368
 
365
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/recipients.js
369
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/recipients.js
366
370
  import { existsSync, readFileSync as readFileSync3, rmSync } from "node:fs";
367
371
  import { join as join3 } from "node:path";
368
372
  var recipientsPathFor = /* @__PURE__ */ __name((app, profile, env = process.env) => join3(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "profiles", `${profile}.recipients.json`), "recipientsPathFor");
@@ -474,7 +478,7 @@ var RecipientList = class {
474
478
  }
475
479
  };
476
480
 
477
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/guard.js
481
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/guard.js
478
482
  var HOUR_MS = 60 * 60 * 1e3;
479
483
  var READS_UNDER_HOLD = /* @__PURE__ */ new Set([
480
484
  "attachments.extract",
@@ -667,7 +671,7 @@ var guardFor = /* @__PURE__ */ __name((app, settings, warn, env = process.env, a
667
671
  }), "guardFor");
668
672
  var journalFailure = /* @__PURE__ */ __name((error) => error?.code ?? (error instanceof Error ? error.name : "error"), "journalFailure");
669
673
 
670
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/permission-keys.js
674
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/permission-keys.js
671
675
  var HOUSEKEEPING = /* @__PURE__ */ new Set([
672
676
  "help",
673
677
  "guide",
@@ -746,10 +750,37 @@ var refuseUnknownPermissionKeys = /* @__PURE__ */ __name((command, settings, too
746
750
  throw new CliError("validation_error", `--permission ${key} names no command`, { permission: key });
747
751
  }, "refuseUnknownPermissionKeys");
748
752
 
749
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/stored.js
753
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/stored.js
750
754
  var REKEY_PACING = { lockMs: 50, pauseMs: 25 };
751
- var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events, pending, announcing, deletedWithoutChat, profile, rekeyed, rekeyPacing = REKEY_PACING, closing, namesFromStore, recipientIds, countsUnread = false }) => {
755
+ 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" }) => {
752
756
  let warned = false;
757
+ let limitedNoted = false;
758
+ const limited = /* @__PURE__ */ __name(async (opened, batch) => {
759
+ if (!historyLimits || !batch.messages?.length)
760
+ return { batch, skipped: /* @__PURE__ */ new Map() };
761
+ const shapes = await opened.chats.historyShapes(account, [...new Set(batch.messages.map((one) => one.chatId))]);
762
+ return limitBatch(batch, (chatId) => shapes.get(chatId), (chatId) => shapes.get(chatId)?.included === true, historyLimits);
763
+ }, "limited");
764
+ const noteLimited = /* @__PURE__ */ __name((skipped) => {
765
+ if (skipped.size === 0)
766
+ return;
767
+ const counts = {
768
+ chats: skipped.size,
769
+ messages: 0,
770
+ group_too_large: 0,
771
+ older_than_window: 0
772
+ };
773
+ for (const skip of skipped.values()) {
774
+ counts.messages = (counts.messages ?? 0) + skip.messages;
775
+ counts[skip.reason] = (counts[skip.reason] ?? 0) + 1;
776
+ }
777
+ const warning = { event: "warning", code: "history_limited", operation: "history.save", counts };
778
+ events(warning);
779
+ if (limitedNoted)
780
+ return;
781
+ limitedNoted = true;
782
+ warn(`history limits left out ${counts.messages} pushed messages of ${skipped.size} chats (big groups, older than the window) \u2014 \`${command} store status\` lists them; \`${command} messages sync <chat> --full-history\` fetches one and keeps it in full`, warning);
783
+ }, "noteLimited");
753
784
  let recorded = profile === void 0;
754
785
  const notWritten = /* @__PURE__ */ __name((operation, error) => {
755
786
  const warning = { event: "warning", code: "store_not_written", operation };
@@ -761,15 +792,18 @@ var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events,
761
792
  const attempt = /* @__PURE__ */ __name(async (operation, write) => {
762
793
  try {
763
794
  const opened = await store();
764
- if (opened)
765
- await write(opened);
795
+ if (!opened)
796
+ return false;
797
+ await write(opened);
766
798
  if (opened && !recorded && profile) {
767
799
  recorded = true;
768
800
  await Promise.resolve().then(() => opened.accounts.saveProfile(profile.app, profile.name, account)).catch(() => {
769
801
  });
770
802
  }
803
+ return true;
771
804
  } catch (error) {
772
805
  notWritten(operation, error);
806
+ return false;
773
807
  }
774
808
  }, "attempt");
775
809
  const save = /* @__PURE__ */ __name((operation, writing) => {
@@ -867,7 +901,13 @@ var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events,
867
901
  rekeysQueued += rekeys.length;
868
902
  const saving = previous.then(async () => {
869
903
  await saveRekeys(rekeys, round);
870
- await attempt(operation, (opened) => fill(opened, account, batch));
904
+ return attempt(operation, async (opened) => {
905
+ const { batch: kept, skipped } = await limited(opened, batch);
906
+ await fill(opened, account, kept);
907
+ if (skipped.size > 0)
908
+ await opened.chats.recordHistorySkips(account, skipped);
909
+ noteLimited(skipped);
910
+ });
871
911
  });
872
912
  previous = saving;
873
913
  pending?.add(saving);
@@ -877,10 +917,11 @@ var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events,
877
917
  pending?.delete(saving);
878
918
  rekeysOnly.delete(saving);
879
919
  });
880
- onBatch(batch);
920
+ void onBatch(batch, saving);
921
+ return saving;
881
922
  };
882
923
  }, "saveBatches");
883
- return throughWrapper(messenger, {
924
+ const wrapped = throughWrapper(messenger, {
884
925
  ...messenger.forumState ? {
885
926
  forumState: /* @__PURE__ */ __name(async (chatId) => {
886
927
  const state = await capability(messenger, "forumState", "read forum settings")(chatId);
@@ -1101,7 +1142,54 @@ var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events,
1101
1142
  return sent;
1102
1143
  }, "send")
1103
1144
  });
1145
+ const chatOf2 = /* @__PURE__ */ __name(async (typed) => {
1146
+ const named = chatReferenceOf(typed, account.provider);
1147
+ if (!named)
1148
+ return typed;
1149
+ let known;
1150
+ try {
1151
+ known = account.account;
1152
+ } catch {
1153
+ }
1154
+ await ensureAccount(named, { account: known, ...profile ? { profile: profile.name } : {} }, async (other) => {
1155
+ const opened = await store();
1156
+ return opened && profilesOnAccount(opened, profile?.app, account.provider)(other);
1157
+ });
1158
+ return named.chat;
1159
+ }, "chatOf");
1160
+ return withChatReferences(wrapped, chatOf2);
1104
1161
  }, "stored");
1162
+ var TYPED_CHAT = [
1163
+ "resolve",
1164
+ "chat",
1165
+ "history",
1166
+ "around",
1167
+ "historyAfter",
1168
+ "historyBefore",
1169
+ "historyFrom",
1170
+ "topics",
1171
+ "topic",
1172
+ "topicHistory",
1173
+ "download",
1174
+ "transcribe",
1175
+ "scheduled",
1176
+ "admins",
1177
+ "chatEvents",
1178
+ "leave",
1179
+ "group",
1180
+ "officialChatStats"
1181
+ ];
1182
+ var withChatReferences = /* @__PURE__ */ __name((adapter, chatOf2) => {
1183
+ const methods = adapter;
1184
+ const own = Object.fromEntries(TYPED_CHAT.flatMap((name) => {
1185
+ const method = methods[name];
1186
+ if (typeof method !== "function")
1187
+ return [];
1188
+ const call = /* @__PURE__ */ __name(async (typed, ...rest) => method.call(adapter, await chatOf2(typed), ...rest), "call");
1189
+ return [[name, call]];
1190
+ }));
1191
+ return throughWrapper(adapter, own);
1192
+ }, "withChatReferences");
1105
1193
  var saveSent = /* @__PURE__ */ __name((opened, account, typed, message, options, into = message.chatId || typed) => opened.messages.saveMessages(account, into, [message], { ...options, typedChatId: typed }), "saveSent");
1106
1194
  var storedChat = /* @__PURE__ */ __name(async (store, account, traits, reference) => {
1107
1195
  const bound = store.forAccount(account);
@@ -1238,7 +1326,7 @@ var keep = /* @__PURE__ */ __name(async (store, account, event, seenAt, among, c
1238
1326
  }
1239
1327
  }, "keep");
1240
1328
 
1241
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/sends/pace.js
1329
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/sends/pace.js
1242
1330
  import { readFileSync as readFileSync4, renameSync as renameSync2, writeFileSync as writeFileSync2 } from "node:fs";
1243
1331
  import { join as join4 } from "node:path";
1244
1332
  var DEFAULT_PACE = { perMinute: 60, burst: 20 };
@@ -1297,7 +1385,7 @@ var Pacer = class {
1297
1385
  }
1298
1386
  };
1299
1387
 
1300
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
1388
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
1301
1389
  var LONG_LIVED = /* @__PURE__ */ new Set(["self", "newSendId", "close", "formatMarkdown", "formatHtml", "storedChats"]);
1302
1390
  var LISTENING = /* @__PURE__ */ new Set(["watch", "feed", "listen", "listenHistory"]);
1303
1391
  var BLOCKING = /* @__PURE__ */ new Set(["frozen", "limited", "banned"]);
@@ -1416,7 +1504,7 @@ var flooded = /* @__PURE__ */ __name((messenger, memory, { name, warn, pacer })
1416
1504
  });
1417
1505
  }, "flooded");
1418
1506
 
1419
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/observed.js
1507
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/observed.js
1420
1508
  var observed = /* @__PURE__ */ __name((messenger, events) => {
1421
1509
  const timed = /* @__PURE__ */ __name(async (operation, named, work, after) => {
1422
1510
  const write = currentOperation();
@@ -1452,9 +1540,9 @@ var observed = /* @__PURE__ */ __name((messenger, events) => {
1452
1540
  }, "timed");
1453
1541
  const counted = /* @__PURE__ */ __name(async (operation, onItem, work, count) => {
1454
1542
  const counts = {};
1455
- await timed(operation, {}, () => work((item) => {
1543
+ await timed(operation, {}, () => work((item, ...rest) => {
1456
1544
  count(item, counts);
1457
- onItem(item);
1545
+ return onItem(item, ...rest);
1458
1546
  }), () => ({ counts }));
1459
1547
  }, "counted");
1460
1548
  const mint = messenger.newSendId;
@@ -1515,7 +1603,7 @@ var byPart = /* @__PURE__ */ __name((batch, counts) => {
1515
1603
  counts[part] = (counts[part] ?? 0) + items.length;
1516
1604
  }, "byPart");
1517
1605
 
1518
- // node_modules/.pnpm/@wirecat+cli-core@0.507.0_@wirecat+cli-base@0.68.1_commander@15.0.0_esbuild@0.28.2_type_d5beb0101c7a90701cc33879a5be8d28/node_modules/@wirecat/cli-core/dist/cli/messenger/context.js
1606
+ // node_modules/.pnpm/@wirecat+cli-core@0.552.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_23aa5a610a285948c067a35e1587367b/node_modules/@wirecat/cli-core/dist/cli/messenger/context.js
1519
1607
  var lazyStore = /* @__PURE__ */ __name((env, command, version) => {
1520
1608
  let opened;
1521
1609
  return {
@@ -1693,7 +1781,8 @@ var connected = /* @__PURE__ */ __name((connection, { app, provider, name, delet
1693
1781
  rekeyed: /* @__PURE__ */ __name((from, to) => rekeyRecipients(app, settings.profile, env, renderer.warn, from, to), "rekeyed"),
1694
1782
  recipientIds: /* @__PURE__ */ __name(() => (new RecipientList(recipientsPathFor(app, settings.profile, env), app.command).read() ?? []).flatMap((recipient) => [recipient.id, ...recipient.partnerId ? [recipient.partnerId] : []]), "recipientIds"),
1695
1783
  ...history === "store" ? { namesFromStore: savedChatId ? { savedChatId } : {} } : {},
1696
- ...unreadCounts === "store" ? { countsUnread: true } : {}
1784
+ ...unreadCounts === "store" ? { countsUnread: true } : {},
1785
+ ...history === "store" && settings.historyLimits ? { historyLimits: settings.historyLimits, command: `${app.command} ${settings.profile}` } : {}
1697
1786
  });
1698
1787
  const passives = history === "store" && self !== null && !watching ? passivesOf(saving).map((passive) => listened(passive, events, renderer.warn, closeWaitMs)) : [];
1699
1788
  return {
@@ -1855,6 +1944,7 @@ var messengerContext = /* @__PURE__ */ __name((command, messenger, resolving = {
1855
1944
  // Turning recording off by name (--no-record, or record: false) keeps no search history either.
1856
1945
  history: base.settings.record,
1857
1946
  searchCatchUp: base.settings.searchCatchUp,
1947
+ ...base.settings.historyLimits ? { historyLimits: base.settings.historyLimits } : {},
1858
1948
  pictures: base.settings.pictureSearch,
1859
1949
  reranker: base.settings.searchReranker,
1860
1950
  guard,