@wirecat/tg-cli 0.107.0 → 0.109.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/dist/bin/tg.js +2 -2
- package/dist/bundle/{adapter-PN5AXCJ7.js → adapter-6JLFYFL5.js} +45 -44
- package/dist/bundle/{all-profiles-SDHNKZQQ.js → all-profiles-X7Y3T5S4.js} +8 -8
- package/dist/bundle/{anthropic-F3BXQLYB.js → anthropic-LGVXAADT.js} +5 -5
- package/dist/bundle/{app-server-XDKMWVCD.js → app-server-UI3AFSJX.js} +40 -39
- package/dist/bundle/{bot-api-YXJL4CEV.js → bot-api-TQYRNYJQ.js} +46 -45
- package/dist/bundle/{bot-history-SDLHR7PV.js → bot-history-DDNTNMNB.js} +15 -15
- package/dist/bundle/{bun-SMH7PKUS.js → bun-WXGS6HML.js} +2 -2
- package/dist/bundle/{bun-sqlite-KB6PSTWH.js → bun-sqlite-M6JEXKRT.js} +4 -4
- package/dist/bundle/{chunk-NCWB3KXP.js → chunk-25VC6U3A.js} +1 -1
- package/dist/bundle/{chunk-NUVHRCUK.js → chunk-2ILQYCBY.js} +390 -291
- package/dist/bundle/{chunk-X7M7YZPF.js → chunk-3PEZWXKO.js} +6 -6
- package/dist/bundle/{chunk-YSDA3EWT.js → chunk-4R4AH6FM.js} +117 -94
- package/dist/bundle/{chunk-TEHAIU6I.js → chunk-5SUFMBU5.js} +44 -44
- package/dist/bundle/chunk-76C5SSMR.js +379 -0
- package/dist/bundle/{chunk-STGY3EAZ.js → chunk-7AJ2IESO.js} +1 -1
- package/dist/bundle/{chunk-3UEFJ75D.js → chunk-7T7ILNCU.js} +2 -2
- package/dist/bundle/{chunk-O7VQHFMZ.js → chunk-AD3QPYI3.js} +2 -2
- package/dist/bundle/{chunk-IY7IEM56.js → chunk-AGVKIJB7.js} +6 -6
- package/dist/bundle/{chunk-OIHAM73W.js → chunk-BESIMQ5U.js} +1 -1
- package/dist/bundle/{chunk-CJJVFGFX.js → chunk-BHPCZCX7.js} +2 -2
- package/dist/bundle/{chunk-GJS26XEB.js → chunk-BZIZLEJN.js} +4 -4
- package/dist/bundle/{chunk-REJM262E.js → chunk-C3RX3UOE.js} +11 -11
- package/dist/bundle/{chunk-WXIGT6FY.js → chunk-CH2ESVV5.js} +22 -22
- package/dist/bundle/{chunk-DFZBGU4G.js → chunk-CHI6D4D6.js} +4 -4
- package/dist/bundle/{chunk-BYDDYOF4.js → chunk-CVLDXFRP.js} +8 -8
- package/dist/bundle/{chunk-MFS52LTZ.js → chunk-DLAFGSTN.js} +1 -1
- package/dist/bundle/{chunk-P4A27ETD.js → chunk-DO33KAMM.js} +94 -59
- package/dist/bundle/{chunk-GGAG3G7B.js → chunk-DZVYGBZB.js} +79 -56
- package/dist/bundle/{chunk-WAGDZB62.js → chunk-GUFM5RLW.js} +2 -2
- package/dist/bundle/{chunk-LA2OUJK5.js → chunk-IGIPIO4J.js} +11 -11
- package/dist/bundle/{chunk-5QBTHR57.js → chunk-INYO2QFW.js} +3 -3
- package/dist/bundle/{chunk-VMKPRAIB.js → chunk-IULYECPC.js} +12 -12
- package/dist/bundle/{chunk-DBZVF73F.js → chunk-IV2QWSPG.js} +2 -2
- package/dist/bundle/{chunk-YA44IPCS.js → chunk-KHKC236O.js} +2 -2
- package/dist/bundle/{chunk-TKCZYJAT.js → chunk-M62LF3QE.js} +2140 -1648
- package/dist/bundle/{chunk-RGNKRI5T.js → chunk-MF6NKU3Z.js} +81 -30
- package/dist/bundle/{chunk-MOZX3JX3.js → chunk-N56WXUCW.js} +2 -2
- package/dist/bundle/{chunk-T4SDOYPY.js → chunk-N5FSRC6H.js} +117 -70
- package/dist/bundle/{chunk-FG2QTYEF.js → chunk-NAVNCM5K.js} +1 -1
- package/dist/bundle/{chunk-NMTFZNFU.js → chunk-OHLMHBDI.js} +28 -28
- package/dist/bundle/{chunk-P5UG655O.js → chunk-P55L4S6N.js} +3 -3
- package/dist/bundle/{chunk-JZOXKRDG.js → chunk-P57R2P75.js} +7 -7
- package/dist/bundle/{chunk-BMXGEQDA.js → chunk-P5ILJ7MN.js} +5 -5
- package/dist/bundle/{chunk-PYRJO6B3.js → chunk-QQF7RDLR.js} +49 -24
- package/dist/bundle/{chunk-TFV4UPQZ.js → chunk-RD2NLJSU.js} +16 -4
- package/dist/bundle/{chunk-KROO42KC.js → chunk-S7B6MTXX.js} +6 -6
- package/dist/bundle/{chunk-NSQL3YRD.js → chunk-SH63Q4QR.js} +22 -22
- package/dist/bundle/{chunk-JAWXJILO.js → chunk-TMXNMO66.js} +3 -3
- package/dist/bundle/{chunk-44UANKAI.js → chunk-UIPBAT2T.js} +31 -14
- package/dist/bundle/{chunk-53RW4KLL.js → chunk-UUQ3BH2Z.js} +2 -2
- package/dist/bundle/{chunk-VMU4SGCE.js → chunk-VFVMB3NV.js} +8 -6
- package/dist/bundle/{chunk-AWBJSYX6.js → chunk-VYR2IIWW.js} +1 -1
- package/dist/bundle/{chunk-53QVFV34.js → chunk-WHYS6OSG.js} +2 -2
- package/dist/bundle/{chunk-WS3S7DXT.js → chunk-WNTXIQMB.js} +2 -2
- package/dist/bundle/{chunk-P5KMLJQR.js → chunk-XJVGCCQE.js} +666 -782
- package/dist/bundle/{chunk-67SRVSPU.js → chunk-XMMWKHNY.js} +26 -9
- package/dist/bundle/{chunk-A4DS5ANQ.js → chunk-YXCQ4DLZ.js} +1 -1
- package/dist/bundle/{chunk-465FPHSG.js → chunk-YYOIULA2.js} +8 -8
- package/dist/bundle/{chunk-WFG7KFM4.js → chunk-ZFMS5G4H.js} +2 -2
- package/dist/bundle/{chunk-BGVODG6P.js → chunk-ZHP44EML.js} +3 -3
- package/dist/bundle/{chunk-6FSG6QZH.js → chunk-ZMZKZL3Y.js} +1 -1
- package/dist/bundle/{chunk-H4LIQVPN.js → chunk-ZUOS7QUB.js} +11 -11
- package/dist/bundle/command-contract-E2MWR3T3.js +32 -0
- package/dist/bundle/{decode-WEP3HD56.js → decode-RKPOGPBE.js} +19 -17
- package/dist/bundle/{echarts-MRMILSAF.js → echarts-H5QQRBHI.js} +2 -2
- package/dist/bundle/{embed-LCLTUVUD.js → embed-7TVAPNP7.js} +5 -5
- package/dist/bundle/{embedder-O4WNEXUC.js → embedder-YOOHWWN6.js} +8 -8
- package/dist/bundle/{entry-7HDX6BDR.js → entry-SAKW5HEZ.js} +5 -5
- package/dist/bundle/{first-run-M7YVVQJS.js → first-run-C744N572.js} +9 -9
- package/dist/bundle/first-screen-7GKUEIWS.js +30 -0
- package/dist/bundle/{identity-EEMHQOTN.js → identity-NRWTZIQ4.js} +3 -3
- package/dist/bundle/{instructions-YIH3J4TI.js → instructions-6LWRAW47.js} +1 -1
- package/dist/bundle/{mcp-OQBZXELQ.js → mcp-WSGVVZWI.js} +2 -2
- package/dist/bundle/{node-YWT7RFN6.js → node-XN4PIVWW.js} +2 -2
- package/dist/bundle/node-sqlite-PCBGROGQ.js +62 -0
- package/dist/bundle/{oauth-CADZB7TT.js → oauth-PX6NGHUV.js} +6 -6
- package/dist/bundle/{open-AMRU27KK.js → open-BKJGJ6GX.js} +3 -3
- package/dist/bundle/openai-MJP7CZXP.js +250 -0
- package/dist/bundle/{process-JC76J5UD.js → process-4PRR3MLT.js} +1 -1
- package/dist/bundle/{program-FI6MTY2V.js → program-7YZUO42B.js} +48 -47
- package/dist/bundle/{prompt-SPYTHKHN.js → prompt-CILSZC2R.js} +4 -4
- package/dist/bundle/{proxy-transport-YSBYG26I.js → proxy-transport-FWGKTYBL.js} +4 -4
- package/dist/bundle/{recognize-G5VVM6MU.js → recognize-AVFDJAIL.js} +5 -3
- package/dist/bundle/{remote-Z3HW42CH.js → remote-2VYXGOM4.js} +6 -6
- package/dist/bundle/{rerank-QJ5NLZUU.js → rerank-6FU2JPCD.js} +6 -6
- package/dist/bundle/{serve-3I4C6Y5X.js → serve-3YQOHBR6.js} +8 -8
- package/dist/bundle/server-S2K4YDDG.js +56 -0
- package/dist/bundle/{server-2L4BONHN.js → server-TPK3LNEX.js} +32 -31
- package/dist/bundle/{state-IXZYPH46.js → state-LLUNBLZE.js} +5 -5
- package/dist/bundle/{store-KS4XIA2R.js → store-27FQ743G.js} +10 -10
- package/dist/bundle/store-maintenance-command-AFJMKEBK.js +45 -0
- package/dist/bundle/tg.js +4 -4
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/dist/bundle/command-contract-B4DA4MXP.js +0 -32
- package/dist/bundle/first-screen-MXW3UZFB.js +0 -30
- package/dist/bundle/node-sqlite-LVHTONMA.js +0 -46
- package/dist/bundle/server-7TJ337SR.js +0 -55
- package/dist/bundle/store-maintenance-command-I3L24P22.js +0 -44
- /package/dist/bundle/{chunk-O5EHUB2V.js → chunk-62EDJKGP.js} +0 -0
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
id,
|
|
6
6
|
text,
|
|
7
7
|
time
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-RD2NLJSU.js";
|
|
9
9
|
import {
|
|
10
10
|
currentCaller,
|
|
11
11
|
endpointTemplate,
|
|
@@ -16,19 +16,19 @@ import {
|
|
|
16
16
|
providerErrorKey,
|
|
17
17
|
renderEvent,
|
|
18
18
|
runContextOf
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-CVLDXFRP.js";
|
|
20
20
|
import {
|
|
21
21
|
permissionCeiling
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-P55L4S6N.js";
|
|
23
23
|
import {
|
|
24
24
|
envName,
|
|
25
25
|
readOnlyLockOf,
|
|
26
26
|
readOnlyRefusal
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-7T7ILNCU.js";
|
|
28
28
|
import {
|
|
29
29
|
filesPresent,
|
|
30
30
|
sharedModelsDirectory
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-IULYECPC.js";
|
|
32
32
|
import {
|
|
33
33
|
FIELD_TYPES,
|
|
34
34
|
QUERY_BACKENDS,
|
|
@@ -37,13 +37,13 @@ import {
|
|
|
37
37
|
TASK_STATES,
|
|
38
38
|
TASK_TYPES,
|
|
39
39
|
describeQuery
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-DO33KAMM.js";
|
|
41
41
|
import {
|
|
42
42
|
sharedConfigPath
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-AGVKIJB7.js";
|
|
44
44
|
import {
|
|
45
45
|
storePath
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-UUQ3BH2Z.js";
|
|
47
47
|
import {
|
|
48
48
|
configFilePath,
|
|
49
49
|
createRecordLog,
|
|
@@ -56,7 +56,7 @@ import {
|
|
|
56
56
|
saveConfigFile,
|
|
57
57
|
singleLine,
|
|
58
58
|
writeSecurely
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-N5FSRC6H.js";
|
|
60
60
|
import {
|
|
61
61
|
CliError,
|
|
62
62
|
MAX_NEXT_STEPS,
|
|
@@ -98,12 +98,12 @@ import {
|
|
|
98
98
|
union,
|
|
99
99
|
unknown,
|
|
100
100
|
writes
|
|
101
|
-
} from "./chunk-
|
|
101
|
+
} from "./chunk-XMMWKHNY.js";
|
|
102
102
|
import {
|
|
103
103
|
__name
|
|
104
104
|
} from "./chunk-ZVVMGPBJ.js";
|
|
105
105
|
|
|
106
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
106
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/commands/registry.js
|
|
107
107
|
var labels = /* @__PURE__ */ new WeakMap();
|
|
108
108
|
var annotate = /* @__PURE__ */ __name((command, meta) => {
|
|
109
109
|
labels.set(command, { ...labels.get(command), ...meta });
|
|
@@ -3604,7 +3604,7 @@ __name(useColor, "useColor");
|
|
|
3604
3604
|
// node_modules/.pnpm/commander@15.0.0/node_modules/commander/index.js
|
|
3605
3605
|
var program = new Command();
|
|
3606
3606
|
|
|
3607
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
3607
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/commands/contracts.js
|
|
3608
3608
|
import { isDeepStrictEqual } from "node:util";
|
|
3609
3609
|
var protectedCommands = /* @__PURE__ */ new WeakMap();
|
|
3610
3610
|
var hasSharedContract = /* @__PURE__ */ __name((command) => protectedCommands.has(command), "hasSharedContract");
|
|
@@ -3806,7 +3806,7 @@ var customizeSharedCommand = /* @__PURE__ */ __name((reference2, reason, build,
|
|
|
3806
3806
|
return command;
|
|
3807
3807
|
}, "customizeSharedCommand");
|
|
3808
3808
|
|
|
3809
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
3809
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/commands/document.js
|
|
3810
3810
|
var argumentInfoSchema = object({
|
|
3811
3811
|
name: string(),
|
|
3812
3812
|
required: boolean(),
|
|
@@ -3879,7 +3879,7 @@ var commandsDocumentSchema = strictObject({
|
|
|
3879
3879
|
exit_codes: record(string(), pipe(number(), integer()))
|
|
3880
3880
|
});
|
|
3881
3881
|
|
|
3882
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
3882
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.67.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/commands/index.js
|
|
3883
3883
|
var refuseJoinedPath = /* @__PURE__ */ __name((root, args, prefix = []) => {
|
|
3884
3884
|
let command = root;
|
|
3885
3885
|
const path2 = [];
|
|
@@ -3897,7 +3897,7 @@ var refuseJoinedPath = /* @__PURE__ */ __name((root, args, prefix = []) => {
|
|
|
3897
3897
|
}
|
|
3898
3898
|
}, "refuseJoinedPath");
|
|
3899
3899
|
|
|
3900
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3900
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/sends/guarded.js
|
|
3901
3901
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
3902
3902
|
var sentIds = /* @__PURE__ */ __name((typed, message) => ({
|
|
3903
3903
|
messageId: message.id,
|
|
@@ -4003,7 +4003,7 @@ var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled2 =
|
|
|
4003
4003
|
}, "guardedWrite");
|
|
4004
4004
|
var codeOf = /* @__PURE__ */ __name((error) => typeof error?.code === "string" ? error.code : "unknown", "codeOf");
|
|
4005
4005
|
|
|
4006
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4006
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/result-fields.js
|
|
4007
4007
|
var named = /* @__PURE__ */ __name((work) => {
|
|
4008
4008
|
try {
|
|
4009
4009
|
return work();
|
|
@@ -4030,7 +4030,7 @@ var projectFields2 = /* @__PURE__ */ __name((value, fields) => named(() => {
|
|
|
4030
4030
|
return projectFields(value, fields);
|
|
4031
4031
|
}), "projectFields");
|
|
4032
4032
|
|
|
4033
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4033
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/execution.js
|
|
4034
4034
|
var DEFAULT_COMMAND_MS = 3e4;
|
|
4035
4035
|
var DEFAULT_COOPERATIVE_MS = 5 * 6e4;
|
|
4036
4036
|
var DEFAULT_SYNC_MS = 15 * 6e4;
|
|
@@ -4212,7 +4212,7 @@ var withAbort = /* @__PURE__ */ __name(async (signal, body) => {
|
|
|
4212
4212
|
}
|
|
4213
4213
|
}, "withAbort");
|
|
4214
4214
|
|
|
4215
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4215
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/sends/permissions.js
|
|
4216
4216
|
var LEVELS = ["deny", "readonly", "ask", "allow"];
|
|
4217
4217
|
var DANGEROUS = /* @__PURE__ */ new Set(["messages.delete", "bot.messages.delete", "topics.delete", "chats.delete", "chats.clear"]);
|
|
4218
4218
|
var skipFlagFor = /* @__PURE__ */ __name((key) => DANGEROUS.has(key) ? "--allow-dangerous" : "--yes", "skipFlagFor");
|
|
@@ -4601,7 +4601,7 @@ var assertRetentionEvidenceRead = /* @__PURE__ */ __name((permissions) => {
|
|
|
4601
4601
|
}
|
|
4602
4602
|
}, "assertRetentionEvidenceRead");
|
|
4603
4603
|
|
|
4604
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4604
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/messenger/accounts.js
|
|
4605
4605
|
import { existsSync, readdirSync, readFileSync } from "node:fs";
|
|
4606
4606
|
import { join } from "node:path";
|
|
4607
4607
|
var accountFileFor = /* @__PURE__ */ __name((app, profile, env) => join(resolvePaths({ appName: app.appName, prefix: app.envPrefix, env }).state, "accounts", `${profile}.json`), "accountFileFor");
|
|
@@ -4623,7 +4623,7 @@ var profilesWithAccounts = /* @__PURE__ */ __name((app, env) => {
|
|
|
4623
4623
|
}, "profilesWithAccounts");
|
|
4624
4624
|
var profilesHere = /* @__PURE__ */ __name((app, configured, env) => [.../* @__PURE__ */ new Set([...configured, ...profilesWithAccounts(app, env)])].sort(), "profilesHere");
|
|
4625
4625
|
|
|
4626
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4626
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/output-detail.js
|
|
4627
4627
|
var RARELY_SET = ["editedAt", "replyTo", "forwardedFrom", "reactions"];
|
|
4628
4628
|
var BRIEF = ["locator", "chatTitle", "timestamp", "senderName", "excerpt", "score"];
|
|
4629
4629
|
var isHit = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && typeof value.locator === "string" && typeof value.text === "string", "isHit");
|
|
@@ -4653,7 +4653,7 @@ var atDetail = /* @__PURE__ */ __name((value, detail = "default") => {
|
|
|
4653
4653
|
return value;
|
|
4654
4654
|
}, "atDetail");
|
|
4655
4655
|
|
|
4656
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4656
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/output.js
|
|
4657
4657
|
var resolveOutput = /* @__PURE__ */ __name(({ json, jsonl, quiet, streams = processStreams, tty, color, fields, hitDetail, env = process.env, capture } = {}) => {
|
|
4658
4658
|
const interactive = tty ?? process.stdout.isTTY === true;
|
|
4659
4659
|
const format = jsonl ? "jsonl" : json || !interactive ? "json" : "pretty";
|
|
@@ -4701,7 +4701,7 @@ var silence = /* @__PURE__ */ __name((renderer) => ({
|
|
|
4701
4701
|
}, "warn")
|
|
4702
4702
|
}), "silence");
|
|
4703
4703
|
|
|
4704
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4704
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/log-events.js
|
|
4705
4705
|
var CORE_LOG_EVENTS = defineLogEvents([
|
|
4706
4706
|
{ id: "provider.request", meaning: "a request went to the messenger", keys: ["operation"] },
|
|
4707
4707
|
{ id: "provider.response", meaning: "the messenger answered the request, or it failed", keys: ["operation"] },
|
|
@@ -4735,7 +4735,7 @@ var DIAGNOSTIC_LOG_EVENTS = {
|
|
|
4735
4735
|
cache: "cache.answered"
|
|
4736
4736
|
};
|
|
4737
4737
|
|
|
4738
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4738
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/log-keys.js
|
|
4739
4739
|
var snake2 = /* @__PURE__ */ __name((key) => key.replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`), "snake");
|
|
4740
4740
|
var camel = /* @__PURE__ */ __name((key) => key.replace(/_([a-z0-9])/g, (_, letter) => letter.toUpperCase()), "camel");
|
|
4741
4741
|
var renamed = /* @__PURE__ */ __name((record2, name) => Object.fromEntries(Object.entries(record2).map(([key, value]) => [name(key), value])), "renamed");
|
|
@@ -4748,13 +4748,13 @@ var snakeLogger = /* @__PURE__ */ __name((logger) => ({
|
|
|
4748
4748
|
error: /* @__PURE__ */ __name((event, message) => logger.error(logAttributes(event), message), "error")
|
|
4749
4749
|
}), "snakeLogger");
|
|
4750
4750
|
|
|
4751
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4751
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/run.js
|
|
4752
4752
|
import { randomUUID } from "node:crypto";
|
|
4753
4753
|
import { appendFileSync, mkdirSync, readdirSync as readdirSync2, readFileSync as readFileSync2, rmSync, statSync, writeFileSync } from "node:fs";
|
|
4754
4754
|
import { userInfo } from "node:os";
|
|
4755
4755
|
import { join as join2, sep } from "node:path";
|
|
4756
4756
|
|
|
4757
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4757
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/log-attributes.js
|
|
4758
4758
|
var diagnostic = {
|
|
4759
4759
|
event: true,
|
|
4760
4760
|
operation: true,
|
|
@@ -4824,7 +4824,7 @@ var LOG_ATTRIBUTES = [
|
|
|
4824
4824
|
...new Set([...Object.keys(diagnostic), ...Object.keys(send), ...background, ...crash, ...dropped].map((key) => Object.keys(logAttributes({ [key]: true }))[0]))
|
|
4825
4825
|
].sort();
|
|
4826
4826
|
|
|
4827
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
4827
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/run.js
|
|
4828
4828
|
var KEEP_RUNS_FOR_DAYS = 30;
|
|
4829
4829
|
var KEEP_SUCCESSFUL_RUNS_FOR_DAYS = 7;
|
|
4830
4830
|
var RUNS_SIZE_LIMIT_MB = 200;
|
|
@@ -5177,7 +5177,7 @@ var metadataOf = /* @__PURE__ */ __name((parsed) => {
|
|
|
5177
5177
|
};
|
|
5178
5178
|
}, "metadataOf");
|
|
5179
5179
|
|
|
5180
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5180
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/scope.js
|
|
5181
5181
|
import { AsyncLocalStorage as AsyncLocalStorage2 } from "node:async_hooks";
|
|
5182
5182
|
import { randomBytes } from "node:crypto";
|
|
5183
5183
|
var scopes = new AsyncLocalStorage2();
|
|
@@ -5215,7 +5215,7 @@ var attempts = new AsyncLocalStorage2();
|
|
|
5215
5215
|
var withAttempt = /* @__PURE__ */ __name((attempt, work) => attempts.run(attempt, work), "withAttempt");
|
|
5216
5216
|
var currentAttempt = /* @__PURE__ */ __name(() => attempts.getStore(), "currentAttempt");
|
|
5217
5217
|
|
|
5218
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5218
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/recording.js
|
|
5219
5219
|
var recorded = /* @__PURE__ */ __name(async (options, body) => {
|
|
5220
5220
|
const recording = startRecording(options);
|
|
5221
5221
|
try {
|
|
@@ -5400,7 +5400,7 @@ var partialOutcome = /* @__PURE__ */ __name((answer) => {
|
|
|
5400
5400
|
return void 0;
|
|
5401
5401
|
}, "partialOutcome");
|
|
5402
5402
|
|
|
5403
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5403
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/deadline.js
|
|
5404
5404
|
var withDeadline = /* @__PURE__ */ __name(async (ms, closeables, body) => {
|
|
5405
5405
|
if (ms === void 0)
|
|
5406
5406
|
return body();
|
|
@@ -5426,7 +5426,7 @@ var withDeadline = /* @__PURE__ */ __name(async (ms, closeables, body) => {
|
|
|
5426
5426
|
}
|
|
5427
5427
|
}, "withDeadline");
|
|
5428
5428
|
|
|
5429
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5429
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/profile.js
|
|
5430
5430
|
var asFirstWord = /* @__PURE__ */ __name((profile) => `${profile} `, "asFirstWord");
|
|
5431
5431
|
var PLAIN_NAME = /^[A-Za-z0-9][A-Za-z0-9._-]*$/;
|
|
5432
5432
|
var isProfileName = /* @__PURE__ */ __name((word) => PLAIN_NAME.test(word), "isProfileName");
|
|
@@ -5495,10 +5495,10 @@ var sampleCommand = /* @__PURE__ */ __name((commands) => {
|
|
|
5495
5495
|
return void 0;
|
|
5496
5496
|
}, "sampleCommand");
|
|
5497
5497
|
|
|
5498
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5498
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/settings.js
|
|
5499
5499
|
import { existsSync as existsSync3 } from "node:fs";
|
|
5500
5500
|
|
|
5501
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5501
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/models/endpoint.js
|
|
5502
5502
|
var endpoint = /* @__PURE__ */ __name((value) => {
|
|
5503
5503
|
try {
|
|
5504
5504
|
const url2 = new URL(value);
|
|
@@ -5508,7 +5508,7 @@ var endpoint = /* @__PURE__ */ __name((value) => {
|
|
|
5508
5508
|
}
|
|
5509
5509
|
}, "endpoint");
|
|
5510
5510
|
|
|
5511
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5511
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/models/settings.js
|
|
5512
5512
|
var MODEL_FIELDS = ["provider", "model", "base_url"];
|
|
5513
5513
|
var modelSettingsShape = record(pipe(string(), regex(/^[a-z][a-z0-9-]*$/)), strictObject({
|
|
5514
5514
|
provider: optional(picklist(["off", "openai", "anthropic"])),
|
|
@@ -5577,7 +5577,7 @@ var modelTarget = /* @__PURE__ */ __name((settings, purpose) => {
|
|
|
5577
5577
|
};
|
|
5578
5578
|
}, "modelTarget");
|
|
5579
5579
|
|
|
5580
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5580
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/analysis/settings.js
|
|
5581
5581
|
var model = pipe(string(), trim(), minLength(1), maxLength(200));
|
|
5582
5582
|
var url = pipe(string(), check(endpoint, "use an HTTP/S endpoint without credentials, query or fragment"));
|
|
5583
5583
|
var AI_FIELDS = {
|
|
@@ -5621,7 +5621,7 @@ var resolveAISettings = /* @__PURE__ */ __name((prefix, layers, env) => {
|
|
|
5621
5621
|
};
|
|
5622
5622
|
}, "resolveAISettings");
|
|
5623
5623
|
|
|
5624
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5624
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/domain/duration.js
|
|
5625
5625
|
var DURATION = /^(\d+)(ms|s|m|h|d)$/;
|
|
5626
5626
|
var UNIT_MS = { ms: 1, s: 1e3, m: 6e4, h: 36e5, d: 864e5 };
|
|
5627
5627
|
var parseDuration = /* @__PURE__ */ __name((value, source) => {
|
|
@@ -5635,7 +5635,7 @@ var parseDuration = /* @__PURE__ */ __name((value, source) => {
|
|
|
5635
5635
|
return ms;
|
|
5636
5636
|
}, "parseDuration");
|
|
5637
5637
|
|
|
5638
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5638
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/embeddings/models.js
|
|
5639
5639
|
var huggingFace = /* @__PURE__ */ __name((repository, commit) => (name) => `https://huggingface.co/${repository}/resolve/${commit}/${name}`, "huggingFace");
|
|
5640
5640
|
var e5 = huggingFace("Xenova/multilingual-e5-small", "761b726dd34fb83930e26aab4e9ac3899aa1fa78");
|
|
5641
5641
|
var gemma = huggingFace("onnx-community/embeddinggemma-300m-ONNX", "5090578d9565bb06545b4552f76e6bc2c93e4a66");
|
|
@@ -5794,7 +5794,7 @@ var rerankModel = /* @__PURE__ */ __name((id2) => {
|
|
|
5794
5794
|
var vectorModelKey = /* @__PURE__ */ __name((model2) => `local:${model2.id}:${model2.dims}`, "vectorModelKey");
|
|
5795
5795
|
var meaningFloor = /* @__PURE__ */ __name((key) => key === "local:e5-small:384" ? 0.8 : 0, "meaningFloor");
|
|
5796
5796
|
|
|
5797
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
5797
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/config-issues.js
|
|
5798
5798
|
import { readFileSync as readFileSync3 } from "node:fs";
|
|
5799
5799
|
var isNode = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && !Array.isArray(value), "isNode");
|
|
5800
5800
|
var SECTIONS = ["personal", "bot"];
|
|
@@ -6084,7 +6084,7 @@ var readConfigFile = /* @__PURE__ */ __name((path2) => {
|
|
|
6084
6084
|
return "issue" in parsed ? { issue: publicIssue(parsed.issue) } : parsed;
|
|
6085
6085
|
}, "readConfigFile");
|
|
6086
6086
|
|
|
6087
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6087
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/default-config.js
|
|
6088
6088
|
import { existsSync as existsSync2, linkSync, mkdirSync as mkdirSync2, mkdtempSync, rmSync as rmSync2, writeFileSync as writeFileSync2 } from "node:fs";
|
|
6089
6089
|
import { dirname, join as join3 } from "node:path";
|
|
6090
6090
|
var DEFAULT_CONFIG = {
|
|
@@ -6113,7 +6113,7 @@ function ensureDefaultConfig(path2, config = DEFAULT_CONFIG) {
|
|
|
6113
6113
|
}
|
|
6114
6114
|
__name(ensureDefaultConfig, "ensureDefaultConfig");
|
|
6115
6115
|
|
|
6116
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6116
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/settings.js
|
|
6117
6117
|
var DEFAULT_LIMIT = DEFAULT_CONFIG.defaults.limit;
|
|
6118
6118
|
var DEFAULT_KEEP_RUNS_FOR_DAYS = DEFAULT_CONFIG.defaults.keep_runs_for_days;
|
|
6119
6119
|
var DEFAULT_SENDS_PER_HOUR = DEFAULT_CONFIG.defaults.sends_per_hour;
|
|
@@ -6503,7 +6503,7 @@ var given = /* @__PURE__ */ __name((value) => {
|
|
|
6503
6503
|
return trimmed === void 0 || trimmed === "" ? void 0 : trimmed;
|
|
6504
6504
|
}, "given");
|
|
6505
6505
|
|
|
6506
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6506
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/context.js
|
|
6507
6507
|
var setExitCode = /* @__PURE__ */ __name((command, code) => {
|
|
6508
6508
|
const slot = environmentOf(command).exit;
|
|
6509
6509
|
if (slot)
|
|
@@ -6610,7 +6610,7 @@ var commandPath = /* @__PURE__ */ __name((command) => {
|
|
|
6610
6610
|
return words.join(" ");
|
|
6611
6611
|
}, "commandPath");
|
|
6612
6612
|
|
|
6613
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6613
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/effects.js
|
|
6614
6614
|
var REMOTE_READ = { remote: "read", local: "read" };
|
|
6615
6615
|
var FETCH = { remote: "read", local: "write" };
|
|
6616
6616
|
var REMOTE_WRITE = { remote: "write", local: "write" };
|
|
@@ -6712,7 +6712,7 @@ var refuseUnderReadOnly = /* @__PURE__ */ __name((command, what) => {
|
|
|
6712
6712
|
throw readOnlyRefusal(lock, what);
|
|
6713
6713
|
}, "refuseUnderReadOnly");
|
|
6714
6714
|
|
|
6715
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6715
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/images/picture/models.js
|
|
6716
6716
|
import { join as join4 } from "node:path";
|
|
6717
6717
|
var clip = /* @__PURE__ */ __name((name) => `https://huggingface.co/Xenova/clip-vit-base-patch32/resolve/d15189d7028b43f1d3e65039190477f6af591c2a/${name}`, "clip");
|
|
6718
6718
|
var IMAGE_MODELS = [
|
|
@@ -6766,7 +6766,7 @@ var imageModelsDirectory = /* @__PURE__ */ __name((env = process.env) => sharedM
|
|
|
6766
6766
|
var placedImage = /* @__PURE__ */ __name((model2, directory) => model2.files.map((file) => [file, join4(directory, model2.id, file.name)]), "placedImage");
|
|
6767
6767
|
var isImageModelInstalled = /* @__PURE__ */ __name((model2, directory) => filesPresent(placedImage(model2, directory)), "isImageModelInstalled");
|
|
6768
6768
|
|
|
6769
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
6769
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/steps.js
|
|
6770
6770
|
var STEPS2 = defineSteps([
|
|
6771
6771
|
...STEPS,
|
|
6772
6772
|
{
|
|
@@ -6775,6 +6775,7 @@ var STEPS2 = defineSteps([
|
|
|
6775
6775
|
args: [
|
|
6776
6776
|
{ name: "chat", required: false },
|
|
6777
6777
|
{ name: "all", required: false },
|
|
6778
|
+
{ name: "since_time", required: false },
|
|
6778
6779
|
{ name: "background", required: false }
|
|
6779
6780
|
],
|
|
6780
6781
|
why: "the local copy is missing messages; syncing brings them in"
|
|
@@ -7032,7 +7033,7 @@ var stepLine = /* @__PURE__ */ __name((root, step) => {
|
|
|
7032
7033
|
].join(" ");
|
|
7033
7034
|
}, "stepLine");
|
|
7034
7035
|
|
|
7035
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7036
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/provider-refs.js
|
|
7036
7037
|
var HIDDEN = /* @__PURE__ */ new Set(["providerRef", "provider_ref"]);
|
|
7037
7038
|
var withoutProviderRefs = /* @__PURE__ */ __name((value) => strip(value), "withoutProviderRefs");
|
|
7038
7039
|
var strip = /* @__PURE__ */ __name((value) => {
|
|
@@ -7046,11 +7047,11 @@ var strip = /* @__PURE__ */ __name((value) => {
|
|
|
7046
7047
|
return Object.fromEntries(Object.entries(value).flatMap(([key, inner]) => HIDDEN.has(key) ? [] : [[key, strip(inner)]]));
|
|
7047
7048
|
}, "strip");
|
|
7048
7049
|
|
|
7049
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7050
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/cli/envelope.js
|
|
7050
7051
|
var answerSchema = /* @__PURE__ */ __name((item = unknown()) => union([listEnvelopeSchema(item), itemEnvelopeSchema(item)]), "answerSchema");
|
|
7051
7052
|
var capped2 = /* @__PURE__ */ __name((steps) => steps.length > 0 ? { next: steps.slice(0, MAX_NEXT_STEPS) } : {}, "capped");
|
|
7052
7053
|
var listOf = /* @__PURE__ */ __name((command, input) => {
|
|
7053
|
-
const { items, limit, has_more, cursor, paging, page, args = {}, next = [], missing, meta } = input;
|
|
7054
|
+
const { items, limit, has_more, cursor, paging, page, total, args = {}, next = [], missing, meta } = input;
|
|
7054
7055
|
const byCursor = paging === "cursor" || cursor !== void 0;
|
|
7055
7056
|
const more = has_more ? [
|
|
7056
7057
|
nextStep("page.next", {
|
|
@@ -7061,7 +7062,19 @@ var listOf = /* @__PURE__ */ __name((command, input) => {
|
|
|
7061
7062
|
] : [];
|
|
7062
7063
|
const body = {
|
|
7063
7064
|
items,
|
|
7064
|
-
page: byCursor ? {
|
|
7065
|
+
page: byCursor ? {
|
|
7066
|
+
mode: "cursor",
|
|
7067
|
+
limit,
|
|
7068
|
+
has_more,
|
|
7069
|
+
...has_more && cursor !== void 0 ? { next_cursor: cursor } : {},
|
|
7070
|
+
...total ? { total } : {}
|
|
7071
|
+
} : {
|
|
7072
|
+
mode: "page",
|
|
7073
|
+
limit,
|
|
7074
|
+
has_more,
|
|
7075
|
+
...has_more ? { next_page: (page ?? 1) + 1 } : {},
|
|
7076
|
+
...total ? { total } : {}
|
|
7077
|
+
},
|
|
7065
7078
|
...capped2([...more, ...next]),
|
|
7066
7079
|
...missing && missing.length > 0 ? { missing } : {},
|
|
7067
7080
|
...meta ? { meta } : {}
|
|
@@ -7168,7 +7181,7 @@ var printItem = /* @__PURE__ */ __name(({ renderer, format }, item) => {
|
|
|
7168
7181
|
renderer.result(item);
|
|
7169
7182
|
}, "printItem");
|
|
7170
7183
|
|
|
7171
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7184
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/store-table.js
|
|
7172
7185
|
var TABLE_KINDS = ["data", "search_index", "search_index_part", "internal"];
|
|
7173
7186
|
var storeTable = strictObject({
|
|
7174
7187
|
name: text,
|
|
@@ -7177,7 +7190,7 @@ var storeTable = strictObject({
|
|
|
7177
7190
|
bytes: optional(nullable(count))
|
|
7178
7191
|
});
|
|
7179
7192
|
|
|
7180
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7193
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/botcheck/reasons.js
|
|
7181
7194
|
var WEIGHTS = {
|
|
7182
7195
|
bot: 3,
|
|
7183
7196
|
scam: 3,
|
|
@@ -7202,7 +7215,7 @@ var LINK = /https?:\/\/|t\.me\/|www\./i;
|
|
|
7202
7215
|
var DIGITS = /\d{5,}/;
|
|
7203
7216
|
var oddName = /* @__PURE__ */ __name((name) => !name?.trim() || DIGITS.test(name) || LINK.test(name), "oddName");
|
|
7204
7217
|
|
|
7205
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7218
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/task.js
|
|
7206
7219
|
var closeSuggestion = strictObject({
|
|
7207
7220
|
as: picklist(["done", "dismissed"]),
|
|
7208
7221
|
/** The agent's name. */
|
|
@@ -7244,7 +7257,7 @@ var task = strictObject({
|
|
|
7244
7257
|
updated_at: optional(time)
|
|
7245
7258
|
});
|
|
7246
7259
|
|
|
7247
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7260
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/agenda.js
|
|
7248
7261
|
var agendaChat = strictObject({
|
|
7249
7262
|
chat: reference,
|
|
7250
7263
|
title: nullable(text),
|
|
@@ -7255,7 +7268,17 @@ var agendaChat = strictObject({
|
|
|
7255
7268
|
/** `null` when the newest message is not stored, or the messenger did not say who sent it. */
|
|
7256
7269
|
last_from_owner: nullable(boolean()),
|
|
7257
7270
|
/** Open tasks whose source is in this chat. */
|
|
7258
|
-
open_tasks: array(id)
|
|
7271
|
+
open_tasks: array(id),
|
|
7272
|
+
/** `unknown` means nothing ever fetched the chat's history; `partial` that the store holds only part of it. */
|
|
7273
|
+
completeness: strictObject({
|
|
7274
|
+
state: picklist(["complete", "partial", "unknown"]),
|
|
7275
|
+
up_to_date: nullable(boolean()),
|
|
7276
|
+
gaps: boolean(),
|
|
7277
|
+
reaches_start: boolean(),
|
|
7278
|
+
fetched_at: nullable(time)
|
|
7279
|
+
}),
|
|
7280
|
+
/** What the store holds of the chat: the count and the span, never the text. */
|
|
7281
|
+
held: strictObject({ messages: number(), oldest_at: nullable(time), newest_at: nullable(time) })
|
|
7259
7282
|
});
|
|
7260
7283
|
var agenda = strictObject({
|
|
7261
7284
|
at: time,
|
|
@@ -7304,7 +7327,7 @@ var agenda = strictObject({
|
|
|
7304
7327
|
unlisted_categories: array(strictObject({ name: text, open_tasks: number() }))
|
|
7305
7328
|
});
|
|
7306
7329
|
|
|
7307
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7330
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/conversation.js
|
|
7308
7331
|
var conversation = strictObject({
|
|
7309
7332
|
id,
|
|
7310
7333
|
chat: reference,
|
|
@@ -7319,7 +7342,7 @@ var conversation = strictObject({
|
|
|
7319
7342
|
rules_version: count
|
|
7320
7343
|
});
|
|
7321
7344
|
|
|
7322
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7345
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/attachment.js
|
|
7323
7346
|
var attachment = strictObject({
|
|
7324
7347
|
/** The message it came with, as a locator; absent inside that message. */
|
|
7325
7348
|
message: optional(reference),
|
|
@@ -7356,7 +7379,7 @@ var attachment = strictObject({
|
|
|
7356
7379
|
}))))
|
|
7357
7380
|
});
|
|
7358
7381
|
|
|
7359
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7382
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/entities/tagging.js
|
|
7360
7383
|
var tagging = strictObject({
|
|
7361
7384
|
tag: text,
|
|
7362
7385
|
type: picklist(TAG_TYPES),
|
|
@@ -7369,7 +7392,7 @@ var tagging = strictObject({
|
|
|
7369
7392
|
created_at: time
|
|
7370
7393
|
});
|
|
7371
7394
|
|
|
7372
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7395
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/runs/record-log.js
|
|
7373
7396
|
var recordLogFor = /* @__PURE__ */ __name((to, app, { traceId, command } = {}) => {
|
|
7374
7397
|
const run = currentRun();
|
|
7375
7398
|
const trace = traceId ?? run.traceId;
|
|
@@ -3,10 +3,10 @@ const require = __bundleRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
proxyError,
|
|
5
5
|
proxyLabel
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-NAVNCM5K.js";
|
|
7
7
|
import {
|
|
8
8
|
CliError
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-XMMWKHNY.js";
|
|
10
10
|
import {
|
|
11
11
|
__name
|
|
12
12
|
} from "./chunk-ZVVMGPBJ.js";
|
|
@@ -13,40 +13,40 @@ import {
|
|
|
13
13
|
privateFiles,
|
|
14
14
|
providerRequest,
|
|
15
15
|
withSqliteSidecars
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-2ILQYCBY.js";
|
|
17
17
|
import {
|
|
18
18
|
parseProxy,
|
|
19
19
|
proxyAddress,
|
|
20
20
|
proxyError,
|
|
21
21
|
proxyLabel,
|
|
22
22
|
proxySetting
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-NAVNCM5K.js";
|
|
24
24
|
import {
|
|
25
25
|
messengerContext
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-SH63Q4QR.js";
|
|
27
27
|
import {
|
|
28
28
|
uploadBlob
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-XJVGCCQE.js";
|
|
30
30
|
import {
|
|
31
31
|
asFirstWord,
|
|
32
32
|
currentAttempt,
|
|
33
33
|
environmentOf,
|
|
34
34
|
fromFile,
|
|
35
35
|
settingsFor
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-DZVYGBZB.js";
|
|
37
37
|
import {
|
|
38
38
|
TG
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-ZFMS5G4H.js";
|
|
40
40
|
import {
|
|
41
41
|
Credentials,
|
|
42
42
|
pathsAreOverridden,
|
|
43
43
|
resolvePaths
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-N5FSRC6H.js";
|
|
45
45
|
import {
|
|
46
46
|
CliError,
|
|
47
47
|
isCliError,
|
|
48
48
|
optional
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-XMMWKHNY.js";
|
|
50
50
|
import {
|
|
51
51
|
importFrom
|
|
52
52
|
} from "./chunk-Y5E2WNWB.js";
|
|
@@ -178,7 +178,7 @@ var telegramOf = /* @__PURE__ */ __name((command, base) => {
|
|
|
178
178
|
throw new CliError(unreachable, loggedIn ? `no Telegram app credentials found for profile "${profile}", although it has logged in on this machine \u2014 the keyring is probably out of reach (cron, ssh, an MCP client that trims the environment: set XDG_RUNTIME_DIR); \`tg ${asFirstWord(profile)}doctor\` shows it. Log in again only if they were removed` : `no Telegram app credentials for profile "${profile}" \u2014 run ${setup} in a local terminal first, or sign in from ${desktop}; agents: read \`tg skill show\``);
|
|
179
179
|
}
|
|
180
180
|
const options = { credentials: resolved, sessionPath, ...connecting };
|
|
181
|
-
return environment.adapter ? await environment.adapter(options) : await (await import("./adapter-
|
|
181
|
+
return environment.adapter ? await environment.adapter(options) : await (await import("./adapter-6JLFYFL5.js")).TelegramAdapter.open({
|
|
182
182
|
...options,
|
|
183
183
|
...proxyOption(proxy()),
|
|
184
184
|
diagnostic: /* @__PURE__ */ __name((line) => base.streams.diagnostic(line), "diagnostic"),
|
|
@@ -864,7 +864,7 @@ var TELEGRAM_BOT = {
|
|
|
864
864
|
const botId = token.split(":", 1)[0] ?? "";
|
|
865
865
|
if (!/^\d+$/.test(botId))
|
|
866
866
|
throw new CliError("authentication_error", "the bot token has no valid bot id");
|
|
867
|
-
const reader = await (environment.botHistory ?? (await import("./bot-history-
|
|
867
|
+
const reader = await (environment.botHistory ?? (await import("./bot-history-DDNTNMNB.js")).openBotHistory)({
|
|
868
868
|
credentials,
|
|
869
869
|
sessionPath: botSessionFile(profile, botId, env),
|
|
870
870
|
token,
|
|
@@ -884,7 +884,7 @@ var TELEGRAM_BOT = {
|
|
|
884
884
|
return void 0;
|
|
885
885
|
let personal;
|
|
886
886
|
try {
|
|
887
|
-
personal = environment.adapter ? await environment.adapter({ credentials, sessionPath: personalPath }) : await (await import("./adapter-
|
|
887
|
+
personal = environment.adapter ? await environment.adapter({ credentials, sessionPath: personalPath }) : await (await import("./adapter-6JLFYFL5.js")).TelegramAdapter.open({
|
|
888
888
|
credentials,
|
|
889
889
|
sessionPath: personalPath,
|
|
890
890
|
checks: words,
|
|
@@ -2,15 +2,15 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
unit
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-3PEZWXKO.js";
|
|
6
6
|
import {
|
|
7
7
|
CliError
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-XMMWKHNY.js";
|
|
9
9
|
import {
|
|
10
10
|
__name
|
|
11
11
|
} from "./chunk-ZVVMGPBJ.js";
|
|
12
12
|
|
|
13
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
13
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.501.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.67.0_commander@15._175d7b0a70ee7b08949f50032917d93e/node_modules/@wirecat/cli-core/dist/embeddings/remote.js
|
|
14
14
|
import { setTimeout } from "node:timers/promises";
|
|
15
15
|
var OPENAI_URL = "https://api.openai.com/v1";
|
|
16
16
|
var OPENAI_MODELS = {
|