@wirecat/attio-cli 0.2.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +47 -0
- package/README.md +13 -9
- package/contracts/wirecat.json +268 -21
- package/dist/bin/attio.js +2 -2
- package/dist/bundle/agent-HM6ST5HY.js +37 -0
- package/dist/bundle/{all-profiles-LZDKPHN2.js → all-profiles-7GUR2SM3.js} +10 -10
- package/dist/bundle/{anthropic-BF72H77D.js → anthropic-4CN3TJYB.js} +5 -5
- package/dist/bundle/{app-server-H57FZJX5.js → app-server-HSQEPWRY.js} +61 -61
- package/dist/bundle/attio.js +11 -11
- package/dist/bundle/{bun-WO77T4LG.js → bun-DTF5MNDQ.js} +2 -2
- package/dist/bundle/{bun-sqlite-2BP7JDVO.js → bun-sqlite-NFVPKLZD.js} +6 -6
- package/dist/bundle/{chunk-IDU4ESRZ.js → chunk-2AVWKAHP.js} +29 -1
- package/dist/bundle/{chunk-X6R74TWX.js → chunk-2KP5LRCK.js} +4 -4
- package/dist/bundle/{chunk-RU5J7DWY.js → chunk-2PDJCM3U.js} +156 -14
- package/dist/bundle/{chunk-4SMGM2Q6.js → chunk-2SM6G7CP.js} +4 -4
- package/dist/bundle/{chunk-TF7ZGCOK.js → chunk-3HFUSESO.js} +3 -3
- package/dist/bundle/{chunk-BUGROVF3.js → chunk-3JZNNESS.js} +2 -2
- package/dist/bundle/{chunk-5K3FGXZH.js → chunk-3L3ZRFKH.js} +1 -1
- package/dist/bundle/{chunk-6NDJDDSQ.js → chunk-3PPTBPRU.js} +42 -38
- package/dist/bundle/{chunk-76RRELCU.js → chunk-4A5E32BA.js} +1747 -826
- package/dist/bundle/{chunk-CMO5ND3Y.js → chunk-4BHD26FI.js} +34 -34
- package/dist/bundle/{chunk-JA26HG7T.js → chunk-4GGTI6J2.js} +8 -8
- package/dist/bundle/{chunk-J5P5VSRG.js → chunk-4IASSY4K.js} +21 -8
- package/dist/bundle/{chunk-DSRXCLPO.js → chunk-55OZY4JK.js} +1 -1
- package/dist/bundle/{chunk-L5WS6CYZ.js → chunk-6GLKKI5B.js} +2 -2
- package/dist/bundle/{chunk-PMP37KLR.js → chunk-6GVBDIY7.js} +3 -3
- package/dist/bundle/{chunk-VDMIJ3JW.js → chunk-6MKREZYW.js} +3 -3
- package/dist/bundle/{chunk-7MXCUMHG.js → chunk-6UVYOUKX.js} +1 -1
- package/dist/bundle/{chunk-4STBJZR4.js → chunk-73D7FXGY.js} +177 -40
- package/dist/bundle/{chunk-3I2FGNWO.js → chunk-77PCNTJY.js} +1 -1
- package/dist/bundle/{chunk-7ZUOI3HY.js → chunk-AO6N3HLS.js} +16 -3
- package/dist/bundle/{chunk-IXCIQ7FZ.js → chunk-CEY7LGCR.js} +4 -4
- package/dist/bundle/{chunk-MNQACPXG.js → chunk-CV65DYDO.js} +31 -27
- package/dist/bundle/{chunk-OBXDRUO4.js → chunk-CWLNO3ZU.js} +1 -1
- package/dist/bundle/{chunk-CHZ26CW5.js → chunk-D3BQH24W.js} +77 -59
- package/dist/bundle/{chunk-ERW2WOJT.js → chunk-EBVOFSWE.js} +1 -1
- package/dist/bundle/{chunk-ESH2QGCA.js → chunk-ECPUCPPX.js} +24 -8
- package/dist/bundle/{chunk-6SK3YB2B.js → chunk-FJUBFNIH.js} +12 -12
- package/dist/bundle/{chunk-Q7BSTQ3T.js → chunk-GFKYZJN4.js} +1 -1
- package/dist/bundle/{chunk-ASCUOOLO.js → chunk-GJFFI6OA.js} +1 -1
- package/dist/bundle/{chunk-S7K2XFQB.js → chunk-GMRYIIGP.js} +6 -6
- package/dist/bundle/{chunk-G3JTLVVL.js → chunk-GS3LY5S5.js} +14 -7
- package/dist/bundle/{chunk-WARIIYSW.js → chunk-H55WJPRM.js} +2 -2
- package/dist/bundle/{chunk-H7QDPW3D.js → chunk-HS7TLG6U.js} +3 -4
- package/dist/bundle/{chunk-EEPE3SOW.js → chunk-HVLKBGYN.js} +5 -5
- package/dist/bundle/{chunk-XXLQNHKF.js → chunk-IFDR5RYE.js} +2 -2
- package/dist/bundle/{chunk-3YFDZSM3.js → chunk-IQSXBZA7.js} +1 -1
- package/dist/bundle/{chunk-GLHFJPYS.js → chunk-IWC3ECVF.js} +3 -3
- package/dist/bundle/{chunk-EQXT7KO4.js → chunk-J3KE3D3L.js} +6 -6
- package/dist/bundle/{chunk-JSTBW7F4.js → chunk-KP7U75NI.js} +6 -6
- package/dist/bundle/{chunk-O4A33Y54.js → chunk-KRCE3EBI.js} +2 -2
- package/dist/bundle/{chunk-ZDBTYBFR.js → chunk-LC4KJJZ2.js} +3 -3
- package/dist/bundle/{chunk-3NVOKVRY.js → chunk-LX6IMPKX.js} +2361 -845
- package/dist/bundle/{chunk-V6BTAILB.js → chunk-MCNZCQ6P.js} +61 -61
- package/dist/bundle/{chunk-DF2IIO32.js → chunk-N7EFLZNW.js} +202 -163
- package/dist/bundle/{chunk-G6FQMVKW.js → chunk-NE65S7F6.js} +3 -3
- package/dist/bundle/{chunk-HG7FT3H3.js → chunk-NK32ZZRV.js} +7 -7
- package/dist/bundle/{chunk-VW5F6FK3.js → chunk-NTW3Z4ZC.js} +4 -4
- package/dist/bundle/{chunk-XXOTX4M3.js → chunk-OOS57MMX.js} +7 -7
- package/dist/bundle/{chunk-2E6JGBM5.js → chunk-PBUBZNIA.js} +25 -174
- package/dist/bundle/{chunk-AFAULIL5.js → chunk-PCYDTU6N.js} +3 -2
- package/dist/bundle/{chunk-WK7GLHHL.js → chunk-PTBGWRI4.js} +5 -5
- package/dist/bundle/{chunk-X5S5KUSU.js → chunk-PX5XI2UR.js} +19 -19
- package/dist/bundle/{chunk-KHDXRFJZ.js → chunk-ROJF7524.js} +8 -8
- package/dist/bundle/{chunk-AMUONYQR.js → chunk-RPL3VL7F.js} +2 -2
- package/dist/bundle/{chunk-MOSH2KPD.js → chunk-SDZJIDMF.js} +10 -10
- package/dist/bundle/{chunk-OFR3YYT6.js → chunk-SEZLN6OX.js} +1 -1
- package/dist/bundle/{chunk-MT2ZUZRA.js → chunk-SIYP5IZG.js} +43 -64
- package/dist/bundle/{chunk-I3WS6V5H.js → chunk-SNUCQQQU.js} +8 -8
- package/dist/bundle/{chunk-34FJ26K2.js → chunk-SRU4EQYO.js} +2 -2
- package/dist/bundle/{chunk-LWJ4ZGUM.js → chunk-SVUQKDBZ.js} +13 -13
- package/dist/bundle/{chunk-GW4G5KLS.js → chunk-SZ76WGXS.js} +8 -8
- package/dist/bundle/{chunk-DQ6P3R4B.js → chunk-UN63OIS5.js} +3 -3
- package/dist/bundle/{chunk-MRREDVPY.js → chunk-UNI5OO3J.js} +20 -14
- package/dist/bundle/{chunk-EQGXEKSV.js → chunk-UXT4532H.js} +7 -7
- package/dist/bundle/{chunk-ZGADZ4CH.js → chunk-V6RIJ22V.js} +15 -15
- package/dist/bundle/{chunk-6ALPRBNV.js → chunk-WAOJEEGU.js} +3 -3
- package/dist/bundle/{chunk-QLHDUYGE.js → chunk-WE6UGOBO.js} +1 -1
- package/dist/bundle/{chunk-Q3JCUUOR.js → chunk-WYPHP2AM.js} +3 -3
- package/dist/bundle/{chunk-W6F2CQZ6.js → chunk-Y6QUAEEJ.js} +17 -17
- package/dist/bundle/{chunk-GBZ6JUXU.js → chunk-YERPSSUC.js} +2 -2
- package/dist/bundle/{chunk-MC2RQ2OB.js → chunk-ZAZUNEZB.js} +1 -1
- package/dist/bundle/{chunk-SQHDE3TC.js → chunk-ZSO3T2W4.js} +4 -4
- package/dist/bundle/command-contract-XZKDRLEC.js +37 -0
- package/dist/bundle/{command-server-entry-MNVPYQZ3.js → command-server-entry-VTYSKZSD.js} +25 -25
- package/dist/bundle/{decode-MQNKNXLK.js → decode-EJCGQVLX.js} +5 -5
- package/dist/bundle/{dispatch-TAQ7635E.js → dispatch-YGAG263C.js} +8 -8
- package/dist/bundle/{echarts-6ZSUNO4L.js → echarts-LHBWIDKI.js} +2 -2
- package/dist/bundle/{embed-PHCCJJ5Z.js → embed-QKVPSZLS.js} +6 -6
- package/dist/bundle/{embedder-WLZZQTKZ.js → embedder-NYO6EOFU.js} +9 -9
- package/dist/bundle/{failure-MR2XVHFP.js → failure-SE7VJEXI.js} +2 -2
- package/dist/bundle/{first-run-64LREHSV.js → first-run-P5QA7RNU.js} +12 -12
- package/dist/bundle/first-screen-EUIV6PVE.js +37 -0
- package/dist/bundle/{instructions-22GCKNR5.js → instructions-T6LGIEPV.js} +1 -1
- package/dist/bundle/{mcp-CNV7F2XZ.js → mcp-PVQZS6IH.js} +2 -2
- package/dist/bundle/meeting-combined-GOBZBEX2.js +24 -0
- package/dist/bundle/{meeting-model-JWDTCGLZ.js → meeting-model-7UBHXIVW.js} +11 -11
- package/dist/bundle/{meeting-semantic-375GYPZQ.js → meeting-semantic-RXCWAIZZ.js} +6 -6
- package/dist/bundle/{node-ITDTNRRZ.js → node-UBG6VKKA.js} +2 -2
- package/dist/bundle/{node-sqlite-IRAGRMEZ.js → node-sqlite-PYNAIHR6.js} +7 -7
- package/dist/bundle/{oauth-CACOQJEL.js → oauth-BLOW6XVT.js} +7 -7
- package/dist/bundle/{open-HU4KHKDR.js → open-VWILPEZ2.js} +5 -5
- package/dist/bundle/{openai-JQUPAVKX.js → openai-N37NPTEE.js} +15 -15
- package/dist/bundle/{process-QS5OHEUK.js → process-DMYM7PNQ.js} +1 -1
- package/dist/bundle/{program-5OTAVU5S.js → program-5QZLUWS4.js} +4240 -4056
- package/dist/bundle/{prompt-VA5MKXJU.js → prompt-EJHIAH4K.js} +5 -5
- package/dist/bundle/{recognize-JGA5IVKC.js → recognize-67LER7ZN.js} +4 -4
- package/dist/bundle/{remote-NPY2KZQ4.js → remote-BONPKWRO.js} +9 -9
- package/dist/bundle/{rerank-4H2QR4XU.js → rerank-FK2AFC3Y.js} +7 -7
- package/dist/bundle/{schemas-THAI3G5S.js → schemas-4E76I6ME.js} +1 -1
- package/dist/bundle/{serve-UH46SZQG.js → serve-ZIXWKUE3.js} +9 -9
- package/dist/bundle/{server-6H7JS6SU.js → server-4RX3LBCA.js} +53 -53
- package/dist/bundle/server-RL6NIURH.js +79 -0
- package/dist/bundle/{sqlite-runtime-EJWEUTBR.js → sqlite-runtime-WDXPYP7C.js} +6 -6
- package/dist/bundle/{state-34B6AUQZ.js → state-NE7WPOBK.js} +6 -6
- package/dist/bundle/{store-3R4ILTCJ.js → store-2LX2ZQY5.js} +22 -18
- package/dist/bundle/{store-XSE35P3U.js → store-PUAKYH6Z.js} +24 -20
- package/dist/bundle/store-maintenance-command-CSYN4LXT.js +66 -0
- package/dist/bundle/surface-HJIDG2KX.js +65 -0
- package/dist/commands/crm.d.ts +3 -0
- package/dist/commands/crm.d.ts.map +1 -1
- package/dist/commands/crm.js +35 -8
- package/dist/commands/crm.js.map +1 -1
- package/dist/commands/schedule.d.ts +3 -0
- package/dist/commands/schedule.d.ts.map +1 -0
- package/dist/commands/schedule.js +9 -0
- package/dist/commands/schedule.js.map +1 -0
- package/dist/commands/session.d.ts +2 -1
- package/dist/commands/session.d.ts.map +1 -1
- package/dist/commands/session.js +5 -1
- package/dist/commands/session.js.map +1 -1
- package/dist/config.d.ts +0 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +22 -5
- package/dist/config.js.map +1 -1
- package/dist/generated/wirecat-config.d.ts.map +1 -1
- package/dist/generated/wirecat-config.js +175 -0
- package/dist/generated/wirecat-config.js.map +1 -1
- package/dist/hooks.d.ts.map +1 -1
- package/dist/hooks.js +10 -2
- package/dist/hooks.js.map +1 -1
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +4 -2
- package/dist/identity.js.map +1 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +11 -1
- package/dist/program.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -4
- package/skills/attio-cli/SKILL.md +18 -3
- package/dist/bundle/agent-DYTWDBTT.js +0 -37
- package/dist/bundle/command-contract-7M6EPH3D.js +0 -37
- package/dist/bundle/first-screen-YSCAZIYJ.js +0 -37
- package/dist/bundle/meeting-combined-YX3T5WJD.js +0 -24
- package/dist/bundle/server-SR52KBL3.js +0 -79
- package/dist/bundle/store-maintenance-command-ABJARLI4.js +0 -66
- package/dist/bundle/surface-NOTIEJB5.js +0 -65
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
import { createRequire as __bundleRequire } from "node:module";
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
|
-
answerOf,
|
|
5
4
|
messengerContext
|
|
6
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-PBUBZNIA.js";
|
|
7
6
|
import {
|
|
8
7
|
chatEventAnswer,
|
|
9
8
|
memberAnswer,
|
|
10
9
|
pollVoteAnswer
|
|
11
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-4GGTI6J2.js";
|
|
12
11
|
import {
|
|
13
12
|
stringWidth,
|
|
14
13
|
wrapAnsi
|
|
15
14
|
} from "./chunk-EH6ZEJGT.js";
|
|
16
15
|
import {
|
|
17
16
|
serveRelay
|
|
18
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-HVLKBGYN.js";
|
|
19
18
|
import {
|
|
20
19
|
FETCHING,
|
|
21
20
|
RULES_VERSION,
|
|
21
|
+
answerOf,
|
|
22
22
|
applyTaskRulesOnArrival,
|
|
23
23
|
embeddingKeys,
|
|
24
24
|
endpointKeyName,
|
|
@@ -32,20 +32,21 @@ import {
|
|
|
32
32
|
servicesFor,
|
|
33
33
|
syncsOneChat,
|
|
34
34
|
withTimeLimit
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-LX6IMPKX.js";
|
|
36
36
|
import {
|
|
37
37
|
capability,
|
|
38
38
|
queryTerms,
|
|
39
39
|
typedQuery,
|
|
40
40
|
withQuery
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-UNI5OO3J.js";
|
|
42
42
|
import {
|
|
43
43
|
holdLock,
|
|
44
44
|
lockPath,
|
|
45
|
+
markCurrent,
|
|
45
46
|
releaseLock,
|
|
46
47
|
servingProfiles,
|
|
47
48
|
takeLock
|
|
48
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-AO6N3HLS.js";
|
|
49
50
|
import {
|
|
50
51
|
Command,
|
|
51
52
|
LOCAL_READ,
|
|
@@ -73,13 +74,13 @@ import {
|
|
|
73
74
|
snakeKeys,
|
|
74
75
|
storeTable,
|
|
75
76
|
withoutProviderRefs
|
|
76
|
-
} from "./chunk-
|
|
77
|
+
} from "./chunk-N7EFLZNW.js";
|
|
77
78
|
import {
|
|
78
79
|
holdersOf
|
|
79
|
-
} from "./chunk-
|
|
80
|
+
} from "./chunk-CWLNO3ZU.js";
|
|
80
81
|
import {
|
|
81
82
|
readSecret
|
|
82
|
-
} from "./chunk-
|
|
83
|
+
} from "./chunk-WAOJEEGU.js";
|
|
83
84
|
import {
|
|
84
85
|
QUICK_HEALTH_CHECKS,
|
|
85
86
|
fts5Tables,
|
|
@@ -87,7 +88,7 @@ import {
|
|
|
87
88
|
lossUnknown,
|
|
88
89
|
storeDamageReport,
|
|
89
90
|
storeHealth
|
|
90
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-Y6QUAEEJ.js";
|
|
91
92
|
import {
|
|
92
93
|
CORPORA,
|
|
93
94
|
MIGRATIONS,
|
|
@@ -111,6 +112,7 @@ import {
|
|
|
111
112
|
readStoreTables,
|
|
112
113
|
rebuildMentions,
|
|
113
114
|
resetAttachmentWords,
|
|
115
|
+
resetContentPostWords,
|
|
114
116
|
resetCrmFileWords,
|
|
115
117
|
resetNoteIndex,
|
|
116
118
|
resetSearchIndex,
|
|
@@ -124,7 +126,7 @@ import {
|
|
|
124
126
|
storeClients,
|
|
125
127
|
storeContents,
|
|
126
128
|
vectorIndexCounts
|
|
127
|
-
} from "./chunk-
|
|
129
|
+
} from "./chunk-4A5E32BA.js";
|
|
128
130
|
import {
|
|
129
131
|
currentRun,
|
|
130
132
|
formatLocator,
|
|
@@ -133,35 +135,35 @@ import {
|
|
|
133
135
|
readHealthMark,
|
|
134
136
|
readJournalMark,
|
|
135
137
|
recordDeepCheck
|
|
136
|
-
} from "./chunk-
|
|
138
|
+
} from "./chunk-3PPTBPRU.js";
|
|
137
139
|
import {
|
|
138
140
|
failureKey,
|
|
139
141
|
isStoreDamage
|
|
140
|
-
} from "./chunk-
|
|
142
|
+
} from "./chunk-IWC3ECVF.js";
|
|
141
143
|
import {
|
|
142
144
|
queryFieldsOf
|
|
143
|
-
} from "./chunk-
|
|
145
|
+
} from "./chunk-MCNZCQ6P.js";
|
|
144
146
|
import {
|
|
145
147
|
modelAddressAllowed,
|
|
146
148
|
onThisComputer
|
|
147
|
-
} from "./chunk-
|
|
149
|
+
} from "./chunk-ECPUCPPX.js";
|
|
148
150
|
import {
|
|
149
151
|
readSharedSection,
|
|
150
152
|
sharedConfigPath,
|
|
151
153
|
writeSharedSection
|
|
152
|
-
} from "./chunk-
|
|
154
|
+
} from "./chunk-UXT4532H.js";
|
|
153
155
|
import {
|
|
154
156
|
storePath
|
|
155
|
-
} from "./chunk-
|
|
157
|
+
} from "./chunk-SRU4EQYO.js";
|
|
156
158
|
import {
|
|
157
159
|
openCache
|
|
158
|
-
} from "./chunk-
|
|
160
|
+
} from "./chunk-GMRYIIGP.js";
|
|
159
161
|
import {
|
|
160
162
|
Credentials,
|
|
161
163
|
isMovedRun,
|
|
162
164
|
resolvePaths,
|
|
163
165
|
writeSecurely
|
|
164
|
-
} from "./chunk-
|
|
166
|
+
} from "./chunk-PX5XI2UR.js";
|
|
165
167
|
import {
|
|
166
168
|
array,
|
|
167
169
|
boolean,
|
|
@@ -188,7 +190,7 @@ import {
|
|
|
188
190
|
CliError,
|
|
189
191
|
singleLine,
|
|
190
192
|
visibleControls
|
|
191
|
-
} from "./chunk-
|
|
193
|
+
} from "./chunk-3JZNNESS.js";
|
|
192
194
|
import {
|
|
193
195
|
__commonJS,
|
|
194
196
|
__name,
|
|
@@ -5528,11 +5530,11 @@ var require_liquid_node = __commonJS({
|
|
|
5528
5530
|
}
|
|
5529
5531
|
});
|
|
5530
5532
|
|
|
5531
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5533
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
|
|
5532
5534
|
import { chmodSync, constants, copyFileSync, existsSync as existsSync10, mkdirSync, realpathSync as realpathSync3, renameSync as renameSync3, rmSync as rmSync3, statfsSync as statfsSync2, statSync as statSync4, writeFileSync as writeFileSync2 } from "node:fs";
|
|
5533
5535
|
import { dirname as dirname3, resolve } from "node:path";
|
|
5534
5536
|
|
|
5535
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5537
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/sealed.js
|
|
5536
5538
|
import { createCipheriv, createDecipheriv, createHash, randomBytes, scrypt, timingSafeEqual } from "node:crypto";
|
|
5537
5539
|
import { closeSync, createReadStream, createWriteStream, existsSync, openSync, readSync, renameSync, rmSync, statSync } from "node:fs";
|
|
5538
5540
|
import { Transform } from "node:stream";
|
|
@@ -5639,7 +5641,7 @@ var unsealFile = /* @__PURE__ */ __name(async (from, to, password) => {
|
|
|
5639
5641
|
renameSync(pending, to);
|
|
5640
5642
|
}, "unsealFile");
|
|
5641
5643
|
|
|
5642
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5644
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/store/compatibility.js
|
|
5643
5645
|
var SPEAKS = MIGRATIONS.at(-1)?.version ?? 0;
|
|
5644
5646
|
var fileSchemaOf = /* @__PURE__ */ __name((database) => {
|
|
5645
5647
|
const tracked = database.prepare("SELECT 1 FROM sqlite_master WHERE name = 'schema_migrations'").get();
|
|
@@ -5663,7 +5665,7 @@ var compatibilityOf = /* @__PURE__ */ __name((file2, migrations = MIGRATIONS) =>
|
|
|
5663
5665
|
};
|
|
5664
5666
|
}, "compatibilityOf");
|
|
5665
5667
|
|
|
5666
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5668
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/store/repair.js
|
|
5667
5669
|
import { createHash as createHash2 } from "node:crypto";
|
|
5668
5670
|
var COPY_MARK = "__repair_";
|
|
5669
5671
|
var COPY_NAME = /__repair_[0-9a-f]{8}(_\d+)?$/;
|
|
@@ -5917,19 +5919,19 @@ var deleteCopy = /* @__PURE__ */ __name((database, name) => {
|
|
|
5917
5919
|
return found;
|
|
5918
5920
|
}, "deleteCopy");
|
|
5919
5921
|
|
|
5920
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5922
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/store-info.js
|
|
5921
5923
|
import { existsSync as existsSync4, statSync as statSync3 } from "node:fs";
|
|
5922
5924
|
|
|
5923
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5925
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
|
|
5924
5926
|
import { existsSync as existsSync3 } from "node:fs";
|
|
5925
5927
|
|
|
5926
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5928
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/store/recover.js
|
|
5927
5929
|
import { execFileSync, spawn } from "node:child_process";
|
|
5928
5930
|
import { existsSync as existsSync2, readFileSync, realpathSync, renameSync as renameSync2, rmSync as rmSync2, statfsSync, statSync as statSync2, writeFileSync } from "node:fs";
|
|
5929
5931
|
import { basename, dirname, join } from "node:path";
|
|
5930
5932
|
import { Transform as Transform2 } from "node:stream";
|
|
5931
5933
|
|
|
5932
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5934
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/store/refill.js
|
|
5933
5935
|
var REFILL_MARGIN_MS = 864e5;
|
|
5934
5936
|
var TIME_KEYS = 1e12;
|
|
5935
5937
|
var integerId = `external_id GLOB '[0-9]*' AND NOT external_id GLOB '*[^0-9]*'`;
|
|
@@ -6009,7 +6011,7 @@ var forgetMail = /* @__PURE__ */ __name((database, cutoff, now) => {
|
|
|
6009
6011
|
return [...folders].map(([account, count3]) => ({ account, folders: count3 }));
|
|
6010
6012
|
}, "forgetMail");
|
|
6011
6013
|
|
|
6012
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6014
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/store/recover.js
|
|
6013
6015
|
var SQLITE3_MINIMUM = [3, 43, 0];
|
|
6014
6016
|
var STORE_PARTS = ["", "-wal", "-shm"];
|
|
6015
6017
|
var RECOVER_LOCK = ".recover-lock";
|
|
@@ -6288,6 +6290,7 @@ var FILLERS = {
|
|
|
6288
6290
|
attachment_words: /* @__PURE__ */ __name((database) => void resetAttachmentWords(database), "attachment_words"),
|
|
6289
6291
|
crm_file_words: /* @__PURE__ */ __name((database) => void resetCrmFileWords(database), "crm_file_words"),
|
|
6290
6292
|
tracker_item_words: /* @__PURE__ */ __name((database) => void resetTrackerItemWords(database), "tracker_item_words"),
|
|
6293
|
+
content_post_words: /* @__PURE__ */ __name((database) => void resetContentPostWords(database), "content_post_words"),
|
|
6291
6294
|
attachment_name_words: /* @__PURE__ */ __name((database) => (
|
|
6292
6295
|
// As migration 20 filled it: й and ё fold as the triggers fold them.
|
|
6293
6296
|
database.exec("INSERT INTO attachment_name_words (rowid, name) SELECT id, replace(replace(replace(replace(name, '\u0439', '\u0438'), '\u0419', '\u0418'), '\u0451', '\u0435'), '\u0401', '\u0415') FROM attachments WHERE name IS NOT NULL")
|
|
@@ -6539,7 +6542,7 @@ var recoverLocked = /* @__PURE__ */ __name(async ({ path, command, version, sqli
|
|
|
6539
6542
|
}
|
|
6540
6543
|
}, "recoverLocked");
|
|
6541
6544
|
|
|
6542
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6545
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
|
|
6543
6546
|
var COUNTED = [
|
|
6544
6547
|
"accounts",
|
|
6545
6548
|
"chats",
|
|
@@ -6695,7 +6698,7 @@ var storeRecoverCommand = /* @__PURE__ */ __name(({ command, version }) => {
|
|
|
6695
6698
|
return recover;
|
|
6696
6699
|
}, "storeRecoverCommand");
|
|
6697
6700
|
|
|
6698
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6701
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/store-info.js
|
|
6699
6702
|
var pendingIfKnown = /* @__PURE__ */ __name((database) => database.prepare("SELECT 1 FROM pragma_table_info('messages') WHERE name = 'normalized_text'").get() ? pendingNormalization(database) : null, "pendingIfKnown");
|
|
6700
6703
|
var bytesOf = /* @__PURE__ */ __name((path) => existsSync4(path) ? statSync3(path).size : 0, "bytesOf");
|
|
6701
6704
|
var messageOf = /* @__PURE__ */ __name((error) => error instanceof Error ? error.message : String(error), "messageOf");
|
|
@@ -6741,7 +6744,7 @@ var storeInfoCommand = /* @__PURE__ */ __name(() => annotate(new Command("info")
|
|
|
6741
6744
|
renderAnswer(this, outputFor(this), itemOf(answer));
|
|
6742
6745
|
}), "storeInfoCommand");
|
|
6743
6746
|
|
|
6744
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6747
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/password.js
|
|
6745
6748
|
var ENCRYPT_OPTION = [
|
|
6746
6749
|
"--encrypt",
|
|
6747
6750
|
"compress and encrypt with a password, typed at a hidden prompt or piped on stdin; it is never kept \u2014 lose it and the file cannot be opened"
|
|
@@ -6760,7 +6763,7 @@ var passwordOf = /* @__PURE__ */ __name(async (command, { twice }) => {
|
|
|
6760
6763
|
return password;
|
|
6761
6764
|
}, "passwordOf");
|
|
6762
6765
|
|
|
6763
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6766
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/rules.js
|
|
6764
6767
|
import { existsSync as existsSync5, readFileSync as readFileSync2 } from "node:fs";
|
|
6765
6768
|
import { join as join2 } from "node:path";
|
|
6766
6769
|
var REPLY_ACTIONS = ["reply", "task"];
|
|
@@ -6931,7 +6934,7 @@ var problem = /* @__PURE__ */ __name((issue) => {
|
|
|
6931
6934
|
}, "problem");
|
|
6932
6935
|
var broken = /* @__PURE__ */ __name((path, why) => new CliError("configuration_error", `the reply rules ${path} cannot be read (${why}) \u2014 fix the file`), "broken");
|
|
6933
6936
|
|
|
6934
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6937
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/state.js
|
|
6935
6938
|
import { existsSync as existsSync6, readFileSync as readFileSync3 } from "node:fs";
|
|
6936
6939
|
import { join as join3 } from "node:path";
|
|
6937
6940
|
var ANSWERED_KEPT = 1e3;
|
|
@@ -6984,7 +6987,7 @@ var recordReply = /* @__PURE__ */ __name((state, rule2, message, now) => {
|
|
|
6984
6987
|
}, "recordReply");
|
|
6985
6988
|
var broken2 = /* @__PURE__ */ __name((path, why) => new CliError("configuration_error", `the reply state ${path} cannot be read (${why}) \u2014 fix or move the file`), "broken");
|
|
6986
6989
|
|
|
6987
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6990
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/decide.js
|
|
6988
6991
|
var skip = /* @__PURE__ */ __name((why) => ({ skip: why }), "skip");
|
|
6989
6992
|
var decide = /* @__PURE__ */ __name((rule2, incoming, state, now) => {
|
|
6990
6993
|
const { message, chat, owner, sender } = incoming;
|
|
@@ -7090,10 +7093,10 @@ var filled = /* @__PURE__ */ __name((template2, senderName) => {
|
|
|
7090
7093
|
return template2.replaceAll("{firstName}", name.split(/\s+/)[0] ?? name).replaceAll("{name}", name);
|
|
7091
7094
|
}, "filled");
|
|
7092
7095
|
|
|
7093
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7096
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/template.js
|
|
7094
7097
|
var import_liquidjs2 = __toESM(require_liquid_node(), 1);
|
|
7095
7098
|
|
|
7096
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7099
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/render/liquid.js
|
|
7097
7100
|
var import_liquidjs = __toESM(require_liquid_node(), 1);
|
|
7098
7101
|
var safeLiquid = /* @__PURE__ */ __name((limits) => {
|
|
7099
7102
|
const engine = new import_liquidjs.Liquid({
|
|
@@ -7120,7 +7123,7 @@ var safeLiquid = /* @__PURE__ */ __name((limits) => {
|
|
|
7120
7123
|
return engine;
|
|
7121
7124
|
}, "safeLiquid");
|
|
7122
7125
|
|
|
7123
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7126
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/template.js
|
|
7124
7127
|
var TEMPLATE_LIMITS = {
|
|
7125
7128
|
parse: 32768,
|
|
7126
7129
|
renders: 2e3,
|
|
@@ -7259,7 +7262,7 @@ var renderReplyTemplate = /* @__PURE__ */ __name(async (reply, input) => {
|
|
|
7259
7262
|
}
|
|
7260
7263
|
}, "renderReplyTemplate");
|
|
7261
7264
|
|
|
7262
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7265
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/dry-run.js
|
|
7263
7266
|
var DRY_RUN_DAYS = 7;
|
|
7264
7267
|
var PAGE = 500;
|
|
7265
7268
|
var dryRun = /* @__PURE__ */ __name(async (store, account, rules, { since, until = Date.now(), only, audience, render }) => {
|
|
@@ -7373,7 +7376,7 @@ var storedSince = /* @__PURE__ */ __name(async (store, account, chat, since) =>
|
|
|
7373
7376
|
}
|
|
7374
7377
|
}, "storedSince");
|
|
7375
7378
|
|
|
7376
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7379
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/models/ai.js
|
|
7377
7380
|
var AI_PROVIDERS = ["anthropic", "openai", "ollama"];
|
|
7378
7381
|
var DEFAULT_BASE_URL = {
|
|
7379
7382
|
anthropic: "https://api.anthropic.com",
|
|
@@ -7523,7 +7526,7 @@ var checkAi = /* @__PURE__ */ __name(async (deps) => {
|
|
|
7523
7526
|
}
|
|
7524
7527
|
}, "checkAi");
|
|
7525
7528
|
|
|
7526
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7529
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/models/purpose.js
|
|
7527
7530
|
var HOSTED = {
|
|
7528
7531
|
openai: "https://api.openai.com/v1",
|
|
7529
7532
|
anthropic: "https://api.anthropic.com"
|
|
@@ -7544,7 +7547,7 @@ var purposeModel = /* @__PURE__ */ __name((settings, purpose, deps) => {
|
|
|
7544
7547
|
return shared ? { target: shared.target, key: /* @__PURE__ */ __name(() => shared.key, "key"), shared: shared.setting } : void 0;
|
|
7545
7548
|
}, "purposeModel");
|
|
7546
7549
|
|
|
7547
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7550
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/consents.js
|
|
7548
7551
|
import { existsSync as existsSync7, readFileSync as readFileSync4 } from "node:fs";
|
|
7549
7552
|
import { join as join4 } from "node:path";
|
|
7550
7553
|
var shape = strictObject({
|
|
@@ -7569,7 +7572,7 @@ var mayModelReply = /* @__PURE__ */ __name((path, provider, chat) => {
|
|
|
7569
7572
|
return consent.provider === provider && !consent.deniedChats.includes(chat);
|
|
7570
7573
|
}, "mayModelReply");
|
|
7571
7574
|
|
|
7572
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7575
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/rendering.js
|
|
7573
7576
|
var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, options = {
|
|
7574
7577
|
ai: true
|
|
7575
7578
|
}) => async (rule2, message, chat, now) => {
|
|
@@ -7617,7 +7620,7 @@ var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, o
|
|
|
7617
7620
|
return result2;
|
|
7618
7621
|
}, "replyRenderer");
|
|
7619
7622
|
|
|
7620
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7623
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/replies/serve.js
|
|
7621
7624
|
var NOT_ALLOWED = "replies.send is not allow";
|
|
7622
7625
|
var NO_RULES = "no rules";
|
|
7623
7626
|
var ONLY_TASK = "opened a task, sent nothing";
|
|
@@ -7710,7 +7713,7 @@ var replyTo = /* @__PURE__ */ __name(async (deps, message) => {
|
|
|
7710
7713
|
return { skip: why };
|
|
7711
7714
|
}, "replyTo");
|
|
7712
7715
|
|
|
7713
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7716
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-catch-up.js
|
|
7714
7717
|
var START_SYNC_DELAY_MS = 3e4;
|
|
7715
7718
|
var START_SYNC_BUDGET_MS = 5 * 6e4;
|
|
7716
7719
|
var START_SYNC_WINDOW_MS = 7 * 864e5;
|
|
@@ -7787,7 +7790,7 @@ var startSync = /* @__PURE__ */ __name(({ chats, newestHeld, fetch, note, warn,
|
|
|
7787
7790
|
};
|
|
7788
7791
|
}, "startSync");
|
|
7789
7792
|
|
|
7790
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7793
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-members.js
|
|
7791
7794
|
var FIRST_FETCH_MS = 6e4;
|
|
7792
7795
|
var DAY_MS = 864e5;
|
|
7793
7796
|
var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch, warn, firstMs = FIRST_FETCH_MS, everyMs = DAY_MS }) => {
|
|
@@ -7841,7 +7844,7 @@ var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch, warn, firstMs =
|
|
|
7841
7844
|
};
|
|
7842
7845
|
}, "memberFetches");
|
|
7843
7846
|
|
|
7844
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7847
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-notice.js
|
|
7845
7848
|
var record2 = /* @__PURE__ */ __name((context, app, severity, attributes) => recordLogFor(context.streams.diagnostic, app, { command: currentRun().command || "serve" })[severity](attributes), "record");
|
|
7846
7849
|
var noticeFor = /* @__PURE__ */ __name((context, app, severity = "warn") => ({ text, ...attributes }) => {
|
|
7847
7850
|
if (context.format === "pretty") {
|
|
@@ -7874,7 +7877,7 @@ var recordDiagnostics = /* @__PURE__ */ __name((context, app) => {
|
|
|
7874
7877
|
return context;
|
|
7875
7878
|
}, "recordDiagnostics");
|
|
7876
7879
|
|
|
7877
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7880
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-outdated.js
|
|
7878
7881
|
import { existsSync as existsSync8, readFileSync as readFileSync5, realpathSync as realpathSync2 } from "node:fs";
|
|
7879
7882
|
import { dirname as dirname2, join as join5 } from "node:path";
|
|
7880
7883
|
var OUTDATED_CHECK_MS = 6e4;
|
|
@@ -7960,7 +7963,7 @@ var watchOutdated = /* @__PURE__ */ __name(({ check: check2, onOutdated, everyMs
|
|
|
7960
7963
|
};
|
|
7961
7964
|
}, "watchOutdated");
|
|
7962
7965
|
|
|
7963
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7966
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-stems.js
|
|
7964
7967
|
var STEMS_EVERY_MS = 3e4;
|
|
7965
7968
|
var STEMS_SLICE_MS = 2e3;
|
|
7966
7969
|
var stemFills = /* @__PURE__ */ __name(({ withStore, warn, everyMs = STEMS_EVERY_MS, sliceMs = STEMS_SLICE_MS }) => {
|
|
@@ -8000,7 +8003,7 @@ var stemFills = /* @__PURE__ */ __name(({ withStore, warn, everyMs = STEMS_EVERY
|
|
|
8000
8003
|
};
|
|
8001
8004
|
}, "stemFills");
|
|
8002
8005
|
|
|
8003
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8006
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/render/messages.js
|
|
8004
8007
|
import { styleText } from "node:util";
|
|
8005
8008
|
var TIME_WIDTH = 8;
|
|
8006
8009
|
var INDENT = " ".repeat(TIME_WIDTH + 2);
|
|
@@ -8176,7 +8179,7 @@ var editedAt = /* @__PURE__ */ __name((message, options) => {
|
|
|
8176
8179
|
return day(edited) === day(message.timestamp) ? time : `${day(edited)} ${time}`;
|
|
8177
8180
|
}, "editedAt");
|
|
8178
8181
|
|
|
8179
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8182
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/message-items.js
|
|
8180
8183
|
var defined = /* @__PURE__ */ __name((value) => Object.fromEntries(Object.entries(value).filter(([, one]) => one !== void 0)), "defined");
|
|
8181
8184
|
var attachmentItem = /* @__PURE__ */ __name((attachment) => defined({
|
|
8182
8185
|
kind: attachment.kind,
|
|
@@ -8272,7 +8275,7 @@ var viewOf = /* @__PURE__ */ __name((context, messenger) => ({
|
|
|
8272
8275
|
locale: messenger.app.locale
|
|
8273
8276
|
}), "viewOf");
|
|
8274
8277
|
|
|
8275
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8278
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-answers.js
|
|
8276
8279
|
var observed = /* @__PURE__ */ __name((value) => ({
|
|
8277
8280
|
value: value.value,
|
|
8278
8281
|
observed_at: value.observedAt,
|
|
@@ -8339,7 +8342,7 @@ var watchEventItem = /* @__PURE__ */ __name((value, account) => {
|
|
|
8339
8342
|
}
|
|
8340
8343
|
}, "watchEventItem");
|
|
8341
8344
|
|
|
8342
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8345
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-command.js
|
|
8343
8346
|
var watchCommand = /* @__PURE__ */ __name((messenger) => annotate(new Command("watch"), {
|
|
8344
8347
|
output: { entity: "watch_item" },
|
|
8345
8348
|
effects: REMOTE_READ,
|
|
@@ -8494,7 +8497,8 @@ var describe = /* @__PURE__ */ __name((event, render) => {
|
|
|
8494
8497
|
}
|
|
8495
8498
|
}, "describe");
|
|
8496
8499
|
|
|
8497
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8500
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-command.js
|
|
8501
|
+
var CURRENT_EVERY_MS = 6e4;
|
|
8498
8502
|
var serveCommand = /* @__PURE__ */ __name((messenger) => {
|
|
8499
8503
|
const command = annotate(new Command("serve"), {
|
|
8500
8504
|
output: { entity: "serve_summary" },
|
|
@@ -8517,9 +8521,18 @@ var serveCommand = /* @__PURE__ */ __name((messenger) => {
|
|
|
8517
8521
|
throw new CliError("validation_error", `${messenger.app.command} serve is already running for profile ${context.profile} (PID ${held.pid}, since ${held.startedAt})`);
|
|
8518
8522
|
}
|
|
8519
8523
|
let relaying;
|
|
8524
|
+
let current;
|
|
8525
|
+
const stamp = /* @__PURE__ */ __name(() => {
|
|
8526
|
+
try {
|
|
8527
|
+
markCurrent(path);
|
|
8528
|
+
} catch {
|
|
8529
|
+
}
|
|
8530
|
+
}, "stamp");
|
|
8520
8531
|
const onReady = /* @__PURE__ */ __name(() => {
|
|
8521
8532
|
const listening2 = { pid: process.pid, startedAt, version, listeningAt: (/* @__PURE__ */ new Date()).toISOString() };
|
|
8522
8533
|
holdLock(path, listening2);
|
|
8534
|
+
stamp();
|
|
8535
|
+
current ??= setInterval(stamp, CURRENT_EVERY_MS).unref();
|
|
8523
8536
|
note({
|
|
8524
8537
|
code: "listening",
|
|
8525
8538
|
text: `listening for profile ${context.profile}, catching up on what arrived while it was down`
|
|
@@ -8640,6 +8653,10 @@ var serveCommand = /* @__PURE__ */ __name((messenger) => {
|
|
|
8640
8653
|
}, "connected")
|
|
8641
8654
|
});
|
|
8642
8655
|
} finally {
|
|
8656
|
+
if (current) {
|
|
8657
|
+
clearInterval(current);
|
|
8658
|
+
stamp();
|
|
8659
|
+
}
|
|
8643
8660
|
watch.stop();
|
|
8644
8661
|
await relaying;
|
|
8645
8662
|
await relay?.close();
|
|
@@ -8780,7 +8797,7 @@ var tasking = /* @__PURE__ */ __name((context, warn) => {
|
|
|
8780
8797
|
};
|
|
8781
8798
|
}, "tasking");
|
|
8782
8799
|
|
|
8783
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8800
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/store-tables-command.js
|
|
8784
8801
|
import { existsSync as existsSync9 } from "node:fs";
|
|
8785
8802
|
var PATH = "store tables list";
|
|
8786
8803
|
var STORE_TABLES_QUERY = {
|
|
@@ -8823,7 +8840,7 @@ var storeTablesCommand = /* @__PURE__ */ __name((owner) => {
|
|
|
8823
8840
|
return tables;
|
|
8824
8841
|
}, "storeTablesCommand");
|
|
8825
8842
|
|
|
8826
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
8843
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
|
|
8827
8844
|
var SEARCH_INDEXES = ["messages_fts", "chats_fts", "identities_fts"];
|
|
8828
8845
|
var WORD_INDEX = "message_words";
|
|
8829
8846
|
var schemaOf = /* @__PURE__ */ __name((database) => {
|
|
@@ -9067,7 +9084,8 @@ var inspect = /* @__PURE__ */ __name((path) => reading(path, (database) => {
|
|
|
9067
9084
|
...stems ? [["message_stems", indexIntegrity(database, "message_stems", 0)]] : [],
|
|
9068
9085
|
...schema.version > 0 ? [["attachment_words", indexIntegrity(database, "attachment_words", 0)]] : [],
|
|
9069
9086
|
...schema.version >= 68 ? [["crm_file_words", indexIntegrity(database, "crm_file_words", 0)]] : [],
|
|
9070
|
-
...schema.version >= 70 ? [["tracker_item_words", indexIntegrity(database, "tracker_item_words", 0)]] : []
|
|
9087
|
+
...schema.version >= 70 ? [["tracker_item_words", indexIntegrity(database, "tracker_item_words", 0)]] : [],
|
|
9088
|
+
...schema.version >= 71 ? [["content_post_words", indexIntegrity(database, "content_post_words", 0)]] : []
|
|
9071
9089
|
]);
|
|
9072
9090
|
const size = bytesOf2(path) + bytesOf2(`${path}-wal`);
|
|
9073
9091
|
const { bavail, bsize } = statfsSync2(dirname3(path));
|
|
@@ -9235,7 +9253,7 @@ var reindexCommand = /* @__PURE__ */ __name((owner) => destroysNothing(annotate(
|
|
|
9235
9253
|
throw new CliError("validation_error", `the store is behind this build \u2014 \`${lineOf(this, "store migrate")}\` first`);
|
|
9236
9254
|
}
|
|
9237
9255
|
resetSearchIndex(database);
|
|
9238
|
-
const fileTexts = resetAttachmentWords(database) + resetCrmFileWords(database) + resetTrackerItemWords(database);
|
|
9256
|
+
const fileTexts = resetAttachmentWords(database) + resetCrmFileWords(database) + resetTrackerItemWords(database) + resetContentPostWords(database);
|
|
9239
9257
|
const words = buildWordIndex(database, (note) => renderer.note(note));
|
|
9240
9258
|
return {
|
|
9241
9259
|
path,
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__name
|
|
5
5
|
} from "./chunk-ZVVMGPBJ.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/mcp/bot/instructions.js
|
|
8
8
|
var botInstructions = /* @__PURE__ */ __name(({ command, name, profile, writes, skill }) => [
|
|
9
9
|
`The owner's ${name} bot "${profile}", through the official Bot API \u2014 not the owner's personal account. What it writes, people see as the bot.`,
|
|
10
10
|
"Use these tools to read the chats this bot is in, find a message or a person, and \u2014 when the profile allows \u2014 write as the bot.",
|
|
@@ -5,16 +5,16 @@ import {
|
|
|
5
5
|
backoffMs,
|
|
6
6
|
realSleep,
|
|
7
7
|
wallClock
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-PX5XI2UR.js";
|
|
9
9
|
import {
|
|
10
10
|
CliError,
|
|
11
11
|
isCliError
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-3JZNNESS.js";
|
|
13
13
|
import {
|
|
14
14
|
__name
|
|
15
15
|
} from "./chunk-ZVVMGPBJ.js";
|
|
16
16
|
|
|
17
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
17
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/http/body.js
|
|
18
18
|
var interrupted = /* @__PURE__ */ __name((signal) => isCliError(signal.reason) ? signal.reason : new CliError(signal.reason instanceof Error && signal.reason.name === "TimeoutError" ? "timeout" : "cancelled", "HTTP response read was interrupted"), "interrupted");
|
|
19
19
|
var checked = /* @__PURE__ */ __name((signal) => {
|
|
20
20
|
if (signal?.aborted)
|
|
@@ -99,7 +99,7 @@ var readJsonResponse = /* @__PURE__ */ __name(async (response, options) => {
|
|
|
99
99
|
}
|
|
100
100
|
}, "readJsonResponse");
|
|
101
101
|
|
|
102
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
102
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/http/hosts.js
|
|
103
103
|
var LABEL = "[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?";
|
|
104
104
|
var HOST_PATTERN = new RegExp(`^(?:${LABEL}(?:\\.${LABEL})*|\\*\\.${LABEL}(?:\\.${LABEL})+)$`);
|
|
105
105
|
var hostProblems = /* @__PURE__ */ __name((hosts) => [
|
|
@@ -111,7 +111,7 @@ var hostCovered = /* @__PURE__ */ __name((hostname, hosts) => {
|
|
|
111
111
|
return hosts.some((host) => host.startsWith("*.") ? name.endsWith(host.slice(1)) : name === host);
|
|
112
112
|
}, "hostCovered");
|
|
113
113
|
|
|
114
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
114
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/http/fetch.js
|
|
115
115
|
var HOST_FETCH_TIMEOUT_MS = 3e4;
|
|
116
116
|
var REDIRECTS = 5;
|
|
117
117
|
var REDIRECT_STATUSES = /* @__PURE__ */ new Set([301, 302, 303, 307, 308]);
|
|
@@ -146,6 +146,17 @@ var checked2 = /* @__PURE__ */ __name((url, hosts) => {
|
|
|
146
146
|
throw undeclared(url);
|
|
147
147
|
return url;
|
|
148
148
|
}, "checked");
|
|
149
|
+
var ENCODED_SLASH = /%2f|%5c/i;
|
|
150
|
+
var scopeOf = /* @__PURE__ */ __name((scope) => {
|
|
151
|
+
if (scope === void 0)
|
|
152
|
+
return void 0;
|
|
153
|
+
if (!URL.canParse(scope))
|
|
154
|
+
throw new CliError("configuration_error", `credentialScope ${scope} is not a URL`);
|
|
155
|
+
const { origin, pathname } = new URL(scope);
|
|
156
|
+
const prefix = pathname.endsWith("/") ? pathname : `${pathname}/`;
|
|
157
|
+
return (url) => url.origin === origin && (url.pathname === pathname || url.pathname.startsWith(prefix)) && !ENCODED_SLASH.test(url.pathname);
|
|
158
|
+
}, "scopeOf");
|
|
159
|
+
var signedHeaders = /* @__PURE__ */ __name((headers) => CREDENTIAL_HEADERS.some((name) => headers.has(name)), "signedHeaders");
|
|
149
160
|
var NOT_SENT = /* @__PURE__ */ new Set(["EAI_AGAIN", "ENOTFOUND", "ECONNREFUSED"]);
|
|
150
161
|
var neverSent = /* @__PURE__ */ __name((error) => {
|
|
151
162
|
for (let at = error, depth = 0; at instanceof Error && depth < 4; at = at.cause, depth++) {
|
|
@@ -160,6 +171,7 @@ var hostFetch = /* @__PURE__ */ __name((options) => {
|
|
|
160
171
|
if (problems.length > 0)
|
|
161
172
|
throw new CliError("configuration_error", problems.join("; "));
|
|
162
173
|
const { hosts, fetch: send = globalThis.fetch, timeoutMs = HOST_FETCH_TIMEOUT_MS, redirects = REDIRECTS } = options;
|
|
174
|
+
const inScope = scopeOf(options.credentialScope);
|
|
163
175
|
return async (input, init = {}) => {
|
|
164
176
|
const request = input instanceof Request ? input : void 0;
|
|
165
177
|
let url = checked2(new URL(request?.url ?? String(input)), hosts);
|
|
@@ -170,6 +182,10 @@ var hostFetch = /* @__PURE__ */ __name((options) => {
|
|
|
170
182
|
let method = (init.method ?? request?.method ?? "GET").toUpperCase();
|
|
171
183
|
let body = init.body ?? request?.body ?? void 0;
|
|
172
184
|
const headers = new Headers(init.headers ?? request?.headers);
|
|
185
|
+
if (inScope && signedHeaders(headers) && !inScope(url))
|
|
186
|
+
throw new CliError("configuration_error", `the sign-in goes only under ${options.credentialScope}, not ${url.origin}${url.pathname}`, {
|
|
187
|
+
sent: false
|
|
188
|
+
});
|
|
173
189
|
let answered = false;
|
|
174
190
|
try {
|
|
175
191
|
let response = await send(input, { ...init, signal, ...follow ? { redirect: "manual" } : {} });
|
|
@@ -190,7 +206,7 @@ var hostFetch = /* @__PURE__ */ __name((options) => {
|
|
|
190
206
|
headers.delete("content-length");
|
|
191
207
|
} else if (body instanceof ReadableStream)
|
|
192
208
|
throw new CliError("invalid_response", `${url.hostname} redirected a streamed body, which cannot be sent again`);
|
|
193
|
-
if (next.origin !== url.origin)
|
|
209
|
+
if (inScope ? !inScope(next) : next.origin !== url.origin)
|
|
194
210
|
for (const name of CREDENTIAL_HEADERS)
|
|
195
211
|
headers.delete(name);
|
|
196
212
|
url = next;
|
|
@@ -213,7 +229,7 @@ var hostFetch = /* @__PURE__ */ __name((options) => {
|
|
|
213
229
|
};
|
|
214
230
|
}, "hostFetch");
|
|
215
231
|
|
|
216
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
232
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/http/index.js
|
|
217
233
|
var parseRetryAfter = /* @__PURE__ */ __name((header, now) => {
|
|
218
234
|
if (!header)
|
|
219
235
|
return void 0;
|
|
@@ -305,7 +321,7 @@ var retrying = /* @__PURE__ */ __name((send, options = {}) => {
|
|
|
305
321
|
};
|
|
306
322
|
}, "retrying");
|
|
307
323
|
|
|
308
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
324
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.726.0_@wirecat+cli-base@0.129.0_commander@15.0.0_esbuild@0.28.2_typ_3f4b9568bff5aeba8fd797c766b422a4/node_modules/@wirecat/cli-core/dist/models/endpoint.js
|
|
309
325
|
var endpoint = /* @__PURE__ */ __name((value) => {
|
|
310
326
|
try {
|
|
311
327
|
const url = new URL(value);
|