@wirecat/zoom-cli 0.55.0 → 0.57.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 (170) hide show
  1. package/README.md +4 -4
  2. package/dist/bin/zm.js +35 -5
  3. package/dist/bundle/all-profiles-EKHWTGOY.js +25 -0
  4. package/dist/bundle/answer-policy-KH2IFXPN.js +96 -0
  5. package/dist/bundle/anthropic-VL54IUGF.js +70 -0
  6. package/dist/bundle/bun-ADJVI4HY.js +169 -0
  7. package/dist/bundle/bun-sqlite-2SDA3YOT.js +69 -0
  8. package/dist/bundle/chunk-2IKY7VBH.js +9 -0
  9. package/dist/bundle/chunk-2WOGZDZG.js +431 -0
  10. package/dist/bundle/chunk-4R7HYNZS.js +73 -0
  11. package/dist/bundle/chunk-4VCA7QU3.js +538 -0
  12. package/dist/bundle/chunk-4YLS4YLS.js +29 -0
  13. package/dist/bundle/chunk-5D4AEUVA.js +24783 -0
  14. package/dist/bundle/chunk-5F7IOESV.js +281 -0
  15. package/dist/bundle/chunk-5QESMCQK.js +122 -0
  16. package/dist/bundle/chunk-6M6FJV5D.js +138 -0
  17. package/dist/bundle/chunk-6MX5T6AQ.js +17 -0
  18. package/dist/bundle/chunk-6P3YHT54.js +385 -0
  19. package/dist/bundle/chunk-7A6PZUDR.js +938 -0
  20. package/dist/bundle/chunk-7GUG6UZS.js +884 -0
  21. package/dist/bundle/chunk-7JZJMHQY.js +487 -0
  22. package/dist/bundle/chunk-A4ETXPMZ.js +98 -0
  23. package/dist/bundle/chunk-ADLS6FVG.js +24600 -0
  24. package/dist/bundle/chunk-AE4BOXH7.js +5292 -0
  25. package/dist/bundle/chunk-AN3GVZTU.js +76 -0
  26. package/dist/bundle/chunk-BAYNCCNM.js +215 -0
  27. package/dist/bundle/chunk-BW2WPOXP.js +166 -0
  28. package/dist/bundle/chunk-BW52AJ4R.js +3387 -0
  29. package/dist/bundle/chunk-CB5UTASG.js +18 -0
  30. package/dist/bundle/chunk-CLMXBW53.js +1028 -0
  31. package/dist/bundle/chunk-DCTXOMOR.js +35 -0
  32. package/dist/bundle/chunk-DFDN6AUB.js +21 -0
  33. package/dist/bundle/chunk-EOQFWJJD.js +1095 -0
  34. package/dist/bundle/chunk-G4R4ZIGD.js +3569 -0
  35. package/dist/bundle/chunk-G4VZDINN.js +161 -0
  36. package/dist/bundle/chunk-GARCOIB6.js +409 -0
  37. package/dist/bundle/chunk-GKMGS7G5.js +1938 -0
  38. package/dist/bundle/chunk-HCNMFFG3.js +82 -0
  39. package/dist/bundle/chunk-HG5KRV55.js +1970 -0
  40. package/dist/bundle/chunk-HKYLSIZ2.js +82 -0
  41. package/dist/bundle/chunk-HTQTIKWP.js +928 -0
  42. package/dist/bundle/chunk-I4VQDXFR.js +100 -0
  43. package/dist/bundle/chunk-ICSKEDPI.js +36139 -0
  44. package/dist/bundle/chunk-IP4OK7RQ.js +24 -0
  45. package/dist/bundle/chunk-IVQ6342B.js +2 -0
  46. package/dist/bundle/chunk-K72SEMYI.js +160 -0
  47. package/dist/bundle/chunk-LHRCJYFC.js +19 -0
  48. package/dist/bundle/chunk-LPTIQLDW.js +192 -0
  49. package/dist/bundle/chunk-LQ3T2ZIX.js +124 -0
  50. package/dist/bundle/chunk-LSVI3A5X.js +836 -0
  51. package/dist/bundle/chunk-LW2G4U6W.js +570 -0
  52. package/dist/bundle/chunk-LXB6ONWC.js +3517 -0
  53. package/dist/bundle/chunk-LY26NW3I.js +6848 -0
  54. package/dist/bundle/chunk-MAEFLDHG.js +6092 -0
  55. package/dist/bundle/chunk-MZH4GDR4.js +45 -0
  56. package/dist/bundle/chunk-NN5B24KP.js +1109 -0
  57. package/dist/bundle/chunk-NO7CJEYV.js +22 -0
  58. package/dist/bundle/chunk-NTDWAAGL.js +18435 -0
  59. package/dist/bundle/chunk-NW3X3G5X.js +264 -0
  60. package/dist/bundle/chunk-O66V2WHK.js +48 -0
  61. package/dist/bundle/chunk-OCGPZHXW.js +25 -0
  62. package/dist/bundle/chunk-OIHDCGV4.js +151 -0
  63. package/dist/bundle/chunk-OVSWVPXL.js +8190 -0
  64. package/dist/bundle/chunk-PIN5RZ3D.js +63 -0
  65. package/dist/bundle/chunk-QLIB3PEC.js +1146 -0
  66. package/dist/bundle/chunk-QTR6D5HT.js +58 -0
  67. package/dist/bundle/chunk-QUJPQMHJ.js +2315 -0
  68. package/dist/bundle/chunk-R3HPOCZD.js +188 -0
  69. package/dist/bundle/chunk-RMV4C2YL.js +482 -0
  70. package/dist/bundle/chunk-RRRBMQ2E.js +844 -0
  71. package/dist/bundle/chunk-S4S7E54J.js +60 -0
  72. package/dist/bundle/chunk-SB6WOSHG.js +1109 -0
  73. package/dist/bundle/chunk-SE75DPBY.js +31 -0
  74. package/dist/bundle/chunk-SQJ7EH2D.js +97 -0
  75. package/dist/bundle/chunk-TKCHUT2H.js +422 -0
  76. package/dist/bundle/chunk-TLQUKHEM.js +193 -0
  77. package/dist/bundle/chunk-TZ2MKETI.js +100 -0
  78. package/dist/bundle/chunk-UC44ZMQV.js +78 -0
  79. package/dist/bundle/chunk-UI5UTMSZ.js +275 -0
  80. package/dist/bundle/chunk-VPPYYWOH.js +630 -0
  81. package/dist/bundle/chunk-WJHK5D7Z.js +35612 -0
  82. package/dist/bundle/chunk-WQ24UC44.js +239 -0
  83. package/dist/bundle/chunk-X5DFDGWS.js +2 -0
  84. package/dist/bundle/chunk-Y5E2WNWB.js +35 -0
  85. package/dist/bundle/chunk-YB4DMKYX.js +119 -0
  86. package/dist/bundle/chunk-Z4TZ6TAF.js +288 -0
  87. package/dist/bundle/chunk-ZVVMGPBJ.js +50 -0
  88. package/dist/bundle/cli-72EQATJF.js +825 -0
  89. package/dist/bundle/command-contract-4MHSZUN3.js +38 -0
  90. package/dist/bundle/config-GFIJK6G2.js +79 -0
  91. package/dist/bundle/dist-IBNHCQXT.js +136 -0
  92. package/dist/bundle/dist-XUFQCJXW.js +7577 -0
  93. package/dist/bundle/echarts-RFTK737T.js +42501 -0
  94. package/dist/bundle/embed-7QYA2ZZE.js +35 -0
  95. package/dist/bundle/embedder-YNN6PCHG.js +108 -0
  96. package/dist/bundle/first-run-EVSRQKZJ.js +23 -0
  97. package/dist/bundle/first-screen-RG4GUKW7.js +36 -0
  98. package/dist/bundle/folders-JEPOMYM4.js +13 -0
  99. package/dist/bundle/instructions-FHNL7CMW.js +9 -0
  100. package/dist/bundle/main-NYGJXPH7.js +130 -0
  101. package/dist/bundle/mcp-IXFC2VVR.js +165 -0
  102. package/dist/bundle/mcp-VGSZDCKK.js +189 -0
  103. package/dist/bundle/mcp-XKP2PXLS.js +92 -0
  104. package/dist/bundle/meetings-IBPI4MM4.js +215 -0
  105. package/dist/bundle/node-P4E63KXA.js +2340 -0
  106. package/dist/bundle/node-TLZSIHIJ.js +21 -0
  107. package/dist/bundle/node-ZMCACJVS.js +176 -0
  108. package/dist/bundle/node-sqlite-ZNGOBA5Q.js +45 -0
  109. package/dist/bundle/oauth-Q6LKF7DB.js +17 -0
  110. package/dist/bundle/open-LJ332Y5O.js +19 -0
  111. package/dist/bundle/output-file-RYQZ3RTE.js +63 -0
  112. package/dist/bundle/process-ZPTLNVQS.js +91 -0
  113. package/dist/bundle/program-IBRQBQ6W.js +5845 -0
  114. package/dist/bundle/prompt-RT7GUUXH.js +12 -0
  115. package/dist/bundle/recognize-QXGE7YJH.js +190 -0
  116. package/dist/bundle/remote-FD4MZQV3.js +26 -0
  117. package/dist/bundle/rerank-V6AVV755.js +49 -0
  118. package/dist/bundle/run-log-RE2EI3UU.js +111 -0
  119. package/dist/bundle/serve-HIJTFAW7.js +19 -0
  120. package/dist/bundle/server-3QOXOYYL.js +53 -0
  121. package/dist/bundle/server-WLJCU7KK.js +812 -0
  122. package/dist/bundle/services-KC5KQFBS.js +330 -0
  123. package/dist/bundle/speech-5JOXLYDA.js +44 -0
  124. package/dist/bundle/state-PPGRB3T6.js +33 -0
  125. package/dist/bundle/store-LODVDPK3.js +141 -0
  126. package/dist/bundle/store-WB5BICTG.js +124 -0
  127. package/dist/bundle/store-connection-EG6Z5ITP.js +76 -0
  128. package/dist/bundle/store-maintenance-command-Q5WMFUZ2.js +54 -0
  129. package/dist/bundle/streaming-UGFFNOXL.js +15 -0
  130. package/dist/bundle/tokens-AF5CPY2F.js +17 -0
  131. package/dist/bundle/zm.js +8 -0
  132. package/dist/commands.js +2 -2
  133. package/dist/commands.js.map +1 -1
  134. package/dist/config-issues.d.ts.map +1 -1
  135. package/dist/config-issues.js +3 -0
  136. package/dist/config-issues.js.map +1 -1
  137. package/dist/config.d.ts +3 -0
  138. package/dist/config.d.ts.map +1 -1
  139. package/dist/config.js +23 -0
  140. package/dist/config.js.map +1 -1
  141. package/dist/contract-overrides.d.ts.map +1 -1
  142. package/dist/contract-overrides.js +34 -45
  143. package/dist/contract-overrides.js.map +1 -1
  144. package/dist/first-screen.js +1 -1
  145. package/dist/first-screen.js.map +1 -1
  146. package/dist/mcp-command.d.ts +5 -3
  147. package/dist/mcp-command.d.ts.map +1 -1
  148. package/dist/mcp-command.js +73 -15
  149. package/dist/mcp-command.js.map +1 -1
  150. package/dist/program-bindings.d.ts.map +1 -1
  151. package/dist/program-bindings.js +1 -0
  152. package/dist/program-bindings.js.map +1 -1
  153. package/dist/recording-archive.d.ts.map +1 -1
  154. package/dist/recording-archive.js +9 -4
  155. package/dist/recording-archive.js.map +1 -1
  156. package/dist/remote-http.d.ts +2 -0
  157. package/dist/remote-http.d.ts.map +1 -1
  158. package/dist/remote-http.js +21 -11
  159. package/dist/remote-http.js.map +1 -1
  160. package/dist/request-events.d.ts +12 -0
  161. package/dist/request-events.d.ts.map +1 -1
  162. package/dist/request-events.js +56 -4
  163. package/dist/request-events.js.map +1 -1
  164. package/dist/run.d.ts.map +1 -1
  165. package/dist/run.js +4 -1
  166. package/dist/run.js.map +1 -1
  167. package/dist/version.d.ts +1 -1
  168. package/dist/version.js +1 -1
  169. package/package.json +7 -5
  170. package/skills/zoom-cli/SKILL.md +3 -1
@@ -0,0 +1,3569 @@
1
+ import { createRequire as __bundleRequire } from "node:module";
2
+ const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ recordLogFor,
5
+ storeTable
6
+ } from "./chunk-MAEFLDHG.js";
7
+ import {
8
+ envName
9
+ } from "./chunk-OCGPZHXW.js";
10
+ import {
11
+ carries
12
+ } from "./chunk-PIN5RZ3D.js";
13
+ import {
14
+ WEIGHTS,
15
+ agenda,
16
+ attachment,
17
+ childTrace,
18
+ closeSuggestion,
19
+ conversation,
20
+ tagging,
21
+ task
22
+ } from "./chunk-EOQFWJJD.js";
23
+ import {
24
+ author,
25
+ count,
26
+ id,
27
+ note,
28
+ organization,
29
+ project,
30
+ providerMetadata,
31
+ reminder,
32
+ text,
33
+ time,
34
+ untrusted
35
+ } from "./chunk-YB4DMKYX.js";
36
+ import {
37
+ FACT_STATUSES,
38
+ FACT_TYPES,
39
+ LINK_KINDS,
40
+ LINK_SOURCES,
41
+ MEMORY_KINDS,
42
+ MEMORY_SCOPES,
43
+ MEMORY_STATUSES,
44
+ RELATION_KINDS,
45
+ TASK_KINDS,
46
+ TASK_ORIGINS,
47
+ TASK_STATES,
48
+ TASK_TYPES,
49
+ TASK_VERDICTS,
50
+ WORK_TASK_TYPES
51
+ } from "./chunk-6M6FJV5D.js";
52
+ import {
53
+ MEETING_RESULT_ENTITIES,
54
+ event,
55
+ meeting,
56
+ meetingDetails,
57
+ meetingHit,
58
+ meetingLink,
59
+ meetingParticipants,
60
+ meetingPassage,
61
+ meetingProjectEvidence,
62
+ meetingReview,
63
+ meetingSpeaker,
64
+ meetingStats,
65
+ meetingSummary,
66
+ meetingTranscript
67
+ } from "./chunk-LXB6ONWC.js";
68
+ import {
69
+ CliError,
70
+ array,
71
+ boolean,
72
+ integer,
73
+ isoDate,
74
+ isoTime,
75
+ jsonSchemaOf,
76
+ literal,
77
+ maxLength,
78
+ minLength,
79
+ minValue,
80
+ null_,
81
+ nullable,
82
+ number,
83
+ objectWithRest,
84
+ omit,
85
+ optional,
86
+ pageSchema,
87
+ partial,
88
+ pick,
89
+ picklist,
90
+ pipe,
91
+ record,
92
+ reference,
93
+ regex,
94
+ resolvePaths,
95
+ safeInteger,
96
+ strictObject,
97
+ string,
98
+ union,
99
+ unknown,
100
+ unwrap,
101
+ variant,
102
+ writeSecurely
103
+ } from "./chunk-AE4BOXH7.js";
104
+ import {
105
+ __name
106
+ } from "./chunk-ZVVMGPBJ.js";
107
+
108
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/member.js
109
+ var member = strictObject({
110
+ id,
111
+ name: nullable(text),
112
+ username: nullable(text),
113
+ role: optional(picklist(["owner", "admin", "member"])),
114
+ /** `null` when their privacy hides it. */
115
+ last_seen_at: optional(nullable(time)),
116
+ registered_at: optional(nullable(time)),
117
+ joined_at: optional(nullable(time)),
118
+ /** Who added them or whose invite they used. */
119
+ invited_by: optional(nullable(id)),
120
+ is_bot: optional(boolean()),
121
+ deleted: optional(boolean()),
122
+ flagged: optional(picklist(["scam", "fake"])),
123
+ has_photo: optional(boolean()),
124
+ /** `chats members check`: how much they look like a bot — a hint, never a verdict. */
125
+ score: optional(count),
126
+ reasons: optional(array(text)),
127
+ /** `chats members check --deep`: the whole person check, as `contacts check` answers it. */
128
+ check: optional(record(string(), unknown()))
129
+ });
130
+
131
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat.js
132
+ var setting = optional(nullable(boolean()));
133
+ var chat = strictObject({
134
+ ref: reference,
135
+ id,
136
+ provider: optional(text),
137
+ account: optional(text),
138
+ title: nullable(text),
139
+ kind: picklist(["dialog", "group", "channel", "saved", "unknown"]),
140
+ unread_count: nullable(count),
141
+ unread_mentions: optional(count),
142
+ last_message_at: nullable(time),
143
+ participants_count: nullable(count),
144
+ muted: optional(boolean()),
145
+ /** When the mute ends; absent with `muted` true is for good. */
146
+ muted_until: optional(time),
147
+ archived: optional(boolean()),
148
+ /** The owner marked it unread, whatever `unread_count` says. */
149
+ marked_unread: optional(boolean()),
150
+ membership_state: optional(picklist(["joined", "left", "public", "imported", "archived", "external"])),
151
+ parent_chat_id: optional(id),
152
+ scope: optional(picklist(["personal", "work"])),
153
+ provider_metadata: providerMetadata,
154
+ /** `chats show`, a group or channel: what it says about itself. */
155
+ description: optional(nullable(text)),
156
+ invite_link: optional(nullable(text)),
157
+ settings: optional(strictObject({
158
+ all_can_pin: setting,
159
+ only_admins_add: setting,
160
+ only_admins_call: setting,
161
+ only_owner_edits_info: setting,
162
+ members_see_link: setting,
163
+ join_approval: setting,
164
+ only_admins_send: setting,
165
+ only_admins_edit_info: setting,
166
+ disappearing_seconds: optional(nullable(count))
167
+ })),
168
+ /** `chats show`: absent when no roster is known; an empty list is a known empty roster. */
169
+ members: optional(array(member))
170
+ });
171
+
172
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/list-results.js
173
+ var botProfile = strictObject({
174
+ name: text,
175
+ token: text,
176
+ bot: optional(text),
177
+ id: optional(id),
178
+ problem: optional(text)
179
+ });
180
+ var botSeenChat = strictObject({
181
+ ...partial(omit(chat, ["ref", "provider", "account", "description", "invite_link", "settings", "members"])).entries,
182
+ id,
183
+ parent_chat_id: optional(nullable(id)),
184
+ muted_until: optional(nullable(time)),
185
+ first_seen_at: optional(time),
186
+ last_seen_at: optional(time)
187
+ });
188
+ var botAdmin = strictObject({
189
+ id,
190
+ name: nullable(text),
191
+ username: nullable(text),
192
+ role: picklist(["owner", "admin"]),
193
+ rights: array(picklist(["read", "members", "admins", "info", "pin", "link", "post", "edit", "delete"])),
194
+ title: nullable(text)
195
+ });
196
+ var botMenuEntry = strictObject({ name: text, description: nullable(text) });
197
+ var botWebhook = strictObject({ url: text, types: optional(array(text)) });
198
+ var scheduledJob = strictObject({
199
+ name: text,
200
+ kind: picklist(["command", "agent"]),
201
+ when: text,
202
+ last: nullable(strictObject({
203
+ at: time,
204
+ exit_code: number(),
205
+ output: text,
206
+ trace_id: optional(text),
207
+ reason: optional(text),
208
+ error_code: optional(text),
209
+ failing_since: optional(time),
210
+ failures: optional(number())
211
+ }))
212
+ });
213
+ var botTemplate = strictObject({
214
+ name: nullable(text),
215
+ status: nullable(text),
216
+ language: nullable(text),
217
+ category: nullable(text)
218
+ });
219
+ var callRecord = strictObject({
220
+ id,
221
+ chat_id: nullable(id),
222
+ caller_id: nullable(id),
223
+ direction: picklist(["incoming", "outgoing"]),
224
+ outcome: picklist(["answered", "missed", "declined"]),
225
+ kind: picklist(["audio", "video"]),
226
+ at: time,
227
+ duration_seconds: nullable(number())
228
+ });
229
+ var stickerInventory = strictObject({
230
+ id,
231
+ title: optional(text),
232
+ count: optional(number()),
233
+ link: optional(nullable(text)),
234
+ set_id: optional(nullable(id)),
235
+ emoji: optional(array(text)),
236
+ url: optional(nullable(text))
237
+ });
238
+
239
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/batch-result.js
240
+ var actionableError = objectWithRest({
241
+ code: text,
242
+ message: text,
243
+ retryable: boolean(),
244
+ retry_after_ms: optional(number())
245
+ }, unknown());
246
+ var batchResult = strictObject({
247
+ attempted: count,
248
+ succeeded: count,
249
+ failed: count,
250
+ error_rate: number(),
251
+ failures: array(strictObject({ id, stage: text, error: actionableError, attachment: optional(count) })),
252
+ stop_reason: optional(picklist(["rate_limited", "authentication", "error_rate", "cancelled"])),
253
+ max_error_percent: count
254
+ });
255
+
256
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/conversation-preparation.js
257
+ var conversationBuild = strictObject({
258
+ chat: id,
259
+ messages: count,
260
+ links: count,
261
+ conversations: count,
262
+ built_at: time,
263
+ rules_version: count
264
+ });
265
+ var chatEmbedding = strictObject({ chat: id, model: text, embedded: count, skipped: count });
266
+ var conversationPreparation = strictObject({
267
+ model: text,
268
+ model_available: boolean(),
269
+ built: array(conversationBuild),
270
+ embedded: array(chatEmbedding),
271
+ left: array(strictObject({ chat: id, needs: picklist(["build", "embed"]) })),
272
+ /** Messages given their own vector, which `search messages --discover` reads, and how many still lack one. */
273
+ messages: optional(strictObject({ embedded: count, left: count }))
274
+ });
275
+ var catchUpPreparation = strictObject({
276
+ complete: boolean(),
277
+ reason: optional(picklist(["message_bound", "time_or_abort_bound", "preparation_failed", "pending"])),
278
+ prepared: optional(conversationPreparation)
279
+ });
280
+
281
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/services/backfill-jobs.js
282
+ import { spawn } from "node:child_process";
283
+ import { randomBytes } from "node:crypto";
284
+ import { closeSync, existsSync as existsSync2, mkdirSync, openSync, readdirSync, readFileSync as readFileSync2, realpathSync, rmSync as rmSync2 } from "node:fs";
285
+ import { dirname, join as join2 } from "node:path";
286
+
287
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/background/checkpoints.js
288
+ import { existsSync, readFileSync, rmSync } from "node:fs";
289
+ import { join } from "node:path";
290
+ var PART = /^[\w@+-][\w.@+-]{0,99}$/;
291
+ var checkpointPath = /* @__PURE__ */ __name((state, profile, job2) => {
292
+ for (const part of [profile, job2]) {
293
+ if (!PART.test(part) || part.includes("..")) {
294
+ throw new CliError("validation_error", `a checkpoint is named by letters, digits, ".", "@" and "-" \u2014 not "${part}"`);
295
+ }
296
+ }
297
+ return join(state, "checkpoints", profile, `${job2}.json`);
298
+ }, "checkpointPath");
299
+ var readCheckpoint = /* @__PURE__ */ __name((path) => {
300
+ try {
301
+ return existsSync(path) ? JSON.parse(readFileSync(path, "utf8")) : void 0;
302
+ } catch {
303
+ return void 0;
304
+ }
305
+ }, "readCheckpoint");
306
+ var saveCheckpoint = /* @__PURE__ */ __name((path, point, now = /* @__PURE__ */ new Date()) => {
307
+ const saved = { ...point, updated_at: now.toISOString() };
308
+ writeSecurely(path, `${JSON.stringify(saved, null, 2)}
309
+ `, 384);
310
+ return saved;
311
+ }, "saveCheckpoint");
312
+ var progressOf = /* @__PURE__ */ __name((input) => {
313
+ const total = input.total ?? null;
314
+ const updated = input.updatedAt ?? null;
315
+ return {
316
+ job: input.job,
317
+ profile: input.profile,
318
+ done: input.done,
319
+ total,
320
+ remaining: total === null ? null : Math.max(0, total - input.done),
321
+ state: input.complete ?? (total !== null && input.done >= total) ? "complete" : "partial",
322
+ updated_at: updated,
323
+ cursor_age_ms: updated === null ? null : Math.max(0, (input.now ?? /* @__PURE__ */ new Date()).getTime() - Date.parse(updated))
324
+ };
325
+ }, "progressOf");
326
+
327
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/services/backfill-jobs.js
328
+ var JOB_STATES = ["running", "done", "partial", "failed", "cancelled", "died"];
329
+ var spawnDetached = /* @__PURE__ */ __name((argv, env, log) => {
330
+ const out = openSync(log, "a", 384);
331
+ try {
332
+ const child = spawn(process.execPath, [realpathSync(process.argv[1] ?? ""), ...argv], {
333
+ detached: true,
334
+ stdio: ["ignore", out, out],
335
+ env
336
+ });
337
+ child.unref();
338
+ return child.pid ?? 0;
339
+ } finally {
340
+ closeSync(out);
341
+ }
342
+ }, "spawnDetached");
343
+ var jobsDir = /* @__PURE__ */ __name((app, env) => join2(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "backfill"), "jobsDir");
344
+ var jobPath = /* @__PURE__ */ __name((dir, id6) => join2(dir, `${id6}.json`), "jobPath");
345
+ var saveJob = /* @__PURE__ */ __name((dir, job2) => {
346
+ mkdirSync(dir, { recursive: true, mode: 448 });
347
+ writeSecurely(jobPath(dir, job2.id), `${JSON.stringify(job2, null, 2)}
348
+ `, 384);
349
+ }, "saveJob");
350
+ var readJob = /* @__PURE__ */ __name((dir, id6) => {
351
+ if (!/^[\w-]+$/.test(id6) || !existsSync2(jobPath(dir, id6)))
352
+ return void 0;
353
+ try {
354
+ return JSON.parse(readFileSync2(jobPath(dir, id6), "utf8"));
355
+ } catch {
356
+ return void 0;
357
+ }
358
+ }, "readJob");
359
+ var recordsPath = /* @__PURE__ */ __name((dir, id6) => join2(dir, `${id6}.jsonl`), "recordsPath");
360
+ var tracedJob = /* @__PURE__ */ __name((env) => {
361
+ const trace = childTrace();
362
+ return { env: { ...env, TRACEPARENT: trace.traceparent }, traceId: trace.traceId };
363
+ }, "tracedJob");
364
+ var jobStarted = /* @__PURE__ */ __name((app, dir, job2) => {
365
+ saveJob(dir, job2);
366
+ recordLogFor(recordsPath(dir, job2.id), app, job2.traceId ? { traceId: job2.traceId } : {}).info({
367
+ event: "job.start",
368
+ job: job2.id,
369
+ pid: job2.pid
370
+ });
371
+ }, "jobStarted");
372
+ var finishJob = /* @__PURE__ */ __name((app, dir, id6, change) => {
373
+ updateJob(dir, id6, change);
374
+ const job2 = readJob(dir, id6);
375
+ if (!job2)
376
+ return;
377
+ const outcome2 = stateOf(job2);
378
+ recordLogFor(recordsPath(dir, id6), app, job2.traceId ? { traceId: job2.traceId } : {})[job2.error ? "error" : "info"]({
379
+ event: "job.exit",
380
+ job: id6,
381
+ outcome: outcome2,
382
+ ...job2.error ? { errorCode: job2.error.code } : {}
383
+ });
384
+ }, "finishJob");
385
+ var updateJob = /* @__PURE__ */ __name((dir, id6, change) => {
386
+ const job2 = readJob(dir, id6);
387
+ if (job2)
388
+ saveJob(dir, { ...job2, ...change });
389
+ }, "updateJob");
390
+ var removeJob = /* @__PURE__ */ __name((dir, job2) => {
391
+ rmSync2(jobPath(dir, job2.id), { force: true });
392
+ rmSync2(recordsPath(dir, job2.id), { force: true });
393
+ if (dirname(job2.log) === dir)
394
+ rmSync2(job2.log, { force: true });
395
+ }, "removeJob");
396
+ var listJobs = /* @__PURE__ */ __name((dir) => existsSync2(dir) ? readdirSync(dir).filter((name) => name.endsWith(".json")).flatMap((name) => readJob(dir, name.slice(0, -".json".length)) ?? []).sort((a, b) => b.startedAt.localeCompare(a.startedAt)) : [], "listJobs");
397
+ var jobDetails = /* @__PURE__ */ __name((job2) => ({
398
+ job: job2.id,
399
+ profile: job2.profile,
400
+ chat: job2.chat,
401
+ state: stateOf(job2),
402
+ pid: job2.pid,
403
+ startedAt: job2.startedAt,
404
+ ...job2.finishedAt ? { finishedAt: job2.finishedAt } : {},
405
+ fetched: Number(job2.result?.fetched ?? job2.progress?.fetched ?? 0),
406
+ ...job2.limit === void 0 ? {} : { messageLimit: job2.limit },
407
+ ...job2.pageSize === void 0 ? {} : { pageSize: job2.pageSize },
408
+ ...job2.last === void 0 ? {} : { last: job2.last },
409
+ ...job2.result ? {
410
+ complete: job2.result.complete === true,
411
+ ...job2.result.issue ? { issue: job2.result.issue } : {},
412
+ ...job2.result.batch ? { batch: job2.result.batch } : {},
413
+ ...job2.result.resume ? { resume: job2.result.resume } : {}
414
+ } : {},
415
+ ...job2.error ? { error: job2.error } : {},
416
+ progress: progressOf({
417
+ job: job2.id,
418
+ profile: job2.profile,
419
+ done: Number(job2.result?.fetched ?? job2.progress?.fetched ?? 0),
420
+ ...job2.limit === void 0 ? {} : { total: job2.limit },
421
+ complete: job2.result?.complete === true,
422
+ ...job2.progress?.at ?? job2.finishedAt ? { updatedAt: job2.progress?.at ?? job2.finishedAt } : {}
423
+ })
424
+ }), "jobDetails");
425
+ var jobItem = /* @__PURE__ */ __name((job2) => {
426
+ const issue = job2.result?.issue;
427
+ return {
428
+ id: job2.id,
429
+ chat: job2.chat,
430
+ state: stateOf(job2),
431
+ pid: job2.pid,
432
+ started_at: job2.startedAt,
433
+ ...job2.finishedAt ? { finished_at: job2.finishedAt } : {},
434
+ fetched: Number(job2.result?.fetched ?? job2.progress?.fetched ?? 0),
435
+ ...job2.limit === void 0 ? {} : { message_limit: job2.limit },
436
+ ...job2.pageSize === void 0 ? {} : { page_size: job2.pageSize },
437
+ ...job2.last === void 0 ? {} : { last: job2.last },
438
+ ...job2.result ? { complete: job2.result.complete === true } : {},
439
+ ...issue ? { issue: { code: String(issue.code), message: String(issue.message) } } : {},
440
+ ...job2.error ? { error: { code: job2.error.code, message: job2.error.message } } : {}
441
+ };
442
+ }, "jobItem");
443
+ var stateOf = /* @__PURE__ */ __name((job2) => {
444
+ if (job2.finishedAt !== void 0) {
445
+ if (job2.cancelRequestedAt)
446
+ return "cancelled";
447
+ return job2.error ? "failed" : job2.result?.batch || job2.result?.issue ? "partial" : "done";
448
+ }
449
+ if (isJob(job2))
450
+ return "running";
451
+ return job2.cancelRequestedAt ? "cancelled" : "died";
452
+ }, "stateOf");
453
+ var isJob = /* @__PURE__ */ __name((job2) => carries(job2.pid, `_BACKFILL_JOB=${job2.id}`), "isJob");
454
+ var startArchiveJob = /* @__PURE__ */ __name((app, env, profile, input, spawnJob = spawnDetached) => {
455
+ const dir = jobsDir(app, env);
456
+ const running = listJobs(dir).find((job3) => job3.profile === profile && job3.chat === input.chat && stateOf(job3) === "running");
457
+ if (running)
458
+ throw new CliError("validation_error", `job ${running.id} already works on this chat; inspect store jobs show first`);
459
+ const startedAt = (/* @__PURE__ */ new Date()).toISOString();
460
+ const id6 = `${startedAt.replace(/[-:]/g, "").slice(0, 15)}-${randomBytes(3).toString("hex")}`;
461
+ mkdirSync(dir, { recursive: true, mode: 448 });
462
+ const log = join2(dir, `${id6}.log`);
463
+ const job2 = {
464
+ id: id6,
465
+ chat: input.chat,
466
+ profile,
467
+ pid: 0,
468
+ startedAt,
469
+ limit: input.limit,
470
+ pageSize: input.pageSize,
471
+ argv: input.argv,
472
+ log
473
+ };
474
+ saveJob(dir, job2);
475
+ const { [envName(app, "TIMEOUT")]: _timeout, ...inherited } = env;
476
+ const traced = tracedJob({ ...inherited, [envName(app, "PROFILE")]: profile, [envName(app, "BACKFILL_JOB")]: id6 });
477
+ const pid = spawnJob(input.argv, traced.env, log);
478
+ jobStarted(app, dir, { ...job2, pid, traceId: traced.traceId });
479
+ return { job: id6, pid, chat: input.chat, log };
480
+ }, "startArchiveJob");
481
+
482
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/job.js
483
+ var problem = strictObject({ code: text, message: text });
484
+ var job = strictObject({
485
+ id,
486
+ /** The chat as the sync was given it. */
487
+ chat: text,
488
+ state: picklist(JOB_STATES),
489
+ pid: count,
490
+ started_at: time,
491
+ finished_at: optional(time),
492
+ /** Messages fetched so far, or in all once it finished. */
493
+ fetched: count,
494
+ /** The `--limit` the sync was started with: how many messages it may fetch. */
495
+ message_limit: optional(count),
496
+ page_size: optional(count),
497
+ last: optional(count),
498
+ /** Whether the sync reached its window; set once it finished. */
499
+ complete: optional(boolean()),
500
+ /** Why a partial job stopped short; `store jobs retry` resumes it. */
501
+ issue: optional(problem),
502
+ error: optional(problem)
503
+ });
504
+
505
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message.js
506
+ var quoted = strictObject({
507
+ id,
508
+ sender_id: nullable(id),
509
+ sender_name: nullable(text),
510
+ timestamp: nullable(time),
511
+ text,
512
+ attachments: array(attachment),
513
+ outgoing: nullable(boolean())
514
+ });
515
+ var mailPerson = strictObject({ name: nullable(text), address: text, ref: nullable(reference) });
516
+ var message = strictObject({
517
+ /** The message's locator. */
518
+ ref: reference,
519
+ id,
520
+ provider: optional(text),
521
+ account: optional(text),
522
+ chat_id: id,
523
+ chat_title: optional(nullable(text)),
524
+ sender_id: nullable(id),
525
+ sender_name: nullable(text),
526
+ sender_username: optional(text),
527
+ sender_is_chat: optional(boolean()),
528
+ mentions: optional(array(id)),
529
+ /** When it was sent. */
530
+ timestamp: time,
531
+ edited_at: nullable(time),
532
+ text,
533
+ /** What a voice message says, once heard. */
534
+ transcript: optional(text),
535
+ /** In a window of messages around one, the one asked for. */
536
+ anchor: optional(boolean()),
537
+ /** A stretch of the text, transcript, file name or file text around what a search matched. */
538
+ excerpt: optional(text),
539
+ /** `picture`: the picture search lane found it by what the picture shows; it follows the text hits. */
540
+ matched_in: optional(picklist(["text", "transcript", "filename", "file", "context", "picture"])),
541
+ score: optional(number()),
542
+ /**
543
+ * `corrected`: a query word matched only a spelling speech recognition garbled in a voice note's transcript,
544
+ * listed in `corrections`. `words` and `beginnings`: what a discovery search matched.
545
+ */
546
+ match: optional(picklist(["words", "beginnings", "corrected"])),
547
+ corrections: optional(array(strictObject({ from: text, to: array(text) }))),
548
+ /** Where a search found it: the local archive, the messenger's server, or both. */
549
+ found_in: optional(picklist(["archive", "server", "both"])),
550
+ /** A discovery search's partial match: how much of the question it covers, and which words it lacks. */
551
+ discovery: optional(strictObject({
552
+ coverage: number(),
553
+ matched_terms: array(text),
554
+ missing_terms: array(text),
555
+ parent: optional(reference),
556
+ /** Present when meaning was searched too: which of the two lists found it. */
557
+ found_by: optional(array(picklist(["words", "meaning"]))),
558
+ /** Present when the reranker read it: its own score, higher is better. It ordered the first hits with `score`. */
559
+ reranker_score: optional(number())
560
+ })),
561
+ /** The messages around a search hit, or its thread, oldest first; the hit itself is among them. */
562
+ context: optional(array(strictObject({ ref: reference, timestamp: time, sender_name: nullable(text), text }))),
563
+ outgoing: nullable(boolean()),
564
+ attachments: array(attachment),
565
+ reply_to: nullable(quoted),
566
+ /** The id a reply answers, also when the provider sent no copy of that message. */
567
+ reply_to_id: optional(id),
568
+ forwarded_from: nullable(quoted),
569
+ thread_id: optional(id),
570
+ thread_root_id: optional(id),
571
+ reactions: optional(nullable(strictObject({
572
+ counts: array(strictObject({ reaction: text, count })),
573
+ mine: nullable(text),
574
+ total: count
575
+ }))),
576
+ scheduled_for: optional(time),
577
+ /** The owner starred it; only where the messenger has stars, and only when set. */
578
+ starred: optional(literal(true)),
579
+ /** The owner's own message in a one-to-one chat: `delivered`, or `read` once opened; absent when no receipt came. */
580
+ delivery: optional(picklist(["delivered", "read"])),
581
+ email: optional(strictObject({
582
+ subject: nullable(text),
583
+ from: nullable(mailPerson),
584
+ to: array(mailPerson),
585
+ cc: array(mailPerson),
586
+ bcc: array(mailPerson),
587
+ /** The mail header Reply-To; `reply_to` is the quoted message a chat reply answers. */
588
+ reply_addresses: array(mailPerson),
589
+ labels: array(text),
590
+ /** The thread as a `chat:` reference. */
591
+ thread: reference,
592
+ read: nullable(boolean()),
593
+ flagged: nullable(boolean()),
594
+ /** How much the sender's mail looks like spam, a scam or a robot (memo's score), and why; absent when unscored. */
595
+ sender_score: optional(strictObject({ score: number(), signals: array(text), demoted: optional(literal(true)) }))
596
+ })),
597
+ provider_metadata: providerMetadata
598
+ });
599
+
600
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/extraction-report.js
601
+ var extractionItem = strictObject({
602
+ ref: reference,
603
+ attachment: count,
604
+ kind: text,
605
+ name: nullable(text),
606
+ status: picklist(["extracted", "needs-agent", "unreadable", "engine-missing", "too-large", "missing"]),
607
+ extractor: optional(text),
608
+ chars: optional(count),
609
+ local_path: optional(text),
610
+ pages: optional(count),
611
+ ocr_pages: optional(count),
612
+ error: optional(text),
613
+ issue: optional(actionableError)
614
+ });
615
+ var extractionSummary = strictObject({
616
+ extracted: count,
617
+ failed: count,
618
+ needs_agent: count,
619
+ complete: boolean(),
620
+ batch: optional(batchResult)
621
+ });
622
+ var extractionReport = strictObject({
623
+ ...extractionSummary.entries,
624
+ items: array(extractionItem),
625
+ unchanged: count,
626
+ not_downloaded: count,
627
+ unsupported: count,
628
+ /** Reader package names, such as unpdf or @napi-rs/canvas. */
629
+ engines_missing: array(text),
630
+ cursor: optional(text)
631
+ });
632
+
633
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-transfer.js
634
+ var savedMessageFile = strictObject({
635
+ kind: text,
636
+ path: text,
637
+ bytes: count,
638
+ existing: optional(literal(true))
639
+ });
640
+ var files = array(savedMessageFile);
641
+ var messageDownload = union([
642
+ strictObject({
643
+ files,
644
+ extraction: optional(extractionReport),
645
+ complete: optional(literal(false)),
646
+ batch: optional(batchResult)
647
+ }),
648
+ strictObject({
649
+ files,
650
+ chat: nullable(id),
651
+ saved: count,
652
+ existing: count,
653
+ complete: boolean(),
654
+ batch: optional(batchResult),
655
+ stopped: optional(literal(true)),
656
+ extraction: optional(extractionSummary)
657
+ })
658
+ ]);
659
+ var historyRange = strictObject({ from: number(), to: number() });
660
+ var messageSyncEstimate = strictObject({
661
+ chat: id,
662
+ held: count,
663
+ ranges: array(historyRange),
664
+ missing: nullable(count),
665
+ requests: nullable(count),
666
+ runs: nullable(count),
667
+ seconds: nullable(count)
668
+ });
669
+ var tasks = optional(strictObject({
670
+ added: count,
671
+ closed: count,
672
+ review: count,
673
+ held: optional(count),
674
+ held_chats: optional(count)
675
+ }));
676
+ var messageSyncChat = strictObject({
677
+ issue: optional(actionableError),
678
+ resume: optional(strictObject({ before: optional(text) })),
679
+ prepared: optional(catchUpPreparation),
680
+ window_complete: optional(boolean()),
681
+ requests: optional(count),
682
+ chat: nullable(id),
683
+ fetched: count,
684
+ complete: boolean(),
685
+ ranges: array(historyRange),
686
+ reached_since: optional(literal(true)),
687
+ reached_last: optional(literal(true)),
688
+ stopped: optional(literal(true)),
689
+ tasks
690
+ });
691
+ var messageSyncAll = strictObject({
692
+ batch: optional(batchResult),
693
+ chats: count,
694
+ fetched: count,
695
+ complete: boolean(),
696
+ stopped: optional(literal(true)),
697
+ items: array(strictObject({
698
+ chat: id,
699
+ title: nullable(text),
700
+ fetched: count,
701
+ complete: boolean(),
702
+ current: optional(literal(true)),
703
+ stopped: optional(literal(true)),
704
+ error: optional(text),
705
+ issue: optional(actionableError)
706
+ })),
707
+ tasks
708
+ });
709
+ var messageSyncStarted = strictObject({ job: id, pid: count, chat: text, log: text });
710
+ var messageSync = union([messageSyncEstimate, messageSyncChat, messageSyncAll, messageSyncStarted]);
711
+
712
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/store-records.js
713
+ var range = strictObject({ from: number(), to: number() });
714
+ var storeChatStatus = strictObject({
715
+ chat_id: id,
716
+ title: nullable(text),
717
+ kind: chat.entries.kind,
718
+ messages: count,
719
+ oldest_at: nullable(time),
720
+ newest_at: nullable(time),
721
+ last_stored_at: nullable(time),
722
+ held: array(range)
723
+ });
724
+ var storeClear = strictObject({
725
+ cleared: boolean(),
726
+ dry_run: optional(literal(true)),
727
+ chats: count,
728
+ messages: count,
729
+ left: array(strictObject({ id, title: nullable(text), messages: count }))
730
+ });
731
+ var storeExport = union([
732
+ message,
733
+ strictObject({
734
+ path: text,
735
+ format: picklist(["jsonl", "markdown"]),
736
+ count,
737
+ encrypted: optional(literal(true))
738
+ }),
739
+ strictObject({
740
+ path: text,
741
+ encrypted: optional(literal(true)),
742
+ chats: array(strictObject({ id, title: nullable(text), file: nullable(text), messages: count, deleted: count }))
743
+ })
744
+ ]);
745
+ var storeGapPlan = strictObject({
746
+ version: literal(1),
747
+ scope: literal("interior"),
748
+ account: strictObject({ provider: text, account: id }),
749
+ chat: id,
750
+ ordering: picklist(["id", "time"]),
751
+ held: array(range),
752
+ gaps: array(range),
753
+ unknown: strictObject({ older: boolean(), newer: literal(true) }),
754
+ fingerprint: text,
755
+ limits: strictObject({ max_gaps: count, limit: count, time_ms: count, page_size: count })
756
+ });
757
+ var storeGapRepair = union([
758
+ messageSyncStarted,
759
+ strictObject({
760
+ version: literal(1),
761
+ scope: literal("interior"),
762
+ chat: id,
763
+ before: storeGapPlan,
764
+ after: storeGapPlan,
765
+ repaired: array(range),
766
+ fetched: count,
767
+ requests: count,
768
+ complete: boolean(),
769
+ prepared: optional(catchUpPreparation),
770
+ stopped: optional(picklist(["bound", "partial_or_inaccessible", "fetch_failed"]))
771
+ })
772
+ ]);
773
+ var problem2 = objectWithRest({ code: text, message: text, retryable: optional(boolean()), retry_after_ms: optional(number()) }, unknown());
774
+ var progress = strictObject({
775
+ job: id,
776
+ profile: text,
777
+ done: count,
778
+ total: nullable(count),
779
+ remaining: nullable(count),
780
+ state: picklist(["partial", "complete"]),
781
+ updated_at: nullable(time),
782
+ cursor_age_ms: nullable(count)
783
+ });
784
+ var storeJobDetails = strictObject({
785
+ ...omit(job, ["id", "issue", "error"]).entries,
786
+ job: id,
787
+ profile: text,
788
+ issue: optional(problem2),
789
+ error: optional(problem2),
790
+ batch: optional(batchResult),
791
+ resume: optional(strictObject({ before: optional(text) })),
792
+ progress,
793
+ held: optional(array(range)),
794
+ log: text
795
+ });
796
+ var storeJobCancel = strictObject({ job: id, cancelled: literal(true) });
797
+ var storeJobRetry = union([
798
+ strictObject({ ...messageSyncStarted.entries, retried: id }),
799
+ strictObject({ retried: id, chat: text, error: strictObject({ code: text, message: text }) })
800
+ ]);
801
+ var storeJobClear = strictObject({ cleared: array(id) });
802
+
803
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-preparation-parts.js
804
+ var preparationId = pipe(string(), minLength(1));
805
+ var preparationCount = pipe(number(), integer(), minValue(0));
806
+ var preparationTime = nullable(isoTime);
807
+ var text2 = nullable(string());
808
+ var id2 = preparationId;
809
+ var count2 = preparationCount;
810
+ var page = /* @__PURE__ */ __name((item) => strictObject({ items: array(item), has_more: boolean() }), "page");
811
+ var preparationUpcoming = strictObject({
812
+ scope: strictObject({ provider: id2, account: id2 }),
813
+ meeting_id: id2,
814
+ kind: picklist(["single", "recurring", "unscheduled", "unknown"]),
815
+ after: isoTime,
816
+ until: isoTime,
817
+ timezone: text2,
818
+ verified_next: boolean(),
819
+ candidate: nullable(strictObject({
820
+ id: text2,
821
+ start_at: preparationTime,
822
+ end_at: preparationTime,
823
+ status: picklist(["scheduled", "cancelled"]),
824
+ verified: boolean()
825
+ })),
826
+ coverage: strictObject({
827
+ schedule_complete: boolean(),
828
+ inspected: count2,
829
+ undated: count2,
830
+ unverified: count2,
831
+ cancelled: count2,
832
+ simultaneous: count2,
833
+ missing: array(picklist(["schedule-details", "occurrence-details"]))
834
+ })
835
+ });
836
+ var preparationCue = strictObject({
837
+ ref: reference,
838
+ fingerprint: id2,
839
+ transcript_id: id2,
840
+ content_hash: text2,
841
+ position: count2,
842
+ offset_ms: count2,
843
+ end_ms: count2,
844
+ speaker_participant_id: nullable(id2),
845
+ speaker_name: text2,
846
+ text: string(),
847
+ revision: picklist(["current", "superseded"])
848
+ });
849
+ var preparationEvidence = strictObject({
850
+ schema_version: literal(1),
851
+ kind: literal("meeting"),
852
+ source: reference,
853
+ fingerprint: id2,
854
+ limits: strictObject({ cues: count2, bytes: count2, max_read_bytes: count2, max_transcript_pages: count2 }),
855
+ content_bytes: count2,
856
+ coverage: strictObject({
857
+ provided: count2,
858
+ included: count2,
859
+ omitted: nullable(count2),
860
+ provided_exact: boolean(),
861
+ next_transcript_id: nullable(id2),
862
+ next_reference: nullable(reference),
863
+ transcript_pages: count2,
864
+ skipped_unavailable: count2,
865
+ has_more: boolean(),
866
+ truncated_by: nullable(picklist(["cues", "bytes", "transcripts"])),
867
+ input: literal("bounded-meeting-pages"),
868
+ archive_completeness: literal("unknown")
869
+ }),
870
+ items: array(preparationCue)
871
+ });
872
+ var preparationContext = strictObject({
873
+ participants: page(strictObject({ id: id2, identity_id: id2, display_name: text2, person_uid: nullable(id2) })),
874
+ projects: page(strictObject({ ref: reference, key: id2, name: string(), link_id: id2 })),
875
+ facts: page(strictObject({ ref: reference, type: id2, statement: string(), updated_at: isoTime })),
876
+ tasks: page(strictObject({
877
+ ref: reference,
878
+ key: id2,
879
+ title: string(),
880
+ status: id2,
881
+ priority: nullable(count2),
882
+ source: nullable(reference)
883
+ }))
884
+ });
885
+ var preparationMeeting = strictObject({
886
+ id: id2,
887
+ external_id: id2,
888
+ title: text2,
889
+ event_id: nullable(id2),
890
+ started_at: preparationTime,
891
+ ended_at: preparationTime,
892
+ updated_at: isoTime
893
+ });
894
+
895
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-communications.js
896
+ var communicationCoverage = strictObject({
897
+ read_usage: strictObject({ reads: preparationCount, charged_bytes: preparationCount, reserved_bytes: preparationCount, remaining_bytes: preparationCount }),
898
+ query: string(),
899
+ window: strictObject({ after: isoTime, before: isoTime }),
900
+ selection: literal("explicit-host-grants/literal-words"),
901
+ sources: array(strictObject({
902
+ selection_id: preparationId,
903
+ source: strictObject({
904
+ kind: picklist(["message", "mail", "document"]),
905
+ account_id: preparationId,
906
+ provider: preparationId,
907
+ account: preparationId
908
+ }),
909
+ state: picklist(["searched", "unavailable", "read-limited"]),
910
+ index: picklist(["ready", "pending", "missing", "unknown"]),
911
+ has_more: boolean(),
912
+ has_undated: boolean(),
913
+ completeness: literal("unknown"),
914
+ consistency: literal("snapshot-per-page"),
915
+ next_cursor: nullable(string()),
916
+ restart_required: boolean(),
917
+ output_limited: boolean(),
918
+ read_bytes: nullable(preparationCount),
919
+ issue: nullable(picklist(["not_found", "validation_error", "configuration_error"]))
920
+ }))
921
+ });
922
+ var preparationCommunications = strictObject({
923
+ coverage: communicationCoverage,
924
+ items: array(strictObject({
925
+ selection_id: preparationId,
926
+ ref: reference,
927
+ provider: preparationId,
928
+ account: preparationId,
929
+ title: nullable(string()),
930
+ url: nullable(string()),
931
+ text: string(),
932
+ at: isoTime,
933
+ updated_at: isoTime,
934
+ revision: nullable(pipe(number(), safeInteger(), minValue(1))),
935
+ time_kind: picklist(["sent", "source-modified", "stored-update"]),
936
+ text_truncated: boolean()
937
+ }))
938
+ });
939
+
940
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-preparation.js
941
+ var meetingPreparation = strictObject({
942
+ communications: optional(preparationCommunications),
943
+ schema_version: literal(1),
944
+ kind: literal("meeting_preparation"),
945
+ account_id: preparationId,
946
+ upcoming: preparationUpcoming,
947
+ series: nullable(strictObject({
948
+ id: preparationId,
949
+ external_id: preparationId,
950
+ title: nullable(string()),
951
+ event_series_id: nullable(preparationId),
952
+ updated_at: isoTime
953
+ })),
954
+ history_window: strictObject({ after: isoTime, before: isoTime }),
955
+ meetings: array(strictObject({
956
+ ref: reference,
957
+ meeting: preparationMeeting,
958
+ evidence: preparationEvidence,
959
+ context: preparationContext
960
+ })),
961
+ related: strictObject({
962
+ anchors: array(reference),
963
+ items: array(strictObject({
964
+ ref: reference,
965
+ meeting: preparationMeeting,
966
+ evidence: preparationEvidence,
967
+ shared_person: boolean(),
968
+ shared_project: boolean()
969
+ })),
970
+ has_more: boolean(),
971
+ output_limited: boolean(),
972
+ selection: literal("explicit-person-links/confirmed-project-links")
973
+ }),
974
+ knowledge: optional(strictObject({
975
+ anchors: array(reference),
976
+ items: array(strictObject({
977
+ ref: reference,
978
+ type: picklist(["fact", "statement", "question", "decision", "promise"]),
979
+ statement: string(),
980
+ subject: nullable(reference),
981
+ project: nullable(reference),
982
+ updated_at: isoTime,
983
+ shared_person: boolean(),
984
+ shared_project: boolean()
985
+ })),
986
+ selection: literal("accepted-global-person/project-facts"),
987
+ coverage: strictObject({
988
+ has_more: boolean(),
989
+ output_limited: boolean(),
990
+ fact_evidence: literal("not-revalidated"),
991
+ other_sources: picklist(["not-queried", "see-communications"])
992
+ })
993
+ })),
994
+ notes: optional(strictObject({
995
+ anchors: array(reference),
996
+ items: array(strictObject({
997
+ ref: reference,
998
+ title: nullable(string()),
999
+ text: string(),
1000
+ revision: pipe(number(), safeInteger(), minValue(1)),
1001
+ updated_at: isoTime,
1002
+ person: nullable(reference),
1003
+ project: nullable(reference),
1004
+ meeting: optional(nullable(reference))
1005
+ })),
1006
+ selection: picklist([
1007
+ "owner-written-global-person/project-notes",
1008
+ "owner-written-meeting/person/project-notes"
1009
+ ]),
1010
+ coverage: strictObject({
1011
+ has_more: boolean(),
1012
+ output_limited: boolean(),
1013
+ source_evidence: literal("not-revalidated"),
1014
+ other_sources: picklist(["not-queried", "see-communications"])
1015
+ })
1016
+ })),
1017
+ project_evidence: optional(strictObject({
1018
+ project: string(),
1019
+ query: string(),
1020
+ pages: array(meetingProjectEvidence),
1021
+ continuation: nullable(strictObject({
1022
+ command: literal("meetings projects evidence"),
1023
+ project: string(),
1024
+ query: string(),
1025
+ cursor: nullable(string()),
1026
+ limit: preparationCount,
1027
+ max_read_bytes: preparationCount
1028
+ })),
1029
+ coverage: strictObject({ page_limit: preparationCount, has_more: boolean(), output_limited: boolean() })
1030
+ })),
1031
+ limits: strictObject({ meetings: preparationCount, cues: preparationCount, context_limit: preparationCount, max_read_bytes: preparationCount, bytes: preparationCount }),
1032
+ coverage: strictObject({
1033
+ archive_completeness: literal("unknown"),
1034
+ consistency: literal("live-reads"),
1035
+ history_has_more: boolean(),
1036
+ has_undated: boolean(),
1037
+ skipped_unavailable: array(reference),
1038
+ output_limited: boolean(),
1039
+ context: literal("observed-participants/confirmed-projects/accepted-meeting-subject-facts/direct-source-tasks"),
1040
+ fact_evidence: literal("not-revalidated"),
1041
+ unqueried: array(picklist([
1042
+ "person-history",
1043
+ "project-wide-context",
1044
+ "person-nonmeeting-context",
1045
+ "project-nonmeeting-context",
1046
+ "project-alias-candidates",
1047
+ "other-person-nonmeeting-context",
1048
+ "other-project-nonmeeting-context"
1049
+ ]))
1050
+ })
1051
+ });
1052
+
1053
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-project-candidates.js
1054
+ var count3 = pipe(number(), integer(), minValue(0));
1055
+ var id3 = pipe(string(), minLength(1));
1056
+ var text3 = string();
1057
+ var meetingProjectCandidates = strictObject({
1058
+ schema_version: literal(1),
1059
+ kind: literal("meeting_project_candidates"),
1060
+ source: strictObject({ provider: text3, account: text3, account_id: id3, ref: reference }),
1061
+ input_fingerprint: id3,
1062
+ vocabulary_fingerprint: id3,
1063
+ association: literal("unconfirmed-literal-evidence"),
1064
+ items: array(strictObject({
1065
+ project: strictObject({ ref: reference, id: id3, name: text3, key: nullable(text3) }),
1066
+ matches: array(strictObject({
1067
+ term: strictObject({
1068
+ name: text3,
1069
+ kind: picklist(["canonical", "key", "alias"]),
1070
+ alias_id: optional(id3)
1071
+ }),
1072
+ ambiguous: boolean(),
1073
+ source: strictObject({
1074
+ kind: picklist(["metadata-title", "transcript"]),
1075
+ ref: reference,
1076
+ fingerprint: nullable(id3),
1077
+ revision: nullable(picklist(["current", "superseded"]))
1078
+ })
1079
+ })),
1080
+ omitted_matches: count3
1081
+ })),
1082
+ limits: strictObject({ limit: count3, max_projects: count3, max_vocabulary_read_bytes: count3, bytes: count3 }),
1083
+ coverage: strictObject({
1084
+ selection: literal("explicit-host-evidence/global-project-vocabulary"),
1085
+ source_evidence: literal("not-revalidated"),
1086
+ association: literal("unconfirmed-literal-evidence"),
1087
+ archive_completeness: literal("unknown"),
1088
+ omitted_matches: count3,
1089
+ candidates_total: count3,
1090
+ has_more: boolean(),
1091
+ output_limited: boolean(),
1092
+ matching: literal("unicode-normalized-literal-word-boundaries")
1093
+ }),
1094
+ evidence: strictObject({
1095
+ fingerprint: id3,
1096
+ limits: strictObject({ cues: count3, bytes: count3, max_read_bytes: count3, max_transcript_pages: count3 }),
1097
+ coverage: strictObject({
1098
+ provided: count3,
1099
+ included: count3,
1100
+ omitted: nullable(count3),
1101
+ provided_exact: boolean(),
1102
+ next_cursor: nullable(reference),
1103
+ next_transcript_id: nullable(id3),
1104
+ next_reference: nullable(reference),
1105
+ transcript_pages: count3,
1106
+ skipped_unavailable: count3,
1107
+ has_more: boolean(),
1108
+ truncated_by: nullable(picklist(["cues", "bytes", "transcripts"])),
1109
+ input: literal("bounded-meeting-pages"),
1110
+ archive_completeness: literal("unknown")
1111
+ }),
1112
+ consistency: literal("live-reads"),
1113
+ max_store_calls: literal(8)
1114
+ })
1115
+ });
1116
+
1117
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-series-inventory.js
1118
+ var count4 = pipe(number(), integer(), minValue(0));
1119
+ var id4 = pipe(string(), minLength(1), maxLength(1e3));
1120
+ var meetingSeriesInventory = strictObject({
1121
+ schema_version: literal(1),
1122
+ kind: literal("meeting_series_inventory"),
1123
+ scope: strictObject({ provider: id4, account: id4 }),
1124
+ after: isoTime,
1125
+ until: isoTime,
1126
+ items: array(strictObject({
1127
+ meeting_id: id4,
1128
+ title: nullable(pipe(string(), maxLength(8192))),
1129
+ kind: picklist(["single", "recurring", "unscheduled", "unknown"]),
1130
+ scheduled_start_at: nullable(isoTime)
1131
+ })),
1132
+ page: pageSchema,
1133
+ fingerprint: pipe(string(), minLength(1), maxLength(200)),
1134
+ limits: strictObject({ limit: count4, max_read_bytes: count4, bytes: count4 }),
1135
+ coverage: strictObject({
1136
+ selection: picklist(["provider-window", "provider-inventory"]),
1137
+ source_partial: boolean(),
1138
+ has_more: boolean(),
1139
+ undated: count4,
1140
+ date_hints_outside_window: count4,
1141
+ calendar_completeness: literal("unknown"),
1142
+ occurrence_proof: literal("not-read"),
1143
+ consistency: literal("live-provider-pages")
1144
+ })
1145
+ });
1146
+
1147
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/saved-search.js
1148
+ var savedSearch = strictObject({
1149
+ id,
1150
+ /** `null` for a run in the history. */
1151
+ name: nullable(text),
1152
+ command: picklist(["search", "stats", "message-top", "author-top", "admin-statistics", "meetings-search"]),
1153
+ /** The query and the options it runs with, as the command took them. */
1154
+ params: record(string(), unknown()),
1155
+ language: text,
1156
+ version: count,
1157
+ fields_version: count,
1158
+ created_at: time,
1159
+ last_run_at: nullable(time),
1160
+ runs: count
1161
+ });
1162
+ var searchHistoryClear = strictObject({ cleared: count });
1163
+
1164
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/account.js
1165
+ var account = strictObject({
1166
+ provider: text,
1167
+ id,
1168
+ name: nullable(text),
1169
+ username: nullable(text),
1170
+ phone: optional(nullable(text)),
1171
+ scope: optional(picklist(["personal", "work"]))
1172
+ });
1173
+
1174
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/account-session.js
1175
+ var accountSession = strictObject({
1176
+ current: boolean(),
1177
+ client: nullable(text),
1178
+ device: nullable(text),
1179
+ location: nullable(text),
1180
+ last_active_at: nullable(time),
1181
+ created_at: optional(nullable(time))
1182
+ });
1183
+
1184
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/account-change.js
1185
+ var accountChange = strictObject({ operation_id: id, account: omit(account, ["provider", "scope"]) });
1186
+ var endedAccountSessions = strictObject({ operation_id: id, sessions: array(accountSession) });
1187
+ var audience = picklist(["everyone", "contacts", "nobody"]);
1188
+ var shownAudience = picklist(["everyone", "contacts", "nobody", "contacts_except"]);
1189
+ var accountPrivacy = strictObject({
1190
+ find_by_phone: optional(audience),
1191
+ phone_number: optional(audience),
1192
+ calls: optional(audience),
1193
+ chat_invites: optional(audience),
1194
+ hide_online: optional(boolean()),
1195
+ read_receipts: optional(boolean()),
1196
+ profile_photo: optional(shownAudience),
1197
+ about: optional(shownAudience),
1198
+ last_seen: optional(shownAudience)
1199
+ });
1200
+ var accountPrivacyChange = strictObject({ operation_id: id, privacy: accountPrivacy });
1201
+
1202
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/account-profile.js
1203
+ var accountProfile = strictObject({
1204
+ profile: id,
1205
+ current: boolean(),
1206
+ account: nullable(id),
1207
+ name: nullable(text),
1208
+ /** False for a profile with no session on this computer; absent when the messenger does not say. */
1209
+ signed_in: optional(boolean())
1210
+ });
1211
+
1212
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/counter-reading.js
1213
+ var milliseconds = pipe(number(), minValue(0));
1214
+ var counterReading = strictObject({
1215
+ counter: picklist(["views", "reactions", "comments"]),
1216
+ value: nullable(number()),
1217
+ observed_at: nullable(time),
1218
+ source: nullable(text),
1219
+ age_ms: nullable(milliseconds),
1220
+ freshness: picklist(["fresh", "stale", "unknown"])
1221
+ });
1222
+ var selection = record(string(), unknown());
1223
+
1224
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/admin-report.js
1225
+ var adminRow = strictObject({
1226
+ ref: reference,
1227
+ /** What `stats * evidence` takes: a person id, a stay or a message locator. */
1228
+ id,
1229
+ status: picklist(["observed", "no-observed-answer", "partial", "unknown"]),
1230
+ chat_ref: optional(reference),
1231
+ person_ref: optional(reference),
1232
+ identity_known: optional(boolean()),
1233
+ questions: optional(count),
1234
+ answered: optional(count),
1235
+ median_ms: optional(nullable(milliseconds)),
1236
+ p90_ms: optional(nullable(milliseconds)),
1237
+ age_ms: optional(milliseconds),
1238
+ joined_at: optional(time),
1239
+ window_end: optional(time),
1240
+ pending: optional(boolean()),
1241
+ views: optional(count),
1242
+ observed_replies: optional(count),
1243
+ comment_snapshot: optional(nullable(count)),
1244
+ counters: optional(array(counterReading)),
1245
+ selection
1246
+ });
1247
+ var adminReport = strictObject({
1248
+ report: picklist(["unanswered", "responses", "newcomers", "discussion"]),
1249
+ cutoff: time,
1250
+ /** Rows the report found; `rows` holds the first `--limit` of them. */
1251
+ total: count,
1252
+ summary: strictObject({
1253
+ questions: count,
1254
+ answered: count,
1255
+ no_observed_answer: count,
1256
+ excluded_future: count,
1257
+ unknown_join: count,
1258
+ missing_views: count
1259
+ }),
1260
+ quality: strictObject({
1261
+ graph: strictObject({
1262
+ unknown_links: count,
1263
+ unknown_authors: count,
1264
+ missing_parents: count,
1265
+ cycles: count,
1266
+ complete: boolean()
1267
+ }),
1268
+ archives: array(strictObject({ chat_ref: reference, state: text, fetched_at: nullable(time) })),
1269
+ archives_total: count,
1270
+ membership: text,
1271
+ counter_freshness: text,
1272
+ answerer_roles: text
1273
+ }),
1274
+ rows: array(adminRow)
1275
+ });
1276
+
1277
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/analysis-consent.js
1278
+ var analysisConsent = strictObject({ chat: id, provider: text, at: time });
1279
+ var analysisConsentRevocation = strictObject({ revoked: boolean() });
1280
+
1281
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/attachment-results.js
1282
+ var fingerprint = pipe(text, regex(/^[a-f0-9]{64}$/));
1283
+ var attachmentBytes = strictObject({
1284
+ ref: reference,
1285
+ attachment: count,
1286
+ name: nullable(text),
1287
+ mime_type: text,
1288
+ total_bytes: count,
1289
+ sha256: fingerprint,
1290
+ offset_bytes: count,
1291
+ read_bytes: count,
1292
+ next_offset_bytes: nullable(count),
1293
+ complete: boolean(),
1294
+ base64: optional(text),
1295
+ pdf: optional(strictObject({ page: count, page_count: count, source_sha256: fingerprint, source_bytes: count }))
1296
+ });
1297
+ var attachmentExtraction = union([
1298
+ strictObject({ ...omit(extractionReport, ["items"]).entries, files: array(extractionItem) }),
1299
+ extractionItem
1300
+ ]);
1301
+ var attachmentTextChange = strictObject({
1302
+ ref: reference,
1303
+ attachment: count,
1304
+ origin: literal("agent"),
1305
+ chars: count,
1306
+ replaced: nullable(picklist(["extracted", "agent"]))
1307
+ });
1308
+
1309
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chart.js
1310
+ var chart = strictObject({
1311
+ version: literal(1),
1312
+ kind: picklist(["bar", "line", "grouped-bar"]),
1313
+ title: text,
1314
+ x: strictObject({ type: picklist(["day", "week"]), values: array(text) }),
1315
+ series: array(strictObject({ name: text, values: array(nullable(number())) })),
1316
+ unit: picklist(["messages", "people"]),
1317
+ timezone: text,
1318
+ /** Lower bounds: the store or the events did not hold the whole period. */
1319
+ partial: boolean(),
1320
+ reasons: array(picklist(["store-incomplete", "events-incomplete"])),
1321
+ file: optional(strictObject({ path: text, format: picklist(["svg", "png"]), width: count, height: count }))
1322
+ });
1323
+
1324
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/folder.js
1325
+ var named = strictObject({
1326
+ id,
1327
+ title: nullable(text),
1328
+ kind: nullable(picklist(["dialog", "group", "channel", "saved", "unknown"]))
1329
+ });
1330
+ var folder = strictObject({
1331
+ id,
1332
+ title: text,
1333
+ /** Chats added by hand; a folder that selects chats by a rule of its own lists none. */
1334
+ chat_ids: array(id),
1335
+ emoji: optional(text),
1336
+ /** Kinds of chat it takes by itself. */
1337
+ include: optional(array(picklist(["contacts", "non-contacts", "groups", "channels", "bots"]))),
1338
+ skip: optional(array(picklist(["muted", "read", "archived"]))),
1339
+ excluded_chat_ids: optional(array(id)),
1340
+ pinned_chat_ids: optional(array(id)),
1341
+ /** `chats folders show`: the chats in it, pinned and left out, by name. */
1342
+ chats: optional(array(named)),
1343
+ pinned_chats: optional(array(named)),
1344
+ excluded_chats: optional(array(named))
1345
+ });
1346
+
1347
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/invite-link.js
1348
+ var inviteLink = strictObject({
1349
+ link: text,
1350
+ /** Who joins by it asks first, and an admin lets them in. */
1351
+ approval: boolean(),
1352
+ /** `null` when it never expires. */
1353
+ expires_at: nullable(time),
1354
+ /** `null` for no limit. */
1355
+ max_uses: nullable(count),
1356
+ /** The group's own link; revoking it makes the messenger issue a new one. */
1357
+ primary: optional(boolean()),
1358
+ revoked: optional(boolean()),
1359
+ pending_count: optional(count),
1360
+ joined_count: optional(count)
1361
+ });
1362
+
1363
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-admin.js
1364
+ var operated = { operation_id: id, chat_id: id };
1365
+ var group = strictObject({
1366
+ ...omit(chat, ["ref", "provider", "account", "invite_link", "members"]).entries,
1367
+ parent_chat_id: optional(nullable(id)),
1368
+ muted_until: optional(nullable(time)),
1369
+ description: nullable(text),
1370
+ link: nullable(text),
1371
+ settings: strictObject({
1372
+ ...unwrap(chat.entries.settings).entries,
1373
+ all_can_pin: nullable(boolean()),
1374
+ only_admins_add: nullable(boolean()),
1375
+ only_admins_call: nullable(boolean()),
1376
+ only_owner_edits_info: nullable(boolean()),
1377
+ members_see_link: nullable(boolean())
1378
+ })
1379
+ });
1380
+ var chatGroupChange = union([
1381
+ strictObject({ operation_id: id, chat: group }),
1382
+ strictObject({ operation_id: id, requested: literal(true) })
1383
+ ]);
1384
+ var chatInspection = strictObject({
1385
+ kind: chat.entries.kind,
1386
+ title: nullable(text),
1387
+ id: nullable(id),
1388
+ username: nullable(text),
1389
+ participants_count: nullable(count),
1390
+ description: nullable(text),
1391
+ member: nullable(boolean()),
1392
+ approval_needed: optional(boolean())
1393
+ });
1394
+ var chatSender = strictObject({
1395
+ id,
1396
+ title: text,
1397
+ kind: picklist(["self", "channel", "group"]),
1398
+ premium_required: boolean(),
1399
+ default: boolean()
1400
+ });
1401
+ var chatRead = strictObject({ ...operated, until: nullable(id), thread_id: optional(id) });
1402
+ var chatMembersFetch = strictObject({
1403
+ chat_id: id,
1404
+ joined: array(id),
1405
+ gone: array(id),
1406
+ changed: array(id),
1407
+ read: count,
1408
+ participants: nullable(count),
1409
+ complete: boolean(),
1410
+ more: boolean(),
1411
+ tracked: boolean()
1412
+ });
1413
+ var chatMembersChange = union([
1414
+ strictObject({ ...operated, added: array(id), not_added: array(id) }),
1415
+ strictObject({ ...operated, removed: array(id) })
1416
+ ]);
1417
+ var chatInvite = strictObject({ chat_id: id, title: nullable(text), link: text });
1418
+ var chatInviteChange = strictObject({
1419
+ ...operated,
1420
+ ...omit(inviteLink, ["pending_count", "joined_count"]).entries,
1421
+ pending: optional(count),
1422
+ joined: optional(count)
1423
+ });
1424
+ var chatRequestChange = union([
1425
+ strictObject({ ...operated, person_id: id, accepted: boolean(), already: boolean() }),
1426
+ strictObject({ chat_id: id, accepted: boolean(), counted: count, operation_id: optional(id) })
1427
+ ]);
1428
+ var chatAdminChange = strictObject({
1429
+ ...operated,
1430
+ person_id: id,
1431
+ rights: optional(array(picklist(["read", "members", "admins", "info", "pin", "link", "post", "edit", "delete"])))
1432
+ });
1433
+ var chatFolderChange = strictObject({
1434
+ operation_id: id,
1435
+ folder: omit(folder, ["chats", "pinned_chats", "excluded_chats"])
1436
+ });
1437
+ var chatFolderRemoval = strictObject({ operation_id: id, folder_id: id });
1438
+ var chatFolderOrder = strictObject({
1439
+ operation_id: id,
1440
+ folders: array(strictObject({ id, title: text }))
1441
+ });
1442
+
1443
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-change.js
1444
+ var operated2 = { operation_id: id, chat_id: id };
1445
+ var chatRemoval = strictObject(operated2);
1446
+ var chatMuting = strictObject({
1447
+ ...operated2,
1448
+ muted_until: nullable(union([time, literal("forever")]))
1449
+ });
1450
+ var chatArchive = strictObject({ ...operated2, archived: boolean() });
1451
+ var chatPin = strictObject({ ...operated2, pinned: boolean() });
1452
+ var chatUnread = strictObject({ ...operated2, unread: literal(true) });
1453
+
1454
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-event.js
1455
+ var who = strictObject({ id: nullable(id), name: nullable(text), username: optional(nullable(text)) });
1456
+ var chatEvent = strictObject({
1457
+ chat_id: id,
1458
+ time,
1459
+ /** `join`, `leave`, `add`, `remove`, `create`, `title`, `pin`, `profile`; a messenger may pass others through. */
1460
+ type: text,
1461
+ /** The service message that says so, where there is one. */
1462
+ message_id: optional(id),
1463
+ by: optional(who),
1464
+ people: array(who),
1465
+ /** `create` and `title` carry the chat's title. */
1466
+ title: optional(text),
1467
+ /** `profile`: the name and username seen before. */
1468
+ before: optional(strictObject({ name: nullable(text), username: nullable(text) }))
1469
+ });
1470
+
1471
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-metadata.js
1472
+ var chatMetadata = strictObject({
1473
+ chat_id: id,
1474
+ title: nullable(text),
1475
+ username: nullable(text),
1476
+ description: nullable(text),
1477
+ fetched_at: time
1478
+ });
1479
+ var cachedChatMetadata = strictObject({ chat_id: id, metadata: nullable(chatMetadata) });
1480
+ var failedChatMetadata = strictObject({ chat_id: id, error: strictObject({ code: text, message: text }) });
1481
+ var chatMetadataRefresh = strictObject({
1482
+ chats: array(union([chatMetadata, failedChatMetadata])),
1483
+ has_more: boolean()
1484
+ });
1485
+
1486
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-moderation.js
1487
+ var action = picklist(["report", "delete", "remove"]);
1488
+ var level = picklist(["deny", "readonly", "ask", "allow"]);
1489
+ var chatRules = strictObject({
1490
+ chat_id: id,
1491
+ title: nullable(text),
1492
+ file: text,
1493
+ saved: boolean(),
1494
+ rules: strictObject({
1495
+ title: nullable(text),
1496
+ trusted: array(id),
1497
+ blocked: array(id),
1498
+ blocked_names: array(text),
1499
+ links: action,
1500
+ invites: action,
1501
+ forwards: action,
1502
+ blocked_people: action,
1503
+ flood: strictObject({ messages: count, minutes: count, action }),
1504
+ new_account: strictObject({ days: count, action: picklist(["report", "remove"]) }),
1505
+ consent: strictObject({ delete: level, remove: level })
1506
+ })
1507
+ });
1508
+ var chatModeration = strictObject({
1509
+ chat_id: id,
1510
+ rows: array(strictObject({
1511
+ kind: picklist(["message", "member"]),
1512
+ rule: picklist(["blocked", "invites", "links", "forwards", "flood", "newAccount"]),
1513
+ person_id: id,
1514
+ person_name: nullable(text),
1515
+ message_id: optional(id),
1516
+ action,
1517
+ outcome: picklist(["reported", "done", "planned", "forbidden", "declined", "refused", "failed", "skipped"]),
1518
+ reason: optional(text),
1519
+ command: optional(text)
1520
+ }))
1521
+ });
1522
+
1523
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-stats.js
1524
+ var optionalCount = optional(count);
1525
+ var minutes = nullable(number());
1526
+ var chatStats = strictObject({
1527
+ chat: reference,
1528
+ since: time,
1529
+ until: time,
1530
+ /** The store holds the chat whole and the messenger read every join and leave; otherwise lower bounds. */
1531
+ complete: boolean(),
1532
+ completeness: strictObject({
1533
+ state: picklist(["complete", "partial", "unknown"]),
1534
+ up_to_date: nullable(boolean()),
1535
+ gaps: boolean(),
1536
+ reaches_start: boolean(),
1537
+ fetched_at: nullable(time)
1538
+ }),
1539
+ messages: count,
1540
+ senders: count,
1541
+ replies: count,
1542
+ threads: count,
1543
+ reactions: count,
1544
+ views: optionalCount,
1545
+ forwards: optionalCount,
1546
+ comments: optionalCount,
1547
+ top_posts: array(strictObject({
1548
+ ref: reference,
1549
+ timestamp: time,
1550
+ reactions: count,
1551
+ views: optionalCount,
1552
+ forwards: optionalCount,
1553
+ comments: optionalCount
1554
+ })),
1555
+ questions: strictObject({
1556
+ asked: count,
1557
+ answered: count,
1558
+ median_minutes_to_answer: minutes,
1559
+ answered_by: picklist(["owner", "owner-and-admins"])
1560
+ }),
1561
+ member_counts: optional(array(strictObject({ day: text, participants: nullable(count), listed: count, complete: boolean() }))),
1562
+ /** Absent where joins and leaves were not asked, or not recorded for the chat yet (then `missing` says so). */
1563
+ members: optional(strictObject({
1564
+ joined: count,
1565
+ left: count,
1566
+ net: number(),
1567
+ wrote: count,
1568
+ median_minutes_to_first_message: minutes,
1569
+ /** The messenger stopped reading its history before `since`: the counts are lower bounds. */
1570
+ more: boolean()
1571
+ })),
1572
+ series: optional(array(strictObject({ key: text, messages: count, senders: count, joined: optionalCount, left: optionalCount })))
1573
+ });
1574
+ var taskStats = strictObject({
1575
+ /** Open tasks across every row. */
1576
+ open: count,
1577
+ rows: array(strictObject({
1578
+ chat: reference,
1579
+ open: count,
1580
+ oldest_open_at: nullable(time),
1581
+ median_close_ms: nullable(pipe(number(), minValue(0)))
1582
+ }))
1583
+ });
1584
+
1585
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/chat-tracking.js
1586
+ var memberCount = strictObject({
1587
+ day: pipe(text, isoDate()),
1588
+ participants: nullable(count),
1589
+ listed: count,
1590
+ complete: boolean()
1591
+ });
1592
+ var trackedChat = strictObject({
1593
+ chat_id: id,
1594
+ title: nullable(text),
1595
+ tracked_at: time,
1596
+ last_count: nullable(memberCount)
1597
+ });
1598
+ var trackedChatHistory = strictObject({
1599
+ chat_id: id,
1600
+ tracked_at: nullable(time),
1601
+ counts: array(memberCount)
1602
+ });
1603
+ var chatTracking = strictObject({
1604
+ chat_id: id,
1605
+ tracked: boolean()
1606
+ });
1607
+
1608
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact.js
1609
+ var contact = strictObject({
1610
+ ref: reference,
1611
+ id,
1612
+ name: nullable(text),
1613
+ username: nullable(text),
1614
+ alias: optional(nullable(text)),
1615
+ display_name: optional(nullable(text)),
1616
+ /** Whatever they wrote about themselves. */
1617
+ description: nullable(text),
1618
+ /** The newest message in a one-to-one chat with them. */
1619
+ last_messaged_at: nullable(time),
1620
+ /** For a source that knows it, such as a Zoom contact. */
1621
+ email: optional(nullable(text)),
1622
+ phones: optional(array(strictObject({ number: text, label: nullable(text) }))),
1623
+ /** `contacts show`: the chats shared with them. */
1624
+ chats: optional(array(pick(chat, ["ref", "id", "title", "kind", "last_message_at"]))),
1625
+ /** `contacts show --with-notes`: the owner's private notes about them. */
1626
+ notes: optional(array(strictObject({ id, text, revision: count, created_at: time, updated_at: time })))
1627
+ });
1628
+
1629
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact-activity.js
1630
+ var linkedIdentity = strictObject({
1631
+ provider: text,
1632
+ id,
1633
+ name: nullable(text),
1634
+ username: nullable(text),
1635
+ is_bot: nullable(boolean()),
1636
+ accounts: array(id),
1637
+ method: text,
1638
+ linked_by: text,
1639
+ linked_at: time
1640
+ });
1641
+ var linkedPerson = strictObject({ uid: id, name: nullable(text), identities: array(linkedIdentity) });
1642
+ var contactActivity = strictObject({
1643
+ at: time,
1644
+ subject: text,
1645
+ subject_id: count,
1646
+ role: text,
1647
+ scope: text,
1648
+ provider: nullable(text),
1649
+ account: nullable(text),
1650
+ chat_id: nullable(text),
1651
+ locator: nullable(text),
1652
+ project_id: nullable(count)
1653
+ });
1654
+ var botReason = picklist(Object.keys(WEIGHTS));
1655
+ var contactCheck = strictObject({
1656
+ person: strictObject({ id, name: nullable(text), username: nullable(text), provider: text }),
1657
+ score: count,
1658
+ reasons: array(strictObject({ reason: botReason, weight: count, source: text, detail: optional(text) })),
1659
+ registries: array(strictObject({
1660
+ name: picklist(["cas", "lols"]),
1661
+ answer: picklist(["listed", "clean", "unknown"]),
1662
+ checked_at: time,
1663
+ detail: optional(text),
1664
+ reasons: optional(array(picklist(["cas_banned", "lols_banned", "lols_scammer"])))
1665
+ })),
1666
+ unknown: array(botReason),
1667
+ checked_at: time
1668
+ });
1669
+
1670
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact-context.js
1671
+ var contextPerson = strictObject({ ...linkedPerson.entries, provider: text, id });
1672
+ var contextMessage = strictObject({
1673
+ locator: reference,
1674
+ provider: text,
1675
+ account: id,
1676
+ chat_id: id,
1677
+ chat_title: nullable(text),
1678
+ id,
1679
+ timestamp: time,
1680
+ sender_id: nullable(id),
1681
+ sender_name: nullable(text),
1682
+ outgoing: nullable(boolean()),
1683
+ text
1684
+ });
1685
+ var sharedChat = strictObject({
1686
+ provider: text,
1687
+ account: id,
1688
+ chat_id: id,
1689
+ title: nullable(text),
1690
+ kind: chat.entries.kind,
1691
+ last_message_at: nullable(time)
1692
+ });
1693
+ var contextEvent = strictObject({
1694
+ ref: reference,
1695
+ title: nullable(text),
1696
+ starts_at: nullable(time),
1697
+ ends_at: nullable(time),
1698
+ all_day: boolean(),
1699
+ location: nullable(text),
1700
+ status: nullable(text)
1701
+ });
1702
+ var context = strictObject({
1703
+ person: contextPerson,
1704
+ shared: array(sharedChat),
1705
+ last: strictObject({
1706
+ from_them: nullable(contextMessage),
1707
+ from_me: nullable(contextMessage),
1708
+ from_them_anywhere: nullable(contextMessage)
1709
+ }),
1710
+ recent: strictObject({ direct: array(contextMessage), groups: array(contextMessage) }),
1711
+ mentions: array(contextMessage),
1712
+ /** Calendar events they are invited to, one occurrence per series. */
1713
+ events: optional(strictObject({ upcoming: array(contextEvent), recent: array(contextEvent) })),
1714
+ limits: strictObject({ messages: count, bytes: count }),
1715
+ complete: boolean(),
1716
+ not_read: array(strictObject({
1717
+ provider: text,
1718
+ account: id,
1719
+ chat_id: id,
1720
+ title: nullable(text),
1721
+ reason: picklist(["not_fetched", "partial"])
1722
+ }))
1723
+ });
1724
+ var shortMessage = strictObject({ at: time, text, transcript: optional(text) });
1725
+ var identifiedMessage = strictObject({
1726
+ ...shortMessage.entries,
1727
+ id,
1728
+ locator: reference,
1729
+ sender_id: nullable(id),
1730
+ reply_to: nullable(id)
1731
+ });
1732
+ var counterObservation = strictObject({
1733
+ value: number(),
1734
+ observed_at: time,
1735
+ source: picklist(["remote_fetch", "remote_update"]),
1736
+ reactions: optional(message.entries.reactions.wrapped.wrapped)
1737
+ });
1738
+ var { reply_addresses: mailReplyTo, ...mailFields } = message.entries.email.wrapped.entries;
1739
+ var fullMessage = strictObject({
1740
+ ...pick(message, [
1741
+ "id",
1742
+ "chat_id",
1743
+ "chat_title",
1744
+ "excerpt",
1745
+ "sender_id",
1746
+ "sender_name",
1747
+ "sender_username",
1748
+ "mentions",
1749
+ "sender_is_chat",
1750
+ "timestamp",
1751
+ "edited_at",
1752
+ "text",
1753
+ "outgoing",
1754
+ "attachments",
1755
+ "reply_to",
1756
+ "reply_to_id",
1757
+ "forwarded_from",
1758
+ "thread_id",
1759
+ "thread_root_id",
1760
+ "scheduled_for",
1761
+ "provider_metadata",
1762
+ "delivery"
1763
+ ]).entries,
1764
+ reactions: nullable(message.entries.reactions.wrapped.wrapped),
1765
+ starred: optional(boolean()),
1766
+ email: optional(strictObject({ ...mailFields, reply_to: mailReplyTo })),
1767
+ counter_observations: optional(partial(strictObject({
1768
+ views: counterObservation,
1769
+ reactions: counterObservation,
1770
+ comments: counterObservation
1771
+ }))),
1772
+ ...shortMessage.entries,
1773
+ locator: reference
1774
+ });
1775
+ var contactMessages = strictObject({
1776
+ person: strictObject({ uid: id, provider: text, id, name: nullable(text) }),
1777
+ chats: array(strictObject({
1778
+ chat: pick(chat, ["id", "title", "kind"]),
1779
+ messages: array(union([shortMessage, identifiedMessage, fullMessage])),
1780
+ complete: boolean(),
1781
+ more: boolean()
1782
+ })),
1783
+ limits: strictObject({ messages: count })
1784
+ });
1785
+ var contactContext = union([context, contactMessages]);
1786
+ var coverage = strictObject({
1787
+ included: count,
1788
+ has_more: boolean(),
1789
+ cut_by: nullable(picklist(["limit", "bytes"]))
1790
+ });
1791
+ var meetingCue = strictObject({
1792
+ reference,
1793
+ fingerprint: text,
1794
+ transcript_id: count,
1795
+ content_hash: nullable(text),
1796
+ position: count,
1797
+ start_ms: count,
1798
+ end_ms: count,
1799
+ speaker_participant_id: nullable(count),
1800
+ speaker_name: nullable(text),
1801
+ text,
1802
+ revision: picklist(["current", "superseded"])
1803
+ });
1804
+ var contactPreparation = strictObject({
1805
+ ...context.entries,
1806
+ prepare: strictObject({
1807
+ waiting: array(strictObject({
1808
+ provider: text,
1809
+ account: id,
1810
+ chat_id: id,
1811
+ title: nullable(text),
1812
+ message: contextMessage,
1813
+ partial: boolean()
1814
+ })),
1815
+ tasks: array(strictObject({
1816
+ ref: reference,
1817
+ title: text,
1818
+ role: text,
1819
+ due_at: nullable(time),
1820
+ project: reference,
1821
+ source: nullable(reference),
1822
+ created_at: time
1823
+ })),
1824
+ facts: array(strictObject({
1825
+ ref: reference,
1826
+ type: text,
1827
+ statement: text,
1828
+ subject: nullable(reference),
1829
+ project: nullable(reference),
1830
+ updated_at: time
1831
+ })),
1832
+ notes: array(strictObject({ ref: reference, title: nullable(text), text, revision: count, updated_at: time })),
1833
+ meetings: array(strictObject({
1834
+ reference,
1835
+ cues: array(meetingCue),
1836
+ cue_coverage: strictObject({ included: count, omitted: nullable(count), has_more: boolean() })
1837
+ })),
1838
+ limits: strictObject({ items: count, bytes: count }),
1839
+ coverage: strictObject({
1840
+ waiting: strictObject({
1841
+ ...coverage.entries,
1842
+ rule: literal("their message is the newest the store holds in a one-to-one chat")
1843
+ }),
1844
+ tasks: strictObject({
1845
+ ...coverage.entries,
1846
+ selection: literal("open, assigned to them in any role"),
1847
+ accounts: array(text)
1848
+ }),
1849
+ facts: strictObject({
1850
+ ...coverage.entries,
1851
+ selection: literal("accepted, about them or a project they are a member of")
1852
+ }),
1853
+ notes: strictObject({
1854
+ ...coverage.entries,
1855
+ selection: literal("written by you, about them"),
1856
+ withheld: optional(literal("contacts.notes.list"))
1857
+ }),
1858
+ meetings: strictObject({
1859
+ ...coverage.entries,
1860
+ read: literal("every account of the store that saw them"),
1861
+ accounts: array(text),
1862
+ pending: count
1863
+ })
1864
+ })
1865
+ })
1866
+ });
1867
+
1868
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact-note.js
1869
+ var contactNote = strictObject({
1870
+ id,
1871
+ /** The contact, as a `contact:` reference. */
1872
+ contact: reference,
1873
+ text,
1874
+ /** Starts at 1; an edit names the revision it read. */
1875
+ revision: count,
1876
+ created_at: time,
1877
+ updated_at: time
1878
+ });
1879
+
1880
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact-read.js
1881
+ var contactLookup = strictObject({ id, name: nullable(text), username: nullable(text) });
1882
+ var contactSync = strictObject({ added: count, changed: count, known: count });
1883
+ var contactProfile = strictObject({
1884
+ id,
1885
+ name: nullable(text),
1886
+ usernames: array(text),
1887
+ bio: nullable(text),
1888
+ birthday: optional(nullable(text)),
1889
+ phone: optional(nullable(text)),
1890
+ flags: partial(strictObject({
1891
+ bot: boolean(),
1892
+ verified: boolean(),
1893
+ premium: boolean(),
1894
+ scam: boolean(),
1895
+ fake: boolean(),
1896
+ restricted: boolean(),
1897
+ deleted: boolean(),
1898
+ support: boolean()
1899
+ })),
1900
+ seen: optional(text),
1901
+ contact: optional(boolean()),
1902
+ mutual_contact: optional(boolean()),
1903
+ common_chats_count: optional(nullable(count)),
1904
+ registered: optional(nullable(strictObject({
1905
+ at: text,
1906
+ source: picklist(["telegram", "max", "estimate"]),
1907
+ precision: picklist(["day", "month"])
1908
+ }))),
1909
+ has_photo: optional(boolean()),
1910
+ chats: array(strictObject({
1911
+ id,
1912
+ title: nullable(text),
1913
+ kind: chat.entries.kind,
1914
+ their_messages: count,
1915
+ first_at: nullable(time),
1916
+ last_at: nullable(time),
1917
+ complete: boolean()
1918
+ })),
1919
+ aliases: array(strictObject({
1920
+ name: optional(text),
1921
+ username: optional(text),
1922
+ link: optional(text),
1923
+ first_seen_at: time,
1924
+ last_seen_at: time,
1925
+ source: picklist(["profile", "messages"])
1926
+ }))
1927
+ });
1928
+
1929
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/contact-write.js
1930
+ var addressBookPerson = strictObject({ id, name: nullable(text), username: nullable(text) });
1931
+ var contactUpdate = strictObject({ operation_id: id, person: addressBookPerson });
1932
+ var contactStateChange = strictObject({ operation_id: id, person_id: id });
1933
+ var contactImport = strictObject({ operation_id: id, sent: count, recognised: array(addressBookPerson) });
1934
+
1935
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/conversation-results.js
1936
+ var conversationDetails = union([
1937
+ strictObject({ ...conversation.entries, messages: array(message) }),
1938
+ message
1939
+ ]);
1940
+ var conversationBatchStatus = strictObject({
1941
+ chat: id,
1942
+ messages: count,
1943
+ characters: count,
1944
+ batches: count,
1945
+ tokens_estimate: count
1946
+ });
1947
+ var batchMessage = strictObject({
1948
+ id,
1949
+ at: time,
1950
+ sender: strictObject({ id: nullable(id), name: nullable(text) }),
1951
+ text,
1952
+ reply_to: optional(id),
1953
+ thread: optional(id),
1954
+ mentions: optional(array(id)),
1955
+ answer: boolean(),
1956
+ candidates: optional(array(strictObject({ parent: nullable(id), source: text, kind: text, confidence: number() })))
1957
+ });
1958
+ var conversationBatch = union([
1959
+ strictObject({ batch: null_() }),
1960
+ strictObject({
1961
+ batch: id,
1962
+ chat: id,
1963
+ messages: array(batchMessage),
1964
+ remaining: strictObject({ messages: count, characters: count })
1965
+ })
1966
+ ]);
1967
+ var analyzedConversation = strictObject({
1968
+ chat: id,
1969
+ model: text,
1970
+ batches: count,
1971
+ stored: count,
1972
+ tokens: count,
1973
+ reserved_tokens: count,
1974
+ max_tokens: count,
1975
+ stopped: picklist(["complete", "budget"]),
1976
+ remaining: conversationBatchStatus,
1977
+ built: optional(conversationBuild)
1978
+ });
1979
+ var conversationBuildResult = union([conversationBuild, conversationPreparation, analyzedConversation]);
1980
+ var conversationEmbedding = union([chatEmbedding, conversationPreparation]);
1981
+ var conversationChange = union([
1982
+ strictObject({ chat: id, stored: count }),
1983
+ strictObject({ chat: id, cleared: count })
1984
+ ]);
1985
+ var conversationReadiness = strictObject({
1986
+ chat: id,
1987
+ model: text,
1988
+ state: picklist(["ready", "stale", "partial", "words-only", "not-built"]),
1989
+ graph: nullable(strictObject({ built_at: time, rules_version: nullable(count), outdated_rules: boolean() })),
1990
+ pending: strictObject({ new: count, edited: count, deleted: count }),
1991
+ vectors: strictObject({ chunks: count, current: count, stale: count, missing: count })
1992
+ });
1993
+ var conversationEmbeddingStatus = strictObject({
1994
+ chat: id,
1995
+ model: text,
1996
+ chunks: count,
1997
+ embedded: count,
1998
+ left: count,
1999
+ estimate_seconds: nullable(number()),
2000
+ tokens_at_most: count,
2001
+ price_at_most: optional(strictObject({ usd: number(), read: text }))
2002
+ });
2003
+ var summary = strictObject({
2004
+ id,
2005
+ chat_id: id,
2006
+ first_message_id: id,
2007
+ first_at: time,
2008
+ last_at: time,
2009
+ message_count: count,
2010
+ senders: count,
2011
+ built_at: time,
2012
+ algorithm_version: count
2013
+ });
2014
+ var conversationHit = strictObject({
2015
+ source: optional(strictObject({ provider: text, account: id })),
2016
+ locator: optional(reference),
2017
+ summary,
2018
+ chunk: strictObject({ first_message_id: id, last_message_id: id }),
2019
+ score: nullable(number()),
2020
+ matched_in: optional(literal("context")),
2021
+ by: array(picklist(["meaning", "words"])),
2022
+ stale: boolean()
2023
+ });
2024
+
2025
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/counters.js
2026
+ var counters = strictObject({
2027
+ cutoff: time,
2028
+ max_age_ms: milliseconds,
2029
+ /** Pins exactly these messages for `counters refresh --selection`. */
2030
+ selection: strictObject({
2031
+ kind: literal("counter-targets"),
2032
+ version: literal(1),
2033
+ locators: array(reference)
2034
+ }),
2035
+ rows: array(strictObject({ ref: reference, counters: array(counterReading) }))
2036
+ });
2037
+ var counterRefresh = strictObject({
2038
+ dry_run: boolean(),
2039
+ targets: array(reference),
2040
+ counters: array(text),
2041
+ supported: array(text),
2042
+ unsupported: array(text),
2043
+ max_messages: count,
2044
+ time_ms: milliseconds,
2045
+ results: optional(array(strictObject({
2046
+ ref: reference,
2047
+ updated: array(text),
2048
+ missing: array(text),
2049
+ status: text
2050
+ }))),
2051
+ stopped: optional(text),
2052
+ complete: optional(boolean())
2053
+ });
2054
+
2055
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/document.js
2056
+ var document = strictObject({
2057
+ ref: reference,
2058
+ id,
2059
+ title: nullable(text),
2060
+ url: nullable(text),
2061
+ mime: optional(text),
2062
+ size: optional(count),
2063
+ /** When its source last changed it. */
2064
+ source_modified_at: nullable(time),
2065
+ /** When the store last read it; not the source's time. */
2066
+ stored_at: optional(nullable(time)),
2067
+ owners: optional(array(text))
2068
+ });
2069
+
2070
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/document-link.js
2071
+ var documentLink = strictObject({
2072
+ ref: reference,
2073
+ url: text,
2074
+ document_id: nullable(id),
2075
+ title: nullable(text),
2076
+ in_store: boolean(),
2077
+ sent_at: time,
2078
+ sender: strictObject({ id: nullable(id), name: nullable(text) })
2079
+ });
2080
+
2081
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/evidence.js
2082
+ var evidenceMessage = pick(message, ["ref", "chat_title", "timestamp", "sender_name", "text"]);
2083
+ var contribution = strictObject({
2084
+ message: evidenceMessage,
2085
+ related: optional(evidenceMessage),
2086
+ contribution: nullable(number()),
2087
+ counters: optional(array(counterReading))
2088
+ });
2089
+ var retentionStay = strictObject({
2090
+ person_ref: reference,
2091
+ joined_at: time,
2092
+ cohort: text,
2093
+ checkpoints: array(strictObject({
2094
+ checkpoint_ms: milliseconds,
2095
+ target_at: time,
2096
+ state: text,
2097
+ observed_at: nullable(time),
2098
+ lag_ms: nullable(milliseconds),
2099
+ complete: boolean()
2100
+ })),
2101
+ activity: strictObject({
2102
+ state: text,
2103
+ first_message_at: nullable(time),
2104
+ window_end: nullable(time),
2105
+ archive_covered: boolean()
2106
+ }),
2107
+ departure: strictObject({ after: nullable(time), at_or_before: nullable(time), early: text })
2108
+ });
2109
+ var evidence = union([contribution, retentionStay]);
2110
+
2111
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/fact.js
2112
+ var fact = strictObject({
2113
+ ref: reference,
2114
+ id,
2115
+ kind: picklist(FACT_TYPES),
2116
+ text,
2117
+ status: picklist(FACT_STATUSES),
2118
+ project: nullable(text),
2119
+ subject: nullable(reference),
2120
+ occurred_at: nullable(time),
2121
+ supersedes: nullable(reference),
2122
+ author,
2123
+ model: nullable(text),
2124
+ /** Who accepted it; `null` while it is proposed. */
2125
+ confirmed_by: optional(nullable(strictObject({ type: picklist(["person", "bot"]), id }))),
2126
+ scope: nullable(picklist(MEMORY_SCOPES)),
2127
+ /** Who recorded it: the owner, or an agent whose fact waits as proposed. */
2128
+ origin: picklist(["owner", "agent"]),
2129
+ evidence: array(reference),
2130
+ created_at: time,
2131
+ updated_at: time
2132
+ });
2133
+
2134
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/hit.js
2135
+ var hit = strictObject({
2136
+ kind: picklist(["message", "mail", "note", "document", "event", "meeting"]),
2137
+ ref: reference,
2138
+ provider: text,
2139
+ url: optional(text),
2140
+ /** The account it was found in; a note's folder id, or `internal` for a note written in memo. */
2141
+ account: text,
2142
+ /** The chat, the mail thread's subject, the note's, the event's or the meeting's title. */
2143
+ title: nullable(text),
2144
+ /** Null for a meeting whose start is unknown. */
2145
+ timestamp: nullable(time),
2146
+ excerpt: text,
2147
+ sender_name: optional(nullable(text)),
2148
+ /** The writer's `person:` reference, where the store has one. */
2149
+ sender_ref: optional(nullable(reference)),
2150
+ found_by: optional(array(picklist(["title", "words", "meaning"]))),
2151
+ /** How far into the meeting the passage is. */
2152
+ offset_ms: optional(nullable(count)),
2153
+ /** A meeting passage's place: its transcript, chat or summary. */
2154
+ scope: optional(picklist(["transcript", "chat", "summary"])),
2155
+ /** A meeting passage's stored line, so two passages of one meeting stay apart; `search meetings` gives the same. */
2156
+ id: optional(pipe(string(), minLength(1))),
2157
+ /** Absent on a note hit: the owner wrote it. */
2158
+ untrusted
2159
+ });
2160
+
2161
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/identity.js
2162
+ var identity = strictObject({
2163
+ ref: reference,
2164
+ provider: text,
2165
+ account: text,
2166
+ /** The messenger's own id for them. */
2167
+ id,
2168
+ name: nullable(text),
2169
+ username: nullable(text),
2170
+ /** The `person:` they are linked to, when one is. */
2171
+ person: optional(nullable(reference))
2172
+ });
2173
+
2174
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/image-embedding.js
2175
+ var imageEmbedding = strictObject({
2176
+ model: text,
2177
+ embedded: count,
2178
+ skipped: count,
2179
+ failed: count,
2180
+ more: boolean()
2181
+ });
2182
+
2183
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/join-request.js
2184
+ var joinRequest = strictObject({
2185
+ person_id: id,
2186
+ name: nullable(text),
2187
+ username: nullable(text),
2188
+ /** `null` where the messenger does not say. */
2189
+ requested_at: nullable(time),
2190
+ /** The note they sent with the request. */
2191
+ about: optional(text)
2192
+ });
2193
+
2194
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/poll-vote.js
2195
+ var pollVote = strictObject({
2196
+ person_id: id,
2197
+ name: nullable(text),
2198
+ username: nullable(text),
2199
+ /** Answer ids, as `polls show` prints them. */
2200
+ answers: array(id),
2201
+ voted_at: time
2202
+ });
2203
+
2204
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/listener.js
2205
+ var reactions = unwrap(unwrap(message.entries.reactions));
2206
+ var observation = strictObject({
2207
+ value: pipe(number(), minValue(0)),
2208
+ observed_at: time,
2209
+ source: picklist(["remote_fetch", "remote_update"]),
2210
+ reactions: optional(reactions)
2211
+ });
2212
+ var watchedMessage = strictObject({
2213
+ ...message.entries,
2214
+ starred: optional(boolean()),
2215
+ counter_observations: optional(partial(strictObject({ views: observation, reactions: observation, comments: observation })))
2216
+ });
2217
+ var target = { chat_id: id, chat_title: nullable(text), message_id: id };
2218
+ var messageEvent = variant("event", [
2219
+ strictObject({ event: picklist(["message", "edit"]), message: watchedMessage }),
2220
+ strictObject({ event: literal("delete"), ...target, chat_id: nullable(id) }),
2221
+ strictObject({ event: literal("reaction"), ...target, reactions, counter_observation: optional(observation) }),
2222
+ strictObject({ event: literal("vote"), ...target, vote: pollVote }),
2223
+ strictObject({
2224
+ event: literal("person_reaction"),
2225
+ ...target,
2226
+ reaction: strictObject({ person: member, own: boolean(), reaction: nullable(text), reacted_at: time })
2227
+ }),
2228
+ strictObject({ event: literal("star"), ...target, starred: boolean() }),
2229
+ strictObject({ event: literal("delivery"), ...target, delivery: unwrap(message.entries.delivery), at: time }),
2230
+ strictObject({ event: literal("chat_event"), chat_id: id, chat_title: nullable(text), change: chatEvent })
2231
+ ]);
2232
+ var watchItem = union([watchedMessage, messageEvent]);
2233
+ var totals = record(text, count);
2234
+ var serveSummary = strictObject({
2235
+ profile: text,
2236
+ started_at: time,
2237
+ stopped_at: time,
2238
+ kept: totals,
2239
+ replies: optional(strictObject({ sent: totals, skipped: totals, tasks: optional(totals) })),
2240
+ members: optional(strictObject({ fetched: count, failed: count })),
2241
+ stems: optional(strictObject({ stemmed: count })),
2242
+ tasks: optional(strictObject({ added: count, closed: count, review: count }))
2243
+ });
2244
+
2245
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/media-archive.js
2246
+ var mediaArchive = strictObject({
2247
+ directory: text,
2248
+ chats: count,
2249
+ saved: count,
2250
+ existing: count,
2251
+ complete: boolean()
2252
+ });
2253
+ var mediaArchiveCheck = strictObject({
2254
+ valid: boolean(),
2255
+ checked: count,
2256
+ files: array(strictObject({ path: text, valid: boolean(), archive_directory: optional(text) }))
2257
+ });
2258
+ var mediaArchiveMove = strictObject({
2259
+ directory: text,
2260
+ archive_directory: text,
2261
+ before_time: time,
2262
+ selected: count,
2263
+ selected_bytes: count,
2264
+ moved: count,
2265
+ moved_bytes: count,
2266
+ already_archived: count,
2267
+ undated: count,
2268
+ complete: boolean(),
2269
+ dry_run: boolean()
2270
+ });
2271
+ var timer = { name: text, installed: boolean(), service_path: text, timer_path: text };
2272
+ var mediaArchiveTimer = union([
2273
+ strictObject({ ...timer, active: boolean() }),
2274
+ strictObject({ ...timer, action: picklist(["install", "start", "stop", "uninstall"]) })
2275
+ ]);
2276
+
2277
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-evidence.js
2278
+ var meetingEvidence = preparationEvidence;
2279
+ var meetingPersonContext = strictObject({
2280
+ person: strictObject({ uid: string(), name: nullable(string()) }),
2281
+ items: array(strictObject({
2282
+ ref: reference,
2283
+ cues: array(preparationCue),
2284
+ cue_coverage: strictObject({ included: preparationCount, omitted: nullable(preparationCount), has_more: boolean() })
2285
+ })),
2286
+ limits: strictObject({ meetings: preparationCount, cues: preparationCount, bytes: preparationCount, scan_limit: preparationCount }),
2287
+ content_bytes: preparationCount,
2288
+ coverage: strictObject({
2289
+ involvements_scanned: preparationCount,
2290
+ scan_limit_reached: boolean(),
2291
+ pending: preparationCount,
2292
+ truncated_by: nullable(picklist(["meetings", "bytes"])),
2293
+ skipped_unavailable: preparationCount,
2294
+ complete: literal(false),
2295
+ input: literal("bounded-meeting-pages")
2296
+ })
2297
+ });
2298
+
2299
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-findings.js
2300
+ var evidence2 = strictObject({ reference, fingerprint: text });
2301
+ var base = { id, project: reference, evidence: array(evidence2) };
2302
+ var finding = variant("kind", [
2303
+ strictObject({ ...base, kind: literal("fact"), type: picklist(FACT_TYPES), statement: text }),
2304
+ strictObject({
2305
+ ...base,
2306
+ kind: literal("task"),
2307
+ type: picklist(WORK_TASK_TYPES),
2308
+ title: text,
2309
+ reason: text,
2310
+ commitment: picklist(["explicit", "inferred"]),
2311
+ due_at: optional(time),
2312
+ due_evidence: optional(array(reference)),
2313
+ assignee: optional(reference),
2314
+ assignee_evidence: optional(array(reference))
2315
+ })
2316
+ ]);
2317
+ var outcome = strictObject({
2318
+ id,
2319
+ fingerprint: text,
2320
+ status: picklist(["accepted", "rejected"]),
2321
+ reference: nullable(reference),
2322
+ reused: boolean()
2323
+ });
2324
+ var meetingFindings = strictObject({
2325
+ id,
2326
+ account: strictObject({ provider: text, account: text }),
2327
+ input: strictObject({ schema_version: literal(1), key: text, extractor: text, findings: array(finding) }),
2328
+ fingerprint: text,
2329
+ status: picklist(["proposed", "reviewed"]),
2330
+ author,
2331
+ decided_by: nullable(strictObject({ type: picklist(["person", "bot"]), id })),
2332
+ decided_at: nullable(time),
2333
+ previous: array(outcome),
2334
+ receipt: nullable(strictObject({ preview_fingerprint: text, accepted: array(id), items: array(outcome) }))
2335
+ });
2336
+
2337
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/meeting-task-proposal.js
2338
+ var text4 = string();
2339
+ var id5 = pipe(number(), integer(), minValue(1));
2340
+ var revision = picklist(["current", "superseded"]);
2341
+ var meetingTaskProposal = strictObject({
2342
+ id: text4,
2343
+ source: reference,
2344
+ source_kind: literal("meeting"),
2345
+ group: reference,
2346
+ account_id: id5,
2347
+ kind: picklist(TASK_KINDS),
2348
+ preview: nullable(text4),
2349
+ revision: nullable(revision),
2350
+ applied: literal(false),
2351
+ persistence: literal("proposal-only")
2352
+ });
2353
+
2354
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/memory.js
2355
+ var memory = strictObject({
2356
+ ref: reference,
2357
+ id,
2358
+ kind: picklist(MEMORY_KINDS),
2359
+ text,
2360
+ subject: nullable(reference),
2361
+ author,
2362
+ model: nullable(text),
2363
+ confidence: nullable(number()),
2364
+ status: picklist(MEMORY_STATUSES),
2365
+ scope: picklist(MEMORY_SCOPES),
2366
+ supersedes: nullable(reference),
2367
+ evidence: array(reference),
2368
+ last_verified_at: nullable(time),
2369
+ created_at: time,
2370
+ updated_at: time
2371
+ });
2372
+
2373
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/mention.js
2374
+ var kind = picklist(["phone", "email", "url", "document", "person-name", "place"]);
2375
+ var status = picklist(["found", "linked", "dismissed"]);
2376
+ var mention = strictObject({
2377
+ id: count,
2378
+ kind,
2379
+ value: text,
2380
+ domain: nullable(text),
2381
+ confidence: number(),
2382
+ status,
2383
+ field: text,
2384
+ author: nullable(text),
2385
+ target: nullable(reference),
2386
+ sent_at: time,
2387
+ found_at: time,
2388
+ written: text,
2389
+ locator: reference
2390
+ });
2391
+ var mentionDetails = strictObject({
2392
+ ...mention.entries,
2393
+ before: text,
2394
+ after: text,
2395
+ same_value: count,
2396
+ candidates: array(reference)
2397
+ });
2398
+ var mentionDomain = strictObject({ domain: text, links: count, chats: count, first_at: time, last_at: time });
2399
+ var place = strictObject({ id: count, address: text, mentions: count });
2400
+ var mentionDecision = strictObject({
2401
+ kind,
2402
+ value: text,
2403
+ status,
2404
+ target: nullable(reference),
2405
+ mentions: count
2406
+ });
2407
+ var mentionRebuild = strictObject({
2408
+ messages: count,
2409
+ attachments: count,
2410
+ documents: count,
2411
+ notes: count,
2412
+ emails: count,
2413
+ mentions: count
2414
+ });
2415
+
2416
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-change.js
2417
+ var operated3 = { operation_id: id, chat_id: id };
2418
+ var messagePin = strictObject({ ...operated3, message_id: id, pinned: boolean() });
2419
+ var messageStar = strictObject({ ...operated3, message_id: id, starred: boolean() });
2420
+ var messageDeletion = strictObject({ ...operated3, deleted: array(id), for_everyone: boolean() });
2421
+
2422
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-read.js
2423
+ var messageTranscript = strictObject({
2424
+ message_id: id,
2425
+ text,
2426
+ pending: boolean(),
2427
+ via: text,
2428
+ model: optional(text)
2429
+ });
2430
+ var conversationLink = strictObject({
2431
+ parent_id: nullable(id),
2432
+ source: picklist(["provider", "rule", "agent"]),
2433
+ kind: text,
2434
+ confidence: number(),
2435
+ method: text,
2436
+ version: nullable(text),
2437
+ created_at: time,
2438
+ stale: boolean(),
2439
+ chosen: boolean()
2440
+ });
2441
+ var messageLinks = strictObject({
2442
+ chat: id,
2443
+ message: id,
2444
+ links: array(conversationLink),
2445
+ chain: array(id)
2446
+ });
2447
+ var fingerprint2 = pipe(text, regex(/^[a-f0-9]{64}$/));
2448
+ var evidencePacket = strictObject({
2449
+ schema_version: literal(1),
2450
+ id,
2451
+ kind: picklist(["chats", "news", "person"]),
2452
+ source: strictObject({ provider: text, account: id, chat: id }),
2453
+ fingerprint: fingerprint2,
2454
+ limits: strictObject({ messages: count, bytes: count }),
2455
+ content_bytes: count,
2456
+ coverage: strictObject({
2457
+ provided: count,
2458
+ included: count,
2459
+ omitted: count,
2460
+ has_more: boolean(),
2461
+ history: literal("unknown"),
2462
+ truncated_by: nullable(picklist(["messages", "bytes"]))
2463
+ }),
2464
+ items: array(strictObject({
2465
+ locator: reference,
2466
+ fingerprint: fingerprint2,
2467
+ timestamp: time,
2468
+ edited_at: nullable(time),
2469
+ sender_id: nullable(id),
2470
+ sender_name: nullable(text),
2471
+ sender_is_chat: boolean(),
2472
+ outgoing: nullable(boolean()),
2473
+ text,
2474
+ reply_to: nullable(reference),
2475
+ thread_id: nullable(id),
2476
+ attachment_kinds: array(text)
2477
+ }))
2478
+ });
2479
+
2480
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-context.js
2481
+ var messageThread = strictObject({
2482
+ ref: reference,
2483
+ chat: id,
2484
+ message: id,
2485
+ mode: picklist(["thread", "time"]),
2486
+ fallback: optional(picklist(["not_built", "not_stored", "not_linked"])),
2487
+ items: array(message),
2488
+ links: array(strictObject({ ...conversationLink.entries, message_id: id })),
2489
+ chain: array(id),
2490
+ stale: boolean(),
2491
+ built_at: nullable(time),
2492
+ stopped: array(picklist(["hops", "messages", "bytes", "time", "links", "cycle", "aborted", "thread"])),
2493
+ bounds: strictObject({ max_hops: count, max_messages: count, max_bytes: count, within_ms: count })
2494
+ });
2495
+ var messageContext = union([message, messageThread]);
2496
+
2497
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-counts.js
2498
+ var messageCounts = strictObject({
2499
+ by: picklist(["chat", "sender", "day", "hour"]),
2500
+ total: count,
2501
+ rows: array(strictObject({
2502
+ /** The chat or sender id, or the calendar day or hour. */
2503
+ key: text,
2504
+ ref: optional(reference),
2505
+ name: nullable(text),
2506
+ count
2507
+ }))
2508
+ });
2509
+
2510
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-link.js
2511
+ var messageLink = strictObject({
2512
+ ref: reference,
2513
+ url: nullable(text),
2514
+ access: picklist(["public", "restricted", "unknown", "unavailable"]),
2515
+ /** Why there is no link. */
2516
+ reason: nullable(picklist(["unsupported_chat", "unsupported_provider", "offline"]))
2517
+ });
2518
+
2519
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/message-write.js
2520
+ var messageWrite = strictObject({
2521
+ operation_id: id,
2522
+ message,
2523
+ /** An album's messages, in order; `message` is the first. Absent for a single message. */
2524
+ messages: optional(array(message)),
2525
+ scheduled_for: optional(time)
2526
+ });
2527
+ var draftWrite = strictObject({
2528
+ operation_id: id,
2529
+ chat_id: id,
2530
+ saved: literal(true)
2531
+ });
2532
+ var messageSend = union([messageWrite, draftWrite]);
2533
+
2534
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/model.js
2535
+ var model = strictObject({
2536
+ id,
2537
+ kind: picklist(["audio", "text", "image", "reranker"]),
2538
+ title: text,
2539
+ /** Which languages it reads, in words. */
2540
+ languages: text,
2541
+ licence: optional(text),
2542
+ /** What its files take on disk once downloaded. */
2543
+ size_bytes: count,
2544
+ downloaded: boolean(),
2545
+ /** The one used when no model is named. */
2546
+ default: boolean(),
2547
+ /** The folder its files are in once downloaded, so an agent can place them by hand. */
2548
+ path: text
2549
+ });
2550
+
2551
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/model-key.js
2552
+ var source = picklist(["environment", "keyring", "file"]);
2553
+ var modelKey = strictObject({
2554
+ provider: text,
2555
+ stored: optional(source),
2556
+ removed: optional(array(source))
2557
+ });
2558
+ var storedModelKey = strictObject({ ...omit(modelKey, ["removed"]).entries, stored: source });
2559
+ var removedModelKey = strictObject({ ...omit(modelKey, ["stored"]).entries, removed: array(source) });
2560
+
2561
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/official-stats.js
2562
+ var versus = strictObject({ current: number(), previous: number() });
2563
+ var person = { person_ref: reference, name: nullable(text) };
2564
+ var graph = strictObject({
2565
+ kind: text,
2566
+ x: strictObject({ type: picklist(["date", "time", "number"]), values: array(union([text, number()])) }),
2567
+ series: array(strictObject({ key: text, name: text, kind: text, values: array(number()) })),
2568
+ stacked: optional(boolean()),
2569
+ percentage: optional(boolean())
2570
+ });
2571
+ var officialStats = strictObject({
2572
+ chat_id: id,
2573
+ title: text,
2574
+ kind: picklist(["group", "channel"]),
2575
+ since: time,
2576
+ until: time,
2577
+ totals: record(string(), versus),
2578
+ top: optional(strictObject({
2579
+ posters: array(strictObject({ ...person, messages: count, average_chars: number() })),
2580
+ admins: array(strictObject({ ...person, deleted: count, removed: count, banned: count })),
2581
+ inviters: array(strictObject({ ...person, invited: count }))
2582
+ })),
2583
+ notifications: optional(strictObject({ enabled: count, total: count })),
2584
+ recent_posts: optional(array(strictObject({
2585
+ kind: picklist(["message", "story"]),
2586
+ id,
2587
+ views: count,
2588
+ forwards: count,
2589
+ reactions: count
2590
+ }))),
2591
+ /** A graph the messenger did not give is `{ error }`; the others still answer. */
2592
+ graphs: record(string(), union([graph, strictObject({ error: text })]))
2593
+ });
2594
+
2595
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/person.js
2596
+ var person2 = strictObject({
2597
+ ref: reference,
2598
+ name: nullable(text),
2599
+ identities: optional(array(identity))
2600
+ });
2601
+
2602
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/poll.js
2603
+ var poll = strictObject({
2604
+ chat_id: id,
2605
+ message_id: id,
2606
+ question: text,
2607
+ answers: array(strictObject({ id, text, voters: nullable(count), chosen: boolean() })),
2608
+ closed: boolean(),
2609
+ multiple: boolean(),
2610
+ anonymous: boolean(),
2611
+ voters: nullable(count),
2612
+ quiz: optional(boolean()),
2613
+ revote: optional(boolean()),
2614
+ creator: optional(boolean())
2615
+ });
2616
+ var pollChange = strictObject({ operation_id: id, poll });
2617
+
2618
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/private-contact.js
2619
+ var contactAlias = strictObject({ person_id: id, alias: nullable(text) });
2620
+ var contactNoteRemoval = strictObject({ id, person_id: id, removed: boolean() });
2621
+
2622
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/ranking.js
2623
+ var figures = record(string(), number());
2624
+ var freshness = picklist(["fresh", "stale", "partial", "unknown"]);
2625
+ var rankingRow = strictObject({
2626
+ rank: count,
2627
+ /** The message's locator, or the author's `contact:` reference. */
2628
+ ref: reference,
2629
+ /** The message or person id, as `stats * evidence` takes it. */
2630
+ id,
2631
+ chat_ref: optional(reference),
2632
+ name: nullable(text),
2633
+ /** A message's kind (`posts`, `comments`); null for authors. */
2634
+ kind: nullable(text),
2635
+ value: number(),
2636
+ components: record(string(), nullable(number())),
2637
+ messages: count,
2638
+ known_reactions: count,
2639
+ unknown_reactions: count,
2640
+ reactions: optional(array(strictObject({ reaction: string(), count }))),
2641
+ score: nullable(strictObject({ score: number(), normalized: figures, contributions: figures })),
2642
+ quality: strictObject({
2643
+ reactions: picklist(["known", "partial", "unknown"]),
2644
+ graph: picklist(["complete", "partial", "not_used"]),
2645
+ counter_freshness: freshness
2646
+ }),
2647
+ counters: optional(array(counterReading)),
2648
+ selection
2649
+ });
2650
+ var ranking = strictObject({
2651
+ target: picklist(["messages", "contacts"]),
2652
+ measure: text,
2653
+ order: picklist(["ascending", "descending"]),
2654
+ preset: nullable(text),
2655
+ weights: nullable(figures),
2656
+ min_messages: count,
2657
+ message_kind: text,
2658
+ /** Messages the query selected. */
2659
+ total: count,
2660
+ population: count,
2661
+ eligible: count,
2662
+ excluded: strictObject({ minimum: count, missing: count, unknown_sender: count, unknown_kind: count }),
2663
+ maxima: figures,
2664
+ counter_freshness: freshness,
2665
+ expanded_discussion_chats: optional(array(text)),
2666
+ rows: array(rankingRow)
2667
+ });
2668
+
2669
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/reaction-change.js
2670
+ var reactionChange = strictObject({
2671
+ operation_id: id,
2672
+ chat_id: id,
2673
+ message_id: id,
2674
+ reaction: nullable(text)
2675
+ });
2676
+
2677
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/recipient.js
2678
+ var recipient = strictObject({ id, title: nullable(text), partner_id: optional(id), added_at: time });
2679
+ var recipientAdded = strictObject({ id, title: nullable(text), added: boolean() });
2680
+ var recipientRemoved = strictObject({ id, title: nullable(text), removed: boolean() });
2681
+ var recipientOff = strictObject({ off: boolean(), was_on: boolean() });
2682
+ var recipientChange = strictObject({
2683
+ ...partial(recipientAdded).entries,
2684
+ ...partial(recipientRemoved).entries,
2685
+ ...partial(recipientOff).entries
2686
+ });
2687
+
2688
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/recorded-run.js
2689
+ var events = array(record(string(), unknown()));
2690
+ var recordedRun = strictObject({
2691
+ run_id: id,
2692
+ command: text,
2693
+ profile: optional(text),
2694
+ started_at: time,
2695
+ completed_at: optional(time),
2696
+ status: picklist(["success", "failed", "partial", "running"]),
2697
+ requests: optional(count),
2698
+ duration_ms: optional(count),
2699
+ cli_version: text,
2700
+ runtime: optional(text),
2701
+ platform: optional(text),
2702
+ arch: optional(text),
2703
+ error_code: optional(text),
2704
+ partial: optional(strictObject({
2705
+ failed: count,
2706
+ stop_reason: optional(text),
2707
+ failures: array(strictObject({ id: text, stage: text, error_code: text, attachment: optional(count) }))
2708
+ })),
2709
+ provider_error: optional(text),
2710
+ kept_because_failed: optional(boolean()),
2711
+ operations: optional(array(text)),
2712
+ codes: optional(array(text)),
2713
+ trace_id: optional(id),
2714
+ cli_command: optional(text),
2715
+ argv: optional(array(text)),
2716
+ unknown_command: optional(text),
2717
+ agent: optional(strictObject({
2718
+ kind: text,
2719
+ session_id: nullable(text),
2720
+ from_chat: optional(literal(true)),
2721
+ client: optional(strictObject({ name: text, version: optional(text), id: optional(text) }))
2722
+ })),
2723
+ via: optional(picklist(["cli", "mcp-stdio", "mcp-http", "desktop"])),
2724
+ mcp: optional(strictObject({
2725
+ tool: text,
2726
+ request_id: optional(text),
2727
+ connection_id: optional(text),
2728
+ proxied: optional(literal(true))
2729
+ })),
2730
+ events_dropped: optional(count),
2731
+ error: optional(strictObject({
2732
+ class: text,
2733
+ code: optional(text),
2734
+ reason: optional(text),
2735
+ message: optional(text),
2736
+ operation: optional(text),
2737
+ http: optional(strictObject({ method: optional(text), endpoint_template: optional(text), status: optional(count) })),
2738
+ provider: optional(strictObject({ key: optional(text), code: optional(number()) })),
2739
+ causes: optional(array(strictObject({ class: text, message: optional(text) }))),
2740
+ stack: optional(array(text))
2741
+ })),
2742
+ directory: optional(text),
2743
+ event_count: optional(count),
2744
+ events: optional(events),
2745
+ events_truncated: optional(boolean())
2746
+ });
2747
+ var runDetails = strictObject({
2748
+ ...omit(recordedRun, ["events_truncated"]).entries,
2749
+ directory: text,
2750
+ event_count: count,
2751
+ events
2752
+ });
2753
+ var runHit = strictObject({
2754
+ ...omit(recordedRun, ["directory", "event_count"]).entries,
2755
+ events,
2756
+ events_truncated: boolean()
2757
+ });
2758
+ var runLocation = strictObject({ path: text });
2759
+
2760
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/relationship.js
2761
+ var relationship = strictObject({
2762
+ id,
2763
+ from: reference,
2764
+ to: reference,
2765
+ kind: picklist(RELATION_KINDS),
2766
+ role: nullable(text),
2767
+ evidence: nullable(text),
2768
+ /** An agent's suggestion stays unconfirmed, and `weak`, until the owner confirms it. */
2769
+ confirmed: boolean(),
2770
+ provenance: nullable(text),
2771
+ confidence_category: picklist(["owner-confirmed", "weak"]),
2772
+ created_at: time
2773
+ });
2774
+
2775
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/retention.js
2776
+ var retentionCohort = strictObject({
2777
+ /** The first day of the joining day or week. */
2778
+ cohort: text,
2779
+ stays: count,
2780
+ checkpoints: array(strictObject({
2781
+ age_ms: milliseconds,
2782
+ eligible: count,
2783
+ observable: count,
2784
+ present: count,
2785
+ absent: count,
2786
+ unknown: count,
2787
+ pending: count,
2788
+ rate: nullable(number())
2789
+ })),
2790
+ activity: strictObject({ observed: count, no_observed: count, pending: count, archive_covered: count }),
2791
+ early_departure: strictObject({ observed: count, not_observed: count, unknown: count, pending: count }),
2792
+ selection
2793
+ });
2794
+ var retention = strictObject({
2795
+ chat_ref: reference,
2796
+ cutoff: time,
2797
+ since: time,
2798
+ until: time,
2799
+ checkpoints_ms: array(milliseconds),
2800
+ within_ms: milliseconds,
2801
+ by: picklist(["day", "week"]),
2802
+ timezone: text,
2803
+ /** Cohorts found; `rows` holds the first `--limit` of them. */
2804
+ total: count,
2805
+ unknown_join: count,
2806
+ eligible_stays: count,
2807
+ quality: strictObject({
2808
+ membership: text,
2809
+ tolerance_ms: milliseconds,
2810
+ archive: nullable(strictObject({
2811
+ state: text,
2812
+ up_to_date: nullable(boolean()),
2813
+ gaps: boolean(),
2814
+ reaches_start: boolean(),
2815
+ fetched_at: nullable(time)
2816
+ })),
2817
+ continuous_survival: boolean(),
2818
+ group_silent_rate: nullable(number())
2819
+ }),
2820
+ rows: array(retentionCohort)
2821
+ });
2822
+
2823
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/send-attempt.js
2824
+ var sendAttempt = strictObject({
2825
+ at: time,
2826
+ profile: text,
2827
+ chat_id: nullable(id),
2828
+ outcome: picklist(["sent", "outcome_unknown", "refused", "failed", "reserved"]),
2829
+ kind: optional(picklist(["message", "reaction", "edit", "forward", "pin", "read", "delete", "chat", "account"])),
2830
+ action: optional(text),
2831
+ people: optional(count),
2832
+ message_id: optional(id),
2833
+ key: optional(text),
2834
+ count: optional(count),
2835
+ for_everyone: optional(boolean()),
2836
+ operation_id: optional(id),
2837
+ parent_operation_id: optional(id),
2838
+ reply_to: optional(id),
2839
+ thread_id: optional(id),
2840
+ send_as: optional(id),
2841
+ result_chat_id: optional(id),
2842
+ length: optional(count),
2843
+ attachments: optional(array(strictObject({ kind: picklist(["photo", "file", "video", "voice", "sticker"]), bytes: count }))),
2844
+ scheduled_for: optional(time),
2845
+ notify: optional(boolean()),
2846
+ origin: optional(text),
2847
+ reservation: optional(id),
2848
+ error_code: optional(text)
2849
+ });
2850
+
2851
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/store-maintenance.js
2852
+ var absent = strictObject({ path: text, exists: literal(false) });
2853
+ var schema = strictObject({ version: count, min_compatible: count, writable: boolean(), speaks: count });
2854
+ var infoSchema = strictObject({
2855
+ ...schema.entries,
2856
+ reason: picklist(["missing", "older", "current", "newer", "too_new"]),
2857
+ upgrade: nullable(strictObject({ version: count, min_compatible: count }))
2858
+ });
2859
+ var client = strictObject({ command: text, version: text, core: text, speaks: count, seen_at: time });
2860
+ var wordIndex = strictObject({
2861
+ watermark: count,
2862
+ filled_through: count,
2863
+ pending_normalization: count,
2864
+ ready: boolean(),
2865
+ terms_through: count,
2866
+ newest: count,
2867
+ terms_ready: boolean(),
2868
+ built_at: nullable(time)
2869
+ });
2870
+ var stemIndex = strictObject({
2871
+ watermark: count,
2872
+ filled_through: count,
2873
+ pending: count,
2874
+ built: nullable(text),
2875
+ wanted: text,
2876
+ ready: boolean(),
2877
+ cause: optional(picklist(["building", "stemmer_changed", "stemmer_unknown"])),
2878
+ built_at: nullable(time)
2879
+ });
2880
+ var readFailure = { path: text, exists: literal(true), opens: literal(false), error: text };
2881
+ var rows = partial(strictObject({
2882
+ accounts: count,
2883
+ chats: count,
2884
+ messages: count,
2885
+ emails: count,
2886
+ documents: count,
2887
+ meetings: count,
2888
+ events: count,
2889
+ attachments: count,
2890
+ identities: count
2891
+ }));
2892
+ var perAccount = { chats: count, messages: count, emails: count, documents: count, meetings: count };
2893
+ var contents = {
2894
+ by_provider: optional(array(strictObject({ provider: text, accounts: count, ...perAccount }))),
2895
+ by_chat_kind: optional(array(strictObject({ provider: text, kind: text, chats: count, messages: count }))),
2896
+ /** `name` is the one `account list` shows; the messenger's own id for the account is left out. */
2897
+ by_account: optional(array(strictObject({ provider: text, account_id: count, name: nullable(text), ...perAccount }))),
2898
+ /** Calendar years in UTC. */
2899
+ by_year: optional(array(strictObject({ provider: text, year: count, messages: count }))),
2900
+ /** `type` is what the file is attached to: a message, an email, a document… `bytes` counts the sizes known. */
2901
+ by_attachment_kind: optional(array(strictObject({ type: text, kind: text, count, bytes: count })))
2902
+ };
2903
+ var storeInfo = union([
2904
+ strictObject({ ...absent.entries, schema: infoSchema }),
2905
+ strictObject({ ...readFailure, schema: strictObject({ speaks: count }) }),
2906
+ strictObject({
2907
+ path: text,
2908
+ exists: literal(true),
2909
+ bytes: strictObject({ file: count, wal: count }),
2910
+ journal_mode: text,
2911
+ /** `free` pages hold nothing; a `VACUUM` would give them back. */
2912
+ pages: strictObject({ size: count, count, free: count }),
2913
+ migrations: array(strictObject({ version: count, min_compatible: count, applied_at: time })),
2914
+ /** From the marker a backup job leaves in `backups/last.json` beside the store; null without one. */
2915
+ backup: nullable(strictObject({ at: time, file: nullable(text), checked: nullable(text) })),
2916
+ schema: infoSchema,
2917
+ clients: array(client),
2918
+ rows,
2919
+ pending_normalization: nullable(count),
2920
+ word_index: nullable(wordIndex),
2921
+ stem_index: nullable(stemIndex),
2922
+ ...contents
2923
+ })
2924
+ ]);
2925
+ var storeCheck = union([
2926
+ strictObject({ ...absent.entries, ok: literal(true) }),
2927
+ strictObject({ ...readFailure, ok: literal(false) }),
2928
+ strictObject({
2929
+ path: text,
2930
+ exists: literal(true),
2931
+ opens: literal(true),
2932
+ ok: boolean(),
2933
+ checks: strictObject({
2934
+ schema: boolean(),
2935
+ integrity: boolean(),
2936
+ foreign_keys: boolean(),
2937
+ search_indexes: boolean(),
2938
+ vector_indexes: boolean(),
2939
+ disk: boolean()
2940
+ }),
2941
+ schema,
2942
+ integrity: array(text),
2943
+ foreign_key_violations: count,
2944
+ search_indexes: record(text, text),
2945
+ disk: strictObject({ free: count, needed: count }),
2946
+ pending_normalization: nullable(count),
2947
+ word_index: nullable(wordIndex),
2948
+ stem_index: nullable(stemIndex),
2949
+ chats_behind: array(strictObject({
2950
+ provider: text,
2951
+ account: text,
2952
+ chat: text,
2953
+ title: nullable(text),
2954
+ newest: time,
2955
+ held: nullable(time),
2956
+ refreshed: time
2957
+ })),
2958
+ orphan_pointers: array(strictObject({ table: text, pointer: text, type: text, count, known: boolean() })),
2959
+ conversations: array(strictObject({
2960
+ provider: text,
2961
+ account: text,
2962
+ chat: text,
2963
+ title: nullable(text),
2964
+ built_at: nullable(time),
2965
+ rules_version: nullable(count),
2966
+ current: boolean(),
2967
+ stale_agent_links: count
2968
+ })),
2969
+ vectors: nullable(strictObject({ models: record(text, count), unused: count })),
2970
+ vector_indexes: array(strictObject({
2971
+ model: text,
2972
+ dims: count,
2973
+ ready: boolean(),
2974
+ indexed: count,
2975
+ expected: count,
2976
+ missing: count,
2977
+ extra: count
2978
+ }))
2979
+ })
2980
+ ]);
2981
+ var indexed = { normalized: count, indexed: count, terms: count, stemmed: count, notes_indexed: count };
2982
+ var storeMigration = union([
2983
+ absent,
2984
+ strictObject({ path: text, exists: literal(true), from: count, to: count, ...indexed })
2985
+ ]);
2986
+ var storeReindex = union([
2987
+ absent,
2988
+ strictObject({
2989
+ path: text,
2990
+ exists: literal(true),
2991
+ ...indexed,
2992
+ file_texts: count,
2993
+ involvements: count,
2994
+ unused_vectors_dropped: count
2995
+ })
2996
+ ]);
2997
+ var storeBackup = strictObject({
2998
+ path: text,
2999
+ from: text,
3000
+ bytes: count,
3001
+ schema: count,
3002
+ rows: strictObject({ chats: count, messages: count }),
3003
+ encrypted: optional(literal(true))
3004
+ });
3005
+ var storeDecrypt = strictObject({ path: text, from: text, bytes: count });
3006
+ var storeRestore = strictObject({
3007
+ path: text,
3008
+ restored_from: text,
3009
+ kept_at: nullable(text),
3010
+ schema: count
3011
+ });
3012
+ var storeReset = union([
3013
+ strictObject({ ...absent.entries, reset: literal(false) }),
3014
+ strictObject({
3015
+ path: text,
3016
+ exists: literal(true),
3017
+ reset: literal(false),
3018
+ dry_run: literal(true),
3019
+ files: array(text),
3020
+ bytes: count,
3021
+ schema: count,
3022
+ tables: array(strictObject({ name: text, rows: count })),
3023
+ backup_first: boolean(),
3024
+ in_use: nullable(boolean())
3025
+ }),
3026
+ strictObject({
3027
+ path: text,
3028
+ exists: literal(true),
3029
+ reset: literal(true),
3030
+ backup: nullable(text),
3031
+ backed_up: nullable(strictObject({ schema: count, rows: partial(strictObject({ chats: count, messages: count })) })),
3032
+ schema: count
3033
+ })
3034
+ ]);
3035
+ var storeRepair = union([
3036
+ absent,
3037
+ strictObject({
3038
+ path: text,
3039
+ dry_run: boolean(),
3040
+ repaired: array(strictObject({
3041
+ table: text,
3042
+ action: picklist(["created", "columns-added", "rebuilt"]),
3043
+ columns_added: optional(array(text)),
3044
+ copy: optional(text),
3045
+ rows_in_copy: optional(count),
3046
+ rows_copied: optional(count),
3047
+ only_in_copy: optional(array(text)),
3048
+ dropped_from_copy: optional(array(text))
3049
+ })),
3050
+ indexes_created: array(text),
3051
+ triggers_created: array(text),
3052
+ mismatches: array(strictObject({ table: text, what: text })),
3053
+ foreign_key_violations: array(strictObject({ table: text, rows: count })),
3054
+ copies: array(strictObject({ name: text, rows: count }))
3055
+ })
3056
+ ]);
3057
+ var storeCopyRemoval = strictObject({ path: text, deleted: strictObject({ name: text, rows: count }) });
3058
+
3059
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/tag-change.js
3060
+ var tagTarget = variant("type", [
3061
+ strictObject({ type: literal("chat"), chat_id: id }),
3062
+ strictObject({ type: literal("contact"), person_id: id }),
3063
+ strictObject({ type: literal("message"), chat_id: id, message_id: id, locator: reference }),
3064
+ strictObject({ type: literal("task"), task_id: id })
3065
+ ]);
3066
+ var receipt = { target: tagTarget, unchanged: array(text) };
3067
+ var tagChange = union([
3068
+ strictObject({ ...receipt, added: array(text) }),
3069
+ strictObject({ ...receipt, removed: array(text) })
3070
+ ]);
3071
+ var automaticTags = strictObject({
3072
+ items: array(union([
3073
+ strictObject({
3074
+ chat_id: id,
3075
+ tags: array(strictObject({
3076
+ tag: text,
3077
+ score: number(),
3078
+ fields: array(picklist(["title", "username", "description"]))
3079
+ })),
3080
+ algorithm: text,
3081
+ fetched_at: nullable(time),
3082
+ source: picklist(["metadata", "stored-chat"])
3083
+ }),
3084
+ strictObject({ chat_id: id, error: strictObject({ code: text, message: text }) })
3085
+ ])),
3086
+ has_more: boolean(),
3087
+ dry_run: boolean()
3088
+ });
3089
+
3090
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/task-pair.js
3091
+ var side = strictObject({ ref: reference, key: text, title: text, status: text });
3092
+ var taskPair = strictObject({
3093
+ task: nullable(side),
3094
+ source: nullable(reference),
3095
+ other: side,
3096
+ score: number(),
3097
+ band: picklist(["likely", "maybe", "different"]),
3098
+ levels: strictObject({
3099
+ text: picklist(["high", "middle", "low"]),
3100
+ person: picklist(["same", "different", "unknown"]),
3101
+ amount: picklist(["equal", "different", "missing"]),
3102
+ category: picklist(["same", "different", "unknown"]),
3103
+ due: picklist(["near", "far", "missing"]),
3104
+ reply: picklist(["yes", "no"]),
3105
+ time: picklist(["near", "weeks", "far"])
3106
+ }),
3107
+ reasons: array(text),
3108
+ decision: picklist(["review", "unsure", "merged", "rejected", "unmerged", "attached", "new"]),
3109
+ decided_at: nullable(time),
3110
+ created_at: time
3111
+ });
3112
+
3113
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/task-results.js
3114
+ var nullableTime = nullable(time);
3115
+ var link = strictObject({
3116
+ id,
3117
+ from: reference,
3118
+ to: nullable(reference),
3119
+ kind: picklist(LINK_KINDS),
3120
+ anchor: nullable(text),
3121
+ origin: picklist(LINK_SOURCES),
3122
+ target_text: nullable(text),
3123
+ role: nullable(text),
3124
+ evidence: nullable(text),
3125
+ provenance: nullable(text),
3126
+ confirmed: boolean(),
3127
+ created_at: time
3128
+ });
3129
+ var taskCard = strictObject({
3130
+ id,
3131
+ ref: reference,
3132
+ key: text,
3133
+ project: reference,
3134
+ title: text,
3135
+ description: nullable(text),
3136
+ type: picklist(TASK_TYPES),
3137
+ status: picklist(TASK_STATES),
3138
+ priority: nullable(number()),
3139
+ parent: nullable(reference),
3140
+ source: nullable(text),
3141
+ due_at: nullableTime,
3142
+ next_check_at: nullableTime,
3143
+ closed_at: nullableTime,
3144
+ reason: nullable(text),
3145
+ verdict: nullable(picklist(TASK_VERDICTS)),
3146
+ category: nullable(text),
3147
+ claimed_by: nullable(text),
3148
+ claimed_until: nullableTime,
3149
+ close_certainty: nullable(number()),
3150
+ close_suggestion: nullable(closeSuggestion),
3151
+ assignments: array(strictObject({ to: reference, role: picklist(["assignee", "reviewer", "watcher"]) })),
3152
+ created_at: time,
3153
+ updated_at: time,
3154
+ links: array(link),
3155
+ linked_from: array(link)
3156
+ });
3157
+ var taskView = strictObject({
3158
+ id,
3159
+ source: text,
3160
+ source_kind: text,
3161
+ account: text,
3162
+ group: text,
3163
+ kind: picklist(TASK_KINDS),
3164
+ state: picklist(TASK_STATES),
3165
+ reason: optional(text),
3166
+ origin: picklist(TASK_ORIGINS),
3167
+ created_at: time,
3168
+ due_at: optional(time),
3169
+ closed_at: optional(time),
3170
+ closed_by: optional(picklist(TASK_ORIGINS)),
3171
+ key: optional(text),
3172
+ category: optional(text),
3173
+ claimed_by: optional(text),
3174
+ claimed_until: optional(time),
3175
+ message: nullable(strictObject({ sender_name: nullable(text), text, timestamp: time })),
3176
+ note: optional(nullable(strictObject({ id, title: nullable(text), text, updated_at: time })))
3177
+ });
3178
+ var taskCreated = strictObject({
3179
+ ...taskView.entries,
3180
+ created: boolean(),
3181
+ attached: optional(literal(true)),
3182
+ review: optional(count),
3183
+ follow_up_of: optional(taskPair.entries.other),
3184
+ card: optional(taskCard)
3185
+ });
3186
+ var taskClosed = strictObject({
3187
+ ...taskView.entries,
3188
+ close_certainty: nullable(number()),
3189
+ close_suggestion: nullable(closeSuggestion)
3190
+ });
3191
+ var taskLinks = union([
3192
+ strictObject({ ...taskCard.entries, review: optional(count) }),
3193
+ strictObject({
3194
+ relations: array(strictObject({
3195
+ id,
3196
+ from: reference,
3197
+ to: reference,
3198
+ kind: picklist(["blocked-by", "follow-up-of", "related-to", "duplicate-of", "discovered-from"])
3199
+ }))
3200
+ })
3201
+ ]);
3202
+ var taskSimilar = strictObject({
3203
+ ref: reference,
3204
+ key: text,
3205
+ title: text,
3206
+ status: text,
3207
+ created_at: time,
3208
+ found_by: array(picklist(["text", "person", "category", "reply"])),
3209
+ score: number(),
3210
+ band: taskPair.entries.band,
3211
+ levels: taskPair.entries.levels,
3212
+ reasons: array(text),
3213
+ text: strictObject({ shared_stems: count, all_stems: count, stems: number(), trigrams: number() })
3214
+ });
3215
+ var taskMerge = strictObject({ pair: taskPair, linked: count, review: count, task: taskCard });
3216
+ var taskUnmerge = strictObject({ pair: taskPair, task: taskCard });
3217
+ var taskCategories = strictObject({
3218
+ categories: array(strictObject({
3219
+ name: text,
3220
+ meaning: text,
3221
+ triggers: strictObject({ en: array(text), ru: array(text), es: array(text) })
3222
+ })),
3223
+ unlisted: array(strictObject({ name: text, open: count, total: count })),
3224
+ file: nullable(text)
3225
+ });
3226
+ var taskScan = strictObject({
3227
+ chat: text,
3228
+ messages: count,
3229
+ added: count,
3230
+ closed: count,
3231
+ review: count,
3232
+ held: optional(count),
3233
+ held_chats: optional(count),
3234
+ tasks: array(strictObject({ source: text, kind: picklist(TASK_KINDS), category: nullable(text) }))
3235
+ });
3236
+
3237
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/topic.js
3238
+ var topic = strictObject({
3239
+ id,
3240
+ title: text,
3241
+ closed: boolean(),
3242
+ pinned: boolean(),
3243
+ /** The General topic only, where the messenger says. */
3244
+ hidden: optional(boolean()),
3245
+ unread_count: nullable(count),
3246
+ last_message_at: nullable(time),
3247
+ created_at: nullable(time),
3248
+ untrusted
3249
+ });
3250
+
3251
+ // node_modules/.pnpm/@wirecat+cli-core@0.469.0_@wirecat+cli-base@0.65.0_commander@15.0.0_typescript@7.0.2_vi_80b586dbc8b099637a6e461856c2ee6b/node_modules/@wirecat/cli-core/dist/entities/index.js
3252
+ var ENTITIES = {
3253
+ sync_progress: progress,
3254
+ ...MEETING_RESULT_ENTITIES,
3255
+ message,
3256
+ message_context: messageContext,
3257
+ message_download: messageDownload,
3258
+ message_sync: messageSync,
3259
+ "message.hit": strictObject({
3260
+ ...pick(message, [
3261
+ "ref",
3262
+ "chat_title",
3263
+ "timestamp",
3264
+ "sender_name",
3265
+ "excerpt",
3266
+ "matched_in",
3267
+ "score",
3268
+ "match",
3269
+ "corrections",
3270
+ "found_in",
3271
+ "discovery",
3272
+ "context",
3273
+ "email"
3274
+ ]).entries,
3275
+ untrusted
3276
+ }),
3277
+ "message.summary": pick(message, [
3278
+ "ref",
3279
+ "chat_id",
3280
+ "chat_title",
3281
+ "timestamp",
3282
+ "sender_name",
3283
+ "outgoing",
3284
+ "text",
3285
+ "transcript",
3286
+ "attachments"
3287
+ ]),
3288
+ message_link: messageLink,
3289
+ message_write: messageWrite,
3290
+ message_send: messageSend,
3291
+ message_pin: messagePin,
3292
+ message_star: messageStar,
3293
+ message_deletion: messageDeletion,
3294
+ message_transcript: messageTranscript,
3295
+ message_links: messageLinks,
3296
+ evidence_packet: evidencePacket,
3297
+ chat_metadata: cachedChatMetadata,
3298
+ chat_metadata_refresh: chatMetadataRefresh,
3299
+ chat,
3300
+ mention,
3301
+ "mention.details": mentionDetails,
3302
+ mention_domain: mentionDomain,
3303
+ mention_decision: mentionDecision,
3304
+ mention_rebuild: mentionRebuild,
3305
+ place,
3306
+ person: person2,
3307
+ identity,
3308
+ contact_context: contactContext,
3309
+ contact_preparation: contactPreparation,
3310
+ contact_activity: contactActivity,
3311
+ contact_check: contactCheck,
3312
+ linked_person: linkedPerson,
3313
+ contact,
3314
+ contact_note: contactNote,
3315
+ contact_lookup: contactLookup,
3316
+ contact_profile: contactProfile,
3317
+ contact_sync: contactSync,
3318
+ contact_update: contactUpdate,
3319
+ contact_state_change: contactStateChange,
3320
+ contact_import: contactImport,
3321
+ contact_alias: contactAlias,
3322
+ contact_note_removal: contactNoteRemoval,
3323
+ account,
3324
+ account_session: accountSession,
3325
+ account_change: accountChange,
3326
+ ended_account_sessions: endedAccountSessions,
3327
+ account_privacy: accountPrivacy,
3328
+ account_privacy_change: accountPrivacyChange,
3329
+ account_profile: accountProfile,
3330
+ organization,
3331
+ project,
3332
+ reminder,
3333
+ bot_profile: botProfile,
3334
+ bot_template: botTemplate,
3335
+ bot_seen_chat: botSeenChat,
3336
+ bot_admin: botAdmin,
3337
+ bot_menu_entry: botMenuEntry,
3338
+ bot_webhook: botWebhook,
3339
+ scheduled_job: scheduledJob,
3340
+ call_record: callRecord,
3341
+ sticker_inventory: stickerInventory,
3342
+ note,
3343
+ "note.hit": strictObject({
3344
+ ...pick(note, [
3345
+ "kind",
3346
+ "provider",
3347
+ "account",
3348
+ "url",
3349
+ "ref",
3350
+ "source",
3351
+ "folder_id",
3352
+ "path",
3353
+ "title",
3354
+ "updated_at",
3355
+ "excerpt",
3356
+ "found_by",
3357
+ "links"
3358
+ ]).entries,
3359
+ untrusted
3360
+ }),
3361
+ hit,
3362
+ document,
3363
+ document_link: documentLink,
3364
+ image_embedding: imageEmbedding,
3365
+ attachment,
3366
+ attachment_bytes: attachmentBytes,
3367
+ attachment_extraction: attachmentExtraction,
3368
+ attachment_text_change: attachmentTextChange,
3369
+ media_archive: mediaArchive,
3370
+ media_archive_check: mediaArchiveCheck,
3371
+ media_archive_move: mediaArchiveMove,
3372
+ media_archive_timer: mediaArchiveTimer,
3373
+ task,
3374
+ task_pair: taskPair,
3375
+ task_card: taskCard,
3376
+ task_created: taskCreated,
3377
+ task_closed: taskClosed,
3378
+ task_links: taskLinks,
3379
+ task_similar: taskSimilar,
3380
+ task_merge: taskMerge,
3381
+ task_unmerge: taskUnmerge,
3382
+ task_categories: taskCategories,
3383
+ task_scan: taskScan,
3384
+ fact,
3385
+ memory,
3386
+ meeting,
3387
+ meeting_details: meetingDetails,
3388
+ meeting_hit: meetingHit,
3389
+ meeting_series_inventory: meetingSeriesInventory,
3390
+ meeting_project_candidates: meetingProjectCandidates,
3391
+ meeting_project_evidence: meetingProjectEvidence,
3392
+ meeting_preparation: meetingPreparation,
3393
+ meeting_findings: meetingFindings,
3394
+ meeting_transcript: meetingTranscript,
3395
+ meeting_summary: meetingSummary,
3396
+ meeting_evidence: meetingEvidence,
3397
+ meeting_person_context: meetingPersonContext,
3398
+ event,
3399
+ meeting_review: meetingReview,
3400
+ meeting_link: meetingLink,
3401
+ meeting_stats: meetingStats,
3402
+ meeting_speaker: meetingSpeaker,
3403
+ meeting_participants: meetingParticipants,
3404
+ meeting_passage: meetingPassage,
3405
+ meeting_task_proposal: meetingTaskProposal,
3406
+ reference,
3407
+ relationship,
3408
+ recipient,
3409
+ recipient_change: recipientChange,
3410
+ "recipient_change.added": recipientAdded,
3411
+ "recipient_change.removed": recipientRemoved,
3412
+ "recipient_change.off": recipientOff,
3413
+ run: recordedRun,
3414
+ "run.details": runDetails,
3415
+ "run.hit": runHit,
3416
+ run_location: runLocation,
3417
+ tag_change: tagChange,
3418
+ automatic_tags: automaticTags,
3419
+ send_attempt: sendAttempt,
3420
+ tagging,
3421
+ "conversation.details": conversationDetails,
3422
+ conversation_build: conversationBuildResult,
3423
+ conversation_batch_status: conversationBatchStatus,
3424
+ conversation_batch: conversationBatch,
3425
+ conversation_change: conversationChange,
3426
+ conversation_readiness: conversationReadiness,
3427
+ conversation_embedding: conversationEmbedding,
3428
+ conversation_embedding_status: conversationEmbeddingStatus,
3429
+ conversation_preparation: conversationPreparation,
3430
+ conversation_hit: conversationHit,
3431
+ conversation,
3432
+ saved_search: savedSearch,
3433
+ search_history_clear: searchHistoryClear,
3434
+ watch_item: watchItem,
3435
+ serve_summary: serveSummary,
3436
+ job,
3437
+ store_chat_status: storeChatStatus,
3438
+ store_clear: storeClear,
3439
+ store_export: storeExport,
3440
+ store_gap_plan: storeGapPlan,
3441
+ store_gap_repair: storeGapRepair,
3442
+ store_job_details: storeJobDetails,
3443
+ store_job_cancel: storeJobCancel,
3444
+ store_job_retry: storeJobRetry,
3445
+ store_job_clear: storeJobClear,
3446
+ store_info: storeInfo,
3447
+ store_check: storeCheck,
3448
+ store_migration: storeMigration,
3449
+ store_reindex: storeReindex,
3450
+ store_backup: storeBackup,
3451
+ store_decrypt: storeDecrypt,
3452
+ store_restore: storeRestore,
3453
+ store_reset: storeReset,
3454
+ store_repair: storeRepair,
3455
+ store_copy_removal: storeCopyRemoval,
3456
+ store_table: storeTable,
3457
+ agenda,
3458
+ model,
3459
+ chat_group_change: chatGroupChange,
3460
+ chat_inspection: chatInspection,
3461
+ chat_sender: chatSender,
3462
+ chat_read: chatRead,
3463
+ chat_members_fetch: chatMembersFetch,
3464
+ chat_members_change: chatMembersChange,
3465
+ chat_invite: chatInvite,
3466
+ chat_invite_change: chatInviteChange,
3467
+ chat_request_change: chatRequestChange,
3468
+ chat_admin_change: chatAdminChange,
3469
+ chat_folder_change: chatFolderChange,
3470
+ chat_folder_removal: chatFolderRemoval,
3471
+ chat_folder_order: chatFolderOrder,
3472
+ chat_rules: chatRules,
3473
+ chat_moderation: chatModeration,
3474
+ model_key: modelKey,
3475
+ "model_key.stored": storedModelKey,
3476
+ "model_key.removed": removedModelKey,
3477
+ chat_event: chatEvent,
3478
+ chat_removal: chatRemoval,
3479
+ chat_muting: chatMuting,
3480
+ chat_archive: chatArchive,
3481
+ chat_pin: chatPin,
3482
+ chat_unread: chatUnread,
3483
+ invite_link: inviteLink,
3484
+ join_request: joinRequest,
3485
+ member,
3486
+ poll,
3487
+ poll_change: pollChange,
3488
+ poll_vote: pollVote,
3489
+ reaction_change: reactionChange,
3490
+ topic,
3491
+ folder,
3492
+ message_counts: messageCounts,
3493
+ ranking,
3494
+ admin_report: adminReport,
3495
+ analysis_consent: analysisConsent,
3496
+ analysis_consent_revocation: analysisConsentRevocation,
3497
+ retention,
3498
+ evidence,
3499
+ counters,
3500
+ counter_refresh: counterRefresh,
3501
+ official_stats: officialStats,
3502
+ chart,
3503
+ chat_stats: chatStats,
3504
+ tracked_chat: trackedChat,
3505
+ tracked_chat_history: trackedChatHistory,
3506
+ chat_tracking: chatTracking,
3507
+ task_stats: taskStats
3508
+ };
3509
+ var entityDefinitions = /* @__PURE__ */ __name(() => Object.fromEntries(Object.entries(ENTITIES).map(([name, schema2]) => {
3510
+ const { $schema: _, ...definition } = jsonSchemaOf(schema2);
3511
+ return [name, definition];
3512
+ })), "entityDefinitions");
3513
+
3514
+ export {
3515
+ accountSession,
3516
+ accountProfile,
3517
+ analysisConsent,
3518
+ member,
3519
+ chat,
3520
+ folder,
3521
+ inviteLink,
3522
+ chatEvent,
3523
+ contact,
3524
+ message,
3525
+ contactNote,
3526
+ documentLink,
3527
+ checkpointPath,
3528
+ readCheckpoint,
3529
+ saveCheckpoint,
3530
+ progressOf,
3531
+ spawnDetached,
3532
+ jobsDir,
3533
+ saveJob,
3534
+ readJob,
3535
+ tracedJob,
3536
+ jobStarted,
3537
+ finishJob,
3538
+ updateJob,
3539
+ removeJob,
3540
+ listJobs,
3541
+ jobDetails,
3542
+ jobItem,
3543
+ stateOf,
3544
+ startArchiveJob,
3545
+ job,
3546
+ joinRequest,
3547
+ botProfile,
3548
+ botSeenChat,
3549
+ botAdmin,
3550
+ botMenuEntry,
3551
+ botWebhook,
3552
+ scheduledJob,
3553
+ botTemplate,
3554
+ callRecord,
3555
+ stickerInventory,
3556
+ pollVote,
3557
+ meetingPreparation,
3558
+ meetingProjectCandidates,
3559
+ meetingSeriesInventory,
3560
+ model,
3561
+ recipient,
3562
+ recordedRun,
3563
+ savedSearch,
3564
+ sendAttempt,
3565
+ progress,
3566
+ topic,
3567
+ ENTITIES,
3568
+ entityDefinitions
3569
+ };