@wirecat/tg-cli 0.124.0 → 0.125.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 (116) hide show
  1. package/contracts/wirecat.json +7 -1
  2. package/dist/bin/tg.js +2 -2
  3. package/dist/bundle/{adapter-GEIZVMWU.js → adapter-H2LTOLOA.js} +52 -53
  4. package/dist/bundle/{all-profiles-EY4GJFWN.js → all-profiles-75HGEFL7.js} +10 -10
  5. package/dist/bundle/{anthropic-RIANJ7WM.js → anthropic-N54MKE4C.js} +5 -5
  6. package/dist/bundle/{app-server-LW7WBFIF.js → app-server-3N5INKKI.js} +45 -45
  7. package/dist/bundle/{bot-api-FHIQ66OM.js → bot-api-V65KTEAH.js} +53 -54
  8. package/dist/bundle/{bot-history-O34YZEFH.js → bot-history-TT2EAHEE.js} +18 -18
  9. package/dist/bundle/{bun-MJWD4VGV.js → bun-LN4J7PA7.js} +2 -2
  10. package/dist/bundle/{bun-sqlite-LCHVO3OB.js → bun-sqlite-6PDBFBUI.js} +6 -6
  11. package/dist/bundle/{chunk-N5UM63JW.js → chunk-37SZHAEA.js} +55 -55
  12. package/dist/bundle/{chunk-A5RWKKBZ.js → chunk-3GILMKQ2.js} +3 -3
  13. package/dist/bundle/{chunk-XDHGM2Z7.js → chunk-4KIOWSDL.js} +3 -3
  14. package/dist/bundle/{chunk-ZL5YG2WK.js → chunk-4TCBRKWQ.js} +7 -7
  15. package/dist/bundle/{chunk-CDSSKK5J.js → chunk-6HLB73UN.js} +3 -3
  16. package/dist/bundle/{chunk-OH3IZ6GW.js → chunk-6Y6SSZ34.js} +100 -91
  17. package/dist/bundle/{chunk-3VVZFBE2.js → chunk-77Z3OGAT.js} +3 -3
  18. package/dist/bundle/{chunk-E6VSARSU.js → chunk-7KCBPAQS.js} +2 -2
  19. package/dist/bundle/{chunk-F3GHTPAO.js → chunk-7OBSIDBJ.js} +4 -4
  20. package/dist/bundle/{chunk-OVDB5CQM.js → chunk-AI2J3WJT.js} +1 -1
  21. package/dist/bundle/{chunk-HSRO77SW.js → chunk-AMPHPP4P.js} +15 -15
  22. package/dist/bundle/{chunk-SGBH3D5D.js → chunk-B252D7V4.js} +3 -3
  23. package/dist/bundle/{chunk-2YLIVDWJ.js → chunk-BLNMM3AX.js} +2 -2
  24. package/dist/bundle/{chunk-GUL6QLNI.js → chunk-CNEJQQMD.js} +17 -17
  25. package/dist/bundle/{chunk-QFV36CAH.js → chunk-DI3RJ3MJ.js} +4 -4
  26. package/dist/bundle/{chunk-DFSLHF46.js → chunk-DNCOELTM.js} +1 -1
  27. package/dist/bundle/{chunk-54JPEGQA.js → chunk-DYOZ7CUV.js} +2 -2
  28. package/dist/bundle/{chunk-E66JBGZZ.js → chunk-E4HDE5DN.js} +2 -2
  29. package/dist/bundle/{chunk-5EL6E6PW.js → chunk-EIGV2JKX.js} +1 -1
  30. package/dist/bundle/{chunk-RHJHOOUL.js → chunk-FHPEUAHQ.js} +181 -155
  31. package/dist/bundle/{chunk-PJGOQSE5.js → chunk-FIVFP53N.js} +1 -1
  32. package/dist/bundle/{chunk-ISGXVFA4.js → chunk-FSP74THJ.js} +4 -4
  33. package/dist/bundle/{chunk-UP3J3YXH.js → chunk-FUYCAROL.js} +6 -6
  34. package/dist/bundle/{chunk-VGUWIHXD.js → chunk-GRDVBJCR.js} +1 -1
  35. package/dist/bundle/{chunk-NL4COYPY.js → chunk-GUPMDMFM.js} +7 -7
  36. package/dist/bundle/{chunk-KVJSCJGZ.js → chunk-HHG5FR5H.js} +2 -2
  37. package/dist/bundle/{chunk-PP4ZBLS4.js → chunk-IN3NAFUN.js} +9 -9
  38. package/dist/bundle/{chunk-NQXVZ5WT.js → chunk-INZAZMUF.js} +6 -6
  39. package/dist/bundle/{chunk-OK4M4MWI.js → chunk-IX3GUNGV.js} +4 -4
  40. package/dist/bundle/{chunk-RBV4M2TC.js → chunk-JB4BO5XZ.js} +1 -1
  41. package/dist/bundle/{chunk-42R4YO4L.js → chunk-JC6HMPL7.js} +1076 -877
  42. package/dist/bundle/{chunk-3PLMMFP6.js → chunk-JCNKGZQG.js} +17 -17
  43. package/dist/bundle/{chunk-PI4XXMPG.js → chunk-JKF7LZBU.js} +6 -6
  44. package/dist/bundle/{chunk-XSGUG5WG.js → chunk-LD42OGKK.js} +4 -4
  45. package/dist/bundle/{chunk-VMWJGUVV.js → chunk-LU2CHHPC.js} +4 -4
  46. package/dist/bundle/{chunk-OIF4B526.js → chunk-M4OP5ASJ.js} +1 -1
  47. package/dist/bundle/{chunk-2GFGZDWS.js → chunk-MK4IKICN.js} +2 -2
  48. package/dist/bundle/{chunk-4CIVGT4P.js → chunk-NM5GBJME.js} +19 -19
  49. package/dist/bundle/{chunk-IVFUSI7G.js → chunk-NTHALPDT.js} +2 -2
  50. package/dist/bundle/{chunk-M4W4Y5YR.js → chunk-OG2ONSH6.js} +53 -32
  51. package/dist/bundle/{chunk-2NG4JPP7.js → chunk-PCC7GWOS.js} +4 -4
  52. package/dist/bundle/{chunk-UII3D3HR.js → chunk-QVK7NF3A.js} +30 -30
  53. package/dist/bundle/{chunk-QGCVQRHV.js → chunk-QYT6HDCL.js} +1 -1
  54. package/dist/bundle/{chunk-BV3HZYOX.js → chunk-RX5GU7GQ.js} +359 -326
  55. package/dist/bundle/{chunk-LKMZ53GC.js → chunk-RZ7KBWDQ.js} +2 -2
  56. package/dist/bundle/{chunk-7AWJZ6NJ.js → chunk-S4SOS27T.js} +8 -8
  57. package/dist/bundle/{chunk-W4LMTNN2.js → chunk-SGHF75RQ.js} +2 -2
  58. package/dist/bundle/{chunk-WSLIXJET.js → chunk-TAFH5K5D.js} +346 -268
  59. package/dist/bundle/{chunk-QK4T3VN7.js → chunk-TVQBOIWC.js} +1 -1
  60. package/dist/bundle/{chunk-4EGB7GSW.js → chunk-UG66U2T7.js} +18 -19
  61. package/dist/bundle/{chunk-I4JUKRW7.js → chunk-URFBZNLU.js} +2 -2
  62. package/dist/bundle/{chunk-VAKSXD4F.js → chunk-UTNK2PFE.js} +13 -13
  63. package/dist/bundle/{chunk-PZ6H65D6.js → chunk-VG3EQJYV.js} +34 -5
  64. package/dist/bundle/{chunk-ZNICTHSC.js → chunk-VHD4V64E.js} +1 -1
  65. package/dist/bundle/{chunk-ZTMV5M3D.js → chunk-VUBSGQ2O.js} +26 -24
  66. package/dist/bundle/{chunk-HEV23NIB.js → chunk-VZDAVZYX.js} +6 -6
  67. package/dist/bundle/{chunk-IK6XKMLL.js → chunk-WH4T44L3.js} +1 -1
  68. package/dist/bundle/{chunk-YQFO7WXQ.js → chunk-X6436BYW.js} +2 -2
  69. package/dist/bundle/{chunk-UR62DZ7Q.js → chunk-XS5C5TQ7.js} +8 -8
  70. package/dist/bundle/{chunk-WKOVQ4OU.js → chunk-XTNOBJRP.js} +12 -12
  71. package/dist/bundle/{chunk-ASEBKZFY.js → chunk-YRZXOQOB.js} +2 -2
  72. package/dist/bundle/{chunk-QWAMX6CN.js → chunk-ZX5OSZHH.js} +12 -12
  73. package/dist/bundle/command-contract-JP6SCP7U.js +34 -0
  74. package/dist/bundle/{command-server-entry-K52OEKIO.js → command-server-entry-BLSFT3T6.js} +24 -24
  75. package/dist/bundle/{decode-OAE25LEJ.js → decode-NNLEQU7B.js} +5 -5
  76. package/dist/bundle/{dispatch-6GVTXIZ2.js → dispatch-PRAIGIFS.js} +8 -8
  77. package/dist/bundle/{echarts-EO4ZGKMN.js → echarts-XAZHGDOM.js} +2 -2
  78. package/dist/bundle/{embed-TB2AS4AT.js → embed-Q7ZCVSCO.js} +6 -6
  79. package/dist/bundle/{embedder-YKC42G6L.js → embedder-MVS3PVWQ.js} +9 -9
  80. package/dist/bundle/{entry-AB6FU7BN.js → entry-XN3ZZAOK.js} +9 -9
  81. package/dist/bundle/{failure-CY7ACT6V.js → failure-7Y34AUJT.js} +2 -2
  82. package/dist/bundle/{first-run-CMQZHDI5.js → first-run-G4EFTONI.js} +11 -11
  83. package/dist/bundle/first-screen-RIDJEPC3.js +32 -0
  84. package/dist/bundle/{instructions-RM3IB6ID.js → instructions-QDHYYZBU.js} +1 -1
  85. package/dist/bundle/{mcp-M5YCSWJJ.js → mcp-TDKGDB4V.js} +2 -2
  86. package/dist/bundle/{node-D2PM62TA.js → node-3Y7OVY2U.js} +2 -2
  87. package/dist/bundle/{node-sqlite-UK5DE525.js → node-sqlite-R2SBROJM.js} +7 -7
  88. package/dist/bundle/{oauth-SKRG67A2.js → oauth-WSPWMWTV.js} +7 -7
  89. package/dist/bundle/{open-XP3SY62D.js → open-VFLF4HRQ.js} +5 -5
  90. package/dist/bundle/{openai-Q3U46UPA.js → openai-DFCKZZDV.js} +21 -20
  91. package/dist/bundle/{process-YJ4LHMJB.js → process-VZKFAGNP.js} +1 -1
  92. package/dist/bundle/{program-EEPEFKTR.js → program-2LB3CUZX.js} +62 -60
  93. package/dist/bundle/{prompt-WYTODP4U.js → prompt-RVLA2PEY.js} +5 -5
  94. package/dist/bundle/{proxy-transport-HJMQ5QFT.js → proxy-transport-DP7SIMIC.js} +5 -5
  95. package/dist/bundle/{recognize-K2S5QQU2.js → recognize-LEKNA3G5.js} +4 -4
  96. package/dist/bundle/{remote-7RSAJ3JC.js → remote-WG5V2I2G.js} +9 -9
  97. package/dist/bundle/{rerank-RJX77BKD.js → rerank-ONAEQVJ6.js} +7 -7
  98. package/dist/bundle/{serve-3E7NN3VW.js → serve-BL2X6FZG.js} +9 -9
  99. package/dist/bundle/{server-O3KU56A4.js → server-3LSC4BMK.js} +36 -36
  100. package/dist/bundle/server-7EYEEGJT.js +62 -0
  101. package/dist/bundle/{sqlite-runtime-RCS5WSG5.js → sqlite-runtime-RQXPRH6C.js} +6 -6
  102. package/dist/bundle/{state-PLWSPSAG.js → state-O7LRA526.js} +6 -6
  103. package/dist/bundle/{store-3FYLH53Z.js → store-7C4UAND2.js} +15 -15
  104. package/dist/bundle/{store-DWMKCXYL.js → store-HMJUPK45.js} +13 -13
  105. package/dist/bundle/store-maintenance-command-I7PSA3SZ.js +52 -0
  106. package/dist/bundle/tg.js +13 -13
  107. package/dist/version.d.ts +1 -1
  108. package/dist/version.js +1 -1
  109. package/package.json +3 -3
  110. package/skills/tg-cli/SKILL.md +6 -2
  111. package/dist/bundle/chunk-VIIIC5LU.js +0 -32
  112. package/dist/bundle/command-contract-UKOL455D.js +0 -34
  113. package/dist/bundle/first-screen-XZ73W3VE.js +0 -32
  114. package/dist/bundle/server-ITHYDPWQ.js +0 -62
  115. package/dist/bundle/store-maintenance-command-3UEKINRB.js +0 -52
  116. /package/dist/bundle/{chunk-HVJJWJYQ.js → chunk-XWBPP2HX.js} +0 -0
@@ -8,16 +8,16 @@ import {
8
8
  sameOrdinaryFile,
9
9
  syncDirectory,
10
10
  writeFileAtomic
11
- } from "./chunk-VAKSXD4F.js";
11
+ } from "./chunk-UTNK2PFE.js";
12
12
  import {
13
13
  isNewer,
14
14
  updateCommand
15
- } from "./chunk-XSGUG5WG.js";
15
+ } from "./chunk-LD42OGKK.js";
16
16
  import {
17
17
  localOnly,
18
18
  refuseOffComputer,
19
19
  remoteKey
20
- } from "./chunk-PP4ZBLS4.js";
20
+ } from "./chunk-IN3NAFUN.js";
21
21
  import {
22
22
  Unzip,
23
23
  UnzipInflate,
@@ -28,7 +28,7 @@ import {
28
28
  placedText,
29
29
  runEmbedders,
30
30
  textModelsDirectory
31
- } from "./chunk-PI4XXMPG.js";
31
+ } from "./chunk-JKF7LZBU.js";
32
32
  import {
33
33
  AGENDA_COLUMNS,
34
34
  BUSINESS_FIND_MAX,
@@ -108,13 +108,13 @@ import {
108
108
  validateAst,
109
109
  validateFields,
110
110
  withoutField
111
- } from "./chunk-42R4YO4L.js";
111
+ } from "./chunk-JC6HMPL7.js";
112
112
  import {
113
113
  DEFAULT_STEMMERS,
114
114
  createStemmer,
115
115
  fold,
116
116
  normalize
117
- } from "./chunk-7AWJZ6NJ.js";
117
+ } from "./chunk-S4SOS27T.js";
118
118
  import {
119
119
  EmptyAnswer,
120
120
  MAX_MODEL_IMAGE_BYTES,
@@ -123,7 +123,7 @@ import {
123
123
  range,
124
124
  systemFor,
125
125
  validateImages
126
- } from "./chunk-VMWJGUVV.js";
126
+ } from "./chunk-LU2CHHPC.js";
127
127
  import {
128
128
  CEILING_KEY,
129
129
  Command,
@@ -172,24 +172,25 @@ import {
172
172
  textModels,
173
173
  vectorModelKey,
174
174
  writeTextModelsSection
175
- } from "./chunk-RHJHOOUL.js";
175
+ } from "./chunk-FHPEUAHQ.js";
176
176
  import {
177
177
  MESSENGER_CHANGE_REFUSAL,
178
178
  ancestorValue,
179
179
  envName,
180
180
  readOnlyLockOf,
181
181
  readOnlyRefusal
182
- } from "./chunk-54JPEGQA.js";
182
+ } from "./chunk-DYOZ7CUV.js";
183
183
  import {
184
184
  PLAIN_HTTP_REFUSED,
185
185
  endpoint,
186
+ endpointFetch,
186
187
  modelAddressAllowed,
187
188
  onThisComputer
188
- } from "./chunk-VIIIC5LU.js";
189
+ } from "./chunk-VG3EQJYV.js";
189
190
  import {
190
191
  installFiles,
191
192
  megabytes
192
- } from "./chunk-2NG4JPP7.js";
193
+ } from "./chunk-PCC7GWOS.js";
193
194
  import {
194
195
  EVENT_QUERY,
195
196
  INTERNAL_NOTES,
@@ -271,22 +272,22 @@ import {
271
272
  walkQuery,
272
273
  withAttempt,
273
274
  zonedMoment
274
- } from "./chunk-OH3IZ6GW.js";
275
+ } from "./chunk-6Y6SSZ34.js";
275
276
  import {
276
277
  isCliFailure,
277
278
  sqliteCode
278
- } from "./chunk-3VVZFBE2.js";
279
+ } from "./chunk-77Z3OGAT.js";
279
280
  import {
280
281
  DEFAULT_TASK_CATEGORIES,
281
282
  FALLBACK_CATEGORY,
282
283
  readSharedSection,
283
284
  sharedConfigPath,
284
285
  writeSharedSection
285
- } from "./chunk-UP3J3YXH.js";
286
+ } from "./chunk-FUYCAROL.js";
286
287
  import {
287
288
  storePath,
288
289
  wirecatDirectory
289
- } from "./chunk-IVFUSI7G.js";
290
+ } from "./chunk-NTHALPDT.js";
290
291
  import {
291
292
  Credentials,
292
293
  logRecordOf,
@@ -294,7 +295,7 @@ import {
294
295
  realSleep,
295
296
  resolvePaths,
296
297
  writeSecurely
297
- } from "./chunk-4CIVGT4P.js";
298
+ } from "./chunk-NM5GBJME.js";
298
299
  import {
299
300
  array,
300
301
  boolean,
@@ -323,7 +324,7 @@ import {
323
324
  trim,
324
325
  union,
325
326
  unknown
326
- } from "./chunk-UR62DZ7Q.js";
327
+ } from "./chunk-XS5C5TQ7.js";
327
328
  import {
328
329
  importFrom,
329
330
  resolveFrom
@@ -333,7 +334,7 @@ import {
333
334
  isCliError,
334
335
  singleLine,
335
336
  visibleControls
336
- } from "./chunk-E6VSARSU.js";
337
+ } from "./chunk-7KCBPAQS.js";
337
338
  import {
338
339
  __commonJS,
339
340
  __name,
@@ -16949,7 +16950,7 @@ var require_lib3 = __commonJS({
16949
16950
  }
16950
16951
  });
16951
16952
 
16952
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/conversations/link.js
16953
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/conversations/link.js
16953
16954
  var RULES_VERSION = 5;
16954
16955
  var LOOK_BACK = 50;
16955
16956
  var SAME_SENDER_WITHIN = 10;
@@ -17039,10 +17040,10 @@ var latest = /* @__PURE__ */ __name((window3, matches) => {
17039
17040
  var sameThread = /* @__PURE__ */ __name((a, b) => a.threadId === b.threadId, "sameThread");
17040
17041
  var link = /* @__PURE__ */ __name((message, parentId, source, kind, confidence, method) => ({ messageId: message.id, parentId, source, kind, confidence, method }), "link");
17041
17042
 
17042
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/ports/traits.js
17043
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/ports/traits.js
17043
17044
  var syncsOneChat = /* @__PURE__ */ __name((messenger) => messenger.history !== "store" || messenger.historyOnDemand === true, "syncsOneChat");
17044
17045
 
17045
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/upload.js
17046
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/upload.js
17046
17047
  import { openAsBlob, realpathSync } from "node:fs";
17047
17048
  import { open, stat } from "node:fs/promises";
17048
17049
  import { basename, dirname, extname, isAbsolute, relative, resolve, sep } from "node:path";
@@ -17275,15 +17276,15 @@ var readStickerFile = /* @__PURE__ */ __name(async (path, maxBytes, read) => {
17275
17276
  return { name, source };
17276
17277
  }, "readStickerFile");
17277
17278
 
17278
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/send-id.js
17279
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/send-id.js
17279
17280
  import { randomBytes } from "node:crypto";
17280
17281
  var newSendId = /* @__PURE__ */ __name(() => randomBytes(8).readBigInt64BE().toString(), "newSendId");
17281
17282
  var newOperationId = newSendId;
17282
17283
 
17283
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/guard.js
17284
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/guard.js
17284
17285
  import { randomUUID } from "node:crypto";
17285
17286
 
17286
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/flood.js
17287
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/flood.js
17287
17288
  import { mkdirSync, readFileSync, renameSync, writeFileSync } from "node:fs";
17288
17289
  import { dirname as dirname2, join } from "node:path";
17289
17290
  var MOST_DEADLINES = 50;
@@ -17367,11 +17368,11 @@ var FloodMemory = class {
17367
17368
  }
17368
17369
  };
17369
17370
 
17370
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/journal.js
17371
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/journal.js
17371
17372
  import { appendFileSync, mkdirSync as mkdirSync3, readFileSync as readFileSync2 } from "node:fs";
17372
17373
  import { dirname as dirname4, join as join2 } from "node:path";
17373
17374
 
17374
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/file-lock.js
17375
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/file-lock.js
17375
17376
  import { closeSync, mkdirSync as mkdirSync2, openSync, statSync, unlinkSync } from "node:fs";
17376
17377
  import { dirname as dirname3 } from "node:path";
17377
17378
  var LOCK_WAIT_MS = 5e3;
@@ -17438,7 +17439,7 @@ var lockTime = /* @__PURE__ */ __name((lock) => {
17438
17439
  }
17439
17440
  }, "lockTime");
17440
17441
 
17441
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/journal.js
17442
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/journal.js
17442
17443
  var sendsPathFor = /* @__PURE__ */ __name((app, profile, env = process.env) => join2(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "sends", `${profile}.jsonl`), "sendsPathFor");
17443
17444
  var SendJournal = class {
17444
17445
  static {
@@ -17515,7 +17516,7 @@ var withSendId = /* @__PURE__ */ __name((entry) => {
17515
17516
  return cid === void 0 || rest.sendId !== void 0 ? rest : { ...rest, sendId: String(cid) };
17516
17517
  }, "withSendId");
17517
17518
 
17518
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/recipients.js
17519
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/recipients.js
17519
17520
  import { existsSync, readFileSync as readFileSync3, rmSync } from "node:fs";
17520
17521
  import { join as join3 } from "node:path";
17521
17522
  var recipientsPathFor = /* @__PURE__ */ __name((app, profile, env = process.env) => join3(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "profiles", `${profile}.recipients.json`), "recipientsPathFor");
@@ -17627,9 +17628,9 @@ var RecipientList = class {
17627
17628
  }
17628
17629
  };
17629
17630
 
17630
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/guard.js
17631
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/guard.js
17631
17632
  var HOUR_MS = 60 * 60 * 1e3;
17632
- var READS_UNDER_HOLD = /* @__PURE__ */ new Set([
17633
+ var READS = /* @__PURE__ */ new Set([
17633
17634
  "attachments.extract",
17634
17635
  "conversations.embeddings",
17635
17636
  "conversations.links",
@@ -17650,12 +17651,14 @@ var sendGuard = /* @__PURE__ */ __name(({ profile, recipients, command = recipie
17650
17651
  const currentPermissions = /* @__PURE__ */ __name(() => typeof permissions === "function" ? permissions() : permissions, "currentPermissions");
17651
17652
  let reservation;
17652
17653
  const answered = /* @__PURE__ */ new WeakSet();
17653
- const refuseReadOnly = /* @__PURE__ */ __name(() => {
17654
+ const refuseReadOnly = /* @__PURE__ */ __name(({ key }) => {
17655
+ if (key !== void 0 && READS.has(key))
17656
+ return;
17654
17657
  if (readOnlyLock)
17655
17658
  throw readOnlyRefusal(readOnlyLock, MESSENGER_CHANGE_REFUSAL);
17656
17659
  }, "refuseReadOnly");
17657
17660
  const refuseHeld = /* @__PURE__ */ __name(({ key }) => {
17658
- if (key !== void 0 && READS_UNDER_HOLD.has(key))
17661
+ if (key !== void 0 && READS.has(key))
17659
17662
  return;
17660
17663
  const block = flood?.sendBlock();
17661
17664
  if (!block)
@@ -17664,7 +17667,7 @@ var sendGuard = /* @__PURE__ */ __name(({ profile, recipients, command = recipie
17664
17667
  }, "refuseHeld");
17665
17668
  const permitted = /* @__PURE__ */ __name((request) => {
17666
17669
  const { chatId, kind = "message", action: action2, personIds: personIds2 } = request;
17667
- refuseReadOnly();
17670
+ refuseReadOnly(request);
17668
17671
  const levels = currentPermissions();
17669
17672
  if (levels !== void 0) {
17670
17673
  const key = request.key ?? keyForWrite(kind, action2);
@@ -17758,7 +17761,7 @@ var sendGuard = /* @__PURE__ */ __name(({ profile, recipients, command = recipie
17758
17761
  }, "counting");
17759
17762
  return {
17760
17763
  ask: /* @__PURE__ */ __name(async (request) => {
17761
- refuseReadOnly();
17764
+ refuseReadOnly(request);
17762
17765
  const levels = currentPermissions();
17763
17766
  if (levels === void 0)
17764
17767
  return;
@@ -17820,7 +17823,7 @@ var guardFor = /* @__PURE__ */ __name((app, settings, warn, env = process.env, a
17820
17823
  }), "guardFor");
17821
17824
  var journalFailure = /* @__PURE__ */ __name((error) => error?.code ?? (error instanceof Error ? error.name : "error"), "journalFailure");
17822
17825
 
17823
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/cli/messenger/lacks.js
17826
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/cli/messenger/lacks.js
17824
17827
  var COMMAND_NEEDS = {
17825
17828
  "account update": ["updateProfile", "change the profile"],
17826
17829
  "account sessions list": ["sessions", "list the account's sessions"],
@@ -17870,7 +17873,7 @@ var hideNever = /* @__PURE__ */ __name((messenger, group) => {
17870
17873
  return group;
17871
17874
  }, "hideNever");
17872
17875
 
17873
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/members-audit.js
17876
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/members-audit.js
17874
17877
  var AUDIT_PAGE = 200;
17875
17878
  var AUDIT_BUDGET = 10;
17876
17879
  var AUDIT_PAUSE_MS = 1e3;
@@ -17950,7 +17953,7 @@ var burstJoins = /* @__PURE__ */ __name((members) => {
17950
17953
  return found;
17951
17954
  }, "burstJoins");
17952
17955
 
17953
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/meetings/cli/query-options.js
17956
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/meetings/cli/query-options.js
17954
17957
  var queryWordsAfterOptions = /* @__PURE__ */ __name((command) => {
17955
17958
  command.allowUnknownOption();
17956
17959
  const parse2 = command.parseOptions.bind(command);
@@ -17970,7 +17973,7 @@ var queryWordsAfterOptions = /* @__PURE__ */ __name((command) => {
17970
17973
  return command;
17971
17974
  }, "queryWordsAfterOptions");
17972
17975
 
17973
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/meetings/cli/passage.js
17976
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/meetings/cli/passage.js
17974
17977
  var count = /* @__PURE__ */ __name((value) => {
17975
17978
  if (!/^(0|[1-9]\d*)$/.test(value) || !Number.isSafeInteger(Number(value)))
17976
17979
  throw new CliError("validation_error", "expected a nonnegative safe integer");
@@ -18012,7 +18015,7 @@ var addMeetingPassageCommandDefinition = /* @__PURE__ */ __name((program, deps)
18012
18015
  var createMeetingPassageCommand = sharedCommand(createMeetingPassageCommandDefinition);
18013
18016
  var addMeetingPassageCommand = sharedCommand(addMeetingPassageCommandDefinition);
18014
18017
 
18015
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/meetings/cli/project-evidence.js
18018
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/meetings/cli/project-evidence.js
18016
18019
  var integer2 = /* @__PURE__ */ __name((value) => {
18017
18020
  if (!/^[1-9]\d*$/.test(value) || !Number.isSafeInteger(Number(value)))
18018
18021
  throw new CliError("validation_error", "expected a positive safe integer");
@@ -18035,7 +18038,7 @@ ${fieldsHelp(MEETING_PROJECT_EVIDENCE_QUERY)}`).option("--limit <n>", "hits in o
18035
18038
  }, "addMeetingProjectEvidenceCommandDefinition");
18036
18039
  var addMeetingProjectEvidenceCommand = sharedCommand(addMeetingProjectEvidenceCommandDefinition);
18037
18040
 
18038
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/meetings/cli/search.js
18041
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/meetings/cli/search.js
18039
18042
  var ZONED = /(?:Z|[+-]\d{2}:?\d{2})$/i;
18040
18043
  var moment = /* @__PURE__ */ __name((flag, end, readIn) => (value) => {
18041
18044
  const zone = timezoneOf();
@@ -18121,7 +18124,7 @@ var addMeetingSearchCommandDefinition = /* @__PURE__ */ __name((program, deps) =
18121
18124
  var createMeetingSearchCommand = sharedCommand(createMeetingSearchCommandDefinition);
18122
18125
  var addMeetingSearchCommand = sharedCommand(addMeetingSearchCommandDefinition);
18123
18126
 
18124
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/meetings/cli/index.js
18127
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/meetings/cli/index.js
18125
18128
  var integer4 = /* @__PURE__ */ __name((text2) => {
18126
18129
  if (!/^[1-9]\d*$/.test(text2) || !Number.isSafeInteger(Number(text2)))
18127
18130
  throw new InvalidArgumentError("expected a positive integer");
@@ -18270,7 +18273,7 @@ ${fieldsHelp(EVENT_QUERY, MEETING_QUERY_GUIDE)}`);
18270
18273
  }, "addMeetingCommandsDefinition");
18271
18274
  var addMeetingCommands = sharedCommand(addMeetingCommandsDefinition);
18272
18275
 
18273
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/cli/list-query.js
18276
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/cli/list-query.js
18274
18277
  var LIST_QUERY_GUIDE = "https://github.com/WireCatLabs/cli-core/blob/main/docs/search/query-language.md";
18275
18278
  var QUERY_ARGUMENT = "field:value terms that narrow the list \u2014 the fields are below";
18276
18279
  var withQuery = /* @__PURE__ */ __name((command, registry) => {
@@ -18404,7 +18407,7 @@ var termField = /* @__PURE__ */ __name((name, type, example, more = {}) => nativ
18404
18407
  var queryHelp = /* @__PURE__ */ __name((registry) => `
18405
18408
  ${fieldsHelp(registry, LIST_QUERY_GUIDE)}`, "queryHelp");
18406
18409
 
18407
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/cli/paging.js
18410
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/cli/paging.js
18408
18411
  var positiveCount = /* @__PURE__ */ __name((flag) => (value) => {
18409
18412
  if (!/^\d+$/.test(value.trim()) || Number(value) < 1)
18410
18413
  throw new CliError("validation_error", `${flag} takes a whole number from 1 upwards, not "${value}"`);
@@ -18413,7 +18416,7 @@ var positiveCount = /* @__PURE__ */ __name((flag) => (value) => {
18413
18416
  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");
18414
18417
  var window = /* @__PURE__ */ __name(({ limit, page, all }) => all ? { offset: 0 } : { limit, offset: (page - 1) * limit }, "window");
18415
18418
 
18416
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/cli/messenger/chat-answers.js
18419
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/cli/messenger/chat-answers.js
18417
18420
  var defined = /* @__PURE__ */ __name((record2) => Object.fromEntries(Object.entries(record2).filter(([, value]) => value !== void 0)), "defined");
18418
18421
  var chatRef = /* @__PURE__ */ __name((account, chat) => formatReference({ type: "chat", provider: account.provider, account: account.account, chat }), "chatRef");
18419
18422
  var settingsOf = /* @__PURE__ */ __name((settings) => defined({
@@ -18675,7 +18678,7 @@ var sessionAnswer = /* @__PURE__ */ __name(({ current, client, device, location,
18675
18678
  ...createdAt === void 0 ? {} : { created_at: createdAt }
18676
18679
  }), "sessionAnswer");
18677
18680
 
18678
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/ports/messenger.js
18681
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/ports/messenger.js
18679
18682
  var throughWrapper = /* @__PURE__ */ __name((inner, handled, wrap = (_, call) => call) => new Proxy(handled, {
18680
18683
  get: /* @__PURE__ */ __name((own, key) => {
18681
18684
  if (key in own)
@@ -18692,7 +18695,7 @@ var capability = /* @__PURE__ */ __name((adapter, method, what) => {
18692
18695
  return found.bind(adapter);
18693
18696
  }, "capability");
18694
18697
 
18695
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/deps.js
18698
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/deps.js
18696
18699
  var accountStore = /* @__PURE__ */ __name(async (deps) => (await deps.store()).forAccount(await deps.account()), "accountStore");
18697
18700
  var crossAccount = /* @__PURE__ */ __name((deps, _reason) => deps.store(), "crossAccount");
18698
18701
  var NO_LOCAL_STORE = "this answer comes from the messenger, not from the local store";
@@ -18754,7 +18757,7 @@ var storedDeps = /* @__PURE__ */ __name((messenger, store, account, guard) => ({
18754
18757
  }), "storedDeps");
18755
18758
  var storeModeDeps = /* @__PURE__ */ __name((messenger, store, account, guard) => ({ ...storedDeps(messenger, store, account, guard), offline: false, reads: "store" }), "storeModeDeps");
18756
18759
 
18757
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/patience.js
18760
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/patience.js
18758
18761
  import { setTimeout as sleep } from "node:timers/promises";
18759
18762
  var LONGEST_WAIT_MS = 5 * 60 * 1e3;
18760
18763
  var patiently = /* @__PURE__ */ __name(async (request, note, stop) => {
@@ -18777,10 +18780,10 @@ var patiently = /* @__PURE__ */ __name(async (request, note, stop) => {
18777
18780
  }
18778
18781
  }, "patiently");
18779
18782
 
18780
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/archive.js
18783
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/archive.js
18781
18784
  import { setTimeout as sleep2 } from "node:timers/promises";
18782
18785
 
18783
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/backfill-estimate.js
18786
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/backfill-estimate.js
18784
18787
  var REQUEST_MS = 400;
18785
18788
  var estimateBackfill = /* @__PURE__ */ __name(({ ranges, held, newest, page, maxPages, pauseMs }) => {
18786
18789
  const lowest = ranges[0];
@@ -18803,13 +18806,13 @@ var estimateBackfill = /* @__PURE__ */ __name(({ ranges, held, newest, page, max
18803
18806
  };
18804
18807
  }, "estimateBackfill");
18805
18808
 
18806
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/recovery.js
18809
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/recovery.js
18807
18810
  var withRecovery = /* @__PURE__ */ __name((error) => ({
18808
18811
  ...error,
18809
18812
  retryable: typeof error.retryable === "boolean" ? error.retryable : error.code === "rate_limited" || error.status === 429
18810
18813
  }), "withRecovery");
18811
18814
 
18812
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/batch.js
18815
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/batch.js
18813
18816
  var actionable = /* @__PURE__ */ __name((error) => {
18814
18817
  if (isCliFailure(error))
18815
18818
  return withRecovery({ code: error.code, message: error.message, ...error.details });
@@ -18892,7 +18895,7 @@ var mergeBatches = /* @__PURE__ */ __name((a, b) => {
18892
18895
  };
18893
18896
  }, "mergeBatches");
18894
18897
 
18895
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/search/groups.js
18898
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/search/groups.js
18896
18899
  var ALL = "all";
18897
18900
  var OWNER_NOTES = { provider: "notes", account: INTERNAL_NOTES };
18898
18901
  var NOT_GROUP_NAMES = /* @__PURE__ */ new Set([ALL, "bots"]);
@@ -18964,7 +18967,7 @@ var groupEntries = /* @__PURE__ */ __name((saved) => ({
18964
18967
  [ALL]: [ALL]
18965
18968
  }), "groupEntries");
18966
18969
 
18967
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-kind.js
18970
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-kind.js
18968
18971
  var NO_MAIL = "no_mail";
18969
18972
  var MAIL = "email";
18970
18973
  var groupLockOf = /* @__PURE__ */ __name((app, env) => {
@@ -19038,7 +19041,7 @@ var accountsOfKind = /* @__PURE__ */ __name((kind, chosen, held, explicit, comma
19038
19041
  return chosenMail.map(({ provider, account }) => ({ provider, account }));
19039
19042
  }, "accountsOfKind");
19040
19043
 
19041
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/message-resolution.js
19044
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/message-resolution.js
19042
19045
  var readChatId = /* @__PURE__ */ __name(async (deps, reference, store, account) => {
19043
19046
  if (deps.reads !== "store")
19044
19047
  return keptChatId(deps.messenger, reference, store, account);
@@ -19237,7 +19240,7 @@ var chatsMatchingIn = /* @__PURE__ */ __name(async (store, accounts, pattern) =>
19237
19240
  }, "chatsMatchingIn");
19238
19241
  var isText = /* @__PURE__ */ __name((value) => typeof value === "string" && value !== "", "isText");
19239
19242
 
19240
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/images/context/index.js
19243
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/images/context/index.js
19241
19244
  var CONTEXT_MESSAGES = 3;
19242
19245
  var CONTEXT_MINUTES = 10;
19243
19246
  var MAX_CHARS = 1200;
@@ -19261,12 +19264,12 @@ var context = {
19261
19264
  }, "describe")
19262
19265
  };
19263
19266
 
19264
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/images/registry.js
19267
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/images/registry.js
19265
19268
  var BUILT_INS = [context];
19266
19269
  var providers = [...BUILT_INS];
19267
19270
  var registeredImageProviders = /* @__PURE__ */ __name(() => providers, "registeredImageProviders");
19268
19271
 
19269
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/conversations.js
19272
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/conversations.js
19270
19273
  var READ_PAGE = 5e3;
19271
19274
  var CHAIN = 50;
19272
19275
  var CONVERSATION_QUERY = {
@@ -19418,7 +19421,7 @@ var sized = /* @__PURE__ */ __name((size2) => {
19418
19421
  return size2;
19419
19422
  }, "sized");
19420
19423
 
19421
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/embeddings-maintenance.js
19424
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/embeddings-maintenance.js
19422
19425
  var REFRESH_BOUNDS = { maxChats: 20, maxChunks: 2e3 };
19423
19426
  var MESSAGE_PAGE = 5e3;
19424
19427
  var PER_SESSION = 8;
@@ -19437,7 +19440,7 @@ var embeddingTarget = /* @__PURE__ */ __name((deps, choice = chosenTextModel(dep
19437
19440
  price: remote.price,
19438
19441
  installed: true,
19439
19442
  perBatch: PER_REQUEST * concurrency,
19440
- open: /* @__PURE__ */ __name(async () => (await import("./remote-7RSAJ3JC.js")).openRemote(remote, apiKey, {
19443
+ open: /* @__PURE__ */ __name(async () => (await import("./remote-WG5V2I2G.js")).openRemote(remote, apiKey, {
19441
19444
  concurrency,
19442
19445
  env: deps.env ?? process.env
19443
19446
  }), "open")
@@ -19457,7 +19460,7 @@ var embeddingTarget = /* @__PURE__ */ __name((deps, choice = chosenTextModel(dep
19457
19460
  if (!isTextModelInstalled(model, directory2))
19458
19461
  throw notDownloaded(model.id);
19459
19462
  if (apart) {
19460
- const { openProcess } = await import("./process-YJ4LHMJB.js");
19463
+ const { openProcess } = await import("./process-VZKFAGNP.js");
19461
19464
  return openProcess(model, directory2, { threads: threads ?? defaultThreads() });
19462
19465
  }
19463
19466
  return openEmbedder(model, directory2, { threads: threads ?? defaultThreads() });
@@ -19746,7 +19749,7 @@ var shaped = /* @__PURE__ */ __name(({ chatId, builtAt, algorithmVersion, pendin
19746
19749
  return { ...one, state };
19747
19750
  }, "shaped");
19748
19751
 
19749
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-catchup.js
19752
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-catchup.js
19750
19753
  var CATCH_UP_BOUNDS = { maxChunks: 500, maxMessages: 1e4, timeMs: 3e4 };
19751
19754
  var validateCatchUpBounds = /* @__PURE__ */ __name((options2) => {
19752
19755
  for (const [key, value, maximum] of [
@@ -19799,7 +19802,7 @@ var catchUpSearch = /* @__PURE__ */ __name(async (deps, chat, options2, signal,
19799
19802
  }
19800
19803
  }, "catchUpSearch");
19801
19804
 
19802
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/archive.js
19805
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/archive.js
19803
19806
  var pushed = /* @__PURE__ */ __name((deps, what) => {
19804
19807
  if (deps.reads === "store") {
19805
19808
  throw new CliError("validation_error", `${what} asks for older history, and this messenger pushes its history instead \u2014 keep \`${typedCommand(deps.messenger.app.command, "serve")}\` running`);
@@ -20180,7 +20183,7 @@ var timeOfKey = /* @__PURE__ */ __name(async (store, account, chatId, key, byTim
20180
20183
  return message?.timestamp ?? fallback;
20181
20184
  }, "timeOfKey");
20182
20185
 
20183
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/questions.js
20186
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/questions.js
20184
20187
  var LINKS = /https?:\/\/\S+/g;
20185
20188
  var unanswered = /* @__PURE__ */ __name((messages, { answerers: answerers2, before: before2 }) => questions(messages, { answerers: answerers2 }).filter(({ question, answer }) => answer === void 0 && Date.parse(question.timestamp) < before2).map(({ question }) => question), "unanswered");
20186
20189
  var questions = /* @__PURE__ */ __name((messages, { answerers: answerers2, asker = "others" }) => {
@@ -20210,7 +20213,7 @@ var questions = /* @__PURE__ */ __name((messages, { answerers: answerers2, asker
20210
20213
  });
20211
20214
  }, "questions");
20212
20215
 
20213
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/task-categories.js
20216
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/task-categories.js
20214
20217
  var names = /* @__PURE__ */ __name((categories) => categories.map(({ name }) => name).join(", "), "names");
20215
20218
  var taskCategoryOf = /* @__PURE__ */ __name((categories = DEFAULT_TASK_CATEGORIES, flag = "--category") => (typed) => {
20216
20219
  const name = typed.trim().toLowerCase();
@@ -20267,7 +20270,7 @@ var categorize = /* @__PURE__ */ __name((text2, categories = DEFAULT_TASK_CATEGO
20267
20270
  return best.name;
20268
20271
  }, "categorize");
20269
20272
 
20270
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/task-rules.js
20273
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/task-rules.js
20271
20274
  var taskAccount = /* @__PURE__ */ __name(({ provider, account }) => `${provider}:${account}`, "taskAccount");
20272
20275
  var RULES_IN = {
20273
20276
  dialog: "all",
@@ -20473,11 +20476,11 @@ var applyTaskRulesToChats = /* @__PURE__ */ __name(async (store, account, chatId
20473
20476
  return passes;
20474
20477
  }, "applyTaskRulesToChats");
20475
20478
 
20476
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/vcard.js
20479
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/vcard.js
20477
20480
  var AS_WORD = new RegExp(`^${WORD_BODY}$`);
20478
20481
  var encoder = new TextEncoder();
20479
20482
 
20480
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/moment.js
20483
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/moment.js
20481
20484
  var AGO = /^(\d+)(m|h|d)$/;
20482
20485
  var AGO_MS = { m: 6e4, h: 36e5, d: 864e5 };
20483
20486
  var DATE = /^\d{4}-\d{2}-\d{2}/;
@@ -20517,7 +20520,7 @@ var dateWindow = /* @__PURE__ */ __name(({ sinceTime, untilTime, zone, now = Dat
20517
20520
  };
20518
20521
  }, "dateWindow");
20519
20522
 
20520
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/botcheck/check.js
20523
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/botcheck/check.js
20521
20524
  var DAY_MS = 864e5;
20522
20525
  var NEW_DAYS = 30;
20523
20526
  var SAME_TEXT_MIN = 20;
@@ -20594,7 +20597,7 @@ var scorePerson = /* @__PURE__ */ __name(({ subject, provider, activity, photos,
20594
20597
  };
20595
20598
  }, "scorePerson");
20596
20599
 
20597
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/http/time-limit.js
20600
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/http/time-limit.js
20598
20601
  var timeLimit = /* @__PURE__ */ __name((ms) => {
20599
20602
  const controller = new AbortController();
20600
20603
  const timer = setTimeout(() => controller.abort(new DOMException("The operation timed out.", "TimeoutError")), ms);
@@ -20610,7 +20613,7 @@ var withTimeLimit = /* @__PURE__ */ __name(async (ms, run2) => {
20610
20613
  }
20611
20614
  }, "withTimeLimit");
20612
20615
 
20613
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/botcheck/registries.js
20616
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/botcheck/registries.js
20614
20617
  var REGISTRIES = {
20615
20618
  cas: { title: "Combot Anti-Spam (CAS)", docs: "https://cas.chat/api" },
20616
20619
  lols: { title: "lols.bot", docs: "https://api.lols.bot/lols-bot.json" }
@@ -20697,7 +20700,7 @@ var notCovered = /* @__PURE__ */ __name((messenger, now = /* @__PURE__ */ new Da
20697
20700
  detail: `lists Telegram accounts only, not ${messenger} ones`
20698
20701
  })), "notCovered");
20699
20702
 
20700
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/botcheck/service.js
20703
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/botcheck/service.js
20701
20704
  var ACTIVITY_MESSAGES = 1e3;
20702
20705
  var botCheckService = /* @__PURE__ */ __name((deps) => {
20703
20706
  const subjectOf = /* @__PURE__ */ __name(async (reference) => {
@@ -20785,7 +20788,7 @@ var botCheckService = /* @__PURE__ */ __name((deps) => {
20785
20788
  };
20786
20789
  }, "botCheckService");
20787
20790
 
20788
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/thread.js
20791
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/thread.js
20789
20792
  var threadIdOf = /* @__PURE__ */ __name((value) => {
20790
20793
  if (value === void 0)
20791
20794
  return void 0;
@@ -20795,7 +20798,7 @@ var threadIdOf = /* @__PURE__ */ __name((value) => {
20795
20798
  return id2;
20796
20799
  }, "threadIdOf");
20797
20800
 
20798
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/chat-stats.js
20801
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/chat-stats.js
20799
20802
  var TOP_POSTS = 5;
20800
20803
  var JOINS = /* @__PURE__ */ new Set(["join", "add"]);
20801
20804
  var LEAVES = /* @__PURE__ */ new Set(["leave", "remove"]);
@@ -20912,7 +20915,7 @@ var median = /* @__PURE__ */ __name((values) => {
20912
20915
  return Math.round(sorted.length % 2 === 0 ? ((sorted[middle - 1] ?? upper) + upper) / 2 : upper);
20913
20916
  }, "median");
20914
20917
 
20915
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/member-history.js
20918
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/member-history.js
20916
20919
  var memberEvents = /* @__PURE__ */ __name((stays, revisions, since = 0) => {
20917
20920
  const events = [];
20918
20921
  for (const stay of stays) {
@@ -20944,7 +20947,7 @@ var memberEvents = /* @__PURE__ */ __name((stays, revisions, since = 0) => {
20944
20947
  return events.filter(({ at }) => Date.parse(at) >= since).sort((a, b) => Date.parse(a.at) - Date.parse(b.at) || a.id.localeCompare(b.id));
20945
20948
  }, "memberEvents");
20946
20949
 
20947
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/chats.js
20950
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/chats.js
20948
20951
  var EVENTS_DAYS = 7;
20949
20952
  var TRACKED_DAYS = 30;
20950
20953
  var STATS_PAGE = 1e3;
@@ -21239,7 +21242,7 @@ var storedMembers = /* @__PURE__ */ __name(async (store, chatId) => {
21239
21242
  return members.length === 0 ? null : members;
21240
21243
  }, "storedMembers");
21241
21244
 
21242
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/inbox.js
21245
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/inbox.js
21243
21246
  var INBOX_CHATS = 20;
21244
21247
  var REVIEW_DAYS = 3;
21245
21248
  var UNANSWERED_HOURS = 24;
@@ -21447,7 +21450,7 @@ var inboxService = /* @__PURE__ */ __name((deps) => {
21447
21450
  };
21448
21451
  }, "inboxService");
21449
21452
 
21450
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/formatting.js
21453
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/formatting.js
21451
21454
  var invalid = /* @__PURE__ */ __name(() => new CliError("validation_error", "the messenger formatter returned invalid text spans"), "invalid");
21452
21455
  var validateFormattedText = /* @__PURE__ */ __name((formatted2) => {
21453
21456
  const { text: text2, spans } = formatted2;
@@ -21507,7 +21510,7 @@ var visibleFormattedText = /* @__PURE__ */ __name((formatted2) => {
21507
21510
  };
21508
21511
  }, "visibleFormattedText");
21509
21512
 
21510
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/moderation/check.js
21513
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/moderation/check.js
21511
21514
  var INVITE = /max\.ru\/join\/|(t|telegram)\.me\/(\+|joinchat\/)|tg:\/\/join/i;
21512
21515
  var LINK2 = /https?:\/\/\S+/i;
21513
21516
  var STRENGTH = { report: 0, delete: 1, remove: 2 };
@@ -21695,7 +21698,7 @@ var nextPoint = /* @__PURE__ */ __name((rows, found) => {
21695
21698
  }, "nextPoint");
21696
21699
  var someUndone = /* @__PURE__ */ __name((rows) => rows.some(undone), "someUndone");
21697
21700
 
21698
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/moderation/rules.js
21701
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/moderation/rules.js
21699
21702
  import { existsSync as existsSync2, readFileSync as readFileSync4 } from "node:fs";
21700
21703
  import { join as join4 } from "node:path";
21701
21704
  var RULE_ACTIONS = ["report", "delete", "remove"];
@@ -21838,7 +21841,59 @@ var assign = /* @__PURE__ */ __name((rules, key, value) => {
21838
21841
  return { ...rules, [head]: { ...rules[head], [tail]: value } };
21839
21842
  }, "assign");
21840
21843
 
21841
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/person-context.js
21844
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-meetings.js
21845
+ var SCAN = 1e3;
21846
+ var personMeetings = /* @__PURE__ */ __name(async (store, people, accounts, { limit = 10, since, until } = {}) => {
21847
+ const byId2 = new Map(accounts.map((one) => [one.id, one]));
21848
+ let cut = false;
21849
+ const found = /* @__PURE__ */ new Map();
21850
+ for (const uid of people) {
21851
+ const rows = store.involvements.forPerson(Number(uid), {
21852
+ limit: SCAN,
21853
+ subjectTypes: ["meeting"],
21854
+ ...since === void 0 ? {} : { since },
21855
+ ...until === void 0 ? {} : { until }
21856
+ });
21857
+ cut ||= rows.length === SCAN;
21858
+ for (const row of rows) {
21859
+ if (row.subjectType !== "meeting" || row.accountId === null || !byId2.has(row.accountId))
21860
+ continue;
21861
+ const key = `${row.accountId}/${row.subjectId}`;
21862
+ const held = found.get(key) ?? {
21863
+ accountId: row.accountId,
21864
+ meetingId: row.subjectId,
21865
+ at: row.occurredAt,
21866
+ people: []
21867
+ };
21868
+ if (!held.people.includes(`person:${uid}`))
21869
+ held.people.push(`person:${uid}`);
21870
+ found.set(key, held);
21871
+ }
21872
+ }
21873
+ const newest = [...found.values()].sort((a, b) => b.at - a.at || b.meetingId - a.meetingId);
21874
+ const items = [];
21875
+ for (const { accountId, meetingId, people: who2 } of newest.slice(0, limit)) {
21876
+ const meeting = await store.meetings.meetingMetadata({ accountId, meetingId }).catch(() => void 0);
21877
+ if (meeting === void 0 || meeting.deletedAt !== null)
21878
+ continue;
21879
+ const transcripts = await store.meetings.transcripts({ accountId, meetingId, limit: 1 });
21880
+ const account = byId2.get(accountId);
21881
+ items.push({
21882
+ ref: formatMeetingReference({ type: "meeting", accountId, meetingId }),
21883
+ meetingId,
21884
+ account: { provider: account.provider, account: account.account },
21885
+ title: meeting.title,
21886
+ startedAt: meeting.startedAt === null ? null : new Date(meeting.startedAt).toISOString(),
21887
+ durationMs: meeting.durationMs,
21888
+ hasTranscript: transcripts.items.length > 0,
21889
+ event: meeting.eventId === null ? null : `event:${meeting.eventId}`,
21890
+ people: who2
21891
+ });
21892
+ }
21893
+ return { items, total: newest.length, hasMore: cut || newest.length > limit };
21894
+ }, "personMeetings");
21895
+
21896
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-context.js
21842
21897
  var CONTEXT_MESSAGES2 = 10;
21843
21898
  var CONTEXT_BYTES = 64 * 1024;
21844
21899
  var toContext = /* @__PURE__ */ __name((key, message, chatTitle2) => ({
@@ -22019,6 +22074,11 @@ var recordContext = /* @__PURE__ */ __name(async (store, record2, reads, readabl
22019
22074
  const upcomingIds = new Set(upcoming.items.map(({ id: id2 }) => id2));
22020
22075
  const past = accountIds.length ? await eventsOnce(store, { personId, accountIds, to: now, newest: true, ...since === void 0 ? {} : { from: since } }, messages) : nothing;
22021
22076
  cut ||= upcoming.cut || past.cut;
22077
+ const recorded = await personMeetings(store, [record2.uid], readable, {
22078
+ limit: messages,
22079
+ ...since === void 0 ? {} : { since }
22080
+ });
22081
+ cut ||= recorded.hasMore;
22022
22082
  direct.sort(newestFirst);
22023
22083
  const each = [...direct, ...beyond].sort(newestFirst);
22024
22084
  theirs.sort(newestFirst);
@@ -22035,8 +22095,9 @@ var recordContext = /* @__PURE__ */ __name(async (store, record2, reads, readabl
22035
22095
  const kept2 = withinBytes(lists, bytes2);
22036
22096
  const read = [
22037
22097
  ...reads.map(({ key, scope }) => ({ ...key, scope })),
22038
- ...calendars.map(({ provider, account, scope }) => ({ provider, account, scope }))
22039
- ];
22098
+ ...calendars.map(({ provider, account, scope }) => ({ provider, account, scope })),
22099
+ ...recorded.items.flatMap(({ account }) => readable.filter((one) => nameOf(one) === nameOf(account)))
22100
+ ].map(({ provider, account, scope }) => ({ provider, account, scope }));
22040
22101
  const accounts = [...new Map(read.map((one) => [nameOf(one), one])).values()].sort((a, b) => nameOf(a).localeCompare(nameOf(b)));
22041
22102
  return {
22042
22103
  accounts,
@@ -22052,6 +22113,7 @@ var recordContext = /* @__PURE__ */ __name(async (store, record2, reads, readabl
22052
22113
  upcoming: upcoming.items.map(contextEvent),
22053
22114
  recent: past.items.filter(({ id: id2 }) => !upcomingIds.has(id2)).map(contextEvent)
22054
22115
  },
22116
+ meetings: recorded.items,
22055
22117
  limits: { messages, bytes: bytes2 },
22056
22118
  hasMore: cut || kept2.cut,
22057
22119
  complete: notRead.length === 0,
@@ -22137,10 +22199,10 @@ var personMessages = /* @__PURE__ */ __name(async (store, asked, reference, { ch
22137
22199
  };
22138
22200
  }, "personMessages");
22139
22201
 
22140
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
22202
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
22141
22203
  import { createHash } from "node:crypto";
22142
22204
 
22143
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-reference.js
22205
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-reference.js
22144
22206
  var missing2 = /* @__PURE__ */ __name(() => new CliError("not_found", "the meeting evidence is unavailable for this account"), "missing");
22145
22207
  var authorizedMeetingMetadata = /* @__PURE__ */ __name(async (store, accountId, reference, options2 = {}) => {
22146
22208
  const parsed = parseMeetingReference(reference);
@@ -22158,7 +22220,7 @@ var authorizedMeetingMetadata = /* @__PURE__ */ __name(async (store, accountId,
22158
22220
  return { parsed, meeting };
22159
22221
  }, "authorizedMeetingMetadata");
22160
22222
 
22161
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
22223
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
22162
22224
  var hash = /* @__PURE__ */ __name((value) => createHash("sha256").update(JSON.stringify(value)).digest("hex"), "hash");
22163
22225
  var checkMeetingCancelled = /* @__PURE__ */ __name((signal) => {
22164
22226
  if (signal?.aborted)
@@ -22357,7 +22419,7 @@ var readMeetingEvidence = /* @__PURE__ */ __name(async (store, accountId, refere
22357
22419
  return { ...packet, fingerprint: hash(packet) };
22358
22420
  }, "readMeetingEvidence");
22359
22421
 
22360
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/person-meeting-context.js
22422
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-meeting-context.js
22361
22423
  var personMeetingContext = /* @__PURE__ */ __name(async (store, personReference, options2) => {
22362
22424
  const { meetings = 10, cues = 5, bytes: bytes2 = 64 * 1024, scanLimit = 1e3, since, signal } = options2;
22363
22425
  const requestedAccounts = options2.accountIds;
@@ -22456,7 +22518,7 @@ var personMeetingContext = /* @__PURE__ */ __name(async (store, personReference,
22456
22518
  };
22457
22519
  }, "personMeetingContext");
22458
22520
 
22459
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/person-preparation.js
22521
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-preparation.js
22460
22522
  var PREPARE_BYTES = 96 * 1024;
22461
22523
  var MEETINGS = 5;
22462
22524
  var CUES = 3;
@@ -22579,7 +22641,7 @@ var meetingsOf = /* @__PURE__ */ __name(async (store, uid, stored, since, left)
22579
22641
  }
22580
22642
  }, "meetingsOf");
22581
22643
 
22582
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/person-profile.js
22644
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-profile.js
22583
22645
  var personProfile = /* @__PURE__ */ __name(async (deps, person, known2) => {
22584
22646
  const online = deps.offline ? void 0 : await deps.connection();
22585
22647
  const held = await storeIfOpen(deps);
@@ -22649,7 +22711,7 @@ var quiet = /* @__PURE__ */ __name((facts) => facts.chats.map(({ id: id2, title,
22649
22711
  complete: false
22650
22712
  })), "quiet");
22651
22713
 
22652
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/person-timeline.js
22714
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/person-timeline.js
22653
22715
  var TIMELINE_ITEMS = 50;
22654
22716
  var TIMELINE_MAX = 500;
22655
22717
  var SCOPES = ["personal", "work"];
@@ -22711,7 +22773,7 @@ var personTimeline = /* @__PURE__ */ __name(async (store, asked, reference, { sc
22711
22773
  };
22712
22774
  }, "personTimeline");
22713
22775
 
22714
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/chat-coverage.js
22776
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/chat-coverage.js
22715
22777
  var chatCoverage = /* @__PURE__ */ __name(async (store, account, chatIds) => {
22716
22778
  const ids = [...new Set(chatIds)];
22717
22779
  if (ids.length === 0)
@@ -22737,7 +22799,7 @@ var chatCoverage = /* @__PURE__ */ __name(async (store, account, chatIds) => {
22737
22799
  }));
22738
22800
  }, "chatCoverage");
22739
22801
 
22740
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/context/evidence-response.js
22802
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/context/evidence-response.js
22741
22803
  var contextSourceKey = /* @__PURE__ */ __name((source) => JSON.stringify([source.kind, source.accountId, source.provider, source.account]), "contextSourceKey");
22742
22804
  var validateContextEvidencePage = /* @__PURE__ */ __name((page, request) => {
22743
22805
  const fail2 = /* @__PURE__ */ __name(() => {
@@ -22801,7 +22863,7 @@ var validateContextEvidencePage = /* @__PURE__ */ __name((page, request) => {
22801
22863
  }
22802
22864
  }, "validateContextEvidencePage");
22803
22865
 
22804
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/context/read-budget.js
22866
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/context/read-budget.js
22805
22867
  var contextReadBudget = /* @__PURE__ */ __name((limits = {}) => {
22806
22868
  if (!limits || typeof limits !== "object" || Array.isArray(limits))
22807
22869
  throw new CliError("validation_error", "limits needs a context read allowance");
@@ -22854,7 +22916,7 @@ var contextReadBudget = /* @__PURE__ */ __name((limits = {}) => {
22854
22916
  };
22855
22917
  }, "contextReadBudget");
22856
22918
 
22857
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/context-evidence.js
22919
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/context-evidence.js
22858
22920
  var createContextEvidenceReader = /* @__PURE__ */ __name((port, allowed, limits) => {
22859
22921
  if (!port || typeof port.read !== "function")
22860
22922
  throw new CliError("configuration_error", "context evidence reader is unavailable");
@@ -22898,7 +22960,7 @@ var createContextEvidenceReader = /* @__PURE__ */ __name((port, allowed, limits)
22898
22960
  };
22899
22961
  }, "createContextEvidenceReader");
22900
22962
 
22901
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/excerpt.js
22963
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/excerpt.js
22902
22964
  var queryWords = /* @__PURE__ */ __name((query) => query.toLowerCase().split(/\s+/).map((word) => word.replace(/^[\p{L}_]+:/u, "").replace(/~\d+$/u, "").replace(/^[^\p{L}\p{N}]+|[^\p{L}\p{N}]+$/gu, "")).filter((word) => word.length > 2 && !["and", "or", "not"].includes(word)), "queryWords");
22903
22965
  var excerpt = /* @__PURE__ */ __name((text2, query, size2 = 240, options2 = {}) => {
22904
22966
  const flat = text2.replace(/\s+/g, " ").trim();
@@ -22914,7 +22976,7 @@ var excerpt = /* @__PURE__ */ __name((text2, query, size2 = 240, options2 = {})
22914
22976
  }, "excerpt");
22915
22977
  var withExcerpt = /* @__PURE__ */ __name(({ matchedText, ...hit }, query) => ({ ...hit, excerpt: excerpt(matchedText ?? hit.text, query) }), "withExcerpt");
22916
22978
 
22917
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-gathering-around.js
22979
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-gathering-around.js
22918
22980
  var storedMessageNeighbours = /* @__PURE__ */ __name((messages) => ({
22919
22981
  async around(ref, window3) {
22920
22982
  const at = parseLocator(ref);
@@ -23009,7 +23071,7 @@ var storedNeighbours = /* @__PURE__ */ __name((store) => {
23009
23071
  };
23010
23072
  }, "storedNeighbours");
23011
23073
 
23012
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-gathering-request.js
23074
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-gathering-request.js
23013
23075
  import { createHash as createHash2 } from "node:crypto";
23014
23076
  var DAY = 864e5;
23015
23077
  var MAX_TIME = 864e13;
@@ -23325,7 +23387,7 @@ var decodeCheckpoint = /* @__PURE__ */ __name((text2, plan) => {
23325
23387
  return value;
23326
23388
  }, "decodeCheckpoint");
23327
23389
 
23328
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-gathering.js
23390
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-gathering.js
23329
23391
  var terminal = /* @__PURE__ */ new Set(["done", "unavailable", "failed"]);
23330
23392
  var PAGE3 = 20;
23331
23393
  var PEOPLE = 20;
@@ -23729,7 +23791,7 @@ var peopleOf = /* @__PURE__ */ __name((items, senderOf) => {
23729
23791
  return [...byKey.values()].sort((a, b) => b.items - a.items || a.name.localeCompare(b.name));
23730
23792
  }, "peopleOf");
23731
23793
 
23732
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-matching.js
23794
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-matching.js
23733
23795
  var normalizedText = /* @__PURE__ */ __name((text2) => text2.normalize("NFKC").toLowerCase().replace(/\s+/gu, " "), "normalizedText");
23734
23796
  var termsOf = /* @__PURE__ */ __name((entry) => [
23735
23797
  { name: entry.name, kind: "canonical" },
@@ -23773,7 +23835,7 @@ var matchVocabularyTerms = /* @__PURE__ */ __name((catalog, texts) => {
23773
23835
  return result.sort((a, b) => Number(a.entry.id) - Number(b.entry.id));
23774
23836
  }, "matchVocabularyTerms");
23775
23837
 
23776
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-gathering-mentions.js
23838
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-gathering-mentions.js
23777
23839
  var KINDS = ["project", "tag", "topic"];
23778
23840
  var findEvidenceMentions = /* @__PURE__ */ __name(async (vocabulary, gathering, options2 = {}) => {
23779
23841
  if (typeof vocabulary?.vocabulary !== "function")
@@ -23828,7 +23890,7 @@ var findEvidenceMentions = /* @__PURE__ */ __name(async (vocabulary, gathering,
23828
23890
  };
23829
23891
  }, "findEvidenceMentions");
23830
23892
 
23831
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-purposes.js
23893
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-purposes.js
23832
23894
  var BUILT_IN_PURPOSES = ["work", "sales", "support", "other"];
23833
23895
  var DEFAULT_PURPOSES = ["work"];
23834
23896
  var LINK_PURPOSE = "work";
@@ -23858,7 +23920,7 @@ var purposeList = /* @__PURE__ */ __name((value, previous = []) => [
23858
23920
  ...value.split(",").map((one) => one.trim()).filter(Boolean)
23859
23921
  ], "purposeList");
23860
23922
 
23861
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/stored-project-gathering.js
23923
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/stored-project-gathering.js
23862
23924
  var storedChatCount = /* @__PURE__ */ __name((store) => async (account, chatId, { since, until }) => {
23863
23925
  const window3 = { since: new Date(since).toISOString(), until: new Date(until - 1).toISOString() };
23864
23926
  const [messages, newest, oldest] = await Promise.all([
@@ -24169,7 +24231,7 @@ var purposeHintOf = /* @__PURE__ */ __name((linked, rows, of) => {
24169
24231
  return { chat: top.ref, relationship: link4.relationship, items, of };
24170
24232
  }, "purposeHintOf");
24171
24233
 
24172
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/people.js
24234
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/people.js
24173
24235
  var peopleService = /* @__PURE__ */ __name((deps) => {
24174
24236
  const localCard = /* @__PURE__ */ __name(async (card, includeNotes = false) => {
24175
24237
  const held = await storeIfOpen(deps);
@@ -24434,7 +24496,7 @@ var withoutPhone = /* @__PURE__ */ __name((answer) => {
24434
24496
  return rest;
24435
24497
  }, "withoutPhone");
24436
24498
 
24437
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/task-stats.js
24499
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/task-stats.js
24438
24500
  var TASK_STATS_BY = ["chat", "meeting", "project"];
24439
24501
  var PERIOD_FIELD = "created";
24440
24502
  var refuseNestedPeriod = /* @__PURE__ */ __name((node, top = true) => {
@@ -24565,7 +24627,7 @@ var meetingNames = /* @__PURE__ */ __name(async (store, groups) => {
24565
24627
  }));
24566
24628
  }, "meetingNames");
24567
24629
 
24568
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/task-tag-filters.js
24630
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/task-tag-filters.js
24569
24631
  var taskTagFilters = /* @__PURE__ */ __name(async (store, query) => {
24570
24632
  const tags = /* @__PURE__ */ new Map();
24571
24633
  for (const node of query ? walkQuery(query.root) : [])
@@ -24574,7 +24636,7 @@ var taskTagFilters = /* @__PURE__ */ __name(async (store, query) => {
24574
24636
  return tags;
24575
24637
  }, "taskTagFilters");
24576
24638
 
24577
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/tasks.js
24639
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/tasks.js
24578
24640
  var TASK_QUERY = {
24579
24641
  entity: "task",
24580
24642
  backend: "sql",
@@ -25074,7 +25136,7 @@ var taskView = /* @__PURE__ */ __name(async (store, account, task2) => {
25074
25136
  };
25075
25137
  }, "taskView");
25076
25138
 
25077
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/mail/owed.js
25139
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/mail/owed.js
25078
25140
  var mailTurn = /* @__PURE__ */ __name((newest) => {
25079
25141
  if (newest === null)
25080
25142
  return null;
@@ -25083,7 +25145,7 @@ var mailTurn = /* @__PURE__ */ __name((newest) => {
25083
25145
  return newest.addressed ? "owed" : null;
25084
25146
  }, "mailTurn");
25085
25147
 
25086
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/agenda-mail.js
25148
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/agenda-mail.js
25087
25149
  var absent = /* @__PURE__ */ __name((error) => {
25088
25150
  if (error instanceof CliError && error.code === "not_found")
25089
25151
  return void 0;
@@ -25141,7 +25203,7 @@ var mailActivity = /* @__PURE__ */ __name(async (store, account, since, chats) =
25141
25203
  };
25142
25204
  }, "mailActivity");
25143
25205
 
25144
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/agenda.js
25206
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/agenda.js
25145
25207
  var DAY2 = 864e5;
25146
25208
  var AGENDA_DEFAULTS = { unanswered: DAY2, waiting: 7 * DAY2 };
25147
25209
  var CLAIMS = ["none", "mine", "others", "any"];
@@ -25395,18 +25457,18 @@ var agendaItem = /* @__PURE__ */ __name((shown) => {
25395
25457
  };
25396
25458
  }, "agendaItem");
25397
25459
 
25398
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive.js
25460
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive.js
25399
25461
  import { setTimeout as sleep3 } from "node:timers/promises";
25400
25462
 
25401
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
25463
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
25402
25464
  import { lstat } from "node:fs/promises";
25403
25465
 
25404
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
25466
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
25405
25467
  import { createHash as createHash4, randomUUID as randomUUID3 } from "node:crypto";
25406
25468
  import { open as open3, rename as rename2, unlink as unlink2 } from "node:fs/promises";
25407
25469
  import { join as join6 } from "node:path";
25408
25470
 
25409
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-metadata.js
25471
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-metadata.js
25410
25472
  import { createHash as createHash3 } from "node:crypto";
25411
25473
  var metadataLimit = 16384;
25412
25474
  var partialIdentity = /* @__PURE__ */ __name((locator) => JSON.stringify([locator.provider, locator.account, locator.occurrenceId, locator.assetId]), "partialIdentity");
@@ -25466,7 +25528,7 @@ var readPartialMetadata = /* @__PURE__ */ __name(async (path, locator, maxBytes,
25466
25528
  }
25467
25529
  }, "readPartialMetadata");
25468
25530
 
25469
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-writer.js
25531
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-writer.js
25470
25532
  import { randomUUID as randomUUID2 } from "node:crypto";
25471
25533
  import { open as open2, rename, unlink } from "node:fs/promises";
25472
25534
  import { join as join5 } from "node:path";
@@ -25558,7 +25620,7 @@ var partialWriter = /* @__PURE__ */ __name(async (input) => {
25558
25620
  };
25559
25621
  }, "partialWriter");
25560
25622
 
25561
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
25623
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
25562
25624
  var NativeRecordingPartialStore = class {
25563
25625
  static {
25564
25626
  __name(this, "NativeRecordingPartialStore");
@@ -25665,12 +25727,12 @@ var NativeRecordingPartialStore = class {
25665
25727
  }
25666
25728
  };
25667
25729
 
25668
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
25730
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
25669
25731
  import { createHash as createHash5 } from "node:crypto";
25670
25732
  import { link as link2 } from "node:fs/promises";
25671
25733
  import { basename as basename2, dirname as dirname5, join as join8, resolve as resolve2 } from "node:path";
25672
25734
 
25673
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-files.js
25735
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-files.js
25674
25736
  import { unlink as unlink3 } from "node:fs/promises";
25675
25737
  var verifiedPublicationFile = /* @__PURE__ */ __name(async (path, expected2, signal, writable = false) => {
25676
25738
  signal?.throwIfAborted();
@@ -25705,7 +25767,7 @@ var commitPublication = /* @__PURE__ */ __name(async (root, partialPath, finalPa
25705
25767
  signal?.throwIfAborted();
25706
25768
  }, "commitPublication");
25707
25769
 
25708
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-journal.js
25770
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-journal.js
25709
25771
  import { randomUUID as randomUUID4 } from "node:crypto";
25710
25772
  import { open as open4, rename as rename3, unlink as unlink4 } from "node:fs/promises";
25711
25773
  import { join as join7 } from "node:path";
@@ -25778,7 +25840,7 @@ var writePublicationJournal = /* @__PURE__ */ __name(async (root, path, prefix,
25778
25840
  }
25779
25841
  }, "writePublicationJournal");
25780
25842
 
25781
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
25843
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
25782
25844
  var NativeRecordingPublication = class {
25783
25845
  static {
25784
25846
  __name(this, "NativeRecordingPublication");
@@ -25851,7 +25913,7 @@ var NativeRecordingPublication = class {
25851
25913
  }
25852
25914
  };
25853
25915
 
25854
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive-manifest.js
25916
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive-manifest.js
25855
25917
  import { createHash as createHash6 } from "node:crypto";
25856
25918
  import { readdir } from "node:fs/promises";
25857
25919
  import { isAbsolute as isAbsolute2, join as join9, resolve as resolve3 } from "node:path";
@@ -25938,7 +26000,7 @@ var commitMediaEntry = /* @__PURE__ */ __name((root, one, beforePublish) => writ
25938
26000
  beforePublish
25939
26001
  }), "commitMediaEntry");
25940
26002
 
25941
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
26003
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
25942
26004
  var validator = '"media-completed-v1"';
25943
26005
  var maximumFileBytes = 64 * 1024 * 1024 * 1024;
25944
26006
  var archiveMediaFile = /* @__PURE__ */ __name(async (root, identity, kind, file2, beforeWrite, signal, metadata = {}) => {
@@ -26039,7 +26101,7 @@ var archiveMediaFile = /* @__PURE__ */ __name(async (root, identity, kind, file2
26039
26101
  return entry;
26040
26102
  }, "archiveMediaFile");
26041
26103
 
26042
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive-locks.js
26104
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive-locks.js
26043
26105
  import { mkdir, realpath } from "node:fs/promises";
26044
26106
  import { join as join10, resolve as resolve4 } from "node:path";
26045
26107
  var archiveLocations = /* @__PURE__ */ __name(async (initial, signal) => {
@@ -26106,7 +26168,7 @@ var withMediaArchiveLocks = /* @__PURE__ */ __name(async (directory2, signal, ru
26106
26168
  throw new CliError("validation_error", "archive locations changed during locking; run the command again");
26107
26169
  }, "withMediaArchiveLocks");
26108
26170
 
26109
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive.js
26171
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive.js
26110
26172
  var validateMediaSince = /* @__PURE__ */ __name((value, flag = "--since-time") => {
26111
26173
  if (value === void 0)
26112
26174
  return void 0;
@@ -26259,7 +26321,7 @@ var archiveMedia = /* @__PURE__ */ __name(async (ports, options2) => {
26259
26321
  }, { create: true });
26260
26322
  }, "archiveMedia");
26261
26323
 
26262
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/media-archive-move.js
26324
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/media-archive-move.js
26263
26325
  import { realpath as realpath2, unlink as unlink5 } from "node:fs/promises";
26264
26326
  import { basename as basename3, dirname as dirname6, join as join11, resolve as resolve5 } from "node:path";
26265
26327
  var canonicalDestination = /* @__PURE__ */ __name(async (directory2) => {
@@ -26412,7 +26474,7 @@ var moveMediaArchive = /* @__PURE__ */ __name(async (options2) => {
26412
26474
  }, { additional: [target2], createAdditional: !options2.dryRun });
26413
26475
  }, "moveMediaArchive");
26414
26476
 
26415
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/model-downloads.js
26477
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/model-downloads.js
26416
26478
  import { writeFileSync as writeFileSync2 } from "node:fs";
26417
26479
  import { join as join12 } from "node:path";
26418
26480
  var bytesOf = /* @__PURE__ */ __name((model) => model.files.reduce((sum2, file2) => sum2 + file2.bytes, 0), "bytesOf");
@@ -26437,7 +26499,7 @@ var downloadTextModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
26437
26499
  `);
26438
26500
  await nativeRuntime({ env, progress });
26439
26501
  progress(`${model.id}: loading it once to check it works`);
26440
- const { openEmbedder: openEmbedder2 } = await import("./embed-TB2AS4AT.js");
26502
+ const { openEmbedder: openEmbedder2 } = await import("./embed-Q7ZCVSCO.js");
26441
26503
  const embedder = await openEmbedder2(model, directory2);
26442
26504
  try {
26443
26505
  const [vector] = await embedder.embed(["check"], "query");
@@ -26458,7 +26520,7 @@ var downloadRerankModel = /* @__PURE__ */ __name(async (id2, { env, progress = /
26458
26520
  }
26459
26521
  await nativeRuntime({ env, progress });
26460
26522
  progress(`${model.id}: loading it once to check it works`);
26461
- const { openReranker } = await import("./rerank-RJX77BKD.js");
26523
+ const { openReranker } = await import("./rerank-ONAEQVJ6.js");
26462
26524
  const reranker = await openReranker(model, directory2);
26463
26525
  try {
26464
26526
  await reranker.score("check", ["check"]);
@@ -26476,7 +26538,7 @@ var downloadImageModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
26476
26538
  await installFiles(placedImage(model, directory2), { progress, ...bytes2 ? { bytes: bytes2 } : {} });
26477
26539
  }
26478
26540
  progress(`${model.id}: loading it once to check it works`);
26479
- const { openPictureEmbedder } = await import("./embedder-YKC42G6L.js");
26541
+ const { openPictureEmbedder } = await import("./embedder-MVS3PVWQ.js");
26480
26542
  const embedder = await openPictureEmbedder(model, directory2);
26481
26543
  try {
26482
26544
  const vector = await embedder.embedQuery("check");
@@ -26488,7 +26550,7 @@ var downloadImageModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
26488
26550
  return { model, directory: directory2 };
26489
26551
  }, "downloadImageModel");
26490
26552
 
26491
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/money-words.js
26553
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/money-words.js
26492
26554
  var MONEY_REQUEST = "money-request";
26493
26555
  var MONEY_DONE = "money-done";
26494
26556
  var PROMISE = "promise";
@@ -26522,10 +26584,10 @@ var MONEY_WORDS = [
26522
26584
  }
26523
26585
  ];
26524
26586
 
26525
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/money-words.js
26587
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/money-words.js
26526
26588
  var moneyClassesOf = /* @__PURE__ */ __name((text2) => listsHit(text2, MONEY_WORDS), "moneyClassesOf");
26527
26589
 
26528
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/status-words.js
26590
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/status-words.js
26529
26591
  var words = /* @__PURE__ */ __name((forms) => new RegExp(`(?<![\\p{L}\\p{N}])(?:${forms.join("|")})(?![\\p{L}\\p{N}])`, "iu"), "words");
26530
26592
  var MONEY_DONE_FORMS = words([
26531
26593
  "\u043E\u043F\u043B\u0430\u0442\u0438\u043B[\u0430\u0438]?",
@@ -26565,7 +26627,7 @@ var PROMISE_FORMS = words([
26565
26627
  "estar\xE1 listo"
26566
26628
  ]);
26567
26629
 
26568
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/items.js
26630
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/items.js
26569
26631
  var EXCERPT_CHARS = 80;
26570
26632
  var excerpt2 = /* @__PURE__ */ __name((text2) => {
26571
26633
  const flat = text2.replace(/\s+/g, " ").trim();
@@ -26587,7 +26649,7 @@ var whoOf = /* @__PURE__ */ __name((message) => ({
26587
26649
  var fromOwner = /* @__PURE__ */ __name((message) => message.outgoing === true, "fromOwner");
26588
26650
  var day = /* @__PURE__ */ __name((at) => new Date(at).toISOString().slice(0, 10), "day");
26589
26651
 
26590
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/amounts.js
26652
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/amounts.js
26591
26653
  var MONEY = DEFAULT_TASK_CATEGORIES.filter((category) => category.name === "money");
26592
26654
  var verbOf = /* @__PURE__ */ __name((text2) => {
26593
26655
  if (MONEY_DONE_FORMS.test(text2))
@@ -26668,7 +26730,7 @@ var amounts = {
26668
26730
  attention: /* @__PURE__ */ __name((items) => items.flatMap((item2) => item2.chat !== null && item2.data.state === "asked" ? [{ chat: item2.chat, weight: 2, why: "money asked" }] : []), "attention")
26669
26731
  };
26670
26732
 
26671
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/children.js
26733
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/children.js
26672
26734
  var children = {
26673
26735
  id: "children",
26674
26736
  version: 1,
@@ -26697,7 +26759,7 @@ var children = {
26697
26759
  }, "read")
26698
26760
  };
26699
26761
 
26700
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/coverage.js
26762
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/coverage.js
26701
26763
  var coverage = {
26702
26764
  id: "coverage",
26703
26765
  version: 1,
@@ -26726,7 +26788,7 @@ var coverage = {
26726
26788
  attention: /* @__PURE__ */ __name((items) => items.flatMap((item2) => item2.chat !== null && item2.data.state !== "complete" && item2.data.beforeHeld ? [{ chat: item2.chat, weight: 3, why: "held in part" }] : []), "attention")
26727
26789
  };
26728
26790
 
26729
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/payments.js
26791
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/payments.js
26730
26792
  var holding2 = /* @__PURE__ */ __name((row) => row.review !== "rejected", "holding");
26731
26793
  var item = /* @__PURE__ */ __name((row, at, data) => ({
26732
26794
  signal: "payments",
@@ -26776,7 +26838,7 @@ var payments = {
26776
26838
  }, "read")
26777
26839
  };
26778
26840
 
26779
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/promises.js
26841
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/promises.js
26780
26842
  var PATTERNS_PER_CHAT = 3;
26781
26843
  var DAY3 = 864e5;
26782
26844
  var KINDS2 = /* @__PURE__ */ new Set(["promise", "request"]);
@@ -26865,7 +26927,7 @@ var promises = {
26865
26927
  }, "read")
26866
26928
  };
26867
26929
 
26868
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/questions.js
26930
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/questions.js
26869
26931
  var PER_SIDE = 5;
26870
26932
  var WEEK = 7 * 864e5;
26871
26933
  var NOBODY = /* @__PURE__ */ new Set();
@@ -26896,7 +26958,7 @@ var questions2 = {
26896
26958
  }, "attention")
26897
26959
  };
26898
26960
 
26899
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/reply-next.js
26961
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/reply-next.js
26900
26962
  var targetOf = /* @__PURE__ */ __name((message, chat, owners) => {
26901
26963
  const byId2 = /* @__PURE__ */ __name((id2) => chat.messages.find((one) => one.id === id2), "byId");
26902
26964
  const quoted = message.replyTo ?? (message.replyToId === void 0 ? void 0 : byId2(message.replyToId));
@@ -26964,7 +27026,7 @@ var replyNext = {
26964
27026
  attention: /* @__PURE__ */ __name((items) => items.flatMap((item2) => item2.chat !== null && item2.data.next === "owner" ? [{ chat: item2.chat, weight: 2, why: "your move" }] : []), "attention")
26965
27027
  };
26966
27028
 
26967
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/topics.js
27029
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/topics.js
26968
27030
  var escaped = /* @__PURE__ */ __name((text2) => text2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "escaped");
26969
27031
  var wholeWord = /* @__PURE__ */ __name((word) => new RegExp(`(?<![\\p{L}\\p{N}])${escaped(word)}(?![\\p{L}\\p{N}])`, "u"), "wholeWord");
26970
27032
  var matcherOf = /* @__PURE__ */ __name((query) => {
@@ -27010,7 +27072,7 @@ var topics = {
27010
27072
  }, "read")
27011
27073
  };
27012
27074
 
27013
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/signals/index.js
27075
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/signals/index.js
27014
27076
  var STATUS_SIGNALS = [
27015
27077
  replyNext,
27016
27078
  questions2,
@@ -27022,7 +27084,7 @@ var STATUS_SIGNALS = [
27022
27084
  children
27023
27085
  ];
27024
27086
 
27025
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/project-status/index.js
27087
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/project-status/index.js
27026
27088
  var DAY4 = 864e5;
27027
27089
  var STATUS_WINDOW = 300;
27028
27090
  var STATUS_CHATS = 16;
@@ -27211,7 +27273,7 @@ var projectStatus = /* @__PURE__ */ __name(async (store, input) => {
27211
27273
  };
27212
27274
  }, "projectStatus");
27213
27275
 
27214
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/account.js
27276
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/account.js
27215
27277
  var accountService = /* @__PURE__ */ __name((deps) => {
27216
27278
  const online = /* @__PURE__ */ __name(async (command) => {
27217
27279
  if (deps.offline)
@@ -27283,7 +27345,7 @@ var accountService = /* @__PURE__ */ __name((deps) => {
27283
27345
  };
27284
27346
  }, "accountService");
27285
27347
 
27286
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/send-time.js
27348
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/send-time.js
27287
27349
  var MINUTE = 6e4;
27288
27350
  var YEAR = 365 * 24 * 60 * MINUTE;
27289
27351
  var DELAY = /^(\d+)(m|h|d)$/;
@@ -27302,7 +27364,7 @@ var sendTime = /* @__PURE__ */ __name((value, now = Date.now(), flag = "--at-tim
27302
27364
  return new Date(at - at % MINUTE).toISOString();
27303
27365
  }, "sendTime");
27304
27366
 
27305
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/admin.js
27367
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/admin.js
27306
27368
  var recordMembership = /* @__PURE__ */ __name(async (deps, operationId, done2, change, fix, write) => {
27307
27369
  try {
27308
27370
  const held = await accountStoreIfOpen(deps);
@@ -27549,7 +27611,7 @@ var linkLimits = /* @__PURE__ */ __name(({ approval, expires, maxUses }) => {
27549
27611
  return expires === void 0 ? void 0 : sendTime(expires, Date.now(), "--expire-time");
27550
27612
  }, "linkLimits");
27551
27613
 
27552
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/mail-search.js
27614
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/mail-search.js
27553
27615
  var THREADS_PAGE = 500;
27554
27616
  var threadsOf = /* @__PURE__ */ __name(async (store, key) => {
27555
27617
  const account = await store.accounts.storedAccount(key).catch(() => void 0);
@@ -27628,7 +27690,7 @@ var readMail = /* @__PURE__ */ __name(async (store, locator, { before: before2 =
27628
27690
  return thread.slice(Math.max(0, at - before2), at + after + 1).map((hit) => hit.id === message ? { ...hit, anchor: true } : hit);
27629
27691
  }, "readMail");
27630
27692
 
27631
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-search.js
27693
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-search.js
27632
27694
  var PERSON_FIELDS = /* @__PURE__ */ new Set(["from", "to", "cc", "bcc"]);
27633
27695
  var MAIL_FIELDS = /* @__PURE__ */ new Set(["to", "cc", "bcc", "subject", "mailbox", "label", "is", "list"]);
27634
27696
  var positiveSources = /* @__PURE__ */ __name((node) => node.kind === "predicate" ? node.field === "in" ? [node.value.toLowerCase()] : [] : node.clauses.filter(({ occur }) => occur !== "must_not").flatMap(({ node: node2 }) => positiveSources(node2)), "positiveSources");
@@ -27997,7 +28059,7 @@ var statsLucene = /* @__PURE__ */ __name(async (store, account, request, messeng
27997
28059
  };
27998
28060
  }, "statsLucene");
27999
28061
 
28000
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/rankings-selection.js
28062
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/rankings-selection.js
28001
28063
  var RANKING_SELECTION_BYTES = 64 * 1024;
28002
28064
  var object2 = /* @__PURE__ */ __name((value) => value !== null && typeof value === "object" && !Array.isArray(value) ? value : void 0, "object");
28003
28065
  function invalid3(message = "ranking selection is invalid \u2014 obtain a new drilldown from stats top") {
@@ -28166,7 +28228,7 @@ var readRankingSelection = /* @__PURE__ */ __name(async (store, input) => {
28166
28228
  };
28167
28229
  }, "readRankingSelection");
28168
28230
 
28169
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-record.js
28231
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-record.js
28170
28232
  var canonical = /* @__PURE__ */ __name((value, nested = false) => Array.isArray(value) ? value.map((one) => canonical(one, true)) : value !== null && typeof value === "object" ? Object.fromEntries(Object.entries(value).filter(([, one]) => one !== void 0 && (nested || one !== false)).sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0).map(([key, one]) => [key, canonical(one, true)])) : value, "canonical");
28171
28233
  var searchRecordOf = /* @__PURE__ */ __name((command, params) => ({
28172
28234
  command,
@@ -28176,7 +28238,7 @@ var searchRecordOf = /* @__PURE__ */ __name((command, params) => ({
28176
28238
  fieldsVersion: FIELD_VERSION
28177
28239
  }), "searchRecordOf");
28178
28240
 
28179
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/admin-statistics.js
28241
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/admin-statistics.js
28180
28242
  function invalid4(message) {
28181
28243
  throw new CliError("validation_error", message);
28182
28244
  }
@@ -28470,7 +28532,7 @@ var adminStatisticsService = /* @__PURE__ */ __name((deps) => ({
28470
28532
  }, "evidence")
28471
28533
  }), "adminStatisticsService");
28472
28534
 
28473
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/archive-gaps.js
28535
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/archive-gaps.js
28474
28536
  import { createHash as createHash7, randomUUID as randomUUID5 } from "node:crypto";
28475
28537
  var GAP_BOUNDS = { maxGaps: 5, limit: 500, timeMs: 3e4 };
28476
28538
  var validateRepair = /* @__PURE__ */ __name((messenger, options2) => {
@@ -28607,12 +28669,12 @@ var gapsService = /* @__PURE__ */ __name((deps) => {
28607
28669
  return { plan, repair };
28608
28670
  }, "gapsService");
28609
28671
 
28610
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/attachments.js
28672
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/attachments.js
28611
28673
  import { createHash as createHash10 } from "node:crypto";
28612
28674
  import { constants as constants2, mkdirSync as mkdirSync5 } from "node:fs";
28613
28675
  import { lstat as lstat5, open as open6, readFile as readFile2, stat as stat2 } from "node:fs/promises";
28614
28676
 
28615
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/directory.js
28677
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/directory.js
28616
28678
  import { lstat as lstat2, readdir as readdir2, realpath as realpath3 } from "node:fs/promises";
28617
28679
  import { basename as basename4, join as join13, relative as relative2, sep as sep2 } from "node:path";
28618
28680
  var MAX_FILES = 1e4;
@@ -28683,15 +28745,15 @@ var directoryPaths = /* @__PURE__ */ __name(async (store, chat, directory2, app,
28683
28745
  return choices;
28684
28746
  }, "directoryPaths");
28685
28747
 
28686
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/documents.js
28748
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/documents.js
28687
28749
  import { posix } from "node:path";
28688
28750
 
28689
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/container.js
28751
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/container.js
28690
28752
  import { setImmediate as tick } from "node:timers/promises";
28691
28753
  import { crc32 } from "node:zlib";
28692
28754
  var import_xmldom = __toESM(require_lib(), 1);
28693
28755
 
28694
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/encoding.js
28756
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/encoding.js
28695
28757
  var import_chardet = __toESM(require_lib2(), 1);
28696
28758
  var import_iconv_lite = __toESM(require_lib3(), 1);
28697
28759
  var SAMPLE = 65536;
@@ -28793,7 +28855,7 @@ var decodeXml = /* @__PURE__ */ __name((bytes2) => {
28793
28855
  return result.text;
28794
28856
  }, "decodeXml");
28795
28857
 
28796
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/container.js
28858
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/container.js
28797
28859
  var MAX_PART = 10 * 1024 * 1024;
28798
28860
  var MAX_ENTRIES = 1e3;
28799
28861
  var decoder = new TextDecoder("utf-8", { fatal: true });
@@ -29008,7 +29070,7 @@ var elements = /* @__PURE__ */ __name((node, name, namespace) => {
29008
29070
  return found;
29009
29071
  }, "elements");
29010
29072
 
29011
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/sheets.js
29073
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/sheets.js
29012
29074
  var columnName = /* @__PURE__ */ __name((column) => {
29013
29075
  let name = "";
29014
29076
  for (let rest = column; rest > 0; rest = Math.floor((rest - 1) / 26))
@@ -29063,7 +29125,7 @@ var sheetText = /* @__PURE__ */ __name((sheets2, maxChars = MAX_TEXT_CHARS) => {
29063
29125
  return { text: parts.join("").trim(), truncated: false };
29064
29126
  }, "sheetText");
29065
29127
 
29066
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/documents.js
29128
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/documents.js
29067
29129
  var OFFICE = "urn:oasis:names:tc:opendocument:xmlns:office:1.0";
29068
29130
  var TEXT = "urn:oasis:names:tc:opendocument:xmlns:text:1.0";
29069
29131
  var TABLE = "urn:oasis:names:tc:opendocument:xmlns:table:1.0";
@@ -29463,10 +29525,10 @@ var readDocument = /* @__PURE__ */ __name(async (bytes2, kind, signal) => {
29463
29525
  }
29464
29526
  }, "readDocument");
29465
29527
 
29466
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/extract.js
29528
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/extract.js
29467
29529
  import { extname as extname3 } from "node:path";
29468
29530
 
29469
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/engine.js
29531
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/engine.js
29470
29532
  import { readFileSync as readFileSync5 } from "node:fs";
29471
29533
  import { dirname as dirname7, extname as extname2, join as join14 } from "node:path";
29472
29534
  import { fileURLToPath } from "node:url";
@@ -29527,7 +29589,7 @@ var derived = /* @__PURE__ */ __name((bytes2, extractor, read) => {
29527
29589
  }
29528
29590
  }, "derived");
29529
29591
 
29530
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/image/index.js
29592
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/image/index.js
29531
29593
  var IMAGES = /* @__PURE__ */ new Set([".jpg", ".jpeg", ".png", ".webp", ".gif", ".heic", ".tif", ".tiff", ".bmp"]);
29532
29594
  var image2 = {
29533
29595
  id: "image",
@@ -29536,7 +29598,7 @@ var image2 = {
29536
29598
  read: /* @__PURE__ */ __name(async () => ({ status: "needs-agent" }), "read")
29537
29599
  };
29538
29600
 
29539
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/doc/index.js
29601
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/doc/index.js
29540
29602
  var OLE = "\xD0\xCF\xE0\xA1\xB1\xE1";
29541
29603
  var doc = {
29542
29604
  id: "doc",
@@ -29548,7 +29610,7 @@ var doc = {
29548
29610
  }), "read")
29549
29611
  };
29550
29612
 
29551
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/docx/index.js
29613
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/docx/index.js
29552
29614
  var DOCX = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
29553
29615
  var docx = {
29554
29616
  id: "docx",
@@ -29561,7 +29623,7 @@ var docx = {
29561
29623
  }), "read")
29562
29624
  };
29563
29625
 
29564
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/markup.js
29626
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/markup.js
29565
29627
  var import_iconv_lite2 = __toESM(require_lib3(), 1);
29566
29628
  var RTF_SKIPPED = /* @__PURE__ */ new Set([
29567
29629
  "fonttbl",
@@ -29737,7 +29799,7 @@ var htmlText = /* @__PURE__ */ __name((source) => {
29737
29799
  }, "htmlText");
29738
29800
  var safeChar = /* @__PURE__ */ __name((code, fallback) => code > 0 && code <= 1114111 ? String.fromCodePoint(code) : fallback, "safeChar");
29739
29801
 
29740
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/html/page.js
29802
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/html/page.js
29741
29803
  var clean = /* @__PURE__ */ __name((value) => typeof value === "string" ? value.replace(/\s+/g, " ").trim() : "", "clean");
29742
29804
  var namesIn = /* @__PURE__ */ __name((value) => [value].flat().map((entry) => typeof entry === "string" ? clean(entry) : clean(entry?.name)).filter(Boolean).join(", "), "namesIn");
29743
29805
  var jsonLdNodes = /* @__PURE__ */ __name((document) => {
@@ -29793,7 +29855,7 @@ var markdownSections = /* @__PURE__ */ __name((text2) => {
29793
29855
  return found.map((section, index) => ({ ...section, end: found[index + 1]?.start ?? text2.length }));
29794
29856
  }, "markdownSections");
29795
29857
 
29796
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/html/index.js
29858
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/html/index.js
29797
29859
  var HTML = /* @__PURE__ */ new Set([".html", ".htm", ".xhtml"]);
29798
29860
  var first = /* @__PURE__ */ __name((...values) => values.find((value) => typeof value === "string" && value !== ""), "first");
29799
29861
  var loaded = /* @__PURE__ */ __name(async (load, name) => {
@@ -29864,7 +29926,7 @@ var html = {
29864
29926
  }, "read")
29865
29927
  };
29866
29928
 
29867
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/office/index.js
29929
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/office/index.js
29868
29930
  var office = {
29869
29931
  id: "office",
29870
29932
  version: documentExtractor("odt"),
@@ -29875,7 +29937,7 @@ var office = {
29875
29937
  }, "read")
29876
29938
  };
29877
29939
 
29878
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/pdf/index.js
29940
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/pdf/index.js
29879
29941
  var pdf = {
29880
29942
  id: "pdf",
29881
29943
  version: "unpdf",
@@ -29942,7 +30004,7 @@ var pdf = {
29942
30004
  }), "read")
29943
30005
  };
29944
30006
 
29945
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/plain/index.js
30007
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/plain/index.js
29946
30008
  var PLAIN = /* @__PURE__ */ new Set([".txt", ".md", ".markdown", ".csv", ".tsv", ".json", ".log"]);
29947
30009
  var isPlain = /* @__PURE__ */ __name((hint) => PLAIN.has(extensionOf(hint)) || hint.mime?.startsWith("text/") || hint.mime === "application/json", "isPlain");
29948
30010
  var readPlain = /* @__PURE__ */ __name((bytes2) => {
@@ -29962,7 +30024,7 @@ var plain = {
29962
30024
  read: /* @__PURE__ */ __name(async (bytes2) => readPlain(bytes2), "read")
29963
30025
  };
29964
30026
 
29965
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/rtf/index.js
30027
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/rtf/index.js
29966
30028
  var rtf = {
29967
30029
  id: "rtf",
29968
30030
  version: "v1",
@@ -29970,10 +30032,10 @@ var rtf = {
29970
30032
  read: /* @__PURE__ */ __name(async (bytes2) => derived(bytes2, "rtf:v1", rtfText), "read")
29971
30033
  };
29972
30034
 
29973
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
30035
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
29974
30036
  import { basename as basename5 } from "node:path";
29975
30037
 
29976
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/csv-spans.js
30038
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/csv-spans.js
29977
30039
  var delimitedSpans = /* @__PURE__ */ __name((text2, delimiter, maxCells = 1e4) => {
29978
30040
  const cells = [];
29979
30041
  let row = 1, column = 1, start = 0, quoted = false, truncated = false;
@@ -30011,7 +30073,7 @@ var delimitedSpans = /* @__PURE__ */ __name((text2, delimiter, maxCells = 1e4) =
30011
30073
  return { cells, truncated };
30012
30074
  }, "delimitedSpans");
30013
30075
 
30014
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
30076
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
30015
30077
  var DELIMITED = {
30016
30078
  ".csv": ",",
30017
30079
  ".tsv": " ",
@@ -30050,7 +30112,7 @@ var sheets = {
30050
30112
  }, "read")
30051
30113
  };
30052
30114
 
30053
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/readers/registry.js
30115
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/readers/registry.js
30054
30116
  var BUILT_INS2 = [office, pdf, docx, doc, rtf, html, sheets, plain, image2];
30055
30117
  var HEAD_BYTES = 1024;
30056
30118
  var readers = [...BUILT_INS2];
@@ -30060,7 +30122,7 @@ var readWithRegistry = /* @__PURE__ */ __name(async (bytes2, hint, context2) =>
30060
30122
  return reader ? reader.read(bytes2, hint, context2) : { status: "unsupported" };
30061
30123
  }, "readWithRegistry");
30062
30124
 
30063
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/extract.js
30125
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/extract.js
30064
30126
  var importEngine = /* @__PURE__ */ __name((name) => importFrom(new URL("attachments/extract.js", import.meta.resolve("@wirecat/cli-core")).href, name), "importEngine");
30065
30127
  var extensionOf2 = /* @__PURE__ */ __name(({ name, path }) => extname3(name ?? path).toLowerCase(), "extensionOf");
30066
30128
  var extractText = /* @__PURE__ */ __name(async (bytes2, hint, load, signal, env = process.env) => {
@@ -31139,7 +31201,7 @@ function imageSize(input) {
31139
31201
  }
31140
31202
  __name(imageSize, "imageSize");
31141
31203
 
31142
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/ocr.js
31204
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/ocr.js
31143
31205
  var MAX_PAGES = 20;
31144
31206
  var MAX_PIXELS = 2e7;
31145
31207
  var cancelled2 = /* @__PURE__ */ __name((signal) => {
@@ -31299,7 +31361,7 @@ var ocrPdf = /* @__PURE__ */ __name(async (bytes2, pipeline2, load, signal) => {
31299
31361
  }
31300
31362
  }, "ocrPdf");
31301
31363
 
31302
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/pdf-preview.js
31364
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/pdf-preview.js
31303
31365
  var pdfPreview = /* @__PURE__ */ __name(async (bytes2, page, signal, load = importEngine, env = process.env) => {
31304
31366
  const limits = pdfPreviewLimits(env);
31305
31367
  const cancelled3 = /* @__PURE__ */ __name(() => {
@@ -31376,7 +31438,7 @@ var pdfPreview = /* @__PURE__ */ __name(async (bytes2, page, signal, load = impo
31376
31438
  }
31377
31439
  }, "pdfPreview");
31378
31440
 
31379
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/picture-reading.js
31441
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/picture-reading.js
31380
31442
  import { spawn } from "node:child_process";
31381
31443
  import { mkdtempSync, readFileSync as readFileSync6, rmSync as rmSync2, writeFileSync as writeFileSync3 } from "node:fs";
31382
31444
  import { tmpdir } from "node:os";
@@ -31539,7 +31601,7 @@ Read the attached picture.`,
31539
31601
  }
31540
31602
  }, "readPictureWithAgent");
31541
31603
 
31542
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/attachments/transfer.js
31604
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/attachments/transfer.js
31543
31605
  import { createHash as createHash8 } from "node:crypto";
31544
31606
  import { constants } from "node:fs";
31545
31607
  import { lstat as lstat3, open as open5 } from "node:fs/promises";
@@ -31647,7 +31709,7 @@ var transferMime = /* @__PURE__ */ __name((head, hint, name = null) => {
31647
31709
  return hint !== null && /^[a-z0-9.+-]+\/[a-z0-9.+-]+$/i.test(hint) ? hint : "application/octet-stream";
31648
31710
  }, "transferMime");
31649
31711
 
31650
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/file-download.js
31712
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/file-download.js
31651
31713
  import { createWriteStream, mkdirSync as mkdirSync4 } from "node:fs";
31652
31714
  import { link as link3, rm } from "node:fs/promises";
31653
31715
  import { join as join16, resolve as resolve6 } from "node:path";
@@ -31761,12 +31823,12 @@ var save = /* @__PURE__ */ __name(async (file2, directory2, fallbackName, { uniq
31761
31823
  }
31762
31824
  }, "save");
31763
31825
 
31764
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/pictures.js
31826
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/pictures.js
31765
31827
  import { createHash as createHash9 } from "node:crypto";
31766
31828
  import { lstat as lstat4, readFile } from "node:fs/promises";
31767
31829
  import { setTimeout as sleep4 } from "node:timers/promises";
31768
31830
 
31769
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/models.js
31831
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/models.js
31770
31832
  var GROUP_SETTINGS = [
31771
31833
  "allCanPin",
31772
31834
  "onlyAdminsAdd",
@@ -31780,7 +31842,7 @@ var ADMIN_RIGHTS = ["read", "members", "admins", "info", "pin", "link", "post",
31780
31842
  var senderIsMe = /* @__PURE__ */ __name((message, account) => message.outgoing === true || message.senderId !== null && String(message.senderId) === account, "senderIsMe");
31781
31843
  var MEDIA_KINDS = ["photo", "video", "file", "audio", "link"];
31782
31844
 
31783
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/pictures.js
31845
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/pictures.js
31784
31846
  var PICTURE_MAX_BYTES = 25 * 1024 * 1024;
31785
31847
  var PICTURE_FLOOR = 0.25;
31786
31848
  var PAGE4 = 50;
@@ -31821,7 +31883,7 @@ var picturesService = /* @__PURE__ */ __name((deps) => {
31821
31883
  const directory2 = imageModelsDirectory(deps.env);
31822
31884
  if (!isImageModelInstalled(model2, directory2))
31823
31885
  throw new CliError("not_found", missingModel(model2.id), { reason: "model.not-downloaded", model: model2.id });
31824
- const { openPictureEmbedder } = await import("./embedder-YKC42G6L.js");
31886
+ const { openPictureEmbedder } = await import("./embedder-MVS3PVWQ.js");
31825
31887
  return openPictureEmbedder(model2, directory2);
31826
31888
  }, "open");
31827
31889
  const embedder = /* @__PURE__ */ __name(() => {
@@ -31995,7 +32057,7 @@ var withPictures = /* @__PURE__ */ __name((messages, pictures) => ({
31995
32057
  }, "search")
31996
32058
  }), "withPictures");
31997
32059
 
31998
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/attachments.js
32060
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/attachments.js
31999
32061
  var ATTACHMENT_QUERY = {
32000
32062
  entity: "attachment",
32001
32063
  backend: "sql",
@@ -32466,7 +32528,7 @@ var attachmentsService = /* @__PURE__ */ __name((deps) => ({
32466
32528
  }, "readPicture")
32467
32529
  }), "attachmentsService");
32468
32530
 
32469
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/chat-documents.js
32531
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/chat-documents.js
32470
32532
  var chatDocumentsService = /* @__PURE__ */ __name((deps) => ({
32471
32533
  list: /* @__PURE__ */ __name(async (chat, { limit, offset, ref }) => {
32472
32534
  const store = await accountStore(deps);
@@ -32496,7 +32558,7 @@ var chatDocumentsService = /* @__PURE__ */ __name((deps) => ({
32496
32558
  }, "list")
32497
32559
  }), "chatDocumentsService");
32498
32560
 
32499
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/retention.js
32561
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/retention.js
32500
32562
  var observationDuration = /* @__PURE__ */ __name((text2, flag) => {
32501
32563
  const match = /^(\d+(?:\.\d+)?)([smhdw])$/.exec(text2);
32502
32564
  const units2 = { s: 1e3, m: 6e4, h: 36e5, d: 864e5, w: 6048e5 };
@@ -32583,7 +32645,7 @@ var isRetentionSelection = /* @__PURE__ */ __name((selection) => {
32583
32645
  }
32584
32646
  }, "isRetentionSelection");
32585
32647
 
32586
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/counters.js
32648
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/counters.js
32587
32649
  var counterFields = /* @__PURE__ */ __name((text2 = "views,reactions,comments") => {
32588
32650
  const fields = text2.split(",").map((one) => one.trim());
32589
32651
  if (!fields.length || fields.some((one) => !COUNTER_FIELDS.includes(one)) || new Set(fields).size !== fields.length)
@@ -32790,7 +32852,7 @@ var countersService = /* @__PURE__ */ __name((deps) => {
32790
32852
  };
32791
32853
  }, "countersService");
32792
32854
 
32793
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-refresh.js
32855
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-refresh.js
32794
32856
  var SYNC_KEY = "messages.sync-first";
32795
32857
  var SYNC_BOUNDS = { maxChats: 5, timeMs: 3e4, maxMessages: 500 };
32796
32858
  var keyOf3 = /* @__PURE__ */ __name((chat) => JSON.stringify([chat.account.provider, chat.account.account, chat.chatId]), "keyOf");
@@ -32922,7 +32984,7 @@ var withRefresh = /* @__PURE__ */ __name((found, refreshed) => ({
32922
32984
  ...!refreshed || refreshed.complete ? {} : { coverage: { ...found.coverage, state: "stale" } }
32923
32985
  }), "withRefresh");
32924
32986
 
32925
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/embeddings-search.js
32987
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/embeddings-search.js
32926
32988
  var CANDIDATES = 50;
32927
32989
  var WORD_HITS = 200;
32928
32990
  var RRF_K = 60;
@@ -33197,13 +33259,13 @@ var meanOf = /* @__PURE__ */ __name((vectors) => {
33197
33259
  return mean2.map((value) => value / length);
33198
33260
  }, "meanOf");
33199
33261
 
33200
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/embeddings.js
33262
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/embeddings.js
33201
33263
  var embeddingsService = /* @__PURE__ */ __name((deps) => ({
33202
33264
  ...embeddingsMaintenance(deps),
33203
33265
  ...embeddingsSearch(deps)
33204
33266
  }), "embeddingsService");
33205
33267
 
33206
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/folders.js
33268
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/folders.js
33207
33269
  var foldersService = /* @__PURE__ */ __name((deps) => {
33208
33270
  const online = /* @__PURE__ */ __name(async (command) => {
33209
33271
  if (deps.offline)
@@ -33344,7 +33406,7 @@ var foldersService = /* @__PURE__ */ __name((deps) => {
33344
33406
  };
33345
33407
  }, "foldersService");
33346
33408
 
33347
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/mentions.js
33409
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/mentions.js
33348
33410
  var REVIEW_COUNT = 500;
33349
33411
  var mentionsService = /* @__PURE__ */ __name((deps) => {
33350
33412
  const located = /* @__PURE__ */ __name(async () => {
@@ -33423,7 +33485,7 @@ var mentionsService = /* @__PURE__ */ __name((deps) => {
33423
33485
  };
33424
33486
  }, "mentionsService");
33425
33487
 
33426
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/message-link.js
33488
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/message-link.js
33427
33489
  var fileLinks = /* @__PURE__ */ __name((attachments) => hitFiles(attachments).map(({ position, kind, name }) => ({
33428
33490
  position,
33429
33491
  kind,
@@ -33472,7 +33534,7 @@ var validatePermalink = /* @__PURE__ */ __name((link4) => {
33472
33534
  return { url: link4.url, access: link4.access, reason: link4.reason };
33473
33535
  }, "validatePermalink");
33474
33536
 
33475
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/pin-duration.js
33537
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/pin-duration.js
33476
33538
  var spokenSeconds = /* @__PURE__ */ __name((seconds) => {
33477
33539
  if (seconds % 86400 === 0 && seconds > 86400)
33478
33540
  return `${seconds / 86400}d`;
@@ -33504,7 +33566,7 @@ var pinDurationOf = /* @__PURE__ */ __name((value, allowed, flag = "--expire-tim
33504
33566
  return seconds;
33505
33567
  }, "pinDurationOf");
33506
33568
 
33507
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/sends/send-as.js
33569
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/sends/send-as.js
33508
33570
  var sendAsCheck = /* @__PURE__ */ __name((connection, sendAs) => {
33509
33571
  if (sendAs === void 0) {
33510
33572
  const saved = connection.savedSender?.bind(connection);
@@ -33529,7 +33591,7 @@ var typedSendAs = /* @__PURE__ */ __name((typed) => {
33529
33591
  return sendAs;
33530
33592
  }, "typedSendAs");
33531
33593
 
33532
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/search/total.js
33594
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/search/total.js
33533
33595
  var TOTAL_CAP = 1e4;
33534
33596
  var totalOf = /* @__PURE__ */ __name((count4, shown, hasMore, exact = true) => {
33535
33597
  const least = shown + (hasMore ? 1 : 0);
@@ -33540,7 +33602,7 @@ var totalOf = /* @__PURE__ */ __name((count4, shown, hasMore, exact = true) => {
33540
33602
  return { value: count4, relation: exact ? "eq" : "gte" };
33541
33603
  }, "totalOf");
33542
33604
 
33543
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/search/lucene/meaning-parts.js
33605
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/search/lucene/meaning-parts.js
33544
33606
  var WORD_FIELDS = /* @__PURE__ */ new Set(["text", "exact"]);
33545
33607
  var fieldsOfQuery = /* @__PURE__ */ __name((root, everything) => {
33546
33608
  let narrows = false;
@@ -33569,7 +33631,7 @@ var meaningWords = /* @__PURE__ */ __name((root) => {
33569
33631
  return wanted(root).join(" ").trim();
33570
33632
  }, "meaningWords");
33571
33633
 
33572
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/search/question-plan.js
33634
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/search/question-plan.js
33573
33635
  var words2 = /* @__PURE__ */ __name((text2) => normalize(text2).match(/[\p{L}\p{N}]+/gu) ?? [], "words");
33574
33636
  var scaffolding = new Set(words2("what which how many much who where when is are was were do does did can could should we the a an for of to under from in on at has have \u0441\u043A\u043E\u043B\u044C\u043A\u043E \u043A\u0430\u043A\u043E\u0439 \u043A\u0430\u043A\u0430\u044F \u043A\u0430\u043A\u0438\u0435 \u043A\u0430\u043A\u043E\u0435 \u043A\u0442\u043E \u043A\u043E\u043C\u0443 \u043A\u0435\u043C \u0433\u0434\u0435 \u043A\u043E\u0433\u0434\u0430 \u043A\u0430\u043A \u0447\u0442\u043E \u0432\u043E \u043F\u043E \u043D\u0430 \u0432 \u043A \u0441 \u0443 \u0447\u0435\u0440\u0435\u0437 \u043B\u0438 \u0434\u043E\u043B\u0436\u0435\u043D \u0434\u043E\u043B\u0436\u043D\u0430 \u043D\u0443\u0436\u043D\u043E \u0438\u0434\u0451\u0442 \u0438\u0434\u0435\u0442 \u043C\u043E\u0436\u043D\u043E \u043C\u043E\u0436\u0435\u0442 \u043C\u043E\u0433\u0443\u0442"));
33575
33637
  var questionWord = /\b(?:what|which|how|who|where|when|can|could|should)\b|(?:^|\s)(?:сколько|какой|какая|какие|какое|кто|кому|кем|где|когда|как|что|можно|может|могут|ли)(?:\s|$)/iu;
@@ -33702,7 +33764,7 @@ var questionLookup = /* @__PURE__ */ __name((text2) => {
33702
33764
  return terms.length ? anyOfTerms(terms, plan.scope) : void 0;
33703
33765
  }, "questionLookup");
33704
33766
 
33705
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-combined.js
33767
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-combined.js
33706
33768
  var COMBINED_DEFAULTS = { candidateDepth: 300, rrfK: 60, rerank: "all", chatCap: 0 };
33707
33769
  var tokensOf = /* @__PURE__ */ __name((text2) => normalize(text2).match(/[\p{L}\p{N}\p{Co}\p{M}]+/gu) ?? [], "tokensOf");
33708
33770
  var searchCombined = /* @__PURE__ */ __name(async (store, account, request, messenger = {}, options2 = COMBINED_DEFAULTS) => {
@@ -33896,7 +33958,7 @@ var signals = /* @__PURE__ */ __name((hit, terms, corrections, execution, mode,
33896
33958
  return mode === "coverage" ? coverage2 * 4 : mode === "proximity" ? proximity : mode === "phrase" ? phrase2 : coverage2 * 4 + proximity + phrase2;
33897
33959
  }, "signals");
33898
33960
 
33899
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-discovery.js
33961
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-discovery.js
33900
33962
  var MEANING_DEPTH = 100;
33901
33963
  var RRF_K2 = 60;
33902
33964
  var RERANK_DEPTH = 50;
@@ -34222,7 +34284,7 @@ var mixedWithReranker = /* @__PURE__ */ __name((head, scores) => {
34222
34284
  })).sort((a, b) => b.mixed - a.mixed).map(({ hit }) => hit);
34223
34285
  }, "mixedWithReranker");
34224
34286
 
34225
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/thread-context.js
34287
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/thread-context.js
34226
34288
  var THREAD_BOUNDS = { maxHops: 8, maxMessages: 50, maxBytes: 65536, withinMs: 864e5 };
34227
34289
  var bytes = /* @__PURE__ */ __name((items, links) => Buffer.byteLength(JSON.stringify({ items, links }), "utf8"), "bytes");
34228
34290
  var threadBounds = /* @__PURE__ */ __name((options2 = {}) => {
@@ -34421,7 +34483,7 @@ var readThreadContext = /* @__PURE__ */ __name(async (store, account, chat, mess
34421
34483
  return result;
34422
34484
  }, "readThreadContext");
34423
34485
 
34424
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-archive-search.js
34486
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-archive-search.js
34425
34487
  var SEARCH_FILL_MS = 200;
34426
34488
  var statsStore = /* @__PURE__ */ __name(async (store, account, request, messenger = {}) => {
34427
34489
  const stop = Date.now() + SEARCH_FILL_MS;
@@ -34490,7 +34552,7 @@ var accountOf2 = /* @__PURE__ */ __name((hit) => {
34490
34552
  }, "accountOf");
34491
34553
  var keyOf4 = /* @__PURE__ */ __name(({ provider, account }) => `${provider}/${account}`, "keyOf");
34492
34554
 
34493
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meaning-model.js
34555
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meaning-model.js
34494
34556
  var meaningModel = /* @__PURE__ */ __name(async (store, env = process.env) => {
34495
34557
  const chosen = chosenTextModel(env);
34496
34558
  if (chosen.from === "chosen" || chosen.id !== DEFAULT_TEXT_MODEL)
@@ -34505,7 +34567,7 @@ var meaningModel = /* @__PURE__ */ __name(async (store, env = process.env) => {
34505
34567
  return (counts.get(before2) ?? 0) > (counts.get(now) ?? 0) ? previous.id : current.id;
34506
34568
  }, "meaningModel");
34507
34569
 
34508
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-meaning.js
34570
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-meaning.js
34509
34571
  var meaningText = /* @__PURE__ */ __name((question) => {
34510
34572
  try {
34511
34573
  const text2 = questionLookup(question) === void 0 ? question : questionText(question);
@@ -34584,7 +34646,7 @@ var meaningLane = /* @__PURE__ */ __name((deps) => async (question, accounts, sh
34584
34646
  }
34585
34647
  }, "meaningLane");
34586
34648
 
34587
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages-rerank.js
34649
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages-rerank.js
34588
34650
  var rerankLane = /* @__PURE__ */ __name((deps) => {
34589
34651
  const choice = deps.reranker ?? DEFAULT_RERANK_MODEL;
34590
34652
  if (choice === "off")
@@ -34596,9 +34658,9 @@ var rerankLane = /* @__PURE__ */ __name((deps) => {
34596
34658
  return { skipped: { reason: `${model.id} is not downloaded`, step: "models.download", model: model.id } };
34597
34659
  try {
34598
34660
  const warm = deps.embedders;
34599
- const reranker = warm ? await warm.reranker(`rerank:${model.id}`, async () => (await import("./process-YJ4LHMJB.js")).openRerankerProcess(model, directory2, {
34661
+ const reranker = warm ? await warm.reranker(`rerank:${model.id}`, async () => (await import("./process-VZKFAGNP.js")).openRerankerProcess(model, directory2, {
34600
34662
  threads: defaultThreads()
34601
- })) : await (await import("./rerank-RJX77BKD.js")).openReranker(model, directory2);
34663
+ })) : await (await import("./rerank-ONAEQVJ6.js")).openReranker(model, directory2);
34602
34664
  return {
34603
34665
  model: model.id,
34604
34666
  score: /* @__PURE__ */ __name((question, passages) => reranker.score(plainWords(question), passages), "score"),
@@ -34618,7 +34680,7 @@ var rerankLane = /* @__PURE__ */ __name((deps) => {
34618
34680
  };
34619
34681
  }, "rerankLane");
34620
34682
 
34621
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/search/question-period.js
34683
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/search/question-period.js
34622
34684
  var DAY5 = 864e5;
34623
34685
  var SPAN = { start: 0, end: 0 };
34624
34686
  var phrase = /* @__PURE__ */ __name((source) => new RegExp(`(?<![\\p{L}\\p{N}])(?:${source})(?![\\p{L}\\p{N}])`, "giu"), "phrase");
@@ -34743,20 +34805,27 @@ var questionPeriod = /* @__PURE__ */ __name((text2, now, zone) => {
34743
34805
  };
34744
34806
  }, "questionPeriod");
34745
34807
 
34746
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/document-pictures.js
34808
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/document-pictures.js
34747
34809
  var openPictureEmbedderFor = /* @__PURE__ */ __name(async ({ env, command } = {}) => {
34748
34810
  const model = imageModel(DEFAULT_IMAGE_MODEL);
34749
34811
  const directory2 = imageModelsDirectory(env);
34750
34812
  if (!isImageModelInstalled(model, directory2))
34751
34813
  throw new CliError("not_found", `the picture model is not downloaded \u2014 ${command === void 0 ? "install it with a WireCat CLI that has `images models download` (tg, max or wa); they share the model folder" : `\`${command} images models download ${model.id}\` fetches it`}`, { reason: "model.not-downloaded", model: model.id });
34752
- const { openPictureEmbedder } = await import("./embedder-YKC42G6L.js");
34814
+ const { openPictureEmbedder } = await import("./embedder-MVS3PVWQ.js");
34753
34815
  return openPictureEmbedder(model, directory2);
34754
34816
  }, "openPictureEmbedderFor");
34755
34817
 
34756
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/document-source.js
34818
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/document-source.js
34757
34819
  var documentSource = /* @__PURE__ */ __name((note, accounts, profiles, file2) => {
34758
34820
  const metadata = note.frontMatter;
34759
34821
  const account = accounts.find(({ id: id2 }) => String(id2) === note.folderId);
34822
+ if (note.source === "file" && account !== void 0 && isImportedProvider(account.provider))
34823
+ return {
34824
+ kind: "document",
34825
+ provider: account.provider,
34826
+ account: account.account,
34827
+ ...file2?.url ? { url: file2.url } : {}
34828
+ };
34760
34829
  const remote = note.source === "file" && (account !== void 0 && kindIn(account.provider) === "documents" || metadata?.source === "google-drive");
34761
34830
  const profile = remote && account ? Object.entries(profiles).flatMap(([command, named2]) => Object.entries(named2).map(([name, key]) => ({ command, name, key }))).find(({ key }) => key.provider === account.provider && key.account === account.account || isFolderProvider(key.provider) && key.account === account.name) : void 0;
34762
34831
  const url = file2?.url ?? (remote && typeof metadata?.sourceUrl === "string" ? metadata.sourceUrl : void 0);
@@ -34768,7 +34837,7 @@ var documentSource = /* @__PURE__ */ __name((note, accounts, profiles, file2) =>
34768
34837
  };
34769
34838
  }, "documentSource");
34770
34839
 
34771
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/embeddings/keys.js
34840
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/embeddings/keys.js
34772
34841
  var endpointKeyName = /* @__PURE__ */ __name((baseUrl) => {
34773
34842
  const host = new URL(baseUrl).host;
34774
34843
  return ["openai", "anthropic"].includes(host) ? `endpoint:${host}` : host;
@@ -34801,7 +34870,7 @@ var embeddingKeys = /* @__PURE__ */ __name((app, env = process.env, keyring) =>
34801
34870
  };
34802
34871
  }, "embeddingKeys");
34803
34872
 
34804
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/models/openai.js
34873
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/models/openai.js
34805
34874
  var options = strictObject({
34806
34875
  temperature: range(0, 2),
34807
34876
  top_p: range(0, 1),
@@ -34868,7 +34937,7 @@ var openai = {
34868
34937
  }), "complete")
34869
34938
  };
34870
34939
 
34871
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/models/index.js
34940
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/models/index.js
34872
34941
  var modelGateway = /* @__PURE__ */ __name((deps) => ({
34873
34942
  complete: /* @__PURE__ */ __name(async (request) => {
34874
34943
  if (deps.signal?.aborted)
@@ -34883,7 +34952,7 @@ var modelGateway = /* @__PURE__ */ __name((deps) => ({
34883
34952
  if (!adapter && target2.provider === "openai")
34884
34953
  adapter = openai;
34885
34954
  if (!adapter && target2.provider === "anthropic")
34886
- adapter = (await import("./anthropic-RIANJ7WM.js")).anthropic;
34955
+ adapter = (await import("./anthropic-N54MKE4C.js")).anthropic;
34887
34956
  if (!adapter)
34888
34957
  throw new CliError("validation_error", `no model adapter for ${target2.provider}`);
34889
34958
  if (request.images !== void 0 && adapter.images !== true)
@@ -34902,7 +34971,7 @@ var modelGateway = /* @__PURE__ */ __name((deps) => ({
34902
34971
  const apiKey = await deps.key?.(target2.provider, target2);
34903
34972
  if (deps.signal?.aborted)
34904
34973
  throw new CliError("cancelled", "model request cancelled");
34905
- const fetcher = deps.fetch ?? fetch;
34974
+ const fetcher = deps.fetch ?? endpointFetch(baseUrl, 12e4);
34906
34975
  let limited = false;
34907
34976
  let unreachable = false;
34908
34977
  let refused = false;
@@ -34943,7 +35012,7 @@ var modelGateway = /* @__PURE__ */ __name((deps) => ({
34943
35012
  }, "complete")
34944
35013
  }), "modelGateway");
34945
35014
 
34946
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/enrichment-setting.js
35015
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/enrichment-setting.js
34947
35016
  var SECTION2 = "enrichment";
34948
35017
  var ENRICHMENT_PROVIDERS = ["openai", "anthropic"];
34949
35018
  var DEFAULT_BASE_URLS = {
@@ -35018,7 +35087,7 @@ var costOf = /* @__PURE__ */ __name((usage, setting) => {
35018
35087
  return price ? Math.round((usage.input * price.input + usage.output * price.output) * 1e6) / 1e6 : null;
35019
35088
  }, "costOf");
35020
35089
 
35021
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/enrichment.js
35090
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/enrichment.js
35022
35091
  var ENRICH_PER_RUN = 600;
35023
35092
  var MAX_LINE = 400;
35024
35093
  var line2 = pipe(unknown(), transform((value) => typeof value === "string" ? value.replace(/\s+/g, " ").trim().slice(0, MAX_LINE) : ""));
@@ -35094,7 +35163,7 @@ var enrichmentState = /* @__PURE__ */ __name(async (store, env, estimateFor, key
35094
35163
  };
35095
35164
  }, "enrichmentState");
35096
35165
 
35097
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/notes-title-tier.js
35166
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/notes-title-tier.js
35098
35167
  var plainQueryWords = /* @__PURE__ */ __name((query) => {
35099
35168
  let root;
35100
35169
  try {
@@ -35121,7 +35190,7 @@ var titleTiers = /* @__PURE__ */ __name((hits, words3) => {
35121
35190
  return [...hits].sort((a, b) => rank(a) - rank(b));
35122
35191
  }, "titleTiers");
35123
35192
 
35124
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/notes-search.js
35193
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/notes-search.js
35125
35194
  var storeQuery = /* @__PURE__ */ __name(async (store, text2, { exact, timezone } = {}) => resolvedQuery(store, parsedQuery(text2, exact), timezone), "storeQuery");
35126
35195
  var parsedQuery = /* @__PURE__ */ __name((text2, exact) => validateFields(parseLucene(text2, { ...SEARCH_QUERY, defaultField: exact ? "exact" : "text" })).root, "parsedQuery");
35127
35196
  var resolvedQuery = /* @__PURE__ */ __name(async (store, root, timezone) => {
@@ -35509,12 +35578,13 @@ var searchNotes = /* @__PURE__ */ __name(async (store, query, { limit = 20, offs
35509
35578
  ...lane
35510
35579
  };
35511
35580
  }, "searchNotes");
35512
- var notesScopeOf = /* @__PURE__ */ __name((accounts) => {
35513
- const folderIds = accounts.map(({ account }) => account).filter((account) => account !== INTERNAL_NOTES);
35581
+ var notesScopeOf = /* @__PURE__ */ __name((accounts, stored = []) => {
35582
+ const folderIds = accounts.filter(({ provider, account }) => provider !== "notes" || account !== INTERNAL_NOTES).map(({ provider, account }) => provider === "notes" ? account : String(stored.find((one) => one.provider === provider && one.account === account)?.id ?? 0));
35514
35583
  if (!folderIds.length)
35515
35584
  return { source: "internal" };
35516
35585
  return { folderIds, ...accounts.length > folderIds.length ? { withInternal: true } : {} };
35517
35586
  }, "notesScopeOf");
35587
+ var importAccounts = /* @__PURE__ */ __name(async (store) => (await store.accounts.storedAccounts()).filter(({ provider }) => isImportedProvider(provider)), "importAccounts");
35518
35588
  var searchNotesOf = /* @__PURE__ */ __name(async (store, account, text2, { accounts: list3, app, env, ...query }) => {
35519
35589
  text2 = plainQuery(text2);
35520
35590
  const own = app?.command ?? query.command;
@@ -35523,30 +35593,33 @@ var searchNotesOf = /* @__PURE__ */ __name(async (store, account, text2, { accou
35523
35593
  { provider: "notes", account: INTERNAL_NOTES },
35524
35594
  ...(await store.notes.folders()).map(({ id: id2 }) => ({ provider: "notes", account: id2 })),
35525
35595
  ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => ({ provider: "notes", account: id2 })),
35526
- ...[await store.notes.addedAccount()].flatMap((added) => added ? [{ provider: "notes", account: added.id }] : [])
35596
+ ...[await store.notes.addedAccount()].flatMap((added) => added ? [{ provider: "notes", account: added.id }] : []),
35597
+ ...(await importAccounts(store)).map(({ provider, account: account2 }) => ({ provider, account: account2 }))
35527
35598
  ];
35528
35599
  const lock = groupLockOf(app, env);
35529
35600
  const typedScope = list3 ?? (lock === void 0 ? void 0 : `group:${lock}`);
35530
35601
  const notesScope = typedScope !== void 0 && /(^|,)\s*group:/i.test(typedScope) ? `${typedScope},${sourceOf2(OWNER_NOTES)}` : typedScope;
35531
35602
  const named2 = notesScope === void 0 ? { accounts: held, skipped: [] } : fitting(entriesOfList(notesScope, await listContextOf(store, account, app, void 0, env)), ["notes", "documents"], what);
35532
35603
  const source = query.source ?? noteSourceOfQuery(text2).source;
35533
- const typed = named2.accounts.filter(({ account: account2 }) => source === void 0 || account2 === INTERNAL_NOTES === (source === "internal"));
35604
+ const internal = /* @__PURE__ */ __name(({ provider, account: account2 }) => provider === "notes" && account2 === INTERNAL_NOTES, "internal");
35605
+ const typed = named2.accounts.filter((one) => source === void 0 || internal(one) === (source === "internal"));
35534
35606
  if (!typed.length && list3 !== void 0)
35535
35607
  throw new CliError("validation_error", source === "internal" ? "the query's source:internal keeps the notes written in memo, and the --source list names none of them: add notes:internal to --source, or drop source:internal from the query" : "the query's source:file keeps the files from notes folders, and the --source list names none of them: add notes:<folder id> to --source, or drop source:file from the query");
35536
- const scope = list3 === void 0 ? {} : notesScopeOf(typed);
35608
+ const scope = list3 === void 0 ? {} : notesScopeOf(typed, await store.accounts.storedAccounts());
35537
35609
  const found = await searchNotes(store, text2, {
35538
35610
  ...query,
35539
35611
  ...scope,
35540
- ...source ? { source } : {}
35612
+ ...source ? { source } : {},
35613
+ ...env === void 0 ? {} : { env }
35541
35614
  });
35542
35615
  return {
35543
35616
  ...found,
35544
- accounts: typed.map(({ account: account2 }) => ({ resource: "notes", provider: "notes", account: account2 })),
35617
+ accounts: typed.map(({ provider, account: account2 }) => ({ resource: "notes", provider, account: account2 })),
35545
35618
  skipped: named2.skipped
35546
35619
  };
35547
35620
  }, "searchNotesOf");
35548
35621
 
35549
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/events-search.js
35622
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/events-search.js
35550
35623
  var MAX_EVENTS_OFFSET = 1e3;
35551
35624
  var iso3 = /* @__PURE__ */ __name((at) => at === null ? null : new Date(at).toISOString(), "iso");
35552
35625
  var accountIdsOf = /* @__PURE__ */ __name(async (store, accounts) => {
@@ -35664,7 +35737,7 @@ var searchEvents = /* @__PURE__ */ __name(async (store, query, { limit = 20, off
35664
35737
  };
35665
35738
  }, "searchEvents");
35666
35739
 
35667
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-all-business.js
35740
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-all-business.js
35668
35741
  var OWN_BUSINESS = { provider: "business", account: INTERNAL_NOTES };
35669
35742
  var BUSINESS_WORDS_ONLY = "invoices, payments, orders, contracts, subscriptions, products and wallets are found by the words of their numbers and names only";
35670
35743
  var placeOf = /* @__PURE__ */ __name(({ source, imported }) => source ?? (imported === void 0 ? OWN_BUSINESS : { provider: imported, account: "" }), "placeOf");
@@ -35694,7 +35767,7 @@ var searchBusiness = /* @__PURE__ */ __name(async (store, { words: words3, anyWo
35694
35767
  };
35695
35768
  }, "searchBusiness");
35696
35769
 
35697
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-hit-search.js
35770
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-hit-search.js
35698
35771
  var resolveMeetingSelection = /* @__PURE__ */ __name(async (store, request) => {
35699
35772
  const { project, tag, topic, ...input } = request;
35700
35773
  input.signal?.throwIfAborted();
@@ -35732,7 +35805,7 @@ var resolveMeetingSelection = /* @__PURE__ */ __name(async (store, request) => {
35732
35805
  return { input, selection };
35733
35806
  }, "resolveMeetingSelection");
35734
35807
 
35735
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-all-meetings.js
35808
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-all-meetings.js
35736
35809
  var MOST_HITS_PER_MEETING = 3;
35737
35810
  var PAGE_ROWS = 200;
35738
35811
  var MOST_PAGES = 25;
@@ -35960,7 +36033,7 @@ var titleItem = /* @__PURE__ */ __name((account, meeting, query) => ({
35960
36033
  foundBy: ["title"]
35961
36034
  }), "titleItem");
35962
36035
 
35963
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-harder.js
36036
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-harder.js
35964
36037
  var SECTION3 = "search_harder";
35965
36038
  var HARDER_MODELS = {
35966
36039
  anthropic: "claude-haiku-5-5",
@@ -36206,7 +36279,7 @@ var reorderHarder = /* @__PURE__ */ __name(async (question, hits, { laterPage, a
36206
36279
  };
36207
36280
  }, "reorderHarder");
36208
36281
 
36209
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/search-all.js
36282
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/search-all.js
36210
36283
  var RESOURCES_SEARCHED = ["messages", "mail", "notes", "events", "crm", "business", "meetings"];
36211
36284
  var refusal = /* @__PURE__ */ __name((error, text2) => {
36212
36285
  const { reason, span } = error.details ?? {};
@@ -36248,9 +36321,11 @@ var sourceScope = /* @__PURE__ */ __name(async (store, account, source, asked, m
36248
36321
  const entries = entriesOfList(source, await listContextOf(store, account, messenger.app));
36249
36322
  const imported = asked.includes("business") ? new Set((await store.business.accounts()).map(accountKeyOf)) : /* @__PURE__ */ new Set();
36250
36323
  const holdsBusiness = /* @__PURE__ */ __name((one) => imported.has(accountKeyOf(one)), "holdsBusiness");
36251
- const { skipped } = fitting(entries, asked.filter((one) => one !== "business"), "search all", (kind) => `--only leaves ${kind} out`, holdsBusiness);
36324
+ const holdsDocuments = /* @__PURE__ */ __name((one) => asked.includes("notes") && holdsKind(one.provider, "documents"), "holdsDocuments");
36325
+ const { skipped } = fitting(entries, asked.filter((one) => one !== "business"), "search all", (kind) => `--only leaves ${kind} out`, (one) => holdsBusiness(one) || holdsDocuments(one));
36326
+ const holds = /* @__PURE__ */ __name((resource, one) => resource === "business" ? holdsBusiness(one) : listedHolds(one, resource) || resource === "notes" && holdsDocuments(one), "holds");
36252
36327
  const named2 = /* @__PURE__ */ __name((resource) => [
36253
- ...new Map(entries.flatMap(({ accounts }) => accounts).filter((one) => resource === "business" ? holdsBusiness(one) : listedHolds(one, resource)).map(({ provider, account: account2 }) => [`${provider}\0${account2}`, { provider, account: account2 }])).values()
36328
+ ...new Map(entries.flatMap(({ accounts }) => accounts).filter((one) => holds(resource, one)).map(({ provider, account: account2 }) => [`${provider}\0${account2}`, { provider, account: account2 }])).values()
36254
36329
  ], "named");
36255
36330
  const scope = Object.fromEntries(asked.map((resource) => [resource, named2(resource)]));
36256
36331
  const only = asked.filter((resource) => scope[resource]?.length);
@@ -36374,7 +36449,7 @@ var searchAll = /* @__PURE__ */ __name(async (store, account, asked, messenger =
36374
36449
  limit: depth,
36375
36450
  command,
36376
36451
  embedders,
36377
- ...chosen2 === void 0 ? {} : notesScopeOf(chosen2),
36452
+ ...chosen2 === void 0 ? {} : notesScopeOf(chosen2, await store.accounts.storedAccounts()),
36378
36453
  ...request.exact ? { exact: true } : {},
36379
36454
  ...discover ? { discover: true } : {},
36380
36455
  ...request.timezone === void 0 ? {} : { timezone: request.timezone },
@@ -36399,13 +36474,16 @@ var searchAll = /* @__PURE__ */ __name(async (store, account, asked, messenger =
36399
36474
  text: hit.excerpt,
36400
36475
  foundBy: hit.found_by
36401
36476
  })));
36402
- const read = chosen2?.map(({ account: account2 }) => account2) ?? [
36403
- INTERNAL_NOTES,
36404
- ...(await store.notes.folders()).map(({ id: id2 }) => id2),
36405
- ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => id2),
36406
- ...[await store.notes.addedAccount()].flatMap((added) => added ? [added.id] : [])
36477
+ const read = chosen2 ?? [
36478
+ ...[
36479
+ INTERNAL_NOTES,
36480
+ ...(await store.notes.folders()).map(({ id: id2 }) => id2),
36481
+ ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => id2),
36482
+ ...[await store.notes.addedAccount()].flatMap((added) => added ? [added.id] : [])
36483
+ ].map((account2) => ({ provider: "notes", account: account2 })),
36484
+ ...(await importAccounts(store)).map(({ provider, account: account2 }) => ({ provider, account: account2 }))
36407
36485
  ];
36408
- accounts.push(...read.map((account2) => ({ resource, provider: "notes", account: account2 })));
36486
+ accounts.push(...read.map(({ provider, account: account2 }) => ({ resource, provider, account: account2 })));
36409
36487
  } else if (resource === "events") {
36410
36488
  const read = scope?.events ?? await calendarAccounts(store);
36411
36489
  if (!read.length)
@@ -36583,7 +36661,7 @@ var insidePeriodFirst = /* @__PURE__ */ __name((ordered, period) => {
36583
36661
  return ordered.map((item2, rank) => ({ item: item2, score: 1 - rank / PERIOD_DEPTH + (inside2(item2) ? PERIOD_BOOST : 0) })).sort((a, b) => b.score - a.score).map(({ item: item2 }) => item2);
36584
36662
  }, "insidePeriodFirst");
36585
36663
 
36586
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/server-search.js
36664
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/server-search.js
36587
36665
  var SERVER_SEARCH_KEY = "messages.server-search";
36588
36666
  var SERVER_BOUNDS = { timeMs: 5e3, perCall: 100, maxCalls: 3, textBytes: 262144 };
36589
36667
  var DEFAULT_BACKEND = "both";
@@ -36772,7 +36850,7 @@ var searchServer = /* @__PURE__ */ __name(async (deps, request) => {
36772
36850
  return { report, sources };
36773
36851
  }, "searchServer");
36774
36852
 
36775
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/messages.js
36853
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/messages.js
36776
36854
  var DELETE_AT_ONCE = 10;
36777
36855
  var filesOf = /* @__PURE__ */ __name(({ attachments }) => {
36778
36856
  const files = fileLinks(attachments);
@@ -37212,7 +37290,7 @@ var checkMediaOptions = /* @__PURE__ */ __name((messenger, asked, attachments) =
37212
37290
  throw new CliError("validation_error", `${MEDIA_FLAGS[first2]} needs a --photo or --file`);
37213
37291
  }, "checkMediaOptions");
37214
37292
 
37215
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/domain/channel-tags.js
37293
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/domain/channel-tags.js
37216
37294
  var CHANNEL_TAG_RULES_VERSION = "keywords-v1";
37217
37295
  var RULES2 = {
37218
37296
  ai: [/\b(ai|gpt|llm|machine learning|artificial intelligence)\b/iu, /нейросет|искусственн/iu],
@@ -37227,7 +37305,7 @@ var classifyChannel = /* @__PURE__ */ __name((metadata) => Object.entries(RULES2
37227
37305
  return fields.length ? [{ tag, score: fields.length / 3, fields }] : [];
37228
37306
  }), "classifyChannel");
37229
37307
 
37230
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/metadata.js
37308
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/metadata.js
37231
37309
  var metadataService = /* @__PURE__ */ __name((deps) => {
37232
37310
  const held = /* @__PURE__ */ __name(async (reference, { includeLeft = false } = {}) => {
37233
37311
  const store = await deps.store();
@@ -37313,7 +37391,7 @@ var metadataService = /* @__PURE__ */ __name((deps) => {
37313
37391
  };
37314
37392
  }, "metadataService");
37315
37393
 
37316
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/moderation/run.js
37394
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/moderation/run.js
37317
37395
  var FIRST_LOOK_MS = 24 * 36e5;
37318
37396
  var moderateWith = /* @__PURE__ */ __name(async (run2) => {
37319
37397
  const { chatId, title, rules, point, since, dryRun } = run2;
@@ -37350,7 +37428,7 @@ var moderateWith = /* @__PURE__ */ __name(async (run2) => {
37350
37428
  return { chatId, rows, notes };
37351
37429
  }, "moderateWith");
37352
37430
 
37353
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/moderation.js
37431
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/moderation.js
37354
37432
  var moderationService = /* @__PURE__ */ __name((deps) => {
37355
37433
  const file2 = /* @__PURE__ */ __name(() => new ModerationRules(moderationPathFor(deps.messenger.app, deps.profile ?? "default", deps.env ?? process.env)), "file");
37356
37434
  const group = /* @__PURE__ */ __name(async (chat) => {
@@ -37428,7 +37506,7 @@ var moderatorOf = /* @__PURE__ */ __name((adapter, deps) => ({
37428
37506
  }, "removePerson")
37429
37507
  }), "moderatorOf");
37430
37508
 
37431
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/private-people.js
37509
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/private-people.js
37432
37510
  var noteItem = /* @__PURE__ */ __name((provider, note) => ({
37433
37511
  id: note.id,
37434
37512
  contact: formatReference({ type: "contact", provider, id: note.personId }),
@@ -37472,7 +37550,7 @@ var privatePeopleService = /* @__PURE__ */ __name((deps) => {
37472
37550
  };
37473
37551
  }, "privatePeopleService");
37474
37552
 
37475
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/rankings.js
37553
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/rankings.js
37476
37554
  var empty = /* @__PURE__ */ __name(() => ({
37477
37555
  total: 0,
37478
37556
  population: 0,
@@ -37728,7 +37806,7 @@ var rankingsService = /* @__PURE__ */ __name((deps) => ({
37728
37806
  }, "evidence")
37729
37807
  }), "rankingsService");
37730
37808
 
37731
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/reply-stats.js
37809
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/reply-stats.js
37732
37810
  var FIELDS = ["date", "chat", "kind", "muted"];
37733
37811
  var WAITING_TAIL = 100;
37734
37812
  var plainOnly = /* @__PURE__ */ __name((text2, command) => {
@@ -37862,7 +37940,7 @@ var replyStatsService = /* @__PURE__ */ __name((deps) => {
37862
37940
  };
37863
37941
  }, "replyStatsService");
37864
37942
 
37865
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/searches.js
37943
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/searches.js
37866
37944
  var savedSearchItem = /* @__PURE__ */ __name((one) => ({
37867
37945
  id: one.id,
37868
37946
  name: one.name,
@@ -37988,7 +38066,7 @@ var searchesService = /* @__PURE__ */ __name((deps) => {
37988
38066
  };
37989
38067
  }, "searchesService");
37990
38068
 
37991
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/tags.js
38069
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/tags.js
37992
38070
  var TAGGING_QUERY = {
37993
38071
  entity: "tagging",
37994
38072
  backend: "sql",
@@ -38072,7 +38150,7 @@ var tagsService = /* @__PURE__ */ __name((deps) => {
38072
38150
  };
38073
38151
  }, "tagsService");
38074
38152
 
38075
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/topics.js
38153
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/topics.js
38076
38154
  var actionOf = /* @__PURE__ */ __name(({ title, closed, pinned, hidden, icon }) => {
38077
38155
  const set = [closed, pinned, hidden].filter((one) => one !== void 0).length;
38078
38156
  if (title !== void 0 || icon !== void 0 || set !== 1)
@@ -38271,10 +38349,10 @@ var topicsService = /* @__PURE__ */ __name((deps) => {
38271
38349
  };
38272
38350
  }, "topicsService");
38273
38351
 
38274
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/crm/sync.js
38352
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/crm/sync.js
38275
38353
  var CLOCK_MARGIN = 60 * 6e4;
38276
38354
 
38277
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/crm/writer.js
38355
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/crm/writer.js
38278
38356
  var CRM_ASSIGN_OTHERS_KEY = "crm.assign-others";
38279
38357
  var CRM_WRITE_DEFAULTS = {
38280
38358
  "deals.delete": "ask",
@@ -38282,7 +38360,7 @@ var CRM_WRITE_DEFAULTS = {
38282
38360
  [CRM_ASSIGN_OTHERS_KEY]: "deny"
38283
38361
  };
38284
38362
 
38285
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/evidence.js
38363
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/evidence.js
38286
38364
  import { createHash as createHash11, randomUUID as randomUUID6 } from "node:crypto";
38287
38365
  var hash2 = /* @__PURE__ */ __name((value) => createHash11("sha256").update(JSON.stringify(value)).digest("hex"), "hash");
38288
38366
  var positive2 = /* @__PURE__ */ __name((value, name, minimum = 1) => {
@@ -38356,7 +38434,7 @@ var prepareEvidencePacket = /* @__PURE__ */ __name(({ kind, source, page, limits
38356
38434
  return { ...content, id: randomUUID6(), fingerprint: hash2(content) };
38357
38435
  }, "prepareEvidencePacket");
38358
38436
 
38359
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/evidence-read.js
38437
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/evidence-read.js
38360
38438
  var readEvidencePacket = /* @__PURE__ */ __name(async (store, account, { chat, limit, before: before2 }, messenger = {}) => {
38361
38439
  if (!Number.isSafeInteger(limit) || limit < 1 || limit > 100)
38362
38440
  throw new CliError("validation_error", "evidence message limit must be an integer from 1 to 100");
@@ -38376,7 +38454,7 @@ var readEvidencePacket = /* @__PURE__ */ __name(async (store, account, { chat, l
38376
38454
  return { ...packet, nextBeforeId: older && last ? last.id : null };
38377
38455
  }, "readEvidencePacket");
38378
38456
 
38379
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-project-discovery.js
38457
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-project-discovery.js
38380
38458
  var scopeKeys = [
38381
38459
  "accountId",
38382
38460
  "meetingId",
@@ -38398,7 +38476,7 @@ var optionKeys = /* @__PURE__ */ new Set([
38398
38476
  "maxVocabularyReadBytes"
38399
38477
  ]);
38400
38478
 
38401
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/text-model-choice.js
38479
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/text-model-choice.js
38402
38480
  import { createHash as createHash12 } from "node:crypto";
38403
38481
  import { existsSync as existsSync3 } from "node:fs";
38404
38482
  var useTextModel = /* @__PURE__ */ __name(async (id2, { env, command }) => {
@@ -38529,7 +38607,7 @@ var addCustomTextModel = /* @__PURE__ */ __name(async (id2, payload, { env, fetc
38529
38607
  return { ...checked2.output, custom: true };
38530
38608
  }, "addCustomTextModel");
38531
38609
 
38532
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/context/communication-selection.js
38610
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/context/communication-selection.js
38533
38611
  var communicationFields = {
38534
38612
  sources: pipe(array(strictObject({
38535
38613
  id: pipe(string(), regex(/^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$/)),
@@ -38561,7 +38639,7 @@ var communicationRequest = /* @__PURE__ */ __name((value, preparationAfter) => {
38561
38639
  return { ...input, after, before: before2 };
38562
38640
  }, "communicationRequest");
38563
38641
 
38564
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-preparation-validation.js
38642
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-preparation-validation.js
38565
38643
  var MEETING_PREPARATION_LIMITS = {
38566
38644
  meetings: { min: 1, max: 20, default: 5 },
38567
38645
  cues: { min: 1, max: 100, default: 10 },
@@ -38634,7 +38712,7 @@ var validateMeetingPreparationRequest = /* @__PURE__ */ __name((externalId, orig
38634
38712
  };
38635
38713
  }, "validateMeetingPreparationRequest");
38636
38714
 
38637
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/meeting-communications-selection.js
38715
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/meeting-communications-selection.js
38638
38716
  var validatePreparationCommunications = /* @__PURE__ */ __name((section, request, after) => {
38639
38717
  const fail2 = /* @__PURE__ */ __name(() => {
38640
38718
  throw new CliError("invalid_response", "Preparation communications returned another selection or invalid evidence");
@@ -38682,7 +38760,7 @@ var validatePreparationCommunications = /* @__PURE__ */ __name((section, request
38682
38760
  }
38683
38761
  }, "validatePreparationCommunications");
38684
38762
 
38685
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/package-upgrade.js
38763
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/package-upgrade.js
38686
38764
  var upgradePackage = /* @__PURE__ */ __name(async ({ current, command, packageName, check: check2 }, ports) => {
38687
38765
  const installer = ports.installer();
38688
38766
  const argv = updateCommand(installer, packageName);
@@ -38747,7 +38825,7 @@ var dayAfter = /* @__PURE__ */ __name((published) => {
38747
38825
  return Number.isNaN(time) ? null : new Date(time + 24 * 60 * 60 * 1e3).toISOString();
38748
38826
  }, "dayAfter");
38749
38827
 
38750
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/services/index.js
38828
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/services/index.js
38751
38829
  var servicesFor = /* @__PURE__ */ __name((deps) => {
38752
38830
  const pictures = picturesService(deps);
38753
38831
  const base = {
@@ -38784,7 +38862,7 @@ var servicesFor = /* @__PURE__ */ __name((deps) => {
38784
38862
  return deps.messenger.services ? { ...base, ...deps.messenger.services(base, deps) } : base;
38785
38863
  }, "servicesFor");
38786
38864
 
38787
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/background/relay.js
38865
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/background/relay.js
38788
38866
  import { createHash as createHash13 } from "node:crypto";
38789
38867
  import { chmodSync, lstatSync, mkdirSync as mkdirSync6, rmSync as rmSync3 } from "node:fs";
38790
38868
  import { createConnection, createServer } from "node:net";
@@ -39005,7 +39083,7 @@ var relayCommand = /* @__PURE__ */ __name((path, request, options2) => new Promi
39005
39083
  }, () => finish({ error: stopped() }));
39006
39084
  }), "relayCommand");
39007
39085
 
39008
- // node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-relay.js
39086
+ // node_modules/.pnpm/@wirecat+cli-core@0.650.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.99.0_commander@15._f55ccfac747d9da64edfb69ea8dcc45a/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-relay.js
39009
39087
  var lentConnection = /* @__PURE__ */ __name((connection, watchers) => throughWrapper(connection, {
39010
39088
  close: /* @__PURE__ */ __name(async () => {
39011
39089
  }, "close"),