@wirecat/zoom-cli 0.68.0 → 0.69.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 (122) hide show
  1. package/dist/bin/zm.js +2 -2
  2. package/dist/bundle/{all-profiles-R66UM3HM.js → all-profiles-ZQWPCJEK.js} +7 -7
  3. package/dist/bundle/{answer-policy-UCGUO53A.js → answer-policy-VBDYLUXI.js} +52 -52
  4. package/dist/bundle/{anthropic-4ZI2BPLG.js → anthropic-7FUQ2HYJ.js} +3 -3
  5. package/dist/bundle/{app-server-64O5IQI5.js → app-server-DNPE2EQB.js} +46 -46
  6. package/dist/bundle/{bun-HUHQD76Z.js → bun-ZVQFCFCC.js} +2 -2
  7. package/dist/bundle/{bun-sqlite-VOVHPTIF.js → bun-sqlite-EB2UMUPJ.js} +2 -2
  8. package/dist/bundle/{chunk-EZRPSZJS.js → chunk-2SYWVIQJ.js} +1 -1
  9. package/dist/bundle/chunk-37B7A4RP.js +66 -0
  10. package/dist/bundle/{chunk-YJY3W2ZT.js → chunk-3TPRYZUW.js} +18 -15
  11. package/dist/bundle/{chunk-K67V24AT.js → chunk-4APZQYCH.js} +3 -3
  12. package/dist/bundle/{chunk-7QNJICKZ.js → chunk-52DCABMU.js} +23 -23
  13. package/dist/bundle/{chunk-KUB2U5NT.js → chunk-5GOE6PQK.js} +5 -5
  14. package/dist/bundle/{chunk-77KFLU5F.js → chunk-5H6VTEEC.js} +2 -2
  15. package/dist/bundle/{chunk-PIHBD3YS.js → chunk-5ZF6QVMC.js} +4 -4
  16. package/dist/bundle/{chunk-FMQS7HCC.js → chunk-5ZJXKASF.js} +249 -8
  17. package/dist/bundle/chunk-6AMMTXEA.js +12473 -0
  18. package/dist/bundle/{chunk-SRP6SFFD.js → chunk-6KMTQX3D.js} +1 -1
  19. package/dist/bundle/{chunk-2T6XHWDX.js → chunk-6N2D6JGX.js} +1 -1
  20. package/dist/bundle/{chunk-R7LFGEDE.js → chunk-6TICX3MN.js} +2 -2
  21. package/dist/bundle/{chunk-W42BJ65M.js → chunk-B5D7NZI7.js} +1 -1
  22. package/dist/bundle/{chunk-EWIBLDQQ.js → chunk-C6TEYKXV.js} +6 -6
  23. package/dist/bundle/{chunk-32FPA7P2.js → chunk-CKK6JOC4.js} +1 -1
  24. package/dist/bundle/{chunk-JRCYFCPL.js → chunk-CUZHKYC2.js} +19 -19
  25. package/dist/bundle/{chunk-355PHJYX.js → chunk-DHD25JII.js} +1 -1
  26. package/dist/bundle/{chunk-PUTGTW6W.js → chunk-EPPSMCEV.js} +1 -1
  27. package/dist/bundle/{chunk-AYEVBAGO.js → chunk-F5DYBWH7.js} +143 -22
  28. package/dist/bundle/{chunk-AJ7CMUGD.js → chunk-G6IX2MD2.js} +172 -143
  29. package/dist/bundle/{chunk-VLD7Y4SY.js → chunk-GR3QDHBU.js} +4 -4
  30. package/dist/bundle/{chunk-DGNPJGD3.js → chunk-GXDOTUUO.js} +8 -14
  31. package/dist/bundle/{chunk-5JAYUG3X.js → chunk-H3MFBYTQ.js} +2 -2
  32. package/dist/bundle/{chunk-TDGZMC6K.js → chunk-HC56J5LB.js} +57 -53
  33. package/dist/bundle/{chunk-4YFJYSSK.js → chunk-HSI7YOYK.js} +45 -29
  34. package/dist/bundle/{chunk-LYWUG43B.js → chunk-HW5QTRFF.js} +31 -31
  35. package/dist/bundle/{chunk-65T3PU75.js → chunk-IEC4E65G.js} +1 -1
  36. package/dist/bundle/{chunk-L4WVLRXM.js → chunk-IPBZKUC3.js} +3 -3
  37. package/dist/bundle/{chunk-TN3FH2GQ.js → chunk-JHFP3Z5S.js} +7 -7
  38. package/dist/bundle/{chunk-3BRV2YU2.js → chunk-JX5JJZC3.js} +2 -2
  39. package/dist/bundle/{chunk-YTF2WPV4.js → chunk-JZ4YOAHA.js} +679 -496
  40. package/dist/bundle/{chunk-474WF55M.js → chunk-KX5MZVPX.js} +38 -25
  41. package/dist/bundle/{chunk-TUNQ6NE2.js → chunk-L62EJDNZ.js} +2 -2
  42. package/dist/bundle/{chunk-6TJ62LZQ.js → chunk-LDRQ5NAP.js} +3 -3
  43. package/dist/bundle/{chunk-7DUYFITC.js → chunk-LEA4BGK7.js} +9 -9
  44. package/dist/bundle/{chunk-P2TISY3R.js → chunk-LQX74VKG.js} +1 -1
  45. package/dist/bundle/{chunk-RP3U3J53.js → chunk-MJMVIFSC.js} +6 -6
  46. package/dist/bundle/{chunk-A63ZFOQJ.js → chunk-MNOVYS43.js} +3 -3
  47. package/dist/bundle/{chunk-YQRNFG2E.js → chunk-MOTKS7XG.js} +7176 -13499
  48. package/dist/bundle/{chunk-6T3P226D.js → chunk-MSDCZ6GT.js} +4 -4
  49. package/dist/bundle/{chunk-DVA6MQWK.js → chunk-MVDPZRFE.js} +1 -1
  50. package/dist/bundle/{chunk-LBOSTBAY.js → chunk-O7L44JK2.js} +2031 -1900
  51. package/dist/bundle/{chunk-Y5LP5SHV.js → chunk-OSBHEM2A.js} +9 -9
  52. package/dist/bundle/{chunk-RRYUD2EF.js → chunk-QLGG7S6F.js} +2 -2
  53. package/dist/bundle/{chunk-ZRD3NDOX.js → chunk-QW5VPZEH.js} +1 -1
  54. package/dist/bundle/{chunk-LV7QRR5S.js → chunk-QXM7S3Y3.js} +5 -5
  55. package/dist/bundle/{chunk-US5C3WAY.js → chunk-R2ULMWB4.js} +27 -27
  56. package/dist/bundle/{chunk-QXTREL2M.js → chunk-R3JYPY3J.js} +2 -2
  57. package/dist/bundle/{chunk-JO4YADNV.js → chunk-RPQ3JOD3.js} +3 -3
  58. package/dist/bundle/{chunk-4TLPOY22.js → chunk-S2EAGDS7.js} +10 -10
  59. package/dist/bundle/{chunk-SSPSNSC5.js → chunk-SQT47CFW.js} +1 -1
  60. package/dist/bundle/{chunk-HXOAPH47.js → chunk-SZ3Z4ZNO.js} +1 -1
  61. package/dist/bundle/{chunk-DWSUSWAX.js → chunk-T5X4LGXE.js} +130 -11
  62. package/dist/bundle/{chunk-2OSBCYJT.js → chunk-TFFEFEG2.js} +16 -16
  63. package/dist/bundle/{chunk-EH5QGQFR.js → chunk-TKXLWFM2.js} +2 -2
  64. package/dist/bundle/{chunk-AVEIQMHZ.js → chunk-TN77LX6W.js} +1 -1
  65. package/dist/bundle/{chunk-77I67HWF.js → chunk-TWIC6JJG.js} +7 -7
  66. package/dist/bundle/{chunk-TZUKDM72.js → chunk-UEZ6URJR.js} +10 -10
  67. package/dist/bundle/{chunk-EJDV5IIF.js → chunk-V4MM6GST.js} +1 -1
  68. package/dist/bundle/{chunk-BSM43OMN.js → chunk-V74QFMSL.js} +1 -1
  69. package/dist/bundle/{chunk-6CJ7NHIP.js → chunk-WY4NYPPS.js} +12 -12
  70. package/dist/bundle/{chunk-FNQASORM.js → chunk-XITUFTON.js} +1 -1
  71. package/dist/bundle/{chunk-GOXDBCDM.js → chunk-XJBYGMZ4.js} +107 -63
  72. package/dist/bundle/{chunk-UU5PLDRA.js → chunk-XRZDYWF6.js} +2 -2
  73. package/dist/bundle/{chunk-6XO7RTJY.js → chunk-Z6TTGTMU.js} +92 -5
  74. package/dist/bundle/{chunk-UDJTRFRV.js → chunk-ZRHMB3LQ.js} +1 -1
  75. package/dist/bundle/{cli-VQJ7ZRYR.js → cli-P3BZUE6S.js} +67 -53
  76. package/dist/bundle/command-contract-TOLB32NJ.js +41 -0
  77. package/dist/bundle/config-4KLLIADY.js +90 -0
  78. package/dist/bundle/{decode-L3ENO2XH.js → decode-QWOQXM7M.js} +2 -2
  79. package/dist/bundle/{dist-WQLS7U23.js → dist-OUE4MF37.js} +79 -19
  80. package/dist/bundle/{echarts-5LLJ6JXC.js → echarts-65IMPY43.js} +2 -2
  81. package/dist/bundle/{embed-37MYTCU7.js → embed-4IULBCKL.js} +3 -3
  82. package/dist/bundle/{embedder-GNGHVJAO.js → embedder-JW4W6IZI.js} +6 -6
  83. package/dist/bundle/{first-run-NR5JKYP3.js → first-run-CH6C674R.js} +5 -5
  84. package/dist/bundle/first-screen-OCAW5ZN6.js +39 -0
  85. package/dist/bundle/{instructions-P72XX4AK.js → instructions-G5QIH2TM.js} +1 -1
  86. package/dist/bundle/{main-QYFCYSTW.js → main-O4ZJIEWP.js} +12 -12
  87. package/dist/bundle/{meetings-66UQINKI.js → meetings-77CCAVYD.js} +1 -1
  88. package/dist/bundle/{node-ZB4RNICS.js → node-E6VQHU4Y.js} +2 -2
  89. package/dist/bundle/{node-sqlite-XPRKBDF3.js → node-sqlite-RJZ4PGLD.js} +3 -3
  90. package/dist/bundle/{oauth-WJRDUU5J.js → oauth-F4JKNRW4.js} +4 -4
  91. package/dist/bundle/{open-S2YSIEOW.js → open-NYOGMIAA.js} +2 -2
  92. package/dist/bundle/{openai-CRNZFNZD.js → openai-5U6EQTFQ.js} +8 -8
  93. package/dist/bundle/{process-XNN4WG6N.js → process-OBWUKBMX.js} +1 -1
  94. package/dist/bundle/{program-BRPJKRCX.js → program-MU7DEJTO.js} +61 -61
  95. package/dist/bundle/{prompt-7RQOL25I.js → prompt-2QWQTHWT.js} +2 -2
  96. package/dist/bundle/{recognize-N5WADGQB.js → recognize-SNUNTUC3.js} +1 -1
  97. package/dist/bundle/{remote-WHYV35IF.js → remote-2CTCIQGF.js} +4 -4
  98. package/dist/bundle/{rerank-FBMZVWSH.js → rerank-XDA7NJNH.js} +4 -4
  99. package/dist/bundle/{run-log-TOCHREH2.js → run-log-NSG3DJVX.js} +50 -50
  100. package/dist/bundle/{serve-4BABX4WS.js → serve-TWQFHOV2.js} +6 -6
  101. package/dist/bundle/{server-CDVI6LOB.js → server-RIQ6HMH2.js} +38 -38
  102. package/dist/bundle/server-XO6XQQTJ.js +72 -0
  103. package/dist/bundle/{services-PIY33I7R.js → services-NKZQJQIV.js} +30 -24
  104. package/dist/bundle/{speech-LS5Q4FL2.js → speech-ZOB76SXA.js} +10 -10
  105. package/dist/bundle/{state-YUX5R2R7.js → state-7YYEIXQ5.js} +3 -3
  106. package/dist/bundle/{store-BD7HAXAA.js → store-E6RTSSNR.js} +21 -12
  107. package/dist/bundle/{store-ERMGBF2B.js → store-OX4HRBLO.js} +45 -14
  108. package/dist/bundle/store-connection-55QPNUDS.js +83 -0
  109. package/dist/bundle/store-maintenance-command-Q5MSU6OK.js +62 -0
  110. package/dist/bundle/zm.js +2 -2
  111. package/dist/bundle/{zoom-app-XJXZ4ZBX.js → zoom-app-TSI2MGVK.js} +2 -2
  112. package/dist/version.d.ts +1 -1
  113. package/dist/version.js +1 -1
  114. package/package.json +2 -2
  115. package/dist/bundle/chunk-NUJMJQXV.js +0 -787
  116. package/dist/bundle/chunk-YOAEZSDG.js +0 -22
  117. package/dist/bundle/command-contract-JPUWWYIV.js +0 -41
  118. package/dist/bundle/config-YGLLR77A.js +0 -90
  119. package/dist/bundle/first-screen-RCR7ATO2.js +0 -39
  120. package/dist/bundle/server-XOFQKFVO.js +0 -72
  121. package/dist/bundle/store-connection-JBR6CMTJ.js +0 -83
  122. package/dist/bundle/store-maintenance-command-I5DUSO2C.js +0 -62
@@ -8,7 +8,7 @@ import {
8
8
  sameOrdinaryFile,
9
9
  syncDirectory,
10
10
  writeFileAtomic
11
- } from "./chunk-6CJ7NHIP.js";
11
+ } from "./chunk-WY4NYPPS.js";
12
12
  import {
13
13
  isNewer,
14
14
  updateCommand
@@ -20,6 +20,7 @@ import {
20
20
  chatReferenceOf,
21
21
  defaultRules,
22
22
  ensureAccount,
23
+ envelopeOfVcard,
23
24
  gather,
24
25
  isId,
25
26
  judge,
@@ -30,7 +31,7 @@ import {
30
31
  someUndone,
31
32
  validateFormattedText,
32
33
  visibleFormattedText
33
- } from "./chunk-FMQS7HCC.js";
34
+ } from "./chunk-5ZJXKASF.js";
34
35
  import {
35
36
  DEFAULT_IMAGE_MODEL,
36
37
  DEFAULT_RERANK_MODEL,
@@ -58,10 +59,7 @@ import {
58
59
  typedCommand,
59
60
  vectorModelKey,
60
61
  withAttempt
61
- } from "./chunk-JRCYFCPL.js";
62
- import {
63
- isCliFailure
64
- } from "./chunk-YOAEZSDG.js";
62
+ } from "./chunk-CUZHKYC2.js";
65
63
  import {
66
64
  AGENDA_COLUMNS,
67
65
  CHAT_COLUMNS,
@@ -82,6 +80,7 @@ import {
82
80
  QUERY_LIMITS,
83
81
  QUERY_VERSION,
84
82
  SEARCH_QUERY,
83
+ SOURCE_REVIEW_KIND,
85
84
  TASK_CLOSE_KIND,
86
85
  TASK_RELATION_KINDS,
87
86
  TRACKED_CHAT_COLUMNS,
@@ -106,10 +105,7 @@ import {
106
105
  entriesOfList,
107
106
  exhausted,
108
107
  fetchedKey,
109
- findMentions,
110
108
  fitting,
111
- googleDocumentId,
112
- googleDocumentLinks,
113
109
  hasStems,
114
110
  hasText,
115
111
  historyStartKey,
@@ -120,6 +116,7 @@ import {
120
116
  isOwnerOnlyKind,
121
117
  isQueryLimit,
122
118
  isStemmed,
119
+ listedHolds,
123
120
  matchDownloads,
124
121
  mayDecide,
125
122
  messageOfEmail,
@@ -135,14 +132,15 @@ import {
135
132
  threadConversation,
136
133
  validateAst,
137
134
  validateFields,
135
+ waitingPointer,
138
136
  withoutField
139
- } from "./chunk-YQRNFG2E.js";
137
+ } from "./chunk-MOTKS7XG.js";
140
138
  import {
141
139
  DEFAULT_STEMMERS,
142
140
  createStemmer,
143
141
  fold,
144
142
  normalize
145
- } from "./chunk-77I67HWF.js";
143
+ } from "./chunk-TWIC6JJG.js";
146
144
  import {
147
145
  COUNTER_FIELDS,
148
146
  INTERNAL_NOTES,
@@ -151,13 +149,20 @@ import {
151
149
  counterFreshness,
152
150
  counterObservationTime,
153
151
  envelopeErrors,
152
+ findMentions,
154
153
  formatLocator,
155
154
  formatReference,
155
+ googleDocumentId,
156
+ googleDocumentLinks,
157
+ headerErrors,
158
+ holdsKind,
159
+ holdsKindOf,
156
160
  isFolderProvider,
161
+ isImportedProvider,
157
162
  isKind,
158
163
  isLocator,
164
+ jsonLine,
159
165
  kindIn,
160
- kindOf,
161
166
  parseLocator,
162
167
  parseReference,
163
168
  pointerOf,
@@ -165,30 +170,35 @@ import {
165
170
  rankingOptions,
166
171
  rankingQuestion,
167
172
  recordErrors
168
- } from "./chunk-NUJMJQXV.js";
173
+ } from "./chunk-6AMMTXEA.js";
169
174
  import {
170
175
  TASK_KINDS,
171
176
  TASK_ORIGINS,
172
177
  TASK_STATES,
173
178
  createTaskService,
174
179
  isClosedState
175
- } from "./chunk-DWSUSWAX.js";
180
+ } from "./chunk-T5X4LGXE.js";
181
+ import {
182
+ isCliFailure,
183
+ sqliteCode
184
+ } from "./chunk-37B7A4RP.js";
176
185
  import {
177
186
  DEFAULT_TASK_CATEGORIES,
178
187
  FALLBACK_CATEGORY
179
- } from "./chunk-VLD7Y4SY.js";
188
+ } from "./chunk-GR3QDHBU.js";
180
189
  import {
190
+ isUsable,
181
191
  normalizeTag
182
- } from "./chunk-AYEVBAGO.js";
192
+ } from "./chunk-F5DYBWH7.js";
183
193
  import {
184
194
  MAX_MODEL_IMAGE_BYTES
185
- } from "./chunk-ZRD3NDOX.js";
195
+ } from "./chunk-QW5VPZEH.js";
186
196
  import {
187
197
  OPENAI_URL,
188
198
  openRemote,
189
199
  remoteKey,
190
200
  remoteModel
191
- } from "./chunk-3BRV2YU2.js";
201
+ } from "./chunk-JX5JJZC3.js";
192
202
  import {
193
203
  Unzip,
194
204
  UnzipInflate,
@@ -199,15 +209,15 @@ import {
199
209
  placedText,
200
210
  runEmbedders,
201
211
  textModelsDirectory
202
- } from "./chunk-KUB2U5NT.js";
212
+ } from "./chunk-5GOE6PQK.js";
203
213
  import {
204
214
  installFiles,
205
215
  megabytes
206
- } from "./chunk-6TJ62LZQ.js";
216
+ } from "./chunk-LDRQ5NAP.js";
207
217
  import {
208
218
  storePath,
209
219
  wirecatDirectory
210
- } from "./chunk-32FPA7P2.js";
220
+ } from "./chunk-CKK6JOC4.js";
211
221
  import {
212
222
  MEETING_FIELD_NAMES,
213
223
  MEETING_FINDINGS_KIND,
@@ -227,7 +237,7 @@ import {
227
237
  validateMeetingHitSearch,
228
238
  validateMeetingPassage,
229
239
  validateMeetingSeriesHistory
230
- } from "./chunk-TDGZMC6K.js";
240
+ } from "./chunk-HC56J5LB.js";
231
241
  import {
232
242
  OPERATORS_BY_TYPE,
233
243
  dateRange,
@@ -16882,7 +16892,7 @@ var require_lib3 = __commonJS({
16882
16892
  }
16883
16893
  });
16884
16894
 
16885
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/deps.js
16895
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/deps.js
16886
16896
  var accountStore = /* @__PURE__ */ __name(async (deps) => (await deps.store()).forAccount(await deps.account()), "accountStore");
16887
16897
  var crossAccount = /* @__PURE__ */ __name((deps, _reason) => deps.store(), "crossAccount");
16888
16898
  var NO_LOCAL_STORE = "this answer comes from the messenger, not from the local store";
@@ -16890,9 +16900,7 @@ var SQLITE_BUSY = 5;
16890
16900
  var storeAbsent = /* @__PURE__ */ __name((error) => {
16891
16901
  if (isCliFailure(error))
16892
16902
  return error.code === "validation_error" && error.message === NO_LOCAL_STORE;
16893
- const { errcode, errno } = error ?? {};
16894
- const code = errcode ?? errno;
16895
- return error instanceof Error && typeof code === "number" && (code & 255) === SQLITE_BUSY;
16903
+ return error instanceof Error && sqliteCode(error) === SQLITE_BUSY;
16896
16904
  }, "storeAbsent");
16897
16905
  var accountUnknown = /* @__PURE__ */ __name((error) => isCliFailure(error) && (error.code === "not_found" || error.code === "authentication_error"), "accountUnknown");
16898
16906
  var unless = /* @__PURE__ */ __name(async (work, expected2) => {
@@ -16959,7 +16967,7 @@ var storeOnlyDeps = /* @__PURE__ */ __name((store, account2, { app, env }) => {
16959
16967
  return { ...storedDeps(messenger, store, account2, guard), ...env === void 0 ? {} : { env } };
16960
16968
  }, "storeOnlyDeps");
16961
16969
 
16962
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/botcheck/check.js
16970
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/botcheck/check.js
16963
16971
  var DAY_MS = 864e5;
16964
16972
  var NEW_DAYS = 30;
16965
16973
  var SAME_TEXT_MIN = 20;
@@ -17036,7 +17044,7 @@ var scorePerson = /* @__PURE__ */ __name(({ subject, provider, activity, photos,
17036
17044
  };
17037
17045
  }, "scorePerson");
17038
17046
 
17039
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/http/time-limit.js
17047
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/http/time-limit.js
17040
17048
  var timeLimit = /* @__PURE__ */ __name((ms) => {
17041
17049
  const controller = new AbortController();
17042
17050
  const timer = setTimeout(() => controller.abort(new DOMException("The operation timed out.", "TimeoutError")), ms);
@@ -17052,7 +17060,7 @@ var withTimeLimit = /* @__PURE__ */ __name(async (ms, run) => {
17052
17060
  }
17053
17061
  }, "withTimeLimit");
17054
17062
 
17055
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/botcheck/registries.js
17063
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/botcheck/registries.js
17056
17064
  var REGISTRIES = {
17057
17065
  cas: { title: "Combot Anti-Spam (CAS)", docs: "https://cas.chat/api" },
17058
17066
  lols: { title: "lols.bot", docs: "https://api.lols.bot/lols-bot.json" }
@@ -17139,7 +17147,7 @@ var notCovered = /* @__PURE__ */ __name((messenger, now = /* @__PURE__ */ new Da
17139
17147
  detail: `lists Telegram accounts only, not ${messenger} ones`
17140
17148
  })), "notCovered");
17141
17149
 
17142
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/botcheck/service.js
17150
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/botcheck/service.js
17143
17151
  var ACTIVITY_MESSAGES = 1e3;
17144
17152
  var botCheckService = /* @__PURE__ */ __name((deps) => {
17145
17153
  const subjectOf = /* @__PURE__ */ __name(async (reference) => {
@@ -17227,7 +17235,7 @@ var botCheckService = /* @__PURE__ */ __name((deps) => {
17227
17235
  };
17228
17236
  }, "botCheckService");
17229
17237
 
17230
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/mail/owed.js
17238
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/mail/owed.js
17231
17239
  var mailTurn = /* @__PURE__ */ __name((newest) => {
17232
17240
  if (newest === null)
17233
17241
  return null;
@@ -17236,7 +17244,7 @@ var mailTurn = /* @__PURE__ */ __name((newest) => {
17236
17244
  return newest.addressed ? "owed" : null;
17237
17245
  }, "mailTurn");
17238
17246
 
17239
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/agenda-mail.js
17247
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/agenda-mail.js
17240
17248
  var absent = /* @__PURE__ */ __name((error) => {
17241
17249
  if (error instanceof CliError && error.code === "not_found")
17242
17250
  return void 0;
@@ -17294,7 +17302,7 @@ var mailActivity = /* @__PURE__ */ __name(async (store, account2, since, chats)
17294
17302
  };
17295
17303
  }, "mailActivity");
17296
17304
 
17297
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/chat-coverage.js
17305
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/chat-coverage.js
17298
17306
  var chatCoverage = /* @__PURE__ */ __name(async (store, account2, chatIds) => {
17299
17307
  const ids = [...new Set(chatIds)];
17300
17308
  if (ids.length === 0)
@@ -17320,7 +17328,7 @@ var chatCoverage = /* @__PURE__ */ __name(async (store, account2, chatIds) => {
17320
17328
  }));
17321
17329
  }, "chatCoverage");
17322
17330
 
17323
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/thread.js
17331
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/thread.js
17324
17332
  var threadIdOf = /* @__PURE__ */ __name((value) => {
17325
17333
  if (value === void 0)
17326
17334
  return void 0;
@@ -17330,7 +17338,7 @@ var threadIdOf = /* @__PURE__ */ __name((value) => {
17330
17338
  return id2;
17331
17339
  }, "threadIdOf");
17332
17340
 
17333
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/ports/messenger.js
17341
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/ports/messenger.js
17334
17342
  var throughWrapper = /* @__PURE__ */ __name((inner, handled, wrap = (_, call) => call) => new Proxy(handled, {
17335
17343
  get: /* @__PURE__ */ __name((own, key) => {
17336
17344
  if (key in own)
@@ -17347,15 +17355,15 @@ var capability = /* @__PURE__ */ __name((adapter, method, what) => {
17347
17355
  return found.bind(adapter);
17348
17356
  }, "capability");
17349
17357
 
17350
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/ports/traits.js
17358
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/ports/traits.js
17351
17359
  var syncsOneChat = /* @__PURE__ */ __name((messenger) => messenger.history !== "store" || messenger.historyOnDemand === true, "syncsOneChat");
17352
17360
 
17353
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/sends/send-id.js
17361
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/sends/send-id.js
17354
17362
  import { randomBytes } from "node:crypto";
17355
17363
  var newSendId = /* @__PURE__ */ __name(() => randomBytes(8).readBigInt64BE().toString(), "newSendId");
17356
17364
  var newOperationId = newSendId;
17357
17365
 
17358
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/questions.js
17366
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/questions.js
17359
17367
  var LINKS = /https?:\/\/\S+/g;
17360
17368
  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");
17361
17369
  var questions = /* @__PURE__ */ __name((messages, { answerers: answerers2, asker = "others" }) => {
@@ -17385,7 +17393,7 @@ var questions = /* @__PURE__ */ __name((messages, { answerers: answerers2, asker
17385
17393
  });
17386
17394
  }, "questions");
17387
17395
 
17388
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/chat-stats.js
17396
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/chat-stats.js
17389
17397
  var TOP_POSTS = 5;
17390
17398
  var JOINS = /* @__PURE__ */ new Set(["join", "add"]);
17391
17399
  var LEAVES = /* @__PURE__ */ new Set(["leave", "remove"]);
@@ -17502,7 +17510,7 @@ var median = /* @__PURE__ */ __name((values) => {
17502
17510
  return Math.round(sorted.length % 2 === 0 ? ((sorted[middle - 1] ?? upper) + upper) / 2 : upper);
17503
17511
  }, "median");
17504
17512
 
17505
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/member-history.js
17513
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/member-history.js
17506
17514
  var memberEvents = /* @__PURE__ */ __name((stays, revisions, since = 0) => {
17507
17515
  const events = [];
17508
17516
  for (const stay of stays) {
@@ -17534,7 +17542,7 @@ var memberEvents = /* @__PURE__ */ __name((stays, revisions, since = 0) => {
17534
17542
  return events.filter(({ at }) => Date.parse(at) >= since).sort((a, b) => Date.parse(a.at) - Date.parse(b.at) || a.id.localeCompare(b.id));
17535
17543
  }, "memberEvents");
17536
17544
 
17537
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/members-audit.js
17545
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/members-audit.js
17538
17546
  var AUDIT_PAGE = 200;
17539
17547
  var AUDIT_BUDGET = 10;
17540
17548
  var AUDIT_PAUSE_MS = 1e3;
@@ -17614,7 +17622,7 @@ var burstJoins = /* @__PURE__ */ __name((members) => {
17614
17622
  return found;
17615
17623
  }, "burstJoins");
17616
17624
 
17617
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/message-resolution.js
17625
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/message-resolution.js
17618
17626
  var readChatId = /* @__PURE__ */ __name(async (deps, reference, store, account2) => {
17619
17627
  if (deps.reads !== "store")
17620
17628
  return keptChatId(deps.messenger, reference, store, account2);
@@ -17773,7 +17781,7 @@ var senderAmong = /* @__PURE__ */ __name(async (store, accounts, reference) => {
17773
17781
  }
17774
17782
  }, "senderAmong");
17775
17783
 
17776
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/chats.js
17784
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/chats.js
17777
17785
  var EVENTS_DAYS = 7;
17778
17786
  var TRACKED_DAYS = 30;
17779
17787
  var STATS_PAGE = 1e3;
@@ -18068,7 +18076,7 @@ var storedMembers = /* @__PURE__ */ __name(async (store, chatId) => {
18068
18076
  return members.length === 0 ? null : members;
18069
18077
  }, "storedMembers");
18070
18078
 
18071
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/task-categories.js
18079
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/task-categories.js
18072
18080
  var names = /* @__PURE__ */ __name((categories) => categories.map(({ name }) => name).join(", "), "names");
18073
18081
  var taskCategoryOf = /* @__PURE__ */ __name((categories = DEFAULT_TASK_CATEGORIES, flag = "--category") => (typed) => {
18074
18082
  const name = typed.trim().toLowerCase();
@@ -18125,7 +18133,7 @@ var categorize = /* @__PURE__ */ __name((text2, categories = DEFAULT_TASK_CATEGO
18125
18133
  return best.name;
18126
18134
  }, "categorize");
18127
18135
 
18128
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/task-rules.js
18136
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/task-rules.js
18129
18137
  var taskAccount = /* @__PURE__ */ __name(({ provider, account: account2 }) => `${provider}:${account2}`, "taskAccount");
18130
18138
  var RULES_IN = {
18131
18139
  dialog: "all",
@@ -18222,7 +18230,7 @@ var applyTaskRules = /* @__PURE__ */ __name(async (review, { store, account: acc
18222
18230
  return result;
18223
18231
  }, "applyTaskRules");
18224
18232
  var ARRIVAL_WINDOW = 50;
18225
- var kindOf2 = /* @__PURE__ */ __name(async (store, account2, chat) => await store.chats.chatKind(account2, chat) ?? "unknown", "kindOf");
18233
+ var kindOf = /* @__PURE__ */ __name(async (store, account2, chat) => await store.chats.chatKind(account2, chat) ?? "unknown", "kindOf");
18226
18234
  var applyTaskRulesOnArrival = /* @__PURE__ */ __name(async (store, account2, message) => {
18227
18235
  const page = await store.messages.messages(account2, message.chatId, { limit: ARRIVAL_WINDOW });
18228
18236
  const messages = [...page.items.filter((one2) => one2.id !== message.id), message].sort((a, b) => Date.parse(a.timestamp) - Date.parse(b.timestamp));
@@ -18231,7 +18239,7 @@ var applyTaskRulesOnArrival = /* @__PURE__ */ __name(async (store, account2, mes
18231
18239
  {
18232
18240
  id: message.chatId,
18233
18241
  messages,
18234
- kind: await kindOf2(store, account2, message.chatId),
18242
+ kind: await kindOf(store, account2, message.chatId),
18235
18243
  watched: (await watchedChats(store, account2)).has(message.chatId)
18236
18244
  }
18237
18245
  ]
@@ -18323,7 +18331,7 @@ var applyTaskRulesToChats = /* @__PURE__ */ __name(async (store, account2, chatI
18323
18331
  const tasks = [];
18324
18332
  const pass = await applyTaskRules({
18325
18333
  chats: [
18326
- { id: chat, messages: page.items, kind: await kindOf2(store, account2, chat), watched: watched.has(chat) }
18334
+ { id: chat, messages: page.items, kind: await kindOf(store, account2, chat), watched: watched.has(chat) }
18327
18335
  ]
18328
18336
  }, { store: store.tasks, account: account2, categories, dryRun: !yes, onHeld: /* @__PURE__ */ __name((task2) => tasks.push(task2), "onHeld") });
18329
18337
  passes.push({ chat, messages: page.items.length, ...pass, tasks });
@@ -18331,7 +18339,7 @@ var applyTaskRulesToChats = /* @__PURE__ */ __name(async (store, account2, chatI
18331
18339
  return passes;
18332
18340
  }, "applyTaskRulesToChats");
18333
18341
 
18334
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/task-tag-filters.js
18342
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/task-tag-filters.js
18335
18343
  var taskTagFilters = /* @__PURE__ */ __name(async (store, query) => {
18336
18344
  const tags = /* @__PURE__ */ new Map();
18337
18345
  for (const node of query ? walkQuery(query.root) : [])
@@ -18340,7 +18348,7 @@ var taskTagFilters = /* @__PURE__ */ __name(async (store, query) => {
18340
18348
  return tags;
18341
18349
  }, "taskTagFilters");
18342
18350
 
18343
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/agenda.js
18351
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/agenda.js
18344
18352
  var DAY = 864e5;
18345
18353
  var AGENDA_DEFAULTS = { unanswered: DAY, waiting: 7 * DAY };
18346
18354
  var CLAIMS = ["none", "mine", "others", "any"];
@@ -18587,7 +18595,7 @@ var agendaItem = /* @__PURE__ */ __name((shown) => {
18587
18595
  };
18588
18596
  }, "agendaItem");
18589
18597
 
18590
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/context/evidence-response.js
18598
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/context/evidence-response.js
18591
18599
  var contextSourceKey = /* @__PURE__ */ __name((source) => JSON.stringify([source.kind, source.accountId, source.provider, source.account]), "contextSourceKey");
18592
18600
  var validateContextEvidencePage = /* @__PURE__ */ __name((page, request) => {
18593
18601
  const fail3 = /* @__PURE__ */ __name(() => {
@@ -18651,7 +18659,7 @@ var validateContextEvidencePage = /* @__PURE__ */ __name((page, request) => {
18651
18659
  }
18652
18660
  }, "validateContextEvidencePage");
18653
18661
 
18654
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/context/read-budget.js
18662
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/context/read-budget.js
18655
18663
  var contextReadBudget = /* @__PURE__ */ __name((limits = {}) => {
18656
18664
  if (!limits || typeof limits !== "object" || Array.isArray(limits))
18657
18665
  throw new CliError("validation_error", "limits needs a context read allowance");
@@ -18704,7 +18712,7 @@ var contextReadBudget = /* @__PURE__ */ __name((limits = {}) => {
18704
18712
  };
18705
18713
  }, "contextReadBudget");
18706
18714
 
18707
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/context-evidence.js
18715
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/context-evidence.js
18708
18716
  var createContextEvidenceReader = /* @__PURE__ */ __name((port, allowed, limits) => {
18709
18717
  if (!port || typeof port.read !== "function")
18710
18718
  throw new CliError("configuration_error", "context evidence reader is unavailable");
@@ -18748,7 +18756,7 @@ var createContextEvidenceReader = /* @__PURE__ */ __name((port, allowed, limits)
18748
18756
  };
18749
18757
  }, "createContextEvidenceReader");
18750
18758
 
18751
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/excerpt.js
18759
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/excerpt.js
18752
18760
  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");
18753
18761
  var excerpt = /* @__PURE__ */ __name((text2, query, size4 = 240, options = {}) => {
18754
18762
  const flat = text2.replace(/\s+/g, " ").trim();
@@ -18764,8 +18772,9 @@ var excerpt = /* @__PURE__ */ __name((text2, query, size4 = 240, options = {}) =
18764
18772
  }, "excerpt");
18765
18773
  var withExcerpt = /* @__PURE__ */ __name(({ matchedText, ...hit }, query) => ({ ...hit, excerpt: excerpt(matchedText ?? hit.text, query) }), "withExcerpt");
18766
18774
 
18767
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/ingest.js
18768
- var emptyReceipt = /* @__PURE__ */ __name((dryRun) => ({
18775
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/ingest.js
18776
+ import { createInterface } from "node:readline";
18777
+ var emptyReceipt = /* @__PURE__ */ __name((dryRun, errors) => ({
18769
18778
  dryRun,
18770
18779
  source: null,
18771
18780
  created: 0,
@@ -18776,70 +18785,91 @@ var emptyReceipt = /* @__PURE__ */ __name((dryRun) => ({
18776
18785
  proposed: [],
18777
18786
  waiting: [],
18778
18787
  flagged: [],
18779
- errors: []
18788
+ unmatched: [],
18789
+ ignored: [],
18790
+ errors,
18791
+ truncated: false
18780
18792
  }), "emptyReceipt");
18781
- var ingest = /* @__PURE__ */ __name(async (store, envelope, { account: account2, dryRun = false, chunk = 1e3 }) => {
18782
- const receipt = emptyReceipt(dryRun);
18783
- const broken = envelopeErrors(envelope, account2);
18784
- if (broken.length > 0)
18785
- return { ...receipt, errors: broken };
18786
- const { source, records } = envelope;
18787
- receipt.source = { provider: source.provider, account: source.account, batchId: source.batch_id };
18788
- const taken = [];
18789
- const keys = /* @__PURE__ */ new Set();
18790
- const identities = /* @__PURE__ */ new Set();
18791
- for (const [index, record] of records.entries()) {
18792
- const errors = recordErrors(record, index);
18793
- const valid = record;
18794
- if (errors.length === 0 && keys.has(valid.key))
18795
- errors.push({
18796
- pointer: pointerOf("records", index, "key"),
18797
- code: "record.duplicate-key",
18798
- message: "another record of this envelope has this key",
18799
- key: valid.key
18800
- });
18801
- const identity = errors.length === 0 ? `${valid.type}\0${valid.external_id}` : "";
18802
- if (errors.length === 0 && identities.has(identity))
18803
- errors.push({
18804
- pointer: pointerOf("records", index, "external_id"),
18805
- code: "record.duplicate",
18806
- message: `another record of this envelope is ${valid.type} ${valid.external_id}`,
18807
- key: valid.key
18808
- });
18809
- if (errors.length > 0) {
18810
- receipt.refused += 1;
18811
- for (const error of errors)
18812
- receipt.errors.push(error);
18813
- continue;
18814
- }
18815
- keys.add(valid.key);
18816
- identities.add(identity);
18817
- taken.push({ index, record: valid });
18818
- }
18819
- const written = await store.records.write(source, taken, { dryRun, chunk });
18820
- for (const outcome2 of written.outcomes) {
18821
- receipt[outcome2.status] += 1;
18822
- if (outcome2.error)
18823
- receipt.errors.push(outcome2.error);
18824
- }
18825
- for (const error of written.laterErrors)
18826
- receipt.errors.push(error);
18827
- receipt.errors.sort((a, b) => a.pointer.localeCompare(b.pointer, "en", { numeric: true }));
18828
- receipt.proposed = written.proposed;
18829
- receipt.waiting = written.waiting.map(({ index, key, missing: missing4 }) => ({
18793
+ var receiptOf = /* @__PURE__ */ __name((dryRun, source, run) => ({
18794
+ dryRun,
18795
+ source: { provider: source.provider, account: source.account, batchId: source.batch_id },
18796
+ created: run.created,
18797
+ updated: run.updated,
18798
+ unchanged: run.unchanged,
18799
+ deleted: run.deleted,
18800
+ refused: run.refused,
18801
+ proposed: run.proposed,
18802
+ waiting: run.waiting.map(({ index, key, missing: missing4 }) => ({ key, pointer: waitingPointer(index, missing4), missing: missing4 })),
18803
+ flagged: run.flagged.map(({ index, ...flag }) => ({ ...flag, pointer: pointerOf("records", index) })),
18804
+ unmatched: run.unmatched.map(({ index, key, reason, candidates }) => ({
18830
18805
  key,
18831
- pointer: pointerOf("records", index, "relations"),
18832
- missing: missing4
18833
- }));
18834
- receipt.flagged = written.flagged.map(({ index, key, entity }) => ({
18806
+ pointer: pointerOf("records", index, "fields"),
18807
+ reason,
18808
+ candidates
18809
+ })),
18810
+ ignored: run.ignored.map(({ index, key, at, reason }) => ({
18835
18811
  key,
18836
- pointer: pointerOf("records", index),
18837
- entity
18838
- }));
18839
- return receipt;
18812
+ pointer: pointerOf("records", index, ...at),
18813
+ reason
18814
+ })),
18815
+ errors: run.errors,
18816
+ truncated: run.truncated
18817
+ }), "receiptOf");
18818
+ var itemOf = /* @__PURE__ */ __name((record, index) => {
18819
+ const errors = recordErrors(record, index);
18820
+ return { index, record, ...errors.length > 0 ? { errors } : {} };
18821
+ }, "itemOf");
18822
+ var refusedAll = /* @__PURE__ */ __name((dryRun, errors, onIssue) => {
18823
+ for (const error of errors)
18824
+ onIssue?.(error);
18825
+ return emptyReceipt(dryRun, errors);
18826
+ }, "refusedAll");
18827
+ var ingest = /* @__PURE__ */ __name(async (store, envelope, { account: account2, dryRun = false, chunk = 1e3, onIssue }) => {
18828
+ const broken = envelopeErrors(envelope, account2);
18829
+ if (broken.length > 0)
18830
+ return refusedAll(dryRun, broken, onIssue);
18831
+ const { source, records, options } = envelope;
18832
+ const items = records.map(itemOf);
18833
+ return receiptOf(dryRun, source, await store.records.run(source, items, { dryRun, chunk, options, onIssue }));
18840
18834
  }, "ingest");
18835
+ var jsonlLines = /* @__PURE__ */ __name((stream) => createInterface({ input: stream, crlfDelay: Number.POSITIVE_INFINITY }), "jsonlLines");
18836
+ var ingestLines = /* @__PURE__ */ __name(async (store, lines, { account: account2, dryRun = false, chunk = 1e3, onIssue }) => {
18837
+ const iterator = lines[Symbol.asyncIterator]();
18838
+ let header = {};
18839
+ for (let next = await iterator.next(); !next.done; next = await iterator.next())
18840
+ if (next.value.trim() !== "" && next.value !== "\uFEFF") {
18841
+ header = jsonLine(next.value);
18842
+ break;
18843
+ }
18844
+ const broken = headerErrors(header, account2);
18845
+ if (broken.length > 0) {
18846
+ await iterator.return?.();
18847
+ return refusedAll(dryRun, broken, onIssue);
18848
+ }
18849
+ const { source, options } = header;
18850
+ async function* items() {
18851
+ let index = 0;
18852
+ for (let next = await iterator.next(); !next.done; next = await iterator.next()) {
18853
+ if (next.value.trim() === "")
18854
+ continue;
18855
+ yield itemOf(jsonLine(next.value), index);
18856
+ index += 1;
18857
+ }
18858
+ }
18859
+ __name(items, "items");
18860
+ return receiptOf(dryRun, source, await store.records.run(source, items(), { dryRun, chunk, options, onIssue }));
18861
+ }, "ingestLines");
18862
+ var ingestVcard = /* @__PURE__ */ __name(async (store, text2, { provider, batchId, region, ...options }) => {
18863
+ const { envelope, issues } = envelopeOfVcard(text2, {
18864
+ provider,
18865
+ account: options.account,
18866
+ batchId,
18867
+ ...region === void 0 ? {} : { region }
18868
+ });
18869
+ return { ...await ingest(store, envelope, options), vcard: issues };
18870
+ }, "ingestVcard");
18841
18871
 
18842
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/shared.js
18872
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/shared.js
18843
18873
  var escaped = /* @__PURE__ */ __name((text2) => text2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "escaped");
18844
18874
  var folded = /* @__PURE__ */ __name((text2) => text2.normalize("NFKC").toLowerCase().replace(/\s+/gu, " "), "folded");
18845
18875
  var wholeWords = /* @__PURE__ */ __name((term) => new RegExp(`(?<![\\p{L}\\p{N}\\p{M}_])${escaped(normalizeVocabularyName(term))}(?![\\p{L}\\p{N}\\p{M}_])`, "u"), "wholeWords");
@@ -18866,7 +18896,10 @@ var personRefOf = /* @__PURE__ */ __name(async (store, provider, id2) => {
18866
18896
  const person = await store.people.personOf({ provider, id: id2 });
18867
18897
  return person ? `person:${person.uid}` : void 0;
18868
18898
  }, "personRefOf");
18869
- var projectsOf = /* @__PURE__ */ __name(async (store, person) => new Set((await store.knowledge.relations(null, person)).filter((one2) => one2.confirmed && one2.kind === "member-of" && one2.from === person && one2.to.startsWith("project:")).map((one2) => one2.to)).size, "projectsOf");
18899
+ var projectsOf = /* @__PURE__ */ __name(async (store, person, project) => (/* @__PURE__ */ new Set([
18900
+ project,
18901
+ ...(await store.knowledge.relations(null, person)).filter((one2) => isUsable(one2.standing) && one2.kind === "member-of" && one2.from === person && one2.to.startsWith("project:")).map((one2) => one2.to)
18902
+ ])).size, "projectsOf");
18870
18903
  var identitiesIn = /* @__PURE__ */ __name(async (store, people, provider) => {
18871
18904
  const found = [];
18872
18905
  for (const person of people) {
@@ -18878,7 +18911,7 @@ var identitiesIn = /* @__PURE__ */ __name(async (store, people, provider) => {
18878
18911
  return found;
18879
18912
  }, "identitiesIn");
18880
18913
 
18881
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/alias-hits.js
18914
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/alias-hits.js
18882
18915
  var SEARCH_LIMIT = 500;
18883
18916
  var aliasWeight = /* @__PURE__ */ __name((hits) => hits >= 10 ? 0.55 : hits >= 3 ? 0.35 : 0, "aliasWeight");
18884
18917
  var aliasHits = {
@@ -18927,15 +18960,17 @@ var aliasHits = {
18927
18960
  }, "candidates")
18928
18961
  };
18929
18962
 
18930
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/chat-senders.js
18963
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/chat-senders.js
18931
18964
  var WEIGHT = 0.5;
18932
18965
  var LARGE_GROUP_WEIGHT = 0.2;
18933
18966
  var LARGE_GROUP = 30;
18967
+ var SMALL_CHAT = 10;
18934
18968
  var MIN_MESSAGES = 5;
18935
18969
  var READ_LIMIT = 2e3;
18936
18970
  var chatSenders = {
18937
18971
  id: "chat-senders",
18938
- version: 1,
18972
+ version: 2,
18973
+ spreads: true,
18939
18974
  candidates: /* @__PURE__ */ __name(async ({ store, project, confirmed, sources, since, owner, signal }) => {
18940
18975
  if (!project)
18941
18976
  return [];
@@ -18959,7 +18994,7 @@ var chatSenders = {
18959
18994
  const size4 = Math.max((await store.roster.members(key, reference.chat)).length, senders.size);
18960
18995
  const weight = size4 > LARGE_GROUP ? LARGE_GROUP_WEIGHT : WEIGHT;
18961
18996
  for (const [id2, { count: count3, last }] of senders) {
18962
- if (count3 < MIN_MESSAGES)
18997
+ if (size4 > SMALL_CHAT && count3 < MIN_MESSAGES)
18963
18998
  continue;
18964
18999
  const person = await personRefOf(store, key.provider, id2);
18965
19000
  if (!person || person === owner)
@@ -18979,7 +19014,7 @@ var chatSenders = {
18979
19014
  }, "candidates")
18980
19015
  };
18981
19016
 
18982
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/chat-title.js
19017
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/chat-title.js
18983
19018
  var WEIGHT2 = 0.7;
18984
19019
  var chatTitle = {
18985
19020
  id: "chat-title",
@@ -19018,7 +19053,7 @@ var chatTitle = {
19018
19053
  }, "candidates")
19019
19054
  };
19020
19055
 
19021
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/email-domain.js
19056
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/email-domain.js
19022
19057
  var WEIGHT3 = 0.3;
19023
19058
  var CONTACTS = 500;
19024
19059
  var MOST_PAIRS = 200;
@@ -19079,13 +19114,14 @@ var emailDomain = {
19079
19114
  }, "candidates")
19080
19115
  };
19081
19116
 
19082
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/mail-thread.js
19117
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/mail-thread.js
19083
19118
  var NAMED = 0.7;
19084
19119
  var MEMBER_ONLY = 0.3;
19085
19120
  var READ_LIMIT2 = 500;
19086
19121
  var mailThread = {
19087
19122
  id: "mail-thread",
19088
19123
  version: 1,
19124
+ spreads: true,
19089
19125
  candidates: /* @__PURE__ */ __name(async ({ store, project, confirmed, sources, since, owner, signal }) => {
19090
19126
  if (!project)
19091
19127
  return [];
@@ -19152,11 +19188,12 @@ var mailThread = {
19152
19188
  }, "candidates")
19153
19189
  };
19154
19190
 
19155
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/member-chats.js
19191
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/member-chats.js
19156
19192
  var WEIGHT4 = 0.5;
19157
19193
  var memberChats = {
19158
19194
  id: "member-chats",
19159
19195
  version: 1,
19196
+ spreads: true,
19160
19197
  candidates: /* @__PURE__ */ __name(async ({ store, project, confirmed, sources, owner, signal }) => {
19161
19198
  if (!project)
19162
19199
  return [];
@@ -19192,11 +19229,12 @@ var memberChats = {
19192
19229
  }, "candidates")
19193
19230
  };
19194
19231
 
19195
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/member-dialog.js
19232
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/member-dialog.js
19196
19233
  var WEIGHT5 = 0.6;
19197
19234
  var memberDialog = {
19198
19235
  id: "member-dialog",
19199
- version: 1,
19236
+ version: 2,
19237
+ spreads: true,
19200
19238
  candidates: /* @__PURE__ */ __name(async ({ store, project, confirmed, sources, owner, signal }) => {
19201
19239
  if (!project)
19202
19240
  return [];
@@ -19210,7 +19248,7 @@ var memberDialog = {
19210
19248
  if (chat.kind !== "dialog")
19211
19249
  continue;
19212
19250
  if (!projects.has(person))
19213
- projects.set(person, Math.max(1, await projectsOf(store, person)));
19251
+ projects.set(person, await projectsOf(store, person, project.ref));
19214
19252
  const shared = projects.get(person) ?? 1;
19215
19253
  found.push({
19216
19254
  from: chatRef(key, chat.id),
@@ -19226,7 +19264,7 @@ var memberDialog = {
19226
19264
  }, "candidates")
19227
19265
  };
19228
19266
 
19229
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-purposes.js
19267
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-purposes.js
19230
19268
  var BUILT_IN_PURPOSES = ["work", "sales", "support", "other"];
19231
19269
  var DEFAULT_PURPOSES = ["work"];
19232
19270
  var LINK_PURPOSE = "work";
@@ -19256,7 +19294,7 @@ var purposeList = /* @__PURE__ */ __name((value, previous = []) => [
19256
19294
  ...value.split(",").map((one2) => one2.trim()).filter(Boolean)
19257
19295
  ], "purposeList");
19258
19296
 
19259
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-gathering-around.js
19297
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-gathering-around.js
19260
19298
  var storedMessageNeighbours = /* @__PURE__ */ __name((messages) => ({
19261
19299
  async around(ref, window2) {
19262
19300
  const at = parseLocator(ref);
@@ -19352,7 +19390,7 @@ var storedNeighbours = /* @__PURE__ */ __name((store) => {
19352
19390
  };
19353
19391
  }, "storedNeighbours");
19354
19392
 
19355
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-gathering-request.js
19393
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-gathering-request.js
19356
19394
  import { createHash } from "node:crypto";
19357
19395
  var DAY2 = 864e5;
19358
19396
  var MAX_TIME = 864e13;
@@ -19668,7 +19706,7 @@ var decodeCheckpoint = /* @__PURE__ */ __name((text2, plan) => {
19668
19706
  return value;
19669
19707
  }, "decodeCheckpoint");
19670
19708
 
19671
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-gathering.js
19709
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-gathering.js
19672
19710
  var terminal = /* @__PURE__ */ new Set(["done", "unavailable", "failed"]);
19673
19711
  var PAGE = 20;
19674
19712
  var PEOPLE = 20;
@@ -20072,7 +20110,7 @@ var peopleOf = /* @__PURE__ */ __name((items, senderOf) => {
20072
20110
  return [...byKey.values()].sort((a, b) => b.items - a.items || a.name.localeCompare(b.name));
20073
20111
  }, "peopleOf");
20074
20112
 
20075
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-matching.js
20113
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-matching.js
20076
20114
  var normalizedText = /* @__PURE__ */ __name((text2) => text2.normalize("NFKC").toLowerCase().replace(/\s+/gu, " "), "normalizedText");
20077
20115
  var termsOf = /* @__PURE__ */ __name((entry) => [
20078
20116
  { name: entry.name, kind: "canonical" },
@@ -20137,7 +20175,7 @@ var matchProjectCandidates = /* @__PURE__ */ __name((catalog, input) => matchVoc
20137
20175
  omittedMatches: omitted
20138
20176
  })), "matchProjectCandidates");
20139
20177
 
20140
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-gathering-mentions.js
20178
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-gathering-mentions.js
20141
20179
  var KINDS = ["project", "tag", "topic"];
20142
20180
  var findEvidenceMentions = /* @__PURE__ */ __name(async (vocabulary, gathering, options = {}) => {
20143
20181
  if (typeof vocabulary?.vocabulary !== "function")
@@ -20192,7 +20230,7 @@ var findEvidenceMentions = /* @__PURE__ */ __name(async (vocabulary, gathering,
20192
20230
  };
20193
20231
  }, "findEvidenceMentions");
20194
20232
 
20195
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/stored-project-gathering.js
20233
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/stored-project-gathering.js
20196
20234
  var storedChatCount = /* @__PURE__ */ __name((store) => async (account2, chatId, { since, until }) => {
20197
20235
  const window2 = { since: new Date(since).toISOString(), until: new Date(until - 1).toISOString() };
20198
20236
  const [messages, newest, oldest] = await Promise.all([
@@ -20287,7 +20325,7 @@ var proposedLinksOf = /* @__PURE__ */ __name(async (store, project) => {
20287
20325
  }
20288
20326
  ];
20289
20327
  }).sort((a, b) => Number(a.id) - Number(b.id));
20290
- const legacy = (await store.knowledge.relations(null, project)).filter((one2) => !one2.confirmed && one2.kind === "member-of" && one2.to === project).map((one2) => ({ from: one2.from, id: `link:${one2.id}`, role: one2.role, purpose: one2.purpose }));
20328
+ const legacy = (await store.knowledge.relations(null, project)).filter((one2) => one2.standing === "proposed" && one2.kind === "member-of" && one2.to === project).map((one2) => ({ from: one2.from, id: `link:${one2.id}`, role: one2.role, purpose: one2.purpose }));
20291
20329
  return [...proposals, ...legacy];
20292
20330
  }, "proposedLinksOf");
20293
20331
  var memberRefsOf = /* @__PURE__ */ __name(async (store, project, includeProposed) => {
@@ -20295,7 +20333,7 @@ var memberRefsOf = /* @__PURE__ */ __name(async (store, project, includeProposed
20295
20333
  return [];
20296
20334
  const confirmed = /* @__PURE__ */ new Set();
20297
20335
  for (const relation of await store.knowledge.relations(null, project))
20298
- if (relation.confirmed && relation.kind === "member-of" && relation.to === project && /^person:.+/.test(relation.from))
20336
+ if (isUsable(relation.standing) && relation.kind === "member-of" && relation.to === project && /^person:.+/.test(relation.from))
20299
20337
  confirmed.add(relation.from);
20300
20338
  const members = [...confirmed].sort().map((ref) => ({ ref }));
20301
20339
  if (!includeProposed)
@@ -20333,7 +20371,7 @@ var linkedChatsOf = /* @__PURE__ */ __name(async (store, project, options = {})
20333
20371
  return [];
20334
20372
  const chats = [];
20335
20373
  for (const relation of await store.knowledge.relations(null, project)) {
20336
- if (!relation.confirmed || relation.kind !== "member-of" || relation.to !== project)
20374
+ if (!isUsable(relation.standing) || relation.kind !== "member-of" || relation.to !== project)
20337
20375
  continue;
20338
20376
  const reference = chatOf2(relation.from);
20339
20377
  if (reference)
@@ -20498,13 +20536,14 @@ var purposeHintOf = /* @__PURE__ */ __name((linked, rows, of) => {
20498
20536
  return { chat: top.ref, relationship: link4.relationship, items, of };
20499
20537
  }, "purposeHintOf");
20500
20538
 
20501
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/link-scorers/scan.js
20539
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/link-scorers/scan.js
20502
20540
  var SCORERS = [chatTitle, aliasHits, memberChats, memberDialog, chatSenders, mailThread];
20503
20541
  var PERSON_SCORERS = [emailDomain];
20504
20542
  var SCAN_BOT = { bot: "memo-scan", kind: "rule" };
20505
20543
  var DEFAULT_THRESHOLD = 0.5;
20506
20544
  var PERSON_THRESHOLD = 0.3;
20507
20545
  var DEFAULT_LIMIT = 20;
20546
+ var MAX_HOPS = 4;
20508
20547
  var projectOf2 = /* @__PURE__ */ __name(async (store, reference) => {
20509
20548
  const ref = await canonicalProjectRef(store, reference);
20510
20549
  const entry = (await store.knowledge.vocabulary({ kind: "project" })).entries.find((one2) => one2.id === ref.slice(8));
@@ -20515,7 +20554,7 @@ var projectOf2 = /* @__PURE__ */ __name(async (store, reference) => {
20515
20554
  var confirmedOf = /* @__PURE__ */ __name(async (store, project) => {
20516
20555
  if (!project)
20517
20556
  return { chats: [], people: [] };
20518
- const members = (await store.knowledge.relations(null, project.ref)).filter((one2) => one2.confirmed && one2.kind === "member-of" && one2.to === project.ref);
20557
+ const members = (await store.knowledge.relations(null, project.ref)).filter((one2) => isUsable(one2.standing) && one2.kind === "member-of" && one2.to === project.ref);
20519
20558
  return {
20520
20559
  chats: [...new Set(members.map((one2) => one2.from).filter((ref) => ref.startsWith("chat:")))].sort(),
20521
20560
  people: [...new Set(members.map((one2) => one2.from).filter((ref) => ref.startsWith("person:")))].sort()
@@ -20571,56 +20610,28 @@ var scanProjectLinks = /* @__PURE__ */ __name(async (store, input) => {
20571
20610
  nameOnly: 0,
20572
20611
  unresolved: 0
20573
20612
  };
20574
- const pairs = /* @__PURE__ */ new Map();
20575
- const nameOnly = /* @__PURE__ */ new Set();
20576
- for (const scorer of scorers) {
20577
- input.signal?.throwIfAborted();
20578
- for (const candidate of await scorer.candidates(scorerInput)) {
20579
- const key = pairKey(candidate);
20580
- const verdict = await admissible(store, scorerInput, candidate);
20581
- if (verdict === "owner")
20582
- continue;
20583
- if (verdict === "name-only") {
20584
- if (!nameOnly.has(key))
20585
- skipped.nameOnly++;
20586
- nameOnly.add(key);
20587
- continue;
20588
- }
20589
- if (verdict !== "ok") {
20590
- skipped.unresolved++;
20591
- continue;
20592
- }
20593
- const weight = Math.min(1, Math.max(0, candidate.weight));
20594
- const held = pairs.get(key) ?? { candidate, signals: /* @__PURE__ */ new Map() };
20595
- const scorerId = `${scorer.id}@${scorer.version}`;
20596
- const before2 = held.signals.get(scorerId);
20597
- if (!before2 || before2.weight < weight)
20598
- held.signals.set(scorerId, {
20599
- scorer: scorerId,
20600
- weight,
20601
- why: candidate.why.slice(0, 500),
20602
- ...candidate.purpose && scorerInput.purposes.includes(candidate.purpose) ? { purpose: candidate.purpose } : {}
20603
- });
20604
- held.candidate = {
20605
- ...held.candidate,
20606
- evidence: [.../* @__PURE__ */ new Set([...held.candidate.evidence, ...candidate.evidence])]
20607
- };
20608
- pairs.set(key, held);
20609
- }
20613
+ const fixed = /* @__PURE__ */ new Map();
20614
+ const candidatesOf = /* @__PURE__ */ __name(async (scorer, seeds2) => {
20615
+ if (scorer.spreads)
20616
+ return scorer.candidates({ ...scorerInput, confirmed: seeds2 });
20617
+ const held = fixed.get(scorer) ?? await scorer.candidates(scorerInput);
20618
+ fixed.set(scorer, held);
20619
+ return held;
20620
+ }, "candidatesOf");
20621
+ let seeds = scorerInput.confirmed;
20622
+ let collected = await collect(store, scorerInput, scorers, (scorer) => candidatesOf(scorer, seeds));
20623
+ for (let hop = 0; hop < MAX_HOPS && scorers.some((one2) => one2.spreads); hop++) {
20624
+ const grown = await seedsOf(store, seeds, collected.scored, threshold);
20625
+ if (!grown)
20626
+ break;
20627
+ seeds = grown;
20628
+ collected = await collect(store, scorerInput, scorers, (scorer) => candidatesOf(scorer, seeds));
20610
20629
  }
20611
- const scored = [...pairs.values()].map(({ candidate, signals: signals2 }) => {
20612
- const list2 = [...signals2.values()].sort((a, b) => b.weight - a.weight || a.scorer.localeCompare(b.scorer));
20613
- const purpose = list2.find((one2) => one2.purpose)?.purpose;
20614
- return {
20615
- candidate,
20616
- purpose,
20617
- signals: list2.map(({ scorer, weight, why }) => ({ scorer, weight, why })),
20618
- score: combinedScore(list2.map((one2) => one2.weight))
20619
- };
20620
- }).sort((a, b) => b.score - a.score || a.candidate.from.localeCompare(b.candidate.from));
20630
+ skipped.nameOnly = collected.nameOnly;
20631
+ skipped.unresolved = collected.unresolved;
20621
20632
  const proposals = [];
20622
20633
  let fresh = 0;
20623
- for (const { candidate, purpose, signals: signals2, score } of scored) {
20634
+ for (const { candidate, purpose, signals: signals2, score } of collected.scored) {
20624
20635
  const state = await store.knowledge.relationState(null, candidate);
20625
20636
  if (!state) {
20626
20637
  skipped.unresolved++;
@@ -20677,6 +20688,73 @@ var scanProjectLinks = /* @__PURE__ */ __name(async (store, input) => {
20677
20688
  }
20678
20689
  return { project: project?.ref ?? null, proposals, skipped };
20679
20690
  }, "scanProjectLinks");
20691
+ var collect = /* @__PURE__ */ __name(async (store, input, scorers, candidatesOf) => {
20692
+ const pairs = /* @__PURE__ */ new Map();
20693
+ const nameOnly = /* @__PURE__ */ new Set();
20694
+ let unresolved = 0;
20695
+ for (const scorer of scorers) {
20696
+ input.signal?.throwIfAborted();
20697
+ for (const candidate of await candidatesOf(scorer)) {
20698
+ const key = pairKey(candidate);
20699
+ const verdict = await admissible(store, input, candidate);
20700
+ if (verdict === "owner")
20701
+ continue;
20702
+ if (verdict === "name-only") {
20703
+ nameOnly.add(key);
20704
+ continue;
20705
+ }
20706
+ if (verdict !== "ok") {
20707
+ unresolved++;
20708
+ continue;
20709
+ }
20710
+ const weight = Math.min(1, Math.max(0, candidate.weight));
20711
+ const held = pairs.get(key) ?? { candidate, signals: /* @__PURE__ */ new Map() };
20712
+ const scorerId = `${scorer.id}@${scorer.version}`;
20713
+ const before2 = held.signals.get(scorerId);
20714
+ if (!before2 || before2.weight < weight)
20715
+ held.signals.set(scorerId, {
20716
+ scorer: scorerId,
20717
+ weight,
20718
+ why: candidate.why.slice(0, 500),
20719
+ ...candidate.purpose && input.purposes.includes(candidate.purpose) ? { purpose: candidate.purpose } : {}
20720
+ });
20721
+ held.candidate = {
20722
+ ...held.candidate,
20723
+ evidence: [.../* @__PURE__ */ new Set([...held.candidate.evidence, ...candidate.evidence])]
20724
+ };
20725
+ pairs.set(key, held);
20726
+ }
20727
+ }
20728
+ const scored = [...pairs.values()].map(({ candidate, signals: signals2 }) => {
20729
+ const list2 = [...signals2.values()].sort((a, b) => b.weight - a.weight || a.scorer.localeCompare(b.scorer));
20730
+ const purpose = list2.find((one2) => one2.purpose)?.purpose;
20731
+ return {
20732
+ candidate,
20733
+ purpose,
20734
+ signals: list2.map(({ scorer, weight, why }) => ({ scorer, weight, why })),
20735
+ score: combinedScore(list2.map((one2) => one2.weight))
20736
+ };
20737
+ }).sort((a, b) => b.score - a.score || a.candidate.from.localeCompare(b.candidate.from));
20738
+ return { scored, nameOnly: nameOnly.size, unresolved };
20739
+ }, "collect");
20740
+ var seedsOf = /* @__PURE__ */ __name(async (store, seeds, scored, threshold) => {
20741
+ const chats = new Set(seeds.chats);
20742
+ const people = new Set(seeds.people);
20743
+ const size4 = chats.size + people.size;
20744
+ for (const { candidate, score } of scored) {
20745
+ if (score < threshold || candidate.kind !== "member-of")
20746
+ continue;
20747
+ if (chats.has(candidate.from) || people.has(candidate.from))
20748
+ continue;
20749
+ if ((await store.knowledge.relationState(null, candidate))?.rejected !== false)
20750
+ continue;
20751
+ if (candidate.from.startsWith("chat:"))
20752
+ chats.add(candidate.from);
20753
+ else if (candidate.from.startsWith("person:"))
20754
+ people.add(candidate.from);
20755
+ }
20756
+ return chats.size + people.size === size4 ? void 0 : { chats: [...chats].sort(), people: [...people].sort() };
20757
+ }, "seedsOf");
20680
20758
  var admissible = /* @__PURE__ */ __name(async (store, input, candidate) => {
20681
20759
  if (candidate.from === candidate.to || !Number.isFinite(candidate.weight))
20682
20760
  return "unresolved";
@@ -20706,18 +20784,18 @@ var referenceOf = /* @__PURE__ */ __name((text2) => {
20706
20784
  }, "referenceOf");
20707
20785
  var rejectedReversed = /* @__PURE__ */ __name(async (store, candidate) => candidate.kind === "related-to" && candidate.to.startsWith("person:") && ((await store.knowledge.relationState(null, { from: candidate.to, to: candidate.from, kind: candidate.kind }))?.rejected ?? false), "rejectedReversed");
20708
20786
 
20709
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive.js
20787
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive.js
20710
20788
  import { setTimeout as sleep } from "node:timers/promises";
20711
20789
 
20712
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
20790
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
20713
20791
  import { lstat } from "node:fs/promises";
20714
20792
 
20715
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
20793
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
20716
20794
  import { createHash as createHash3, randomUUID as randomUUID2 } from "node:crypto";
20717
20795
  import { open as open2, rename as rename2, unlink as unlink2 } from "node:fs/promises";
20718
20796
  import { join as join2 } from "node:path";
20719
20797
 
20720
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-metadata.js
20798
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-metadata.js
20721
20799
  import { createHash as createHash2 } from "node:crypto";
20722
20800
  var metadataLimit = 16384;
20723
20801
  var partialIdentity = /* @__PURE__ */ __name((locator) => JSON.stringify([locator.provider, locator.account, locator.occurrenceId, locator.assetId]), "partialIdentity");
@@ -20777,7 +20855,7 @@ var readPartialMetadata = /* @__PURE__ */ __name(async (path, locator, maxBytes,
20777
20855
  }
20778
20856
  }, "readPartialMetadata");
20779
20857
 
20780
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-writer.js
20858
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-writer.js
20781
20859
  import { randomUUID } from "node:crypto";
20782
20860
  import { open, rename, unlink } from "node:fs/promises";
20783
20861
  import { join } from "node:path";
@@ -20869,7 +20947,7 @@ var partialWriter = /* @__PURE__ */ __name(async (input) => {
20869
20947
  };
20870
20948
  }, "partialWriter");
20871
20949
 
20872
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
20950
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-partial-store.js
20873
20951
  var NativeRecordingPartialStore = class {
20874
20952
  static {
20875
20953
  __name(this, "NativeRecordingPartialStore");
@@ -20976,12 +21054,12 @@ var NativeRecordingPartialStore = class {
20976
21054
  }
20977
21055
  };
20978
21056
 
20979
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
21057
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
20980
21058
  import { createHash as createHash4 } from "node:crypto";
20981
21059
  import { link } from "node:fs/promises";
20982
21060
  import { basename, dirname, join as join4, resolve } from "node:path";
20983
21061
 
20984
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-files.js
21062
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-files.js
20985
21063
  import { unlink as unlink3 } from "node:fs/promises";
20986
21064
  var verifiedPublicationFile = /* @__PURE__ */ __name(async (path, expected2, signal, writable = false) => {
20987
21065
  signal?.throwIfAborted();
@@ -21016,7 +21094,7 @@ var commitPublication = /* @__PURE__ */ __name(async (root, partialPath, finalPa
21016
21094
  signal?.throwIfAborted();
21017
21095
  }, "commitPublication");
21018
21096
 
21019
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-journal.js
21097
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication-journal.js
21020
21098
  import { randomUUID as randomUUID3 } from "node:crypto";
21021
21099
  import { open as open3, rename as rename3, unlink as unlink4 } from "node:fs/promises";
21022
21100
  import { join as join3 } from "node:path";
@@ -21089,7 +21167,7 @@ var writePublicationJournal = /* @__PURE__ */ __name(async (root, path, prefix,
21089
21167
  }
21090
21168
  }, "writePublicationJournal");
21091
21169
 
21092
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
21170
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/persistence/native/recording-publication.js
21093
21171
  var NativeRecordingPublication = class {
21094
21172
  static {
21095
21173
  __name(this, "NativeRecordingPublication");
@@ -21162,7 +21240,7 @@ var NativeRecordingPublication = class {
21162
21240
  }
21163
21241
  };
21164
21242
 
21165
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive-manifest.js
21243
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive-manifest.js
21166
21244
  import { createHash as createHash5 } from "node:crypto";
21167
21245
  import { readdir } from "node:fs/promises";
21168
21246
  import { isAbsolute, join as join5, resolve as resolve2 } from "node:path";
@@ -21249,7 +21327,7 @@ var commitMediaEntry = /* @__PURE__ */ __name((root, one2, beforePublish) => wri
21249
21327
  beforePublish
21250
21328
  }), "commitMediaEntry");
21251
21329
 
21252
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
21330
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive-files.js
21253
21331
  var validator = '"media-completed-v1"';
21254
21332
  var maximumFileBytes = 64 * 1024 * 1024 * 1024;
21255
21333
  var archiveMediaFile = /* @__PURE__ */ __name(async (root, identity, kind, file, beforeWrite, signal, metadata = {}) => {
@@ -21350,7 +21428,7 @@ var archiveMediaFile = /* @__PURE__ */ __name(async (root, identity, kind, file,
21350
21428
  return entry;
21351
21429
  }, "archiveMediaFile");
21352
21430
 
21353
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive-locks.js
21431
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive-locks.js
21354
21432
  import { mkdir, realpath } from "node:fs/promises";
21355
21433
  import { join as join6, resolve as resolve3 } from "node:path";
21356
21434
  var archiveLocations = /* @__PURE__ */ __name(async (initial, signal) => {
@@ -21417,7 +21495,7 @@ var withMediaArchiveLocks = /* @__PURE__ */ __name(async (directory2, signal, ru
21417
21495
  throw new CliError("validation_error", "archive locations changed during locking; run the command again");
21418
21496
  }, "withMediaArchiveLocks");
21419
21497
 
21420
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive.js
21498
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive.js
21421
21499
  var validateMediaSince = /* @__PURE__ */ __name((value, flag = "--since-time") => {
21422
21500
  if (value === void 0)
21423
21501
  return void 0;
@@ -21570,7 +21648,7 @@ var archiveMedia = /* @__PURE__ */ __name(async (ports, options) => {
21570
21648
  }, { create: true });
21571
21649
  }, "archiveMedia");
21572
21650
 
21573
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/media-archive-move.js
21651
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/media-archive-move.js
21574
21652
  import { realpath as realpath2, unlink as unlink5 } from "node:fs/promises";
21575
21653
  import { basename as basename2, dirname as dirname2, join as join7, resolve as resolve4 } from "node:path";
21576
21654
  var canonicalDestination = /* @__PURE__ */ __name(async (directory2) => {
@@ -21723,7 +21801,7 @@ var moveMediaArchive = /* @__PURE__ */ __name(async (options) => {
21723
21801
  }, { additional: [target2], createAdditional: !options.dryRun });
21724
21802
  }, "moveMediaArchive");
21725
21803
 
21726
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/model-downloads.js
21804
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/model-downloads.js
21727
21805
  var bytesOf = /* @__PURE__ */ __name((model) => model.files.reduce((sum2, file) => sum2 + file.bytes, 0), "bytesOf");
21728
21806
  var nativeRuntime = /* @__PURE__ */ __name(async ({ env, progress = /* @__PURE__ */ __name(() => {
21729
21807
  }, "progress") }) => {
@@ -21746,7 +21824,7 @@ var downloadTextModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
21746
21824
  }
21747
21825
  await nativeRuntime({ env, progress });
21748
21826
  progress(`${model.id}: loading it once to check it works`);
21749
- const { openEmbedder: openEmbedder2 } = await import("./embed-37MYTCU7.js");
21827
+ const { openEmbedder: openEmbedder2 } = await import("./embed-4IULBCKL.js");
21750
21828
  const embedder = await openEmbedder2(model, directory2);
21751
21829
  try {
21752
21830
  const [vector] = await embedder.embed(["check"], "query");
@@ -21767,7 +21845,7 @@ var downloadRerankModel = /* @__PURE__ */ __name(async (id2, { env, progress = /
21767
21845
  }
21768
21846
  await nativeRuntime({ env, progress });
21769
21847
  progress(`${model.id}: loading it once to check it works`);
21770
- const { openReranker } = await import("./rerank-FBMZVWSH.js");
21848
+ const { openReranker } = await import("./rerank-XDA7NJNH.js");
21771
21849
  const reranker = await openReranker(model, directory2);
21772
21850
  try {
21773
21851
  await reranker.score("check", ["check"]);
@@ -21785,7 +21863,7 @@ var downloadImageModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
21785
21863
  await installFiles(placedImage(model, directory2), { progress, ...bytes2 ? { bytes: bytes2 } : {} });
21786
21864
  }
21787
21865
  progress(`${model.id}: loading it once to check it works`);
21788
- const { openPictureEmbedder } = await import("./embedder-GNGHVJAO.js");
21866
+ const { openPictureEmbedder } = await import("./embedder-JW4W6IZI.js");
21789
21867
  const embedder = await openPictureEmbedder(model, directory2);
21790
21868
  try {
21791
21869
  const vector = await embedder.embedQuery("check");
@@ -21797,7 +21875,7 @@ var downloadImageModel = /* @__PURE__ */ __name(async (id2, { env, progress = /*
21797
21875
  return { model, directory: directory2 };
21798
21876
  }, "downloadImageModel");
21799
21877
 
21800
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/money-words.js
21878
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/money-words.js
21801
21879
  var MONEY_REQUEST = "money-request";
21802
21880
  var MONEY_DONE = "money-done";
21803
21881
  var PROMISE = "promise";
@@ -21831,10 +21909,10 @@ var MONEY_WORDS = [
21831
21909
  }
21832
21910
  ];
21833
21911
 
21834
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/money-words.js
21912
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/money-words.js
21835
21913
  var moneyClassesOf = /* @__PURE__ */ __name((text2) => listsHit(text2, MONEY_WORDS), "moneyClassesOf");
21836
21914
 
21837
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/status-words.js
21915
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/status-words.js
21838
21916
  var words = /* @__PURE__ */ __name((forms) => new RegExp(`(?<![\\p{L}\\p{N}])(?:${forms.join("|")})(?![\\p{L}\\p{N}])`, "iu"), "words");
21839
21917
  var MONEY_DONE_FORMS = words([
21840
21918
  "\u043E\u043F\u043B\u0430\u0442\u0438\u043B[\u0430\u0438]?",
@@ -21874,7 +21952,7 @@ var PROMISE_FORMS = words([
21874
21952
  "estar\xE1 listo"
21875
21953
  ]);
21876
21954
 
21877
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/items.js
21955
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/items.js
21878
21956
  var EXCERPT_CHARS = 80;
21879
21957
  var excerpt2 = /* @__PURE__ */ __name((text2) => {
21880
21958
  const flat = text2.replace(/\s+/g, " ").trim();
@@ -21896,7 +21974,7 @@ var whoOf = /* @__PURE__ */ __name((message) => ({
21896
21974
  var fromOwner = /* @__PURE__ */ __name((message) => message.outgoing === true, "fromOwner");
21897
21975
  var day = /* @__PURE__ */ __name((at) => new Date(at).toISOString().slice(0, 10), "day");
21898
21976
 
21899
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/amounts.js
21977
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/amounts.js
21900
21978
  var MONEY = DEFAULT_TASK_CATEGORIES.filter((category) => category.name === "money");
21901
21979
  var verbOf = /* @__PURE__ */ __name((text2) => {
21902
21980
  if (MONEY_DONE_FORMS.test(text2))
@@ -21977,7 +22055,7 @@ var amounts = {
21977
22055
  attention: /* @__PURE__ */ __name((items) => items.flatMap((item2) => item2.chat !== null && item2.data.state === "asked" ? [{ chat: item2.chat, weight: 2, why: "money asked" }] : []), "attention")
21978
22056
  };
21979
22057
 
21980
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/children.js
22058
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/children.js
21981
22059
  var children = {
21982
22060
  id: "children",
21983
22061
  version: 1,
@@ -22006,7 +22084,7 @@ var children = {
22006
22084
  }, "read")
22007
22085
  };
22008
22086
 
22009
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/coverage.js
22087
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/coverage.js
22010
22088
  var coverage = {
22011
22089
  id: "coverage",
22012
22090
  version: 1,
@@ -22035,7 +22113,7 @@ var coverage = {
22035
22113
  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")
22036
22114
  };
22037
22115
 
22038
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/payments.js
22116
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/payments.js
22039
22117
  var holding = /* @__PURE__ */ __name((row) => row.review !== "rejected", "holding");
22040
22118
  var item = /* @__PURE__ */ __name((row, at, data) => ({
22041
22119
  signal: "payments",
@@ -22085,7 +22163,7 @@ var payments = {
22085
22163
  }, "read")
22086
22164
  };
22087
22165
 
22088
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/promises.js
22166
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/promises.js
22089
22167
  var PATTERNS_PER_CHAT = 3;
22090
22168
  var DAY3 = 864e5;
22091
22169
  var KINDS2 = /* @__PURE__ */ new Set(["promise", "request"]);
@@ -22174,7 +22252,7 @@ var promises = {
22174
22252
  }, "read")
22175
22253
  };
22176
22254
 
22177
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/questions.js
22255
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/questions.js
22178
22256
  var PER_SIDE = 5;
22179
22257
  var WEEK = 7 * 864e5;
22180
22258
  var NOBODY = /* @__PURE__ */ new Set();
@@ -22205,7 +22283,7 @@ var questions2 = {
22205
22283
  }, "attention")
22206
22284
  };
22207
22285
 
22208
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/reply-next.js
22286
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/reply-next.js
22209
22287
  var targetOf = /* @__PURE__ */ __name((message, chat, owners) => {
22210
22288
  const byId2 = /* @__PURE__ */ __name((id2) => chat.messages.find((one2) => one2.id === id2), "byId");
22211
22289
  const quoted = message.replyTo ?? (message.replyToId === void 0 ? void 0 : byId2(message.replyToId));
@@ -22273,7 +22351,7 @@ var replyNext = {
22273
22351
  attention: /* @__PURE__ */ __name((items) => items.flatMap((item2) => item2.chat !== null && item2.data.next === "owner" ? [{ chat: item2.chat, weight: 2, why: "your move" }] : []), "attention")
22274
22352
  };
22275
22353
 
22276
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/topics.js
22354
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/topics.js
22277
22355
  var escaped2 = /* @__PURE__ */ __name((text2) => text2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "escaped");
22278
22356
  var wholeWord = /* @__PURE__ */ __name((word) => new RegExp(`(?<![\\p{L}\\p{N}])${escaped2(word)}(?![\\p{L}\\p{N}])`, "u"), "wholeWord");
22279
22357
  var matcherOf = /* @__PURE__ */ __name((query) => {
@@ -22319,7 +22397,7 @@ var topics = {
22319
22397
  }, "read")
22320
22398
  };
22321
22399
 
22322
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/signals/index.js
22400
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/signals/index.js
22323
22401
  var STATUS_SIGNALS = [
22324
22402
  replyNext,
22325
22403
  questions2,
@@ -22331,7 +22409,7 @@ var STATUS_SIGNALS = [
22331
22409
  children
22332
22410
  ];
22333
22411
 
22334
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/project-status/index.js
22412
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/project-status/index.js
22335
22413
  var DAY4 = 864e5;
22336
22414
  var STATUS_WINDOW = 300;
22337
22415
  var STATUS_CHATS = 16;
@@ -22347,7 +22425,7 @@ var childrenOf = /* @__PURE__ */ __name(async (store, root, catalog) => {
22347
22425
  const below = [];
22348
22426
  for (const parent of level)
22349
22427
  for (const relation of await store.knowledge.relations(null, parent)) {
22350
- if (!relation.confirmed || relation.kind !== "member-of" || relation.to !== parent)
22428
+ if (!isUsable(relation.standing) || relation.kind !== "member-of" || relation.to !== parent)
22351
22429
  continue;
22352
22430
  if (!relation.from.startsWith("project:"))
22353
22431
  continue;
@@ -22520,7 +22598,7 @@ var projectStatus = /* @__PURE__ */ __name(async (store, input) => {
22520
22598
  };
22521
22599
  }, "projectStatus");
22522
22600
 
22523
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/account.js
22601
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/account.js
22524
22602
  var accountService = /* @__PURE__ */ __name((deps) => {
22525
22603
  const online = /* @__PURE__ */ __name(async (command) => {
22526
22604
  if (deps.offline)
@@ -22592,7 +22670,7 @@ var accountService = /* @__PURE__ */ __name((deps) => {
22592
22670
  };
22593
22671
  }, "accountService");
22594
22672
 
22595
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/send-time.js
22673
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/send-time.js
22596
22674
  var MINUTE = 6e4;
22597
22675
  var YEAR = 365 * 24 * 60 * MINUTE;
22598
22676
  var DELAY = /^(\d+)(m|h|d)$/;
@@ -22611,7 +22689,7 @@ var sendTime = /* @__PURE__ */ __name((value, now = Date.now(), flag = "--at-tim
22611
22689
  return new Date(at - at % MINUTE).toISOString();
22612
22690
  }, "sendTime");
22613
22691
 
22614
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/admin.js
22692
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/admin.js
22615
22693
  var recordMembership = /* @__PURE__ */ __name(async (deps, operationId, done2, change, fix, write) => {
22616
22694
  try {
22617
22695
  const held = await accountStoreIfOpen(deps);
@@ -22858,7 +22936,7 @@ var linkLimits = /* @__PURE__ */ __name(({ approval, expires, maxUses }) => {
22858
22936
  return expires === void 0 ? void 0 : sendTime(expires, Date.now(), "--expire-time");
22859
22937
  }, "linkLimits");
22860
22938
 
22861
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/mail-search.js
22939
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/mail-search.js
22862
22940
  var THREADS_PAGE = 500;
22863
22941
  var threadsOf = /* @__PURE__ */ __name(async (store, key) => {
22864
22942
  const account2 = await store.accounts.storedAccount(key).catch(() => void 0);
@@ -22937,7 +23015,7 @@ var readMail = /* @__PURE__ */ __name(async (store, locator, { before: before2 =
22937
23015
  return thread.slice(Math.max(0, at - before2), at + after + 1).map((hit) => hit.id === message ? { ...hit, anchor: true } : hit);
22938
23016
  }, "readMail");
22939
23017
 
22940
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-kind.js
23018
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-kind.js
22941
23019
  var NO_MAIL = "no_mail";
22942
23020
  var MAIL = "email";
22943
23021
  var listContextOf = /* @__PURE__ */ __name(async (store, account2, app, stored) => {
@@ -22968,11 +23046,11 @@ var accountsOfKind = /* @__PURE__ */ __name((kind, chosen, held, explicit, comma
22968
23046
  if (kind === "messages") {
22969
23047
  if (explicit === MAIL)
22970
23048
  throw new CliError("validation_error", "mail is searched with `memo search mail`, not search messages");
22971
- return chosen.filter(({ provider }) => kindOf(provider) === "messages");
23049
+ return chosen.filter(({ provider }) => holdsKindOf(provider, "messages"));
22972
23050
  }
22973
23051
  if (explicit !== void 0 && explicit !== MAIL && explicit !== "all")
22974
23052
  throw new CliError("validation_error", `search mail reads mail only \u2014 \`${command === void 0 ? "" : `${command} `}search messages\` searches ${explicit}`);
22975
- const mail = (listed ? chosen : held).filter(({ provider }) => kindOf(provider) === "mail");
23053
+ const mail = (listed ? chosen : held).filter(({ provider }) => holdsKindOf(provider, "mail"));
22976
23054
  if (mail.length === 0)
22977
23055
  throw new CliError("not_found", "no mail in the store yet \u2014 `memo sync --only mail --since-time <time>` imports it", {
22978
23056
  reason: NO_MAIL
@@ -22984,7 +23062,7 @@ var accountsOfKind = /* @__PURE__ */ __name((kind, chosen, held, explicit, comma
22984
23062
  return chosenMail.map(({ provider, account: account2 }) => ({ provider, account: account2 }));
22985
23063
  }, "accountsOfKind");
22986
23064
 
22987
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-search.js
23065
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-search.js
22988
23066
  var MAIL_FIELDS = /* @__PURE__ */ new Set(["to", "cc", "bcc", "subject", "mailbox", "label", "is"]);
22989
23067
  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");
22990
23068
  var prepareLucene = /* @__PURE__ */ __name(async (store, account2, request, messenger) => {
@@ -23167,7 +23245,7 @@ var coverageOf = /* @__PURE__ */ __name(async (store, { scopeAccounts, selectedC
23167
23245
  const completeness = [];
23168
23246
  const stats = /* @__PURE__ */ new Map();
23169
23247
  let inventoryComplete = scopeAccounts.length > 0;
23170
- for (const selected of scopeAccounts) {
23248
+ for (const selected of scopeAccounts.filter(({ provider }) => !isImportedProvider(provider))) {
23171
23249
  if (!await store.sync.syncState(selected, CHAT_LIST_KEY)) {
23172
23250
  inventoryComplete = false;
23173
23251
  }
@@ -23332,7 +23410,7 @@ var statsLucene = /* @__PURE__ */ __name(async (store, account2, request, messen
23332
23410
  };
23333
23411
  }, "statsLucene");
23334
23412
 
23335
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/moment.js
23413
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/moment.js
23336
23414
  var AGO = /^(\d+)(m|h|d)$/;
23337
23415
  var AGO_MS = { m: 6e4, h: 36e5, d: 864e5 };
23338
23416
  var DATE = /^\d{4}-\d{2}-\d{2}/;
@@ -23372,7 +23450,7 @@ var dateWindow = /* @__PURE__ */ __name(({ sinceTime, untilTime, zone, now = Dat
23372
23450
  };
23373
23451
  }, "dateWindow");
23374
23452
 
23375
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/rankings-selection.js
23453
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/rankings-selection.js
23376
23454
  var RANKING_SELECTION_BYTES = 64 * 1024;
23377
23455
  var object = /* @__PURE__ */ __name((value) => value !== null && typeof value === "object" && !Array.isArray(value) ? value : void 0, "object");
23378
23456
  function invalid(message = "ranking selection is invalid \u2014 obtain a new drilldown from stats top") {
@@ -23541,7 +23619,7 @@ var readRankingSelection = /* @__PURE__ */ __name(async (store, input) => {
23541
23619
  };
23542
23620
  }, "readRankingSelection");
23543
23621
 
23544
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-record.js
23622
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-record.js
23545
23623
  var canonical = /* @__PURE__ */ __name((value, nested = false) => Array.isArray(value) ? value.map((one2) => canonical(one2, true)) : value !== null && typeof value === "object" ? Object.fromEntries(Object.entries(value).filter(([, one2]) => one2 !== void 0 && (nested || one2 !== false)).sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0).map(([key, one2]) => [key, canonical(one2, true)])) : value, "canonical");
23546
23624
  var searchRecordOf = /* @__PURE__ */ __name((command, params) => ({
23547
23625
  command,
@@ -23551,7 +23629,7 @@ var searchRecordOf = /* @__PURE__ */ __name((command, params) => ({
23551
23629
  fieldsVersion: FIELD_VERSION
23552
23630
  }), "searchRecordOf");
23553
23631
 
23554
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/admin-statistics.js
23632
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/admin-statistics.js
23555
23633
  function invalid2(message) {
23556
23634
  throw new CliError("validation_error", message);
23557
23635
  }
@@ -23845,10 +23923,10 @@ var adminStatisticsService = /* @__PURE__ */ __name((deps) => ({
23845
23923
  }, "evidence")
23846
23924
  }), "adminStatisticsService");
23847
23925
 
23848
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/archive.js
23926
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/archive.js
23849
23927
  import { setTimeout as sleep3 } from "node:timers/promises";
23850
23928
 
23851
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/backfill-estimate.js
23929
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/backfill-estimate.js
23852
23930
  var REQUEST_MS = 400;
23853
23931
  var estimateBackfill = /* @__PURE__ */ __name(({ ranges, held, newest, page, maxPages, pauseMs }) => {
23854
23932
  const lowest = ranges[0];
@@ -23871,13 +23949,13 @@ var estimateBackfill = /* @__PURE__ */ __name(({ ranges, held, newest, page, max
23871
23949
  };
23872
23950
  }, "estimateBackfill");
23873
23951
 
23874
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/recovery.js
23952
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/recovery.js
23875
23953
  var withRecovery = /* @__PURE__ */ __name((error) => ({
23876
23954
  ...error,
23877
23955
  retryable: typeof error.retryable === "boolean" ? error.retryable : error.code === "rate_limited" || error.status === 429
23878
23956
  }), "withRecovery");
23879
23957
 
23880
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/batch.js
23958
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/batch.js
23881
23959
  var actionable = /* @__PURE__ */ __name((error) => {
23882
23960
  if (isCliFailure(error))
23883
23961
  return withRecovery({ code: error.code, message: error.message, ...error.details });
@@ -23960,7 +24038,7 @@ var mergeBatches = /* @__PURE__ */ __name((a, b) => {
23960
24038
  };
23961
24039
  }, "mergeBatches");
23962
24040
 
23963
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/patience.js
24041
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/patience.js
23964
24042
  import { setTimeout as sleep2 } from "node:timers/promises";
23965
24043
  var LONGEST_WAIT_MS = 5 * 60 * 1e3;
23966
24044
  var patiently = /* @__PURE__ */ __name(async (request, note, stop) => {
@@ -23983,7 +24061,7 @@ var patiently = /* @__PURE__ */ __name(async (request, note, stop) => {
23983
24061
  }
23984
24062
  }, "patiently");
23985
24063
 
23986
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/conversations/link.js
24064
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/conversations/link.js
23987
24065
  var RULES_VERSION = 5;
23988
24066
  var LOOK_BACK = 50;
23989
24067
  var SAME_SENDER_WITHIN = 10;
@@ -24073,7 +24151,7 @@ var latest = /* @__PURE__ */ __name((window2, matches) => {
24073
24151
  var sameThread = /* @__PURE__ */ __name((a, b) => a.threadId === b.threadId, "sameThread");
24074
24152
  var link2 = /* @__PURE__ */ __name((message, parentId, source, kind, confidence, method) => ({ messageId: message.id, parentId, source, kind, confidence, method }), "link");
24075
24153
 
24076
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/images/context/index.js
24154
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/images/context/index.js
24077
24155
  var CONTEXT_MESSAGES = 3;
24078
24156
  var CONTEXT_MINUTES = 10;
24079
24157
  var MAX_CHARS = 1200;
@@ -24097,12 +24175,12 @@ var context = {
24097
24175
  }, "describe")
24098
24176
  };
24099
24177
 
24100
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/images/registry.js
24178
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/images/registry.js
24101
24179
  var BUILT_INS = [context];
24102
24180
  var providers = [...BUILT_INS];
24103
24181
  var registeredImageProviders = /* @__PURE__ */ __name(() => providers, "registeredImageProviders");
24104
24182
 
24105
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/conversations.js
24183
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/conversations.js
24106
24184
  var READ_PAGE = 5e3;
24107
24185
  var CHAIN = 50;
24108
24186
  var CONVERSATION_QUERY = {
@@ -24254,7 +24332,7 @@ var sized = /* @__PURE__ */ __name((size4) => {
24254
24332
  return size4;
24255
24333
  }, "sized");
24256
24334
 
24257
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/embeddings-maintenance.js
24335
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/embeddings-maintenance.js
24258
24336
  var REFRESH_BOUNDS = { maxChats: 20, maxChunks: 2e3 };
24259
24337
  var MESSAGE_PAGE = 5e3;
24260
24338
  var PER_SESSION = 8;
@@ -24273,7 +24351,7 @@ var embeddingTarget = /* @__PURE__ */ __name((deps, choice = DEFAULT_TEXT_MODEL)
24273
24351
  price: remote.price,
24274
24352
  installed: true,
24275
24353
  perBatch: PER_REQUEST * concurrency,
24276
- open: /* @__PURE__ */ __name(async () => (await import("./remote-WHYV35IF.js")).openRemote(remote, apiKey, { concurrency }), "open")
24354
+ open: /* @__PURE__ */ __name(async () => (await import("./remote-2CTCIQGF.js")).openRemote(remote, apiKey, { concurrency }), "open")
24277
24355
  };
24278
24356
  }
24279
24357
  const model = textModel(choice);
@@ -24290,7 +24368,7 @@ var embeddingTarget = /* @__PURE__ */ __name((deps, choice = DEFAULT_TEXT_MODEL)
24290
24368
  if (!isTextModelInstalled(model, directory2))
24291
24369
  throw notDownloaded(model.id);
24292
24370
  if (apart) {
24293
- const { openProcess } = await import("./process-XNN4WG6N.js");
24371
+ const { openProcess } = await import("./process-OBWUKBMX.js");
24294
24372
  return openProcess(model, directory2, { threads: threads ?? defaultThreads() });
24295
24373
  }
24296
24374
  return openEmbedder(model, directory2, { threads: threads ?? defaultThreads() });
@@ -24579,7 +24657,7 @@ var shaped = /* @__PURE__ */ __name(({ chatId, builtAt, algorithmVersion, pendin
24579
24657
  return { ...one2, state };
24580
24658
  }, "shaped");
24581
24659
 
24582
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-catchup.js
24660
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-catchup.js
24583
24661
  var CATCH_UP_BOUNDS = { maxChunks: 500, maxMessages: 1e4, timeMs: 3e4 };
24584
24662
  var validateCatchUpBounds = /* @__PURE__ */ __name((options) => {
24585
24663
  for (const [key, value, maximum] of [
@@ -24632,7 +24710,7 @@ var catchUpSearch = /* @__PURE__ */ __name(async (deps, chat, options, signal, c
24632
24710
  }
24633
24711
  }, "catchUpSearch");
24634
24712
 
24635
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/archive.js
24713
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/archive.js
24636
24714
  var pushed = /* @__PURE__ */ __name((deps, what) => {
24637
24715
  if (deps.reads === "store") {
24638
24716
  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`);
@@ -24998,7 +25076,7 @@ var timeOfKey = /* @__PURE__ */ __name(async (store, account2, chatId, key, byTi
24998
25076
  return message?.timestamp ?? fallback;
24999
25077
  }, "timeOfKey");
25000
25078
 
25001
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/archive-gaps.js
25079
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/archive-gaps.js
25002
25080
  import { createHash as createHash6, randomUUID as randomUUID4 } from "node:crypto";
25003
25081
  var GAP_BOUNDS = { maxGaps: 5, limit: 500, timeMs: 3e4 };
25004
25082
  var validateRepair = /* @__PURE__ */ __name((messenger, options) => {
@@ -25135,16 +25213,16 @@ var gapsService = /* @__PURE__ */ __name((deps) => {
25135
25213
  return { plan, repair };
25136
25214
  }, "gapsService");
25137
25215
 
25138
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/attachments.js
25216
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/attachments.js
25139
25217
  import { createHash as createHash8 } from "node:crypto";
25140
25218
  import { constants as constants2, mkdirSync as mkdirSync2 } from "node:fs";
25141
25219
  import { lstat as lstat4, open as open6, readFile, stat as stat2 } from "node:fs/promises";
25142
25220
 
25143
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/directory.js
25221
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/directory.js
25144
25222
  import { lstat as lstat2, readdir as readdir2, realpath as realpath3 } from "node:fs/promises";
25145
25223
  import { basename as basename4, join as join8, relative as relative2, sep as sep2 } from "node:path";
25146
25224
 
25147
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/sends/upload.js
25225
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/sends/upload.js
25148
25226
  import { openAsBlob, realpathSync } from "node:fs";
25149
25227
  import { open as open4, stat } from "node:fs/promises";
25150
25228
  import { basename as basename3, dirname as dirname3, extname, isAbsolute as isAbsolute2, relative, resolve as resolve5, sep } from "node:path";
@@ -25346,7 +25424,7 @@ var readStickerFile = /* @__PURE__ */ __name(async (path, maxBytes, read) => {
25346
25424
  return { name, source };
25347
25425
  }, "readStickerFile");
25348
25426
 
25349
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/directory.js
25427
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/directory.js
25350
25428
  var MAX_FILES = 1e4;
25351
25429
  var directoryPaths = /* @__PURE__ */ __name(async (store, chat, directory2, app, env) => {
25352
25430
  if (refusedPlace(directory2, app, env))
@@ -25415,15 +25493,15 @@ var directoryPaths = /* @__PURE__ */ __name(async (store, chat, directory2, app,
25415
25493
  return choices;
25416
25494
  }, "directoryPaths");
25417
25495
 
25418
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/documents.js
25496
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/documents.js
25419
25497
  import { posix } from "node:path";
25420
25498
 
25421
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/container.js
25499
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/container.js
25422
25500
  import { setImmediate as tick } from "node:timers/promises";
25423
25501
  import { crc32 } from "node:zlib";
25424
25502
  var import_xmldom = __toESM(require_lib(), 1);
25425
25503
 
25426
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/encoding.js
25504
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/encoding.js
25427
25505
  var import_chardet = __toESM(require_lib2(), 1);
25428
25506
  var import_iconv_lite = __toESM(require_lib3(), 1);
25429
25507
  var SAMPLE = 65536;
@@ -25525,7 +25603,7 @@ var decodeXml = /* @__PURE__ */ __name((bytes2) => {
25525
25603
  return result.text;
25526
25604
  }, "decodeXml");
25527
25605
 
25528
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/container.js
25606
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/container.js
25529
25607
  var MAX_PART = 10 * 1024 * 1024;
25530
25608
  var MAX_ENTRIES = 1e3;
25531
25609
  var decoder = new TextDecoder("utf-8", { fatal: true });
@@ -25740,7 +25818,7 @@ var elements = /* @__PURE__ */ __name((node, name, namespace) => {
25740
25818
  return found;
25741
25819
  }, "elements");
25742
25820
 
25743
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/sheets.js
25821
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/sheets.js
25744
25822
  var columnName = /* @__PURE__ */ __name((column) => {
25745
25823
  let name = "";
25746
25824
  for (let rest = column; rest > 0; rest = Math.floor((rest - 1) / 26))
@@ -25795,7 +25873,7 @@ var sheetText = /* @__PURE__ */ __name((sheets2, maxChars = MAX_TEXT_CHARS) => {
25795
25873
  return { text: parts.join("").trim(), truncated: false };
25796
25874
  }, "sheetText");
25797
25875
 
25798
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/documents.js
25876
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/documents.js
25799
25877
  var OFFICE = "urn:oasis:names:tc:opendocument:xmlns:office:1.0";
25800
25878
  var TEXT = "urn:oasis:names:tc:opendocument:xmlns:text:1.0";
25801
25879
  var TABLE = "urn:oasis:names:tc:opendocument:xmlns:table:1.0";
@@ -26195,10 +26273,10 @@ var readDocument = /* @__PURE__ */ __name(async (bytes2, kind, signal) => {
26195
26273
  }
26196
26274
  }, "readDocument");
26197
26275
 
26198
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/extract.js
26276
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/extract.js
26199
26277
  import { extname as extname3 } from "node:path";
26200
26278
 
26201
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/engine.js
26279
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/engine.js
26202
26280
  import { readFileSync } from "node:fs";
26203
26281
  import { dirname as dirname4, extname as extname2, join as join9 } from "node:path";
26204
26282
  import { fileURLToPath } from "node:url";
@@ -26259,7 +26337,7 @@ var derived = /* @__PURE__ */ __name((bytes2, extractor, read) => {
26259
26337
  }
26260
26338
  }, "derived");
26261
26339
 
26262
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/image/index.js
26340
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/image/index.js
26263
26341
  var IMAGES = /* @__PURE__ */ new Set([".jpg", ".jpeg", ".png", ".webp", ".gif", ".heic", ".tif", ".tiff", ".bmp"]);
26264
26342
  var image2 = {
26265
26343
  id: "image",
@@ -26268,7 +26346,7 @@ var image2 = {
26268
26346
  read: /* @__PURE__ */ __name(async () => ({ status: "needs-agent" }), "read")
26269
26347
  };
26270
26348
 
26271
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/doc/index.js
26349
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/doc/index.js
26272
26350
  var OLE = "\xD0\xCF\xE0\xA1\xB1\xE1";
26273
26351
  var doc = {
26274
26352
  id: "doc",
@@ -26280,7 +26358,7 @@ var doc = {
26280
26358
  }), "read")
26281
26359
  };
26282
26360
 
26283
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/docx/index.js
26361
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/docx/index.js
26284
26362
  var DOCX = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
26285
26363
  var docx = {
26286
26364
  id: "docx",
@@ -26293,7 +26371,7 @@ var docx = {
26293
26371
  }), "read")
26294
26372
  };
26295
26373
 
26296
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/markup.js
26374
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/markup.js
26297
26375
  var import_iconv_lite2 = __toESM(require_lib3(), 1);
26298
26376
  var RTF_SKIPPED = /* @__PURE__ */ new Set([
26299
26377
  "fonttbl",
@@ -26469,7 +26547,7 @@ var htmlText = /* @__PURE__ */ __name((source) => {
26469
26547
  }, "htmlText");
26470
26548
  var safeChar = /* @__PURE__ */ __name((code, fallback) => code > 0 && code <= 1114111 ? String.fromCodePoint(code) : fallback, "safeChar");
26471
26549
 
26472
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/html/page.js
26550
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/html/page.js
26473
26551
  var clean = /* @__PURE__ */ __name((value) => typeof value === "string" ? value.replace(/\s+/g, " ").trim() : "", "clean");
26474
26552
  var namesIn = /* @__PURE__ */ __name((value) => [value].flat().map((entry) => typeof entry === "string" ? clean(entry) : clean(entry?.name)).filter(Boolean).join(", "), "namesIn");
26475
26553
  var jsonLdNodes = /* @__PURE__ */ __name((document) => {
@@ -26525,7 +26603,7 @@ var markdownSections = /* @__PURE__ */ __name((text2) => {
26525
26603
  return found.map((section, index) => ({ ...section, end: found[index + 1]?.start ?? text2.length }));
26526
26604
  }, "markdownSections");
26527
26605
 
26528
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/html/index.js
26606
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/html/index.js
26529
26607
  var HTML = /* @__PURE__ */ new Set([".html", ".htm", ".xhtml"]);
26530
26608
  var first = /* @__PURE__ */ __name((...values) => values.find((value) => typeof value === "string" && value !== ""), "first");
26531
26609
  var loaded = /* @__PURE__ */ __name(async (load, name) => {
@@ -26596,7 +26674,7 @@ var html = {
26596
26674
  }, "read")
26597
26675
  };
26598
26676
 
26599
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/office/index.js
26677
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/office/index.js
26600
26678
  var office = {
26601
26679
  id: "office",
26602
26680
  version: documentExtractor("odt"),
@@ -26607,7 +26685,7 @@ var office = {
26607
26685
  }, "read")
26608
26686
  };
26609
26687
 
26610
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/pdf/index.js
26688
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/pdf/index.js
26611
26689
  var pdf = {
26612
26690
  id: "pdf",
26613
26691
  version: "unpdf",
@@ -26674,7 +26752,7 @@ var pdf = {
26674
26752
  }), "read")
26675
26753
  };
26676
26754
 
26677
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/plain/index.js
26755
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/plain/index.js
26678
26756
  var PLAIN = /* @__PURE__ */ new Set([".txt", ".md", ".markdown", ".csv", ".tsv", ".json", ".log"]);
26679
26757
  var isPlain = /* @__PURE__ */ __name((hint) => PLAIN.has(extensionOf(hint)) || hint.mime?.startsWith("text/") || hint.mime === "application/json", "isPlain");
26680
26758
  var readPlain = /* @__PURE__ */ __name((bytes2) => {
@@ -26694,7 +26772,7 @@ var plain = {
26694
26772
  read: /* @__PURE__ */ __name(async (bytes2) => readPlain(bytes2), "read")
26695
26773
  };
26696
26774
 
26697
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/rtf/index.js
26775
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/rtf/index.js
26698
26776
  var rtf = {
26699
26777
  id: "rtf",
26700
26778
  version: "v1",
@@ -26702,10 +26780,10 @@ var rtf = {
26702
26780
  read: /* @__PURE__ */ __name(async (bytes2) => derived(bytes2, "rtf:v1", rtfText), "read")
26703
26781
  };
26704
26782
 
26705
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
26783
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
26706
26784
  import { basename as basename5 } from "node:path";
26707
26785
 
26708
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/csv-spans.js
26786
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/csv-spans.js
26709
26787
  var delimitedSpans = /* @__PURE__ */ __name((text2, delimiter, maxCells = 1e4) => {
26710
26788
  const cells = [];
26711
26789
  let row = 1, column = 1, start = 0, quoted = false, truncated = false;
@@ -26743,7 +26821,7 @@ var delimitedSpans = /* @__PURE__ */ __name((text2, delimiter, maxCells = 1e4) =
26743
26821
  return { cells, truncated };
26744
26822
  }, "delimitedSpans");
26745
26823
 
26746
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
26824
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/sheets/index.js
26747
26825
  var DELIMITED = {
26748
26826
  ".csv": ",",
26749
26827
  ".tsv": " ",
@@ -26782,7 +26860,7 @@ var sheets = {
26782
26860
  }, "read")
26783
26861
  };
26784
26862
 
26785
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/readers/registry.js
26863
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/readers/registry.js
26786
26864
  var BUILT_INS2 = [office, pdf, docx, doc, rtf, html, sheets, plain, image2];
26787
26865
  var HEAD_BYTES = 1024;
26788
26866
  var readers = [...BUILT_INS2];
@@ -26792,7 +26870,7 @@ var readWithRegistry = /* @__PURE__ */ __name(async (bytes2, hint, context2) =>
26792
26870
  return reader ? reader.read(bytes2, hint, context2) : { status: "unsupported" };
26793
26871
  }, "readWithRegistry");
26794
26872
 
26795
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/extract.js
26873
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/extract.js
26796
26874
  var importEngine = /* @__PURE__ */ __name((name) => importFrom(new URL("attachments/extract.js", import.meta.resolve("@wirecat/cli-core")).href, name), "importEngine");
26797
26875
  var extensionOf2 = /* @__PURE__ */ __name(({ name, path }) => extname3(name ?? path).toLowerCase(), "extensionOf");
26798
26876
  var extractText = /* @__PURE__ */ __name(async (bytes2, hint, load, signal, env = process.env) => {
@@ -27871,7 +27949,7 @@ function imageSize(input) {
27871
27949
  }
27872
27950
  __name(imageSize, "imageSize");
27873
27951
 
27874
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/ocr.js
27952
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/ocr.js
27875
27953
  var MAX_PAGES = 20;
27876
27954
  var MAX_PIXELS = 2e7;
27877
27955
  var cancelled2 = /* @__PURE__ */ __name((signal) => {
@@ -28022,7 +28100,7 @@ var ocrPdf = /* @__PURE__ */ __name(async (bytes2, pipeline2, load, signal) => {
28022
28100
  }
28023
28101
  }, "ocrPdf");
28024
28102
 
28025
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/pdf-preview.js
28103
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/pdf-preview.js
28026
28104
  var pdfPreview = /* @__PURE__ */ __name(async (bytes2, page, signal, load = importEngine, env = process.env) => {
28027
28105
  const limits = pdfPreviewLimits(env);
28028
28106
  const cancelled5 = /* @__PURE__ */ __name(() => {
@@ -28099,7 +28177,7 @@ var pdfPreview = /* @__PURE__ */ __name(async (bytes2, page, signal, load = impo
28099
28177
  }
28100
28178
  }, "pdfPreview");
28101
28179
 
28102
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/attachments/transfer.js
28180
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/attachments/transfer.js
28103
28181
  import { createHash as createHash7 } from "node:crypto";
28104
28182
  import { constants } from "node:fs";
28105
28183
  import { lstat as lstat3, open as open5 } from "node:fs/promises";
@@ -28207,7 +28285,7 @@ var transferMime = /* @__PURE__ */ __name((head, hint, name = null) => {
28207
28285
  return hint !== null && /^[a-z0-9.+-]+\/[a-z0-9.+-]+$/i.test(hint) ? hint : "application/octet-stream";
28208
28286
  }, "transferMime");
28209
28287
 
28210
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/file-download.js
28288
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/file-download.js
28211
28289
  import { createWriteStream, mkdirSync } from "node:fs";
28212
28290
  import { link as link3, rm } from "node:fs/promises";
28213
28291
  import { join as join10, resolve as resolve6 } from "node:path";
@@ -28321,7 +28399,7 @@ var save = /* @__PURE__ */ __name(async (file, directory2, fallbackName, { uniqu
28321
28399
  }
28322
28400
  }, "save");
28323
28401
 
28324
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/attachments.js
28402
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/attachments.js
28325
28403
  var ATTACHMENT_QUERY = {
28326
28404
  entity: "attachment",
28327
28405
  backend: "sql",
@@ -28410,7 +28488,7 @@ var keep = /* @__PURE__ */ __name(async (store, file, extraction, bytes2, sha) =
28410
28488
  });
28411
28489
  }
28412
28490
  }, "keep");
28413
- var itemOf = /* @__PURE__ */ __name((account2, view) => ({
28491
+ var itemOf2 = /* @__PURE__ */ __name((account2, view) => ({
28414
28492
  message: formatLocator({ ...account2, chat: view.chatId, message: view.messageId }),
28415
28493
  kind: view.kind,
28416
28494
  position: view.position + 1,
@@ -28622,7 +28700,7 @@ var attachmentsService = /* @__PURE__ */ __name((deps) => ({
28622
28700
  }
28623
28701
  const where = query ? queryFilter(query, attachmentColumns(chats), { command: "attachments list" }) : void 0;
28624
28702
  const views = await store.attachments.attachments({ ...where ? { where } : {}, offset, limit: limit + 1 });
28625
- return { items: views.slice(0, limit).map((view) => itemOf(account2, view)), has_more: views.length > limit };
28703
+ return { items: views.slice(0, limit).map((view) => itemOf2(account2, view)), has_more: views.length > limit };
28626
28704
  }, "list"),
28627
28705
  show: /* @__PURE__ */ __name(async ({ chat, message, attachment: attachment2, page, load, ...window2 }) => {
28628
28706
  validateWindow(window2);
@@ -28744,7 +28822,7 @@ var attachmentsService = /* @__PURE__ */ __name((deps) => ({
28744
28822
  }, "setText")
28745
28823
  }), "attachmentsService");
28746
28824
 
28747
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/chat-documents.js
28825
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/chat-documents.js
28748
28826
  var chatDocumentsService = /* @__PURE__ */ __name((deps) => ({
28749
28827
  list: /* @__PURE__ */ __name(async (chat, { limit, offset, ref }) => {
28750
28828
  const store = await accountStore(deps);
@@ -28774,7 +28852,7 @@ var chatDocumentsService = /* @__PURE__ */ __name((deps) => ({
28774
28852
  }, "list")
28775
28853
  }), "chatDocumentsService");
28776
28854
 
28777
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/retention.js
28855
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/retention.js
28778
28856
  var observationDuration = /* @__PURE__ */ __name((text2, flag) => {
28779
28857
  const match = /^(\d+(?:\.\d+)?)([smhdw])$/.exec(text2);
28780
28858
  const units2 = { s: 1e3, m: 6e4, h: 36e5, d: 864e5, w: 6048e5 };
@@ -28861,7 +28939,7 @@ var isRetentionSelection = /* @__PURE__ */ __name((selection) => {
28861
28939
  }
28862
28940
  }, "isRetentionSelection");
28863
28941
 
28864
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/counters.js
28942
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/counters.js
28865
28943
  var counterFields = /* @__PURE__ */ __name((text2 = "views,reactions,comments") => {
28866
28944
  const fields = text2.split(",").map((one2) => one2.trim());
28867
28945
  if (!fields.length || fields.some((one2) => !COUNTER_FIELDS.includes(one2)) || new Set(fields).size !== fields.length)
@@ -29068,7 +29146,7 @@ var countersService = /* @__PURE__ */ __name((deps) => {
29068
29146
  };
29069
29147
  }, "countersService");
29070
29148
 
29071
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-refresh.js
29149
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-refresh.js
29072
29150
  var SYNC_KEY = "messages.sync-first";
29073
29151
  var SYNC_BOUNDS = { maxChats: 5, timeMs: 3e4, maxMessages: 500 };
29074
29152
  var keyOf2 = /* @__PURE__ */ __name((chat) => JSON.stringify([chat.account.provider, chat.account.account, chat.chatId]), "keyOf");
@@ -29200,7 +29278,7 @@ var withRefresh = /* @__PURE__ */ __name((found, refreshed) => ({
29200
29278
  ...!refreshed || refreshed.complete ? {} : { coverage: { ...found.coverage, state: "stale" } }
29201
29279
  }), "withRefresh");
29202
29280
 
29203
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/embeddings-search.js
29281
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/embeddings-search.js
29204
29282
  var CANDIDATES = 50;
29205
29283
  var WORD_HITS = 200;
29206
29284
  var RRF_K = 60;
@@ -29475,13 +29553,13 @@ var meanOf = /* @__PURE__ */ __name((vectors) => {
29475
29553
  return mean2.map((value) => value / length);
29476
29554
  }, "meanOf");
29477
29555
 
29478
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/embeddings.js
29556
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/embeddings.js
29479
29557
  var embeddingsService = /* @__PURE__ */ __name((deps) => ({
29480
29558
  ...embeddingsMaintenance(deps),
29481
29559
  ...embeddingsSearch(deps)
29482
29560
  }), "embeddingsService");
29483
29561
 
29484
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/folders.js
29562
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/folders.js
29485
29563
  var foldersService = /* @__PURE__ */ __name((deps) => {
29486
29564
  const online = /* @__PURE__ */ __name(async (command) => {
29487
29565
  if (deps.offline)
@@ -29622,7 +29700,7 @@ var foldersService = /* @__PURE__ */ __name((deps) => {
29622
29700
  };
29623
29701
  }, "foldersService");
29624
29702
 
29625
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/inbox.js
29703
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/inbox.js
29626
29704
  var INBOX_CHATS = 20;
29627
29705
  var REVIEW_DAYS = 3;
29628
29706
  var UNANSWERED_HOURS = 24;
@@ -29830,7 +29908,7 @@ var inboxService = /* @__PURE__ */ __name((deps) => {
29830
29908
  };
29831
29909
  }, "inboxService");
29832
29910
 
29833
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/mentions.js
29911
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/mentions.js
29834
29912
  var REVIEW_COUNT = 500;
29835
29913
  var mentionsService = /* @__PURE__ */ __name((deps) => {
29836
29914
  const located = /* @__PURE__ */ __name(async () => {
@@ -29909,7 +29987,7 @@ var mentionsService = /* @__PURE__ */ __name((deps) => {
29909
29987
  };
29910
29988
  }, "mentionsService");
29911
29989
 
29912
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/message-link.js
29990
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/message-link.js
29913
29991
  var fileLinks = /* @__PURE__ */ __name((attachments) => hitFiles(attachments).map(({ position, kind, name }) => ({
29914
29992
  position,
29915
29993
  kind,
@@ -29958,7 +30036,7 @@ var validatePermalink = /* @__PURE__ */ __name((link4) => {
29958
30036
  return { url: link4.url, access: link4.access, reason: link4.reason };
29959
30037
  }, "validatePermalink");
29960
30038
 
29961
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/pin-duration.js
30039
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/pin-duration.js
29962
30040
  var spokenSeconds = /* @__PURE__ */ __name((seconds) => {
29963
30041
  if (seconds % 86400 === 0 && seconds > 86400)
29964
30042
  return `${seconds / 86400}d`;
@@ -29990,7 +30068,7 @@ var pinDurationOf = /* @__PURE__ */ __name((value, allowed, flag = "--expire-tim
29990
30068
  return seconds;
29991
30069
  }, "pinDurationOf");
29992
30070
 
29993
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/sends/send-as.js
30071
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/sends/send-as.js
29994
30072
  var sendAsCheck = /* @__PURE__ */ __name((connection, sendAs) => {
29995
30073
  if (sendAs === void 0) {
29996
30074
  const saved = connection.savedSender?.bind(connection);
@@ -30015,7 +30093,7 @@ var typedSendAs = /* @__PURE__ */ __name((typed) => {
30015
30093
  return sendAs;
30016
30094
  }, "typedSendAs");
30017
30095
 
30018
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/search/total.js
30096
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/search/total.js
30019
30097
  var TOTAL_CAP = 1e4;
30020
30098
  var totalOf = /* @__PURE__ */ __name((count3, shown, hasMore, exact = true) => {
30021
30099
  const least = shown + (hasMore ? 1 : 0);
@@ -30026,7 +30104,7 @@ var totalOf = /* @__PURE__ */ __name((count3, shown, hasMore, exact = true) => {
30026
30104
  return { value: count3, relation: exact ? "eq" : "gte" };
30027
30105
  }, "totalOf");
30028
30106
 
30029
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/search/lucene/meaning-parts.js
30107
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/search/lucene/meaning-parts.js
30030
30108
  var WORD_FIELDS = /* @__PURE__ */ new Set(["text", "exact"]);
30031
30109
  var fieldsOfQuery = /* @__PURE__ */ __name((root, everything) => {
30032
30110
  let narrows = false;
@@ -30055,7 +30133,7 @@ var meaningWords = /* @__PURE__ */ __name((root) => {
30055
30133
  return wanted(root).join(" ").trim();
30056
30134
  }, "meaningWords");
30057
30135
 
30058
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/search/question-plan.js
30136
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/search/question-plan.js
30059
30137
  var words2 = /* @__PURE__ */ __name((text2) => normalize(text2).match(/[\p{L}\p{N}]+/gu) ?? [], "words");
30060
30138
  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"));
30061
30139
  var questionWord = /\b(?:what|which|how|who|where|when|can|could|should)\b|(?:^|\s)(?:сколько|какой|какая|какие|какое|кто|кому|кем|где|когда|как|что|можно|может|могут|ли)(?:\s|$)/iu;
@@ -30188,7 +30266,7 @@ var questionLookup = /* @__PURE__ */ __name((text2) => {
30188
30266
  return terms.length ? anyOfTerms(terms, plan.scope) : void 0;
30189
30267
  }, "questionLookup");
30190
30268
 
30191
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-combined.js
30269
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-combined.js
30192
30270
  var COMBINED_DEFAULTS = { candidateDepth: 300, rrfK: 60, rerank: "all", chatCap: 0 };
30193
30271
  var tokensOf = /* @__PURE__ */ __name((text2) => normalize(text2).match(/[\p{L}\p{N}\p{Co}\p{M}]+/gu) ?? [], "tokensOf");
30194
30272
  var searchCombined = /* @__PURE__ */ __name(async (store, account2, request, messenger = {}, options = COMBINED_DEFAULTS) => {
@@ -30381,7 +30459,7 @@ var signals = /* @__PURE__ */ __name((hit, terms, corrections, execution, mode,
30381
30459
  return mode === "coverage" ? coverage2 * 4 : mode === "proximity" ? proximity : mode === "phrase" ? phrase : coverage2 * 4 + proximity + phrase;
30382
30460
  }, "signals");
30383
30461
 
30384
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-discovery.js
30462
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-discovery.js
30385
30463
  var MEANING_DEPTH = 100;
30386
30464
  var RRF_K2 = 60;
30387
30465
  var RERANK_DEPTH = 50;
@@ -30706,7 +30784,7 @@ var mixedWithReranker = /* @__PURE__ */ __name((head, scores) => {
30706
30784
  })).sort((a, b) => b.mixed - a.mixed).map(({ hit }) => hit);
30707
30785
  }, "mixedWithReranker");
30708
30786
 
30709
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/thread-context.js
30787
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/thread-context.js
30710
30788
  var THREAD_BOUNDS = { maxHops: 8, maxMessages: 50, maxBytes: 65536, withinMs: 864e5 };
30711
30789
  var bytes = /* @__PURE__ */ __name((items, links) => Buffer.byteLength(JSON.stringify({ items, links }), "utf8"), "bytes");
30712
30790
  var threadBounds = /* @__PURE__ */ __name((options = {}) => {
@@ -30905,7 +30983,7 @@ var readThreadContext = /* @__PURE__ */ __name(async (store, account2, chat, mes
30905
30983
  return result;
30906
30984
  }, "readThreadContext");
30907
30985
 
30908
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-archive-search.js
30986
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-archive-search.js
30909
30987
  var SEARCH_FILL_MS = 200;
30910
30988
  var statsStore = /* @__PURE__ */ __name(async (store, account2, request, messenger = {}) => {
30911
30989
  const stop = Date.now() + SEARCH_FILL_MS;
@@ -30974,12 +31052,12 @@ var accountOf2 = /* @__PURE__ */ __name((hit) => {
30974
31052
  }, "accountOf");
30975
31053
  var keyOf3 = /* @__PURE__ */ __name(({ provider, account: account2 }) => `${provider}/${account2}`, "keyOf");
30976
31054
 
30977
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/pictures.js
31055
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/pictures.js
30978
31056
  import { createHash as createHash9 } from "node:crypto";
30979
31057
  import { readFile as readFile2, stat as stat3 } from "node:fs/promises";
30980
31058
  import { setTimeout as sleep4 } from "node:timers/promises";
30981
31059
 
30982
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/models.js
31060
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/models.js
30983
31061
  var GROUP_SETTINGS = [
30984
31062
  "allCanPin",
30985
31063
  "onlyAdminsAdd",
@@ -30993,7 +31071,7 @@ var ADMIN_RIGHTS = ["read", "members", "admins", "info", "pin", "link", "post",
30993
31071
  var senderIsMe = /* @__PURE__ */ __name((message, account2) => message.outgoing === true || message.senderId !== null && String(message.senderId) === account2, "senderIsMe");
30994
31072
  var MEDIA_KINDS = ["photo", "video", "file", "audio", "link"];
30995
31073
 
30996
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/pictures.js
31074
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/pictures.js
30997
31075
  var PICTURE_MAX_BYTES = 25 * 1024 * 1024;
30998
31076
  var PICTURE_FLOOR = 0.25;
30999
31077
  var PAGE4 = 50;
@@ -31010,7 +31088,7 @@ var picturesService = /* @__PURE__ */ __name((deps) => {
31010
31088
  const directory2 = imageModelsDirectory(deps.env);
31011
31089
  if (!isImageModelInstalled(model2, directory2))
31012
31090
  throw new CliError("not_found", missingModel(model2.id), { reason: "model.not-downloaded", model: model2.id });
31013
- const { openPictureEmbedder } = await import("./embedder-GNGHVJAO.js");
31091
+ const { openPictureEmbedder } = await import("./embedder-JW4W6IZI.js");
31014
31092
  return openPictureEmbedder(model2, directory2);
31015
31093
  }, "open");
31016
31094
  const embedder = /* @__PURE__ */ __name(() => {
@@ -31207,7 +31285,7 @@ var withPictures = /* @__PURE__ */ __name((messages, pictures) => ({
31207
31285
  }, "search")
31208
31286
  }), "withPictures");
31209
31287
 
31210
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-meaning.js
31288
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-meaning.js
31211
31289
  var meaningLane = /* @__PURE__ */ __name((deps) => async (question, accounts, shared, within) => {
31212
31290
  const target2 = embeddingTarget(deps, DEFAULT_TEXT_MODEL);
31213
31291
  const skipped = /* @__PURE__ */ __name((reason, step) => ({
@@ -31275,7 +31353,7 @@ var meaningLane = /* @__PURE__ */ __name((deps) => async (question, accounts, sh
31275
31353
  }
31276
31354
  }, "meaningLane");
31277
31355
 
31278
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages-rerank.js
31356
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages-rerank.js
31279
31357
  var rerankLane = /* @__PURE__ */ __name((deps) => {
31280
31358
  const choice = deps.reranker ?? DEFAULT_RERANK_MODEL;
31281
31359
  if (choice === "off")
@@ -31287,9 +31365,9 @@ var rerankLane = /* @__PURE__ */ __name((deps) => {
31287
31365
  return { skipped: { reason: `${model.id} is not downloaded`, step: "models.download", model: model.id } };
31288
31366
  try {
31289
31367
  const warm = deps.embedders;
31290
- const reranker = warm ? await warm.reranker(`rerank:${model.id}`, async () => (await import("./process-XNN4WG6N.js")).openRerankerProcess(model, directory2, {
31368
+ const reranker = warm ? await warm.reranker(`rerank:${model.id}`, async () => (await import("./process-OBWUKBMX.js")).openRerankerProcess(model, directory2, {
31291
31369
  threads: defaultThreads()
31292
- })) : await (await import("./rerank-FBMZVWSH.js")).openReranker(model, directory2);
31370
+ })) : await (await import("./rerank-XDA7NJNH.js")).openReranker(model, directory2);
31293
31371
  return {
31294
31372
  model: model.id,
31295
31373
  score: /* @__PURE__ */ __name((question, passages) => reranker.score(plainWords(question), passages), "score"),
@@ -31309,7 +31387,7 @@ var rerankLane = /* @__PURE__ */ __name((deps) => {
31309
31387
  };
31310
31388
  }, "rerankLane");
31311
31389
 
31312
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/document-pictures.js
31390
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/document-pictures.js
31313
31391
  import { createHash as createHash10 } from "node:crypto";
31314
31392
  var refOf = /* @__PURE__ */ __name((target2) => target2.ref ?? `document:${target2.documentId}`, "refOf");
31315
31393
  var openPictureEmbedderFor = /* @__PURE__ */ __name(async ({ env, command } = {}) => {
@@ -31317,7 +31395,7 @@ var openPictureEmbedderFor = /* @__PURE__ */ __name(async ({ env, command } = {}
31317
31395
  const directory2 = imageModelsDirectory(env);
31318
31396
  if (!isImageModelInstalled(model, directory2))
31319
31397
  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 });
31320
- const { openPictureEmbedder } = await import("./embedder-GNGHVJAO.js");
31398
+ const { openPictureEmbedder } = await import("./embedder-JW4W6IZI.js");
31321
31399
  return openPictureEmbedder(model, directory2);
31322
31400
  }, "openPictureEmbedderFor");
31323
31401
  var savePicture = /* @__PURE__ */ __name(async (store, target2, bytes2, options = {}) => {
@@ -31338,7 +31416,7 @@ var savePicture = /* @__PURE__ */ __name(async (store, target2, bytes2, options
31338
31416
  }, "savePicture");
31339
31417
  var removePicture = /* @__PURE__ */ __name((store, target2) => store.notes.removePicture(refOf(target2)), "removePicture");
31340
31418
 
31341
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/document-source.js
31419
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/document-source.js
31342
31420
  var documentSource = /* @__PURE__ */ __name((note, accounts, profiles, file) => {
31343
31421
  const metadata = note.frontMatter;
31344
31422
  const account2 = accounts.find(({ id: id2 }) => String(id2) === note.folderId);
@@ -31353,7 +31431,7 @@ var documentSource = /* @__PURE__ */ __name((note, accounts, profiles, file) =>
31353
31431
  };
31354
31432
  }, "documentSource");
31355
31433
 
31356
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/notes-title-tier.js
31434
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/notes-title-tier.js
31357
31435
  var plainQueryWords = /* @__PURE__ */ __name((query) => {
31358
31436
  let root;
31359
31437
  try {
@@ -31380,7 +31458,7 @@ var titleTiers = /* @__PURE__ */ __name((hits, words4) => {
31380
31458
  return [...hits].sort((a, b) => rank(a) - rank(b));
31381
31459
  }, "titleTiers");
31382
31460
 
31383
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/notes-search.js
31461
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/notes-search.js
31384
31462
  var storeQuery = /* @__PURE__ */ __name(async (store, text2, { exact, timezone } = {}) => resolvedQuery(store, parsedQuery(text2, exact), timezone), "storeQuery");
31385
31463
  var parsedQuery = /* @__PURE__ */ __name((text2, exact) => validateFields(parseLucene(text2, { ...SEARCH_QUERY, defaultField: exact ? "exact" : "text" })).root, "parsedQuery");
31386
31464
  var resolvedQuery = /* @__PURE__ */ __name(async (store, root, timezone) => {
@@ -31808,7 +31886,8 @@ var searchNotesOf = /* @__PURE__ */ __name(async (store, account2, text2, { acco
31808
31886
  const held = [
31809
31887
  { provider: "notes", account: INTERNAL_NOTES },
31810
31888
  ...(await store.notes.folders()).map(({ id: id2 }) => ({ provider: "notes", account: id2 })),
31811
- ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => ({ provider: "notes", account: id2 }))
31889
+ ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => ({ provider: "notes", account: id2 })),
31890
+ ...[await store.notes.addedAccount()].flatMap((added) => added ? [{ provider: "notes", account: added.id }] : [])
31812
31891
  ];
31813
31892
  const named2 = list2 === void 0 ? { accounts: held, skipped: [] } : fitting(entriesOfList(list2, await listContextOf(store, account2, app)), ["notes", "documents"], what);
31814
31893
  const source = query.source ?? noteSourceOfQuery(text2).source;
@@ -31828,14 +31907,14 @@ var searchNotesOf = /* @__PURE__ */ __name(async (store, account2, text2, { acco
31828
31907
  };
31829
31908
  }, "searchNotesOf");
31830
31909
 
31831
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/events-search.js
31910
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/events-search.js
31832
31911
  var MAX_EVENTS_OFFSET = 1e3;
31833
31912
  var iso = /* @__PURE__ */ __name((at) => at === null ? null : new Date(at).toISOString(), "iso");
31834
31913
  var accountIdsOf = /* @__PURE__ */ __name(async (store, accounts) => {
31835
31914
  const held = await store.accounts.storedAccounts();
31836
31915
  return held.filter((one2) => accounts.some(({ provider, account: account2 }) => one2.provider === provider && one2.account === account2)).map(({ id: id2 }) => String(id2));
31837
31916
  }, "accountIdsOf");
31838
- var calendarAccounts = /* @__PURE__ */ __name(async (store) => (await store.accounts.storedAccounts()).filter(({ provider }) => kindIn(provider) === "events").map(({ provider, account: account2 }) => ({ provider, account: account2 })), "calendarAccounts");
31917
+ var calendarAccounts = /* @__PURE__ */ __name(async (store) => (await store.accounts.storedAccounts()).filter(({ provider }) => holdsKind(provider, "events")).map(({ provider, account: account2 }) => ({ provider, account: account2 })), "calendarAccounts");
31839
31918
  var foundEvent = /* @__PURE__ */ __name((hit, query, foundBy) => ({
31840
31919
  ref: hit.ref,
31841
31920
  provider: hit.account?.provider ?? null,
@@ -31946,7 +32025,7 @@ var searchEvents = /* @__PURE__ */ __name(async (store, query, { limit = 20, off
31946
32025
  };
31947
32026
  }, "searchEvents");
31948
32027
 
31949
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-all.js
32028
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-all.js
31950
32029
  var RESOURCES_SEARCHED = ["messages", "mail", "notes", "events", "crm"];
31951
32030
  var refusal = /* @__PURE__ */ __name((error, text2) => {
31952
32031
  const { reason, span } = error.details ?? {};
@@ -31972,7 +32051,7 @@ var titleWords = /* @__PURE__ */ __name((text2) => {
31972
32051
  })());
31973
32052
  return { words: words4, anyWord: clauses.length > 1 && clauses.every(({ occur }) => occur === "should") };
31974
32053
  }, "titleWords");
31975
- var crmAccounts = /* @__PURE__ */ __name(async (store) => (await store.accounts.accounts()).filter(({ provider }) => kindIn(provider) === "crm"), "crmAccounts");
32054
+ var crmAccounts = /* @__PURE__ */ __name(async (store) => (await store.accounts.accounts()).filter(({ provider }) => holdsKind(provider, "crm")), "crmAccounts");
31976
32055
  var searchAll = /* @__PURE__ */ __name(async (store, account2, asked, messenger = {}, searchMessages = (query) => searchStore(store, account2, query, messenger), meaning) => {
31977
32056
  if (!asked.text.trim())
31978
32057
  throw new CliError("validation_error", "say what to find");
@@ -32020,12 +32099,12 @@ var searchAll = /* @__PURE__ */ __name(async (store, account2, asked, messenger
32020
32099
  if (kind === "messages" && found.coverage)
32021
32100
  coverage2 = found.coverage;
32022
32101
  hasMore ||= found.hasMore;
32023
- const read = found.coverage?.accounts ?? given ?? (await store.accounts.accounts()).filter(({ provider }) => kindIn(provider) === kind);
32102
+ const read = found.coverage?.accounts ?? given ?? (await store.accounts.accounts()).filter(({ provider }) => holdsKind(provider, kind));
32024
32103
  for (const one2 of found.skipped ?? [])
32025
32104
  if (!skipped.some(({ source }) => source === one2.source))
32026
32105
  skipped.push(one2);
32027
32106
  accounts.push(...read.map(({ provider, account: account3 }) => ({ resource: kind, provider, account: account3 })));
32028
- const itemOf2 = /* @__PURE__ */ __name((hit, foundBy) => {
32107
+ const itemOf3 = /* @__PURE__ */ __name((hit, foundBy) => {
32029
32108
  const at = parseLocator(hit.locator);
32030
32109
  return {
32031
32110
  kind: kind === "mail" ? "mail" : "message",
@@ -32042,7 +32121,7 @@ var searchAll = /* @__PURE__ */ __name(async (store, account2, asked, messenger
32042
32121
  foundBy
32043
32122
  };
32044
32123
  }, "itemOf");
32045
- const byWords = found.items.map((hit) => itemOf2(hit, ["words"]));
32124
+ const byWords = found.items.map((hit) => itemOf3(hit, ["words"]));
32046
32125
  if (!meaning || request.exact || kind === "messages" && request.backend === "server")
32047
32126
  return byWords;
32048
32127
  const filters = filtersBeside(request.text);
@@ -32071,7 +32150,7 @@ var searchAll = /* @__PURE__ */ __name(async (store, account2, asked, messenger
32071
32150
  if (held && discovers)
32072
32151
  held.score = Math.max(held.score, vote);
32073
32152
  else
32074
- fused2.set(hit.locator, { item: held?.item ?? itemOf2(hit, ["meaning"]), score: (held?.score ?? 0) + vote });
32153
+ fused2.set(hit.locator, { item: held?.item ?? itemOf3(hit, ["meaning"]), score: (held?.score ?? 0) + vote });
32075
32154
  });
32076
32155
  return [...fused2.values()].sort((a, b) => b.score - a.score).map(({ item: item2 }) => item2);
32077
32156
  }, "messagesOf");
@@ -32113,7 +32192,8 @@ var searchAll = /* @__PURE__ */ __name(async (store, account2, asked, messenger
32113
32192
  const read = chosen?.map(({ account: account3 }) => account3) ?? [
32114
32193
  INTERNAL_NOTES,
32115
32194
  ...(await store.notes.folders()).map(({ id: id2 }) => id2),
32116
- ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => id2)
32195
+ ...(await store.notes.documentsAccounts()).map(({ id: id2 }) => id2),
32196
+ ...[await store.notes.addedAccount()].flatMap((added) => added ? [added.id] : [])
32117
32197
  ];
32118
32198
  accounts.push(...read.map((account3) => ({ resource, provider: "notes", account: account3 })));
32119
32199
  } else if (resource === "events") {
@@ -32217,7 +32297,7 @@ var oneList = /* @__PURE__ */ __name((lists, cosines) => {
32217
32297
  return [...place.values()].sort((a, b) => a.rank - b.rank || cosine(b.item.ref) - cosine(a.item.ref)).map(({ item: item2 }) => item2);
32218
32298
  }, "oneList");
32219
32299
 
32220
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/search-all-meetings.js
32300
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/search-all-meetings.js
32221
32301
  var RESOURCES_SEARCHED_WITH_MEETINGS = [...RESOURCES_SEARCHED, "meetings"];
32222
32302
  var whole2 = /* @__PURE__ */ __name((value, minimum, maximum, label) => {
32223
32303
  if (!Number.isSafeInteger(value) || value < minimum || value > maximum)
@@ -32442,7 +32522,7 @@ var searchAllOfSource = /* @__PURE__ */ __name(async (store, account2, source, r
32442
32522
  const entries = entriesOfList(source, await listContextOf(store, account2, messenger.app));
32443
32523
  const { skipped } = fitting(entries, only, "search all", (kind) => `--only leaves ${kind} out`);
32444
32524
  const named2 = /* @__PURE__ */ __name((resource) => [
32445
- ...new Map(entries.flatMap(({ accounts }) => accounts).filter(({ kind }) => kind === resource).map(({ provider, account: account3 }) => [`${provider}\0${account3}`, { provider, account: account3 }])).values()
32525
+ ...new Map(entries.flatMap(({ accounts }) => accounts).filter((one2) => listedHolds(one2, resource)).map(({ provider, account: account3 }) => [`${provider}\0${account3}`, { provider, account: account3 }])).values()
32446
32526
  ], "named");
32447
32527
  const meetings = await holdingMeetings(store, named2("meetings"));
32448
32528
  const empty2 = named2("meetings").filter((one2) => !meetings.some(({ provider, account: account3 }) => provider === one2.provider && account3 === one2.account)).map(({ provider, account: account3 }) => ({
@@ -32471,7 +32551,7 @@ var searchAllOfSource = /* @__PURE__ */ __name(async (store, account2, source, r
32471
32551
  return { ...found, skipped: [...skipped, ...empty2, ...unnamed, ...found.skipped] };
32472
32552
  }, "searchAllOfSource");
32473
32553
 
32474
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/server-search.js
32554
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/server-search.js
32475
32555
  var SERVER_SEARCH_KEY = "messages.server-search";
32476
32556
  var SERVER_BOUNDS = { timeMs: 5e3, perCall: 100, maxCalls: 3, textBytes: 262144 };
32477
32557
  var DEFAULT_BACKEND = "both";
@@ -32660,7 +32740,7 @@ var searchServer = /* @__PURE__ */ __name(async (deps, request) => {
32660
32740
  return { report, sources };
32661
32741
  }, "searchServer");
32662
32742
 
32663
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/messages.js
32743
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/messages.js
32664
32744
  var DELETE_AT_ONCE = 10;
32665
32745
  var filesOf = /* @__PURE__ */ __name(({ attachments }) => {
32666
32746
  const files = fileLinks(attachments);
@@ -33101,7 +33181,7 @@ var checkMediaOptions = /* @__PURE__ */ __name((messenger, asked, attachments) =
33101
33181
  throw new CliError("validation_error", `${MEDIA_FLAGS[first2]} needs a --photo or --file`);
33102
33182
  }, "checkMediaOptions");
33103
33183
 
33104
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/domain/channel-tags.js
33184
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/domain/channel-tags.js
33105
33185
  var CHANNEL_TAG_RULES_VERSION = "keywords-v1";
33106
33186
  var RULES = {
33107
33187
  ai: [/\b(ai|gpt|llm|machine learning|artificial intelligence)\b/iu, /нейросет|искусственн/iu],
@@ -33116,7 +33196,7 @@ var classifyChannel = /* @__PURE__ */ __name((metadata) => Object.entries(RULES)
33116
33196
  return fields.length ? [{ tag, score: fields.length / 3, fields }] : [];
33117
33197
  }), "classifyChannel");
33118
33198
 
33119
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/metadata.js
33199
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/metadata.js
33120
33200
  var metadataService = /* @__PURE__ */ __name((deps) => {
33121
33201
  const held = /* @__PURE__ */ __name(async (reference, { includeLeft = false } = {}) => {
33122
33202
  const store = await deps.store();
@@ -33202,7 +33282,7 @@ var metadataService = /* @__PURE__ */ __name((deps) => {
33202
33282
  };
33203
33283
  }, "metadataService");
33204
33284
 
33205
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/moderation/run.js
33285
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/moderation/run.js
33206
33286
  var FIRST_LOOK_MS = 24 * 36e5;
33207
33287
  var moderateWith = /* @__PURE__ */ __name(async (run) => {
33208
33288
  const { chatId, title, rules, point, since, dryRun } = run;
@@ -33239,7 +33319,7 @@ var moderateWith = /* @__PURE__ */ __name(async (run) => {
33239
33319
  return { chatId, rows, notes };
33240
33320
  }, "moderateWith");
33241
33321
 
33242
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/moderation.js
33322
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/moderation.js
33243
33323
  var moderationService = /* @__PURE__ */ __name((deps) => {
33244
33324
  const file = /* @__PURE__ */ __name(() => new ModerationRules(moderationPathFor(deps.messenger.app, deps.profile ?? "default", deps.env ?? process.env)), "file");
33245
33325
  const group = /* @__PURE__ */ __name(async (chat) => {
@@ -33317,7 +33397,7 @@ var moderatorOf = /* @__PURE__ */ __name((adapter, deps) => ({
33317
33397
  }, "removePerson")
33318
33398
  }), "moderatorOf");
33319
33399
 
33320
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/person-context.js
33400
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/person-context.js
33321
33401
  var CONTEXT_MESSAGES2 = 10;
33322
33402
  var CONTEXT_BYTES = 64 * 1024;
33323
33403
  var toContext = /* @__PURE__ */ __name((key, message, chatTitle2) => ({
@@ -33393,18 +33473,34 @@ var eventsOnce = /* @__PURE__ */ __name(async (store, filter, limit) => {
33393
33473
  }
33394
33474
  return { items, cut: true };
33395
33475
  }, "eventsOnce");
33396
- var readsOf = /* @__PURE__ */ __name((record, asked) => record.identities.flatMap((identity) => (identity.provider === asked.provider ? [asked.account] : identity.accounts).filter((account2) => identity.accounts.includes(account2)).map((account2) => ({ key: { provider: identity.provider, account: account2 }, identity }))), "readsOf");
33476
+ var nameOf = /* @__PURE__ */ __name(({ provider, account: account2 }) => `${provider}:${account2}`, "nameOf");
33477
+ var readableAccounts = /* @__PURE__ */ __name(async (store, asked, scopes) => {
33478
+ const stored = await store.accounts.storedAccounts();
33479
+ const own = stored.find((one2) => nameOf(one2) === nameOf(asked));
33480
+ if (!own || asked.scope !== void 0 && asked.scope !== own.scope)
33481
+ throw new CliError("not_found", `no ${asked.provider} account ${asked.account} in the store`);
33482
+ const allowed = scopes ?? [own.scope];
33483
+ return stored.filter((one2) => allowed.includes(one2.scope));
33484
+ }, "readableAccounts");
33485
+ var readsOf = /* @__PURE__ */ __name((record, asked, readable) => {
33486
+ const scopeOf4 = new Map(readable.map((one2) => [nameOf(one2), one2.scope]));
33487
+ return record.identities.flatMap((identity) => (identity.provider === asked.provider ? [asked.account] : identity.accounts).flatMap((account2) => {
33488
+ const scope = scopeOf4.get(nameOf({ provider: identity.provider, account: account2 }));
33489
+ return identity.accounts.includes(account2) && scope !== void 0 ? [{ key: { provider: identity.provider, account: account2 }, scope, identity }] : [];
33490
+ }));
33491
+ }, "readsOf");
33397
33492
  var personContext = /* @__PURE__ */ __name(async (store, asked, reference, options = {}) => {
33398
33493
  const found = pickPerson(reference, await store.people.people(asked.provider, { account: asked.account }));
33399
33494
  const record = await store.people.personOf({ provider: asked.provider, id: found.id });
33400
33495
  if (!record)
33401
33496
  throw new CliError("not_found", `no person ${found.id} in the store`);
33497
+ const readable = await readableAccounts(store, asked, options.scopes);
33402
33498
  return {
33403
33499
  person: { ...record, provider: asked.provider, id: found.id },
33404
- ...await recordContext(store, record, readsOf(record, asked), options)
33500
+ ...await recordContext(store, record, readsOf(record, asked, readable), readable, options)
33405
33501
  };
33406
33502
  }, "personContext");
33407
- var recordContext = /* @__PURE__ */ __name(async (store, record, reads, { messages = CONTEXT_MESSAGES2, bytes: bytes2 = CONTEXT_BYTES, since, now = Date.now() } = {}) => {
33503
+ var recordContext = /* @__PURE__ */ __name(async (store, record, reads, readable, { messages = CONTEXT_MESSAGES2, bytes: bytes2 = CONTEXT_BYTES, since, now = Date.now() } = {}) => {
33408
33504
  const recent = /* @__PURE__ */ __name((message) => since === void 0 || Date.parse(message.timestamp) >= since, "recent");
33409
33505
  const shared = [];
33410
33506
  const notRead = [];
@@ -33462,9 +33558,15 @@ var recordContext = /* @__PURE__ */ __name(async (store, record, reads, { messag
33462
33558
  cut ||= named2.hasMore;
33463
33559
  }
33464
33560
  const personId = Number(record.uid);
33465
- const upcoming = await eventsOnce(store, { personId, from: now }, messages);
33561
+ const calendars = [];
33562
+ for (const one2 of readable)
33563
+ if ((await store.calendar.calendars(one2.id)).length)
33564
+ calendars.push(one2);
33565
+ const accountIds = calendars.map(({ id: id2 }) => id2);
33566
+ const nothing = { items: [], cut: false };
33567
+ const upcoming = accountIds.length ? await eventsOnce(store, { personId, accountIds, from: now }, messages) : nothing;
33466
33568
  const upcomingIds = new Set(upcoming.items.map(({ id: id2 }) => id2));
33467
- const past = await eventsOnce(store, { personId, to: now, newest: true, ...since === void 0 ? {} : { from: since } }, messages);
33569
+ const past = accountIds.length ? await eventsOnce(store, { personId, accountIds, to: now, newest: true, ...since === void 0 ? {} : { from: since } }, messages) : nothing;
33468
33570
  cut ||= upcoming.cut || past.cut;
33469
33571
  direct.sort(newestFirst);
33470
33572
  const each = [...direct, ...beyond].sort(newestFirst);
@@ -33480,7 +33582,13 @@ var recordContext = /* @__PURE__ */ __name(async (store, record, reads, { messag
33480
33582
  };
33481
33583
  cut ||= direct.length > messages || groups.length > messages || mentions.length > messages;
33482
33584
  const kept2 = withinBytes(lists, bytes2);
33585
+ const read = [
33586
+ ...reads.map(({ key, scope }) => ({ ...key, scope })),
33587
+ ...calendars.map(({ provider, account: account2, scope }) => ({ provider, account: account2, scope }))
33588
+ ];
33589
+ const accounts = [...new Map(read.map((one2) => [nameOf(one2), one2])).values()].sort((a, b) => nameOf(a).localeCompare(nameOf(b)));
33483
33590
  return {
33591
+ accounts,
33484
33592
  shared: shared.sort((a, b) => Date.parse(b.lastMessageAt ?? "") - Date.parse(a.lastMessageAt ?? "")),
33485
33593
  last: {
33486
33594
  fromThem: each.find((message) => !message.outgoing) ?? null,
@@ -33552,7 +33660,7 @@ var lean = /* @__PURE__ */ __name((key, message, detail) => {
33552
33660
  replyTo: message.replyTo?.id ?? message.replyToId ?? null
33553
33661
  };
33554
33662
  }, "lean");
33555
- var kindOf3 = /* @__PURE__ */ __name((chat, chatId, person) => chat && chat.kind !== "unknown" ? chat.kind : chatId === person ? "dialog" : chat?.kind ?? "unknown", "kindOf");
33663
+ var kindOf2 = /* @__PURE__ */ __name((chat, chatId, person) => chat && chat.kind !== "unknown" ? chat.kind : chatId === person ? "dialog" : chat?.kind ?? "unknown", "kindOf");
33556
33664
  var personMessages = /* @__PURE__ */ __name(async (store, asked, reference, { chats, limit = CHAT_MESSAGES, detail = 0 }) => {
33557
33665
  const found = pickPerson(reference, await store.people.people(asked.provider, { account: asked.account }));
33558
33666
  const record = await store.people.personOf({ provider: asked.provider, id: found.id });
@@ -33565,7 +33673,7 @@ var personMessages = /* @__PURE__ */ __name(async (store, asked, reference, { ch
33565
33673
  const chat = stored.find((one2) => one2.id === chatId);
33566
33674
  const page = await store.messages.find({ account: asked, senders: [found.id], chatId, limit });
33567
33675
  answer.push({
33568
- chat: { id: chatId, title: chat?.title ?? null, kind: kindOf3(chat, chatId, found.id) },
33676
+ chat: { id: chatId, title: chat?.title ?? null, kind: kindOf2(chat, chatId, found.id) },
33569
33677
  messages: page.items.toSorted((a, b) => Date.parse(a.timestamp) - Date.parse(b.timestamp)).map((message) => lean(asked, message, detail)),
33570
33678
  complete: held.get(chatId) === "complete",
33571
33679
  more: page.hasMore
@@ -33578,10 +33686,10 @@ var personMessages = /* @__PURE__ */ __name(async (store, asked, reference, { ch
33578
33686
  };
33579
33687
  }, "personMessages");
33580
33688
 
33581
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
33689
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
33582
33690
  import { createHash as createHash11 } from "node:crypto";
33583
33691
 
33584
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-reference.js
33692
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-reference.js
33585
33693
  var missing3 = /* @__PURE__ */ __name(() => new CliError("not_found", "the meeting evidence is unavailable for this account"), "missing");
33586
33694
  var authorizedMeetingMetadata = /* @__PURE__ */ __name(async (store, accountId, reference, options = {}) => {
33587
33695
  const parsed = parseMeetingReference(reference);
@@ -33629,7 +33737,7 @@ var resolveMeetingReference = /* @__PURE__ */ __name(async (store, accountId, re
33629
33737
  };
33630
33738
  }, "resolveMeetingReference");
33631
33739
 
33632
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
33740
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-evidence.js
33633
33741
  var hash = /* @__PURE__ */ __name((value) => createHash11("sha256").update(JSON.stringify(value)).digest("hex"), "hash");
33634
33742
  var checkMeetingCancelled = /* @__PURE__ */ __name((signal) => {
33635
33743
  if (signal?.aborted)
@@ -33828,7 +33936,7 @@ var readMeetingEvidence = /* @__PURE__ */ __name(async (store, accountId, refere
33828
33936
  return { ...packet, fingerprint: hash(packet) };
33829
33937
  }, "readMeetingEvidence");
33830
33938
 
33831
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/person-meeting-context.js
33939
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/person-meeting-context.js
33832
33940
  var personMeetingContext = /* @__PURE__ */ __name(async (store, personReference, options) => {
33833
33941
  const { meetings = 10, cues = 5, bytes: bytes2 = 64 * 1024, scanLimit = 1e3, since, signal } = options;
33834
33942
  const requestedAccounts = options.accountIds;
@@ -33927,7 +34035,7 @@ var personMeetingContext = /* @__PURE__ */ __name(async (store, personReference,
33927
34035
  };
33928
34036
  }, "personMeetingContext");
33929
34037
 
33930
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/person-preparation.js
34038
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/person-preparation.js
33931
34039
  var PREPARE_BYTES = 96 * 1024;
33932
34040
  var MEETINGS = 5;
33933
34041
  var CUES = 3;
@@ -33955,7 +34063,6 @@ var personPreparation = /* @__PURE__ */ __name(async (store, asked, reference, o
33955
34063
  coverage: { included: items.length, hasMore: over || cut, cutBy: cut ? "bytes" : over ? "limit" : null }
33956
34064
  };
33957
34065
  }, "budgeted");
33958
- const reads = readsOf(context2.person, asked);
33959
34066
  const partial = new Set(context2.notRead.map((chat) => `${chat.provider}/${chat.account}/${chat.chatId}`));
33960
34067
  const waiting = [];
33961
34068
  for (const chat of context2.shared.filter((one2) => one2.kind === "dialog")) {
@@ -33972,10 +34079,10 @@ var personPreparation = /* @__PURE__ */ __name(async (store, asked, reference, o
33972
34079
  });
33973
34080
  }
33974
34081
  waiting.sort((a, b) => Date.parse(b.message.timestamp) - Date.parse(a.message.timestamp));
33975
- const accounts = [...new Map(reads.map(({ key }) => [accountName(key), key])).values()];
34082
+ const accounts = context2.accounts.map(({ provider, account: account2 }) => ({ provider, account: account2 }));
33976
34083
  const held = await store.people.preparation(context2.person.uid, { accounts, limit });
33977
- const stored = await store.accounts.storedAccounts();
33978
- const meetings = await meetingsOf(store, context2.person.uid, stored, options.since, () => left);
34084
+ const readable = await readableAccounts(store, asked, options.scopes);
34085
+ const meetings = await meetingsOf(store, context2.person.uid, readable, options.since, () => left);
33979
34086
  const sections = {
33980
34087
  waiting: budgeted({ items: waiting, hasMore: false }),
33981
34088
  tasks: budgeted(held.tasks),
@@ -34044,7 +34151,7 @@ var meetingsOf = /* @__PURE__ */ __name(async (store, uid, stored, since, left)
34044
34151
  }
34045
34152
  }, "meetingsOf");
34046
34153
 
34047
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/person-profile.js
34154
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/person-profile.js
34048
34155
  var personProfile = /* @__PURE__ */ __name(async (deps, person, known2) => {
34049
34156
  const online = deps.offline ? void 0 : await deps.connection();
34050
34157
  const held = await storeIfOpen(deps);
@@ -34114,7 +34221,7 @@ var quiet = /* @__PURE__ */ __name((facts) => facts.chats.map(({ id: id2, title,
34114
34221
  complete: false
34115
34222
  })), "quiet");
34116
34223
 
34117
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/person-timeline.js
34224
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/person-timeline.js
34118
34225
  var TIMELINE_ITEMS = 50;
34119
34226
  var TIMELINE_MAX = 500;
34120
34227
  var SCOPES = ["personal", "work"];
@@ -34169,7 +34276,7 @@ var personTimeline = /* @__PURE__ */ __name(async (store, asked, reference, { sc
34169
34276
  };
34170
34277
  }, "personTimeline");
34171
34278
 
34172
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/people.js
34279
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/people.js
34173
34280
  var peopleService = /* @__PURE__ */ __name((deps) => {
34174
34281
  const localCard = /* @__PURE__ */ __name(async (card, includeNotes = false) => {
34175
34282
  const held = await storeIfOpen(deps);
@@ -34396,7 +34503,7 @@ var withoutPhone = /* @__PURE__ */ __name((answer) => {
34396
34503
  return rest;
34397
34504
  }, "withoutPhone");
34398
34505
 
34399
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/private-people.js
34506
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/private-people.js
34400
34507
  var noteItem = /* @__PURE__ */ __name((provider, note) => ({
34401
34508
  id: note.id,
34402
34509
  contact: formatReference({ type: "contact", provider, id: note.personId }),
@@ -34440,7 +34547,7 @@ var privatePeopleService = /* @__PURE__ */ __name((deps) => {
34440
34547
  };
34441
34548
  }, "privatePeopleService");
34442
34549
 
34443
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/rankings.js
34550
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/rankings.js
34444
34551
  var empty = /* @__PURE__ */ __name(() => ({
34445
34552
  total: 0,
34446
34553
  population: 0,
@@ -34696,7 +34803,7 @@ var rankingsService = /* @__PURE__ */ __name((deps) => ({
34696
34803
  }, "evidence")
34697
34804
  }), "rankingsService");
34698
34805
 
34699
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/reply-stats.js
34806
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/reply-stats.js
34700
34807
  var FIELDS = ["date", "chat", "kind"];
34701
34808
  var WAITING_TAIL = 100;
34702
34809
  var plainOnly = /* @__PURE__ */ __name((text2, command) => {
@@ -34823,7 +34930,7 @@ var replyStatsService = /* @__PURE__ */ __name((deps) => {
34823
34930
  };
34824
34931
  }, "replyStatsService");
34825
34932
 
34826
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/searches.js
34933
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/searches.js
34827
34934
  var savedSearchItem = /* @__PURE__ */ __name((one2) => ({
34828
34935
  id: one2.id,
34829
34936
  name: one2.name,
@@ -34844,7 +34951,7 @@ var MESSAGE_SEARCH_COMMANDS = [
34844
34951
  "admin-statistics"
34845
34952
  ];
34846
34953
  var NAME = /^[a-z0-9][a-z0-9-]{0,63}$/;
34847
- var nameOf = /* @__PURE__ */ __name((value) => {
34954
+ var nameOf2 = /* @__PURE__ */ __name((value) => {
34848
34955
  const name = value.trim().toLowerCase();
34849
34956
  if (!NAME.test(name) || /^\d+$/.test(name))
34850
34957
  throw new CliError("validation_error", `"${singleLine(value)}" cannot name a saved search \u2014 use up to 64 letters a\u2013z, digits and hyphens, not only digits`, { reason: "name.invalid" });
@@ -34899,13 +35006,13 @@ var searchesService = /* @__PURE__ */ __name((deps) => {
34899
35006
  if (isAdminSelection(params.selection)) {
34900
35007
  const selected = await readAdminSelection(store, params.selection);
34901
35008
  const normalized2 = typeof params.selection === "string" ? JSON.parse(params.selection) : params.selection;
34902
- return store.searches.saveSearch(nameOf(name), searchRecordOf("admin-statistics", {
35009
+ return store.searches.saveSearch(nameOf2(name), searchRecordOf("admin-statistics", {
34903
35010
  adminReport: selected.options.report,
34904
35011
  selection: normalized2,
34905
35012
  timezone: selected.base.timezone
34906
35013
  }), { replace });
34907
35014
  }
34908
- return store.searches.saveSearch(nameOf(name), searchRecordOf(params.target ? params.target === "messages" ? "message-top" : "author-top" : params.by === void 0 ? "search" : "stats", checked(params)), {
35015
+ return store.searches.saveSearch(nameOf2(name), searchRecordOf(params.target ? params.target === "messages" ? "message-top" : "author-top" : params.by === void 0 ? "search" : "stats", checked(params)), {
34909
35016
  replace
34910
35017
  });
34911
35018
  }), "create"),
@@ -34952,7 +35059,7 @@ var searchesService = /* @__PURE__ */ __name((deps) => {
34952
35059
  };
34953
35060
  }, "searchesService");
34954
35061
 
34955
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/tags.js
35062
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/tags.js
34956
35063
  var TAGGING_QUERY = {
34957
35064
  entity: "tagging",
34958
35065
  backend: "sql",
@@ -35036,7 +35143,7 @@ var tagsService = /* @__PURE__ */ __name((deps) => {
35036
35143
  };
35037
35144
  }, "tagsService");
35038
35145
 
35039
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/task-stats.js
35146
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/task-stats.js
35040
35147
  var TASK_STATS_BY = ["chat", "meeting", "project"];
35041
35148
  var PERIOD_FIELD = "created";
35042
35149
  var refuseNestedPeriod = /* @__PURE__ */ __name((node, top = true) => {
@@ -35139,7 +35246,7 @@ var meetingNames = /* @__PURE__ */ __name(async (store, groups) => {
35139
35246
  }));
35140
35247
  }, "meetingNames");
35141
35248
 
35142
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/tasks.js
35249
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/tasks.js
35143
35250
  var TASK_QUERY = {
35144
35251
  entity: "task",
35145
35252
  backend: "sql",
@@ -35631,7 +35738,7 @@ var taskView = /* @__PURE__ */ __name(async (store, account2, task2) => {
35631
35738
  };
35632
35739
  }, "taskView");
35633
35740
 
35634
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/topics.js
35741
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/topics.js
35635
35742
  var actionOf = /* @__PURE__ */ __name(({ title, closed, pinned, hidden, icon }) => {
35636
35743
  const set = [closed, pinned, hidden].filter((one2) => one2 !== void 0).length;
35637
35744
  if (title !== void 0 || icon !== void 0 || set !== 1)
@@ -35830,7 +35937,7 @@ var topicsService = /* @__PURE__ */ __name((deps) => {
35830
35937
  };
35831
35938
  }, "topicsService");
35832
35939
 
35833
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/evidence.js
35940
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/evidence.js
35834
35941
  import { createHash as createHash12, randomUUID as randomUUID5 } from "node:crypto";
35835
35942
  var hash2 = /* @__PURE__ */ __name((value) => createHash12("sha256").update(JSON.stringify(value)).digest("hex"), "hash");
35836
35943
  var positive = /* @__PURE__ */ __name((value, name, minimum = 1) => {
@@ -35904,7 +36011,7 @@ var prepareEvidencePacket = /* @__PURE__ */ __name(({ kind, source, page, limits
35904
36011
  return { ...content, id: randomUUID5(), fingerprint: hash2(content) };
35905
36012
  }, "prepareEvidencePacket");
35906
36013
 
35907
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/evidence-read.js
36014
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/evidence-read.js
35908
36015
  var readEvidencePacket = /* @__PURE__ */ __name(async (store, account2, { chat, limit, before: before2 }, messenger = {}) => {
35909
36016
  if (!Number.isSafeInteger(limit) || limit < 1 || limit > 100)
35910
36017
  throw new CliError("validation_error", "evidence message limit must be an integer from 1 to 100");
@@ -35924,7 +36031,7 @@ var readEvidencePacket = /* @__PURE__ */ __name(async (store, account2, { chat,
35924
36031
  return { ...packet, nextBeforeId: older && last ? last.id : null };
35925
36032
  }, "readEvidencePacket");
35926
36033
 
35927
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-hit-search.js
36034
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-hit-search.js
35928
36035
  var refreshMeetingIndex = /* @__PURE__ */ __name(async (meetings, accountId, signal) => {
35929
36036
  let before2 = Number.POSITIVE_INFINITY;
35930
36037
  for (; ; ) {
@@ -35986,7 +36093,7 @@ var searchMeetingHits = /* @__PURE__ */ __name(async (store, query, request, opt
35986
36093
  return { ...result, selection };
35987
36094
  }, "searchMeetingHits");
35988
36095
 
35989
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-links.js
36096
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-links.js
35990
36097
  var readMeetingLinks = /* @__PURE__ */ __name(async (store, request) => {
35991
36098
  const { maxMessages, url, ...selecting } = request;
35992
36099
  const { input, selection } = await resolveMeetingSelection(store, selecting);
@@ -36025,10 +36132,10 @@ var readMeetingLinks = /* @__PURE__ */ __name(async (store, request) => {
36025
36132
  };
36026
36133
  }, "readMeetingLinks");
36027
36134
 
36028
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidates.js
36135
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidates.js
36029
36136
  import { createHash as createHash13 } from "node:crypto";
36030
36137
 
36031
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-validation.js
36138
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidate-validation.js
36032
36139
  function invalid3(field, response = false) {
36033
36140
  throw new CliError(response ? "invalid_response" : "validation_error", `invalid project candidate ${field}`);
36034
36141
  }
@@ -36147,7 +36254,7 @@ var candidateCatalog = /* @__PURE__ */ __name((catalog, limits) => {
36147
36254
  }
36148
36255
  }, "candidateCatalog");
36149
36256
 
36150
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidates.js
36257
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-candidates.js
36151
36258
  var createMeetingProjectCandidateReader = /* @__PURE__ */ __name((scope, accountId, ports) => {
36152
36259
  const fixed = snapshotMeetingScope(scope);
36153
36260
  if (!Number.isSafeInteger(accountId) || accountId < 1 || typeof ports?.vocabulary?.vocabulary !== "function")
@@ -36200,7 +36307,7 @@ var createMeetingProjectCandidateReader = /* @__PURE__ */ __name((scope, account
36200
36307
  };
36201
36308
  }, "createMeetingProjectCandidateReader");
36202
36309
 
36203
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-discovery.js
36310
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-discovery.js
36204
36311
  import { createHash as createHash14 } from "node:crypto";
36205
36312
  var scopeKeys = [
36206
36313
  "accountId",
@@ -36335,7 +36442,7 @@ var readMeetingProjectDiscovery = /* @__PURE__ */ __name(async (ports, projectNa
36335
36442
  };
36336
36443
  }, "readMeetingProjectDiscovery");
36337
36444
 
36338
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-review.js
36445
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-review.js
36339
36446
  var readMeetingReview = /* @__PURE__ */ __name(async (store, request) => {
36340
36447
  const { limit, ...selecting } = request;
36341
36448
  const { input, selection } = await resolveMeetingSelection(store, selecting);
@@ -36343,7 +36450,7 @@ var readMeetingReview = /* @__PURE__ */ __name(async (store, request) => {
36343
36450
  return { ...review, selection };
36344
36451
  }, "readMeetingReview");
36345
36452
 
36346
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-searches.js
36453
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-searches.js
36347
36454
  var KIND = ["meetings-search"];
36348
36455
  var meetingSearchesService = /* @__PURE__ */ __name((searches) => {
36349
36456
  const found = /* @__PURE__ */ __name(async (reference) => {
@@ -36359,7 +36466,7 @@ var meetingSearchesService = /* @__PURE__ */ __name((searches) => {
36359
36466
  }, "found");
36360
36467
  const record = /* @__PURE__ */ __name(({ query, options }) => searchRecordOf("meetings-search", { ...options, text: query }), "record");
36361
36468
  return {
36362
- create: /* @__PURE__ */ __name(async (name, params, { replace = false } = {}) => (await searches()).saveSearch(nameOf(name), record(params), { replace }), "create"),
36469
+ create: /* @__PURE__ */ __name(async (name, params, { replace = false } = {}) => (await searches()).saveSearch(nameOf2(name), record(params), { replace }), "create"),
36363
36470
  list: /* @__PURE__ */ __name(async () => (await searches()).savedSearches(KIND), "list"),
36364
36471
  show: found,
36365
36472
  delete: /* @__PURE__ */ __name(async (reference) => (await searches()).deleteSearch((await found(reference)).id), "delete"),
@@ -36373,7 +36480,7 @@ var meetingSearchesService = /* @__PURE__ */ __name((searches) => {
36373
36480
  };
36374
36481
  }, "meetingSearchesService");
36375
36482
 
36376
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-stats.js
36483
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-stats.js
36377
36484
  var readMeetingStats = /* @__PURE__ */ __name(async (store, request) => {
36378
36485
  const { timeZone, maxRows, ...selecting } = request;
36379
36486
  const { input, selection } = await resolveMeetingSelection(store, selecting);
@@ -36396,7 +36503,7 @@ var readMeetingCounts = /* @__PURE__ */ __name(async (store, request) => {
36396
36503
  return { ...counts, selection };
36397
36504
  }, "readMeetingCounts");
36398
36505
 
36399
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-hit-context.js
36506
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-hit-context.js
36400
36507
  import { createHash as createHash15 } from "node:crypto";
36401
36508
  var contextCue = /* @__PURE__ */ __name((cue) => ({
36402
36509
  ref: cue.reference,
@@ -36514,7 +36621,7 @@ var readMeetingHitContext = /* @__PURE__ */ __name(async (store, accountId, refe
36514
36621
  return { ...packet, fingerprint: createHash15("sha256").update(JSON.stringify(packet)).digest("hex") };
36515
36622
  }, "readMeetingHitContext");
36516
36623
 
36517
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-passage-format.js
36624
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-passage-format.js
36518
36625
  var visible = /* @__PURE__ */ __name((text2) => text2.replace(/[\p{Cc}\p{Cf}]/gu, (value) => value === "\n" || value === " " ? value : `\\u{${value.codePointAt(0)?.toString(16)}}`), "visible");
36519
36626
  var markdown = /* @__PURE__ */ __name((text2) => visible(text2).replaceAll("&", "&amp;").replaceAll("<", "&lt;").replaceAll(">", "&gt;").replace(/[\\`*_[\]#|~]/g, "\\$&"), "markdown");
36520
36627
  var timestamp = /* @__PURE__ */ __name((ms) => {
@@ -36591,7 +36698,7 @@ var readMeetingPassage = /* @__PURE__ */ __name(async (store, accountId, referen
36591
36698
  return { packet, content };
36592
36699
  }, "readMeetingPassage");
36593
36700
 
36594
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-batch.js
36701
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-batch.js
36595
36702
  var createMeetingBatchReader = /* @__PURE__ */ __name((store, accountId) => {
36596
36703
  if (!Number.isSafeInteger(accountId) || accountId < 1)
36597
36704
  throw new CliError("validation_error", "choose a positive meeting account");
@@ -36605,10 +36712,10 @@ var createMeetingBatchReader = /* @__PURE__ */ __name((store, accountId) => {
36605
36712
  };
36606
36713
  }, "createMeetingBatchReader");
36607
36714
 
36608
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-combined.js
36715
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-combined.js
36609
36716
  import { createHash as createHash16 } from "node:crypto";
36610
36717
 
36611
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-semantic.js
36718
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-semantic.js
36612
36719
  var positive2 = /* @__PURE__ */ __name((value, name, max) => {
36613
36720
  if (!Number.isSafeInteger(value) || value < 1 || value > max)
36614
36721
  throw new CliError("validation_error", `Invalid ${name}`);
@@ -36760,7 +36867,7 @@ var applyMeetingEmbedding = /* @__PURE__ */ __name(async (store, accountId, embe
36760
36867
  };
36761
36868
  }, "applyMeetingEmbedding");
36762
36869
 
36763
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-combined.js
36870
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-combined.js
36764
36871
  var DEPTH = 200;
36765
36872
  var cursorOf3 = /* @__PURE__ */ __name((value, key) => {
36766
36873
  if (value === void 0)
@@ -36897,7 +37004,7 @@ var searchMeetingsCombined = /* @__PURE__ */ __name(async (store, embedder, type
36897
37004
  };
36898
37005
  }, "searchMeetingsCombined");
36899
37006
 
36900
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-context.js
37007
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-context.js
36901
37008
  var meetingReferences = /* @__PURE__ */ __name((values) => values.map((value) => formatMeetingReference(parseMeetingReference(value))), "meetingReferences");
36902
37009
  var checkCancelled = /* @__PURE__ */ __name((signal) => {
36903
37010
  if (!signal?.aborted)
@@ -37002,7 +37109,7 @@ var createMeetingContextService = /* @__PURE__ */ __name(async (store, input, op
37002
37109
  };
37003
37110
  }, "createMeetingContextService");
37004
37111
 
37005
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-model.js
37112
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-model.js
37006
37113
  var integer = /* @__PURE__ */ __name((value, name, max) => {
37007
37114
  if (!Number.isSafeInteger(value) || value < 1 || value > max)
37008
37115
  throw new CliError("validation_error", `Invalid ${name}`);
@@ -37229,7 +37336,7 @@ var openMeetingEmbedder = /* @__PURE__ */ __name(async (choice, options = {}) =>
37229
37336
  };
37230
37337
  }, "openMeetingEmbedder");
37231
37338
 
37232
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/context/communication-selection.js
37339
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/context/communication-selection.js
37233
37340
  var communicationFields = {
37234
37341
  sources: pipe(array(strictObject({
37235
37342
  id: pipe(string(), regex(/^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$/)),
@@ -37261,7 +37368,7 @@ var communicationRequest = /* @__PURE__ */ __name((value, preparationAfter) => {
37261
37368
  return { ...input, after, before: before2 };
37262
37369
  }, "communicationRequest");
37263
37370
 
37264
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-preparation-validation.js
37371
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-preparation-validation.js
37265
37372
  var MEETING_PREPARATION_LIMITS = {
37266
37373
  meetings: { min: 1, max: 20, default: 5 },
37267
37374
  cues: { min: 1, max: 100, default: 10 },
@@ -37347,7 +37454,7 @@ var preparationRequest = /* @__PURE__ */ __name((accountId, externalId, original
37347
37454
  return { ...input, history };
37348
37455
  }, "preparationRequest");
37349
37456
 
37350
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-communications-preparation.js
37457
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-communications-preparation.js
37351
37458
  var readPreparationCommunications = /* @__PURE__ */ __name(async (plan, signal) => {
37352
37459
  const section = {
37353
37460
  readUsage: plan.reader.usage(),
@@ -37452,7 +37559,7 @@ var appendPreparationCommunications = /* @__PURE__ */ __name((result, read) => {
37452
37559
  result.knowledge.coverage.otherSources = "see-communications";
37453
37560
  }, "appendPreparationCommunications");
37454
37561
 
37455
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-communications-selection.js
37562
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-communications-selection.js
37456
37563
  var captureCommunicationSelections = /* @__PURE__ */ __name((port) => {
37457
37564
  if (port === void 0)
37458
37565
  return void 0;
@@ -37557,7 +37664,7 @@ var validatePreparationCommunications = /* @__PURE__ */ __name((section, request
37557
37664
  }
37558
37665
  }, "validatePreparationCommunications");
37559
37666
 
37560
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-knowledge-preparation.js
37667
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-knowledge-preparation.js
37561
37668
  var invalid4 = /* @__PURE__ */ __name(() => {
37562
37669
  throw new CliError("invalid_response", "Preparation knowledge returned an invalid selection");
37563
37670
  }, "invalid");
@@ -37626,7 +37733,7 @@ var appendKnowledgePreparation = /* @__PURE__ */ __name(async (store, result, in
37626
37733
  }
37627
37734
  }, "appendKnowledgePreparation");
37628
37735
 
37629
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-notes-preparation.js
37736
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-notes-preparation.js
37630
37737
  var invalid5 = /* @__PURE__ */ __name(() => {
37631
37738
  throw new CliError("invalid_response", "Preparation notes returned an invalid selection");
37632
37739
  }, "invalid");
@@ -37700,7 +37807,7 @@ var appendNotesPreparation = /* @__PURE__ */ __name(async (store, result, input)
37700
37807
  }
37701
37808
  }, "appendNotesPreparation");
37702
37809
 
37703
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-project-preparation.js
37810
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-project-preparation.js
37704
37811
  var PAGE_LIMIT = 4;
37705
37812
  var size2 = /* @__PURE__ */ __name((value) => Buffer.byteLength(JSON.stringify(value), "utf8"), "size");
37706
37813
  var appendProjectPreparation = /* @__PURE__ */ __name(async (ports, result, input) => {
@@ -37750,7 +37857,7 @@ var appendProjectPreparation = /* @__PURE__ */ __name(async (ports, result, inpu
37750
37857
  }
37751
37858
  }, "appendProjectPreparation");
37752
37859
 
37753
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-related-preparation.js
37860
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-related-preparation.js
37754
37861
  var appendRelatedPreparation = /* @__PURE__ */ __name(async (store, result, input) => {
37755
37862
  if (!result.series || !result.items.length || result.coverage.outputLimited)
37756
37863
  return;
@@ -37822,7 +37929,7 @@ var appendRelatedPreparation = /* @__PURE__ */ __name(async (store, result, inpu
37822
37929
  }
37823
37930
  }, "appendRelatedPreparation");
37824
37931
 
37825
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-preparation.js
37932
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-preparation.js
37826
37933
  var size3 = /* @__PURE__ */ __name((value) => Buffer.byteLength(JSON.stringify(value), "utf8"), "size");
37827
37934
  var createMeetingPreparationService = /* @__PURE__ */ __name((scope, accountId, ports) => {
37828
37935
  const fixed = snapshotMeetingScope(scope);
@@ -37960,7 +38067,7 @@ var createMeetingPreparationService = /* @__PURE__ */ __name((scope, accountId,
37960
38067
  };
37961
38068
  }, "createMeetingPreparationService");
37962
38069
 
37963
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-task-proposal.js
38070
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-task-proposal.js
37964
38071
  import { createHash as createHash17 } from "node:crypto";
37965
38072
  var proposeMeetingTask = /* @__PURE__ */ __name(async (store, accountId, reference, kind) => {
37966
38073
  if (!TASK_KINDS.includes(kind))
@@ -37980,7 +38087,7 @@ var proposeMeetingTask = /* @__PURE__ */ __name(async (store, accountId, referen
37980
38087
  };
37981
38088
  }, "proposeMeetingTask");
37982
38089
 
37983
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/meeting-tasks.js
38090
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/meeting-tasks.js
37984
38091
  var accountSnapshot = /* @__PURE__ */ __name((key) => {
37985
38092
  const { provider, account: account2, scope } = key;
37986
38093
  if (!provider.trim() || provider.includes(":") || !account2.trim())
@@ -38043,7 +38150,7 @@ var readMeetingTask = /* @__PURE__ */ __name(async (store, account2, id2) => {
38043
38150
  }
38044
38151
  }, "readMeetingTask");
38045
38152
 
38046
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/package-upgrade.js
38153
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/package-upgrade.js
38047
38154
  var upgradePackage = /* @__PURE__ */ __name(async ({ current, command, packageName, check }, ports) => {
38048
38155
  const installer = ports.installer();
38049
38156
  const argv = updateCommand(installer, packageName);
@@ -38108,7 +38215,7 @@ var dayAfter = /* @__PURE__ */ __name((published) => {
38108
38215
  return Number.isNaN(time) ? null : new Date(time + 24 * 60 * 60 * 1e3).toISOString();
38109
38216
  }, "dayAfter");
38110
38217
 
38111
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposal-tasks.js
38218
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposal-tasks.js
38112
38219
  var proposalSource = /* @__PURE__ */ __name((id2) => `proposed-action:${id2}`, "proposalSource");
38113
38220
  var approveAsTask = /* @__PURE__ */ __name(async (store, id2, by) => {
38114
38221
  const proposal = await store.proposedActions.get(id2);
@@ -38131,7 +38238,7 @@ var approveAsTask = /* @__PURE__ */ __name(async (store, id2, by) => {
38131
38238
  return { proposal: await store.proposedActions.approve(proposal.id, by, { task: task2.id }), task: task2 };
38132
38239
  }, "approveAsTask");
38133
38240
 
38134
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/ids.js
38241
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/ids.js
38135
38242
  var MAX_IDS = 500;
38136
38243
  var refuse = /* @__PURE__ */ __name((message) => {
38137
38244
  throw new CliError("validation_error", message, { reason: "proposal.ids" });
@@ -38173,7 +38280,7 @@ var parseProposalIds = /* @__PURE__ */ __name((text2) => {
38173
38280
  return ids;
38174
38281
  }, "parseProposalIds");
38175
38282
 
38176
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/shared.js
38283
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/shared.js
38177
38284
  var proposerOfAuthor = /* @__PURE__ */ __name((author) => {
38178
38285
  if (author.type === "person")
38179
38286
  return { type: "person", id: author.id };
@@ -38214,8 +38321,38 @@ var storedStatus = /* @__PURE__ */ __name((filter) => {
38214
38321
  const status = filter.status ?? "proposed";
38215
38322
  return status === "proposed" || status === "rejected" ? status : void 0;
38216
38323
  }, "storedStatus");
38324
+ var reviewedRow = /* @__PURE__ */ __name((kind, entry, object3) => ({
38325
+ id: entry.ref,
38326
+ kind,
38327
+ status: entry.review,
38328
+ project: entry.project,
38329
+ subject: entry.ref,
38330
+ object: object3,
38331
+ summary: entry.title,
38332
+ proposedBy: proposerOfAuthor(entry.author),
38333
+ reason: entry.reason,
38334
+ evidence: [],
38335
+ score: null,
38336
+ signals: null,
38337
+ parts: null,
38338
+ createdAt: entry.createdAt
38339
+ }), "reviewedRow");
38340
+ var reviewedKind = /* @__PURE__ */ __name((spec) => ({
38341
+ kind: spec.type,
38342
+ prefix: spec.type,
38343
+ list: /* @__PURE__ */ __name(async (filter) => {
38344
+ const status = filter.status ?? "proposed";
38345
+ const entries = await spec.list({ ...pushed2(filter), ...status === "all" ? {} : { review: status } });
38346
+ return kept(entries.map(spec.row), filter);
38347
+ }, "list"),
38348
+ get: /* @__PURE__ */ __name(async (id2) => spec.row(await spec.get(id2)), "get"),
38349
+ decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
38350
+ const made = await spec.decide(id2, confirm, { by, reason });
38351
+ return { id: id2, kind: spec.type, status: confirm ? "confirmed" : "rejected", made: confirm ? [made] : [] };
38352
+ }, "decide")
38353
+ }), "reviewedKind");
38217
38354
 
38218
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/findings.js
38355
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/findings.js
38219
38356
  var FACT_SUMMARIES = {
38220
38357
  fact: /* @__PURE__ */ __name((finding) => finding.statement, "fact"),
38221
38358
  task: /* @__PURE__ */ __name((finding) => finding.title, "task"),
@@ -38287,7 +38424,7 @@ var findingsKind = /* @__PURE__ */ __name((store) => {
38287
38424
  };
38288
38425
  }, "findingsKind");
38289
38426
 
38290
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/organization.js
38427
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/organization.js
38291
38428
  var ORGANIZATION_ADD_KIND = "organization_add";
38292
38429
  var ORGANIZATION_RENAME_KIND = "organization_rename";
38293
38430
  var rowOf2 = /* @__PURE__ */ __name((action) => {
@@ -38343,7 +38480,7 @@ var organizationKind = /* @__PURE__ */ __name((store) => ({
38343
38480
  }, "decide")
38344
38481
  }), "organizationKind");
38345
38482
 
38346
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/action.js
38483
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/action.js
38347
38484
  var rowOf3 = /* @__PURE__ */ __name((action) => ({
38348
38485
  id: action.id,
38349
38486
  kind: "action",
@@ -38383,7 +38520,16 @@ var actionKind = /* @__PURE__ */ __name((store, claimed) => ({
38383
38520
  }, "decide")
38384
38521
  }), "actionKind");
38385
38522
 
38386
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/fact.js
38523
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/contracts.js
38524
+ var contractKind = /* @__PURE__ */ __name((store) => reviewedKind({
38525
+ type: "contract",
38526
+ list: /* @__PURE__ */ __name((options) => store.contracts.list(options), "list"),
38527
+ get: /* @__PURE__ */ __name((id2) => store.contracts.get(id2), "get"),
38528
+ row: /* @__PURE__ */ __name((contract) => reviewedRow("contract", contract, contract.deal), "row"),
38529
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.contracts.confirm(id2, by, reason) : await store.contracts.reject(id2, by, reason)).ref, "decide")
38530
+ }), "contractKind");
38531
+
38532
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/fact.js
38387
38533
  var STATUS = {
38388
38534
  proposed: "proposed",
38389
38535
  accepted: "confirmed",
@@ -38426,42 +38572,23 @@ var factKind = /* @__PURE__ */ __name((store) => ({
38426
38572
  }, "decide")
38427
38573
  }), "factKind");
38428
38574
 
38429
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/finance.js
38430
- var rowOf5 = /* @__PURE__ */ __name((kind, entry) => ({
38431
- id: entry.ref,
38432
- kind,
38433
- status: entry.review,
38434
- project: entry.project,
38435
- subject: entry.ref,
38436
- object: "counterparty" in entry ? entry.counterparty.ref : (entry.direction === "in" ? entry.payer : entry.payee)?.ref ?? null,
38437
- summary: entry.title,
38438
- proposedBy: proposerOfAuthor(entry.author),
38439
- reason: entry.reason,
38440
- evidence: [],
38441
- score: null,
38442
- signals: null,
38443
- parts: null,
38444
- createdAt: entry.createdAt
38445
- }), "rowOf");
38446
- var financeKind = /* @__PURE__ */ __name((store, kind) => ({
38447
- kind,
38448
- prefix: kind,
38449
- list: /* @__PURE__ */ __name(async (filter) => {
38450
- const status = filter.status ?? "proposed";
38451
- const options = { ...pushed2(filter), ...status === "all" ? {} : { review: status } };
38452
- const entries = kind === "invoice" ? await store.finance.invoices(options) : await store.finance.payments(options);
38453
- return kept(entries.map((entry) => rowOf5(kind, entry)), filter);
38454
- }, "list"),
38455
- get: /* @__PURE__ */ __name(async (id2) => rowOf5(kind, kind === "invoice" ? await store.finance.invoice(id2) : await store.finance.payment(id2)), "get"),
38456
- decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
38457
- const entry = confirm ? await store.finance.confirm(id2, by, reason) : await store.finance.reject(id2, by, reason);
38458
- return { id: id2, kind, status: confirm ? "confirmed" : "rejected", made: confirm ? [entry.ref] : [] };
38459
- }, "decide")
38460
- }), "financeKind");
38461
- var invoiceKind = /* @__PURE__ */ __name((store) => financeKind(store, "invoice"), "invoiceKind");
38462
- var paymentKind = /* @__PURE__ */ __name((store) => financeKind(store, "payment"), "paymentKind");
38463
-
38464
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/key-document.js
38575
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/finance.js
38576
+ var invoiceKind = /* @__PURE__ */ __name((store) => reviewedKind({
38577
+ type: "invoice",
38578
+ list: /* @__PURE__ */ __name((options) => store.finance.invoices(options), "list"),
38579
+ get: /* @__PURE__ */ __name((id2) => store.finance.invoice(id2), "get"),
38580
+ row: /* @__PURE__ */ __name((invoice) => reviewedRow("invoice", invoice, invoice.counterparty.ref), "row"),
38581
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.finance.confirm(id2, by, reason) : await store.finance.reject(id2, by, reason)).ref, "decide")
38582
+ }), "invoiceKind");
38583
+ var paymentKind = /* @__PURE__ */ __name((store) => reviewedKind({
38584
+ type: "payment",
38585
+ list: /* @__PURE__ */ __name((options) => store.finance.payments(options), "list"),
38586
+ get: /* @__PURE__ */ __name((id2) => store.finance.payment(id2), "get"),
38587
+ row: /* @__PURE__ */ __name((payment) => reviewedRow("payment", payment, (payment.direction === "in" ? payment.payer : payment.payee)?.ref ?? null), "row"),
38588
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.finance.confirm(id2, by, reason) : await store.finance.reject(id2, by, reason)).ref, "decide")
38589
+ }), "paymentKind");
38590
+
38591
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/key-document.js
38465
38592
  var linkRow = /* @__PURE__ */ __name((link4) => ({
38466
38593
  id: `key:${link4.id}`,
38467
38594
  kind: "key_document",
@@ -38529,7 +38656,7 @@ var keyDocumentKind = /* @__PURE__ */ __name((store) => {
38529
38656
  };
38530
38657
  }, "keyDocumentKind");
38531
38658
 
38532
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/mail-findings.js
38659
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/mail-findings.js
38533
38660
  var words3 = /* @__PURE__ */ __name((...parts) => parts.filter(Boolean).join(" "), "words");
38534
38661
  var summaryOf = /* @__PURE__ */ __name((finding) => {
38535
38662
  switch (finding.kind) {
@@ -38555,7 +38682,7 @@ var summaryOf = /* @__PURE__ */ __name((finding) => {
38555
38682
  return words3("order", finding.number, finding.supplierName, finding.status, `\xB7 ${finding.reason}`);
38556
38683
  }
38557
38684
  }, "summaryOf");
38558
- var rowOf6 = /* @__PURE__ */ __name((batch, createdAt) => {
38685
+ var rowOf5 = /* @__PURE__ */ __name((batch, createdAt) => {
38559
38686
  const findings = batch.input.findings;
38560
38687
  const outcome2 = /* @__PURE__ */ __name((id2) => batch.receipt?.items.find((item2) => item2.id === id2)?.status ?? null, "outcome");
38561
38688
  const project = findings.flatMap((finding) => "project" in finding && finding.project ? [finding.project] : [])[0] ?? null;
@@ -38582,7 +38709,7 @@ var rowOf6 = /* @__PURE__ */ __name((batch, createdAt) => {
38582
38709
  };
38583
38710
  }, "rowOf");
38584
38711
  var mailFindingsKind = /* @__PURE__ */ __name((store) => {
38585
- const created = /* @__PURE__ */ __name(async (batch) => rowOf6(batch, (await store.proposedActions.get(batch.id)).createdAt), "created");
38712
+ const created = /* @__PURE__ */ __name(async (batch) => rowOf5(batch, (await store.proposedActions.get(batch.id)).createdAt), "created");
38586
38713
  return {
38587
38714
  kind: "mail_findings",
38588
38715
  stored: [MAIL_FINDINGS_KIND],
@@ -38617,8 +38744,8 @@ var mailFindingsKind = /* @__PURE__ */ __name((store) => {
38617
38744
  };
38618
38745
  }, "mailFindingsKind");
38619
38746
 
38620
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/meeting-findings.js
38621
- var rowOf7 = /* @__PURE__ */ __name((action, batch) => {
38747
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/meeting-findings.js
38748
+ var rowOf6 = /* @__PURE__ */ __name((action, batch) => {
38622
38749
  const findings = batch.input.findings;
38623
38750
  const projects = [...new Set(findings.map((one2) => "project" in one2 ? one2.project : void 0))];
38624
38751
  const outcome2 = /* @__PURE__ */ __name((id2) => batch.receipt?.items.find((item2) => item2.id === id2)?.status ?? null, "outcome");
@@ -38663,12 +38790,12 @@ var meetingFindingsKind = /* @__PURE__ */ __name((store) => {
38663
38790
  ...filter.by === void 0 ? {} : { proposedBy: filter.by },
38664
38791
  limit: Math.min(filter.offset + filter.limit, 500)
38665
38792
  });
38666
- const rows = await Promise.all(actions.map(async (action) => rowOf7(action, (await batchOf(action)).batch)));
38793
+ const rows = await Promise.all(actions.map(async (action) => rowOf6(action, (await batchOf(action)).batch)));
38667
38794
  return kept(rows, { ...filter, limit: filter.offset + filter.limit });
38668
38795
  }, "list"),
38669
38796
  get: /* @__PURE__ */ __name(async (id2) => {
38670
38797
  const action = await store.proposedActions.get(id2);
38671
- return rowOf7(action, (await batchOf(action)).batch);
38798
+ return rowOf6(action, (await batchOf(action)).batch);
38672
38799
  }, "get"),
38673
38800
  decide: /* @__PURE__ */ __name(async (id2, { confirm, by, parts }) => {
38674
38801
  const { account: account2, batch } = await batchOf(await store.proposedActions.get(id2));
@@ -38681,14 +38808,14 @@ var meetingFindingsKind = /* @__PURE__ */ __name((store) => {
38681
38808
  };
38682
38809
  }, "meetingFindingsKind");
38683
38810
 
38684
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/memory.js
38811
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/memory.js
38685
38812
  var STATUS2 = {
38686
38813
  proposed: "proposed",
38687
38814
  confirmed: "confirmed",
38688
38815
  superseded: "confirmed",
38689
38816
  stale: "rejected"
38690
38817
  };
38691
- var rowOf8 = /* @__PURE__ */ __name((memory) => ({
38818
+ var rowOf7 = /* @__PURE__ */ __name((memory) => ({
38692
38819
  id: memory.ref,
38693
38820
  kind: "memory",
38694
38821
  status: STATUS2[memory.status],
@@ -38713,48 +38840,25 @@ var memoryKind = /* @__PURE__ */ __name((store) => ({
38713
38840
  ...pushed2(filter),
38714
38841
  ...status === "all" ? {} : { status: status === "rejected" ? "stale" : status }
38715
38842
  });
38716
- return kept(memories.map(rowOf8), filter);
38843
+ return kept(memories.map(rowOf7), filter);
38717
38844
  }, "list"),
38718
- get: /* @__PURE__ */ __name(async (id2) => rowOf8(await store.memories.get(id2)), "get"),
38845
+ get: /* @__PURE__ */ __name(async (id2) => rowOf7(await store.memories.get(id2)), "get"),
38719
38846
  decide: /* @__PURE__ */ __name(async (id2, { confirm, by }) => {
38720
38847
  const memory = confirm ? await store.memories.confirm(id2, by) : await store.memories.markStale(id2, by);
38721
38848
  return { id: id2, kind: "memory", status: confirm ? "confirmed" : "rejected", made: confirm ? [memory.ref] : [] };
38722
38849
  }, "decide")
38723
38850
  }), "memoryKind");
38724
38851
 
38725
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/orders.js
38726
- var rowOf9 = /* @__PURE__ */ __name((order) => ({
38727
- id: order.ref,
38728
- kind: "order",
38729
- status: order.review,
38730
- project: order.project,
38731
- subject: order.ref,
38732
- object: order.supplier?.ref ?? null,
38733
- summary: order.title,
38734
- proposedBy: proposerOfAuthor(order.author),
38735
- reason: order.reason,
38736
- evidence: [],
38737
- score: null,
38738
- signals: null,
38739
- parts: null,
38740
- createdAt: order.createdAt
38741
- }), "rowOf");
38742
- var orderKind = /* @__PURE__ */ __name((store) => ({
38743
- kind: "order",
38744
- prefix: "order",
38745
- list: /* @__PURE__ */ __name(async (filter) => {
38746
- const status = filter.status ?? "proposed";
38747
- const orders = await store.orders.list({ ...pushed2(filter), ...status === "all" ? {} : { review: status } });
38748
- return kept(orders.map(rowOf9), filter);
38749
- }, "list"),
38750
- get: /* @__PURE__ */ __name(async (id2) => rowOf9(await store.orders.get(id2)), "get"),
38751
- decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
38752
- const order = confirm ? await store.orders.confirm(id2, by, reason) : await store.orders.reject(id2, by, reason);
38753
- return { id: id2, kind: "order", status: confirm ? "confirmed" : "rejected", made: confirm ? [order.ref] : [] };
38754
- }, "decide")
38852
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/orders.js
38853
+ var orderKind = /* @__PURE__ */ __name((store) => reviewedKind({
38854
+ type: "order",
38855
+ list: /* @__PURE__ */ __name((options) => store.orders.list(options), "list"),
38856
+ get: /* @__PURE__ */ __name((id2) => store.orders.get(id2), "get"),
38857
+ row: /* @__PURE__ */ __name((order) => reviewedRow("order", order, order.supplier?.ref ?? null), "row"),
38858
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.orders.confirm(id2, by, reason) : await store.orders.reject(id2, by, reason)).ref, "decide")
38755
38859
  }), "orderKind");
38756
38860
 
38757
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/relationship.js
38861
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/relationship.js
38758
38862
  var linkRow2 = /* @__PURE__ */ __name((link4) => ({
38759
38863
  id: `link:${link4.id}`,
38760
38864
  kind: "relationship",
@@ -38828,10 +38932,10 @@ var relationshipKind = /* @__PURE__ */ __name((store) => {
38828
38932
  };
38829
38933
  }, "relationshipKind");
38830
38934
 
38831
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/relationship-update.js
38935
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/relationship-update.js
38832
38936
  var KIND2 = "relationship_update";
38833
38937
  var summaryOf2 = /* @__PURE__ */ __name(({ changes }) => Object.entries(changes).map(([field, value]) => `${field} ${value ?? "cleared"}`).join(", "), "summaryOf");
38834
- var rowOf10 = /* @__PURE__ */ __name((action) => {
38938
+ var rowOf8 = /* @__PURE__ */ __name((action) => {
38835
38939
  const payload = action.payload;
38836
38940
  return {
38837
38941
  id: action.id,
@@ -38860,9 +38964,9 @@ var relationshipUpdateKind = /* @__PURE__ */ __name((store) => ({
38860
38964
  ...status === void 0 ? {} : { status },
38861
38965
  ...pushed2(filter)
38862
38966
  });
38863
- return kept(stored.map(rowOf10), filter);
38967
+ return kept(stored.map(rowOf8), filter);
38864
38968
  }, "list"),
38865
- get: /* @__PURE__ */ __name(async (id2) => rowOf10(await store.proposedActions.get(id2)), "get"),
38969
+ get: /* @__PURE__ */ __name(async (id2) => rowOf8(await store.proposedActions.get(id2)), "get"),
38866
38970
  decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
38867
38971
  const { relation } = await store.knowledge.decideRelationUpdate(id2, {
38868
38972
  confirm,
@@ -38878,8 +38982,70 @@ var relationshipUpdateKind = /* @__PURE__ */ __name((store) => ({
38878
38982
  }, "decide")
38879
38983
  }), "relationshipUpdateKind");
38880
38984
 
38881
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/task-close.js
38882
- var rowOf11 = /* @__PURE__ */ __name((task2) => {
38985
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/source-review.js
38986
+ var rowOf9 = /* @__PURE__ */ __name((action) => {
38987
+ const payload = action.payload;
38988
+ const sources = payload.sources.flatMap((source) => source.ref ?? []);
38989
+ const contradicting = payload.challenges.flatMap((challenge) => challenge.evidence);
38990
+ const replacement = payload.sources.find((source) => source.replacement !== void 0)?.replacement ?? null;
38991
+ return {
38992
+ id: action.id,
38993
+ kind: SOURCE_REVIEW_KIND,
38994
+ status: actionStatus(action.status),
38995
+ project: null,
38996
+ subject: action.target ?? payload.target,
38997
+ object: replacement,
38998
+ summary: `${payload.cause}: ${payload.sources.length} source(s), ${payload.challenges.length} challenge(s)`,
38999
+ proposedBy: proposerOfAction(action),
39000
+ reason: payload.challenges.at(-1)?.reason ?? action.reason,
39001
+ evidence: [.../* @__PURE__ */ new Set([...sources, ...contradicting])].slice(0, 5),
39002
+ score: null,
39003
+ signals: null,
39004
+ parts: null,
39005
+ createdAt: payload.raisedAt
39006
+ };
39007
+ }, "rowOf");
39008
+ var sourceReviewKind = /* @__PURE__ */ __name((store) => ({
39009
+ kind: SOURCE_REVIEW_KIND,
39010
+ stored: [SOURCE_REVIEW_KIND],
39011
+ ownerOnly: true,
39012
+ list: /* @__PURE__ */ __name(async (filter) => {
39013
+ const status = storedStatus(filter);
39014
+ const stored = await store.proposedActions.list({
39015
+ kinds: [SOURCE_REVIEW_KIND],
39016
+ ...status === void 0 ? {} : { status },
39017
+ ...pushed2(filter)
39018
+ });
39019
+ return kept(stored.map(rowOf9), filter);
39020
+ }, "list"),
39021
+ get: /* @__PURE__ */ __name(async (id2) => rowOf9(await store.proposedActions.get(id2)), "get"),
39022
+ decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
39023
+ await store.knowledge.decideSourceReview(id2, { confirm, by, ...reason === void 0 ? {} : { reason } });
39024
+ return { id: id2, kind: SOURCE_REVIEW_KIND, status: confirm ? "confirmed" : "rejected", made: [] };
39025
+ }, "decide")
39026
+ }), "sourceReviewKind");
39027
+
39028
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/subscriptions.js
39029
+ var subscriptionKind = /* @__PURE__ */ __name((store) => reviewedKind({
39030
+ type: "subscription",
39031
+ list: /* @__PURE__ */ __name((options) => store.subscriptions.list(options), "list"),
39032
+ get: /* @__PURE__ */ __name((id2) => store.subscriptions.get(id2), "get"),
39033
+ row: /* @__PURE__ */ __name((subscription) => reviewedRow("subscription", subscription, (subscription.direction === "receivable" ? subscription.customer : subscription.supplier).ref), "row"),
39034
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.subscriptions.confirm(id2, by, reason) : await store.subscriptions.reject(id2, by, reason)).ref, "decide")
39035
+ }), "subscriptionKind");
39036
+ var subscriptionPriceKind = /* @__PURE__ */ __name((store) => reviewedKind({
39037
+ type: "subscription_price",
39038
+ list: /* @__PURE__ */ __name(({ review, proposedBy, limit }) => store.subscriptions.prices({ review, proposedBy, limit }), "list"),
39039
+ get: /* @__PURE__ */ __name((id2) => store.subscriptions.price(id2), "get"),
39040
+ row: /* @__PURE__ */ __name((price) => reviewedRow("subscription_price", price, price.subscription), "row"),
39041
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => {
39042
+ await (confirm ? store.subscriptions.confirm(id2, by, reason) : store.subscriptions.reject(id2, by, reason));
39043
+ return id2;
39044
+ }, "decide")
39045
+ }), "subscriptionPriceKind");
39046
+
39047
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/task-close.js
39048
+ var rowOf10 = /* @__PURE__ */ __name((task2) => {
38883
39049
  const suggestion = task2.closeSuggestion;
38884
39050
  if (suggestion === null)
38885
39051
  return void 0;
@@ -38904,7 +39070,7 @@ var taskCloseKind = /* @__PURE__ */ __name((store) => {
38904
39070
  const taskOf = /* @__PURE__ */ __name(async (id2) => {
38905
39071
  const key = id2.slice("close:".length);
38906
39072
  const task2 = await store.tasks.details(key).catch(() => void 0);
38907
- const row = task2 && rowOf11(task2);
39073
+ const row = task2 && rowOf10(task2);
38908
39074
  if (!task2 || !row)
38909
39075
  throw new CliError("not_found", `no close waits on task ${key}`);
38910
39076
  return { task: task2, row };
@@ -38921,7 +39087,7 @@ var taskCloseKind = /* @__PURE__ */ __name((store) => {
38921
39087
  where: { sql: "t.close_suggested_as IS NOT NULL", params: [] },
38922
39088
  limit: filter.offset + filter.limit
38923
39089
  });
38924
- return kept(tasks.flatMap((task2) => rowOf11(task2) ?? []), { ...filter, limit: filter.offset + filter.limit });
39090
+ return kept(tasks.flatMap((task2) => rowOf10(task2) ?? []), { ...filter, limit: filter.offset + filter.limit });
38925
39091
  }, "list"),
38926
39092
  get: /* @__PURE__ */ __name(async (id2) => (await taskOf(id2)).row, "get"),
38927
39093
  decide: /* @__PURE__ */ __name(async (id2, { confirm, by, reason }) => {
@@ -38946,7 +39112,16 @@ var taskCloseKind = /* @__PURE__ */ __name((store) => {
38946
39112
  };
38947
39113
  }, "taskCloseKind");
38948
39114
 
38949
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/proposals/registry.js
39115
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/kinds/transactions.js
39116
+ var transactionKind = /* @__PURE__ */ __name((store) => reviewedKind({
39117
+ type: "transaction",
39118
+ list: /* @__PURE__ */ __name((options) => store.transactions.list(options), "list"),
39119
+ get: /* @__PURE__ */ __name((id2) => store.transactions.get(id2), "get"),
39120
+ row: /* @__PURE__ */ __name((transaction) => reviewedRow("transaction", transaction, transaction.counterparty?.ref ?? transaction.wallet), "row"),
39121
+ decide: /* @__PURE__ */ __name(async (id2, confirm, { by, reason }) => (confirm ? await store.transactions.confirm(id2, by, reason) : await store.transactions.reject(id2, by, reason)).ref, "decide")
39122
+ }), "transactionKind");
39123
+
39124
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/proposals/registry.js
38950
39125
  var PREFIX = /^([a-z][a-z_]*):/;
38951
39126
  var marked = /* @__PURE__ */ __name((kind, row) => kind.ownerOnly ? { ...row, ownerOnly: true } : row, "marked");
38952
39127
  var refusalOf = /* @__PURE__ */ __name((id2, error) => {
@@ -38960,7 +39135,7 @@ var emptyProposalRegistry = /* @__PURE__ */ __name((store) => {
38960
39135
  const policy = store.decisionPolicy;
38961
39136
  const kinds = [];
38962
39137
  const claimed = /* @__PURE__ */ __name(() => kinds.flatMap((kind) => kind.stored ?? []), "claimed");
38963
- const kindOf4 = /* @__PURE__ */ __name(async (id2) => {
39138
+ const kindOf3 = /* @__PURE__ */ __name(async (id2) => {
38964
39139
  const prefix = PREFIX.exec(id2)?.[1];
38965
39140
  const found = prefix !== void 0 ? kinds.find((kind) => kind.prefix === prefix) : await (async () => {
38966
39141
  const stored = (await store.proposedActions.get(id2)).kind;
@@ -38992,7 +39167,7 @@ var emptyProposalRegistry = /* @__PURE__ */ __name((store) => {
38992
39167
  return { items: page.slice(0, filter.limit), hasMore: page.length > filter.limit };
38993
39168
  }, "list"),
38994
39169
  get: /* @__PURE__ */ __name(async (id2) => {
38995
- const kind = await kindOf4(id2);
39170
+ const kind = await kindOf3(id2);
38996
39171
  return marked(kind, await kind.get(id2));
38997
39172
  }, "get"),
38998
39173
  decide: /* @__PURE__ */ __name(async (ids, decision) => {
@@ -39022,7 +39197,7 @@ var emptyProposalRegistry = /* @__PURE__ */ __name((store) => {
39022
39197
  continue;
39023
39198
  }
39024
39199
  try {
39025
- const kind = await kindOf4(id2);
39200
+ const kind = await kindOf3(id2);
39026
39201
  if (chosen.length && !kind.parts) {
39027
39202
  refuseIds(id2, `a ${kind.kind} proposal has no parts; name ${id2} alone`);
39028
39203
  continue;
@@ -39062,19 +39237,24 @@ var proposalRegistry = /* @__PURE__ */ __name((store) => {
39062
39237
  invoiceKind(store),
39063
39238
  paymentKind(store),
39064
39239
  orderKind(store),
39240
+ contractKind(store),
39241
+ subscriptionKind(store),
39242
+ subscriptionPriceKind(store),
39243
+ transactionKind(store),
39065
39244
  organizationKind(store),
39066
39245
  memoryKind(store),
39067
39246
  findingsKind(store),
39068
39247
  mailFindingsKind(store),
39069
39248
  meetingFindingsKind(store),
39070
- taskCloseKind(store)
39249
+ taskCloseKind(store),
39250
+ sourceReviewKind(store)
39071
39251
  ])
39072
39252
  registry.register(kind);
39073
39253
  registry.register(actionKind(store, registry.claimed));
39074
39254
  return registry;
39075
39255
  }, "proposalRegistry");
39076
39256
 
39077
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/stored-meeting-project-candidate-validation.js
39257
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/stored-meeting-project-candidate-validation.js
39078
39258
  var storedCandidateRequest = /* @__PURE__ */ __name((reference, accountId, options) => {
39079
39259
  const invalid6 = /* @__PURE__ */ __name((field) => {
39080
39260
  throw new CliError("validation_error", `invalid stored project candidate ${field}`);
@@ -39116,7 +39296,7 @@ var storedCandidateRequest = /* @__PURE__ */ __name((reference, accountId, optio
39116
39296
  return { reference, limits, after, afterTranscriptId, signal };
39117
39297
  }, "storedCandidateRequest");
39118
39298
 
39119
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/stored-meeting-project-candidates.js
39299
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/stored-meeting-project-candidates.js
39120
39300
  var createStoredMeetingProjectCandidateReader = /* @__PURE__ */ __name((scope, accountId, ports) => {
39121
39301
  const fixed = snapshotMeetingScope(scope);
39122
39302
  const store = ports?.meetings;
@@ -39208,7 +39388,7 @@ var createStoredMeetingProjectCandidateReader = /* @__PURE__ */ __name((scope, a
39208
39388
  };
39209
39389
  }, "createStoredMeetingProjectCandidateReader");
39210
39390
 
39211
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_90db47d7f41d7a563eea7bc9cc13c345/node_modules/@wirecat/cli-core/dist/services/index.js
39391
+ // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3e7ac84c094d466aed903c683c124ab5/node_modules/@wirecat/cli-core/dist/services/index.js
39212
39392
  var servicesFor = /* @__PURE__ */ __name((deps) => {
39213
39393
  const pictures = picturesService(deps);
39214
39394
  const base = {
@@ -39307,6 +39487,9 @@ export {
39307
39487
  createContextEvidenceReader,
39308
39488
  excerpt,
39309
39489
  ingest,
39490
+ jsonlLines,
39491
+ ingestLines,
39492
+ ingestVcard,
39310
39493
  aliasHits,
39311
39494
  chatSenders,
39312
39495
  chatTitle,