@wirecat/cli-memo 0.131.69 → 0.131.71
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.
- package/README.md +3 -3
- package/THIRD_PARTY_NOTICES +2 -0
- package/dist/actions/actions.d.ts +2 -1
- package/dist/actions/actions.d.ts.map +1 -1
- package/dist/actions/actions.js +5 -3
- package/dist/actions/actions.js.map +1 -1
- package/dist/actions/command.d.ts.map +1 -1
- package/dist/actions/command.js +15 -6
- package/dist/actions/command.js.map +1 -1
- package/dist/answer.d.ts +1 -0
- package/dist/answer.d.ts.map +1 -1
- package/dist/answer.js +2 -1
- package/dist/answer.js.map +1 -1
- package/dist/bin/memo.js +2 -2
- package/dist/bin/memo.js.map +1 -1
- package/dist/bundle/{all-profiles-6JKSPBBO.js → all-profiles-G6S5HOBT.js} +5 -5
- package/dist/bundle/{anthropic-YA2N6EJ4.js → anthropic-LA6PXTPQ.js} +2 -2
- package/dist/bundle/{app-server-UP3AL2XQ.js → app-server-W622CBPF.js} +35 -35
- package/dist/bundle/auto-WUU2MYGS.js +85 -0
- package/dist/bundle/{bun-OUFOAYV4.js → bun-PZNVNH4G.js} +2 -2
- package/dist/bundle/{bun-sqlite-5RZTFU2Q.js → bun-sqlite-VICDK5FS.js} +2 -2
- package/dist/bundle/{chunk-3TFK7RBA.js → chunk-2LTQ6ZBS.js} +23908 -22107
- package/dist/bundle/{chunk-IHHXGTMX.js → chunk-3LS76TFB.js} +1 -1
- package/dist/bundle/{chunk-IJAILIZR.js → chunk-3PIKTX3U.js} +18 -18
- package/dist/bundle/{chunk-N73YBQ42.js → chunk-3ZSPTUG3.js} +9 -7
- package/dist/bundle/{chunk-RHW3DDWI.js → chunk-6B3GQMR6.js} +1 -1
- package/dist/bundle/{chunk-LYAJUZM4.js → chunk-6EIWRE6E.js} +30 -30
- package/dist/bundle/{chunk-EDPA54WQ.js → chunk-6Z62U7NY.js} +3 -3
- package/dist/bundle/{chunk-JMGQATR6.js → chunk-ASDOPGKC.js} +2 -2
- package/dist/bundle/{chunk-EKSOPEFQ.js → chunk-BE22RDTR.js} +4 -4
- package/dist/bundle/{chunk-FZHYGJQ2.js → chunk-CLQXHFKG.js} +5 -5
- package/dist/bundle/{chunk-VPKJZKXV.js → chunk-CPUQC7UF.js} +1 -1
- package/dist/bundle/{chunk-GGFL64HF.js → chunk-CZUAGRL7.js} +13168 -11987
- package/dist/bundle/{chunk-GVP6CAPH.js → chunk-DW6CDBXA.js} +33 -586
- package/dist/bundle/{chunk-5MUR6D2G.js → chunk-DXWDHC2K.js} +44 -2
- package/dist/bundle/{chunk-5OMM4CDT.js → chunk-ESYCZ575.js} +2 -2
- package/dist/bundle/{chunk-OBQ7TSUB.js → chunk-FHIGY5K6.js} +1 -1
- package/dist/bundle/{chunk-MK6SQ32Q.js → chunk-FPWF2XLH.js} +12 -12
- package/dist/bundle/{chunk-MYLNRBDF.js → chunk-FVJSDDSV.js} +46 -13
- package/dist/bundle/{chunk-TV75OHKJ.js → chunk-G3FQTKHT.js} +7 -7
- package/dist/bundle/{chunk-WNA2WNDK.js → chunk-G7XOBQB5.js} +3 -3
- package/dist/bundle/{chunk-PSYQPO6D.js → chunk-H3LAORYX.js} +2 -2
- package/dist/bundle/{chunk-2DQYP2K3.js → chunk-HIHZNBR7.js} +1 -1
- package/dist/bundle/{chunk-QAXIZHK7.js → chunk-HNQGX4AG.js} +33 -33
- package/dist/bundle/{chunk-22CDLXSR.js → chunk-I4HWKPQR.js} +4 -4
- package/dist/bundle/{chunk-2NFI7SDW.js → chunk-INQAQ55X.js} +2304 -1111
- package/dist/bundle/{chunk-XTEJXJJ3.js → chunk-IP5CA3CW.js} +10 -10
- package/dist/bundle/{chunk-EO4JMJFZ.js → chunk-IXZWUHSG.js} +7 -7
- package/dist/bundle/{chunk-MWQI6FSU.js → chunk-K55WZ67L.js} +3 -3
- package/dist/bundle/{chunk-YTJWIJIG.js → chunk-KH43CUE2.js} +5 -5
- package/dist/bundle/{chunk-2C7Z7CKD.js → chunk-LIF2HXIQ.js} +1 -1
- package/dist/bundle/{chunk-GVEY6743.js → chunk-LRS5X7G3.js} +9 -9
- package/dist/bundle/{chunk-3LGLKLBA.js → chunk-M2DAITNE.js} +2 -2
- package/dist/bundle/{chunk-OAO5UCPJ.js → chunk-MAGAWAPG.js} +1366 -1574
- package/dist/bundle/{chunk-7JFLHRQL.js → chunk-MKOQDN3I.js} +1 -1
- package/dist/bundle/{chunk-67VEVKMJ.js → chunk-MSTWHRLN.js} +1 -1
- package/dist/bundle/{chunk-YXXAPVAZ.js → chunk-NLRPCKUS.js} +8 -8
- package/dist/bundle/{chunk-W2FFA7T5.js → chunk-NNUS57F4.js} +5 -5
- package/dist/bundle/{chunk-3YVLNOPE.js → chunk-OHBP2KPQ.js} +4 -4
- package/dist/bundle/{chunk-BJJULUUC.js → chunk-OWFC6BAF.js} +5 -5
- package/dist/bundle/{chunk-267N22E4.js → chunk-PGOMGFXA.js} +1 -1
- package/dist/bundle/{chunk-4HSWIXYE.js → chunk-PHL53ERQ.js} +4 -4
- package/dist/bundle/{chunk-5EHUHZU5.js → chunk-QNJ4EKKW.js} +80 -68
- package/dist/bundle/{chunk-53EAI4VZ.js → chunk-QUPPO7DB.js} +1 -1
- package/dist/bundle/{chunk-276KPJI5.js → chunk-RF6KPQWV.js} +2 -2
- package/dist/bundle/{chunk-TXOXPQN2.js → chunk-SL2LXOCN.js} +2 -2
- package/dist/bundle/{chunk-QZU5IM5E.js → chunk-SR7C53CS.js} +2 -2
- package/dist/bundle/{chunk-ECHN36DC.js → chunk-STJWETNW.js} +4 -4
- package/dist/bundle/{chunk-BGWPKEKK.js → chunk-SVVSGUMU.js} +4 -4
- package/dist/bundle/{chunk-FQ54GW57.js → chunk-TG3XWDFI.js} +8360 -8360
- package/dist/bundle/{chunk-V2YS63Z5.js → chunk-U3P5F57B.js} +1 -1
- package/dist/bundle/{chunk-PHSYMVYX.js → chunk-UCRR7R6Q.js} +2 -2
- package/dist/bundle/{chunk-2F35N6BI.js → chunk-UX52EWLQ.js} +1 -1
- package/dist/bundle/{chunk-OHA7HDPX.js → chunk-V6BJM3XW.js} +1024 -676
- package/dist/bundle/{chunk-TVZXLAID.js → chunk-X337K4BD.js} +10 -6
- package/dist/bundle/{chunk-UEMI6FXR.js → chunk-XNX3U6GD.js} +6 -6
- package/dist/bundle/{chunk-7L4PBN5S.js → chunk-ZM6J47GY.js} +2 -2
- package/dist/bundle/{command-contract-OGW2DX4C.js → command-contract-7QECBB6M.js} +11 -11
- package/dist/bundle/{decode-IJMDTGTW.js → decode-WRWXOJML.js} +2 -2
- package/dist/bundle/{echarts-EHYUXOKP.js → echarts-MTCNTCST.js} +2 -2
- package/dist/bundle/{embed-RUY3UIVC.js → embed-PPPCHSTE.js} +3 -3
- package/dist/bundle/{embedder-P6WBMEGP.js → embedder-UJBIX6A2.js} +6 -6
- package/dist/bundle/{entry-7S2ONYSF.js → entry-4P5556KI.js} +4 -4
- package/dist/bundle/failure-3F3YHF7G.js +65 -0
- package/dist/bundle/{first-run-MLIFZSVH.js → first-run-EKRDZLLY.js} +5 -5
- package/dist/bundle/{first-screen-DGTTK6VK.js → first-screen-FRRTKWFB.js} +12 -12
- package/dist/bundle/{instructions-ZMG4FLGO.js → instructions-JKIO4JF7.js} +1 -1
- package/dist/bundle/{mcp-CFIL7WZU.js → mcp-FQPK2KAF.js} +35 -35
- package/dist/bundle/memo.js +14 -11
- package/dist/bundle/{node-QYL4B7JS.js → node-3AIXDDDR.js} +2 -2
- package/dist/bundle/{node-sqlite-ESTT2OCF.js → node-sqlite-NX722DXD.js} +3 -3
- package/dist/bundle/{oauth-CFQFSIRQ.js → oauth-2NPSI7Q3.js} +4 -4
- package/dist/bundle/{open-3XO2HMIT.js → open-AFRN6Q36.js} +2 -2
- package/dist/bundle/{openai-STUNDBD6.js → openai-U5CQFLRU.js} +7 -7
- package/dist/bundle/{process-P4UAJCZX.js → process-J2IBN6X7.js} +1 -1
- package/dist/bundle/{program-BXL5ZOVQ.js → program-L5IM35PO.js} +1433 -531
- package/dist/bundle/{prompt-ZCYMFMIG.js → prompt-6XNKR4VQ.js} +2 -2
- package/dist/bundle/{recognize-V3BY33FK.js → recognize-G3GI32QS.js} +1 -1
- package/dist/bundle/{remote-IP4QR7SP.js → remote-DJO255PT.js} +4 -4
- package/dist/bundle/{rerank-VKUSF3DM.js → rerank-5SBZRIHF.js} +4 -4
- package/dist/bundle/{serve-VBIUARHJ.js → serve-BZVBKGU3.js} +6 -6
- package/dist/bundle/server-GCESLOOF.js +48 -0
- package/dist/bundle/server-JUSMYLIQ.js +61 -0
- package/dist/bundle/{server-JLPZUC42.js → server-LWQAHDBH.js} +55 -52
- package/dist/bundle/{state-UBAIZ2WP.js → state-A57F7T5D.js} +3 -3
- package/dist/bundle/{store-VQQVUA4W.js → store-WG2GYWTG.js} +9 -9
- package/dist/bundle/store-maintenance-command-GTY6VU76.js +47 -0
- package/dist/bundle/update-LICMP7UR.js +68 -0
- package/dist/context/command.d.ts +2 -1
- package/dist/context/command.d.ts.map +1 -1
- package/dist/context/command.js +34 -12
- package/dist/context/command.js.map +1 -1
- package/dist/context/context.d.ts +20 -8
- package/dist/context/context.d.ts.map +1 -1
- package/dist/context/context.js +65 -40
- package/dist/context/context.js.map +1 -1
- package/dist/contract-overrides/search.js +1 -1
- package/dist/contract-overrides/search.js.map +1 -1
- package/dist/contract-overrides/skill.d.ts.map +1 -1
- package/dist/contract-overrides/skill.js +5 -10
- package/dist/contract-overrides/skill.js.map +1 -1
- package/dist/digest/backfill.d.ts.map +1 -1
- package/dist/digest/backfill.js +4 -2
- package/dist/digest/backfill.js.map +1 -1
- package/dist/digest/brief.d.ts +14 -0
- package/dist/digest/brief.d.ts.map +1 -0
- package/dist/digest/brief.js +143 -0
- package/dist/digest/brief.js.map +1 -0
- package/dist/digest/digest.d.ts.map +1 -1
- package/dist/digest/digest.js +2 -1
- package/dist/digest/digest.js.map +1 -1
- package/dist/discovery/command.d.ts.map +1 -1
- package/dist/discovery/command.js +2 -0
- package/dist/discovery/command.js.map +1 -1
- package/dist/doctor/command.d.ts +22 -2
- package/dist/doctor/command.d.ts.map +1 -1
- package/dist/examples.d.ts.map +1 -1
- package/dist/examples.js +51 -10
- package/dist/examples.js.map +1 -1
- package/dist/facts/command.d.ts.map +1 -1
- package/dist/facts/command.js +7 -6
- package/dist/facts/command.js.map +1 -1
- package/dist/finance/deal-text.d.ts +4 -0
- package/dist/finance/deal-text.d.ts.map +1 -0
- package/dist/finance/deal-text.js +34 -0
- package/dist/finance/deal-text.js.map +1 -0
- package/dist/finance/deals-command.d.ts +1 -1
- package/dist/finance/deals-command.d.ts.map +1 -1
- package/dist/finance/deals-command.js +113 -13
- package/dist/finance/deals-command.js.map +1 -1
- package/dist/knowledge/business-text.d.ts +7 -0
- package/dist/knowledge/business-text.d.ts.map +1 -0
- package/dist/knowledge/business-text.js +19 -0
- package/dist/knowledge/business-text.js.map +1 -0
- package/dist/knowledge/command.d.ts +1 -1
- package/dist/knowledge/command.d.ts.map +1 -1
- package/dist/knowledge/command.js +131 -42
- package/dist/knowledge/command.js.map +1 -1
- package/dist/knowledge/money-text.d.ts +4 -0
- package/dist/knowledge/money-text.d.ts.map +1 -0
- package/dist/knowledge/money-text.js +16 -0
- package/dist/knowledge/money-text.js.map +1 -0
- package/dist/knowledge/organization-text.d.ts +7 -0
- package/dist/knowledge/organization-text.d.ts.map +1 -0
- package/dist/knowledge/organization-text.js +24 -0
- package/dist/knowledge/organization-text.js.map +1 -0
- package/dist/knowledge/project-actions-command.js +1 -1
- package/dist/knowledge/project-actions-command.js.map +1 -1
- package/dist/knowledge/project-actions.d.ts +1 -1
- package/dist/knowledge/project-actions.d.ts.map +1 -1
- package/dist/knowledge/project-actions.js +2 -2
- package/dist/knowledge/project-actions.js.map +1 -1
- package/dist/knowledge/project-context.d.ts +27 -1
- package/dist/knowledge/project-context.d.ts.map +1 -1
- package/dist/knowledge/project-context.js +9 -5
- package/dist/knowledge/project-context.js.map +1 -1
- package/dist/knowledge/project-status-command.d.ts.map +1 -1
- package/dist/knowledge/project-status-command.js +21 -5
- package/dist/knowledge/project-status-command.js.map +1 -1
- package/dist/knowledge/relationships.d.ts +27 -23
- package/dist/knowledge/relationships.d.ts.map +1 -1
- package/dist/knowledge/relationships.js +65 -52
- package/dist/knowledge/relationships.js.map +1 -1
- package/dist/knowledge/roles-command.d.ts +8 -0
- package/dist/knowledge/roles-command.d.ts.map +1 -0
- package/dist/knowledge/roles-command.js +65 -0
- package/dist/knowledge/roles-command.js.map +1 -0
- package/dist/mcp/catalogue.d.ts +1 -1
- package/dist/mcp/catalogue.d.ts.map +1 -1
- package/dist/mcp/catalogue.js +3 -1
- package/dist/mcp/catalogue.js.map +1 -1
- package/dist/mcp/server.js +1 -1
- package/dist/mcp/server.js.map +1 -1
- package/dist/memories/command.d.ts.map +1 -1
- package/dist/memories/command.js +6 -5
- package/dist/memories/command.js.map +1 -1
- package/dist/memories/sources.js +2 -2
- package/dist/memories/sources.js.map +1 -1
- package/dist/models/command.d.ts +1 -1
- package/dist/models/command.d.ts.map +1 -1
- package/dist/models/command.js +2 -1
- package/dist/models/command.js.map +1 -1
- package/dist/notes/command.d.ts.map +1 -1
- package/dist/notes/command.js +13 -8
- package/dist/notes/command.js.map +1 -1
- package/dist/notes/embed.d.ts +6 -1
- package/dist/notes/embed.d.ts.map +1 -1
- package/dist/notes/embed.js +17 -8
- package/dist/notes/embed.js.map +1 -1
- package/dist/people/command.d.ts.map +1 -1
- package/dist/people/command.js +2 -1
- package/dist/people/command.js.map +1 -1
- package/dist/program.d.ts +13 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +173 -11
- package/dist/program.js.map +1 -1
- package/dist/reasons.d.ts.map +1 -1
- package/dist/reasons.js +42 -0
- package/dist/reasons.js.map +1 -1
- package/dist/review/command.js +2 -2
- package/dist/review/command.js.map +1 -1
- package/dist/review/review.d.ts +3 -3
- package/dist/review/review.d.ts.map +1 -1
- package/dist/review/review.js +6 -6
- package/dist/review/review.js.map +1 -1
- package/dist/review/status.d.ts.map +1 -1
- package/dist/review/status.js +5 -4
- package/dist/review/status.js.map +1 -1
- package/dist/run/import.d.ts +2 -2
- package/dist/run/import.d.ts.map +1 -1
- package/dist/run/import.js +9 -3
- package/dist/run/import.js.map +1 -1
- package/dist/search/command.d.ts.map +1 -1
- package/dist/search/command.js +21 -3
- package/dist/search/command.js.map +1 -1
- package/dist/search/denied.d.ts +10 -0
- package/dist/search/denied.d.ts.map +1 -0
- package/dist/search/denied.js +10 -0
- package/dist/search/denied.js.map +1 -0
- package/dist/search/people.d.ts.map +1 -1
- package/dist/search/people.js +11 -1
- package/dist/search/people.js.map +1 -1
- package/dist/search/search.d.ts +2 -0
- package/dist/search/search.d.ts.map +1 -1
- package/dist/search/search.js +37 -12
- package/dist/search/search.js.map +1 -1
- package/dist/store/group.d.ts +38 -0
- package/dist/store/group.d.ts.map +1 -0
- package/dist/store/group.js +112 -0
- package/dist/store/group.js.map +1 -0
- package/dist/store/groups-command.d.ts +10 -0
- package/dist/store/groups-command.d.ts.map +1 -0
- package/dist/store/groups-command.js +88 -0
- package/dist/store/groups-command.js.map +1 -0
- package/dist/store/guard.d.ts +29 -0
- package/dist/store/guard.d.ts.map +1 -0
- package/dist/store/guard.js +94 -0
- package/dist/store/guard.js.map +1 -0
- package/dist/store/scope.d.ts +3 -3
- package/dist/store/scope.d.ts.map +1 -1
- package/dist/store/scope.js +7 -6
- package/dist/store/scope.js.map +1 -1
- package/dist/store/source-list.d.ts +5 -1
- package/dist/store/source-list.d.ts.map +1 -1
- package/dist/store/source-list.js +30 -15
- package/dist/store/source-list.js.map +1 -1
- package/dist/tags/command.d.ts.map +1 -1
- package/dist/tags/command.js +3 -2
- package/dist/tags/command.js.map +1 -1
- package/dist/tasks/shared.d.ts.map +1 -1
- package/dist/tasks/shared.js +2 -1
- package/dist/tasks/shared.js.map +1 -1
- package/dist/tasks/tasks.js +3 -3
- package/dist/tasks/tasks.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -4
- package/skills/cli-memo/SKILL.md +7 -7
- package/skills/cli-memo/topics/mcp.md +9 -0
- package/skills/cli-memo/topics/money.md +14 -1
- package/skills/cli-memo/topics/projects.md +2 -1
- package/skills/cli-memo/topics/search.md +12 -4
- package/dist/bundle/auto-IKZIROGF.js +0 -85
- package/dist/bundle/failure-NRZUB77S.js +0 -65
- package/dist/bundle/server-AASCSGCI.js +0 -61
- package/dist/bundle/server-YQLPZK4Z.js +0 -48
- package/dist/bundle/store-maintenance-command-GCBABKEZ.js +0 -47
- package/dist/bundle/update-M54Z3SEU.js +0 -68
- /package/dist/bundle/{chunk-AWVQHWIS.js → chunk-YSYFOIW7.js} +0 -0
|
@@ -9,27 +9,35 @@ import {
|
|
|
9
9
|
providerErrorKey,
|
|
10
10
|
renderEvent,
|
|
11
11
|
runContextOf
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-3ZSPTUG3.js";
|
|
13
13
|
import {
|
|
14
14
|
permissionCeiling
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-6Z62U7NY.js";
|
|
16
16
|
import {
|
|
17
17
|
envName,
|
|
18
18
|
readOnlyLockOf,
|
|
19
19
|
readOnlyRefusal
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-HIHZNBR7.js";
|
|
21
21
|
import {
|
|
22
22
|
carries
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-3LS76TFB.js";
|
|
24
24
|
import {
|
|
25
25
|
BUSINESS_KINDS,
|
|
26
|
+
CATEGORIES,
|
|
27
|
+
DEAL_KINDS,
|
|
26
28
|
DEAL_ROLES,
|
|
29
|
+
DEAL_STATUSES,
|
|
27
30
|
FACT_STATUSES,
|
|
28
31
|
FACT_TYPES,
|
|
29
32
|
FIELD_TYPES,
|
|
33
|
+
FINANCE_REVIEWS,
|
|
30
34
|
INVOICE_DIRECTIONS,
|
|
35
|
+
INVOICE_STATUSES,
|
|
36
|
+
KEEP_STORE_RUNS_FOR_DAYS,
|
|
37
|
+
KEEP_SUCCESSFUL_RUNS_FOR_DAYS,
|
|
31
38
|
LINK_KINDS,
|
|
32
39
|
LINK_SOURCES,
|
|
40
|
+
LOG_ATTRIBUTES,
|
|
33
41
|
MEETING_RESULT_ENTITIES,
|
|
34
42
|
MEMORY_KINDS,
|
|
35
43
|
MEMORY_SCOPES,
|
|
@@ -40,6 +48,7 @@ import {
|
|
|
40
48
|
PRIORITY_LABELS,
|
|
41
49
|
QUERY_BACKENDS,
|
|
42
50
|
RELATION_KINDS,
|
|
51
|
+
RUNS_SIZE_LIMIT_MB,
|
|
43
52
|
STANDINGS,
|
|
44
53
|
TAG_TYPES,
|
|
45
54
|
TASK_KINDS,
|
|
@@ -49,11 +58,17 @@ import {
|
|
|
49
58
|
TASK_VERDICTS,
|
|
50
59
|
WORK_TASK_TYPES,
|
|
51
60
|
author,
|
|
61
|
+
childTrace,
|
|
52
62
|
count,
|
|
63
|
+
currentRun,
|
|
53
64
|
describeQuery,
|
|
65
|
+
enclosingTraceId,
|
|
54
66
|
event,
|
|
55
67
|
evidenceSource,
|
|
56
68
|
id,
|
|
69
|
+
inRun,
|
|
70
|
+
isGroupName,
|
|
71
|
+
logAttributes,
|
|
57
72
|
markStoreDamaged,
|
|
58
73
|
meeting,
|
|
59
74
|
meetingCounts,
|
|
@@ -68,31 +83,38 @@ import {
|
|
|
68
83
|
meetingStats,
|
|
69
84
|
meetingSummary,
|
|
70
85
|
meetingTranscript,
|
|
86
|
+
newRunId,
|
|
71
87
|
organization,
|
|
72
88
|
project,
|
|
73
89
|
providerMetadata,
|
|
74
90
|
reminder,
|
|
91
|
+
runsDirFor,
|
|
92
|
+
snakeLogger,
|
|
75
93
|
sourceReview,
|
|
94
|
+
startRun,
|
|
76
95
|
text,
|
|
77
96
|
time,
|
|
78
|
-
|
|
79
|
-
|
|
97
|
+
traceOf,
|
|
98
|
+
typedCommand,
|
|
99
|
+
untrusted,
|
|
100
|
+
useAsProcessRun
|
|
101
|
+
} from "./chunk-INQAQ55X.js";
|
|
80
102
|
import {
|
|
81
103
|
isCliFailure,
|
|
82
104
|
storeDamaged
|
|
83
|
-
} from "./chunk-
|
|
105
|
+
} from "./chunk-M2DAITNE.js";
|
|
84
106
|
import {
|
|
85
107
|
readSharedSection,
|
|
86
108
|
sharedConfigPath,
|
|
87
109
|
writeSharedSection
|
|
88
|
-
} from "./chunk-
|
|
110
|
+
} from "./chunk-SVVSGUMU.js";
|
|
89
111
|
import {
|
|
90
112
|
filesPresent,
|
|
91
113
|
sharedModelsDirectory
|
|
92
|
-
} from "./chunk-
|
|
114
|
+
} from "./chunk-G7XOBQB5.js";
|
|
93
115
|
import {
|
|
94
116
|
storePath
|
|
95
|
-
} from "./chunk-
|
|
117
|
+
} from "./chunk-U3P5F57B.js";
|
|
96
118
|
import {
|
|
97
119
|
configFilePath,
|
|
98
120
|
createRecordLog,
|
|
@@ -103,7 +125,6 @@ import {
|
|
|
103
125
|
projectFields,
|
|
104
126
|
resolvePaths,
|
|
105
127
|
saveConfigFile,
|
|
106
|
-
traceIdOf,
|
|
107
128
|
writeSecurely
|
|
108
129
|
} from "./chunk-UUBV5ATQ.js";
|
|
109
130
|
import {
|
|
@@ -3681,7 +3702,7 @@ var hidden = /* @__PURE__ */ __name((command) => Boolean(command._hidden), "hidd
|
|
|
3681
3702
|
var snapshot = /* @__PURE__ */ __name((command, known = /* @__PURE__ */ new Map(), children) => {
|
|
3682
3703
|
if (hidden(command))
|
|
3683
3704
|
throw new Error("a hidden command cannot own a shared contract");
|
|
3684
|
-
const { commands:
|
|
3705
|
+
const { commands: _2, usage: __, path: ___, ...contract } = describeAlone(command, known);
|
|
3685
3706
|
return {
|
|
3686
3707
|
...contract,
|
|
3687
3708
|
aliases: [...command.aliases()],
|
|
@@ -3958,7 +3979,7 @@ var commandsDocument = /* @__PURE__ */ __name((root, about) => ({
|
|
|
3958
3979
|
exit_codes: { ok: 0, internal_error: GENERIC_FAILURE, ...EXIT_CODES }
|
|
3959
3980
|
}), "commandsDocument");
|
|
3960
3981
|
|
|
3961
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3982
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/sends/guarded.js
|
|
3962
3983
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
3963
3984
|
var sentIds = /* @__PURE__ */ __name((typed2, message2) => ({
|
|
3964
3985
|
messageId: message2.id,
|
|
@@ -3985,18 +4006,18 @@ var stopWrites = /* @__PURE__ */ __name((scope, reason) => {
|
|
|
3985
4006
|
for (const write of scope)
|
|
3986
4007
|
write.cut();
|
|
3987
4008
|
}, "stopWrites");
|
|
3988
|
-
var refuseStopped = /* @__PURE__ */ __name((
|
|
3989
|
-
for (const scope of
|
|
4009
|
+
var refuseStopped = /* @__PURE__ */ __name((scopes2) => {
|
|
4010
|
+
for (const scope of scopes2)
|
|
3990
4011
|
if (stopped.has(scope))
|
|
3991
4012
|
throw stopped.get(scope);
|
|
3992
4013
|
}, "refuseStopped");
|
|
3993
4014
|
var currentOperation = /* @__PURE__ */ __name(() => current.getStore(), "currentOperation");
|
|
3994
4015
|
var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled2 = () => ({}), prepare) => {
|
|
3995
|
-
const
|
|
3996
|
-
refuseStopped(
|
|
4016
|
+
const scopes2 = scopesFor();
|
|
4017
|
+
refuseStopped(scopes2);
|
|
3997
4018
|
try {
|
|
3998
4019
|
await guard.ask?.(attempt);
|
|
3999
|
-
refuseStopped(
|
|
4020
|
+
refuseStopped(scopes2);
|
|
4000
4021
|
if (guard.reserve) {
|
|
4001
4022
|
guard.check(attempt, { reserve: false });
|
|
4002
4023
|
await guard.reserve(attempt);
|
|
@@ -4007,7 +4028,7 @@ var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled2 =
|
|
|
4007
4028
|
throw error;
|
|
4008
4029
|
}
|
|
4009
4030
|
try {
|
|
4010
|
-
refuseStopped(
|
|
4031
|
+
refuseStopped(scopes2);
|
|
4011
4032
|
} catch (error) {
|
|
4012
4033
|
guard.record({ ...attempt, outcome: "failed", errorCode: codeOf(error) });
|
|
4013
4034
|
throw error;
|
|
@@ -4032,7 +4053,7 @@ var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled2 =
|
|
|
4032
4053
|
});
|
|
4033
4054
|
}, "cut")
|
|
4034
4055
|
};
|
|
4035
|
-
for (const scope of
|
|
4056
|
+
for (const scope of scopes2)
|
|
4036
4057
|
scope.add(flight);
|
|
4037
4058
|
try {
|
|
4038
4059
|
if (prepare !== void 0)
|
|
@@ -4058,13 +4079,13 @@ var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled2 =
|
|
|
4058
4079
|
throw new CliError(error.code, error.message, { ...error.details, sent: false });
|
|
4059
4080
|
throw error;
|
|
4060
4081
|
} finally {
|
|
4061
|
-
for (const scope of
|
|
4082
|
+
for (const scope of scopes2)
|
|
4062
4083
|
scope.delete(flight);
|
|
4063
4084
|
}
|
|
4064
4085
|
}, "guardedWrite");
|
|
4065
4086
|
var codeOf = /* @__PURE__ */ __name((error) => typeof error?.code === "string" ? error.code : "unknown", "codeOf");
|
|
4066
4087
|
|
|
4067
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4088
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/result-fields.js
|
|
4068
4089
|
var named = /* @__PURE__ */ __name((work) => {
|
|
4069
4090
|
try {
|
|
4070
4091
|
return work();
|
|
@@ -4091,7 +4112,7 @@ var projectFields2 = /* @__PURE__ */ __name((value, fields) => named(() => {
|
|
|
4091
4112
|
return projectFields(value, fields);
|
|
4092
4113
|
}), "projectFields");
|
|
4093
4114
|
|
|
4094
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4115
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/execution.js
|
|
4095
4116
|
var DEFAULT_COOPERATIVE_MS = 5 * 6e4;
|
|
4096
4117
|
var DEFAULT_SYNC_MS = 15 * 6e4;
|
|
4097
4118
|
var DEFAULT_OUTPUT_BYTES = 4 * 1024 * 1024;
|
|
@@ -4102,7 +4123,7 @@ var withAbort = /* @__PURE__ */ __name(async (signal, body) => {
|
|
|
4102
4123
|
throw signal.reason;
|
|
4103
4124
|
let abort = /* @__PURE__ */ __name(() => {
|
|
4104
4125
|
}, "abort");
|
|
4105
|
-
const interrupted = new Promise((
|
|
4126
|
+
const interrupted = new Promise((_2, reject) => {
|
|
4106
4127
|
abort = /* @__PURE__ */ __name(() => reject(signal.reason), "abort");
|
|
4107
4128
|
signal.addEventListener("abort", abort, { once: true });
|
|
4108
4129
|
});
|
|
@@ -4113,7 +4134,67 @@ var withAbort = /* @__PURE__ */ __name(async (signal, body) => {
|
|
|
4113
4134
|
}
|
|
4114
4135
|
}, "withAbort");
|
|
4115
4136
|
|
|
4116
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4137
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/profile.js
|
|
4138
|
+
var asFirstWord = /* @__PURE__ */ __name((profile) => `${profile} `, "asFirstWord");
|
|
4139
|
+
var PLAIN_NAME = /^[A-Za-z0-9][A-Za-z0-9._-]*$/;
|
|
4140
|
+
var isProfileName = /* @__PURE__ */ __name((word) => PLAIN_NAME.test(word), "isProfileName");
|
|
4141
|
+
var usableProfileName = /* @__PURE__ */ __name((profile) => {
|
|
4142
|
+
if (!isProfileName(profile)) {
|
|
4143
|
+
throw new CliError("validation_error", `"${profile}" cannot be a profile name \u2014 letters, digits, dot, dash and underscore only, starting with a letter or a digit`);
|
|
4144
|
+
}
|
|
4145
|
+
return profile;
|
|
4146
|
+
}, "usableProfileName");
|
|
4147
|
+
var PROFILE_FREE = /* @__PURE__ */ new Set(["commands", "complete", "guide", "help", "skill", "upgrade"]);
|
|
4148
|
+
var freeOfProfile = /* @__PURE__ */ new WeakSet();
|
|
4149
|
+
var profileFree = /* @__PURE__ */ __name((command) => {
|
|
4150
|
+
freeOfProfile.add(command);
|
|
4151
|
+
return command;
|
|
4152
|
+
}, "profileFree");
|
|
4153
|
+
var takesProfile = /* @__PURE__ */ __name((command) => {
|
|
4154
|
+
let top;
|
|
4155
|
+
for (let at2 = command; at2?.parent; at2 = at2.parent) {
|
|
4156
|
+
if (freeOfProfile.has(at2))
|
|
4157
|
+
return false;
|
|
4158
|
+
top = at2;
|
|
4159
|
+
}
|
|
4160
|
+
return top !== void 0 && !PROFILE_FREE.has(top.name());
|
|
4161
|
+
}, "takesProfile");
|
|
4162
|
+
var commandWords = /* @__PURE__ */ __name((program2) => /* @__PURE__ */ new Set(["help", ...program2.commands.flatMap((command) => [command.name(), ...command.aliases()])]), "commandWords");
|
|
4163
|
+
var liftProfile = /* @__PURE__ */ __name((argv, words2, valued = /* @__PURE__ */ new Set()) => {
|
|
4164
|
+
let at2 = 0;
|
|
4165
|
+
while (argv[at2]?.startsWith("-") && argv[at2] !== "--")
|
|
4166
|
+
at2 += valued.has(argv[at2]) ? 2 : 1;
|
|
4167
|
+
const first2 = argv[at2];
|
|
4168
|
+
if (first2 === void 0 || first2.startsWith("-") || words2.has(first2))
|
|
4169
|
+
return { rest: argv };
|
|
4170
|
+
return { profile: first2, rest: [...argv.slice(0, at2), ...argv.slice(at2 + 1)] };
|
|
4171
|
+
}, "liftProfile");
|
|
4172
|
+
var runGroup = /* @__PURE__ */ __name((app, env, word) => {
|
|
4173
|
+
const GROUP = envName(app, "GROUP");
|
|
4174
|
+
const LOCK = envName(app, "GROUP_LOCK");
|
|
4175
|
+
const lock = env[LOCK]?.trim() || void 0;
|
|
4176
|
+
const named3 = word ?? (env[GROUP]?.trim() || void 0);
|
|
4177
|
+
const from = word === void 0 ? GROUP : "first word";
|
|
4178
|
+
for (const [name, origin] of [
|
|
4179
|
+
[named3, from],
|
|
4180
|
+
[lock, LOCK]
|
|
4181
|
+
])
|
|
4182
|
+
if (name !== void 0 && !isGroupName(name))
|
|
4183
|
+
throw new CliError("validation_error", `"${name}" (${origin}) is not a group name \u2014 letters, digits, - and _, starting with a letter or a digit`);
|
|
4184
|
+
if (lock === void 0 || lock.toLowerCase() === "all")
|
|
4185
|
+
return named3 === void 0 || named3.toLowerCase() === "all" ? void 0 : { name: named3, from, locked: false };
|
|
4186
|
+
if (named3 !== void 0 && named3 !== lock)
|
|
4187
|
+
throw new CliError("permission_error", `this process is locked to group ${lock} (${LOCK}) \u2014 group "${named3}" (${from}) is refused`);
|
|
4188
|
+
return { name: lock, from: LOCK, locked: true };
|
|
4189
|
+
}, "runGroup");
|
|
4190
|
+
var rootOf = /* @__PURE__ */ __name((command) => {
|
|
4191
|
+
let root = command;
|
|
4192
|
+
while (root.parent)
|
|
4193
|
+
root = root.parent;
|
|
4194
|
+
return root;
|
|
4195
|
+
}, "rootOf");
|
|
4196
|
+
|
|
4197
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/sends/permissions.js
|
|
4117
4198
|
var LEVELS = ["deny", "readonly", "ask", "allow"];
|
|
4118
4199
|
var DANGEROUS = /* @__PURE__ */ new Set(["messages.delete", "bot.messages.delete", "topics.delete", "chats.delete", "chats.clear"]);
|
|
4119
4200
|
var skipFlagFor = /* @__PURE__ */ __name((key) => DANGEROUS.has(key) ? "--allow-dangerous" : "--yes", "skipFlagFor");
|
|
@@ -4513,7 +4594,7 @@ var assertRetentionEvidenceRead = /* @__PURE__ */ __name((permissions) => {
|
|
|
4513
4594
|
}
|
|
4514
4595
|
}, "assertRetentionEvidenceRead");
|
|
4515
4596
|
|
|
4516
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4597
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/messenger/accounts.js
|
|
4517
4598
|
import { existsSync, readdirSync, readFileSync } from "node:fs";
|
|
4518
4599
|
import { join } from "node:path";
|
|
4519
4600
|
var accountFileFor = /* @__PURE__ */ __name((app, profile, env) => join(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "accounts", `${profile}.json`), "accountFileFor");
|
|
@@ -4535,12 +4616,12 @@ var profilesWithAccounts = /* @__PURE__ */ __name((app, env) => {
|
|
|
4535
4616
|
}, "profilesWithAccounts");
|
|
4536
4617
|
var profilesHere = /* @__PURE__ */ __name((app, configured, env) => [.../* @__PURE__ */ new Set([...configured, ...profilesWithAccounts(app, env)])].sort(), "profilesHere");
|
|
4537
4618
|
|
|
4538
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4619
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/background/budget.js
|
|
4539
4620
|
var DEADLINE_MARGIN_MS = 5e3;
|
|
4540
4621
|
var DEADLINE_MARGIN_SHARE = 0.15;
|
|
4541
4622
|
var deadlineMargin = /* @__PURE__ */ __name((deadline) => Math.max(DEADLINE_MARGIN_MS, deadline.ms * DEADLINE_MARGIN_SHARE), "deadlineMargin");
|
|
4542
4623
|
|
|
4543
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4624
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/output-detail.js
|
|
4544
4625
|
var RARELY_SET = ["editedAt", "replyTo", "forwardedFrom", "reactions"];
|
|
4545
4626
|
var BRIEF = ["locator", "chatTitle", "timestamp", "senderName", "excerpt", "score"];
|
|
4546
4627
|
var SNAKE_BRIEF = ["ref", "chat_title", "timestamp", "sender_name", "excerpt", "score"];
|
|
@@ -4576,7 +4657,7 @@ var atDetail = /* @__PURE__ */ __name((value, detail = "default") => {
|
|
|
4576
4657
|
return value;
|
|
4577
4658
|
}, "atDetail");
|
|
4578
4659
|
|
|
4579
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4660
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/output.js
|
|
4580
4661
|
var refuseCompact = /* @__PURE__ */ __name(({ json, jsonl, fields, hitDetail }) => {
|
|
4581
4662
|
const other = jsonl ? "--jsonl" : fields !== void 0 ? "--json=\u2026" : json ? "--json" : hitDetail === "brief" ? "--brief" : "";
|
|
4582
4663
|
if (other)
|
|
@@ -4640,7 +4721,7 @@ var silence = /* @__PURE__ */ __name((renderer) => ({
|
|
|
4640
4721
|
}, "warn")
|
|
4641
4722
|
}), "silence");
|
|
4642
4723
|
|
|
4643
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4724
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/runs/log-events.js
|
|
4644
4725
|
var CORE_LOG_EVENTS = defineLogEvents([
|
|
4645
4726
|
{ id: "provider.request", meaning: "a request went to the messenger", keys: ["operation"] },
|
|
4646
4727
|
{ id: "provider.response", meaning: "the messenger answered the request, or it failed", keys: ["operation"] },
|
|
@@ -4650,6 +4731,7 @@ var CORE_LOG_EVENTS = defineLogEvents([
|
|
|
4650
4731
|
meaning: "a read was answered from what was kept, without asking the messenger",
|
|
4651
4732
|
keys: ["operation", "reason"]
|
|
4652
4733
|
},
|
|
4734
|
+
{ id: "store.write", meaning: "a committed write changed rows of one store table", keys: ["table", "op", "n"] },
|
|
4653
4735
|
{ id: "command.crashed", meaning: "a command failed on a bug; where, never what", keys: ["error_class", "frames"] },
|
|
4654
4736
|
{
|
|
4655
4737
|
id: "events.dropped",
|
|
@@ -4671,487 +4753,11 @@ var DIAGNOSTIC_LOG_EVENTS = {
|
|
|
4671
4753
|
request: "provider.request",
|
|
4672
4754
|
response: "provider.response",
|
|
4673
4755
|
warning: "client.warning",
|
|
4674
|
-
cache: "cache.answered"
|
|
4675
|
-
|
|
4676
|
-
|
|
4677
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/runs/log-keys.js
|
|
4678
|
-
var snake2 = /* @__PURE__ */ __name((key) => key.replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`), "snake");
|
|
4679
|
-
var camel = /* @__PURE__ */ __name((key) => key.replace(/_([a-z0-9])/g, (_, letter) => letter.toUpperCase()), "camel");
|
|
4680
|
-
var renamed = /* @__PURE__ */ __name((record2, name) => Object.fromEntries(Object.entries(record2).map(([key, value]) => [name(key), value])), "renamed");
|
|
4681
|
-
var logAttributes = /* @__PURE__ */ __name((event2) => renamed(event2, snake2), "logAttributes");
|
|
4682
|
-
var fromLogAttributes = /* @__PURE__ */ __name((attributes) => renamed(attributes, camel), "fromLogAttributes");
|
|
4683
|
-
var snakeLogger = /* @__PURE__ */ __name((logger) => ({
|
|
4684
|
-
debug: /* @__PURE__ */ __name((event2, message2) => logger.debug(logAttributes(event2), message2), "debug"),
|
|
4685
|
-
info: /* @__PURE__ */ __name((event2, message2) => logger.info(logAttributes(event2), message2), "info"),
|
|
4686
|
-
warn: /* @__PURE__ */ __name((event2, message2) => logger.warn(logAttributes(event2), message2), "warn"),
|
|
4687
|
-
error: /* @__PURE__ */ __name((event2, message2) => logger.error(logAttributes(event2), message2), "error")
|
|
4688
|
-
}), "snakeLogger");
|
|
4689
|
-
|
|
4690
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/runs/run.js
|
|
4691
|
-
import { randomUUID } from "node:crypto";
|
|
4692
|
-
import { appendFileSync, mkdirSync, readdirSync as readdirSync2, readFileSync as readFileSync2, rmSync, statSync, writeFileSync } from "node:fs";
|
|
4693
|
-
import { userInfo } from "node:os";
|
|
4694
|
-
import { join as join2, sep } from "node:path";
|
|
4695
|
-
|
|
4696
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/runs/log-attributes.js
|
|
4697
|
-
var diagnostic = {
|
|
4698
|
-
event: true,
|
|
4699
|
-
operation: true,
|
|
4700
|
-
opcode: true,
|
|
4701
|
-
seq: true,
|
|
4702
|
-
status: true,
|
|
4703
|
-
method: true,
|
|
4704
|
-
endpointTemplate: true,
|
|
4705
|
-
bytes: true,
|
|
4706
|
-
ids: true,
|
|
4707
|
-
counts: true,
|
|
4708
|
-
durationMs: true,
|
|
4709
|
-
outcome: true,
|
|
4710
|
-
errorCode: true,
|
|
4711
|
-
providerError: true,
|
|
4712
|
-
level: true,
|
|
4713
|
-
transport: true,
|
|
4714
|
-
attempt: true,
|
|
4715
|
-
waitMs: true,
|
|
4716
|
-
code: true,
|
|
4717
|
-
detail: true,
|
|
4718
|
-
reason: true,
|
|
4719
|
-
ageMs: true
|
|
4720
|
-
};
|
|
4721
|
-
var send = {
|
|
4722
|
-
profile: true,
|
|
4723
|
-
chatId: true,
|
|
4724
|
-
outcome: true,
|
|
4725
|
-
kind: true,
|
|
4726
|
-
action: true,
|
|
4727
|
-
people: true,
|
|
4728
|
-
messageId: true,
|
|
4729
|
-
key: true,
|
|
4730
|
-
count: true,
|
|
4731
|
-
forEveryone: true,
|
|
4732
|
-
sendId: true,
|
|
4733
|
-
operationId: true,
|
|
4734
|
-
parentOperationId: true,
|
|
4735
|
-
replyTo: true,
|
|
4736
|
-
threadId: true,
|
|
4737
|
-
sendAs: true,
|
|
4738
|
-
resultChatId: true,
|
|
4739
|
-
length: true,
|
|
4740
|
-
attachments: true,
|
|
4741
|
-
scheduledFor: true,
|
|
4742
|
-
notify: true,
|
|
4743
|
-
origin: true,
|
|
4744
|
-
reservation: true,
|
|
4745
|
-
errorCode: true
|
|
4756
|
+
cache: "cache.answered",
|
|
4757
|
+
store: "store.write"
|
|
4746
4758
|
};
|
|
4747
|
-
var background = [
|
|
4748
|
-
"job",
|
|
4749
|
-
"pid",
|
|
4750
|
-
"schedule",
|
|
4751
|
-
"exitCode",
|
|
4752
|
-
"tool",
|
|
4753
|
-
"tier",
|
|
4754
|
-
"actorType",
|
|
4755
|
-
"actorId",
|
|
4756
|
-
"agent",
|
|
4757
|
-
"targetType",
|
|
4758
|
-
"targetId"
|
|
4759
|
-
];
|
|
4760
|
-
var crash = ["errorClass", "frames"];
|
|
4761
|
-
var dropped = ["dropped"];
|
|
4762
|
-
var LOG_ATTRIBUTES = [
|
|
4763
|
-
...new Set([...Object.keys(diagnostic), ...Object.keys(send), ...background, ...crash, ...dropped].map((key) => Object.keys(logAttributes({ [key]: true }))[0]))
|
|
4764
|
-
].sort();
|
|
4765
|
-
|
|
4766
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/runs/run.js
|
|
4767
|
-
var KEEP_RUNS_FOR_DAYS = 30;
|
|
4768
|
-
var KEEP_SUCCESSFUL_RUNS_FOR_DAYS = 7;
|
|
4769
|
-
var RUNS_SIZE_LIMIT_MB = 200;
|
|
4770
|
-
var runsDirFor = /* @__PURE__ */ __name((app, env = process.env) => join2(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "runs"), "runsDirFor");
|
|
4771
|
-
var startRun = /* @__PURE__ */ __name((options) => {
|
|
4772
|
-
const now = options.now ?? (() => /* @__PURE__ */ new Date());
|
|
4773
|
-
const startedAt = options.startedAt ?? now();
|
|
4774
|
-
const id6 = options.runId ?? newRunId(startedAt, options.command);
|
|
4775
|
-
const dir = join2(options.runsDir, day(startedAt), id6);
|
|
4776
|
-
pruneRuns(options.runsDir, {
|
|
4777
|
-
keepDays: options.keepDays ?? KEEP_RUNS_FOR_DAYS,
|
|
4778
|
-
keepSuccessDays: options.keepSuccessDays ?? KEEP_SUCCESSFUL_RUNS_FOR_DAYS,
|
|
4779
|
-
maxBytes: options.maxBytes ?? RUNS_SIZE_LIMIT_MB * 1024 * 1024,
|
|
4780
|
-
now: startedAt
|
|
4781
|
-
});
|
|
4782
|
-
refuseRealStateInTests(dir);
|
|
4783
|
-
const metadata = {
|
|
4784
|
-
runId: id6,
|
|
4785
|
-
command: options.command,
|
|
4786
|
-
...options.profile === void 0 ? {} : { profile: options.profile },
|
|
4787
|
-
startedAt: startedAt.toISOString(),
|
|
4788
|
-
status: "running",
|
|
4789
|
-
cliVersion: options.cliVersion,
|
|
4790
|
-
runtime: runtime(),
|
|
4791
|
-
platform: process.platform,
|
|
4792
|
-
arch: process.arch,
|
|
4793
|
-
...options.traceId === void 0 ? {} : { traceId: options.traceId },
|
|
4794
|
-
...options.context
|
|
4795
|
-
};
|
|
4796
|
-
let file;
|
|
4797
|
-
const opened = /* @__PURE__ */ __name(() => {
|
|
4798
|
-
if (file)
|
|
4799
|
-
return file;
|
|
4800
|
-
mkdirSync(dir, { recursive: true, mode: 448 });
|
|
4801
|
-
const events2 = join2(dir, "events.jsonl");
|
|
4802
|
-
writeFileSync(events2, "", { flag: "a", mode: 384 });
|
|
4803
|
-
file = snakeLogger(createRecordLog({
|
|
4804
|
-
to: events2,
|
|
4805
|
-
runId: id6,
|
|
4806
|
-
command: options.command,
|
|
4807
|
-
resource: { service: options.service, version: options.cliVersion },
|
|
4808
|
-
allow: LOG_ATTRIBUTES,
|
|
4809
|
-
...options.traceId === void 0 ? {} : { traceId: options.traceId },
|
|
4810
|
-
...options.onError === void 0 ? {} : { onError: options.onError }
|
|
4811
|
-
}));
|
|
4812
|
-
writeRunFile(dir, metadata);
|
|
4813
|
-
return file;
|
|
4814
|
-
}, "opened");
|
|
4815
|
-
if (!options.lazy)
|
|
4816
|
-
opened();
|
|
4817
|
-
let finished = false;
|
|
4818
|
-
const operations = /* @__PURE__ */ new Set();
|
|
4819
|
-
const codes = /* @__PURE__ */ new Set();
|
|
4820
|
-
const noted = /* @__PURE__ */ __name((level2) => (event2, message2) => {
|
|
4821
|
-
const { operation, errorCode, error_code, code } = event2;
|
|
4822
|
-
if (typeof operation === "string")
|
|
4823
|
-
operations.add(operation);
|
|
4824
|
-
for (const value of [errorCode, error_code, code])
|
|
4825
|
-
if (typeof value === "string")
|
|
4826
|
-
codes.add(value);
|
|
4827
|
-
if (finished)
|
|
4828
|
-
return;
|
|
4829
|
-
opened()[level2](event2, message2);
|
|
4830
|
-
}, "noted");
|
|
4831
|
-
const logger = { debug: noted("debug"), info: noted("info"), warn: noted("warn"), error: noted("error") };
|
|
4832
|
-
return {
|
|
4833
|
-
id: id6,
|
|
4834
|
-
dir,
|
|
4835
|
-
logger,
|
|
4836
|
-
finish: /* @__PURE__ */ __name(async (status2, extra = {}) => {
|
|
4837
|
-
if (finished)
|
|
4838
|
-
return;
|
|
4839
|
-
finished = true;
|
|
4840
|
-
const completedAt = now();
|
|
4841
|
-
const final = {
|
|
4842
|
-
...metadata,
|
|
4843
|
-
...extra,
|
|
4844
|
-
status: status2,
|
|
4845
|
-
completedAt: completedAt.toISOString(),
|
|
4846
|
-
durationMs: completedAt.getTime() - startedAt.getTime(),
|
|
4847
|
-
operations: [...operations].sort(),
|
|
4848
|
-
codes: [...codes].sort()
|
|
4849
|
-
};
|
|
4850
|
-
if (file || status2 !== "success") {
|
|
4851
|
-
opened();
|
|
4852
|
-
writeRunFile(dir, final);
|
|
4853
|
-
return;
|
|
4854
|
-
}
|
|
4855
|
-
try {
|
|
4856
|
-
mkdirSync(join2(dir, ".."), { recursive: true, mode: 448 });
|
|
4857
|
-
appendIndex(join2(dir, ".."), runFileOf(final));
|
|
4858
|
-
} catch (error) {
|
|
4859
|
-
options.onError?.(error);
|
|
4860
|
-
}
|
|
4861
|
-
}, "finish")
|
|
4862
|
-
};
|
|
4863
|
-
}, "startRun");
|
|
4864
|
-
var refuseRealStateInTests = /* @__PURE__ */ __name((dir, env = process.env) => {
|
|
4865
|
-
if (env.VITEST === void 0)
|
|
4866
|
-
return;
|
|
4867
|
-
let home;
|
|
4868
|
-
try {
|
|
4869
|
-
home = userInfo().homedir;
|
|
4870
|
-
} catch {
|
|
4871
|
-
return;
|
|
4872
|
-
}
|
|
4873
|
-
if (dir.startsWith(join2(home, ".local", "share") + sep))
|
|
4874
|
-
throw new Error(`a test opened a run in the real data folder: ${dir}`);
|
|
4875
|
-
}, "refuseRealStateInTests");
|
|
4876
|
-
var runtime = /* @__PURE__ */ __name(() => {
|
|
4877
|
-
const bun = process.versions.bun;
|
|
4878
|
-
return bun ? `bun ${bun}` : `node ${process.versions.node}`;
|
|
4879
|
-
}, "runtime");
|
|
4880
|
-
var newRunId = /* @__PURE__ */ __name((startedAt, command) => {
|
|
4881
|
-
const stamp = startedAt.toISOString().replace(/[-:]/g, "").replace(/\.\d+Z$/, "Z");
|
|
4882
|
-
const slug2 = command.replace(/[^a-z0-9]+/gi, "-").toLowerCase();
|
|
4883
|
-
return `${stamp}-${slug2}-${randomUUID().slice(0, 6)}`;
|
|
4884
|
-
}, "newRunId");
|
|
4885
|
-
var INDEX = "index.jsonl";
|
|
4886
|
-
var appendIndex = /* @__PURE__ */ __name((dayDir, written) => {
|
|
4887
|
-
appendFileSync(join2(dayDir, INDEX), `${JSON.stringify(written)}
|
|
4888
|
-
`, { mode: 384 });
|
|
4889
|
-
}, "appendIndex");
|
|
4890
|
-
var writeRunFile = /* @__PURE__ */ __name((dir, metadata) => {
|
|
4891
|
-
const written = runFileOf(metadata);
|
|
4892
|
-
writeSecurely(join2(dir, "run.json"), `${JSON.stringify(written, null, 2)}
|
|
4893
|
-
`, 384);
|
|
4894
|
-
try {
|
|
4895
|
-
appendIndex(join2(dir, ".."), written);
|
|
4896
|
-
} catch {
|
|
4897
|
-
}
|
|
4898
|
-
}, "writeRunFile");
|
|
4899
|
-
var matchesListFilter = /* @__PURE__ */ __name((run, filter) => (filter.runId === void 0 || run.runId === filter.runId) && (filter.command === void 0 || run.command === filter.command) && (filter.profile === void 0 || run.profile === filter.profile) && (filter.status === void 0 || run.status === filter.status) && (filter.errorCode === void 0 || run.errorCode === filter.errorCode), "matchesListFilter");
|
|
4900
|
-
var listRuns = /* @__PURE__ */ __name((runsDir, { since, atLeast = Number.POSITIVE_INFINITY, filter = {} } = {}) => {
|
|
4901
|
-
const first2 = since === void 0 ? void 0 : day(new Date(since));
|
|
4902
|
-
const runs = [];
|
|
4903
|
-
for (const date of days(runsDir).sort().reverse()) {
|
|
4904
|
-
if (first2 !== void 0 && date < first2 || runs.length >= atLeast)
|
|
4905
|
-
break;
|
|
4906
|
-
for (const metadata of runsOfDay(join2(runsDir, date))) {
|
|
4907
|
-
if (matchesListFilter(metadata, filter))
|
|
4908
|
-
runs.push(metadata);
|
|
4909
|
-
}
|
|
4910
|
-
}
|
|
4911
|
-
return runs;
|
|
4912
|
-
}, "listRuns");
|
|
4913
|
-
var indexedRuns = /* @__PURE__ */ __name((dayDir) => {
|
|
4914
|
-
const latest = /* @__PURE__ */ new Map();
|
|
4915
|
-
let raw = "";
|
|
4916
|
-
try {
|
|
4917
|
-
raw = readFileSync2(join2(dayDir, INDEX), "utf8");
|
|
4918
|
-
} catch {
|
|
4919
|
-
}
|
|
4920
|
-
for (const line of raw.split("\n")) {
|
|
4921
|
-
if (line.trim() === "")
|
|
4922
|
-
continue;
|
|
4923
|
-
try {
|
|
4924
|
-
const metadata = metadataOf(JSON.parse(line));
|
|
4925
|
-
if (typeof metadata.runId === "string")
|
|
4926
|
-
latest.set(metadata.runId, metadata);
|
|
4927
|
-
} catch {
|
|
4928
|
-
}
|
|
4929
|
-
}
|
|
4930
|
-
return latest;
|
|
4931
|
-
}, "indexedRuns");
|
|
4932
|
-
var runsOfDay = /* @__PURE__ */ __name((dayDir) => {
|
|
4933
|
-
const latest = indexedRuns(dayDir);
|
|
4934
|
-
for (const entry of safeReaddir(dayDir)) {
|
|
4935
|
-
if (entry === INDEX || entry.startsWith(".") || latest.has(entry))
|
|
4936
|
-
continue;
|
|
4937
|
-
const metadata = readRun(join2(dayDir, entry));
|
|
4938
|
-
if (metadata)
|
|
4939
|
-
latest.set(metadata.runId, metadata);
|
|
4940
|
-
}
|
|
4941
|
-
return [...latest.values()].sort((a, b) => a.runId < b.runId ? 1 : a.runId > b.runId ? -1 : 0);
|
|
4942
|
-
}, "runsOfDay");
|
|
4943
|
-
var findRun = /* @__PURE__ */ __name((runsDir, id6) => {
|
|
4944
|
-
const stamped = /^(\d{4})(\d{2})(\d{2})T/.exec(id6);
|
|
4945
|
-
const likely = stamped ? [`${stamped[1]}-${stamped[2]}-${stamped[3]}`] : [];
|
|
4946
|
-
const dates = [.../* @__PURE__ */ new Set([...likely, ...days(runsDir)])];
|
|
4947
|
-
for (const date of dates) {
|
|
4948
|
-
const dir = join2(runsDir, date, id6);
|
|
4949
|
-
const metadata = readRun(dir);
|
|
4950
|
-
if (metadata)
|
|
4951
|
-
return { dir, metadata };
|
|
4952
|
-
}
|
|
4953
|
-
for (const date of dates) {
|
|
4954
|
-
const metadata = indexedRuns(join2(runsDir, date)).get(id6);
|
|
4955
|
-
if (metadata)
|
|
4956
|
-
return { dir: join2(runsDir, date, id6), metadata };
|
|
4957
|
-
}
|
|
4958
|
-
return void 0;
|
|
4959
|
-
}, "findRun");
|
|
4960
|
-
var readEvents = /* @__PURE__ */ __name((dir) => {
|
|
4961
|
-
let raw;
|
|
4962
|
-
try {
|
|
4963
|
-
raw = readFileSync2(join2(dir, "events.jsonl"), "utf8");
|
|
4964
|
-
} catch {
|
|
4965
|
-
return [];
|
|
4966
|
-
}
|
|
4967
|
-
const events2 = [];
|
|
4968
|
-
for (const line of raw.split("\n")) {
|
|
4969
|
-
if (line.trim() === "")
|
|
4970
|
-
continue;
|
|
4971
|
-
try {
|
|
4972
|
-
const parsed = JSON.parse(line);
|
|
4973
|
-
if (parsed !== null && typeof parsed === "object")
|
|
4974
|
-
events2.push(eventOf(parsed));
|
|
4975
|
-
} catch {
|
|
4976
|
-
}
|
|
4977
|
-
}
|
|
4978
|
-
return events2;
|
|
4979
|
-
}, "readEvents");
|
|
4980
|
-
var eventOf = /* @__PURE__ */ __name((line) => {
|
|
4981
|
-
const { attributes, time: time2, severity } = line;
|
|
4982
|
-
if (attributes === null || typeof attributes !== "object")
|
|
4983
|
-
return logAttributes(line);
|
|
4984
|
-
return { time: time2, severity, ...logAttributes(attributes) };
|
|
4985
|
-
}, "eventOf");
|
|
4986
|
-
var pruneRuns = /* @__PURE__ */ __name((runsDir, { keepDays, keepSuccessDays = keepDays, maxBytes, now }) => {
|
|
4987
|
-
const cutoff = day(new Date(now.getTime() - keepDays * DAY_MS));
|
|
4988
|
-
const successCutoff = day(new Date(now.getTime() - Math.min(keepSuccessDays, keepDays) * DAY_MS));
|
|
4989
|
-
let removed = 0;
|
|
4990
|
-
for (const date of days(runsDir)) {
|
|
4991
|
-
if (date >= cutoff) {
|
|
4992
|
-
if (date < successCutoff)
|
|
4993
|
-
dropSuccesses(join2(runsDir, date));
|
|
4994
|
-
continue;
|
|
4995
|
-
}
|
|
4996
|
-
try {
|
|
4997
|
-
rmSync(join2(runsDir, date), { recursive: true, force: true });
|
|
4998
|
-
removed += 1;
|
|
4999
|
-
} catch {
|
|
5000
|
-
}
|
|
5001
|
-
}
|
|
5002
|
-
if (maxBytes !== void 0)
|
|
5003
|
-
removed += fitSize(runsDir, maxBytes, now);
|
|
5004
|
-
return removed;
|
|
5005
|
-
}, "pruneRuns");
|
|
5006
|
-
var DAY_MS = 24 * 60 * 60 * 1e3;
|
|
5007
|
-
var SUCCESSES_DROPPED = ".successes-dropped";
|
|
5008
|
-
var SIZE_CHECKED = ".size-checked";
|
|
5009
|
-
var dropSuccesses = /* @__PURE__ */ __name((dayDir) => {
|
|
5010
|
-
const marker = join2(dayDir, SUCCESSES_DROPPED);
|
|
5011
|
-
try {
|
|
5012
|
-
statSync(marker);
|
|
5013
|
-
return;
|
|
5014
|
-
} catch {
|
|
5015
|
-
}
|
|
5016
|
-
try {
|
|
5017
|
-
const kept = [];
|
|
5018
|
-
for (const [id6, metadata] of indexedRuns(dayDir)) {
|
|
5019
|
-
if (metadata.status === "success")
|
|
5020
|
-
rmSync(join2(dayDir, id6), { recursive: true, force: true });
|
|
5021
|
-
else
|
|
5022
|
-
kept.push(JSON.stringify(runFileOf(metadata)));
|
|
5023
|
-
}
|
|
5024
|
-
for (const entry of safeReaddir(dayDir)) {
|
|
5025
|
-
if (entry === INDEX || entry.startsWith("."))
|
|
5026
|
-
continue;
|
|
5027
|
-
if (readRun(join2(dayDir, entry))?.status === "success")
|
|
5028
|
-
rmSync(join2(dayDir, entry), { recursive: true, force: true });
|
|
5029
|
-
}
|
|
5030
|
-
writeSecurely(join2(dayDir, INDEX), kept.map((line) => `${line}
|
|
5031
|
-
`).join(""), 384);
|
|
5032
|
-
writeFileSync(marker, "", { mode: 384 });
|
|
5033
|
-
} catch {
|
|
5034
|
-
}
|
|
5035
|
-
}, "dropSuccesses");
|
|
5036
|
-
var sizeOf = /* @__PURE__ */ __name((path2) => {
|
|
5037
|
-
let total = 0;
|
|
5038
|
-
for (const entry of safeReaddir(path2)) {
|
|
5039
|
-
const full = join2(path2, entry);
|
|
5040
|
-
try {
|
|
5041
|
-
const stat = statSync(full);
|
|
5042
|
-
total += stat.isDirectory() ? sizeOf(full) : stat.size;
|
|
5043
|
-
} catch {
|
|
5044
|
-
}
|
|
5045
|
-
}
|
|
5046
|
-
return total;
|
|
5047
|
-
}, "sizeOf");
|
|
5048
|
-
var fitSize = /* @__PURE__ */ __name((runsDir, maxBytes, now) => {
|
|
5049
|
-
const stamp = join2(runsDir, SIZE_CHECKED);
|
|
5050
|
-
const today = day(now);
|
|
5051
|
-
try {
|
|
5052
|
-
if (readFileSync2(stamp, "utf8").trim() === today)
|
|
5053
|
-
return 0;
|
|
5054
|
-
} catch {
|
|
5055
|
-
}
|
|
5056
|
-
const dates = days(runsDir).sort();
|
|
5057
|
-
const sizes = new Map(dates.map((date) => [date, sizeOf(join2(runsDir, date))]));
|
|
5058
|
-
let total = [...sizes.values()].reduce((sum, size) => sum + size, 0);
|
|
5059
|
-
let removed = 0;
|
|
5060
|
-
for (const date of dates) {
|
|
5061
|
-
if (total <= maxBytes || date === today)
|
|
5062
|
-
break;
|
|
5063
|
-
dropSuccesses(join2(runsDir, date));
|
|
5064
|
-
const after = sizeOf(join2(runsDir, date));
|
|
5065
|
-
total -= (sizes.get(date) ?? 0) - after;
|
|
5066
|
-
sizes.set(date, after);
|
|
5067
|
-
}
|
|
5068
|
-
for (const date of dates) {
|
|
5069
|
-
if (total <= maxBytes || date === today)
|
|
5070
|
-
break;
|
|
5071
|
-
try {
|
|
5072
|
-
rmSync(join2(runsDir, date), { recursive: true, force: true });
|
|
5073
|
-
total -= sizes.get(date) ?? 0;
|
|
5074
|
-
removed += 1;
|
|
5075
|
-
} catch {
|
|
5076
|
-
}
|
|
5077
|
-
}
|
|
5078
|
-
try {
|
|
5079
|
-
mkdirSync(runsDir, { recursive: true, mode: 448 });
|
|
5080
|
-
writeFileSync(stamp, today, { mode: 384 });
|
|
5081
|
-
} catch {
|
|
5082
|
-
}
|
|
5083
|
-
return removed;
|
|
5084
|
-
}, "fitSize");
|
|
5085
|
-
var day = /* @__PURE__ */ __name((date) => date.toISOString().slice(0, 10), "day");
|
|
5086
|
-
var days = /* @__PURE__ */ __name((runsDir) => safeReaddir(runsDir).filter((entry) => /^\d{4}-\d{2}-\d{2}$/.test(entry)), "days");
|
|
5087
|
-
var readRun = /* @__PURE__ */ __name((dir) => {
|
|
5088
|
-
try {
|
|
5089
|
-
return metadataOf(JSON.parse(readFileSync2(join2(dir, "run.json"), "utf8")));
|
|
5090
|
-
} catch {
|
|
5091
|
-
return void 0;
|
|
5092
|
-
}
|
|
5093
|
-
}, "readRun");
|
|
5094
|
-
var safeReaddir = /* @__PURE__ */ __name((dir) => {
|
|
5095
|
-
try {
|
|
5096
|
-
return readdirSync2(dir);
|
|
5097
|
-
} catch {
|
|
5098
|
-
return [];
|
|
5099
|
-
}
|
|
5100
|
-
}, "safeReaddir");
|
|
5101
|
-
var runFileOf = /* @__PURE__ */ __name(({ partial: partial2, ...metadata }) => ({
|
|
5102
|
-
...logAttributes(metadata),
|
|
5103
|
-
...partial2 ? { partial: { ...logAttributes(partial2), failures: partial2.failures.map((failure) => logAttributes(failure)) } } : {}
|
|
5104
|
-
}), "runFileOf");
|
|
5105
|
-
var metadataOf = /* @__PURE__ */ __name((parsed) => {
|
|
5106
|
-
const { partial: partial2, ...metadata } = fromLogAttributes(parsed);
|
|
5107
|
-
if (partial2 === null || typeof partial2 !== "object")
|
|
5108
|
-
return metadata;
|
|
5109
|
-
const { failures, ...rest } = fromLogAttributes(partial2);
|
|
5110
|
-
return {
|
|
5111
|
-
...metadata,
|
|
5112
|
-
partial: {
|
|
5113
|
-
...rest,
|
|
5114
|
-
failures: Array.isArray(failures) ? failures.map((failure) => fromLogAttributes(failure)) : []
|
|
5115
|
-
}
|
|
5116
|
-
};
|
|
5117
|
-
}, "metadataOf");
|
|
5118
4759
|
|
|
5119
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5120
|
-
import { AsyncLocalStorage as AsyncLocalStorage2 } from "node:async_hooks";
|
|
5121
|
-
import { randomBytes } from "node:crypto";
|
|
5122
|
-
var scopes = new AsyncLocalStorage2();
|
|
5123
|
-
var processScope;
|
|
5124
|
-
var currentRun = /* @__PURE__ */ __name(() => {
|
|
5125
|
-
const scope = scopes.getStore();
|
|
5126
|
-
if (scope)
|
|
5127
|
-
return scope;
|
|
5128
|
-
processScope ??= {
|
|
5129
|
-
runId: newRunId(/* @__PURE__ */ new Date(), "process"),
|
|
5130
|
-
command: "",
|
|
5131
|
-
startedAt: Date.now(),
|
|
5132
|
-
...traceOf(process.env)
|
|
5133
|
-
};
|
|
5134
|
-
return processScope;
|
|
5135
|
-
}, "currentRun");
|
|
5136
|
-
var inRun = /* @__PURE__ */ __name((scope, body) => scopes.run(scope, body), "inRun");
|
|
5137
|
-
var typedCommand = /* @__PURE__ */ __name((tool, words2, profile = currentRun().profile) => [tool, profile, words2].filter((part) => part !== void 0 && part !== "").join(" "), "typedCommand");
|
|
5138
|
-
var useAsProcessRun = /* @__PURE__ */ __name((scope) => {
|
|
5139
|
-
processScope = scope;
|
|
5140
|
-
}, "useAsProcessRun");
|
|
5141
|
-
var enclosingTraceId = /* @__PURE__ */ __name(() => scopes.getStore()?.traceId, "enclosingTraceId");
|
|
5142
|
-
var traceOf = /* @__PURE__ */ __name((env) => {
|
|
5143
|
-
const traceId = traceIdOf(env.TRACEPARENT);
|
|
5144
|
-
return traceId === void 0 ? {} : { traceId };
|
|
5145
|
-
}, "traceOf");
|
|
5146
|
-
var childTrace = /* @__PURE__ */ __name(() => {
|
|
5147
|
-
const hex = /* @__PURE__ */ __name((bytes) => randomBytes(bytes).toString("hex"), "hex");
|
|
5148
|
-
const traceId = hex(16);
|
|
5149
|
-
return { traceId, traceparent: `00-${traceId}-${hex(8)}-01` };
|
|
5150
|
-
}, "childTrace");
|
|
5151
|
-
var attempts = new AsyncLocalStorage2();
|
|
5152
|
-
var withAttempt = /* @__PURE__ */ __name((attempt, work) => attempts.run(attempt, work), "withAttempt");
|
|
5153
|
-
|
|
5154
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/runs/recording.js
|
|
4760
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/runs/recording.js
|
|
5155
4761
|
var recorded = /* @__PURE__ */ __name(async (options, body) => {
|
|
5156
4762
|
const recording = startRecording(options);
|
|
5157
4763
|
try {
|
|
@@ -5197,6 +4803,7 @@ var startRecording = /* @__PURE__ */ __name((options) => {
|
|
|
5197
4803
|
}, "onError"),
|
|
5198
4804
|
...options.keepDays === void 0 ? {} : { keepDays: options.keepDays },
|
|
5199
4805
|
...options.keepSuccessDays === void 0 ? {} : { keepSuccessDays: options.keepSuccessDays },
|
|
4806
|
+
...options.keepStoreDays === void 0 ? {} : { keepStoreDays: options.keepStoreDays },
|
|
5200
4807
|
...options.maxBytes === void 0 ? {} : { maxBytes: options.maxBytes },
|
|
5201
4808
|
now,
|
|
5202
4809
|
...extra
|
|
@@ -5205,6 +4812,7 @@ var startRecording = /* @__PURE__ */ __name((options) => {
|
|
|
5205
4812
|
const held = !run && options.keepFailed ? [] : void 0;
|
|
5206
4813
|
const counted = { wire: 0, operation: 0 };
|
|
5207
4814
|
let refused;
|
|
4815
|
+
let wroteStore = false;
|
|
5208
4816
|
const cap = capped();
|
|
5209
4817
|
const requests = /* @__PURE__ */ __name(() => counted.wire > 0 ? counted.wire : counted.operation, "requests");
|
|
5210
4818
|
const events2 = /* @__PURE__ */ __name((event2) => {
|
|
@@ -5212,6 +4820,8 @@ var startRecording = /* @__PURE__ */ __name((options) => {
|
|
|
5212
4820
|
counted[event2.level === "wire" ? "wire" : "operation"] += 1;
|
|
5213
4821
|
if (event2.event === "response" && event2.outcome === "error")
|
|
5214
4822
|
refused = event2;
|
|
4823
|
+
if (event2.event === "store")
|
|
4824
|
+
wroteStore = true;
|
|
5215
4825
|
if (options.trace)
|
|
5216
4826
|
streams.diagnostic(options.format === "pretty" ? renderEvent(event2) : JSON.stringify(logAttributes(event2)));
|
|
5217
4827
|
if (run)
|
|
@@ -5233,13 +4843,14 @@ var startRecording = /* @__PURE__ */ __name((options) => {
|
|
|
5233
4843
|
events: events2,
|
|
5234
4844
|
succeed: /* @__PURE__ */ __name(async (answer) => {
|
|
5235
4845
|
const partial2 = partialOutcome(answer);
|
|
5236
|
-
const kept = run ?? (partial2 && held ? keep(open({ startedAt })) : void 0);
|
|
4846
|
+
const kept = run ?? ((partial2 || wroteStore) && held ? keep(open({ startedAt })) : void 0);
|
|
5237
4847
|
if (kept)
|
|
5238
4848
|
cap.close(kept);
|
|
5239
4849
|
await kept?.finish(partial2 ? "partial" : "success", {
|
|
5240
4850
|
requests: requests(),
|
|
5241
4851
|
...cap.dropped(),
|
|
5242
|
-
...partial2 ? { partial: partial2 } : {}
|
|
4852
|
+
...partial2 ? { partial: partial2 } : {},
|
|
4853
|
+
...!run && !partial2 && wroteStore ? { keptBecauseStore: true } : {}
|
|
5243
4854
|
});
|
|
5244
4855
|
}, "succeed"),
|
|
5245
4856
|
fail: /* @__PURE__ */ __name(async (thrown) => {
|
|
@@ -5274,29 +4885,47 @@ var wasSettled = /* @__PURE__ */ __name((error) => typeof error === "object" &&
|
|
|
5274
4885
|
var HELD_AT_MOST = 500;
|
|
5275
4886
|
var EVENTS_AT_MOST = 2e3;
|
|
5276
4887
|
var EVENT_BYTES_AT_MOST = 1024 * 1024;
|
|
4888
|
+
var STORE_EVENTS_AT_MOST = 100;
|
|
5277
4889
|
var capped = /* @__PURE__ */ __name(() => {
|
|
5278
4890
|
let lines = 0;
|
|
5279
4891
|
let bytes = 0;
|
|
5280
|
-
let
|
|
4892
|
+
let dropped = 0;
|
|
4893
|
+
let stores = 0;
|
|
5281
4894
|
const byOperation = {};
|
|
4895
|
+
const summed = /* @__PURE__ */ new Map();
|
|
4896
|
+
const write = /* @__PURE__ */ __name((run, event2) => {
|
|
4897
|
+
const size = JSON.stringify(logAttributes(event2)).length + 200;
|
|
4898
|
+
if (lines >= EVENTS_AT_MOST || bytes + size > EVENT_BYTES_AT_MOST) {
|
|
4899
|
+
dropped += 1;
|
|
4900
|
+
const operation = "operation" in event2 && event2.operation ? event2.operation : event2.event;
|
|
4901
|
+
byOperation[operation] = (byOperation[operation] ?? 0) + 1;
|
|
4902
|
+
return;
|
|
4903
|
+
}
|
|
4904
|
+
lines += 1;
|
|
4905
|
+
bytes += size;
|
|
4906
|
+
logEvent(run, event2);
|
|
4907
|
+
}, "write");
|
|
5282
4908
|
return {
|
|
5283
4909
|
log: /* @__PURE__ */ __name((run, event2) => {
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5288
|
-
|
|
4910
|
+
if (event2.event === "store" && ++stores > STORE_EVENTS_AT_MOST) {
|
|
4911
|
+
const key = `${event2.table} ${event2.op}`;
|
|
4912
|
+
const sum = summed.get(key);
|
|
4913
|
+
if (sum)
|
|
4914
|
+
sum.n += event2.n;
|
|
4915
|
+
else
|
|
4916
|
+
summed.set(key, { ...event2 });
|
|
5289
4917
|
return;
|
|
5290
4918
|
}
|
|
5291
|
-
|
|
5292
|
-
bytes += size;
|
|
5293
|
-
logEvent(run, event2);
|
|
4919
|
+
write(run, event2);
|
|
5294
4920
|
}, "log"),
|
|
5295
4921
|
close: /* @__PURE__ */ __name((run) => {
|
|
5296
|
-
|
|
5297
|
-
run
|
|
4922
|
+
for (const sum of summed.values())
|
|
4923
|
+
write(run, sum);
|
|
4924
|
+
summed.clear();
|
|
4925
|
+
if (dropped > 0)
|
|
4926
|
+
run.logger.warn({ event: "events.dropped", dropped, counts: byOperation });
|
|
5298
4927
|
}, "close"),
|
|
5299
|
-
dropped: /* @__PURE__ */ __name(() =>
|
|
4928
|
+
dropped: /* @__PURE__ */ __name(() => dropped > 0 ? { eventsDropped: dropped } : {}, "dropped")
|
|
5300
4929
|
};
|
|
5301
4930
|
}, "capped");
|
|
5302
4931
|
var logEvent = /* @__PURE__ */ __name((run, event2) => {
|
|
@@ -5307,7 +4936,7 @@ var logEvent = /* @__PURE__ */ __name((run, event2) => {
|
|
|
5307
4936
|
};
|
|
5308
4937
|
if (event2.event === "warning")
|
|
5309
4938
|
run.logger.warn(record2);
|
|
5310
|
-
else if (event2.event
|
|
4939
|
+
else if ((event2.event === "request" || event2.event === "response") && event2.outcome === "error")
|
|
5311
4940
|
run.logger.error(record2);
|
|
5312
4941
|
else
|
|
5313
4942
|
run.logger.info(record2);
|
|
@@ -5343,14 +4972,14 @@ var partialOutcome = /* @__PURE__ */ __name((answer) => {
|
|
|
5343
4972
|
return void 0;
|
|
5344
4973
|
}, "partialOutcome");
|
|
5345
4974
|
|
|
5346
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4975
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/deadline.js
|
|
5347
4976
|
var withDeadline = /* @__PURE__ */ __name(async (ms2, closeables, body) => {
|
|
5348
4977
|
if (ms2 === void 0)
|
|
5349
4978
|
return body();
|
|
5350
4979
|
let timer2;
|
|
5351
4980
|
let timedOut;
|
|
5352
4981
|
const writes2 = /* @__PURE__ */ new Set();
|
|
5353
|
-
const expired = new Promise((
|
|
4982
|
+
const expired = new Promise((_2, reject) => {
|
|
5354
4983
|
timer2 = setTimeout(() => {
|
|
5355
4984
|
const pending = [...writes2];
|
|
5356
4985
|
const cut2 = pending.filter((write) => !write.preparing);
|
|
@@ -5369,52 +4998,10 @@ var withDeadline = /* @__PURE__ */ __name(async (ms2, closeables, body) => {
|
|
|
5369
4998
|
}
|
|
5370
4999
|
}, "withDeadline");
|
|
5371
5000
|
|
|
5372
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5373
|
-
|
|
5374
|
-
var PLAIN_NAME = /^[A-Za-z0-9][A-Za-z0-9._-]*$/;
|
|
5375
|
-
var isProfileName = /* @__PURE__ */ __name((word) => PLAIN_NAME.test(word), "isProfileName");
|
|
5376
|
-
var usableProfileName = /* @__PURE__ */ __name((profile) => {
|
|
5377
|
-
if (!isProfileName(profile)) {
|
|
5378
|
-
throw new CliError("validation_error", `"${profile}" cannot be a profile name \u2014 letters, digits, dot, dash and underscore only, starting with a letter or a digit`);
|
|
5379
|
-
}
|
|
5380
|
-
return profile;
|
|
5381
|
-
}, "usableProfileName");
|
|
5382
|
-
var PROFILE_FREE = /* @__PURE__ */ new Set(["commands", "complete", "guide", "help", "skill", "upgrade"]);
|
|
5383
|
-
var freeOfProfile = /* @__PURE__ */ new WeakSet();
|
|
5384
|
-
var profileFree = /* @__PURE__ */ __name((command) => {
|
|
5385
|
-
freeOfProfile.add(command);
|
|
5386
|
-
return command;
|
|
5387
|
-
}, "profileFree");
|
|
5388
|
-
var takesProfile = /* @__PURE__ */ __name((command) => {
|
|
5389
|
-
let top;
|
|
5390
|
-
for (let at2 = command; at2?.parent; at2 = at2.parent) {
|
|
5391
|
-
if (freeOfProfile.has(at2))
|
|
5392
|
-
return false;
|
|
5393
|
-
top = at2;
|
|
5394
|
-
}
|
|
5395
|
-
return top !== void 0 && !PROFILE_FREE.has(top.name());
|
|
5396
|
-
}, "takesProfile");
|
|
5397
|
-
var commandWords = /* @__PURE__ */ __name((program2) => /* @__PURE__ */ new Set(["help", ...program2.commands.flatMap((command) => [command.name(), ...command.aliases()])]), "commandWords");
|
|
5398
|
-
var liftProfile = /* @__PURE__ */ __name((argv, words2, valued = /* @__PURE__ */ new Set()) => {
|
|
5399
|
-
let at2 = 0;
|
|
5400
|
-
while (argv[at2]?.startsWith("-") && argv[at2] !== "--")
|
|
5401
|
-
at2 += valued.has(argv[at2]) ? 2 : 1;
|
|
5402
|
-
const first2 = argv[at2];
|
|
5403
|
-
if (first2 === void 0 || first2.startsWith("-") || words2.has(first2))
|
|
5404
|
-
return { rest: argv };
|
|
5405
|
-
return { profile: first2, rest: [...argv.slice(0, at2), ...argv.slice(at2 + 1)] };
|
|
5406
|
-
}, "liftProfile");
|
|
5407
|
-
var rootOf = /* @__PURE__ */ __name((command) => {
|
|
5408
|
-
let root = command;
|
|
5409
|
-
while (root.parent)
|
|
5410
|
-
root = root.parent;
|
|
5411
|
-
return root;
|
|
5412
|
-
}, "rootOf");
|
|
5413
|
-
|
|
5414
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/cli/settings.js
|
|
5415
|
-
import { existsSync as existsSync4 } from "node:fs";
|
|
5001
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/settings.js
|
|
5002
|
+
import { existsSync as existsSync5 } from "node:fs";
|
|
5416
5003
|
|
|
5417
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5004
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/models/endpoint.js
|
|
5418
5005
|
var endpoint = /* @__PURE__ */ __name((value) => {
|
|
5419
5006
|
try {
|
|
5420
5007
|
const url3 = new URL(value);
|
|
@@ -5424,7 +5011,7 @@ var endpoint = /* @__PURE__ */ __name((value) => {
|
|
|
5424
5011
|
}
|
|
5425
5012
|
}, "endpoint");
|
|
5426
5013
|
|
|
5427
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5014
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/models/settings.js
|
|
5428
5015
|
var MODEL_FIELDS = ["provider", "model", "base_url"];
|
|
5429
5016
|
var modelSettingsShape = record(pipe(string(), regex(/^[a-z][a-z0-9-]*$/)), strictObject({
|
|
5430
5017
|
provider: optional(picklist(["off", "openai", "anthropic"])),
|
|
@@ -5493,7 +5080,7 @@ var modelTarget = /* @__PURE__ */ __name((settings, purpose) => {
|
|
|
5493
5080
|
};
|
|
5494
5081
|
}, "modelTarget");
|
|
5495
5082
|
|
|
5496
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5083
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/analysis/settings.js
|
|
5497
5084
|
var model = pipe(string(), trim(), minLength(1), maxLength(200));
|
|
5498
5085
|
var url2 = pipe(string(), check(endpoint, "use an HTTP/S endpoint without credentials, query or fragment"));
|
|
5499
5086
|
var AI_FIELDS = {
|
|
@@ -5537,7 +5124,7 @@ var resolveAISettings = /* @__PURE__ */ __name((prefix, layers, env) => {
|
|
|
5537
5124
|
};
|
|
5538
5125
|
}, "resolveAISettings");
|
|
5539
5126
|
|
|
5540
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5127
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/domain/duration.js
|
|
5541
5128
|
var DURATION = /^(\d+)(ms|s|m|h|d)$/;
|
|
5542
5129
|
var UNIT_MS = { ms: 1, s: 1e3, m: 6e4, h: 36e5, d: 864e5 };
|
|
5543
5130
|
var parseDuration = /* @__PURE__ */ __name((value, source2) => {
|
|
@@ -5551,7 +5138,9 @@ var parseDuration = /* @__PURE__ */ __name((value, source2) => {
|
|
|
5551
5138
|
return ms2;
|
|
5552
5139
|
}, "parseDuration");
|
|
5553
5140
|
|
|
5554
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5141
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/embeddings/models.js
|
|
5142
|
+
import { existsSync as existsSync2 } from "node:fs";
|
|
5143
|
+
import { join as join2 } from "node:path";
|
|
5555
5144
|
var huggingFace = /* @__PURE__ */ __name((repository, commit) => (name) => `https://huggingface.co/${repository}/resolve/${commit}/${name}`, "huggingFace");
|
|
5556
5145
|
var e5 = huggingFace("Xenova/multilingual-e5-small", "761b726dd34fb83930e26aab4e9ac3899aa1fa78");
|
|
5557
5146
|
var e5Large = huggingFace("Xenova/multilingual-e5-large", "00fc3aeb3dbb95842de2ac1961d33c6319acf57b");
|
|
@@ -5598,9 +5187,13 @@ var TEXT_MODELS = [
|
|
|
5598
5187
|
languages: "over 100 languages \u2014 the best of the two on chat, about seven times slower",
|
|
5599
5188
|
licence: "Gemma Terms of Use",
|
|
5600
5189
|
terms: "https://ai.google.dev/gemma/terms",
|
|
5190
|
+
// Gemma Terms of Use §3.1: every copy carries this notice and the use restrictions of §3.2.
|
|
5191
|
+
notice: "Gemma is provided under and subject to the Gemma Terms of Use found at ai.google.dev/gemma/terms. Its use is restricted by the Gemma Prohibited Use Policy: https://ai.google.dev/gemma/prohibited_use_policy",
|
|
5601
5192
|
dims: 768,
|
|
5602
5193
|
maxTokens: 2048,
|
|
5603
|
-
|
|
5194
|
+
// 2026-11-08, 1,200-character chunks, 8 threads on the Ryzen AI 9 HX 470: 8.3 chunks/s against e5-small's 52.7, so
|
|
5195
|
+
// 5 on the scale e5-small's 31 sets. It was 2, which held a memo sync to 39 chunks.
|
|
5196
|
+
chunksPerSecond: 5,
|
|
5604
5197
|
pooling: "sentence_embedding",
|
|
5605
5198
|
prefix: { query: "task: search result | query: ", passage: "title: none | text: " },
|
|
5606
5199
|
onnx: "onnx/model_q4.onnx",
|
|
@@ -5667,7 +5260,8 @@ var TEXT_MODELS = [
|
|
|
5667
5260
|
]
|
|
5668
5261
|
}
|
|
5669
5262
|
];
|
|
5670
|
-
var DEFAULT_TEXT_MODEL = "
|
|
5263
|
+
var DEFAULT_TEXT_MODEL = "embeddinggemma";
|
|
5264
|
+
var PREVIOUS_DEFAULT_TEXT_MODEL = "e5-small";
|
|
5671
5265
|
var SECTION = "text_models";
|
|
5672
5266
|
var slug = pipe(string(), regex(/^[a-z0-9][a-z0-9._-]{0,62}$/, "is not a model id: a-z, 0-9, . _ -"));
|
|
5673
5267
|
var words = pipe(string(), trim(), minLength(1), maxLength(300));
|
|
@@ -5706,10 +5300,10 @@ var TextModelsSection = strictObject({
|
|
|
5706
5300
|
var textModelsFile = /* @__PURE__ */ __name((env = process.env) => sharedConfigPath(storePath(env), env), "textModelsFile");
|
|
5707
5301
|
var readTextModelsSection = /* @__PURE__ */ __name((env = process.env) => {
|
|
5708
5302
|
const path2 = textModelsFile(env);
|
|
5709
|
-
const
|
|
5710
|
-
if (
|
|
5303
|
+
const section2 = readSharedSection(path2, SECTION);
|
|
5304
|
+
if (section2 === void 0)
|
|
5711
5305
|
return {};
|
|
5712
|
-
const checked = safeParse(TextModelsSection,
|
|
5306
|
+
const checked = safeParse(TextModelsSection, section2);
|
|
5713
5307
|
if (!checked.success) {
|
|
5714
5308
|
const issue = checked.issues[0];
|
|
5715
5309
|
const at2 = issue ? getDotPath(issue) : null;
|
|
@@ -5721,7 +5315,7 @@ var readTextModelsSection = /* @__PURE__ */ __name((env = process.env) => {
|
|
|
5721
5315
|
throw new CliError("configuration_error", `${path2}: ${SECTION}.custom names ${twice} twice`);
|
|
5722
5316
|
return checked.output;
|
|
5723
5317
|
}, "readTextModelsSection");
|
|
5724
|
-
var writeTextModelsSection = /* @__PURE__ */ __name((
|
|
5318
|
+
var writeTextModelsSection = /* @__PURE__ */ __name((section2, env = process.env) => writeSharedSection(textModelsFile(env), SECTION, section2.use === void 0 && !section2.custom?.length ? void 0 : section2), "writeTextModelsSection");
|
|
5725
5319
|
var textModels = /* @__PURE__ */ __name((env = process.env) => [
|
|
5726
5320
|
...TEXT_MODELS,
|
|
5727
5321
|
...(readTextModelsSection(env).custom ?? []).map((model3) => ({ ...model3, custom: true }))
|
|
@@ -5734,9 +5328,17 @@ var textModel = /* @__PURE__ */ __name((id6, env = process.env) => {
|
|
|
5734
5328
|
}
|
|
5735
5329
|
return found;
|
|
5736
5330
|
}, "textModel");
|
|
5331
|
+
var downloaded = /* @__PURE__ */ __name((id6, env) => {
|
|
5332
|
+
const model3 = TEXT_MODELS.find((one) => one.id === id6);
|
|
5333
|
+
const directory = sharedModelsDirectory("text", env);
|
|
5334
|
+
return model3 !== void 0 && filesPresent(model3.files.map((file) => [file, join2(directory, model3.id, file.name)]));
|
|
5335
|
+
}, "downloaded");
|
|
5737
5336
|
var chosenTextModel = /* @__PURE__ */ __name((env = process.env) => {
|
|
5738
5337
|
const use = readTextModelsSection(env).use;
|
|
5739
|
-
|
|
5338
|
+
if (use !== void 0)
|
|
5339
|
+
return { id: use, from: "chosen" };
|
|
5340
|
+
const kept = !downloaded(DEFAULT_TEXT_MODEL, env) && existsSync2(join2(sharedModelsDirectory("text", env), PREVIOUS_DEFAULT_TEXT_MODEL));
|
|
5341
|
+
return { id: kept ? PREVIOUS_DEFAULT_TEXT_MODEL : DEFAULT_TEXT_MODEL, from: "default" };
|
|
5740
5342
|
}, "chosenTextModel");
|
|
5741
5343
|
var mmarco = huggingFace("cross-encoder/mmarco-mMiniLMv2-L12-H384-v1", "1427fd652930e4ba29e8149678df786c240d8825");
|
|
5742
5344
|
var bge = huggingFace("onnx-community/bge-reranker-v2-m3-ONNX", "6f5ff65298512715a1e669753bc754d2bc8f367b");
|
|
@@ -5813,16 +5415,16 @@ var vectorModelKey = /* @__PURE__ */ __name((model3) => {
|
|
|
5813
5415
|
}, "vectorModelKey");
|
|
5814
5416
|
var meaningFloor = /* @__PURE__ */ __name((key) => key === "local:e5-small:384" ? 0.8 : 0, "meaningFloor");
|
|
5815
5417
|
|
|
5816
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5418
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/services/history-limits.js
|
|
5817
5419
|
var HISTORY_MAX_DAYS = 1095;
|
|
5818
5420
|
var DEFAULT_HISTORY_LIMITS = { dialogDays: 1095, groupDays: 365, groupMembersMax: 50 };
|
|
5819
|
-
var
|
|
5421
|
+
var DAY_MS = 24 * 60 * 60 * 1e3;
|
|
5820
5422
|
var historyWindow = /* @__PURE__ */ __name((shape, limits, now) => {
|
|
5821
5423
|
const group2 = shape !== void 0 && shape.kind !== "dialog" && shape.kind !== "saved";
|
|
5822
5424
|
if (group2 && (shape.participantsCount ?? 0) > limits.groupMembersMax)
|
|
5823
5425
|
return { skip: "group_too_large", members: shape.participantsCount ?? 0 };
|
|
5824
|
-
const
|
|
5825
|
-
return { keepFrom: now - Math.min(
|
|
5426
|
+
const days = group2 ? limits.groupDays : limits.dialogDays;
|
|
5427
|
+
return { keepFrom: now - Math.min(days, HISTORY_MAX_DAYS) * DAY_MS };
|
|
5826
5428
|
}, "historyWindow");
|
|
5827
5429
|
var limitBatch = /* @__PURE__ */ __name((batch, shapes, included, limits, now = Date.now()) => {
|
|
5828
5430
|
const skipped = /* @__PURE__ */ new Map();
|
|
@@ -5860,8 +5462,8 @@ var limitBatch = /* @__PURE__ */ __name((batch, shapes, included, limits, now =
|
|
|
5860
5462
|
return { batch: { ...batch, messages }, skipped };
|
|
5861
5463
|
}, "limitBatch");
|
|
5862
5464
|
|
|
5863
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5864
|
-
import { existsSync as
|
|
5465
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/bot/registry.js
|
|
5466
|
+
import { existsSync as existsSync3, readdirSync as readdirSync2, readFileSync as readFileSync2 } from "node:fs";
|
|
5865
5467
|
import { join as join3 } from "node:path";
|
|
5866
5468
|
var botsDirectory = /* @__PURE__ */ __name((app, env = process.env) => join3(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "bots"), "botsDirectory");
|
|
5867
5469
|
var botFiles = /* @__PURE__ */ __name((app, profile, env = process.env) => {
|
|
@@ -5899,7 +5501,7 @@ var ChatRegistry = class {
|
|
|
5899
5501
|
}
|
|
5900
5502
|
/** Makes this bot known to `bot list` before it has seen any chat. */
|
|
5901
5503
|
touch() {
|
|
5902
|
-
if (!
|
|
5504
|
+
if (!existsSync3(this.#path))
|
|
5903
5505
|
writeSecurely(this.#path, `${JSON.stringify({ chats: [] }, null, 2)}
|
|
5904
5506
|
`, 384);
|
|
5905
5507
|
}
|
|
@@ -5928,10 +5530,10 @@ var ChatRegistry = class {
|
|
|
5928
5530
|
this.#write({ ...this.#read(), chats: [...byId.values()] });
|
|
5929
5531
|
}
|
|
5930
5532
|
#read() {
|
|
5931
|
-
if (!
|
|
5533
|
+
if (!existsSync3(this.#path))
|
|
5932
5534
|
return {};
|
|
5933
5535
|
try {
|
|
5934
|
-
const parsed = JSON.parse(
|
|
5536
|
+
const parsed = JSON.parse(readFileSync2(this.#path, "utf8"));
|
|
5935
5537
|
return parsed && typeof parsed === "object" ? parsed : {};
|
|
5936
5538
|
} catch {
|
|
5937
5539
|
return {};
|
|
@@ -5944,15 +5546,15 @@ var ChatRegistry = class {
|
|
|
5944
5546
|
};
|
|
5945
5547
|
var registryProfiles = /* @__PURE__ */ __name((app, env = process.env) => {
|
|
5946
5548
|
const directory = botsDirectory(app, env);
|
|
5947
|
-
if (!
|
|
5549
|
+
if (!existsSync3(directory))
|
|
5948
5550
|
return [];
|
|
5949
|
-
return
|
|
5551
|
+
return readdirSync2(directory, { withFileTypes: true }).filter((entry) => entry.isFile() && entry.name.endsWith(".json")).map((entry) => entry.name).map((name) => name.slice(0, -".json".length));
|
|
5950
5552
|
}, "registryProfiles");
|
|
5951
5553
|
|
|
5952
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5953
|
-
import { readFileSync as
|
|
5554
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/config-issues.js
|
|
5555
|
+
import { readFileSync as readFileSync3 } from "node:fs";
|
|
5954
5556
|
|
|
5955
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5557
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/config-repair.js
|
|
5956
5558
|
var REPAIR_WORDS = {
|
|
5957
5559
|
byte_order_mark: "an invisible byte-order mark at the start",
|
|
5958
5560
|
comment: "a comment, which JSON does not allow",
|
|
@@ -6193,7 +5795,7 @@ ${parts.join(",\n")}
|
|
|
6193
5795
|
${indent}${close}`;
|
|
6194
5796
|
}, "serialise");
|
|
6195
5797
|
|
|
6196
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5798
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/config-issues.js
|
|
6197
5799
|
var isNode = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isNode");
|
|
6198
5800
|
var SECTIONS = ["personal", "bot"];
|
|
6199
5801
|
var SHELL_SAFE = /^[A-Za-z0-9_.:@-]*$/;
|
|
@@ -6372,7 +5974,7 @@ var schemaIssues = /* @__PURE__ */ __name((raw, schema2, context2) => {
|
|
|
6372
5974
|
return [...found.values()];
|
|
6373
5975
|
}
|
|
6374
5976
|
}, "schemaIssues");
|
|
6375
|
-
var
|
|
5977
|
+
var scopes = /* @__PURE__ */ __name((raw) => {
|
|
6376
5978
|
if (!isNode(raw))
|
|
6377
5979
|
return [];
|
|
6378
5980
|
const out = [];
|
|
@@ -6380,12 +5982,12 @@ var scopes2 = /* @__PURE__ */ __name((raw) => {
|
|
|
6380
5982
|
if (isNode(node))
|
|
6381
5983
|
out.push([path2, node]);
|
|
6382
5984
|
}, "add");
|
|
6383
|
-
const addSection = /* @__PURE__ */ __name((path2,
|
|
6384
|
-
if (!isNode(
|
|
5985
|
+
const addSection = /* @__PURE__ */ __name((path2, section2) => {
|
|
5986
|
+
if (!isNode(section2))
|
|
6385
5987
|
return;
|
|
6386
|
-
add([...path2, "defaults"],
|
|
6387
|
-
if (isNode(
|
|
6388
|
-
for (const [name, scope] of Object.entries(
|
|
5988
|
+
add([...path2, "defaults"], section2.defaults);
|
|
5989
|
+
if (isNode(section2.profiles))
|
|
5990
|
+
for (const [name, scope] of Object.entries(section2.profiles))
|
|
6389
5991
|
add([...path2, "profiles", name], scope);
|
|
6390
5992
|
}, "addSection");
|
|
6391
5993
|
add([], raw);
|
|
@@ -6394,7 +5996,7 @@ var scopes2 = /* @__PURE__ */ __name((raw) => {
|
|
|
6394
5996
|
addSection([name], raw[name]);
|
|
6395
5997
|
return out;
|
|
6396
5998
|
}, "scopes");
|
|
6397
|
-
var savedPermissionKeys = /* @__PURE__ */ __name((raw) =>
|
|
5999
|
+
var savedPermissionKeys = /* @__PURE__ */ __name((raw) => scopes(raw).flatMap(([path2, scope]) => isNode(scope.permissions) ? Object.keys(scope.permissions).map((key) => ({ key, at: [...path2, "permissions", key] })) : []), "savedPermissionKeys");
|
|
6398
6000
|
var permissionIssues = /* @__PURE__ */ __name((saved, known, context2) => saved.filter(({ key }) => !known.has(key)).map(({ at: at2 }) => locate("unknown_permission", at2, context2, (key) => `${key} names no command`)), "permissionIssues");
|
|
6399
6001
|
var pathId = /* @__PURE__ */ __name((path2) => path2.join("\0"), "pathId");
|
|
6400
6002
|
var prune = /* @__PURE__ */ __name((raw, paths) => {
|
|
@@ -6402,7 +6004,7 @@ var prune = /* @__PURE__ */ __name((raw, paths) => {
|
|
|
6402
6004
|
const kept = /* @__PURE__ */ new Map();
|
|
6403
6005
|
const walk = /* @__PURE__ */ __name((node, at2) => {
|
|
6404
6006
|
if (Array.isArray(node)) {
|
|
6405
|
-
const indices = node.flatMap((
|
|
6007
|
+
const indices = node.flatMap((_2, index) => drop.has(pathId([...at2, String(index)])) ? [] : [index]);
|
|
6406
6008
|
kept.set(pathId(at2), indices);
|
|
6407
6009
|
return indices.map((index) => walk(node[index], [...at2, String(index)]));
|
|
6408
6010
|
}
|
|
@@ -6439,7 +6041,7 @@ var withoutPath = /* @__PURE__ */ __name((raw, at2) => {
|
|
|
6439
6041
|
return { config: prune(raw, [gone]).pruned, removed: true };
|
|
6440
6042
|
}, "withoutPath");
|
|
6441
6043
|
var withoutSetting = /* @__PURE__ */ __name((raw, setting2) => withoutPath(raw, settingPathOf(setting2)), "withoutSetting");
|
|
6442
|
-
var publicIssue = /* @__PURE__ */ __name(({ at:
|
|
6044
|
+
var publicIssue = /* @__PURE__ */ __name(({ at: _2, ...issue }) => issue, "publicIssue");
|
|
6443
6045
|
var fixVerb = /* @__PURE__ */ __name((issue) => issue.kind === "invalid_json" ? "repair" : "remove", "fixVerb");
|
|
6444
6046
|
var issueMessage = /* @__PURE__ */ __name((issues, doctor = "doctor") => {
|
|
6445
6047
|
const [first2] = issues;
|
|
@@ -6468,7 +6070,7 @@ var checkConfigText = /* @__PURE__ */ __name((text5, { file, tool, schema: schem
|
|
|
6468
6070
|
var wholeFile = /* @__PURE__ */ __name((file, what) => ({ kind: "invalid_value", file, what }), "wholeFile");
|
|
6469
6071
|
var readConfigText = /* @__PURE__ */ __name((path2) => {
|
|
6470
6072
|
try {
|
|
6471
|
-
return { text:
|
|
6073
|
+
return { text: readFileSync3(path2, "utf8") };
|
|
6472
6074
|
} catch (error) {
|
|
6473
6075
|
const code = error.code;
|
|
6474
6076
|
if (code === "ENOENT")
|
|
@@ -6488,22 +6090,22 @@ var readConfigFile = /* @__PURE__ */ __name((path2) => {
|
|
|
6488
6090
|
return "issue" in parsed ? { issue: publicIssue(parsed.issue) } : parsed;
|
|
6489
6091
|
}, "readConfigFile");
|
|
6490
6092
|
|
|
6491
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6492
|
-
import { existsSync as
|
|
6093
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/default-config.js
|
|
6094
|
+
import { existsSync as existsSync4, linkSync, mkdirSync, mkdtempSync, rmSync, writeFileSync } from "node:fs";
|
|
6493
6095
|
import { dirname, join as join4 } from "node:path";
|
|
6494
6096
|
var DEFAULT_CONFIG = {
|
|
6495
6097
|
defaults: { limit: 20, keep_runs_for_days: 30, sends_per_hour: 30, update_check: true, skill_hint: true },
|
|
6496
6098
|
profiles: {}
|
|
6497
6099
|
};
|
|
6498
6100
|
function ensureDefaultConfig(path2, config = DEFAULT_CONFIG) {
|
|
6499
|
-
if (
|
|
6101
|
+
if (existsSync4(path2))
|
|
6500
6102
|
return;
|
|
6501
6103
|
const directory = dirname(path2);
|
|
6502
|
-
|
|
6104
|
+
mkdirSync(directory, { recursive: true, mode: 448 });
|
|
6503
6105
|
const temporary = mkdtempSync(join4(directory, ".config-"));
|
|
6504
6106
|
const candidate = join4(temporary, "config.json");
|
|
6505
6107
|
try {
|
|
6506
|
-
|
|
6108
|
+
writeFileSync(candidate, `${JSON.stringify(config, null, 2)}
|
|
6507
6109
|
`, { flag: "wx", mode: 384 });
|
|
6508
6110
|
try {
|
|
6509
6111
|
linkSync(candidate, path2);
|
|
@@ -6512,12 +6114,12 @@ function ensureDefaultConfig(path2, config = DEFAULT_CONFIG) {
|
|
|
6512
6114
|
throw error;
|
|
6513
6115
|
}
|
|
6514
6116
|
} finally {
|
|
6515
|
-
|
|
6117
|
+
rmSync(temporary, { recursive: true, force: true });
|
|
6516
6118
|
}
|
|
6517
6119
|
}
|
|
6518
6120
|
__name(ensureDefaultConfig, "ensureDefaultConfig");
|
|
6519
6121
|
|
|
6520
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6122
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/setting-defaults.js
|
|
6521
6123
|
var isNode2 = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isNode");
|
|
6522
6124
|
var parentOf = /* @__PURE__ */ __name((config, key) => {
|
|
6523
6125
|
const path2 = key.split(".");
|
|
@@ -6550,7 +6152,7 @@ var settingRows = /* @__PURE__ */ __name((raw, declared) => declared.map((settin
|
|
|
6550
6152
|
};
|
|
6551
6153
|
}), "settingRows");
|
|
6552
6154
|
|
|
6553
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6155
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/settings.js
|
|
6554
6156
|
var DEFAULT_LIMIT = DEFAULT_CONFIG.defaults.limit;
|
|
6555
6157
|
var DEFAULT_KEEP_RUNS_FOR_DAYS = DEFAULT_CONFIG.defaults.keep_runs_for_days;
|
|
6556
6158
|
var DEFAULT_SENDS_PER_HOUR = DEFAULT_CONFIG.defaults.sends_per_hour;
|
|
@@ -6589,6 +6191,7 @@ var SHARED_PROFILE_ENTRIES = {
|
|
|
6589
6191
|
record_input: optional(recordInputSetting),
|
|
6590
6192
|
keep_runs_for_days: optional(count2),
|
|
6591
6193
|
keep_successful_runs_for_days: optional(count2),
|
|
6194
|
+
keep_store_runs_for_days: optional(count2),
|
|
6592
6195
|
runs_size_limit_mb: optional(count2),
|
|
6593
6196
|
permissions: optional(permissionLevels),
|
|
6594
6197
|
sends_per_hour: optional(count2),
|
|
@@ -6599,6 +6202,7 @@ var SHARED_PROFILE_ENTRIES = {
|
|
|
6599
6202
|
history_dialog_days: optional(historyDays),
|
|
6600
6203
|
history_group_days: optional(historyDays),
|
|
6601
6204
|
history_group_members_max: optional(count2),
|
|
6205
|
+
history_muted: optional(flag),
|
|
6602
6206
|
picture_search: optional(flag),
|
|
6603
6207
|
search_reranker: optional(picklist([...RERANK_MODELS.map((model3) => model3.id), "off"], plain(`has to be off or a reranker id: ${RERANK_MODELS.map((model3) => model3.id).join(", ")}`))),
|
|
6604
6208
|
...AI_ENTRIES
|
|
@@ -6614,6 +6218,7 @@ var MESSENGER_ONLY_SETTINGS = [
|
|
|
6614
6218
|
"history_dialog_days",
|
|
6615
6219
|
"history_group_days",
|
|
6616
6220
|
"history_group_members_max",
|
|
6221
|
+
"history_muted",
|
|
6617
6222
|
"read_other_bots",
|
|
6618
6223
|
"speech_model",
|
|
6619
6224
|
"picture_search"
|
|
@@ -6647,6 +6252,11 @@ var SHARED_SETTINGS = [
|
|
|
6647
6252
|
default: KEEP_SUCCESSFUL_RUNS_FOR_DAYS,
|
|
6648
6253
|
description: "days a successful run is kept"
|
|
6649
6254
|
},
|
|
6255
|
+
{
|
|
6256
|
+
key: "keep_store_runs_for_days",
|
|
6257
|
+
default: KEEP_STORE_RUNS_FOR_DAYS,
|
|
6258
|
+
description: "days a successful run that wrote the store is kept, even unrecorded"
|
|
6259
|
+
},
|
|
6650
6260
|
{ key: "runs_size_limit_mb", default: RUNS_SIZE_LIMIT_MB, description: "the most megabytes all runs may take" },
|
|
6651
6261
|
{ key: "sender_colors", default: false, description: "color each sender's name in a conversation" },
|
|
6652
6262
|
{ key: "search_catch_up", default: false, description: "prepare local search after a gaps repair" },
|
|
@@ -6665,6 +6275,7 @@ var SHARED_SETTINGS = [
|
|
|
6665
6275
|
default: DEFAULT_HISTORY_LIMITS.groupMembersMax,
|
|
6666
6276
|
description: "a group with more people than this keeps no pushed history"
|
|
6667
6277
|
},
|
|
6278
|
+
{ key: "history_muted", default: false, description: "messages sync --all reads muted chats too" },
|
|
6668
6279
|
{
|
|
6669
6280
|
key: "picture_search",
|
|
6670
6281
|
default: false,
|
|
@@ -6789,7 +6400,7 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6789
6400
|
const env = options.env ?? process.env;
|
|
6790
6401
|
const configPath = configPathFor(options);
|
|
6791
6402
|
try {
|
|
6792
|
-
if (!options.readOnly)
|
|
6403
|
+
if (!options.readOnly && !readOnlyLockOf(app, env))
|
|
6793
6404
|
ensureDefaultConfig(configPath, withDefaults(DEFAULT_CONFIG).config);
|
|
6794
6405
|
} catch (error) {
|
|
6795
6406
|
throw new CliError("configuration_error", error instanceof Error ? error.message : String(error));
|
|
@@ -6810,11 +6421,11 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6810
6421
|
const name = usableProfileName(profile.value);
|
|
6811
6422
|
const configured = config.profiles[name] ?? {};
|
|
6812
6423
|
const shared = config.defaults ?? {};
|
|
6813
|
-
const
|
|
6424
|
+
const section2 = config[kind2];
|
|
6814
6425
|
const layers = [
|
|
6815
|
-
[`config file: ${kind2}.profiles.${name}`,
|
|
6426
|
+
[`config file: ${kind2}.profiles.${name}`, section2?.profiles?.[name]],
|
|
6816
6427
|
[extension.sourcePaths ? `config file: profiles.${name}` : "config file", configured],
|
|
6817
|
-
[`config file: ${kind2}.defaults`,
|
|
6428
|
+
[`config file: ${kind2}.defaults`, section2?.defaults],
|
|
6818
6429
|
[extension.sourcePaths ? "config file: defaults" : "config defaults", shared]
|
|
6819
6430
|
];
|
|
6820
6431
|
const fromLayers = /* @__PURE__ */ __name((key, fallback, only = layers) => first(only.map(([from, scope]) => [from, scope?.[key]]), fallback), "fromLayers");
|
|
@@ -6828,11 +6439,13 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6828
6439
|
const historyDialogDays = fromLayers("history_dialog_days", DEFAULT_HISTORY_LIMITS.dialogDays);
|
|
6829
6440
|
const historyGroupDays = fromLayers("history_group_days", DEFAULT_HISTORY_LIMITS.groupDays);
|
|
6830
6441
|
const historyGroupMembersMax = fromLayers("history_group_members_max", DEFAULT_HISTORY_LIMITS.groupMembersMax);
|
|
6442
|
+
const historyMuted = fromLayers("history_muted", false);
|
|
6831
6443
|
const pictureSearch = fromLayers("picture_search", false);
|
|
6832
6444
|
const searchReranker = fromLayers("search_reranker", DEFAULT_RERANK_MODEL);
|
|
6833
6445
|
const recordInput = fromLayers("record_input", true);
|
|
6834
6446
|
const keepRunsForDays = fromLayers("keep_runs_for_days", DEFAULT_KEEP_RUNS_FOR_DAYS);
|
|
6835
6447
|
const keepSuccessfulRunsForDays = fromLayers("keep_successful_runs_for_days", KEEP_SUCCESSFUL_RUNS_FOR_DAYS);
|
|
6448
|
+
const keepStoreRunsForDays = fromLayers("keep_store_runs_for_days", KEEP_STORE_RUNS_FOR_DAYS);
|
|
6836
6449
|
const runsSizeLimitMb = fromLayers("runs_size_limit_mb", RUNS_SIZE_LIMIT_MB);
|
|
6837
6450
|
const readOnlyLock = readOnlyLockOf(app, env);
|
|
6838
6451
|
const sendsPerHour = kind2 === "bot" ? fromLayers("sends_per_hour", Number.POSITIVE_INFINITY, kindLayers) : fromLayers("sends_per_hour", DEFAULT_SENDS_PER_HOUR);
|
|
@@ -6875,6 +6488,7 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6875
6488
|
groupDays: historyGroupDays.value,
|
|
6876
6489
|
groupMembersMax: historyGroupMembersMax.value
|
|
6877
6490
|
},
|
|
6491
|
+
historyMuted: historyMuted.value,
|
|
6878
6492
|
pictureSearch: pictureSearch.value,
|
|
6879
6493
|
searchReranker: searchReranker.value,
|
|
6880
6494
|
limit: limit.value,
|
|
@@ -6887,6 +6501,7 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6887
6501
|
keepFailedRuns: record2.value || record2.from !== "flag",
|
|
6888
6502
|
keepRunsForDays: keepRunsForDays.value,
|
|
6889
6503
|
keepSuccessfulRunsForDays: keepSuccessfulRunsForDays.value,
|
|
6504
|
+
keepStoreRunsForDays: keepStoreRunsForDays.value,
|
|
6890
6505
|
runsSizeLimitMb: runsSizeLimitMb.value,
|
|
6891
6506
|
...readOnlyLock ? { readOnlyLock } : {},
|
|
6892
6507
|
permissions: permissions.levels,
|
|
@@ -6898,7 +6513,7 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6898
6513
|
updateCheck: updateCheck.value,
|
|
6899
6514
|
skillHint: skillHint.value,
|
|
6900
6515
|
configPath,
|
|
6901
|
-
configFound:
|
|
6516
|
+
configFound: existsSync5(configPath),
|
|
6902
6517
|
configuredProfiles: namedProfiles(config),
|
|
6903
6518
|
profilesHere: profilesOf(config, env),
|
|
6904
6519
|
accountProfiles: accountsOf(config, env, bots),
|
|
@@ -6915,12 +6530,14 @@ var settingsFor = /* @__PURE__ */ __name((app, extension = {}) => {
|
|
|
6915
6530
|
historyDialogDays: historyDialogDays.from,
|
|
6916
6531
|
historyGroupDays: historyGroupDays.from,
|
|
6917
6532
|
historyGroupMembersMax: historyGroupMembersMax.from,
|
|
6533
|
+
historyMuted: historyMuted.from,
|
|
6918
6534
|
pictureSearch: pictureSearch.from,
|
|
6919
6535
|
searchReranker: searchReranker.from,
|
|
6920
6536
|
record: record2.from,
|
|
6921
6537
|
recordInput: recordInput.from,
|
|
6922
6538
|
keepRunsForDays: keepRunsForDays.from,
|
|
6923
6539
|
keepSuccessfulRunsForDays: keepSuccessfulRunsForDays.from,
|
|
6540
|
+
keepStoreRunsForDays: keepStoreRunsForDays.from,
|
|
6924
6541
|
runsSizeLimitMb: runsSizeLimitMb.from,
|
|
6925
6542
|
sendsPerHour: sendsPerHour.from,
|
|
6926
6543
|
requestsPerMinute: requestsPerMinute.from,
|
|
@@ -7060,7 +6677,7 @@ var given = /* @__PURE__ */ __name((value) => {
|
|
|
7060
6677
|
return trimmed === void 0 || trimmed === "" ? void 0 : trimmed;
|
|
7061
6678
|
}, "given");
|
|
7062
6679
|
|
|
7063
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6680
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/context.js
|
|
7064
6681
|
var setExitCode = /* @__PURE__ */ __name((command, code) => {
|
|
7065
6682
|
const slot = environmentOf(command).exit;
|
|
7066
6683
|
if (slot)
|
|
@@ -7155,6 +6772,7 @@ var baseContext = /* @__PURE__ */ __name((command, resolveSettings) => {
|
|
|
7155
6772
|
trace: settings.trace,
|
|
7156
6773
|
keepDays: settings.keepRunsForDays,
|
|
7157
6774
|
...settings.keepSuccessfulRunsForDays === void 0 ? {} : { keepSuccessDays: settings.keepSuccessfulRunsForDays },
|
|
6775
|
+
...settings.keepStoreRunsForDays === void 0 ? {} : { keepStoreDays: settings.keepStoreRunsForDays },
|
|
7158
6776
|
...settings.runsSizeLimitMb === void 0 ? {} : { maxBytes: settings.runsSizeLimitMb * 1024 * 1024 },
|
|
7159
6777
|
processRun: !environment.agent,
|
|
7160
6778
|
format,
|
|
@@ -7182,7 +6800,7 @@ var commandPath = /* @__PURE__ */ __name((command) => {
|
|
|
7182
6800
|
return words2.join(" ");
|
|
7183
6801
|
}, "commandPath");
|
|
7184
6802
|
|
|
7185
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6803
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/effects.js
|
|
7186
6804
|
var REMOTE_READ = { remote: "read", local: "read" };
|
|
7187
6805
|
var FETCH = { remote: "read", local: "write" };
|
|
7188
6806
|
var REMOTE_WRITE = { remote: "write", local: "write" };
|
|
@@ -7302,7 +6920,7 @@ var refuseUnderReadOnly = /* @__PURE__ */ __name((command, what) => {
|
|
|
7302
6920
|
throw readOnlyRefusal(lock, what);
|
|
7303
6921
|
}, "refuseUnderReadOnly");
|
|
7304
6922
|
|
|
7305
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6923
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/account.js
|
|
7306
6924
|
var account = strictObject({
|
|
7307
6925
|
provider: text,
|
|
7308
6926
|
id,
|
|
@@ -7312,7 +6930,7 @@ var account = strictObject({
|
|
|
7312
6930
|
scope: optional(picklist(["personal", "work"]))
|
|
7313
6931
|
});
|
|
7314
6932
|
|
|
7315
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6933
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/account-session.js
|
|
7316
6934
|
var accountSession = strictObject({
|
|
7317
6935
|
current: boolean(),
|
|
7318
6936
|
client: nullable(text),
|
|
@@ -7322,7 +6940,7 @@ var accountSession = strictObject({
|
|
|
7322
6940
|
created_at: optional(nullable(time))
|
|
7323
6941
|
});
|
|
7324
6942
|
|
|
7325
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6943
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/account-change.js
|
|
7326
6944
|
var accountChange = strictObject({ operation_id: id, account: omit(account, ["provider", "scope"]) });
|
|
7327
6945
|
var endedAccountSessions = strictObject({ operation_id: id, sessions: array(accountSession) });
|
|
7328
6946
|
var audience = picklist(["everyone", "contacts", "nobody"]);
|
|
@@ -7351,7 +6969,7 @@ var accountRemoval = strictObject({
|
|
|
7351
6969
|
kept: array(strictObject({ kind: removalKind, target: text, reason: text }))
|
|
7352
6970
|
});
|
|
7353
6971
|
|
|
7354
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6972
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/account-profile.js
|
|
7355
6973
|
var accountProfile = strictObject({
|
|
7356
6974
|
profile: id,
|
|
7357
6975
|
current: boolean(),
|
|
@@ -7363,7 +6981,7 @@ var accountProfile = strictObject({
|
|
|
7363
6981
|
bot: optional(literal(true))
|
|
7364
6982
|
});
|
|
7365
6983
|
|
|
7366
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6984
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/counter-reading.js
|
|
7367
6985
|
var milliseconds = pipe(number(), minValue(0));
|
|
7368
6986
|
var counterReading = strictObject({
|
|
7369
6987
|
counter: picklist(["views", "reactions", "comments"]),
|
|
@@ -7375,7 +6993,7 @@ var counterReading = strictObject({
|
|
|
7375
6993
|
});
|
|
7376
6994
|
var selection = record(string(), unknown());
|
|
7377
6995
|
|
|
7378
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6996
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/admin-report.js
|
|
7379
6997
|
var adminRow = strictObject({
|
|
7380
6998
|
ref: reference,
|
|
7381
6999
|
/** What `stats * evidence` takes: a person id, a stay or a message locator. */
|
|
@@ -7428,7 +7046,7 @@ var adminReport = strictObject({
|
|
|
7428
7046
|
rows: array(adminRow)
|
|
7429
7047
|
});
|
|
7430
7048
|
|
|
7431
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7049
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/task.js
|
|
7432
7050
|
var closeSuggestion = strictObject({
|
|
7433
7051
|
as: picklist(["done", "dismissed"]),
|
|
7434
7052
|
/** The agent's name. */
|
|
@@ -7490,7 +7108,7 @@ var task = strictObject({
|
|
|
7490
7108
|
updated_at: optional(time)
|
|
7491
7109
|
});
|
|
7492
7110
|
|
|
7493
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7111
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/agenda.js
|
|
7494
7112
|
var agendaChat = strictObject({
|
|
7495
7113
|
chat: reference,
|
|
7496
7114
|
title: nullable(text),
|
|
@@ -7560,11 +7178,11 @@ var agenda = strictObject({
|
|
|
7560
7178
|
unlisted_categories: array(strictObject({ name: text, open_tasks: number() }))
|
|
7561
7179
|
});
|
|
7562
7180
|
|
|
7563
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7181
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/analysis-consent.js
|
|
7564
7182
|
var analysisConsent = strictObject({ chat: id, provider: text, at: time });
|
|
7565
7183
|
var analysisConsentRevocation = strictObject({ revoked: boolean() });
|
|
7566
7184
|
|
|
7567
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7185
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/attachment.js
|
|
7568
7186
|
var attachment = strictObject({
|
|
7569
7187
|
/** The message it came with, as a locator; absent inside that message. */
|
|
7570
7188
|
message: optional(reference),
|
|
@@ -7602,7 +7220,7 @@ var attachment = strictObject({
|
|
|
7602
7220
|
});
|
|
7603
7221
|
var hitFile = strictObject({ position: count, kind: text, name: optional(text), size: optional(count) });
|
|
7604
7222
|
|
|
7605
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7223
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/batch-result.js
|
|
7606
7224
|
var actionableError = objectWithRest({
|
|
7607
7225
|
code: text,
|
|
7608
7226
|
message: text,
|
|
@@ -7619,7 +7237,7 @@ var batchResult = strictObject({
|
|
|
7619
7237
|
max_error_percent: count
|
|
7620
7238
|
});
|
|
7621
7239
|
|
|
7622
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7240
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/extraction-report.js
|
|
7623
7241
|
var extractionItem = strictObject({
|
|
7624
7242
|
ref: reference,
|
|
7625
7243
|
attachment: count,
|
|
@@ -7652,7 +7270,7 @@ var extractionReport = strictObject({
|
|
|
7652
7270
|
cursor: optional(text)
|
|
7653
7271
|
});
|
|
7654
7272
|
|
|
7655
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7273
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/attachment-results.js
|
|
7656
7274
|
var fingerprint = pipe(text, regex(/^[a-f0-9]{64}$/));
|
|
7657
7275
|
var attachmentBytes = strictObject({
|
|
7658
7276
|
ref: reference,
|
|
@@ -7680,45 +7298,103 @@ var attachmentTextChange = strictObject({
|
|
|
7680
7298
|
replaced: nullable(picklist(["extracted", "agent"]))
|
|
7681
7299
|
});
|
|
7682
7300
|
|
|
7683
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7684
|
-
var
|
|
7685
|
-
|
|
7686
|
-
|
|
7687
|
-
|
|
7688
|
-
|
|
7689
|
-
|
|
7690
|
-
|
|
7691
|
-
|
|
7692
|
-
|
|
7693
|
-
|
|
7694
|
-
|
|
7695
|
-
|
|
7696
|
-
|
|
7301
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/botcheck/reasons.js
|
|
7302
|
+
var WEIGHTS = {
|
|
7303
|
+
bot: 3,
|
|
7304
|
+
scam: 3,
|
|
7305
|
+
fake: 3,
|
|
7306
|
+
deleted: 1,
|
|
7307
|
+
no_photo: 1,
|
|
7308
|
+
no_username: 1,
|
|
7309
|
+
odd_name: 1,
|
|
7310
|
+
never_wrote: 1,
|
|
7311
|
+
link_first: 2,
|
|
7312
|
+
burst_join: 1,
|
|
7313
|
+
mass_invited: 1,
|
|
7314
|
+
new_account: 2,
|
|
7315
|
+
no_bio: 1,
|
|
7316
|
+
same_text: 2,
|
|
7317
|
+
photo_recent: 1,
|
|
7318
|
+
cas_banned: 3,
|
|
7319
|
+
lols_banned: 3,
|
|
7320
|
+
lols_scammer: 3
|
|
7321
|
+
};
|
|
7322
|
+
var LINK = /https?:\/\/|t\.me\/|www\./i;
|
|
7323
|
+
var DIGITS = /\d{5,}/;
|
|
7324
|
+
var oddName = /* @__PURE__ */ __name((name) => !name?.trim() || DIGITS.test(name) || LINK.test(name), "oddName");
|
|
7697
7325
|
|
|
7698
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7699
|
-
var
|
|
7326
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact-activity.js
|
|
7327
|
+
var linkedIdentity = strictObject({
|
|
7328
|
+
provider: text,
|
|
7700
7329
|
id,
|
|
7701
7330
|
name: nullable(text),
|
|
7702
7331
|
username: nullable(text),
|
|
7703
|
-
|
|
7704
|
-
|
|
7705
|
-
|
|
7706
|
-
|
|
7707
|
-
|
|
7708
|
-
|
|
7709
|
-
|
|
7710
|
-
|
|
7711
|
-
|
|
7712
|
-
|
|
7713
|
-
|
|
7714
|
-
/**
|
|
7715
|
-
|
|
7716
|
-
|
|
7717
|
-
|
|
7718
|
-
|
|
7332
|
+
is_bot: nullable(boolean()),
|
|
7333
|
+
accounts: array(id),
|
|
7334
|
+
seen_in: array(strictObject({ account: id, scope: picklist(["personal", "work"]) })),
|
|
7335
|
+
method: text,
|
|
7336
|
+
linked_by: text,
|
|
7337
|
+
linked_at: time
|
|
7338
|
+
});
|
|
7339
|
+
var linkedPerson = strictObject({
|
|
7340
|
+
uid: id,
|
|
7341
|
+
name: nullable(text),
|
|
7342
|
+
identities: array(linkedIdentity),
|
|
7343
|
+
/** An agent's link: the `identity_link` proposal the owner decides; the person is still as it was. */
|
|
7344
|
+
proposal: optional(text)
|
|
7345
|
+
});
|
|
7346
|
+
var contactActivity = strictObject({
|
|
7347
|
+
at: time,
|
|
7348
|
+
subject: text,
|
|
7349
|
+
subject_id: count,
|
|
7350
|
+
role: text,
|
|
7351
|
+
scope: text,
|
|
7352
|
+
provider: nullable(text),
|
|
7353
|
+
account: nullable(text),
|
|
7354
|
+
chat_id: nullable(text),
|
|
7355
|
+
locator: nullable(text),
|
|
7356
|
+
project_id: nullable(count)
|
|
7357
|
+
});
|
|
7358
|
+
var botReason = picklist(Object.keys(WEIGHTS));
|
|
7359
|
+
var contactCheck = strictObject({
|
|
7360
|
+
person: strictObject({ id, name: nullable(text), username: nullable(text), provider: text }),
|
|
7361
|
+
score: count,
|
|
7362
|
+
reasons: array(strictObject({ reason: botReason, weight: count, source: text, detail: optional(text) })),
|
|
7363
|
+
registries: array(strictObject({
|
|
7364
|
+
name: picklist(["cas", "lols"]),
|
|
7365
|
+
answer: picklist(["listed", "clean", "unknown"]),
|
|
7366
|
+
checked_at: time,
|
|
7367
|
+
detail: optional(text),
|
|
7368
|
+
reasons: optional(array(picklist(["cas_banned", "lols_banned", "lols_scammer"])))
|
|
7369
|
+
})),
|
|
7370
|
+
unknown: array(botReason),
|
|
7371
|
+
checked_at: time
|
|
7372
|
+
});
|
|
7373
|
+
|
|
7374
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/member.js
|
|
7375
|
+
var member = strictObject({
|
|
7376
|
+
id,
|
|
7377
|
+
name: nullable(text),
|
|
7378
|
+
username: nullable(text),
|
|
7379
|
+
role: optional(picklist(["owner", "admin", "member"])),
|
|
7380
|
+
/** `null` when their privacy hides it. */
|
|
7381
|
+
last_seen_at: optional(nullable(time)),
|
|
7382
|
+
registered_at: optional(nullable(time)),
|
|
7383
|
+
joined_at: optional(nullable(time)),
|
|
7384
|
+
/** Who added them or whose invite they used. */
|
|
7385
|
+
invited_by: optional(nullable(id)),
|
|
7386
|
+
is_bot: optional(boolean()),
|
|
7387
|
+
deleted: optional(boolean()),
|
|
7388
|
+
flagged: optional(picklist(["scam", "fake"])),
|
|
7389
|
+
has_photo: optional(boolean()),
|
|
7390
|
+
/** `chats members check`: how much they look like a bot — a hint, never a verdict. */
|
|
7391
|
+
score: optional(count),
|
|
7392
|
+
reasons: optional(array(text)),
|
|
7393
|
+
/** `chats members check --deep`: the whole person check, as `contacts check` answers it. */
|
|
7394
|
+
check: optional(record(string(), unknown()))
|
|
7719
7395
|
});
|
|
7720
7396
|
|
|
7721
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7397
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat.js
|
|
7722
7398
|
var setting = optional(nullable(boolean()));
|
|
7723
7399
|
var chat = strictObject({
|
|
7724
7400
|
ref: reference,
|
|
@@ -7759,758 +7435,972 @@ var chat = strictObject({
|
|
|
7759
7435
|
members: optional(array(member))
|
|
7760
7436
|
});
|
|
7761
7437
|
|
|
7762
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7763
|
-
var
|
|
7438
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message.js
|
|
7439
|
+
var quoted = strictObject({
|
|
7764
7440
|
id,
|
|
7765
|
-
|
|
7766
|
-
|
|
7441
|
+
sender_id: nullable(id),
|
|
7442
|
+
sender_name: nullable(text),
|
|
7443
|
+
timestamp: nullable(time),
|
|
7444
|
+
text,
|
|
7445
|
+
attachments: array(attachment),
|
|
7446
|
+
outgoing: nullable(boolean())
|
|
7767
7447
|
});
|
|
7768
|
-
var
|
|
7448
|
+
var mailPerson = strictObject({ name: nullable(text), address: text, ref: nullable(reference) });
|
|
7449
|
+
var message = strictObject({
|
|
7450
|
+
/** The message's locator. */
|
|
7451
|
+
ref: reference,
|
|
7769
7452
|
id,
|
|
7770
|
-
|
|
7771
|
-
|
|
7772
|
-
|
|
7773
|
-
|
|
7774
|
-
|
|
7775
|
-
|
|
7776
|
-
|
|
7777
|
-
|
|
7778
|
-
|
|
7779
|
-
|
|
7780
|
-
|
|
7781
|
-
|
|
7782
|
-
|
|
7783
|
-
|
|
7784
|
-
|
|
7785
|
-
|
|
7786
|
-
|
|
7787
|
-
|
|
7788
|
-
/**
|
|
7789
|
-
|
|
7790
|
-
/** `
|
|
7791
|
-
|
|
7792
|
-
|
|
7793
|
-
|
|
7794
|
-
|
|
7795
|
-
|
|
7796
|
-
|
|
7797
|
-
|
|
7798
|
-
|
|
7453
|
+
provider: optional(text),
|
|
7454
|
+
account: optional(text),
|
|
7455
|
+
chat_id: id,
|
|
7456
|
+
chat_title: optional(nullable(text)),
|
|
7457
|
+
sender_id: nullable(id),
|
|
7458
|
+
sender_name: nullable(text),
|
|
7459
|
+
sender_username: optional(text),
|
|
7460
|
+
sender_is_chat: optional(boolean()),
|
|
7461
|
+
sender_is_me: boolean(),
|
|
7462
|
+
mentions: optional(array(id)),
|
|
7463
|
+
/** When it was sent. */
|
|
7464
|
+
timestamp: time,
|
|
7465
|
+
edited_at: nullable(time),
|
|
7466
|
+
text,
|
|
7467
|
+
/** What a voice message says, once heard. */
|
|
7468
|
+
transcript: optional(text),
|
|
7469
|
+
/** In a window of messages around one, the one asked for. */
|
|
7470
|
+
anchor: optional(boolean()),
|
|
7471
|
+
/** A stretch of the text, transcript, file name or file text around what a search matched. */
|
|
7472
|
+
excerpt: optional(text),
|
|
7473
|
+
/** `picture`: the picture search lane found it by what the picture shows; it follows the text hits. */
|
|
7474
|
+
matched_in: optional(picklist(["text", "transcript", "filename", "file", "context", "picture"])),
|
|
7475
|
+
score: optional(number()),
|
|
7476
|
+
/**
|
|
7477
|
+
* `corrected`: a query word matched only a spelling speech recognition garbled in a voice note's transcript,
|
|
7478
|
+
* listed in `corrections`. `words` and `beginnings`: what a discovery search matched.
|
|
7479
|
+
*/
|
|
7480
|
+
match: optional(picklist(["words", "beginnings", "corrected"])),
|
|
7481
|
+
corrections: optional(array(strictObject({ from: text, to: array(text) }))),
|
|
7482
|
+
/** Where a search found it: the local archive, the messenger's server, or both. */
|
|
7483
|
+
found_in: optional(picklist(["archive", "server", "both"])),
|
|
7484
|
+
/** A discovery search's partial match: how much of the question it covers, and which words it lacks. */
|
|
7485
|
+
discovery: optional(strictObject({
|
|
7486
|
+
coverage: number(),
|
|
7487
|
+
matched_terms: array(text),
|
|
7488
|
+
missing_terms: array(text),
|
|
7489
|
+
parent: optional(reference),
|
|
7490
|
+
/** Present when meaning was searched too: which of the two lists found it. */
|
|
7491
|
+
found_by: optional(array(picklist(["words", "meaning"]))),
|
|
7492
|
+
/** Present when the reranker read it: its own score, higher is better. It ordered the first hits with `score`. */
|
|
7493
|
+
reranker_score: optional(number())
|
|
7494
|
+
})),
|
|
7495
|
+
/** The messages around a search hit, or its thread, oldest first; the hit itself is among them. */
|
|
7496
|
+
context: optional(array(strictObject({ ref: reference, timestamp: time, sender_name: nullable(text), text }))),
|
|
7497
|
+
/**
|
|
7498
|
+
* A discovery hit's later messages, from any chat the search reads, that share a rare word with it, latest first:
|
|
7499
|
+
* one may change or cancel what the hit says. An excerpt, as the hit's own: `messages context <ref>` has the whole text.
|
|
7500
|
+
*/
|
|
7501
|
+
follow_ups: optional(array(strictObject({
|
|
7502
|
+
ref: reference,
|
|
7503
|
+
chat_title: nullable(text),
|
|
7504
|
+
timestamp: time,
|
|
7505
|
+
sender_name: nullable(text),
|
|
7506
|
+
excerpt: text
|
|
7507
|
+
}))),
|
|
7508
|
+
outgoing: nullable(boolean()),
|
|
7509
|
+
attachments: array(attachment),
|
|
7510
|
+
reply_to: nullable(quoted),
|
|
7511
|
+
/** The id a reply answers, also when the provider sent no copy of that message. */
|
|
7512
|
+
reply_to_id: optional(id),
|
|
7513
|
+
forwarded_from: nullable(quoted),
|
|
7514
|
+
thread_id: optional(id),
|
|
7515
|
+
thread_root_id: optional(id),
|
|
7516
|
+
reactions: optional(nullable(strictObject({
|
|
7517
|
+
counts: array(strictObject({ reaction: text, count })),
|
|
7518
|
+
mine: nullable(text),
|
|
7519
|
+
total: count
|
|
7520
|
+
}))),
|
|
7521
|
+
scheduled_for: optional(time),
|
|
7522
|
+
/** The owner starred it; only where the messenger has stars, and only when set. */
|
|
7523
|
+
starred: optional(literal(true)),
|
|
7524
|
+
/** The owner's own message in a one-to-one chat: `delivered`, or `read` once opened; absent when no receipt came. */
|
|
7525
|
+
delivery: optional(picklist(["delivered", "read"])),
|
|
7526
|
+
email: optional(strictObject({
|
|
7527
|
+
subject: nullable(text),
|
|
7528
|
+
from: nullable(mailPerson),
|
|
7529
|
+
to: array(mailPerson),
|
|
7530
|
+
cc: array(mailPerson),
|
|
7531
|
+
bcc: array(mailPerson),
|
|
7532
|
+
/** The mail header Reply-To; `reply_to` is the quoted message a chat reply answers. */
|
|
7533
|
+
reply_addresses: array(mailPerson),
|
|
7534
|
+
labels: array(text),
|
|
7535
|
+
/** The thread as a `chat:` reference. */
|
|
7536
|
+
thread: reference,
|
|
7537
|
+
read: nullable(boolean()),
|
|
7538
|
+
flagged: nullable(boolean()),
|
|
7539
|
+
/** How much the sender's mail looks like spam, a scam or a robot (memo's score), and why; absent when unscored. */
|
|
7540
|
+
sender_score: optional(strictObject({ score: number(), signals: array(text), demoted: optional(literal(true)) })),
|
|
7541
|
+
/** Mail `review`: filed in the mailbox of mail sent to many. */
|
|
7542
|
+
bulk: optional(boolean()),
|
|
7543
|
+
/** Mail `review`: its List-Id, `null` when it has none. */
|
|
7544
|
+
list_id: optional(nullable(text)),
|
|
7545
|
+
/** Mail `review`: the mail rule that decided how it is stored, by its id in `rules list`; `null` when none. */
|
|
7546
|
+
rule_id: optional(nullable(number())),
|
|
7547
|
+
/** Mail `review`: the evidence fingerprint a finding cites this email by. */
|
|
7548
|
+
fingerprint: optional(pipe(text, regex(/^[a-f0-9]{64}$/))),
|
|
7549
|
+
/** Mail `review`: no earlier stored email, in any account, came from this address. */
|
|
7550
|
+
new_sender: optional(boolean()),
|
|
7551
|
+
/** Mail `review`: how many identities the sender's person has; 1 is this address alone. */
|
|
7552
|
+
sender_identities: optional(number())
|
|
7553
|
+
})),
|
|
7554
|
+
provider_metadata: providerMetadata
|
|
7799
7555
|
});
|
|
7800
7556
|
|
|
7801
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7802
|
-
var
|
|
7803
|
-
var
|
|
7804
|
-
|
|
7805
|
-
|
|
7806
|
-
|
|
7807
|
-
|
|
7808
|
-
|
|
7809
|
-
|
|
7810
|
-
|
|
7811
|
-
|
|
7812
|
-
|
|
7813
|
-
|
|
7814
|
-
|
|
7815
|
-
members_see_link: nullable(boolean())
|
|
7816
|
-
})
|
|
7557
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact-context.js
|
|
7558
|
+
var contextPerson = strictObject({ ...linkedPerson.entries, provider: text, id });
|
|
7559
|
+
var contextMessage = strictObject({
|
|
7560
|
+
locator: reference,
|
|
7561
|
+
provider: text,
|
|
7562
|
+
account: id,
|
|
7563
|
+
chat_id: id,
|
|
7564
|
+
chat_title: nullable(text),
|
|
7565
|
+
id,
|
|
7566
|
+
timestamp: time,
|
|
7567
|
+
sender_id: nullable(id),
|
|
7568
|
+
sender_name: nullable(text),
|
|
7569
|
+
outgoing: nullable(boolean()),
|
|
7570
|
+
text
|
|
7817
7571
|
});
|
|
7818
|
-
var
|
|
7819
|
-
|
|
7820
|
-
|
|
7821
|
-
|
|
7822
|
-
|
|
7572
|
+
var sharedChat = strictObject({
|
|
7573
|
+
provider: text,
|
|
7574
|
+
account: id,
|
|
7575
|
+
chat_id: id,
|
|
7576
|
+
title: nullable(text),
|
|
7823
7577
|
kind: chat.entries.kind,
|
|
7578
|
+
last_message_at: nullable(time)
|
|
7579
|
+
});
|
|
7580
|
+
var contextEvent = strictObject({
|
|
7581
|
+
ref: reference,
|
|
7824
7582
|
title: nullable(text),
|
|
7825
|
-
|
|
7826
|
-
|
|
7827
|
-
|
|
7828
|
-
|
|
7829
|
-
|
|
7830
|
-
approval_needed: optional(boolean())
|
|
7583
|
+
starts_at: nullable(time),
|
|
7584
|
+
ends_at: nullable(time),
|
|
7585
|
+
all_day: boolean(),
|
|
7586
|
+
location: nullable(text),
|
|
7587
|
+
status: nullable(text)
|
|
7831
7588
|
});
|
|
7832
|
-
var
|
|
7833
|
-
|
|
7834
|
-
|
|
7835
|
-
|
|
7836
|
-
|
|
7837
|
-
|
|
7838
|
-
|
|
7839
|
-
|
|
7840
|
-
|
|
7841
|
-
|
|
7842
|
-
|
|
7843
|
-
|
|
7844
|
-
|
|
7845
|
-
|
|
7846
|
-
|
|
7589
|
+
var context = strictObject({
|
|
7590
|
+
person: contextPerson,
|
|
7591
|
+
/** The accounts read: only those of the scopes the caller may read. */
|
|
7592
|
+
accounts: array(strictObject({ provider: text, account: id, scope: picklist(["personal", "work"]) })),
|
|
7593
|
+
shared: array(sharedChat),
|
|
7594
|
+
last: strictObject({
|
|
7595
|
+
from_them: nullable(contextMessage),
|
|
7596
|
+
from_me: nullable(contextMessage),
|
|
7597
|
+
from_them_anywhere: nullable(contextMessage)
|
|
7598
|
+
}),
|
|
7599
|
+
recent: strictObject({ direct: array(contextMessage), groups: array(contextMessage) }),
|
|
7600
|
+
mentions: array(contextMessage),
|
|
7601
|
+
/** Calendar events they are invited to, one occurrence per series. */
|
|
7602
|
+
events: optional(strictObject({ upcoming: array(contextEvent), recent: array(contextEvent) })),
|
|
7603
|
+
limits: strictObject({ messages: count, bytes: count }),
|
|
7847
7604
|
complete: boolean(),
|
|
7848
|
-
|
|
7849
|
-
|
|
7850
|
-
|
|
7851
|
-
|
|
7852
|
-
|
|
7853
|
-
|
|
7854
|
-
|
|
7855
|
-
var chatInvite = strictObject({ chat_id: id, title: nullable(text), link: text });
|
|
7856
|
-
var chatInviteChange = strictObject({
|
|
7857
|
-
...operated,
|
|
7858
|
-
...omit(inviteLink, ["pending_count", "joined_count"]).entries,
|
|
7859
|
-
pending: optional(count),
|
|
7860
|
-
joined: optional(count)
|
|
7861
|
-
});
|
|
7862
|
-
var chatRequestChange = union([
|
|
7863
|
-
strictObject({ ...operated, person_id: id, accepted: boolean(), already: boolean() }),
|
|
7864
|
-
strictObject({ chat_id: id, accepted: boolean(), counted: count, operation_id: optional(id) })
|
|
7865
|
-
]);
|
|
7866
|
-
var chatAdminChange = strictObject({
|
|
7867
|
-
...operated,
|
|
7868
|
-
person_id: id,
|
|
7869
|
-
rights: optional(array(picklist(["read", "members", "admins", "info", "pin", "link", "post", "edit", "delete"])))
|
|
7605
|
+
not_read: array(strictObject({
|
|
7606
|
+
provider: text,
|
|
7607
|
+
account: id,
|
|
7608
|
+
chat_id: id,
|
|
7609
|
+
title: nullable(text),
|
|
7610
|
+
reason: picklist(["not_fetched", "partial"])
|
|
7611
|
+
}))
|
|
7870
7612
|
});
|
|
7871
|
-
var
|
|
7872
|
-
|
|
7873
|
-
|
|
7613
|
+
var shortMessage = strictObject({ at: time, text, transcript: optional(text) });
|
|
7614
|
+
var identifiedMessage = strictObject({
|
|
7615
|
+
...shortMessage.entries,
|
|
7616
|
+
id,
|
|
7617
|
+
locator: reference,
|
|
7618
|
+
sender_id: nullable(id),
|
|
7619
|
+
reply_to: nullable(id)
|
|
7874
7620
|
});
|
|
7875
|
-
var
|
|
7876
|
-
|
|
7877
|
-
|
|
7878
|
-
|
|
7621
|
+
var counterObservation = strictObject({
|
|
7622
|
+
value: number(),
|
|
7623
|
+
observed_at: time,
|
|
7624
|
+
source: picklist(["remote_fetch", "remote_update"]),
|
|
7625
|
+
reactions: optional(message.entries.reactions.wrapped.wrapped)
|
|
7879
7626
|
});
|
|
7880
|
-
|
|
7881
|
-
|
|
7882
|
-
|
|
7883
|
-
|
|
7884
|
-
|
|
7885
|
-
|
|
7886
|
-
|
|
7627
|
+
var { reply_addresses: mailReplyTo, ...mailFields } = message.entries.email.wrapped.entries;
|
|
7628
|
+
var fullMessage = strictObject({
|
|
7629
|
+
...pick(message, [
|
|
7630
|
+
"id",
|
|
7631
|
+
"chat_id",
|
|
7632
|
+
"chat_title",
|
|
7633
|
+
"excerpt",
|
|
7634
|
+
"sender_id",
|
|
7635
|
+
"sender_name",
|
|
7636
|
+
"sender_username",
|
|
7637
|
+
"mentions",
|
|
7638
|
+
"sender_is_chat",
|
|
7639
|
+
"timestamp",
|
|
7640
|
+
"edited_at",
|
|
7641
|
+
"text",
|
|
7642
|
+
"outgoing",
|
|
7643
|
+
"attachments",
|
|
7644
|
+
"reply_to",
|
|
7645
|
+
"reply_to_id",
|
|
7646
|
+
"forwarded_from",
|
|
7647
|
+
"thread_id",
|
|
7648
|
+
"thread_root_id",
|
|
7649
|
+
"scheduled_for",
|
|
7650
|
+
"provider_metadata",
|
|
7651
|
+
"delivery"
|
|
7652
|
+
]).entries,
|
|
7653
|
+
reactions: nullable(message.entries.reactions.wrapped.wrapped),
|
|
7654
|
+
starred: optional(boolean()),
|
|
7655
|
+
email: optional(strictObject({ ...mailFields, reply_to: mailReplyTo })),
|
|
7656
|
+
counter_observations: optional(partial(strictObject({
|
|
7657
|
+
views: counterObservation,
|
|
7658
|
+
reactions: counterObservation,
|
|
7659
|
+
comments: counterObservation
|
|
7660
|
+
}))),
|
|
7661
|
+
...shortMessage.entries,
|
|
7662
|
+
locator: reference
|
|
7887
7663
|
});
|
|
7888
|
-
var
|
|
7889
|
-
|
|
7890
|
-
|
|
7891
|
-
|
|
7892
|
-
|
|
7893
|
-
|
|
7894
|
-
|
|
7895
|
-
|
|
7896
|
-
|
|
7897
|
-
/** `join`, `leave`, `add`, `remove`, `create`, `title`, `pin`, `profile`; a messenger may pass others through. */
|
|
7898
|
-
type: text,
|
|
7899
|
-
/** The service message that says so, where there is one. */
|
|
7900
|
-
message_id: optional(id),
|
|
7901
|
-
by: optional(who),
|
|
7902
|
-
people: array(who),
|
|
7903
|
-
/** `create` and `title` carry the chat's title. */
|
|
7904
|
-
title: optional(text),
|
|
7905
|
-
/** `profile`: the name and username seen before. */
|
|
7906
|
-
before: optional(strictObject({ name: nullable(text), username: nullable(text) }))
|
|
7664
|
+
var contactMessages = strictObject({
|
|
7665
|
+
person: strictObject({ uid: id, provider: text, id, name: nullable(text) }),
|
|
7666
|
+
chats: array(strictObject({
|
|
7667
|
+
chat: pick(chat, ["id", "title", "kind"]),
|
|
7668
|
+
messages: array(union([shortMessage, identifiedMessage, fullMessage])),
|
|
7669
|
+
complete: boolean(),
|
|
7670
|
+
more: boolean()
|
|
7671
|
+
})),
|
|
7672
|
+
limits: strictObject({ messages: count })
|
|
7907
7673
|
});
|
|
7908
|
-
|
|
7909
|
-
|
|
7910
|
-
|
|
7911
|
-
|
|
7912
|
-
|
|
7913
|
-
username: nullable(text),
|
|
7914
|
-
description: nullable(text),
|
|
7915
|
-
fetched_at: time
|
|
7674
|
+
var contactContext = union([context, contactMessages]);
|
|
7675
|
+
var coverage = strictObject({
|
|
7676
|
+
included: count,
|
|
7677
|
+
has_more: boolean(),
|
|
7678
|
+
cut_by: nullable(picklist(["limit", "bytes"]))
|
|
7916
7679
|
});
|
|
7917
|
-
var
|
|
7918
|
-
|
|
7919
|
-
|
|
7920
|
-
|
|
7921
|
-
|
|
7680
|
+
var meetingCue = strictObject({
|
|
7681
|
+
reference,
|
|
7682
|
+
fingerprint: text,
|
|
7683
|
+
transcript_id: count,
|
|
7684
|
+
content_hash: nullable(text),
|
|
7685
|
+
position: count,
|
|
7686
|
+
start_ms: count,
|
|
7687
|
+
end_ms: count,
|
|
7688
|
+
speaker_participant_id: nullable(count),
|
|
7689
|
+
speaker_name: nullable(text),
|
|
7690
|
+
text,
|
|
7691
|
+
revision: picklist(["current", "superseded"])
|
|
7922
7692
|
});
|
|
7923
|
-
|
|
7924
|
-
|
|
7925
|
-
|
|
7926
|
-
|
|
7927
|
-
|
|
7928
|
-
|
|
7929
|
-
|
|
7930
|
-
|
|
7931
|
-
|
|
7932
|
-
|
|
7933
|
-
|
|
7934
|
-
|
|
7935
|
-
|
|
7936
|
-
|
|
7937
|
-
|
|
7938
|
-
|
|
7939
|
-
|
|
7940
|
-
|
|
7941
|
-
|
|
7942
|
-
|
|
7943
|
-
|
|
7693
|
+
var contactPreparation = strictObject({
|
|
7694
|
+
...context.entries,
|
|
7695
|
+
prepare: strictObject({
|
|
7696
|
+
waiting: array(strictObject({
|
|
7697
|
+
provider: text,
|
|
7698
|
+
account: id,
|
|
7699
|
+
chat_id: id,
|
|
7700
|
+
title: nullable(text),
|
|
7701
|
+
message: contextMessage,
|
|
7702
|
+
partial: boolean()
|
|
7703
|
+
})),
|
|
7704
|
+
tasks: array(strictObject({
|
|
7705
|
+
ref: reference,
|
|
7706
|
+
title: text,
|
|
7707
|
+
role: text,
|
|
7708
|
+
due_at: nullable(time),
|
|
7709
|
+
project: reference,
|
|
7710
|
+
source: nullable(reference),
|
|
7711
|
+
created_at: time
|
|
7712
|
+
})),
|
|
7713
|
+
facts: array(strictObject({
|
|
7714
|
+
ref: reference,
|
|
7715
|
+
type: text,
|
|
7716
|
+
statement: text,
|
|
7717
|
+
subject: nullable(reference),
|
|
7718
|
+
project: nullable(reference),
|
|
7719
|
+
updated_at: time
|
|
7720
|
+
})),
|
|
7721
|
+
notes: array(strictObject({ ref: reference, title: nullable(text), text, revision: count, updated_at: time })),
|
|
7722
|
+
meetings: array(strictObject({
|
|
7723
|
+
reference,
|
|
7724
|
+
cues: array(meetingCue),
|
|
7725
|
+
cue_coverage: strictObject({ included: count, omitted: nullable(count), has_more: boolean() })
|
|
7726
|
+
})),
|
|
7727
|
+
limits: strictObject({ items: count, bytes: count }),
|
|
7728
|
+
coverage: strictObject({
|
|
7729
|
+
waiting: strictObject({
|
|
7730
|
+
...coverage.entries,
|
|
7731
|
+
rule: literal("their message is the newest the store holds in a one-to-one chat")
|
|
7732
|
+
}),
|
|
7733
|
+
tasks: strictObject({
|
|
7734
|
+
...coverage.entries,
|
|
7735
|
+
selection: literal("open, assigned to them in any role"),
|
|
7736
|
+
accounts: array(text)
|
|
7737
|
+
}),
|
|
7738
|
+
facts: strictObject({
|
|
7739
|
+
...coverage.entries,
|
|
7740
|
+
selection: literal("accepted, about them or a project they are a member of")
|
|
7741
|
+
}),
|
|
7742
|
+
notes: strictObject({
|
|
7743
|
+
...coverage.entries,
|
|
7744
|
+
selection: literal("written by you, about them"),
|
|
7745
|
+
withheld: optional(literal("contacts.notes.list"))
|
|
7746
|
+
}),
|
|
7747
|
+
meetings: strictObject({
|
|
7748
|
+
...coverage.entries,
|
|
7749
|
+
read: literal("every account of the store that saw them"),
|
|
7750
|
+
accounts: array(text),
|
|
7751
|
+
pending: count
|
|
7752
|
+
})
|
|
7753
|
+
})
|
|
7944
7754
|
})
|
|
7945
7755
|
});
|
|
7946
|
-
var chatModeration = strictObject({
|
|
7947
|
-
chat_id: id,
|
|
7948
|
-
rows: array(strictObject({
|
|
7949
|
-
kind: picklist(["message", "member"]),
|
|
7950
|
-
rule: picklist(["blocked", "invites", "links", "forwards", "flood", "newAccount"]),
|
|
7951
|
-
person_id: id,
|
|
7952
|
-
person_name: nullable(text),
|
|
7953
|
-
message_id: optional(id),
|
|
7954
|
-
action,
|
|
7955
|
-
outcome: picklist(["reported", "done", "planned", "forbidden", "declined", "refused", "failed", "skipped"]),
|
|
7956
|
-
reason: optional(text),
|
|
7957
|
-
command: optional(text)
|
|
7958
|
-
}))
|
|
7959
|
-
});
|
|
7960
7756
|
|
|
7961
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7962
|
-
var
|
|
7963
|
-
var
|
|
7964
|
-
var
|
|
7965
|
-
|
|
7966
|
-
|
|
7967
|
-
|
|
7968
|
-
|
|
7969
|
-
|
|
7970
|
-
|
|
7971
|
-
|
|
7972
|
-
|
|
7973
|
-
|
|
7974
|
-
|
|
7975
|
-
|
|
7976
|
-
|
|
7977
|
-
|
|
7978
|
-
|
|
7979
|
-
|
|
7980
|
-
|
|
7981
|
-
|
|
7982
|
-
|
|
7983
|
-
|
|
7984
|
-
|
|
7985
|
-
|
|
7986
|
-
|
|
7987
|
-
|
|
7988
|
-
|
|
7989
|
-
|
|
7990
|
-
|
|
7991
|
-
|
|
7757
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/deal.js
|
|
7758
|
+
var nullableText = nullable(text);
|
|
7759
|
+
var party = strictObject({ ref: reference, name: nullableText, owner: boolean() });
|
|
7760
|
+
var outcome = picklist(["open", "won", "lost"]);
|
|
7761
|
+
var crmAccount = nullable(strictObject({ provider: text, account: text }));
|
|
7762
|
+
var day = nullable(pipe(string(), regex(/^\d{4}-\d{2}-\d{2}$/)));
|
|
7763
|
+
var deal = strictObject({
|
|
7764
|
+
id,
|
|
7765
|
+
ref: reference,
|
|
7766
|
+
kind: picklist(["deal", "lead"]),
|
|
7767
|
+
title: text,
|
|
7768
|
+
/** One line with the stage, amount and status. */
|
|
7769
|
+
summary: text,
|
|
7770
|
+
pipeline: reference,
|
|
7771
|
+
pipeline_name: text,
|
|
7772
|
+
stage: text,
|
|
7773
|
+
/** The base stage `stage` maps to, once the owner confirmed it; `null` while unsorted. */
|
|
7774
|
+
base_stage: nullable(strictObject({ ref: reference, name: text })),
|
|
7775
|
+
status: outcome,
|
|
7776
|
+
organization: nullable(party),
|
|
7777
|
+
currency: nullableText,
|
|
7778
|
+
amount: nullableText,
|
|
7779
|
+
close_date: day,
|
|
7780
|
+
closed_date: day,
|
|
7781
|
+
closed_reason: nullableText,
|
|
7782
|
+
rank: nullable(number()),
|
|
7783
|
+
/** A lead's deal, once it became one. */
|
|
7784
|
+
deal: nullable(reference),
|
|
7785
|
+
/** The CRM account it is a copy from; `null` for the owner's own. */
|
|
7786
|
+
account: crmAccount,
|
|
7787
|
+
external_id: nullableText,
|
|
7788
|
+
/** A CRM copy's assignee, the identity `<account>/user/<id>`. */
|
|
7789
|
+
assignee: nullableText,
|
|
7790
|
+
/** A CRM copy's own fields by code; a list field's value is its option's label, `option_id` its id. */
|
|
7791
|
+
provider_metadata: record(string(), strictObject({
|
|
7792
|
+
label: nullable(string()),
|
|
7793
|
+
value: unknown(),
|
|
7794
|
+
option_id: optional(union([string(), array(string())]))
|
|
7992
7795
|
})),
|
|
7993
|
-
|
|
7994
|
-
|
|
7995
|
-
|
|
7996
|
-
|
|
7997
|
-
|
|
7796
|
+
people: array(strictObject({ ...party.entries, role: picklist(DEAL_ROLES) })),
|
|
7797
|
+
author: strictObject({
|
|
7798
|
+
type: picklist(["person", "bot"]),
|
|
7799
|
+
id,
|
|
7800
|
+
name: nullableText,
|
|
7801
|
+
kind: nullable(picklist(["agent", "rule"]))
|
|
7998
7802
|
}),
|
|
7999
|
-
|
|
8000
|
-
|
|
8001
|
-
|
|
8002
|
-
|
|
8003
|
-
|
|
8004
|
-
|
|
8005
|
-
|
|
8006
|
-
|
|
8007
|
-
|
|
8008
|
-
more: boolean()
|
|
8009
|
-
})),
|
|
8010
|
-
series: optional(array(strictObject({ key: text, messages: count, senders: count, joined: optionalCount, left: optionalCount })))
|
|
7803
|
+
model: nullableText,
|
|
7804
|
+
source: text,
|
|
7805
|
+
reason: nullableText,
|
|
7806
|
+
evidence: array(reference),
|
|
7807
|
+
project: nullable(reference),
|
|
7808
|
+
project_name: nullableText,
|
|
7809
|
+
created_at: time,
|
|
7810
|
+
updated_at: time,
|
|
7811
|
+
untrusted
|
|
8011
7812
|
});
|
|
8012
|
-
var
|
|
8013
|
-
var
|
|
8014
|
-
|
|
7813
|
+
var lead = deal;
|
|
7814
|
+
var pipelineStage = strictObject({
|
|
7815
|
+
name: text,
|
|
7816
|
+
position: count,
|
|
7817
|
+
outcome,
|
|
7818
|
+
external_id: nullableText,
|
|
7819
|
+
/** Open deals or leads in it now. */
|
|
8015
7820
|
open: count,
|
|
8016
|
-
|
|
8017
|
-
|
|
8018
|
-
|
|
8019
|
-
|
|
8020
|
-
|
|
8021
|
-
|
|
8022
|
-
|
|
8023
|
-
|
|
8024
|
-
|
|
8025
|
-
|
|
8026
|
-
|
|
8027
|
-
|
|
8028
|
-
|
|
8029
|
-
|
|
8030
|
-
|
|
8031
|
-
|
|
8032
|
-
}))
|
|
7821
|
+
/** With a funnel: rows that got this far, and the share of them that reached the next stage. */
|
|
7822
|
+
reached: optional(count),
|
|
7823
|
+
conversion: optional(nullable(number())),
|
|
7824
|
+
/** With a funnel: rows standing in it now, and their sum per currency, never converted. */
|
|
7825
|
+
items: optional(count),
|
|
7826
|
+
amounts: optional(array(strictObject({ amount: text, currency: text, items: count })))
|
|
7827
|
+
});
|
|
7828
|
+
var pipeline = strictObject({
|
|
7829
|
+
id,
|
|
7830
|
+
ref: reference,
|
|
7831
|
+
name: text,
|
|
7832
|
+
kind: picklist(["deal", "lead"]),
|
|
7833
|
+
account: crmAccount,
|
|
7834
|
+
external_id: nullableText,
|
|
7835
|
+
stages: array(pipelineStage),
|
|
7836
|
+
created_at: time,
|
|
7837
|
+
totals: optional(strictObject({ items: count, open: count, won: count, lost: count, win_rate: nullable(number()) })),
|
|
7838
|
+
since: optional(day),
|
|
7839
|
+
untrusted
|
|
7840
|
+
});
|
|
7841
|
+
var stage = strictObject({
|
|
7842
|
+
...pipelineStage.entries,
|
|
7843
|
+
pipeline: reference,
|
|
7844
|
+
pipeline_name: text,
|
|
7845
|
+
kind: picklist(["deal", "lead"]),
|
|
7846
|
+
untrusted
|
|
8033
7847
|
});
|
|
8034
7848
|
|
|
8035
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8036
|
-
var
|
|
8037
|
-
|
|
8038
|
-
|
|
8039
|
-
|
|
7849
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/business-context.js
|
|
7850
|
+
var nullableText2 = nullable(text);
|
|
7851
|
+
var day2 = nullable(pipe(string(), regex(/^\d{4}-\d{2}-\d{2}$/)));
|
|
7852
|
+
var standing = picklist(STANDINGS);
|
|
7853
|
+
var categories = array(picklist(CATEGORIES));
|
|
7854
|
+
var section = /* @__PURE__ */ __name((item) => strictObject({ items: array(item), total: count, has_more: boolean(), next: nullableText2 }), "section");
|
|
7855
|
+
var relationRole = strictObject({
|
|
7856
|
+
/** `link:<id>`; absent for a proposal. */
|
|
7857
|
+
link: optional(reference),
|
|
7858
|
+
/** A `relationship` proposal waiting for the owner: its id, with `standing: proposed`. */
|
|
7859
|
+
proposal: optional(text),
|
|
7860
|
+
kind: picklist(RELATION_KINDS),
|
|
7861
|
+
role: nullableText2,
|
|
7862
|
+
/** `reported`: a CRM account says so and nobody confirmed it; `ended`: it no longer holds. */
|
|
7863
|
+
standing,
|
|
7864
|
+
/** The source account that reported it, `<provider>:<account>`. */
|
|
7865
|
+
account: optional(text),
|
|
7866
|
+
/** A job title the source gave; never a role. */
|
|
7867
|
+
position: optional(text),
|
|
7868
|
+
/** How a source made it when it stated none, such as `department-head`. */
|
|
7869
|
+
derived: optional(text),
|
|
7870
|
+
starts_at: optional(time),
|
|
7871
|
+
ends_at: optional(time)
|
|
7872
|
+
});
|
|
7873
|
+
var related = strictObject({ ref: reference, name: nullableText2, roles: array(relationRole) });
|
|
7874
|
+
var coverage2 = strictObject({
|
|
7875
|
+
/** `<provider>:<account>` of every account read. */
|
|
7876
|
+
accounts: array(text),
|
|
7877
|
+
not_read: array(strictObject({ source: text, reason: text }))
|
|
7878
|
+
});
|
|
7879
|
+
var linkedBy = array(picklist(["project", "counterparty"]));
|
|
7880
|
+
var financeTotal = strictObject({
|
|
7881
|
+
status: text,
|
|
7882
|
+
currency: text,
|
|
7883
|
+
rows: count,
|
|
7884
|
+
total: text,
|
|
7885
|
+
open: optional(text)
|
|
7886
|
+
});
|
|
7887
|
+
var money = strictObject({
|
|
7888
|
+
invoices: section(strictObject({
|
|
7889
|
+
ref: reference,
|
|
7890
|
+
title: text,
|
|
7891
|
+
direction: picklist(INVOICE_DIRECTIONS),
|
|
7892
|
+
status: picklist(INVOICE_STATUSES),
|
|
7893
|
+
review: picklist(FINANCE_REVIEWS),
|
|
7894
|
+
currency: text,
|
|
7895
|
+
total: text,
|
|
7896
|
+
open: text,
|
|
7897
|
+
due_date: day2,
|
|
7898
|
+
linked_by: linkedBy
|
|
7899
|
+
})),
|
|
7900
|
+
payments: section(strictObject({
|
|
7901
|
+
ref: reference,
|
|
7902
|
+
title: text,
|
|
7903
|
+
direction: picklist(MONEY_DIRECTIONS),
|
|
7904
|
+
review: picklist(FINANCE_REVIEWS),
|
|
7905
|
+
currency: text,
|
|
7906
|
+
amount: text,
|
|
7907
|
+
date: day2,
|
|
7908
|
+
linked_by: linkedBy
|
|
7909
|
+
})),
|
|
7910
|
+
orders: optional(section(strictObject({
|
|
7911
|
+
ref: reference,
|
|
7912
|
+
title: text,
|
|
7913
|
+
status: picklist(ORDER_STATUSES),
|
|
7914
|
+
review: picklist(FINANCE_REVIEWS),
|
|
7915
|
+
currency: nullableText2,
|
|
7916
|
+
total: nullableText2,
|
|
7917
|
+
side: picklist(["customer", "supplier"])
|
|
7918
|
+
}))),
|
|
7919
|
+
/** Confirmed rows only, per status (payments: direction) and currency; nothing converted. */
|
|
7920
|
+
totals: strictObject({ invoices: array(financeTotal), payments: array(financeTotal) }),
|
|
7921
|
+
/** Invoices and payments still proposed, of every row read. */
|
|
7922
|
+
unconfirmed: count,
|
|
7923
|
+
/** `false` when a read stopped at the store's page: the totals may leave rows out. */
|
|
8040
7924
|
complete: boolean()
|
|
8041
7925
|
});
|
|
8042
|
-
var
|
|
8043
|
-
|
|
8044
|
-
|
|
8045
|
-
|
|
8046
|
-
|
|
7926
|
+
var taskLine = strictObject({
|
|
7927
|
+
ref: reference,
|
|
7928
|
+
key: text,
|
|
7929
|
+
title: text,
|
|
7930
|
+
status: picklist(TASK_STATES),
|
|
7931
|
+
project: reference,
|
|
7932
|
+
due_at: nullable(time)
|
|
7933
|
+
});
|
|
7934
|
+
var counts = { messages: count, mail: count, meetings: count };
|
|
7935
|
+
var personBusiness = strictObject({
|
|
7936
|
+
organizations: section(strictObject({ ...related.entries, categories })),
|
|
7937
|
+
reports_to: section(related),
|
|
7938
|
+
direct_reports: section(related),
|
|
7939
|
+
deals: section(related),
|
|
7940
|
+
projects: section(related),
|
|
7941
|
+
categories
|
|
7942
|
+
});
|
|
7943
|
+
var personContext = strictObject({
|
|
7944
|
+
...context.entries,
|
|
7945
|
+
person: linkedPerson,
|
|
7946
|
+
has_more: boolean(),
|
|
7947
|
+
business: personBusiness,
|
|
7948
|
+
coverage: coverage2
|
|
7949
|
+
});
|
|
7950
|
+
var organizationContext = strictObject({
|
|
7951
|
+
organization: strictObject({ ...organization.entries, own: boolean() }),
|
|
7952
|
+
categories,
|
|
7953
|
+
people: section(related),
|
|
7954
|
+
customers: section(related),
|
|
7955
|
+
/** Whom it is a customer of: "supplier of", read backwards. */
|
|
7956
|
+
suppliers: section(related),
|
|
7957
|
+
partners: section(related),
|
|
7958
|
+
projects: section(strictObject({ ref: reference, name: text, via: array(picklist(["organization", "deal"])) })),
|
|
7959
|
+
deals: section(strictObject({
|
|
7960
|
+
ref: reference,
|
|
7961
|
+
kind: picklist(DEAL_KINDS),
|
|
7962
|
+
title: text,
|
|
7963
|
+
summary: text,
|
|
7964
|
+
stage: text,
|
|
7965
|
+
status: picklist(DEAL_STATUSES),
|
|
7966
|
+
currency: nullableText2,
|
|
7967
|
+
amount: nullableText2,
|
|
7968
|
+
close_date: day2,
|
|
7969
|
+
project: nullable(reference)
|
|
7970
|
+
})),
|
|
7971
|
+
money,
|
|
7972
|
+
/** Counts only, through its own people, in the accounts read. */
|
|
7973
|
+
communications: strictObject({ ...counts, has_more: boolean() }),
|
|
7974
|
+
tasks: section(taskLine),
|
|
7975
|
+
coverage: coverage2
|
|
7976
|
+
});
|
|
7977
|
+
var { untrusted: _, ...dealRow } = deal.entries;
|
|
7978
|
+
var dealContext = strictObject({
|
|
7979
|
+
deal: strictObject(dealRow),
|
|
7980
|
+
stages: section(strictObject({ from: nullableText2, to: text, pipeline: reference, at: time })),
|
|
7981
|
+
organization: nullable(strictObject({ ref: reference, name: nullableText2, categories })),
|
|
7982
|
+
participants: section(related),
|
|
7983
|
+
owner: nullable(related),
|
|
7984
|
+
project: nullable(strictObject({ ref: reference, name: nullableText2 })),
|
|
7985
|
+
money,
|
|
7986
|
+
window: strictObject({ since: time, until: time }),
|
|
7987
|
+
/** Shared people within its lifetime: `proposed`, an overlap of people, never a link. */
|
|
7988
|
+
communications: strictObject({
|
|
7989
|
+
...section(strictObject({
|
|
7990
|
+
kind: picklist(["message", "mail", "meeting"]),
|
|
7991
|
+
ref: reference,
|
|
7992
|
+
title: nullableText2,
|
|
7993
|
+
at: nullable(time),
|
|
7994
|
+
people: array(reference),
|
|
7995
|
+
standing: literal("proposed")
|
|
7996
|
+
})).entries,
|
|
7997
|
+
counts: strictObject(counts)
|
|
7998
|
+
}),
|
|
7999
|
+
tasks: section(taskLine),
|
|
8000
|
+
coverage: coverage2
|
|
8047
8001
|
});
|
|
8048
|
-
var
|
|
8049
|
-
|
|
8050
|
-
|
|
8051
|
-
|
|
8002
|
+
var dealBrief = strictObject({
|
|
8003
|
+
ref: reference,
|
|
8004
|
+
kind: picklist(DEAL_KINDS),
|
|
8005
|
+
title: text,
|
|
8006
|
+
pipeline: text,
|
|
8007
|
+
stage: text,
|
|
8008
|
+
status: picklist(DEAL_STATUSES),
|
|
8009
|
+
amount: nullableText2,
|
|
8010
|
+
currency: nullableText2,
|
|
8011
|
+
close_date: day2,
|
|
8012
|
+
organization: nullableText2,
|
|
8013
|
+
owner: nullableText2,
|
|
8014
|
+
people: array(strictObject({ ref: reference, name: nullableText2, roles: array(text), standing })),
|
|
8015
|
+
project: nullableText2,
|
|
8016
|
+
stages: array(text),
|
|
8017
|
+
money: strictObject({ ...money.entries.totals.entries, unconfirmed: count, complete: boolean() }),
|
|
8018
|
+
communications: strictObject({ ...counts, standing: literal("proposed") }),
|
|
8019
|
+
open_tasks: count,
|
|
8020
|
+
not_read: coverage2.entries.not_read
|
|
8021
|
+
});
|
|
8022
|
+
|
|
8023
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chart.js
|
|
8024
|
+
var chart = strictObject({
|
|
8025
|
+
version: literal(1),
|
|
8026
|
+
kind: picklist(["bar", "line", "grouped-bar"]),
|
|
8027
|
+
title: text,
|
|
8028
|
+
x: strictObject({ type: picklist(["day", "week"]), values: array(text) }),
|
|
8029
|
+
series: array(strictObject({ name: text, values: array(nullable(number())) })),
|
|
8030
|
+
unit: picklist(["messages", "people"]),
|
|
8031
|
+
timezone: text,
|
|
8032
|
+
/** Lower bounds: the store or the events did not hold the whole period. */
|
|
8033
|
+
partial: boolean(),
|
|
8034
|
+
reasons: array(picklist(["store-incomplete", "events-incomplete"])),
|
|
8035
|
+
file: optional(strictObject({ path: text, format: picklist(["svg", "png"]), width: count, height: count }))
|
|
8052
8036
|
});
|
|
8053
|
-
|
|
8054
|
-
|
|
8055
|
-
|
|
8037
|
+
|
|
8038
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/folder.js
|
|
8039
|
+
var named2 = strictObject({
|
|
8040
|
+
id,
|
|
8041
|
+
title: nullable(text),
|
|
8042
|
+
kind: nullable(picklist(["dialog", "group", "channel", "saved", "unknown"]))
|
|
8043
|
+
});
|
|
8044
|
+
var folder = strictObject({
|
|
8045
|
+
id,
|
|
8046
|
+
title: text,
|
|
8047
|
+
/** Chats added by hand; a folder that selects chats by a rule of its own lists none. */
|
|
8048
|
+
chat_ids: array(id),
|
|
8049
|
+
emoji: optional(text),
|
|
8050
|
+
/** Kinds of chat it takes by itself. */
|
|
8051
|
+
include: optional(array(picklist(["contacts", "non-contacts", "groups", "channels", "bots"]))),
|
|
8052
|
+
skip: optional(array(picklist(["muted", "read", "archived"]))),
|
|
8053
|
+
excluded_chat_ids: optional(array(id)),
|
|
8054
|
+
pinned_chat_ids: optional(array(id)),
|
|
8055
|
+
/** `chats folders show`: the chats in it, pinned and left out, by name. */
|
|
8056
|
+
chats: optional(array(named2)),
|
|
8057
|
+
pinned_chats: optional(array(named2)),
|
|
8058
|
+
excluded_chats: optional(array(named2))
|
|
8056
8059
|
});
|
|
8057
8060
|
|
|
8058
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8059
|
-
var
|
|
8060
|
-
|
|
8061
|
-
|
|
8062
|
-
|
|
8063
|
-
|
|
8064
|
-
|
|
8065
|
-
|
|
8066
|
-
|
|
8067
|
-
|
|
8068
|
-
|
|
8069
|
-
|
|
8070
|
-
|
|
8071
|
-
|
|
8072
|
-
|
|
8073
|
-
support: boolean()
|
|
8074
|
-
})),
|
|
8075
|
-
seen: optional(text),
|
|
8076
|
-
contact: optional(boolean()),
|
|
8077
|
-
mutual_contact: optional(boolean()),
|
|
8078
|
-
common_chats_count: optional(nullable(count)),
|
|
8079
|
-
registered: optional(nullable(strictObject({
|
|
8080
|
-
at: text,
|
|
8081
|
-
source: picklist(["telegram", "max", "estimate"]),
|
|
8082
|
-
precision: picklist(["day", "month"])
|
|
8083
|
-
}))),
|
|
8084
|
-
has_photo: optional(boolean()),
|
|
8085
|
-
/** Earlier names and usernames, oldest first; the current ones are not repeated. */
|
|
8086
|
-
aliases: array(strictObject({
|
|
8087
|
-
name: optional(text),
|
|
8088
|
-
username: optional(text),
|
|
8089
|
-
link: optional(text),
|
|
8090
|
-
first_seen_at: time,
|
|
8091
|
-
last_seen_at: time,
|
|
8092
|
-
source: picklist(["profile", "messages"])
|
|
8093
|
-
}))
|
|
8094
|
-
};
|
|
8061
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/invite-link.js
|
|
8062
|
+
var inviteLink = strictObject({
|
|
8063
|
+
link: text,
|
|
8064
|
+
/** Who joins by it asks first, and an admin lets them in. */
|
|
8065
|
+
approval: boolean(),
|
|
8066
|
+
/** `null` when it never expires. */
|
|
8067
|
+
expires_at: nullable(time),
|
|
8068
|
+
/** `null` for no limit. */
|
|
8069
|
+
max_uses: nullable(count),
|
|
8070
|
+
/** The group's own link; revoking it makes the messenger issue a new one. */
|
|
8071
|
+
primary: optional(boolean()),
|
|
8072
|
+
revoked: optional(boolean()),
|
|
8073
|
+
pending_count: optional(count),
|
|
8074
|
+
joined_count: optional(count)
|
|
8075
|
+
});
|
|
8095
8076
|
|
|
8096
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8097
|
-
var
|
|
8098
|
-
|
|
8099
|
-
|
|
8100
|
-
|
|
8077
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-admin.js
|
|
8078
|
+
var operated = { operation_id: id, chat_id: id };
|
|
8079
|
+
var group = strictObject({
|
|
8080
|
+
...omit(chat, ["ref", "provider", "account", "invite_link", "members"]).entries,
|
|
8081
|
+
parent_chat_id: optional(nullable(id)),
|
|
8082
|
+
muted_until: optional(nullable(time)),
|
|
8083
|
+
description: nullable(text),
|
|
8084
|
+
link: nullable(text),
|
|
8085
|
+
settings: strictObject({
|
|
8086
|
+
...unwrap(chat.entries.settings).entries,
|
|
8087
|
+
all_can_pin: nullable(boolean()),
|
|
8088
|
+
only_admins_add: nullable(boolean()),
|
|
8089
|
+
only_admins_call: nullable(boolean()),
|
|
8090
|
+
only_owner_edits_info: nullable(boolean()),
|
|
8091
|
+
members_see_link: nullable(boolean())
|
|
8092
|
+
})
|
|
8093
|
+
});
|
|
8094
|
+
var chatGroupChange = union([
|
|
8095
|
+
strictObject({ operation_id: id, chat: group }),
|
|
8096
|
+
strictObject({ operation_id: id, requested: literal(true) })
|
|
8097
|
+
]);
|
|
8098
|
+
var chatInspection = strictObject({
|
|
8099
|
+
kind: chat.entries.kind,
|
|
8100
|
+
title: nullable(text),
|
|
8101
|
+
id: nullable(id),
|
|
8101
8102
|
username: nullable(text),
|
|
8102
|
-
|
|
8103
|
-
display_name: optional(nullable(text)),
|
|
8104
|
-
/** Whatever they wrote about themselves. */
|
|
8103
|
+
participants_count: nullable(count),
|
|
8105
8104
|
description: nullable(text),
|
|
8106
|
-
|
|
8107
|
-
|
|
8108
|
-
/** For a source that knows it, such as a Zoom contact. */
|
|
8109
|
-
email: optional(nullable(text)),
|
|
8110
|
-
phones: optional(array(strictObject({ number: text, label: nullable(text) }))),
|
|
8111
|
-
/** `contacts show`: the chats shared with them, and what the store holds of their messages in each. */
|
|
8112
|
-
chats: optional(array(strictObject({
|
|
8113
|
-
...pick(chat, ["ref", "id", "title", "kind", "last_message_at"]).entries,
|
|
8114
|
-
/** Their messages stored; a floor unless `complete`. */
|
|
8115
|
-
their_messages: optional(count),
|
|
8116
|
-
first_at: optional(nullable(time)),
|
|
8117
|
-
last_at: optional(nullable(time)),
|
|
8118
|
-
/** The store holds the whole chat, so the count is the real one. */
|
|
8119
|
-
complete: optional(boolean())
|
|
8120
|
-
}))),
|
|
8121
|
-
/** `contacts show`: what the messenger says about them, or with `--offline` what the store saw of them. */
|
|
8122
|
-
...partial(strictObject(profileFields)).entries,
|
|
8123
|
-
/** `contacts show --with-notes`: the owner's private notes about them. */
|
|
8124
|
-
notes: optional(array(strictObject({ id, text, revision: count, created_at: time, updated_at: time })))
|
|
8105
|
+
member: nullable(boolean()),
|
|
8106
|
+
approval_needed: optional(boolean())
|
|
8125
8107
|
});
|
|
8126
|
-
|
|
8127
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/botcheck/reasons.js
|
|
8128
|
-
var WEIGHTS = {
|
|
8129
|
-
bot: 3,
|
|
8130
|
-
scam: 3,
|
|
8131
|
-
fake: 3,
|
|
8132
|
-
deleted: 1,
|
|
8133
|
-
no_photo: 1,
|
|
8134
|
-
no_username: 1,
|
|
8135
|
-
odd_name: 1,
|
|
8136
|
-
never_wrote: 1,
|
|
8137
|
-
link_first: 2,
|
|
8138
|
-
burst_join: 1,
|
|
8139
|
-
mass_invited: 1,
|
|
8140
|
-
new_account: 2,
|
|
8141
|
-
no_bio: 1,
|
|
8142
|
-
same_text: 2,
|
|
8143
|
-
photo_recent: 1,
|
|
8144
|
-
cas_banned: 3,
|
|
8145
|
-
lols_banned: 3,
|
|
8146
|
-
lols_scammer: 3
|
|
8147
|
-
};
|
|
8148
|
-
var LINK = /https?:\/\/|t\.me\/|www\./i;
|
|
8149
|
-
var DIGITS = /\d{5,}/;
|
|
8150
|
-
var oddName = /* @__PURE__ */ __name((name) => !name?.trim() || DIGITS.test(name) || LINK.test(name), "oddName");
|
|
8151
|
-
|
|
8152
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/entities/contact-activity.js
|
|
8153
|
-
var linkedIdentity = strictObject({
|
|
8154
|
-
provider: text,
|
|
8108
|
+
var chatSender = strictObject({
|
|
8155
8109
|
id,
|
|
8156
|
-
|
|
8157
|
-
|
|
8158
|
-
|
|
8159
|
-
|
|
8160
|
-
seen_in: array(strictObject({ account: id, scope: picklist(["personal", "work"]) })),
|
|
8161
|
-
method: text,
|
|
8162
|
-
linked_by: text,
|
|
8163
|
-
linked_at: time
|
|
8110
|
+
title: text,
|
|
8111
|
+
kind: picklist(["self", "channel", "group"]),
|
|
8112
|
+
premium_required: boolean(),
|
|
8113
|
+
default: boolean()
|
|
8164
8114
|
});
|
|
8165
|
-
var
|
|
8166
|
-
var
|
|
8167
|
-
|
|
8168
|
-
|
|
8169
|
-
|
|
8170
|
-
|
|
8171
|
-
|
|
8172
|
-
|
|
8173
|
-
|
|
8174
|
-
|
|
8175
|
-
|
|
8176
|
-
project_id: nullable(count)
|
|
8115
|
+
var chatRead = strictObject({ ...operated, until: nullable(id), thread_id: optional(id) });
|
|
8116
|
+
var chatMembersFetch = strictObject({
|
|
8117
|
+
chat_id: id,
|
|
8118
|
+
joined: array(id),
|
|
8119
|
+
gone: array(id),
|
|
8120
|
+
changed: array(id),
|
|
8121
|
+
read: count,
|
|
8122
|
+
participants: nullable(count),
|
|
8123
|
+
complete: boolean(),
|
|
8124
|
+
more: boolean(),
|
|
8125
|
+
tracked: boolean()
|
|
8177
8126
|
});
|
|
8178
|
-
var
|
|
8179
|
-
|
|
8180
|
-
|
|
8181
|
-
|
|
8182
|
-
|
|
8183
|
-
|
|
8184
|
-
|
|
8185
|
-
|
|
8186
|
-
|
|
8187
|
-
|
|
8188
|
-
reasons: optional(array(picklist(["cas_banned", "lols_banned", "lols_scammer"])))
|
|
8189
|
-
})),
|
|
8190
|
-
unknown: array(botReason),
|
|
8191
|
-
checked_at: time
|
|
8127
|
+
var chatMembersChange = union([
|
|
8128
|
+
strictObject({ ...operated, added: array(id), not_added: array(id) }),
|
|
8129
|
+
strictObject({ ...operated, removed: array(id) })
|
|
8130
|
+
]);
|
|
8131
|
+
var chatInvite = strictObject({ chat_id: id, title: nullable(text), link: text });
|
|
8132
|
+
var chatInviteChange = strictObject({
|
|
8133
|
+
...operated,
|
|
8134
|
+
...omit(inviteLink, ["pending_count", "joined_count"]).entries,
|
|
8135
|
+
pending: optional(count),
|
|
8136
|
+
joined: optional(count)
|
|
8192
8137
|
});
|
|
8193
|
-
|
|
8194
|
-
|
|
8195
|
-
|
|
8196
|
-
|
|
8197
|
-
|
|
8198
|
-
|
|
8199
|
-
|
|
8200
|
-
|
|
8201
|
-
attachments: array(attachment),
|
|
8202
|
-
outgoing: nullable(boolean())
|
|
8138
|
+
var chatRequestChange = union([
|
|
8139
|
+
strictObject({ ...operated, person_id: id, accepted: boolean(), already: boolean() }),
|
|
8140
|
+
strictObject({ chat_id: id, accepted: boolean(), counted: count, operation_id: optional(id) })
|
|
8141
|
+
]);
|
|
8142
|
+
var chatAdminChange = strictObject({
|
|
8143
|
+
...operated,
|
|
8144
|
+
person_id: id,
|
|
8145
|
+
rights: optional(array(picklist(["read", "members", "admins", "info", "pin", "link", "post", "edit", "delete"])))
|
|
8203
8146
|
});
|
|
8204
|
-
var
|
|
8205
|
-
|
|
8206
|
-
|
|
8207
|
-
|
|
8208
|
-
|
|
8209
|
-
|
|
8210
|
-
|
|
8211
|
-
|
|
8212
|
-
|
|
8213
|
-
|
|
8214
|
-
|
|
8215
|
-
|
|
8216
|
-
|
|
8217
|
-
|
|
8218
|
-
|
|
8219
|
-
|
|
8220
|
-
timestamp: time,
|
|
8221
|
-
edited_at: nullable(time),
|
|
8222
|
-
text,
|
|
8223
|
-
/** What a voice message says, once heard. */
|
|
8224
|
-
transcript: optional(text),
|
|
8225
|
-
/** In a window of messages around one, the one asked for. */
|
|
8226
|
-
anchor: optional(boolean()),
|
|
8227
|
-
/** A stretch of the text, transcript, file name or file text around what a search matched. */
|
|
8228
|
-
excerpt: optional(text),
|
|
8229
|
-
/** `picture`: the picture search lane found it by what the picture shows; it follows the text hits. */
|
|
8230
|
-
matched_in: optional(picklist(["text", "transcript", "filename", "file", "context", "picture"])),
|
|
8231
|
-
score: optional(number()),
|
|
8232
|
-
/**
|
|
8233
|
-
* `corrected`: a query word matched only a spelling speech recognition garbled in a voice note's transcript,
|
|
8234
|
-
* listed in `corrections`. `words` and `beginnings`: what a discovery search matched.
|
|
8235
|
-
*/
|
|
8236
|
-
match: optional(picklist(["words", "beginnings", "corrected"])),
|
|
8237
|
-
corrections: optional(array(strictObject({ from: text, to: array(text) }))),
|
|
8238
|
-
/** Where a search found it: the local archive, the messenger's server, or both. */
|
|
8239
|
-
found_in: optional(picklist(["archive", "server", "both"])),
|
|
8240
|
-
/** A discovery search's partial match: how much of the question it covers, and which words it lacks. */
|
|
8241
|
-
discovery: optional(strictObject({
|
|
8242
|
-
coverage: number(),
|
|
8243
|
-
matched_terms: array(text),
|
|
8244
|
-
missing_terms: array(text),
|
|
8245
|
-
parent: optional(reference),
|
|
8246
|
-
/** Present when meaning was searched too: which of the two lists found it. */
|
|
8247
|
-
found_by: optional(array(picklist(["words", "meaning"]))),
|
|
8248
|
-
/** Present when the reranker read it: its own score, higher is better. It ordered the first hits with `score`. */
|
|
8249
|
-
reranker_score: optional(number())
|
|
8250
|
-
})),
|
|
8251
|
-
/** The messages around a search hit, or its thread, oldest first; the hit itself is among them. */
|
|
8252
|
-
context: optional(array(strictObject({ ref: reference, timestamp: time, sender_name: nullable(text), text }))),
|
|
8253
|
-
/**
|
|
8254
|
-
* A discovery hit's later messages, from any chat the search reads, that share a rare word with it, latest first:
|
|
8255
|
-
* one may change or cancel what the hit says. An excerpt, as the hit's own: `messages context <ref>` has the whole text.
|
|
8256
|
-
*/
|
|
8257
|
-
follow_ups: optional(array(strictObject({
|
|
8258
|
-
ref: reference,
|
|
8259
|
-
chat_title: nullable(text),
|
|
8260
|
-
timestamp: time,
|
|
8261
|
-
sender_name: nullable(text),
|
|
8262
|
-
excerpt: text
|
|
8263
|
-
}))),
|
|
8264
|
-
outgoing: nullable(boolean()),
|
|
8265
|
-
attachments: array(attachment),
|
|
8266
|
-
reply_to: nullable(quoted),
|
|
8267
|
-
/** The id a reply answers, also when the provider sent no copy of that message. */
|
|
8268
|
-
reply_to_id: optional(id),
|
|
8269
|
-
forwarded_from: nullable(quoted),
|
|
8270
|
-
thread_id: optional(id),
|
|
8271
|
-
thread_root_id: optional(id),
|
|
8272
|
-
reactions: optional(nullable(strictObject({
|
|
8273
|
-
counts: array(strictObject({ reaction: text, count })),
|
|
8274
|
-
mine: nullable(text),
|
|
8275
|
-
total: count
|
|
8276
|
-
}))),
|
|
8277
|
-
scheduled_for: optional(time),
|
|
8278
|
-
/** The owner starred it; only where the messenger has stars, and only when set. */
|
|
8279
|
-
starred: optional(literal(true)),
|
|
8280
|
-
/** The owner's own message in a one-to-one chat: `delivered`, or `read` once opened; absent when no receipt came. */
|
|
8281
|
-
delivery: optional(picklist(["delivered", "read"])),
|
|
8282
|
-
email: optional(strictObject({
|
|
8283
|
-
subject: nullable(text),
|
|
8284
|
-
from: nullable(mailPerson),
|
|
8285
|
-
to: array(mailPerson),
|
|
8286
|
-
cc: array(mailPerson),
|
|
8287
|
-
bcc: array(mailPerson),
|
|
8288
|
-
/** The mail header Reply-To; `reply_to` is the quoted message a chat reply answers. */
|
|
8289
|
-
reply_addresses: array(mailPerson),
|
|
8290
|
-
labels: array(text),
|
|
8291
|
-
/** The thread as a `chat:` reference. */
|
|
8292
|
-
thread: reference,
|
|
8293
|
-
read: nullable(boolean()),
|
|
8294
|
-
flagged: nullable(boolean()),
|
|
8295
|
-
/** How much the sender's mail looks like spam, a scam or a robot (memo's score), and why; absent when unscored. */
|
|
8296
|
-
sender_score: optional(strictObject({ score: number(), signals: array(text), demoted: optional(literal(true)) })),
|
|
8297
|
-
/** Mail `review`: filed in the mailbox of mail sent to many. */
|
|
8298
|
-
bulk: optional(boolean()),
|
|
8299
|
-
/** Mail `review`: its List-Id, `null` when it has none. */
|
|
8300
|
-
list_id: optional(nullable(text)),
|
|
8301
|
-
/** Mail `review`: the mail rule that decided how it is stored, by its id in `rules list`; `null` when none. */
|
|
8302
|
-
rule_id: optional(nullable(number())),
|
|
8303
|
-
/** Mail `review`: the evidence fingerprint a finding cites this email by. */
|
|
8304
|
-
fingerprint: optional(pipe(text, regex(/^[a-f0-9]{64}$/))),
|
|
8305
|
-
/** Mail `review`: no earlier stored email, in any account, came from this address. */
|
|
8306
|
-
new_sender: optional(boolean()),
|
|
8307
|
-
/** Mail `review`: how many identities the sender's person has; 1 is this address alone. */
|
|
8308
|
-
sender_identities: optional(number())
|
|
8309
|
-
})),
|
|
8310
|
-
provider_metadata: providerMetadata
|
|
8147
|
+
var chatFolderChange = strictObject({
|
|
8148
|
+
operation_id: id,
|
|
8149
|
+
folder: omit(folder, ["chats", "pinned_chats", "excluded_chats"])
|
|
8150
|
+
});
|
|
8151
|
+
var chatFolderRemoval = strictObject({ operation_id: id, folder_id: id });
|
|
8152
|
+
var chatFolderOrder = strictObject({
|
|
8153
|
+
operation_id: id,
|
|
8154
|
+
folders: array(strictObject({ id, title: text }))
|
|
8155
|
+
});
|
|
8156
|
+
|
|
8157
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-change.js
|
|
8158
|
+
var operated2 = { operation_id: id, chat_id: id };
|
|
8159
|
+
var chatRemoval = strictObject(operated2);
|
|
8160
|
+
var chatMuting = strictObject({
|
|
8161
|
+
...operated2,
|
|
8162
|
+
muted_until: nullable(union([time, literal("forever")]))
|
|
8311
8163
|
});
|
|
8164
|
+
var chatArchive = strictObject({ ...operated2, archived: boolean() });
|
|
8165
|
+
var chatPin = strictObject({ ...operated2, pinned: boolean() });
|
|
8166
|
+
var chatUnread = strictObject({ ...operated2, unread: literal(true) });
|
|
8312
8167
|
|
|
8313
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8314
|
-
var
|
|
8315
|
-
var
|
|
8316
|
-
locator: reference,
|
|
8317
|
-
provider: text,
|
|
8318
|
-
account: id,
|
|
8168
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-event.js
|
|
8169
|
+
var who = strictObject({ id: nullable(id), name: nullable(text), username: optional(nullable(text)) });
|
|
8170
|
+
var chatEvent = strictObject({
|
|
8319
8171
|
chat_id: id,
|
|
8320
|
-
|
|
8321
|
-
|
|
8322
|
-
|
|
8323
|
-
|
|
8324
|
-
|
|
8325
|
-
|
|
8326
|
-
|
|
8172
|
+
time,
|
|
8173
|
+
/** `join`, `leave`, `add`, `remove`, `create`, `title`, `pin`, `profile`; a messenger may pass others through. */
|
|
8174
|
+
type: text,
|
|
8175
|
+
/** The service message that says so, where there is one. */
|
|
8176
|
+
message_id: optional(id),
|
|
8177
|
+
by: optional(who),
|
|
8178
|
+
people: array(who),
|
|
8179
|
+
/** `create` and `title` carry the chat's title. */
|
|
8180
|
+
title: optional(text),
|
|
8181
|
+
/** `profile`: the name and username seen before. */
|
|
8182
|
+
before: optional(strictObject({ name: nullable(text), username: nullable(text) }))
|
|
8327
8183
|
});
|
|
8328
|
-
|
|
8329
|
-
|
|
8330
|
-
|
|
8184
|
+
|
|
8185
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-metadata.js
|
|
8186
|
+
var chatMetadata = strictObject({
|
|
8331
8187
|
chat_id: id,
|
|
8332
8188
|
title: nullable(text),
|
|
8333
|
-
|
|
8334
|
-
|
|
8189
|
+
username: nullable(text),
|
|
8190
|
+
description: nullable(text),
|
|
8191
|
+
fetched_at: time
|
|
8335
8192
|
});
|
|
8336
|
-
var
|
|
8337
|
-
|
|
8338
|
-
|
|
8339
|
-
|
|
8340
|
-
|
|
8341
|
-
all_day: boolean(),
|
|
8342
|
-
location: nullable(text),
|
|
8343
|
-
status: nullable(text)
|
|
8193
|
+
var cachedChatMetadata = strictObject({ chat_id: id, metadata: nullable(chatMetadata) });
|
|
8194
|
+
var failedChatMetadata = strictObject({ chat_id: id, error: strictObject({ code: text, message: text }) });
|
|
8195
|
+
var chatMetadataRefresh = strictObject({
|
|
8196
|
+
chats: array(union([chatMetadata, failedChatMetadata])),
|
|
8197
|
+
has_more: boolean()
|
|
8344
8198
|
});
|
|
8345
|
-
|
|
8346
|
-
|
|
8347
|
-
|
|
8348
|
-
|
|
8349
|
-
|
|
8350
|
-
|
|
8351
|
-
|
|
8352
|
-
|
|
8353
|
-
|
|
8354
|
-
|
|
8355
|
-
recent: strictObject({ direct: array(contextMessage), groups: array(contextMessage) }),
|
|
8356
|
-
mentions: array(contextMessage),
|
|
8357
|
-
/** Calendar events they are invited to, one occurrence per series. */
|
|
8358
|
-
events: optional(strictObject({ upcoming: array(contextEvent), recent: array(contextEvent) })),
|
|
8359
|
-
limits: strictObject({ messages: count, bytes: count }),
|
|
8360
|
-
complete: boolean(),
|
|
8361
|
-
not_read: array(strictObject({
|
|
8362
|
-
provider: text,
|
|
8363
|
-
account: id,
|
|
8364
|
-
chat_id: id,
|
|
8199
|
+
|
|
8200
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-moderation.js
|
|
8201
|
+
var action = picklist(["report", "delete", "remove"]);
|
|
8202
|
+
var level = picklist(["deny", "readonly", "ask", "allow"]);
|
|
8203
|
+
var chatRules = strictObject({
|
|
8204
|
+
chat_id: id,
|
|
8205
|
+
title: nullable(text),
|
|
8206
|
+
file: text,
|
|
8207
|
+
saved: boolean(),
|
|
8208
|
+
rules: strictObject({
|
|
8365
8209
|
title: nullable(text),
|
|
8366
|
-
|
|
8210
|
+
trusted: array(id),
|
|
8211
|
+
blocked: array(id),
|
|
8212
|
+
blocked_names: array(text),
|
|
8213
|
+
links: action,
|
|
8214
|
+
invites: action,
|
|
8215
|
+
forwards: action,
|
|
8216
|
+
blocked_people: action,
|
|
8217
|
+
flood: strictObject({ messages: count, minutes: count, action }),
|
|
8218
|
+
new_account: strictObject({ days: count, action: picklist(["report", "remove"]) }),
|
|
8219
|
+
consent: strictObject({ delete: level, remove: level })
|
|
8220
|
+
})
|
|
8221
|
+
});
|
|
8222
|
+
var chatModeration = strictObject({
|
|
8223
|
+
chat_id: id,
|
|
8224
|
+
rows: array(strictObject({
|
|
8225
|
+
kind: picklist(["message", "member"]),
|
|
8226
|
+
rule: picklist(["blocked", "invites", "links", "forwards", "flood", "newAccount"]),
|
|
8227
|
+
person_id: id,
|
|
8228
|
+
person_name: nullable(text),
|
|
8229
|
+
message_id: optional(id),
|
|
8230
|
+
action,
|
|
8231
|
+
outcome: picklist(["reported", "done", "planned", "forbidden", "declined", "refused", "failed", "skipped"]),
|
|
8232
|
+
reason: optional(text),
|
|
8233
|
+
command: optional(text)
|
|
8367
8234
|
}))
|
|
8368
8235
|
});
|
|
8369
|
-
|
|
8370
|
-
|
|
8371
|
-
|
|
8372
|
-
|
|
8373
|
-
|
|
8374
|
-
|
|
8375
|
-
|
|
8236
|
+
|
|
8237
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-stats.js
|
|
8238
|
+
var optionalCount = optional(count);
|
|
8239
|
+
var minutes = nullable(number());
|
|
8240
|
+
var chatStats = strictObject({
|
|
8241
|
+
chat: reference,
|
|
8242
|
+
since: time,
|
|
8243
|
+
until: time,
|
|
8244
|
+
/** The store holds the chat whole and the messenger read every join and leave; otherwise lower bounds. */
|
|
8245
|
+
complete: boolean(),
|
|
8246
|
+
completeness: strictObject({
|
|
8247
|
+
state: picklist(["complete", "partial", "unknown"]),
|
|
8248
|
+
up_to_date: nullable(boolean()),
|
|
8249
|
+
gaps: boolean(),
|
|
8250
|
+
reaches_start: boolean(),
|
|
8251
|
+
fetched_at: nullable(time)
|
|
8252
|
+
}),
|
|
8253
|
+
messages: count,
|
|
8254
|
+
senders: count,
|
|
8255
|
+
replies: count,
|
|
8256
|
+
threads: count,
|
|
8257
|
+
reactions: count,
|
|
8258
|
+
views: optionalCount,
|
|
8259
|
+
forwards: optionalCount,
|
|
8260
|
+
comments: optionalCount,
|
|
8261
|
+
top_posts: array(strictObject({
|
|
8262
|
+
ref: reference,
|
|
8263
|
+
timestamp: time,
|
|
8264
|
+
reactions: count,
|
|
8265
|
+
views: optionalCount,
|
|
8266
|
+
forwards: optionalCount,
|
|
8267
|
+
comments: optionalCount
|
|
8268
|
+
})),
|
|
8269
|
+
questions: strictObject({
|
|
8270
|
+
asked: count,
|
|
8271
|
+
answered: count,
|
|
8272
|
+
median_minutes_to_answer: minutes,
|
|
8273
|
+
answered_by: picklist(["owner", "owner-and-admins"])
|
|
8274
|
+
}),
|
|
8275
|
+
member_counts: optional(array(strictObject({ day: text, participants: nullable(count), listed: count, complete: boolean() }))),
|
|
8276
|
+
/** Absent where joins and leaves were not asked, or not recorded for the chat yet (then `missing` says so). */
|
|
8277
|
+
members: optional(strictObject({
|
|
8278
|
+
joined: count,
|
|
8279
|
+
left: count,
|
|
8280
|
+
net: number(),
|
|
8281
|
+
wrote: count,
|
|
8282
|
+
median_minutes_to_first_message: minutes,
|
|
8283
|
+
/** The messenger stopped reading its history before `since`: the counts are lower bounds. */
|
|
8284
|
+
more: boolean()
|
|
8285
|
+
})),
|
|
8286
|
+
series: optional(array(strictObject({ key: text, messages: count, senders: count, joined: optionalCount, left: optionalCount })))
|
|
8376
8287
|
});
|
|
8377
|
-
var
|
|
8378
|
-
|
|
8379
|
-
|
|
8380
|
-
|
|
8381
|
-
|
|
8288
|
+
var ms = nullable(pipe(number(), minValue(0)));
|
|
8289
|
+
var taskStats = strictObject({
|
|
8290
|
+
/** Open tasks across every row. */
|
|
8291
|
+
open: count,
|
|
8292
|
+
created: count,
|
|
8293
|
+
closed: count,
|
|
8294
|
+
median_close_ms: ms,
|
|
8295
|
+
mean_open_age_ms: ms,
|
|
8296
|
+
rows: array(strictObject({
|
|
8297
|
+
/** Rows of `--by chat` only. */
|
|
8298
|
+
chat: optional(reference),
|
|
8299
|
+
/** The chat reference, `meeting:<account>/<meeting>` or `project:<id>`. */
|
|
8300
|
+
key: text,
|
|
8301
|
+
name: nullable(text),
|
|
8302
|
+
open: count,
|
|
8303
|
+
created: count,
|
|
8304
|
+
closed: count,
|
|
8305
|
+
oldest_open_at: nullable(time),
|
|
8306
|
+
median_close_ms: ms,
|
|
8307
|
+
mean_open_age_ms: ms
|
|
8308
|
+
}))
|
|
8382
8309
|
});
|
|
8383
|
-
|
|
8384
|
-
|
|
8385
|
-
|
|
8386
|
-
|
|
8387
|
-
|
|
8388
|
-
|
|
8389
|
-
|
|
8390
|
-
"sender_id",
|
|
8391
|
-
"sender_name",
|
|
8392
|
-
"sender_username",
|
|
8393
|
-
"mentions",
|
|
8394
|
-
"sender_is_chat",
|
|
8395
|
-
"timestamp",
|
|
8396
|
-
"edited_at",
|
|
8397
|
-
"text",
|
|
8398
|
-
"outgoing",
|
|
8399
|
-
"attachments",
|
|
8400
|
-
"reply_to",
|
|
8401
|
-
"reply_to_id",
|
|
8402
|
-
"forwarded_from",
|
|
8403
|
-
"thread_id",
|
|
8404
|
-
"thread_root_id",
|
|
8405
|
-
"scheduled_for",
|
|
8406
|
-
"provider_metadata",
|
|
8407
|
-
"delivery"
|
|
8408
|
-
]).entries,
|
|
8409
|
-
reactions: nullable(message.entries.reactions.wrapped.wrapped),
|
|
8410
|
-
starred: optional(boolean()),
|
|
8411
|
-
email: optional(strictObject({ ...mailFields, reply_to: mailReplyTo })),
|
|
8412
|
-
counter_observations: optional(partial(strictObject({
|
|
8413
|
-
views: counterObservation,
|
|
8414
|
-
reactions: counterObservation,
|
|
8415
|
-
comments: counterObservation
|
|
8416
|
-
}))),
|
|
8417
|
-
...shortMessage.entries,
|
|
8418
|
-
locator: reference
|
|
8310
|
+
|
|
8311
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/chat-tracking.js
|
|
8312
|
+
var memberCount = strictObject({
|
|
8313
|
+
day: pipe(text, isoDate()),
|
|
8314
|
+
participants: nullable(count),
|
|
8315
|
+
listed: count,
|
|
8316
|
+
complete: boolean()
|
|
8419
8317
|
});
|
|
8420
|
-
var
|
|
8421
|
-
|
|
8422
|
-
|
|
8423
|
-
|
|
8424
|
-
|
|
8425
|
-
complete: boolean(),
|
|
8426
|
-
more: boolean()
|
|
8427
|
-
})),
|
|
8428
|
-
limits: strictObject({ messages: count })
|
|
8318
|
+
var trackedChat = strictObject({
|
|
8319
|
+
chat_id: id,
|
|
8320
|
+
title: nullable(text),
|
|
8321
|
+
tracked_at: time,
|
|
8322
|
+
last_count: nullable(memberCount)
|
|
8429
8323
|
});
|
|
8430
|
-
var
|
|
8431
|
-
|
|
8432
|
-
|
|
8433
|
-
|
|
8434
|
-
cut_by: nullable(picklist(["limit", "bytes"]))
|
|
8324
|
+
var trackedChatHistory = strictObject({
|
|
8325
|
+
chat_id: id,
|
|
8326
|
+
tracked_at: nullable(time),
|
|
8327
|
+
counts: array(memberCount)
|
|
8435
8328
|
});
|
|
8436
|
-
var
|
|
8437
|
-
|
|
8438
|
-
|
|
8439
|
-
transcript_id: count,
|
|
8440
|
-
content_hash: nullable(text),
|
|
8441
|
-
position: count,
|
|
8442
|
-
start_ms: count,
|
|
8443
|
-
end_ms: count,
|
|
8444
|
-
speaker_participant_id: nullable(count),
|
|
8445
|
-
speaker_name: nullable(text),
|
|
8446
|
-
text,
|
|
8447
|
-
revision: picklist(["current", "superseded"])
|
|
8329
|
+
var chatTracking = strictObject({
|
|
8330
|
+
chat_id: id,
|
|
8331
|
+
tracked: boolean()
|
|
8448
8332
|
});
|
|
8449
|
-
|
|
8450
|
-
|
|
8451
|
-
|
|
8452
|
-
|
|
8453
|
-
|
|
8454
|
-
|
|
8455
|
-
|
|
8456
|
-
|
|
8457
|
-
|
|
8458
|
-
|
|
8459
|
-
|
|
8460
|
-
|
|
8461
|
-
|
|
8462
|
-
|
|
8463
|
-
|
|
8464
|
-
|
|
8465
|
-
|
|
8466
|
-
|
|
8467
|
-
|
|
8468
|
-
|
|
8469
|
-
|
|
8470
|
-
|
|
8471
|
-
|
|
8472
|
-
|
|
8473
|
-
|
|
8474
|
-
|
|
8475
|
-
|
|
8476
|
-
|
|
8477
|
-
|
|
8478
|
-
|
|
8479
|
-
|
|
8480
|
-
|
|
8481
|
-
|
|
8482
|
-
|
|
8483
|
-
|
|
8484
|
-
|
|
8485
|
-
|
|
8486
|
-
|
|
8487
|
-
|
|
8488
|
-
|
|
8489
|
-
|
|
8490
|
-
|
|
8491
|
-
|
|
8492
|
-
|
|
8493
|
-
|
|
8494
|
-
|
|
8495
|
-
|
|
8496
|
-
|
|
8497
|
-
|
|
8498
|
-
|
|
8499
|
-
|
|
8500
|
-
|
|
8501
|
-
|
|
8502
|
-
|
|
8503
|
-
|
|
8504
|
-
|
|
8505
|
-
|
|
8506
|
-
|
|
8507
|
-
|
|
8508
|
-
|
|
8509
|
-
|
|
8510
|
-
|
|
8333
|
+
|
|
8334
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact-read.js
|
|
8335
|
+
var contactLookup = strictObject({ id, name: nullable(text), username: nullable(text) });
|
|
8336
|
+
var contactSync = strictObject({ added: count, changed: count, known: count });
|
|
8337
|
+
var profileFields = {
|
|
8338
|
+
usernames: array(text),
|
|
8339
|
+
birthday: optional(nullable(text)),
|
|
8340
|
+
phone: optional(nullable(text)),
|
|
8341
|
+
flags: partial(strictObject({
|
|
8342
|
+
bot: boolean(),
|
|
8343
|
+
verified: boolean(),
|
|
8344
|
+
premium: boolean(),
|
|
8345
|
+
scam: boolean(),
|
|
8346
|
+
fake: boolean(),
|
|
8347
|
+
restricted: boolean(),
|
|
8348
|
+
deleted: boolean(),
|
|
8349
|
+
support: boolean()
|
|
8350
|
+
})),
|
|
8351
|
+
seen: optional(text),
|
|
8352
|
+
contact: optional(boolean()),
|
|
8353
|
+
mutual_contact: optional(boolean()),
|
|
8354
|
+
common_chats_count: optional(nullable(count)),
|
|
8355
|
+
registered: optional(nullable(strictObject({
|
|
8356
|
+
at: text,
|
|
8357
|
+
source: picklist(["telegram", "max", "estimate"]),
|
|
8358
|
+
precision: picklist(["day", "month"])
|
|
8359
|
+
}))),
|
|
8360
|
+
has_photo: optional(boolean()),
|
|
8361
|
+
/** Earlier names and usernames, oldest first; the current ones are not repeated. */
|
|
8362
|
+
aliases: array(strictObject({
|
|
8363
|
+
name: optional(text),
|
|
8364
|
+
username: optional(text),
|
|
8365
|
+
link: optional(text),
|
|
8366
|
+
first_seen_at: time,
|
|
8367
|
+
last_seen_at: time,
|
|
8368
|
+
source: picklist(["profile", "messages"])
|
|
8369
|
+
}))
|
|
8370
|
+
};
|
|
8371
|
+
|
|
8372
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact.js
|
|
8373
|
+
var contact = strictObject({
|
|
8374
|
+
ref: reference,
|
|
8375
|
+
id,
|
|
8376
|
+
name: nullable(text),
|
|
8377
|
+
username: nullable(text),
|
|
8378
|
+
alias: optional(nullable(text)),
|
|
8379
|
+
display_name: optional(nullable(text)),
|
|
8380
|
+
/** Whatever they wrote about themselves. */
|
|
8381
|
+
description: nullable(text),
|
|
8382
|
+
/** The newest message in a one-to-one chat with them. */
|
|
8383
|
+
last_messaged_at: nullable(time),
|
|
8384
|
+
/** For a source that knows it, such as a Zoom contact. */
|
|
8385
|
+
email: optional(nullable(text)),
|
|
8386
|
+
phones: optional(array(strictObject({ number: text, label: nullable(text) }))),
|
|
8387
|
+
/** `contacts show`: the chats shared with them, and what the store holds of their messages in each. */
|
|
8388
|
+
chats: optional(array(strictObject({
|
|
8389
|
+
...pick(chat, ["ref", "id", "title", "kind", "last_message_at"]).entries,
|
|
8390
|
+
/** Their messages stored; a floor unless `complete`. */
|
|
8391
|
+
their_messages: optional(count),
|
|
8392
|
+
first_at: optional(nullable(time)),
|
|
8393
|
+
last_at: optional(nullable(time)),
|
|
8394
|
+
/** The store holds the whole chat, so the count is the real one. */
|
|
8395
|
+
complete: optional(boolean())
|
|
8396
|
+
}))),
|
|
8397
|
+
/** `contacts show`: what the messenger says about them, or with `--offline` what the store saw of them. */
|
|
8398
|
+
...partial(strictObject(profileFields)).entries,
|
|
8399
|
+
/** `contacts show --with-notes`: the owner's private notes about them. */
|
|
8400
|
+
notes: optional(array(strictObject({ id, text, revision: count, created_at: time, updated_at: time })))
|
|
8511
8401
|
});
|
|
8512
8402
|
|
|
8513
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8403
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact-note.js
|
|
8514
8404
|
var contactNote = strictObject({
|
|
8515
8405
|
id,
|
|
8516
8406
|
/** The contact, as a `contact:` reference. */
|
|
@@ -8522,13 +8412,13 @@ var contactNote = strictObject({
|
|
|
8522
8412
|
updated_at: time
|
|
8523
8413
|
});
|
|
8524
8414
|
|
|
8525
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8415
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/contact-write.js
|
|
8526
8416
|
var addressBookPerson = strictObject({ id, name: nullable(text), username: nullable(text) });
|
|
8527
8417
|
var contactUpdate = strictObject({ operation_id: id, person: addressBookPerson });
|
|
8528
8418
|
var contactStateChange = strictObject({ operation_id: id, person_id: id });
|
|
8529
8419
|
var contactImport = strictObject({ operation_id: id, sent: count, recognised: array(addressBookPerson) });
|
|
8530
8420
|
|
|
8531
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8421
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/conversation.js
|
|
8532
8422
|
var conversation = strictObject({
|
|
8533
8423
|
id,
|
|
8534
8424
|
chat: reference,
|
|
@@ -8543,7 +8433,7 @@ var conversation = strictObject({
|
|
|
8543
8433
|
rules_version: count
|
|
8544
8434
|
});
|
|
8545
8435
|
|
|
8546
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8436
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/conversation-preparation.js
|
|
8547
8437
|
var conversationBuild = strictObject({
|
|
8548
8438
|
chat: id,
|
|
8549
8439
|
messages: count,
|
|
@@ -8568,7 +8458,7 @@ var catchUpPreparation = strictObject({
|
|
|
8568
8458
|
prepared: optional(conversationPreparation)
|
|
8569
8459
|
});
|
|
8570
8460
|
|
|
8571
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8461
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/conversation-results.js
|
|
8572
8462
|
var conversationDetails = union([
|
|
8573
8463
|
strictObject({ ...conversation.entries, messages: array(message) }),
|
|
8574
8464
|
message
|
|
@@ -8658,7 +8548,7 @@ var conversationHit = strictObject({
|
|
|
8658
8548
|
stale: boolean()
|
|
8659
8549
|
});
|
|
8660
8550
|
|
|
8661
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8551
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/counters.js
|
|
8662
8552
|
var counters = strictObject({
|
|
8663
8553
|
cutoff: time,
|
|
8664
8554
|
max_age_ms: milliseconds,
|
|
@@ -8688,97 +8578,7 @@ var counterRefresh = strictObject({
|
|
|
8688
8578
|
complete: optional(boolean())
|
|
8689
8579
|
});
|
|
8690
8580
|
|
|
8691
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8692
|
-
var nullableText = nullable(text);
|
|
8693
|
-
var party = strictObject({ ref: reference, name: nullableText, owner: boolean() });
|
|
8694
|
-
var outcome = picklist(["open", "won", "lost"]);
|
|
8695
|
-
var crmAccount = nullable(strictObject({ provider: text, account: text }));
|
|
8696
|
-
var day2 = nullable(pipe(string(), regex(/^\d{4}-\d{2}-\d{2}$/)));
|
|
8697
|
-
var deal = strictObject({
|
|
8698
|
-
id,
|
|
8699
|
-
ref: reference,
|
|
8700
|
-
kind: picklist(["deal", "lead"]),
|
|
8701
|
-
title: text,
|
|
8702
|
-
/** One line with the stage, amount and status. */
|
|
8703
|
-
summary: text,
|
|
8704
|
-
pipeline: reference,
|
|
8705
|
-
pipeline_name: text,
|
|
8706
|
-
stage: text,
|
|
8707
|
-
status: outcome,
|
|
8708
|
-
organization: nullable(party),
|
|
8709
|
-
currency: nullableText,
|
|
8710
|
-
amount: nullableText,
|
|
8711
|
-
close_date: day2,
|
|
8712
|
-
closed_date: day2,
|
|
8713
|
-
closed_reason: nullableText,
|
|
8714
|
-
rank: nullable(number()),
|
|
8715
|
-
/** A lead's deal, once it became one. */
|
|
8716
|
-
deal: nullable(reference),
|
|
8717
|
-
/** The CRM account it is a copy from; `null` for the owner's own. */
|
|
8718
|
-
account: crmAccount,
|
|
8719
|
-
external_id: nullableText,
|
|
8720
|
-
/** A CRM copy's assignee, the identity `<account>/user/<id>`. */
|
|
8721
|
-
assignee: nullableText,
|
|
8722
|
-
/** A CRM copy's own fields by code; a list field's value is its option's label, `option_id` its id. */
|
|
8723
|
-
provider_metadata: record(string(), strictObject({
|
|
8724
|
-
label: nullable(string()),
|
|
8725
|
-
value: unknown(),
|
|
8726
|
-
option_id: optional(union([string(), array(string())]))
|
|
8727
|
-
})),
|
|
8728
|
-
people: array(strictObject({ ...party.entries, role: picklist(DEAL_ROLES) })),
|
|
8729
|
-
author: strictObject({
|
|
8730
|
-
type: picklist(["person", "bot"]),
|
|
8731
|
-
id,
|
|
8732
|
-
name: nullableText,
|
|
8733
|
-
kind: nullable(picklist(["agent", "rule"]))
|
|
8734
|
-
}),
|
|
8735
|
-
model: nullableText,
|
|
8736
|
-
source: text,
|
|
8737
|
-
reason: nullableText,
|
|
8738
|
-
evidence: array(reference),
|
|
8739
|
-
project: nullable(reference),
|
|
8740
|
-
project_name: nullableText,
|
|
8741
|
-
created_at: time,
|
|
8742
|
-
updated_at: time,
|
|
8743
|
-
untrusted
|
|
8744
|
-
});
|
|
8745
|
-
var lead = deal;
|
|
8746
|
-
var pipelineStage = strictObject({
|
|
8747
|
-
name: text,
|
|
8748
|
-
position: count,
|
|
8749
|
-
outcome,
|
|
8750
|
-
external_id: nullableText,
|
|
8751
|
-
/** Open deals or leads in it now. */
|
|
8752
|
-
open: count,
|
|
8753
|
-
/** With a funnel: rows that got this far, and the share of them that reached the next stage. */
|
|
8754
|
-
reached: optional(count),
|
|
8755
|
-
conversion: optional(nullable(number())),
|
|
8756
|
-
/** With a funnel: rows standing in it now, and their sum per currency, never converted. */
|
|
8757
|
-
items: optional(count),
|
|
8758
|
-
amounts: optional(array(strictObject({ amount: text, currency: text, items: count })))
|
|
8759
|
-
});
|
|
8760
|
-
var pipeline = strictObject({
|
|
8761
|
-
id,
|
|
8762
|
-
ref: reference,
|
|
8763
|
-
name: text,
|
|
8764
|
-
kind: picklist(["deal", "lead"]),
|
|
8765
|
-
account: crmAccount,
|
|
8766
|
-
external_id: nullableText,
|
|
8767
|
-
stages: array(pipelineStage),
|
|
8768
|
-
created_at: time,
|
|
8769
|
-
totals: optional(strictObject({ items: count, open: count, won: count, lost: count, win_rate: nullable(number()) })),
|
|
8770
|
-
since: optional(day2),
|
|
8771
|
-
untrusted
|
|
8772
|
-
});
|
|
8773
|
-
var stage = strictObject({
|
|
8774
|
-
...pipelineStage.entries,
|
|
8775
|
-
pipeline: reference,
|
|
8776
|
-
pipeline_name: text,
|
|
8777
|
-
kind: picklist(["deal", "lead"]),
|
|
8778
|
-
untrusted
|
|
8779
|
-
});
|
|
8780
|
-
|
|
8781
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_a1c6dd927639f1a41fe5f9c53e24865e/node_modules/@wirecat/cli-core/dist/entities/document.js
|
|
8581
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/document.js
|
|
8782
8582
|
var document = strictObject({
|
|
8783
8583
|
ref: reference,
|
|
8784
8584
|
id,
|
|
@@ -8793,7 +8593,7 @@ var document = strictObject({
|
|
|
8793
8593
|
owners: optional(array(text))
|
|
8794
8594
|
});
|
|
8795
8595
|
|
|
8796
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8596
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/document-link.js
|
|
8797
8597
|
var documentLink = strictObject({
|
|
8798
8598
|
ref: reference,
|
|
8799
8599
|
url: text,
|
|
@@ -8804,7 +8604,7 @@ var documentLink = strictObject({
|
|
|
8804
8604
|
sender: strictObject({ id: nullable(id), name: nullable(text) })
|
|
8805
8605
|
});
|
|
8806
8606
|
|
|
8807
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8607
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/evidence.js
|
|
8808
8608
|
var evidenceMessage = pick(message, ["ref", "chat_title", "timestamp", "sender_name", "text"]);
|
|
8809
8609
|
var contribution = strictObject({
|
|
8810
8610
|
message: evidenceMessage,
|
|
@@ -8834,7 +8634,7 @@ var retentionStay = strictObject({
|
|
|
8834
8634
|
});
|
|
8835
8635
|
var evidence = union([contribution, retentionStay]);
|
|
8836
8636
|
|
|
8837
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8637
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/fact.js
|
|
8838
8638
|
var fact = strictObject({
|
|
8839
8639
|
ref: reference,
|
|
8840
8640
|
id,
|
|
@@ -8865,7 +8665,7 @@ var fact = strictObject({
|
|
|
8865
8665
|
updated_at: time
|
|
8866
8666
|
});
|
|
8867
8667
|
|
|
8868
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8668
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/hit.js
|
|
8869
8669
|
var hit = strictObject({
|
|
8870
8670
|
kind: picklist(["message", "mail", "note", "document", "event", "meeting", "deal", "lead", ...BUSINESS_KINDS]),
|
|
8871
8671
|
ref: reference,
|
|
@@ -8907,7 +8707,7 @@ var hit = strictObject({
|
|
|
8907
8707
|
untrusted
|
|
8908
8708
|
});
|
|
8909
8709
|
|
|
8910
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8710
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/identity.js
|
|
8911
8711
|
var identity = strictObject({
|
|
8912
8712
|
ref: reference,
|
|
8913
8713
|
provider: text,
|
|
@@ -8920,7 +8720,7 @@ var identity = strictObject({
|
|
|
8920
8720
|
person: optional(nullable(reference))
|
|
8921
8721
|
});
|
|
8922
8722
|
|
|
8923
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8723
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/image-embedding.js
|
|
8924
8724
|
var imageEmbedding = strictObject({
|
|
8925
8725
|
model: text,
|
|
8926
8726
|
embedded: count,
|
|
@@ -8929,13 +8729,13 @@ var imageEmbedding = strictObject({
|
|
|
8929
8729
|
more: boolean()
|
|
8930
8730
|
});
|
|
8931
8731
|
|
|
8932
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8732
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/services/backfill-jobs.js
|
|
8933
8733
|
import { spawn } from "node:child_process";
|
|
8934
|
-
import { randomBytes
|
|
8935
|
-
import { closeSync, existsSync as
|
|
8734
|
+
import { randomBytes } from "node:crypto";
|
|
8735
|
+
import { closeSync, existsSync as existsSync6, mkdirSync as mkdirSync2, openSync, readdirSync as readdirSync3, readFileSync as readFileSync4, realpathSync, rmSync as rmSync2 } from "node:fs";
|
|
8936
8736
|
import { dirname as dirname2, join as join5 } from "node:path";
|
|
8937
8737
|
|
|
8938
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8738
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/background/checkpoints.js
|
|
8939
8739
|
var progressOf = /* @__PURE__ */ __name((input) => {
|
|
8940
8740
|
const total = input.total ?? null;
|
|
8941
8741
|
const updated = input.updatedAt ?? null;
|
|
@@ -8966,7 +8766,7 @@ var progressLine = /* @__PURE__ */ __name((progress2) => {
|
|
|
8966
8766
|
return `${progress2.job} ${progress2.profile}: ${of} \u2014 ${progress2.state}${when}`;
|
|
8967
8767
|
}, "progressLine");
|
|
8968
8768
|
|
|
8969
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8769
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/runs/record-log.js
|
|
8970
8770
|
var recordLogFor = /* @__PURE__ */ __name((to, app, { traceId, command } = {}) => {
|
|
8971
8771
|
const run = currentRun();
|
|
8972
8772
|
const trace = traceId ?? run.traceId;
|
|
@@ -8980,7 +8780,7 @@ var recordLogFor = /* @__PURE__ */ __name((to, app, { traceId, command } = {}) =
|
|
|
8980
8780
|
}));
|
|
8981
8781
|
}, "recordLogFor");
|
|
8982
8782
|
|
|
8983
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8783
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/services/backfill-jobs.js
|
|
8984
8784
|
var JOB_STATES = ["running", "done", "partial", "failed", "cancelled", "died"];
|
|
8985
8785
|
var spawnDetached = /* @__PURE__ */ __name((argv, env, log) => {
|
|
8986
8786
|
const out = openSync(log, "a", 384);
|
|
@@ -8999,15 +8799,15 @@ var spawnDetached = /* @__PURE__ */ __name((argv, env, log) => {
|
|
|
8999
8799
|
var jobsDir = /* @__PURE__ */ __name((app, env) => join5(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "backfill"), "jobsDir");
|
|
9000
8800
|
var jobPath = /* @__PURE__ */ __name((dir, id6) => join5(dir, `${id6}.json`), "jobPath");
|
|
9001
8801
|
var saveJob = /* @__PURE__ */ __name((dir, job2) => {
|
|
9002
|
-
|
|
8802
|
+
mkdirSync2(dir, { recursive: true, mode: 448 });
|
|
9003
8803
|
writeSecurely(jobPath(dir, job2.id), `${JSON.stringify(job2, null, 2)}
|
|
9004
8804
|
`, 384);
|
|
9005
8805
|
}, "saveJob");
|
|
9006
8806
|
var readJob = /* @__PURE__ */ __name((dir, id6) => {
|
|
9007
|
-
if (!/^[\w-]+$/.test(id6) || !
|
|
8807
|
+
if (!/^[\w-]+$/.test(id6) || !existsSync6(jobPath(dir, id6)))
|
|
9008
8808
|
return void 0;
|
|
9009
8809
|
try {
|
|
9010
|
-
return JSON.parse(
|
|
8810
|
+
return JSON.parse(readFileSync4(jobPath(dir, id6), "utf8"));
|
|
9011
8811
|
} catch {
|
|
9012
8812
|
return void 0;
|
|
9013
8813
|
}
|
|
@@ -9044,12 +8844,12 @@ var updateJob = /* @__PURE__ */ __name((dir, id6, change) => {
|
|
|
9044
8844
|
saveJob(dir, { ...job2, ...change });
|
|
9045
8845
|
}, "updateJob");
|
|
9046
8846
|
var removeJob = /* @__PURE__ */ __name((dir, job2) => {
|
|
9047
|
-
|
|
9048
|
-
|
|
8847
|
+
rmSync2(jobPath(dir, job2.id), { force: true });
|
|
8848
|
+
rmSync2(recordsPath(dir, job2.id), { force: true });
|
|
9049
8849
|
if (dirname2(job2.log) === dir)
|
|
9050
|
-
|
|
8850
|
+
rmSync2(job2.log, { force: true });
|
|
9051
8851
|
}, "removeJob");
|
|
9052
|
-
var listJobs = /* @__PURE__ */ __name((dir) =>
|
|
8852
|
+
var listJobs = /* @__PURE__ */ __name((dir) => existsSync6(dir) ? readdirSync3(dir).filter((name) => name.endsWith(".json")).flatMap((name) => readJob(dir, name.slice(0, -".json".length)) ?? []).sort((a, b) => b.startedAt.localeCompare(a.startedAt)) : [], "listJobs");
|
|
9053
8853
|
var jobDetails = /* @__PURE__ */ __name((job2) => ({
|
|
9054
8854
|
job: job2.id,
|
|
9055
8855
|
profile: job2.profile,
|
|
@@ -9113,8 +8913,8 @@ var startArchiveJob = /* @__PURE__ */ __name((app, env, profile, input, spawnJob
|
|
|
9113
8913
|
if (running)
|
|
9114
8914
|
throw new CliError("validation_error", `job ${running.id} already works on this chat; inspect store jobs show first`);
|
|
9115
8915
|
const startedAt = (/* @__PURE__ */ new Date()).toISOString();
|
|
9116
|
-
const id6 = `${startedAt.replace(/[-:]/g, "").slice(0, 15)}-${
|
|
9117
|
-
|
|
8916
|
+
const id6 = `${startedAt.replace(/[-:]/g, "").slice(0, 15)}-${randomBytes(3).toString("hex")}`;
|
|
8917
|
+
mkdirSync2(dir, { recursive: true, mode: 448 });
|
|
9118
8918
|
const log = join5(dir, `${id6}.log`);
|
|
9119
8919
|
const job2 = {
|
|
9120
8920
|
id: id6,
|
|
@@ -9135,7 +8935,7 @@ var startArchiveJob = /* @__PURE__ */ __name((app, env, profile, input, spawnJob
|
|
|
9135
8935
|
return { job: id6, pid, chat: input.chat, log };
|
|
9136
8936
|
}, "startArchiveJob");
|
|
9137
8937
|
|
|
9138
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8938
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/job.js
|
|
9139
8939
|
var problem = strictObject({ code: text, message: text });
|
|
9140
8940
|
var job = strictObject({
|
|
9141
8941
|
id,
|
|
@@ -9158,7 +8958,7 @@ var job = strictObject({
|
|
|
9158
8958
|
error: optional(problem)
|
|
9159
8959
|
});
|
|
9160
8960
|
|
|
9161
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8961
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/join-request.js
|
|
9162
8962
|
var joinRequest = strictObject({
|
|
9163
8963
|
person_id: id,
|
|
9164
8964
|
name: nullable(text),
|
|
@@ -9169,7 +8969,7 @@ var joinRequest = strictObject({
|
|
|
9169
8969
|
about: optional(text)
|
|
9170
8970
|
});
|
|
9171
8971
|
|
|
9172
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8972
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/list-results.js
|
|
9173
8973
|
var botProfile = strictObject({
|
|
9174
8974
|
name: text,
|
|
9175
8975
|
token: text,
|
|
@@ -9264,7 +9064,7 @@ var stickerInventory = strictObject({
|
|
|
9264
9064
|
url: optional(nullable(text))
|
|
9265
9065
|
});
|
|
9266
9066
|
|
|
9267
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9067
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/poll-vote.js
|
|
9268
9068
|
var pollVote = strictObject({
|
|
9269
9069
|
person_id: id,
|
|
9270
9070
|
name: nullable(text),
|
|
@@ -9274,7 +9074,7 @@ var pollVote = strictObject({
|
|
|
9274
9074
|
voted_at: time
|
|
9275
9075
|
});
|
|
9276
9076
|
|
|
9277
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9077
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/listener.js
|
|
9278
9078
|
var reactions = unwrap(unwrap(message.entries.reactions));
|
|
9279
9079
|
var observation = strictObject({
|
|
9280
9080
|
value: pipe(number(), minValue(0)),
|
|
@@ -9316,7 +9116,7 @@ var serveSummary = strictObject({
|
|
|
9316
9116
|
tasks: optional(strictObject({ added: count, closed: count, review: count }))
|
|
9317
9117
|
});
|
|
9318
9118
|
|
|
9319
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9119
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/mail-counts.js
|
|
9320
9120
|
var mailCounts = strictObject({
|
|
9321
9121
|
by: picklist(["day", "week", "sender"]),
|
|
9322
9122
|
received: count,
|
|
@@ -9331,7 +9131,7 @@ var mailCounts = strictObject({
|
|
|
9331
9131
|
}))
|
|
9332
9132
|
});
|
|
9333
9133
|
|
|
9334
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9134
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/mail-findings.js
|
|
9335
9135
|
var evidence2 = strictObject({ reference, fingerprint: text });
|
|
9336
9136
|
var base = { id, evidence: array(evidence2) };
|
|
9337
9137
|
var finding = variant("kind", [
|
|
@@ -9475,7 +9275,7 @@ var mailFindings = strictObject({
|
|
|
9475
9275
|
receipt: nullable(strictObject({ preview_fingerprint: text, accepted: array(id), items: array(outcome2) }))
|
|
9476
9276
|
});
|
|
9477
9277
|
|
|
9478
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9278
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/media-archive.js
|
|
9479
9279
|
var mediaArchive = strictObject({
|
|
9480
9280
|
directory: text,
|
|
9481
9281
|
chats: count,
|
|
@@ -9507,7 +9307,7 @@ var mediaArchiveTimer = union([
|
|
|
9507
9307
|
strictObject({ ...timer, action: picklist(["install", "start", "stop", "uninstall"]) })
|
|
9508
9308
|
]);
|
|
9509
9309
|
|
|
9510
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9310
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-preparation-parts.js
|
|
9511
9311
|
var preparationId = pipe(string(), minLength(1));
|
|
9512
9312
|
var preparationCount = pipe(number(), integer(), minValue(0));
|
|
9513
9313
|
var preparationTime = nullable(isoTime);
|
|
@@ -9599,7 +9399,7 @@ var preparationMeeting = strictObject({
|
|
|
9599
9399
|
updated_at: isoTime
|
|
9600
9400
|
});
|
|
9601
9401
|
|
|
9602
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9402
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-evidence.js
|
|
9603
9403
|
var meetingEvidence = preparationEvidence;
|
|
9604
9404
|
var meetingPersonContext = strictObject({
|
|
9605
9405
|
person: strictObject({ uid: string(), name: nullable(string()) }),
|
|
@@ -9621,7 +9421,7 @@ var meetingPersonContext = strictObject({
|
|
|
9621
9421
|
})
|
|
9622
9422
|
});
|
|
9623
9423
|
|
|
9624
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9424
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-findings.js
|
|
9625
9425
|
var evidence3 = strictObject({ reference, fingerprint: text });
|
|
9626
9426
|
var base2 = { id, project: reference, evidence: array(evidence3) };
|
|
9627
9427
|
var finding2 = variant("kind", [
|
|
@@ -9659,7 +9459,7 @@ var meetingFindings = strictObject({
|
|
|
9659
9459
|
receipt: nullable(strictObject({ preview_fingerprint: text, accepted: array(id), items: array(outcome3) }))
|
|
9660
9460
|
});
|
|
9661
9461
|
|
|
9662
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9462
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-communications.js
|
|
9663
9463
|
var communicationCoverage = strictObject({
|
|
9664
9464
|
read_usage: strictObject({ reads: preparationCount, charged_bytes: preparationCount, reserved_bytes: preparationCount, remaining_bytes: preparationCount }),
|
|
9665
9465
|
query: string(),
|
|
@@ -9704,7 +9504,7 @@ var preparationCommunications = strictObject({
|
|
|
9704
9504
|
}))
|
|
9705
9505
|
});
|
|
9706
9506
|
|
|
9707
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9507
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-preparation.js
|
|
9708
9508
|
var meetingPreparation = strictObject({
|
|
9709
9509
|
communications: optional(preparationCommunications),
|
|
9710
9510
|
schema_version: literal(1),
|
|
@@ -9817,7 +9617,7 @@ var meetingPreparation = strictObject({
|
|
|
9817
9617
|
})
|
|
9818
9618
|
});
|
|
9819
9619
|
|
|
9820
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9620
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-project-candidates.js
|
|
9821
9621
|
var count4 = pipe(number(), integer(), minValue(0));
|
|
9822
9622
|
var id3 = pipe(string(), minLength(1));
|
|
9823
9623
|
var text3 = string();
|
|
@@ -9881,7 +9681,7 @@ var meetingProjectCandidates = strictObject({
|
|
|
9881
9681
|
})
|
|
9882
9682
|
});
|
|
9883
9683
|
|
|
9884
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9684
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-series-inventory.js
|
|
9885
9685
|
var count5 = pipe(number(), integer(), minValue(0));
|
|
9886
9686
|
var id4 = pipe(string(), minLength(1), maxLength(1e3));
|
|
9887
9687
|
var meetingSeriesInventory = strictObject({
|
|
@@ -9911,7 +9711,7 @@ var meetingSeriesInventory = strictObject({
|
|
|
9911
9711
|
})
|
|
9912
9712
|
});
|
|
9913
9713
|
|
|
9914
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9714
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/meeting-task-proposal.js
|
|
9915
9715
|
var text4 = string();
|
|
9916
9716
|
var id5 = pipe(number(), integer(), minValue(1));
|
|
9917
9717
|
var revision = picklist(["current", "superseded"]);
|
|
@@ -9928,7 +9728,7 @@ var meetingTaskProposal = strictObject({
|
|
|
9928
9728
|
persistence: literal("proposal-only")
|
|
9929
9729
|
});
|
|
9930
9730
|
|
|
9931
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9731
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/memory.js
|
|
9932
9732
|
var memory = strictObject({
|
|
9933
9733
|
ref: reference,
|
|
9934
9734
|
id,
|
|
@@ -9956,9 +9756,9 @@ var memory = strictObject({
|
|
|
9956
9756
|
updated_at: time
|
|
9957
9757
|
});
|
|
9958
9758
|
|
|
9959
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9759
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/mention.js
|
|
9960
9760
|
var kind = picklist(["phone", "email", "url", "document", "person-name", "place"]);
|
|
9961
|
-
var status = picklist(["found", "linked", "dismissed"]);
|
|
9761
|
+
var status = picklist(["found", "linked", "proposed", "dismissed"]);
|
|
9962
9762
|
var mention = strictObject({
|
|
9963
9763
|
id: count,
|
|
9964
9764
|
kind,
|
|
@@ -9988,7 +9788,8 @@ var mentionDecision = strictObject({
|
|
|
9988
9788
|
value: text,
|
|
9989
9789
|
status,
|
|
9990
9790
|
target: nullable(reference),
|
|
9991
|
-
mentions: count
|
|
9791
|
+
mentions: count,
|
|
9792
|
+
proposal: optional(text)
|
|
9992
9793
|
});
|
|
9993
9794
|
var mentionRebuild = strictObject({
|
|
9994
9795
|
messages: count,
|
|
@@ -9999,13 +9800,13 @@ var mentionRebuild = strictObject({
|
|
|
9999
9800
|
mentions: count
|
|
10000
9801
|
});
|
|
10001
9802
|
|
|
10002
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9803
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-change.js
|
|
10003
9804
|
var operated3 = { operation_id: id, chat_id: id };
|
|
10004
9805
|
var messagePin = strictObject({ ...operated3, message_id: id, pinned: boolean() });
|
|
10005
9806
|
var messageStar = strictObject({ ...operated3, message_id: id, starred: boolean() });
|
|
10006
9807
|
var messageDeletion = strictObject({ ...operated3, deleted: array(id), for_everyone: boolean() });
|
|
10007
9808
|
|
|
10008
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9809
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-read.js
|
|
10009
9810
|
var messageTranscript = strictObject({
|
|
10010
9811
|
message_id: id,
|
|
10011
9812
|
text,
|
|
@@ -10063,7 +9864,7 @@ var evidencePacket = strictObject({
|
|
|
10063
9864
|
}))
|
|
10064
9865
|
});
|
|
10065
9866
|
|
|
10066
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9867
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-context.js
|
|
10067
9868
|
var messageThread = strictObject({
|
|
10068
9869
|
ref: reference,
|
|
10069
9870
|
chat: id,
|
|
@@ -10080,7 +9881,7 @@ var messageThread = strictObject({
|
|
|
10080
9881
|
});
|
|
10081
9882
|
var messageContext = union([message, messageThread]);
|
|
10082
9883
|
|
|
10083
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9884
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-counts.js
|
|
10084
9885
|
var messageCounts = strictObject({
|
|
10085
9886
|
by: picklist(["chat", "sender", "day", "hour"]),
|
|
10086
9887
|
total: count,
|
|
@@ -10093,7 +9894,7 @@ var messageCounts = strictObject({
|
|
|
10093
9894
|
}))
|
|
10094
9895
|
});
|
|
10095
9896
|
|
|
10096
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9897
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-link.js
|
|
10097
9898
|
var messageLink = strictObject({
|
|
10098
9899
|
ref: reference,
|
|
10099
9900
|
url: nullable(text),
|
|
@@ -10110,7 +9911,7 @@ var messageLink = strictObject({
|
|
|
10110
9911
|
})))
|
|
10111
9912
|
});
|
|
10112
9913
|
|
|
10113
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
9914
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-transfer.js
|
|
10114
9915
|
var savedMessageFile = strictObject({
|
|
10115
9916
|
kind: text,
|
|
10116
9917
|
path: text,
|
|
@@ -10190,14 +9991,14 @@ var messageSyncAll = strictObject({
|
|
|
10190
9991
|
issue: optional(actionableError),
|
|
10191
9992
|
limited: optional(historyLimited)
|
|
10192
9993
|
})),
|
|
10193
|
-
/** How many chats the history limits left unread (big groups) or read only to the window's start. */
|
|
10194
|
-
limited: optional(strictObject({ group_too_large: count, older_than_window: count })),
|
|
9994
|
+
/** How many chats the history limits left unread (big groups) or read only to the window's start; muted, unread. */
|
|
9995
|
+
limited: optional(strictObject({ group_too_large: count, older_than_window: count, muted: optional(count) })),
|
|
10195
9996
|
tasks
|
|
10196
9997
|
});
|
|
10197
9998
|
var messageSyncStarted = strictObject({ job: id, pid: count, chat: text, log: text });
|
|
10198
9999
|
var messageSync = union([messageSyncEstimate, messageSyncChat, messageSyncAll, messageSyncStarted]);
|
|
10199
10000
|
|
|
10200
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10001
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/message-write.js
|
|
10201
10002
|
var messageWrite = strictObject({
|
|
10202
10003
|
operation_id: id,
|
|
10203
10004
|
message,
|
|
@@ -10212,7 +10013,7 @@ var draftWrite = strictObject({
|
|
|
10212
10013
|
});
|
|
10213
10014
|
var messageSend = union([messageWrite, draftWrite]);
|
|
10214
10015
|
|
|
10215
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10016
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/model.js
|
|
10216
10017
|
var model2 = strictObject({
|
|
10217
10018
|
id,
|
|
10218
10019
|
kind: picklist(["audio", "text", "image", "reranker"]),
|
|
@@ -10220,7 +10021,7 @@ var model2 = strictObject({
|
|
|
10220
10021
|
/** Which languages it reads, in words. */
|
|
10221
10022
|
languages: text,
|
|
10222
10023
|
licence: optional(text),
|
|
10223
|
-
/** A text model's licence
|
|
10024
|
+
/** A text model's licence page, for a model under conditions of its own (`NOTICE` beside its files says the same). */
|
|
10224
10025
|
terms: optional(text),
|
|
10225
10026
|
/** A text model's size next to the others: small is fastest, large reads best. */
|
|
10226
10027
|
size: optional(picklist(["small", "medium", "large"])),
|
|
@@ -10247,7 +10048,7 @@ var chosenModel = strictObject({
|
|
|
10247
10048
|
estimate_seconds: nullable(count)
|
|
10248
10049
|
});
|
|
10249
10050
|
|
|
10250
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10051
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/model-key.js
|
|
10251
10052
|
var source = picklist(["environment", "keyring", "file"]);
|
|
10252
10053
|
var modelKey = strictObject({
|
|
10253
10054
|
provider: text,
|
|
@@ -10257,7 +10058,7 @@ var modelKey = strictObject({
|
|
|
10257
10058
|
var storedModelKey = strictObject({ ...omit(modelKey, ["removed"]).entries, stored: source });
|
|
10258
10059
|
var removedModelKey = strictObject({ ...omit(modelKey, ["stored"]).entries, removed: array(source) });
|
|
10259
10060
|
|
|
10260
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10061
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/note.js
|
|
10261
10062
|
var link = {
|
|
10262
10063
|
target_text: nullable(text),
|
|
10263
10064
|
kind: text,
|
|
@@ -10298,7 +10099,7 @@ var note = strictObject({
|
|
|
10298
10099
|
backlinks: optional(array(strictObject({ from: reference, ...link })))
|
|
10299
10100
|
});
|
|
10300
10101
|
|
|
10301
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10102
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/official-stats.js
|
|
10302
10103
|
var versus = strictObject({ current: number(), previous: number() });
|
|
10303
10104
|
var person = { person_ref: reference, name: nullable(text) };
|
|
10304
10105
|
var graph = strictObject({
|
|
@@ -10332,14 +10133,14 @@ var officialStats = strictObject({
|
|
|
10332
10133
|
graphs: record(string(), union([graph, strictObject({ error: text })]))
|
|
10333
10134
|
});
|
|
10334
10135
|
|
|
10335
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10136
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/person.js
|
|
10336
10137
|
var person2 = strictObject({
|
|
10337
10138
|
ref: reference,
|
|
10338
10139
|
name: nullable(text),
|
|
10339
10140
|
identities: optional(array(identity))
|
|
10340
10141
|
});
|
|
10341
10142
|
|
|
10342
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10143
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/poll.js
|
|
10343
10144
|
var poll = strictObject({
|
|
10344
10145
|
chat_id: id,
|
|
10345
10146
|
message_id: id,
|
|
@@ -10355,11 +10156,11 @@ var poll = strictObject({
|
|
|
10355
10156
|
});
|
|
10356
10157
|
var pollChange = strictObject({ operation_id: id, poll });
|
|
10357
10158
|
|
|
10358
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10159
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/private-contact.js
|
|
10359
10160
|
var contactAlias = strictObject({ person_id: id, alias: nullable(text) });
|
|
10360
10161
|
var contactNoteRemoval = strictObject({ id, person_id: id, removed: boolean() });
|
|
10361
10162
|
|
|
10362
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10163
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/ranking.js
|
|
10363
10164
|
var figures = record(string(), number());
|
|
10364
10165
|
var freshness = picklist(["fresh", "stale", "partial", "unknown"]);
|
|
10365
10166
|
var rankingRow = strictObject({
|
|
@@ -10406,7 +10207,7 @@ var ranking = strictObject({
|
|
|
10406
10207
|
rows: array(rankingRow)
|
|
10407
10208
|
});
|
|
10408
10209
|
|
|
10409
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10210
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/reaction.js
|
|
10410
10211
|
var reaction = strictObject({
|
|
10411
10212
|
person: strictObject({ id, name: nullable(text), username: nullable(text) }),
|
|
10412
10213
|
/** The emoji, or `custom:<id>` for a custom one. */
|
|
@@ -10414,7 +10215,7 @@ var reaction = strictObject({
|
|
|
10414
10215
|
reacted_at: time
|
|
10415
10216
|
});
|
|
10416
10217
|
|
|
10417
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10218
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/reaction-change.js
|
|
10418
10219
|
var reactionChange = strictObject({
|
|
10419
10220
|
operation_id: id,
|
|
10420
10221
|
chat_id: id,
|
|
@@ -10422,7 +10223,7 @@ var reactionChange = strictObject({
|
|
|
10422
10223
|
reaction: nullable(text)
|
|
10423
10224
|
});
|
|
10424
10225
|
|
|
10425
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10226
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/recipient.js
|
|
10426
10227
|
var recipient = strictObject({ id, title: nullable(text), partner_id: optional(id), added_at: time });
|
|
10427
10228
|
var recipientAdded = strictObject({ id, title: nullable(text), added: boolean() });
|
|
10428
10229
|
var recipientRemoved = strictObject({ id, title: nullable(text), removed: boolean() });
|
|
@@ -10433,7 +10234,7 @@ var recipientChange = strictObject({
|
|
|
10433
10234
|
...partial(recipientOff).entries
|
|
10434
10235
|
});
|
|
10435
10236
|
|
|
10436
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10237
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/recorded-run.js
|
|
10437
10238
|
var events = array(record(string(), unknown()));
|
|
10438
10239
|
var recordedRun = strictObject({
|
|
10439
10240
|
run_id: id,
|
|
@@ -10505,7 +10306,7 @@ var runHit = strictObject({
|
|
|
10505
10306
|
});
|
|
10506
10307
|
var runLocation = strictObject({ path: text });
|
|
10507
10308
|
|
|
10508
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10309
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/relationship.js
|
|
10509
10310
|
var relationship = strictObject({
|
|
10510
10311
|
id,
|
|
10511
10312
|
from: reference,
|
|
@@ -10525,10 +10326,14 @@ var relationship = strictObject({
|
|
|
10525
10326
|
position: nullable(text),
|
|
10526
10327
|
starts_at: nullable(time),
|
|
10527
10328
|
ends_at: nullable(time),
|
|
10329
|
+
/** The source account that reported it, `<provider>:<account>`. */
|
|
10330
|
+
account: optional(text),
|
|
10331
|
+
/** How a source made it when it stated none, such as `department-head`. */
|
|
10332
|
+
derived: optional(text),
|
|
10528
10333
|
created_at: time
|
|
10529
10334
|
});
|
|
10530
10335
|
|
|
10531
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10336
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/reply-stats.js
|
|
10532
10337
|
var milliseconds2 = nullable(pipe(number(), minValue(0)));
|
|
10533
10338
|
var figures2 = { replies: count, median_ms: milliseconds2, p90_ms: milliseconds2, mean_ms: milliseconds2 };
|
|
10534
10339
|
var responseTimes = strictObject({
|
|
@@ -10545,7 +10350,7 @@ var waitingChats = strictObject({
|
|
|
10545
10350
|
by_kind: strictObject({ private: count, group: count })
|
|
10546
10351
|
});
|
|
10547
10352
|
|
|
10548
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10353
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/retention.js
|
|
10549
10354
|
var retentionCohort = strictObject({
|
|
10550
10355
|
/** The first day of the joining day or week. */
|
|
10551
10356
|
cohort: text,
|
|
@@ -10593,7 +10398,7 @@ var retention = strictObject({
|
|
|
10593
10398
|
rows: array(retentionCohort)
|
|
10594
10399
|
});
|
|
10595
10400
|
|
|
10596
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10401
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/saved-search.js
|
|
10597
10402
|
var savedSearch = strictObject({
|
|
10598
10403
|
id,
|
|
10599
10404
|
/** `null` for a run in the history. */
|
|
@@ -10610,7 +10415,7 @@ var savedSearch = strictObject({
|
|
|
10610
10415
|
});
|
|
10611
10416
|
var searchHistoryClear = strictObject({ cleared: count });
|
|
10612
10417
|
|
|
10613
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10418
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/send-attempt.js
|
|
10614
10419
|
var sendAttempt = strictObject({
|
|
10615
10420
|
at: time,
|
|
10616
10421
|
profile: text,
|
|
@@ -10638,7 +10443,7 @@ var sendAttempt = strictObject({
|
|
|
10638
10443
|
error_code: optional(text)
|
|
10639
10444
|
});
|
|
10640
10445
|
|
|
10641
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10446
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/store-maintenance.js
|
|
10642
10447
|
var absent = strictObject({ path: text, exists: literal(false) });
|
|
10643
10448
|
var schema = strictObject({ version: count, min_compatible: count, writable: boolean(), speaks: count });
|
|
10644
10449
|
var infoSchema = strictObject({
|
|
@@ -10859,7 +10664,7 @@ var storeRepair = union([
|
|
|
10859
10664
|
]);
|
|
10860
10665
|
var storeCopyRemoval = strictObject({ path: text, deleted: strictObject({ name: text, rows: count }) });
|
|
10861
10666
|
|
|
10862
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10667
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/store-records.js
|
|
10863
10668
|
var range = strictObject({ from: number(), to: number() });
|
|
10864
10669
|
var storeChatStatus = strictObject({
|
|
10865
10670
|
chat_id: id,
|
|
@@ -10957,7 +10762,7 @@ var storeJobRetry = union([
|
|
|
10957
10762
|
]);
|
|
10958
10763
|
var storeJobClear = strictObject({ cleared: array(id) });
|
|
10959
10764
|
|
|
10960
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10765
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/store-table.js
|
|
10961
10766
|
var TABLE_KINDS = ["data", "search_index", "search_index_part", "internal"];
|
|
10962
10767
|
var storeTable = strictObject({
|
|
10963
10768
|
name: text,
|
|
@@ -10966,7 +10771,7 @@ var storeTable = strictObject({
|
|
|
10966
10771
|
bytes: optional(nullable(count))
|
|
10967
10772
|
});
|
|
10968
10773
|
|
|
10969
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10774
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/tag-change.js
|
|
10970
10775
|
var tagTarget = variant("type", [
|
|
10971
10776
|
strictObject({ type: literal("chat"), chat_id: id }),
|
|
10972
10777
|
strictObject({ type: literal("contact"), person_id: id }),
|
|
@@ -10997,7 +10802,7 @@ var automaticTags = strictObject({
|
|
|
10997
10802
|
dry_run: boolean()
|
|
10998
10803
|
});
|
|
10999
10804
|
|
|
11000
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10805
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/tagging.js
|
|
11001
10806
|
var tagging = strictObject({
|
|
11002
10807
|
tag: text,
|
|
11003
10808
|
type: picklist(TAG_TYPES),
|
|
@@ -11010,7 +10815,7 @@ var tagging = strictObject({
|
|
|
11010
10815
|
created_at: time
|
|
11011
10816
|
});
|
|
11012
10817
|
|
|
11013
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10818
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/task-pair.js
|
|
11014
10819
|
var side = strictObject({ ref: reference, key: text, title: text, status: text });
|
|
11015
10820
|
var taskPair = strictObject({
|
|
11016
10821
|
task: nullable(side),
|
|
@@ -11033,7 +10838,7 @@ var taskPair = strictObject({
|
|
|
11033
10838
|
created_at: time
|
|
11034
10839
|
});
|
|
11035
10840
|
|
|
11036
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10841
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/task-results.js
|
|
11037
10842
|
var nullableTime = nullable(time);
|
|
11038
10843
|
var link2 = strictObject({
|
|
11039
10844
|
id,
|
|
@@ -11207,7 +11012,7 @@ var taskReview = strictObject({
|
|
|
11207
11012
|
untrusted
|
|
11208
11013
|
});
|
|
11209
11014
|
|
|
11210
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11015
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/template.js
|
|
11211
11016
|
var template = strictObject({
|
|
11212
11017
|
key: text,
|
|
11213
11018
|
channel: picklist(["telegram", "email", "text"]),
|
|
@@ -11219,7 +11024,7 @@ var template = strictObject({
|
|
|
11219
11024
|
updated_by: nullable(text)
|
|
11220
11025
|
});
|
|
11221
11026
|
|
|
11222
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11027
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/topic.js
|
|
11223
11028
|
var topic = strictObject({
|
|
11224
11029
|
id,
|
|
11225
11030
|
title: text,
|
|
@@ -11233,7 +11038,7 @@ var topic = strictObject({
|
|
|
11233
11038
|
untrusted
|
|
11234
11039
|
});
|
|
11235
11040
|
|
|
11236
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11041
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/entities/index.js
|
|
11237
11042
|
var ENTITIES = {
|
|
11238
11043
|
sync_progress: progress,
|
|
11239
11044
|
deal,
|
|
@@ -11305,6 +11110,10 @@ var ENTITIES = {
|
|
|
11305
11110
|
identity,
|
|
11306
11111
|
contact_context: contactContext,
|
|
11307
11112
|
contact_preparation: contactPreparation,
|
|
11113
|
+
person_context: personContext,
|
|
11114
|
+
organization_context: organizationContext,
|
|
11115
|
+
deal_context: dealContext,
|
|
11116
|
+
"deal_context.brief": dealBrief,
|
|
11308
11117
|
contact_activity: contactActivity,
|
|
11309
11118
|
contact_check: contactCheck,
|
|
11310
11119
|
linked_person: linkedPerson,
|
|
@@ -11518,11 +11327,11 @@ var ENTITIES = {
|
|
|
11518
11327
|
template
|
|
11519
11328
|
};
|
|
11520
11329
|
var entityDefinitions = /* @__PURE__ */ __name(() => Object.fromEntries(Object.entries(ENTITIES).map(([name, schema2]) => {
|
|
11521
|
-
const { $schema:
|
|
11330
|
+
const { $schema: _2, ...definition } = jsonSchemaOf(schema2);
|
|
11522
11331
|
return [name, definition];
|
|
11523
11332
|
})), "entityDefinitions");
|
|
11524
11333
|
|
|
11525
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11334
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/answer-entity.js
|
|
11526
11335
|
var schemas = /* @__PURE__ */ new WeakMap();
|
|
11527
11336
|
var answerEntity = /* @__PURE__ */ __name((command, name, schema2, options = {}) => {
|
|
11528
11337
|
if (Object.hasOwn(ENTITIES, name))
|
|
@@ -11556,7 +11365,7 @@ var answerRow = /* @__PURE__ */ __name((command) => {
|
|
|
11556
11365
|
return own && metaOf(command).output?.entity === own.name ? own.row : void 0;
|
|
11557
11366
|
}, "answerRow");
|
|
11558
11367
|
|
|
11559
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11368
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/images/picture/models.js
|
|
11560
11369
|
import { join as join6 } from "node:path";
|
|
11561
11370
|
var clip = /* @__PURE__ */ __name((name) => `https://huggingface.co/Xenova/clip-vit-base-patch32/resolve/d15189d7028b43f1d3e65039190477f6af591c2a/${name}`, "clip");
|
|
11562
11371
|
var IMAGE_MODELS = [
|
|
@@ -11610,7 +11419,7 @@ var imageModelsDirectory = /* @__PURE__ */ __name((env = process.env) => sharedM
|
|
|
11610
11419
|
var placedImage = /* @__PURE__ */ __name((model3, directory) => model3.files.map((file) => [file, join6(directory, model3.id, file.name)]), "placedImage");
|
|
11611
11420
|
var isImageModelInstalled = /* @__PURE__ */ __name((model3, directory) => filesPresent(placedImage(model3, directory)), "isImageModelInstalled");
|
|
11612
11421
|
|
|
11613
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11422
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/steps.js
|
|
11614
11423
|
var STEPS2 = defineSteps([
|
|
11615
11424
|
...STEPS,
|
|
11616
11425
|
{
|
|
@@ -11888,7 +11697,7 @@ var stepLine = /* @__PURE__ */ __name((root, step2) => {
|
|
|
11888
11697
|
].join(" ");
|
|
11889
11698
|
}, "stepLine");
|
|
11890
11699
|
|
|
11891
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11700
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/project-status-rows.js
|
|
11892
11701
|
var where = [{ field: "ref" }];
|
|
11893
11702
|
var who2 = { field: ["who.owner", "who.name"], tag: "you" };
|
|
11894
11703
|
var ON_CHAT_ROW = /* @__PURE__ */ new Set(["reply-next", "coverage"]);
|
|
@@ -11980,7 +11789,7 @@ var STATUS_ROWS = {
|
|
|
11980
11789
|
"status.failed": { columns: [{ field: "signal" }], text: ["why"] }
|
|
11981
11790
|
};
|
|
11982
11791
|
|
|
11983
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
11792
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/compact.js
|
|
11984
11793
|
var TEXT_CHARS = 400;
|
|
11985
11794
|
var sender = { field: ["sender_is_me", "sender_name"], tag: "me" };
|
|
11986
11795
|
var messageRow = {
|
|
@@ -12222,8 +12031,8 @@ var dayColumn = /* @__PURE__ */ __name((rows2, shape, hoisted) => {
|
|
|
12222
12031
|
const dates = rows2.map(({ cells }) => cells[index]?.date);
|
|
12223
12032
|
if (dates.some((one) => one === void 0))
|
|
12224
12033
|
return -1;
|
|
12225
|
-
const
|
|
12226
|
-
return ordered(
|
|
12034
|
+
const days = dates;
|
|
12035
|
+
return ordered(days) && new Set(days).size * 3 <= days.length ? index : -1;
|
|
12227
12036
|
}, "dayColumn");
|
|
12228
12037
|
var rowsOfItems = /* @__PURE__ */ __name((items, shape, clock, chars) => {
|
|
12229
12038
|
const dates = [];
|
|
@@ -12239,7 +12048,7 @@ var rowsOfItems = /* @__PURE__ */ __name((items, shape, clock, chars) => {
|
|
|
12239
12048
|
const firstColumn = shape.columns[0];
|
|
12240
12049
|
const refs = rows2.map(({ item }) => item && firstColumn ? firstSet(item, firstColumn.field) : void 0);
|
|
12241
12050
|
const prefix = sharedPrefix(refs.map((ref) => typeof ref === "string" ? ref : void 0));
|
|
12242
|
-
const hoisted = rows2.length < 2 ? [] : shape.columns.map((
|
|
12051
|
+
const hoisted = rows2.length < 2 ? [] : shape.columns.map((_2, index) => index > 0 && sameEverywhere(rows2, index));
|
|
12243
12052
|
const named3 = hoisted.flatMap((hoist, index) => {
|
|
12244
12053
|
const column = shape.columns[index];
|
|
12245
12054
|
const item = rows2[0]?.item;
|
|
@@ -12346,11 +12155,11 @@ var compactText = /* @__PURE__ */ __name((body, shape, options, rowsOf = rowsOfE
|
|
|
12346
12155
|
return lines.concat(footerOf(body)).join("\n");
|
|
12347
12156
|
}, "compactText");
|
|
12348
12157
|
|
|
12349
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
12158
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/output-budget.js
|
|
12350
12159
|
var SOFT_OUTPUT_BYTES = 256 * 1024;
|
|
12351
12160
|
var CARRIED = ["json", "compact", "offline", "timeout", "full", "brief", "maxOutputBytes"];
|
|
12352
12161
|
var NOT_WITH_COMPACT = /* @__PURE__ */ new Set(["json", "brief"]);
|
|
12353
|
-
var
|
|
12162
|
+
var snake2 = /* @__PURE__ */ __name((name) => name.replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`), "snake");
|
|
12354
12163
|
var typed = /* @__PURE__ */ __name((command, key) => command.getOptionValueSource(key) === "cli", "typed");
|
|
12355
12164
|
var typedArgs = /* @__PURE__ */ __name((command) => {
|
|
12356
12165
|
const root = rootOf2(command);
|
|
@@ -12363,8 +12172,8 @@ var typedArgs = /* @__PURE__ */ __name((command) => {
|
|
|
12363
12172
|
const word = Array.isArray(value) ? value.join(" ") : value;
|
|
12364
12173
|
return word === void 0 || word === "" ? [] : [[argument.name(), word]];
|
|
12365
12174
|
});
|
|
12366
|
-
const own = command.options.map((option) => option.attributeName()).filter((key) => typed(command, key)).map((key) => [
|
|
12367
|
-
const global = CARRIED.filter((key) => typed(root, key)).map((key) => [
|
|
12175
|
+
const own = command.options.map((option) => option.attributeName()).filter((key) => typed(command, key)).map((key) => [snake2(key), command.getOptionValue(key)]);
|
|
12176
|
+
const global = CARRIED.filter((key) => typed(root, key)).map((key) => [snake2(key), root.getOptionValue(key)]);
|
|
12368
12177
|
return Object.fromEntries([...positional, ...own, ...global]);
|
|
12369
12178
|
}, "typedArgs");
|
|
12370
12179
|
var declaresRow = /* @__PURE__ */ __name((command) => {
|
|
@@ -12393,7 +12202,7 @@ var largeAnswerSteps = /* @__PURE__ */ __name((command) => {
|
|
|
12393
12202
|
return args ? compactStep(command, args, "the answer is large as JSON; one line per item keeps every ref") : [];
|
|
12394
12203
|
}, "largeAnswerSteps");
|
|
12395
12204
|
|
|
12396
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
12205
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/provider-refs.js
|
|
12397
12206
|
var HIDDEN = /* @__PURE__ */ new Set(["providerRef", "provider_ref"]);
|
|
12398
12207
|
var withoutProviderRefs = /* @__PURE__ */ __name((value) => strip(value), "withoutProviderRefs");
|
|
12399
12208
|
var strip = /* @__PURE__ */ __name((value) => {
|
|
@@ -12407,7 +12216,7 @@ var strip = /* @__PURE__ */ __name((value) => {
|
|
|
12407
12216
|
return Object.fromEntries(Object.entries(value).flatMap(([key, inner]) => HIDDEN.has(key) ? [] : [[key, strip(inner)]]));
|
|
12408
12217
|
}, "strip");
|
|
12409
12218
|
|
|
12410
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
12219
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.619.0_@wirecat+cli-base@0.91.0_commander@15.0.0_esbuild@0.28.2_type_25b690dd810be59ade44e4d26e61c9f5/node_modules/@wirecat/cli-core/dist/cli/envelope.js
|
|
12411
12220
|
var answerSchema = /* @__PURE__ */ __name((item = unknown()) => union([listEnvelopeSchema(item), itemEnvelopeSchema(item)]), "answerSchema");
|
|
12412
12221
|
var capped2 = /* @__PURE__ */ __name((steps) => steps.length > 0 ? { next: steps.slice(0, MAX_NEXT_STEPS) } : {}, "capped");
|
|
12413
12222
|
var listOf = /* @__PURE__ */ __name((command, input) => {
|
|
@@ -12450,7 +12259,7 @@ var itemOf = /* @__PURE__ */ __name((item, { next = [], missing, meta } = {}) =>
|
|
|
12450
12259
|
};
|
|
12451
12260
|
return body;
|
|
12452
12261
|
}, "itemOf");
|
|
12453
|
-
var
|
|
12262
|
+
var snake3 = /* @__PURE__ */ __name((key) => key.replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`), "snake");
|
|
12454
12263
|
var snakeKeysKeeping = /* @__PURE__ */ __name((verbatim) => {
|
|
12455
12264
|
const kept = new Set(verbatim);
|
|
12456
12265
|
const convert = /* @__PURE__ */ __name((value) => {
|
|
@@ -12461,7 +12270,7 @@ var snakeKeysKeeping = /* @__PURE__ */ __name((verbatim) => {
|
|
|
12461
12270
|
return Object.fromEntries(Object.entries(value).flatMap(([key, inner]) => {
|
|
12462
12271
|
if (inner === void 0)
|
|
12463
12272
|
return [];
|
|
12464
|
-
const name =
|
|
12273
|
+
const name = snake3(key);
|
|
12465
12274
|
return [[name, kept.has(key) || kept.has(name) ? inner : convert(inner)]];
|
|
12466
12275
|
}));
|
|
12467
12276
|
}, "convert");
|
|
@@ -12583,25 +12392,6 @@ export {
|
|
|
12583
12392
|
deadlineMargin,
|
|
12584
12393
|
atDetail,
|
|
12585
12394
|
resolveOutput,
|
|
12586
|
-
logAttributes,
|
|
12587
|
-
fromLogAttributes,
|
|
12588
|
-
LOG_ATTRIBUTES,
|
|
12589
|
-
KEEP_RUNS_FOR_DAYS,
|
|
12590
|
-
KEEP_SUCCESSFUL_RUNS_FOR_DAYS,
|
|
12591
|
-
RUNS_SIZE_LIMIT_MB,
|
|
12592
|
-
runsDirFor,
|
|
12593
|
-
runtime,
|
|
12594
|
-
newRunId,
|
|
12595
|
-
listRuns,
|
|
12596
|
-
findRun,
|
|
12597
|
-
readEvents,
|
|
12598
|
-
currentRun,
|
|
12599
|
-
inRun,
|
|
12600
|
-
typedCommand,
|
|
12601
|
-
enclosingTraceId,
|
|
12602
|
-
traceOf,
|
|
12603
|
-
childTrace,
|
|
12604
|
-
withAttempt,
|
|
12605
12395
|
startRecording,
|
|
12606
12396
|
wasSettled,
|
|
12607
12397
|
sentIds,
|
|
@@ -12616,11 +12406,13 @@ export {
|
|
|
12616
12406
|
takesProfile,
|
|
12617
12407
|
commandWords,
|
|
12618
12408
|
liftProfile,
|
|
12409
|
+
runGroup,
|
|
12619
12410
|
rootOf,
|
|
12620
12411
|
endpoint,
|
|
12621
12412
|
modelTarget,
|
|
12622
12413
|
parseDuration,
|
|
12623
12414
|
DEFAULT_TEXT_MODEL,
|
|
12415
|
+
PREVIOUS_DEFAULT_TEXT_MODEL,
|
|
12624
12416
|
CustomTextModelShape,
|
|
12625
12417
|
textModelsFile,
|
|
12626
12418
|
readTextModelsSection,
|
|
@@ -12714,16 +12506,16 @@ export {
|
|
|
12714
12506
|
agenda,
|
|
12715
12507
|
analysisConsent,
|
|
12716
12508
|
attachment,
|
|
12509
|
+
WEIGHTS,
|
|
12510
|
+
LINK,
|
|
12511
|
+
oddName,
|
|
12717
12512
|
member,
|
|
12718
12513
|
chat,
|
|
12514
|
+
message,
|
|
12719
12515
|
folder,
|
|
12720
12516
|
inviteLink,
|
|
12721
12517
|
chatEvent,
|
|
12722
12518
|
contact,
|
|
12723
|
-
WEIGHTS,
|
|
12724
|
-
LINK,
|
|
12725
|
-
oddName,
|
|
12726
|
-
message,
|
|
12727
12519
|
contactNote,
|
|
12728
12520
|
conversation,
|
|
12729
12521
|
documentLink,
|