@wirecat/cli-memo 0.131.18 → 0.131.19

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 (125) hide show
  1. package/dist/bin/memo.js +2 -2
  2. package/dist/bundle/{all-profiles-23QZDAFJ.js → all-profiles-MVF2XGZK.js} +5 -4
  3. package/dist/bundle/{anthropic-KRFZSA2B.js → anthropic-OPFHMF2S.js} +3 -3
  4. package/dist/bundle/{app-server-ESZGTLU2.js → app-server-VHVC55S3.js} +35 -34
  5. package/dist/bundle/auto-F53FUP45.js +82 -0
  6. package/dist/bundle/{bun-53GOPGVX.js → bun-P6TMDZGU.js} +2 -2
  7. package/dist/bundle/{bun-sqlite-4KFNOFXO.js → bun-sqlite-3G3NLK4O.js} +2 -2
  8. package/dist/bundle/{chunk-OCL47NBH.js → chunk-2KOVYXWK.js} +960 -346
  9. package/dist/bundle/{chunk-XHTVSSX6.js → chunk-2R25UBIH.js} +20 -20
  10. package/dist/bundle/{chunk-XNX6I4Y6.js → chunk-36ULPM2W.js} +2 -2
  11. package/dist/bundle/{chunk-65GCFOVP.js → chunk-3ORDQ62F.js} +6 -6
  12. package/dist/bundle/{chunk-NFKJNCVK.js → chunk-4MIPN37I.js} +144 -144
  13. package/dist/bundle/{chunk-UR2XQFDT.js → chunk-4TERVG26.js} +1 -1
  14. package/dist/bundle/{chunk-46UHRZHI.js → chunk-4VKNUBD5.js} +5 -5
  15. package/dist/bundle/{chunk-BHBJGVFE.js → chunk-57Q6NXQT.js} +3 -3
  16. package/dist/bundle/{chunk-DV3YRUZA.js → chunk-5KUPVC5M.js} +1 -1
  17. package/dist/bundle/{chunk-MOWIIEN4.js → chunk-5XDYV2YT.js} +1 -1
  18. package/dist/bundle/{chunk-VPJQJS3H.js → chunk-63XICXGM.js} +1 -1
  19. package/dist/bundle/{chunk-SPPM44M6.js → chunk-66YZUX2C.js} +4 -4
  20. package/dist/bundle/{chunk-6XRH4A37.js → chunk-6DG7VK3H.js} +2 -2
  21. package/dist/bundle/{chunk-DQONI6JU.js → chunk-7J5HTZCM.js} +1 -1
  22. package/dist/bundle/{chunk-WOYXJJOZ.js → chunk-BINR6MJ5.js} +1 -1
  23. package/dist/bundle/{chunk-P6CJJR55.js → chunk-BMHSGZNE.js} +4 -4
  24. package/dist/bundle/{chunk-TIF4AZ5I.js → chunk-BPYQYZXA.js} +10 -10
  25. package/dist/bundle/{chunk-I4VU7HTS.js → chunk-D6G23NFJ.js} +1 -1
  26. package/dist/bundle/{chunk-IJ2ZAFZ6.js → chunk-DLRLOGVU.js} +4 -4
  27. package/dist/bundle/{chunk-Q7EZ4RG7.js → chunk-EFKEG2BA.js} +2 -2
  28. package/dist/bundle/{chunk-2UATT3OK.js → chunk-EL4ZKQUN.js} +2 -2
  29. package/dist/bundle/{chunk-OTPEBFD4.js → chunk-EMKFG5BP.js} +2 -2
  30. package/dist/bundle/{chunk-OWI3LD55.js → chunk-F5CQ2NVA.js} +10 -87
  31. package/dist/bundle/{chunk-W32TSBMM.js → chunk-FMSA2X3E.js} +1 -1
  32. package/dist/bundle/{chunk-I5FQ6YVU.js → chunk-GJKM32WA.js} +20 -20
  33. package/dist/bundle/{chunk-CAIAS3VT.js → chunk-IW3U6XXI.js} +3 -3
  34. package/dist/bundle/chunk-JDJDNMCP.js +93 -0
  35. package/dist/bundle/{chunk-OVNALS6T.js → chunk-JHKTN6NL.js} +9 -9
  36. package/dist/bundle/{chunk-HJDLAJGM.js → chunk-KO455254.js} +12 -12
  37. package/dist/bundle/{chunk-QVDHD7UF.js → chunk-KVVDRD7M.js} +1 -1
  38. package/dist/bundle/{chunk-PUZ3VNLX.js → chunk-LDVU22MF.js} +5 -5
  39. package/dist/bundle/{chunk-A7KQAW7W.js → chunk-LEUNYKL6.js} +2 -2
  40. package/dist/bundle/{chunk-ZEY2XV7V.js → chunk-LKYHSVQL.js} +7 -7
  41. package/dist/bundle/{chunk-3RXPDCSZ.js → chunk-LQJ4KHXK.js} +8 -8
  42. package/dist/bundle/{chunk-55M2ZGXO.js → chunk-NKTAEBCU.js} +3 -3
  43. package/dist/bundle/{chunk-CL5QVFJA.js → chunk-OTHEM74Z.js} +5 -5
  44. package/dist/bundle/{chunk-OMTNOGFW.js → chunk-OVFMY6ZP.js} +1 -1
  45. package/dist/bundle/{chunk-76I4DYXH.js → chunk-P22V2OLJ.js} +18 -9
  46. package/dist/bundle/{chunk-Q5DWAV74.js → chunk-P3TYFDMP.js} +4 -4
  47. package/dist/bundle/{chunk-P7AB4FU3.js → chunk-RFB5LOYR.js} +4 -4
  48. package/dist/bundle/{chunk-3V7N7LX3.js → chunk-RITXQKYG.js} +5 -5
  49. package/dist/bundle/{chunk-BXF52WH2.js → chunk-SHDZVM3B.js} +1 -1
  50. package/dist/bundle/{chunk-RFVAYHGN.js → chunk-SJLVBJ2L.js} +1 -1
  51. package/dist/bundle/{chunk-PV6UEVGF.js → chunk-SO6VNTF6.js} +1 -1
  52. package/dist/bundle/{chunk-XQN3RYNB.js → chunk-T557KUST.js} +2 -2
  53. package/dist/bundle/{chunk-QEX6BCTL.js → chunk-TQNQS6TR.js} +43 -43
  54. package/dist/bundle/{chunk-OC5LYRFA.js → chunk-UC4IL2P7.js} +1 -1
  55. package/dist/bundle/{chunk-MFRJZAVS.js → chunk-V7DZG62U.js} +7 -7
  56. package/dist/bundle/{chunk-IENYANCU.js → chunk-VQGVPDMH.js} +11 -11
  57. package/dist/bundle/{chunk-6CWWZJM6.js → chunk-VUWUSGSN.js} +4 -4
  58. package/dist/bundle/{chunk-ZMRINA7O.js → chunk-WOIRWVDJ.js} +243 -243
  59. package/dist/bundle/{chunk-HI2DICLB.js → chunk-WRPRPVZF.js} +27 -27
  60. package/dist/bundle/{chunk-GJM5FMWW.js → chunk-XWS4PTES.js} +320 -241
  61. package/dist/bundle/{chunk-VADQ64BX.js → chunk-XZWUBDBG.js} +1 -1
  62. package/dist/bundle/{chunk-SCCPYBHR.js → chunk-Y3DGAYTD.js} +3 -3
  63. package/dist/bundle/{chunk-DDRCYAOJ.js → chunk-YVECM7XA.js} +3 -3
  64. package/dist/bundle/{chunk-H6F7WZRW.js → chunk-Z54GPSVH.js} +51 -51
  65. package/dist/bundle/{chunk-MQ2TLCNP.js → chunk-ZYM4M62Q.js} +1 -1
  66. package/dist/bundle/{command-contract-RO6MFDXO.js → command-contract-NMJKYTS4.js} +11 -10
  67. package/dist/bundle/{decode-4ZC23D7U.js → decode-BUTF6VGO.js} +2 -2
  68. package/dist/bundle/{echarts-PWJPVWHJ.js → echarts-KH3YOWMK.js} +2 -2
  69. package/dist/bundle/{embed-HASNG6ER.js → embed-WBVM7KQ2.js} +3 -3
  70. package/dist/bundle/{embedder-NU6EJLTB.js → embedder-27HQIFHM.js} +6 -6
  71. package/dist/bundle/{entry-SFSRFMWO.js → entry-K2WWMF2B.js} +4 -4
  72. package/dist/bundle/failure-NHDQ5WEW.js +62 -0
  73. package/dist/bundle/{first-run-OSNIHVHZ.js → first-run-7P5N72VR.js} +5 -5
  74. package/dist/bundle/{first-screen-26B3BEL6.js → first-screen-3GM5HC4Y.js} +12 -11
  75. package/dist/bundle/{instructions-V54XGULG.js → instructions-POJKHKRZ.js} +1 -1
  76. package/dist/bundle/mcp-YGWNSJUH.js +86 -0
  77. package/dist/bundle/memo.js +6 -6
  78. package/dist/bundle/{node-J7TQQBYI.js → node-W245R2OP.js} +2 -2
  79. package/dist/bundle/{node-sqlite-ESX7VQKP.js → node-sqlite-FUYOXFW5.js} +3 -3
  80. package/dist/bundle/{oauth-TXZKIG4H.js → oauth-ATB3NWQA.js} +4 -4
  81. package/dist/bundle/{open-QRACRP6K.js → open-HEBEWCYB.js} +2 -2
  82. package/dist/bundle/{openai-QSUFOP44.js → openai-DN7NA2IU.js} +7 -7
  83. package/dist/bundle/{process-PECJIROU.js → process-QTIDOJMF.js} +1 -1
  84. package/dist/bundle/{program-VLYHKDRG.js → program-WNFCYNGP.js} +163 -91
  85. package/dist/bundle/{prompt-E3RWYIKM.js → prompt-RQXVPJ4A.js} +2 -2
  86. package/dist/bundle/{recognize-X45GM6LD.js → recognize-G7NIZ3IT.js} +1 -1
  87. package/dist/bundle/{remote-YBR4S7UN.js → remote-H452UBSK.js} +4 -4
  88. package/dist/bundle/{rerank-35IH2PCJ.js → rerank-77UYD2UD.js} +4 -4
  89. package/dist/bundle/{serve-IRUY567I.js → serve-L6R4ODZV.js} +6 -6
  90. package/dist/bundle/server-SWUSQSRW.js +44 -0
  91. package/dist/bundle/server-W4IKTTUY.js +57 -0
  92. package/dist/bundle/{server-D5SWP77Y.js → server-ZBX4HFHT.js} +55 -50
  93. package/dist/bundle/{setup-K53LBBVC.js → setup-ZGH5OZ7A.js} +39 -38
  94. package/dist/bundle/{state-2GC644IL.js → state-KHMYDV4I.js} +3 -3
  95. package/dist/bundle/{store-73MT2RVQ.js → store-M7KGTLUG.js} +9 -8
  96. package/dist/bundle/store-maintenance-command-ZPN2ZUL4.js +44 -0
  97. package/dist/bundle/update-RFTADFRO.js +65 -0
  98. package/dist/discovery/command.d.ts.map +1 -1
  99. package/dist/discovery/command.js +1 -0
  100. package/dist/discovery/command.js.map +1 -1
  101. package/dist/examples.d.ts.map +1 -1
  102. package/dist/examples.js +5 -0
  103. package/dist/examples.js.map +1 -1
  104. package/dist/mcp/catalogue.d.ts.map +1 -1
  105. package/dist/mcp/catalogue.js +8 -2
  106. package/dist/mcp/catalogue.js.map +1 -1
  107. package/dist/program.d.ts.map +1 -1
  108. package/dist/program.js +15 -0
  109. package/dist/program.js.map +1 -1
  110. package/dist/records/import.d.ts +8 -0
  111. package/dist/records/import.d.ts.map +1 -0
  112. package/dist/records/import.js +72 -0
  113. package/dist/records/import.js.map +1 -0
  114. package/dist/version.d.ts +1 -1
  115. package/dist/version.js +1 -1
  116. package/package.json +2 -2
  117. package/skills/cli-memo/SKILL.md +2 -0
  118. package/dist/bundle/auto-BA5VRQIC.js +0 -81
  119. package/dist/bundle/failure-2E4CILMB.js +0 -61
  120. package/dist/bundle/mcp-M62VFVJS.js +0 -85
  121. package/dist/bundle/server-KMM6CFGV.js +0 -56
  122. package/dist/bundle/server-YUAIDS2B.js +0 -43
  123. package/dist/bundle/store-maintenance-command-TWJ4VLK5.js +0 -43
  124. package/dist/bundle/update-BI2FTFUU.js +0 -64
  125. /package/dist/bundle/{chunk-GUJ6OEF7.js → chunk-7YF2MSEC.js} +0 -0
@@ -6,22 +6,22 @@ import {
6
6
  autoState,
7
7
  lastAutoRun,
8
8
  recordAutoRun
9
- } from "./chunk-Q5DWAV74.js";
9
+ } from "./chunk-P3TYFDMP.js";
10
10
  import {
11
11
  installer,
12
12
  latest,
13
13
  upgradeCommand
14
- } from "./chunk-46UHRZHI.js";
14
+ } from "./chunk-4VKNUBD5.js";
15
15
  import {
16
16
  himalaya,
17
17
  isThrottled,
18
18
  throttledError
19
- } from "./chunk-I4VU7HTS.js";
19
+ } from "./chunk-D6G23NFJ.js";
20
20
  import {
21
21
  mcpOwnerAllowed,
22
22
  readOnlyAvailability,
23
23
  refuseWritesUnderLock
24
- } from "./chunk-3V7N7LX3.js";
24
+ } from "./chunk-RITXQKYG.js";
25
25
  import {
26
26
  answers,
27
27
  atDetail as atDetail2,
@@ -31,7 +31,7 @@ import {
31
31
  trackAnswers,
32
32
  wholeList,
33
33
  withStore
34
- } from "./chunk-IJ2ZAFZ6.js";
34
+ } from "./chunk-DLRLOGVU.js";
35
35
  import {
36
36
  DIALECTS,
37
37
  NOTE_EXTENSIONS,
@@ -46,14 +46,14 @@ import {
46
46
  readMemoId,
47
47
  unsetConfigKey,
48
48
  updateConfig
49
- } from "./chunk-55M2ZGXO.js";
50
- import "./chunk-Q7EZ4RG7.js";
51
- import "./chunk-MFRJZAVS.js";
52
- import "./chunk-CAIAS3VT.js";
49
+ } from "./chunk-NKTAEBCU.js";
50
+ import "./chunk-EFKEG2BA.js";
51
+ import "./chunk-V7DZG62U.js";
52
+ import "./chunk-IW3U6XXI.js";
53
53
  import {
54
54
  errorObject,
55
55
  recognisable
56
- } from "./chunk-SCCPYBHR.js";
56
+ } from "./chunk-Y3DGAYTD.js";
57
57
  import {
58
58
  DISCOVERY_DESCRIPTIONS,
59
59
  addContractInfo,
@@ -93,9 +93,9 @@ import {
93
93
  tasksStatsCommand,
94
94
  unansweredHours,
95
95
  withSqliteSidecars
96
- } from "./chunk-ZMRINA7O.js";
97
- import "./chunk-MOWIIEN4.js";
98
- import "./chunk-WOYXJJOZ.js";
96
+ } from "./chunk-WOIRWVDJ.js";
97
+ import "./chunk-5XDYV2YT.js";
98
+ import "./chunk-BINR6MJ5.js";
99
99
  import "./chunk-QP3KNC5D.js";
100
100
  import {
101
101
  allHitItem,
@@ -105,21 +105,21 @@ import {
105
105
  noteHitItem,
106
106
  offsetOf,
107
107
  shownOf
108
- } from "./chunk-XHTVSSX6.js";
109
- import "./chunk-RFVAYHGN.js";
108
+ } from "./chunk-2R25UBIH.js";
109
+ import "./chunk-SJLVBJ2L.js";
110
110
  import {
111
111
  SKILL_TARGETS,
112
112
  skillCommand,
113
113
  skillPath,
114
114
  skillVersion
115
- } from "./chunk-76I4DYXH.js";
115
+ } from "./chunk-P22V2OLJ.js";
116
116
  import {
117
117
  messageItem,
118
118
  modelGateway,
119
119
  storeInfo,
120
120
  storeSummary
121
- } from "./chunk-QEX6BCTL.js";
122
- import "./chunk-I5FQ6YVU.js";
121
+ } from "./chunk-TQNQS6TR.js";
122
+ import "./chunk-GJKM32WA.js";
123
123
  import {
124
124
  AGENDA_DEFAULTS,
125
125
  DEFAULT_BACKEND,
@@ -148,6 +148,7 @@ import {
148
148
  extractText,
149
149
  gatherStoredProject,
150
150
  importEngine,
151
+ ingest,
151
152
  listQuery,
152
153
  mailTurn,
153
154
  meaningLane,
@@ -187,18 +188,18 @@ import {
187
188
  termField,
188
189
  typedQuery,
189
190
  withQuery
190
- } from "./chunk-GJM5FMWW.js";
191
+ } from "./chunk-XWS4PTES.js";
191
192
  import {
192
193
  readBoundedUtf8File,
193
194
  writeFileAtomic
194
- } from "./chunk-HJDLAJGM.js";
195
+ } from "./chunk-KO455254.js";
195
196
  import {
196
197
  commandsText,
197
198
  inSection,
198
199
  installHelp
199
- } from "./chunk-65GCFOVP.js";
200
+ } from "./chunk-3ORDQ62F.js";
200
201
  import "./chunk-HTQTIKWP.js";
201
- import "./chunk-2UATT3OK.js";
202
+ import "./chunk-EL4ZKQUN.js";
202
203
  import {
203
204
  Command,
204
205
  FETCH,
@@ -238,29 +239,29 @@ import {
238
239
  text,
239
240
  time,
240
241
  untrusted
241
- } from "./chunk-NFKJNCVK.js";
242
- import "./chunk-OWI3LD55.js";
243
- import "./chunk-TIF4AZ5I.js";
242
+ } from "./chunk-4MIPN37I.js";
243
+ import "./chunk-F5CQ2NVA.js";
244
+ import "./chunk-BPYQYZXA.js";
244
245
  import {
245
246
  isNewer
246
247
  } from "./chunk-3DVKC2XM.js";
247
248
  import "./chunk-LPUFOWL3.js";
248
- import "./chunk-DDRCYAOJ.js";
249
- import "./chunk-OVNALS6T.js";
250
- import "./chunk-BXF52WH2.js";
251
- import "./chunk-6CWWZJM6.js";
249
+ import "./chunk-YVECM7XA.js";
250
+ import "./chunk-JHKTN6NL.js";
251
+ import "./chunk-SHDZVM3B.js";
252
+ import "./chunk-VUWUSGSN.js";
252
253
  import {
253
254
  releaseLock,
254
255
  takeLock
255
- } from "./chunk-XQN3RYNB.js";
256
- import "./chunk-PV6UEVGF.js";
257
- import "./chunk-VPJQJS3H.js";
258
- import "./chunk-DV3YRUZA.js";
259
- import "./chunk-A7KQAW7W.js";
260
- import "./chunk-PUZ3VNLX.js";
256
+ } from "./chunk-T557KUST.js";
257
+ import "./chunk-SO6VNTF6.js";
258
+ import "./chunk-63XICXGM.js";
259
+ import "./chunk-5KUPVC5M.js";
260
+ import "./chunk-LEUNYKL6.js";
261
+ import "./chunk-LDVU22MF.js";
261
262
  import {
262
263
  sharedModelsDirectory
263
- } from "./chunk-BHBJGVFE.js";
264
+ } from "./chunk-57Q6NXQT.js";
264
265
  import {
265
266
  provideTerminal,
266
267
  terminalOf
@@ -270,7 +271,7 @@ import {
270
271
  REASONS,
271
272
  STORE_CLIENT,
272
273
  VERSION
273
- } from "./chunk-UR2XQFDT.js";
274
+ } from "./chunk-4TERVG26.js";
274
275
  import {
275
276
  EVIDENCE_FINDINGS_KIND,
276
277
  FINANCE_REVIEWS,
@@ -294,6 +295,7 @@ import {
294
295
  contextEvidenceFingerprint,
295
296
  decodeProjectAnnotationSnapshot,
296
297
  entriesOfList,
298
+ envelopeOfJsonl,
297
299
  formatLocator,
298
300
  formatReference,
299
301
  isBusy,
@@ -310,7 +312,7 @@ import {
310
312
  queryFilter,
311
313
  refLabel,
312
314
  validateFields
313
- } from "./chunk-OCL47NBH.js";
315
+ } from "./chunk-2KOVYXWK.js";
314
316
  import {
315
317
  FACT_STATUSES,
316
318
  FACT_TYPES,
@@ -337,18 +339,19 @@ import {
337
339
  timezoneOf,
338
340
  validateQuery,
339
341
  walkQuery
340
- } from "./chunk-H6F7WZRW.js";
341
- import "./chunk-ZEY2XV7V.js";
342
- import "./chunk-P7AB4FU3.js";
342
+ } from "./chunk-Z54GPSVH.js";
343
+ import "./chunk-JDJDNMCP.js";
344
+ import "./chunk-LKYHSVQL.js";
345
+ import "./chunk-RFB5LOYR.js";
343
346
  import {
344
347
  storePath
345
- } from "./chunk-DQONI6JU.js";
348
+ } from "./chunk-7J5HTZCM.js";
346
349
  import "./chunk-NUN6OGOV.js";
347
- import "./chunk-CL5QVFJA.js";
348
- import "./chunk-VADQ64BX.js";
349
- import "./chunk-W32TSBMM.js";
350
- import "./chunk-OTPEBFD4.js";
351
- import "./chunk-QVDHD7UF.js";
350
+ import "./chunk-OTHEM74Z.js";
351
+ import "./chunk-XZWUBDBG.js";
352
+ import "./chunk-FMSA2X3E.js";
353
+ import "./chunk-EMKFG5BP.js";
354
+ import "./chunk-KVVDRD7M.js";
352
355
  import {
353
356
  CliError,
354
357
  array,
@@ -10426,14 +10429,14 @@ var collect = /* @__PURE__ */ __name((value, previous = []) => [...previous, val
10426
10429
  var readScope = /* @__PURE__ */ __name((command, help = ONE_ACCOUNT_HELP) => sourceOptions(command, help).option("--json", "print JSON; --json=id,title keeps only those fields"), "readScope");
10427
10430
  var writeScope = /* @__PURE__ */ __name((command, help) => writeOptions(command, help).option("--json", "print JSON; --json=id,title keeps only those fields"), "writeScope");
10428
10431
 
10429
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/account-key.js
10432
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/account-key.js
10430
10433
  var mailAccountKey = /* @__PURE__ */ __name((address) => ({ provider: "email", account: address.toLowerCase() }), "mailAccountKey");
10431
10434
 
10432
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/bulk.js
10435
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/bulk.js
10433
10436
  var BULK = "bulk";
10434
10437
  var bulkBox = { externalId: "memo:bulk", name: "bulk", kind: BULK };
10435
10438
 
10436
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/score.js
10439
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/score.js
10437
10440
  var import_disposable_email_domains_js = __toESM(require_dist(), 1);
10438
10441
  var import_tldts = __toESM(require_cjs(), 1);
10439
10442
  var WEIGHTS = {
@@ -10567,7 +10570,7 @@ var scoreGroup = /* @__PURE__ */ __name((items, context) => {
10567
10570
  return { score: kept.reduce((sum, signal) => sum + WEIGHTS[signal], 0), signals: kept };
10568
10571
  }, "scoreGroup");
10569
10572
 
10570
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/presets.js
10573
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/presets.js
10571
10574
  var PRESETS = {
10572
10575
  social: {
10573
10576
  about: "notifications from social networks",
@@ -10659,7 +10662,7 @@ var presetMatches = /* @__PURE__ */ __name((name, facts) => {
10659
10662
  return false;
10660
10663
  }, "presetMatches");
10661
10664
 
10662
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/probe.js
10665
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/probe.js
10663
10666
  var SUGGEST_RULE = "suggest is skip when a group has at least 20 emails, at least 80% of them list or bulk mail (List-Id, List-Unsubscribe or Precedence: bulk) and the owner never sent mail to its sender";
10664
10667
  var share = /* @__PURE__ */ __name((part, whole2) => Math.round(part / whole2 * 100) / 100, "share");
10665
10668
  var isSent = /* @__PURE__ */ __name((item) => item.labels?.includes("Sent") || /(^|\/)sent\b/i.test(item.folder ?? ""), "isSent");
@@ -10736,7 +10739,7 @@ var domainsToAge = /* @__PURE__ */ __name((groups, skip) => [
10736
10739
  }))
10737
10740
  ], "domainsToAge");
10738
10741
 
10739
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/facts.js
10742
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/facts.js
10740
10743
  var factsOf = /* @__PURE__ */ __name((listed, rules, ages = /* @__PURE__ */ new Map()) => {
10741
10744
  const grouped = rules.some(({ match }) => match.score_at_least !== void 0 || match.preset !== void 0);
10742
10745
  if (!grouped)
@@ -10754,7 +10757,7 @@ var factsOf = /* @__PURE__ */ __name((listed, rules, ages = /* @__PURE__ */ new
10754
10757
  };
10755
10758
  }, "factsOf");
10756
10759
 
10757
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/folders.js
10760
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/folders.js
10758
10761
  var GMAIL_ALL_MAIL = "[Gmail]/All Mail";
10759
10762
  var mailFolders = /* @__PURE__ */ __name(async (account2, source) => {
10760
10763
  if (account2.folders)
@@ -10765,7 +10768,7 @@ var mailFolders = /* @__PURE__ */ __name(async (account2, source) => {
10765
10768
  return [all ?? GMAIL_ALL_MAIL];
10766
10769
  }, "mailFolders");
10767
10770
 
10768
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/gone.js
10771
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/gone.js
10769
10772
  var PAGE = 500;
10770
10773
  var MAX_DELETED_SHARE = 0.2;
10771
10774
  var MIN_DELETIONS_CAPPED = 5;
@@ -16064,7 +16067,7 @@ var PostalMime = class _PostalMime {
16064
16067
  }
16065
16068
  };
16066
16069
 
16067
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/headers.js
16070
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/headers.js
16068
16071
  var HEADER_FIELDS = "FROM TO CC SUBJECT LIST-ID LIST-UNSUBSCRIBE PRECEDENCE REPLY-TO AUTHENTICATION-RESULTS CONTENT-TYPE";
16069
16072
  var unfold = /* @__PURE__ */ __name((text3) => text3.replace(/\r?\n[ \t]+/g, " "), "unfold");
16070
16073
  var field = /* @__PURE__ */ __name((unfolded, name) => new RegExp(`^${name}:[ \\t]*(.*?)\\r?$`, "im").exec(unfolded)?.[1], "field");
@@ -16140,7 +16143,7 @@ var mailHeadersOf = /* @__PURE__ */ __name((raw) => {
16140
16143
  };
16141
16144
  }, "mailHeadersOf");
16142
16145
 
16143
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/ids.js
16146
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/ids.js
16144
16147
  import { createHash } from "node:crypto";
16145
16148
  var digest = /* @__PURE__ */ __name((id) => `imap:${createHash("sha256").update(id).digest("hex")}`, "digest");
16146
16149
  var firstId = /* @__PURE__ */ __name((value) => /<[^<>\s]+>/.exec(value ?? "")?.[0], "firstId");
@@ -16151,7 +16154,7 @@ var mailIds = /* @__PURE__ */ __name(({ messageId, head, folder, validity, uid }
16151
16154
  return { messageId: digest(identity), threadId: digest(root ?? identity) };
16152
16155
  }, "mailIds");
16153
16156
 
16154
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/labels.js
16157
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/labels.js
16155
16158
  var SYSTEM_LABELS = {
16156
16159
  inbox: "Inbox",
16157
16160
  sent: "Sent",
@@ -16179,7 +16182,7 @@ var decodedLabelName = /* @__PURE__ */ __name((name) => {
16179
16182
  }, "decodedLabelName");
16180
16183
  var labelName = /* @__PURE__ */ __name((raw) => decodedLabelName(decodeMailboxName(raw)), "labelName");
16181
16184
 
16182
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/marks.js
16185
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/marks.js
16183
16186
  var HOLDER = /^[a-z0-9][a-z0-9-]{0,39}$/;
16184
16187
  var MARK_BATCH = 200;
16185
16188
  var HOLD_PARTIAL_MS = 7 * 864e5;
@@ -16336,7 +16339,7 @@ var acknowledgeMark = /* @__PURE__ */ __name(async (store, mailbox, holder, curs
16336
16339
  return { holder, ...next, updatedAt: now };
16337
16340
  }, "acknowledgeMark");
16338
16341
 
16339
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/parse.js
16342
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/parse.js
16340
16343
  var MAX_BODY_CHARS = 1e6;
16341
16344
  var MAX_ATTACHMENTS = 50;
16342
16345
  var BRACKETED_ID = /<[^<>\s]+>/g;
@@ -16401,7 +16404,7 @@ var parseMail = /* @__PURE__ */ __name(async (raw, maxBodyChars = MAX_BODY_CHARS
16401
16404
  };
16402
16405
  }, "parseMail");
16403
16406
 
16404
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/attachments.js
16407
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/attachments.js
16405
16408
  var MAX_ATTACHMENT_CHARS = 2e5;
16406
16409
  var FETCH_CHUNK = 50;
16407
16410
  var addressOf = /* @__PURE__ */ __name(({ email, name }) => ({ address: email, name }), "addressOf");
@@ -16438,7 +16441,7 @@ var readAttachments = /* @__PURE__ */ __name(async (mail, messageId, { loadEngin
16438
16441
  return files;
16439
16442
  }, "readAttachments");
16440
16443
 
16441
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/email-input.js
16444
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/email-input.js
16442
16445
  var sentAtOf = /* @__PURE__ */ __name((date, receivedAt) => {
16443
16446
  const sent = date === null ? Number.NaN : Date.parse(date);
16444
16447
  return Number.isNaN(sent) ? Date.parse(receivedAt) : sent;
@@ -16458,7 +16461,7 @@ var parsedEmail = /* @__PURE__ */ __name((mail, item, header, address) => ({
16458
16461
  outgoing: mail.from === null ? null : mail.from.email === address
16459
16462
  }), "parsedEmail");
16460
16463
 
16461
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/partial.js
16464
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/partial.js
16462
16465
  var PARTIAL = "partial";
16463
16466
  var PARTIAL_PER_RUN = 100;
16464
16467
  var PARTIAL_TRIES = 3;
@@ -16559,7 +16562,7 @@ var completePartial = /* @__PURE__ */ __name(async ({ store, source, accountId,
16559
16562
  return { completed, left: total - completed - given, stuck: stuck + given };
16560
16563
  }, "completePartial");
16561
16564
 
16562
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/resume.js
16565
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/resume.js
16563
16566
  import { createHash as createHash2 } from "node:crypto";
16564
16567
  var FULL_PASS_MS = 864e5;
16565
16568
  var resumeKey = /* @__PURE__ */ __name((folder) => `mail_resume:${folder}`, "resumeKey");
@@ -16613,7 +16616,7 @@ var parsePoint = /* @__PURE__ */ __name((value) => {
16613
16616
  }
16614
16617
  }, "parsePoint");
16615
16618
 
16616
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/read.js
16619
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/read.js
16617
16620
  var lowerSuspicious = /* @__PURE__ */ __name((items, suspicious) => [
16618
16621
  ...items.filter((item) => !suspicious(item)),
16619
16622
  ...items.filter(suspicious)
@@ -16700,7 +16703,7 @@ var attachmentsText = /* @__PURE__ */ __name((hit) => (hit.attachments ?? []).ma
16700
16703
  ${file.text.replace(/\n/g, "\n ")}`;
16701
16704
  }).join("\n"), "attachmentsText");
16702
16705
 
16703
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/review.js
16706
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/review.js
16704
16707
  var REVIEW_THREADS = 50;
16705
16708
  var REVIEW_PER_THREAD = 50;
16706
16709
  var OWED_DAYS = 30;
@@ -16798,7 +16801,7 @@ var reviewMail = /* @__PURE__ */ __name(async (store, mailbox, options) => {
16798
16801
  };
16799
16802
  }, "reviewMail");
16800
16803
 
16801
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/rules.js
16804
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/rules.js
16802
16805
  var DAY_MS2 = 24 * 60 * 60 * 1e3;
16803
16806
  var domainOf = /* @__PURE__ */ __name((address) => address.slice(address.lastIndexOf("@") + 1), "domainOf");
16804
16807
  var domainMatches = /* @__PURE__ */ __name((wanted3, sender) => {
@@ -16887,7 +16890,7 @@ var envelopeBoxOf = /* @__PURE__ */ __name((externalId) => {
16887
16890
  return { externalId, name: `envelope: ${kind} ${value.join(":")}`, kind: ENVELOPE };
16888
16891
  }, "envelopeBoxOf");
16889
16892
 
16890
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/rule-input.js
16893
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/rule-input.js
16891
16894
  var STORE_ACTION = { keep: "full", envelope: "envelope", skip: "skip" };
16892
16895
  var LOWER = ["from", "domain", "list_id", "subject"];
16893
16896
  var conditionsOf = /* @__PURE__ */ __name((match) => Object.fromEntries(conditionKeys(match).map((key) => {
@@ -16917,7 +16920,7 @@ var ruleInput = /* @__PURE__ */ __name((rule, source = rule.source ?? "owner") =
16917
16920
  decidedAt: decidedAtOf(rule.decided_at)
16918
16921
  }), "ruleInput");
16919
16922
 
16920
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/rule-stored.js
16923
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/rule-stored.js
16921
16924
  var ACTION_OF = { full: "keep", envelope: "envelope", skip: "skip" };
16922
16925
  var KINDS = {
16923
16926
  from: "string",
@@ -16986,7 +16989,7 @@ var storedMailRuleSet = /* @__PURE__ */ __name(async (store, account2, query) =>
16986
16989
  }, "storedMailRuleSet");
16987
16990
  var storedMailRules = /* @__PURE__ */ __name(async (store, account2, query) => (await storedMailRuleSet(store, account2, query)).rules, "storedMailRules");
16988
16991
 
16989
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/rule-tags.js
16992
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/rule-tags.js
16990
16993
  var reuseOf = /* @__PURE__ */ __name((error) => {
16991
16994
  const { details } = error;
16992
16995
  return details?.reason === "tag-review.required" ? details.candidates?.[0]?.name : void 0;
@@ -17047,7 +17050,7 @@ var settleRuleTags = /* @__PURE__ */ __name(async (store, accountId, rules, outc
17047
17050
  }
17048
17051
  }, "settleRuleTags");
17049
17052
 
17050
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/stored.js
17053
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/stored.js
17051
17054
  var listedOf2 = /* @__PURE__ */ __name((email) => {
17052
17055
  const labels = email.mailboxes.filter(({ kind }) => kind === "label").map(({ name }) => name);
17053
17056
  if (email.flagged && !labels.includes("Starred"))
@@ -17080,7 +17083,7 @@ var listedOf2 = /* @__PURE__ */ __name((email) => {
17080
17083
  };
17081
17084
  }, "listedOf");
17082
17085
 
17083
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/sender-scores.js
17086
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/sender-scores.js
17084
17087
  var SCORED = "mail_sender_scores";
17085
17088
  var SCORE_VERSION = 4;
17086
17089
  var DEMOTE_AT = 3;
@@ -17159,7 +17162,7 @@ var demotedSenders = /* @__PURE__ */ __name(async (store) => {
17159
17162
  return senders;
17160
17163
  }, "demotedSenders");
17161
17164
 
17162
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/server-query.js
17165
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/server-query.js
17163
17166
  var DAY2 = 864e5;
17164
17167
  var empty = /* @__PURE__ */ __name(() => ({ words: [], from: [], to: [], cc: [], subject: [], body: [] }), "empty");
17165
17168
  var narrows = /* @__PURE__ */ __name((criteria) => criteria.words.length + criteria.from.length + criteria.to.length + criteria.cc.length + criteria.subject.length + criteria.body.length > 0 || criteria.since !== void 0 || criteria.before !== void 0 || criteria.seen !== void 0 || criteria.flagged !== void 0, "narrows");
@@ -17232,7 +17235,7 @@ var mailCriteriaOf = /* @__PURE__ */ __name((text3, { exact, timezone } = {}) =>
17232
17235
  };
17233
17236
  }, "mailCriteriaOf");
17234
17237
 
17235
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/server-search.js
17238
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/server-search.js
17236
17239
  var refusal = {
17237
17240
  unsupported: "this mailbox's server cannot be searched \u2014 use --backend archive",
17238
17241
  offline: "--backend server needs the network \u2014 not with --offline",
@@ -17447,14 +17450,14 @@ var searchMailServer = /* @__PURE__ */ __name(async (store, mailbox, access, req
17447
17450
  return { report, sources };
17448
17451
  }, "searchMailServer");
17449
17452
 
17450
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/source.js
17453
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/source.js
17451
17454
  var SEARCH_REFUSED = "mail.search-refused";
17452
17455
  var searchRefused = /* @__PURE__ */ __name((error) => error instanceof CliError && error.details.reason === SEARCH_REFUSED, "searchRefused");
17453
17456
 
17454
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/sync.js
17457
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/sync.js
17455
17458
  import { setTimeout as setTimeout2 } from "node:timers/promises";
17456
17459
 
17457
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/locations.js
17460
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/locations.js
17458
17461
  var flagsToRefresh = /* @__PURE__ */ __name((rows, listing) => {
17459
17462
  const changes = /* @__PURE__ */ new Map();
17460
17463
  for (const { uid, seen, flagged } of listing) {
@@ -17501,7 +17504,7 @@ var proveByLocation = /* @__PURE__ */ __name(async (store, accountId, { folders,
17501
17504
  return { deleted };
17502
17505
  }, "proveByLocation");
17503
17506
 
17504
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/quick.js
17507
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/quick.js
17505
17508
  var FETCH_SLICE = 50;
17506
17509
  var keyOf2 = /* @__PURE__ */ __name((folder, uid) => `${folder}\0${uid}`, "keyOf");
17507
17510
  var readQuick = /* @__PURE__ */ __name(async (source, since, folder, searched, done, max, plan, located) => {
@@ -17571,7 +17574,7 @@ var readQuick = /* @__PURE__ */ __name(async (source, since, folder, searched, d
17571
17574
  return answer;
17572
17575
  }, "readQuick");
17573
17576
 
17574
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/retry.js
17577
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/retry.js
17575
17578
  var RETRYABLE_ATTACHMENTS = ["engine-missing"];
17576
17579
  var retryUnread = /* @__PURE__ */ __name(async ({ store, source, account: account2, since, max, maxBodyChars, maxAttachmentChars, now, loadEngine, index }) => {
17577
17580
  const startedAt = now();
@@ -17671,7 +17674,7 @@ var retryUnread = /* @__PURE__ */ __name(async ({ store, source, account: accoun
17671
17674
  };
17672
17675
  }, "retryUnread");
17673
17676
 
17674
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/sync.js
17677
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/sync.js
17675
17678
  var DAY3 = 864e5;
17676
17679
  var EDGE = 2 * DAY3;
17677
17680
  var SAVE_EVERY_MS = 3e4;
@@ -19916,7 +19919,7 @@ import { createHash as createHash3 } from "node:crypto";
19916
19919
  import { existsSync, readFileSync as readFileSync2, statSync } from "node:fs";
19917
19920
  import { basename, extname, relative, sep } from "node:path";
19918
19921
 
19919
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/services/documents/extraction.js
19922
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/services/documents/extraction.js
19920
19923
  var Proposal = object({
19921
19924
  kind: picklist(["summary", "digest", "fact", "preference"]),
19922
19925
  body: pipe(string(), trim(), minLength(1), maxLength(15e3)),
@@ -19924,10 +19927,10 @@ var Proposal = object({
19924
19927
  });
19925
19928
  var Proposals = object({ items: pipe(array(Proposal), maxLength(20)) });
19926
19929
 
19927
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/services/documents/mirrors.js
19930
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/services/documents/mirrors.js
19928
19931
  var ID = pipe(string(), regex(/^[A-Za-z0-9_-]{1,200}$/));
19929
19932
 
19930
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/services/documents/sync.js
19933
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/services/documents/sync.js
19931
19934
  var MAX_PICTURE_BYTES = 25 * 1024 * 1024;
19932
19935
 
19933
19936
  // dist/notes/links.js
@@ -20233,7 +20236,7 @@ var importNotesMap = /* @__PURE__ */ __name(async (store, env, folders) => {
20233
20236
  return linked2;
20234
20237
  }, "importNotesMap");
20235
20238
 
20236
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/cli/marks.js
20239
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/cli/marks.js
20237
20240
  var iso = /* @__PURE__ */ __name((ms) => ms === null ? null : new Date(ms).toISOString(), "iso");
20238
20241
  var mailMark = strictObject({
20239
20242
  holder: string(),
@@ -20266,7 +20269,7 @@ var acknowledgeCommand = /* @__PURE__ */ __name((mail) => answerEntity(destroysN
20266
20269
  renderAnswer(this, outputFor(this), itemOf(markItem(mark)), () => markText(mark));
20267
20270
  }), "acknowledgeCommand");
20268
20271
 
20269
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/cli/review.js
20272
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/cli/review.js
20270
20273
  var DAY4 = 864e5;
20271
20274
  var MAIL_REVIEW_QUERY = defineQuery({
20272
20275
  entity: "message",
@@ -20481,7 +20484,7 @@ an agent over MCP, and each scheduled run.`).action(async function(query) {
20481
20484
  saved?.save(found.checked ?? {}, found.complete ? { through: found.until } : {});
20482
20485
  }), "mailReviewCommand");
20483
20486
 
20484
- // node_modules/.pnpm/@wirecat+cli-core@0.558.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_453e84576400aa35c5cf5bcf0ba79cec/node_modules/@wirecat/cli-core/dist/mail/cli/index.js
20487
+ // node_modules/.pnpm/@wirecat+cli-core@0.559.0_@wirecat+cli-base@0.75.0_commander@15.0.0_esbuild@0.28.2_type_907a8c00de2c01e4b50d7050f36772c6/node_modules/@wirecat/cli-core/dist/mail/cli/index.js
20485
20488
  var absentAccount = /* @__PURE__ */ __name((error) => {
20486
20489
  if (error instanceof CliError && error.code === "not_found")
20487
20490
  return void 0;
@@ -22500,6 +22503,7 @@ var SECTIONS = [
22500
22503
  ["organizations", "organise"],
22501
22504
  ["invoices", "organise"],
22502
22505
  ["payments", "organise"],
22506
+ ["records", "organise"],
22503
22507
  ["projects", "organise"],
22504
22508
  ["people", "organise"],
22505
22509
  ["relationships", "organise"],
@@ -22847,6 +22851,11 @@ var EXAMPLES = {
22847
22851
  "payments add": [
22848
22852
  "memo payments add 25000.00 RUB --kind in --organization organization:3 --occurred-time 2026-11-01 --project HRB"
22849
22853
  ],
22854
+ "records import": [
22855
+ "memo records import payments.jsonl --account prokat-med --dry-run",
22856
+ "memo records import envelope.json --account prokat-med --json"
22857
+ ],
22858
+ "records check": ["memo records check - --account prokat-med"],
22850
22859
  "payments allocate": ["memo payments allocate payment:9 invoice:4 25000.00"],
22851
22860
  "facts show": ["memo facts show fact:4 --sources"],
22852
22861
  "facts confirm": ["memo facts confirm fact:4"],
@@ -25376,7 +25385,7 @@ var mailSetupCommand = /* @__PURE__ */ __name((mail, streams, env) => {
25376
25385
  effects: LOCAL_WRITE,
25377
25386
  examples: ["memo mail add work you@example.test --kind imap"]
25378
25387
  })).description("add an explicit account after matching its Himalaya email").argument("[account]", "one Himalaya account name; omission lists choices and changes nothing").argument("[address]", "must match the email configured for this Himalaya account").option("--kind <kind>", "gmail or imap", oneOf(["gmail", "imap"]), "gmail").option("--folder <folder>", "mail folder to import; repeat for several", collect).option("--json", "print the added account as JSON").action(async (account2, address, given) => {
25379
- const { addMailAccount } = await import("./setup-K53LBBVC.js");
25388
+ const { addMailAccount } = await import("./setup-ZGH5OZ7A.js");
25380
25389
  print(given.json, itemAnswer(await addMailAccount(env, {
25381
25390
  ...account2 ? { name: account2 } : {},
25382
25391
  ...address ? { address } : {},
@@ -25389,7 +25398,7 @@ var mailSetupCommand = /* @__PURE__ */ __name((mail, streams, env) => {
25389
25398
  const saved = accounts.find((one2) => one2.name === account2);
25390
25399
  if (!saved)
25391
25400
  throw new CliError("validation_error", `name one Memo account explicitly; choices: ${accounts.map((one2) => one2.name).join(", ") || "none"}`);
25392
- const { checkMailAccount } = await import("./setup-K53LBBVC.js");
25401
+ const { checkMailAccount } = await import("./setup-ZGH5OZ7A.js");
25393
25402
  print(given.json, itemAnswer(await checkMailAccount(env, { name: saved.name, address: saved.address })));
25394
25403
  });
25395
25404
  }, "mailSetupCommand");
@@ -25505,10 +25514,10 @@ var mcpCommandDefinition = /* @__PURE__ */ __name((program, streams, env, create
25505
25514
  }).summary("serve this profile's commands to an AI agent").description("serve memo commands over MCP on stdio or authenticated HTTP, limited by saved permissions").option("--permission <key=level>", "tighten one saved permission for this server; repeat for more keys", (value, previous = []) => [...previous, value]).option("--http", "serve on 127.0.0.1 behind an HTTPS tunnel with an owner access-code login").option("--port <port>", `local HTTP port (default ${DEFAULT_PORT}); requires --http`).option("--public-url <url>", "tunnel's HTTPS address without /mcp, or a path of it such as https://<name>.ts.net/memo; requires --http").action(async (options) => {
25506
25515
  if (!options.http && (options.port !== void 0 || options.publicUrl !== void 0))
25507
25516
  throw new CliError("validation_error", "--port and --public-url require --http");
25508
- const { createMemoServer } = await import("./server-D5SWP77Y.js");
25517
+ const { createMemoServer } = await import("./server-ZBX4HFHT.js");
25509
25518
  const build = /* @__PURE__ */ __name(() => createMemoServer(env, createProgram2, options.permission), "build");
25510
25519
  if (options.http) {
25511
- const { httpLockFile, mcpUrlOf, portOf, publicUrlOf, serveOverHttp } = await import("./mcp-M62VFVJS.js");
25520
+ const { httpLockFile, mcpUrlOf, portOf, publicUrlOf, serveOverHttp } = await import("./mcp-YGWNSJUH.js");
25512
25521
  const publicUrl = publicUrlOf(options.publicUrl, {
25513
25522
  missing: "--http",
25514
25523
  reaches: "the browser apps reach memo",
@@ -25560,7 +25569,7 @@ var mcpCommandDefinition = /* @__PURE__ */ __name((program, streams, env, create
25560
25569
  });
25561
25570
  });
25562
25571
  annotate(mcp2.command("revoke"), { effects: LOCAL_WRITE, mcp: false, examples: ["memo mcp revoke --json"] }).summary("forget every login given to a browser app").description("forget every login `memo mcp serve --http` gave a browser app; each app must log in again").option("--json", "print JSON").action(async function() {
25563
- const { revokeAll } = await import("./mcp-M62VFVJS.js");
25572
+ const { revokeAll } = await import("./mcp-YGWNSJUH.js");
25564
25573
  revokeAll(httpTokenFile(env));
25565
25574
  out.print(this.opts().json, itemAnswer({ revoked: true }));
25566
25575
  });
@@ -26344,6 +26353,55 @@ var peopleCommand = /* @__PURE__ */ __name((program, streams, env) => {
26344
26353
  });
26345
26354
  }, "peopleCommand");
26346
26355
 
26356
+ // dist/records/import.js
26357
+ import { readFile } from "node:fs/promises";
26358
+ var readAll = /* @__PURE__ */ __name(async (file, stdin) => {
26359
+ if (file !== "-")
26360
+ return readFile(file, "utf8");
26361
+ let text3 = "";
26362
+ stdin.setEncoding("utf8");
26363
+ for await (const chunk of stdin)
26364
+ text3 += chunk;
26365
+ return text3;
26366
+ }, "readAll");
26367
+ var envelopeOf = /* @__PURE__ */ __name((text3) => {
26368
+ try {
26369
+ const whole2 = JSON.parse(text3);
26370
+ if (whole2 && typeof whole2 === "object" && "records" in whole2)
26371
+ return whole2;
26372
+ } catch {
26373
+ }
26374
+ return envelopeOfJsonl(text3);
26375
+ }, "envelopeOf");
26376
+ var receiptText = /* @__PURE__ */ __name((receipt) => [
26377
+ `${receipt.dryRun ? "would import" : "imported"} ${receipt.source?.batchId ?? "nothing"}: ${receipt.created} created, ${receipt.updated} updated, ${receipt.unchanged} unchanged, ${receipt.deleted} deleted, ${receipt.refused} refused`,
26378
+ ...receipt.proposed.length ? [`proposed for your review (memo review kind:invoice,payment): ${receipt.proposed.join(" ")}`] : [],
26379
+ ...receipt.waiting.map((one2) => `waiting ${one2.key}: no entity yet for ${one2.missing.join(", ")}`),
26380
+ ...receipt.flagged.map((one2) => `changed at the source ${one2.key}: ${one2.entity} kept as it was`),
26381
+ ...receipt.errors.map((one2) => `refused ${one2.pointer} \xB7 ${one2.message} (${one2.code})`)
26382
+ ].join("\n"), "receiptText");
26383
+ var recordsCommand = /* @__PURE__ */ __name((program, streams, env) => {
26384
+ const { print } = answers(program, streams, env);
26385
+ const records = program.command("records").description("what a source said, kept per account; invoices and payments from it wait for your review").summary("what a source said, kept per account");
26386
+ const importing = /* @__PURE__ */ __name((command, dryRun) => command.argument("<file>", "a records envelope as JSON, or JSONL (a header line, then a record per line); - for stdin").option("--account <account>", "the source account the envelope is for, as its source.account says").option("--json", "print JSON; --json=created,errors keeps only those fields").action(async (file, given) => {
26387
+ const account2 = given.account?.trim();
26388
+ if (!account2)
26389
+ throw new CliError("validation_error", "name the source account the envelope is for: --account <account>", {
26390
+ param: "--account"
26391
+ });
26392
+ const envelope = envelopeOf(await readAll(file, environmentOf(program).stdin ?? process.stdin));
26393
+ const receipt = await withStore(env, (store) => ingest(store, envelope, { account: account2, dryRun: dryRun ?? given.dryRun === true }));
26394
+ const issues = receipt.errors.map((one2) => ({
26395
+ code: "validation_error",
26396
+ source: one2.pointer,
26397
+ reason: one2.code
26398
+ }));
26399
+ print(given.json, itemAnswer(receipt, issues.length ? { meta: { complete: false, issues } } : void 0), receiptText(receipt));
26400
+ }), "importing");
26401
+ importing(annotate(records.command("import"), { effects: LOCAL_WRITE, output: { entity: "records_receipt" } }).description("bring a source's records into the store, once: the same file twice changes nothing, a lower revision is refused, and an invoice or a payment becomes a proposal for you, never confirmed money").summary("import a source's records; money waits for your review").option("--dry-run", "check and plan the import; write nothing"), void 0);
26402
+ importing(annotate(records.command("check"), { effects: LOCAL_READ, output: { entity: "records_receipt" } }).description("what records import would do with the file, as its receipt, writing nothing").summary("check a records file against the store; write nothing"), true);
26403
+ }, "recordsCommand");
26404
+
26347
26405
  // dist/review/command.js
26348
26406
  var PROPOSAL = strictObject({
26349
26407
  id: string(),
@@ -28134,6 +28192,19 @@ var OWN_ENTITIES = entityFields({
28134
28192
  "updated_at",
28135
28193
  "allocations"
28136
28194
  ],
28195
+ records_receipt: [
28196
+ "dry_run",
28197
+ "source",
28198
+ "created",
28199
+ "updated",
28200
+ "unchanged",
28201
+ "deleted",
28202
+ "refused",
28203
+ "proposed",
28204
+ "waiting",
28205
+ "flagged",
28206
+ "errors"
28207
+ ],
28137
28208
  payment_allocation: ["payment", "invoice", "amount", "currency", "created_at"]
28138
28209
  });
28139
28210
  var FIRST_SCREEN = {
@@ -28173,6 +28244,7 @@ var createProgram = /* @__PURE__ */ __name(({ streams: raw = processStreams, env
28173
28244
  mentionsCommand(program, streams, env);
28174
28245
  factsCommand(program, streams, env);
28175
28246
  financeCommands(program, streams, env);
28247
+ recordsCommand(program, streams, env);
28176
28248
  findingsCommand(program, streams, env);
28177
28249
  actionsCommand(program, streams, env);
28178
28250
  reviewCommand(program, streams, env);