@wirecat/hubspot-cli 0.4.0 → 0.6.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 +44 -0
- package/README.md +75 -54
- package/contracts/wirecat.json +39 -13
- package/dist/bin/hubspot.js +2 -2
- package/dist/bundle/agent-XB35QVOK.js +40 -0
- package/dist/bundle/{all-profiles-JVEE4PXX.js → all-profiles-HFVXPMF6.js} +11 -11
- package/dist/bundle/{anthropic-6HT57GNF.js → anthropic-VE6WR6IN.js} +5 -5
- package/dist/bundle/{app-server-FOBFF6G6.js → app-server-GZ4DCQK7.js} +68 -68
- package/dist/bundle/{bun-GW443QB3.js → bun-2DHMKD34.js} +2 -2
- package/dist/bundle/{bun-sqlite-TGIAICDN.js → bun-sqlite-T5XTYL7L.js} +6 -6
- package/dist/bundle/{chunk-FK4LEJZM.js → chunk-24HPBWKZ.js} +63 -4
- package/dist/bundle/{chunk-4OPN3KCN.js → chunk-2I2KBCS6.js} +5 -5
- package/dist/bundle/{chunk-3BM6KBWP.js → chunk-2K5BAY32.js} +19 -19
- package/dist/bundle/{chunk-6ULR7N3T.js → chunk-2VUIJ5XB.js} +2 -2
- package/dist/bundle/{chunk-UHHXZKB2.js → chunk-3HS7JTPI.js} +27 -177
- package/dist/bundle/{chunk-3SRGN5MQ.js → chunk-3TLNO3VM.js} +2 -2
- package/dist/bundle/{chunk-ATGD64VO.js → chunk-3W5R3XAH.js} +8 -8
- package/dist/bundle/{chunk-CFQQTDSA.js → chunk-3WG4MTQI.js} +1 -1
- package/dist/bundle/{chunk-NL3RKJR6.js → chunk-3YTTWJKL.js} +1 -1
- package/dist/bundle/{chunk-5WKJFMC3.js → chunk-4UEYVM46.js} +4 -4
- package/dist/bundle/{chunk-5G4L6NQJ.js → chunk-5ILCAAY4.js} +35 -35
- package/dist/bundle/{chunk-ETKLP4VE.js → chunk-5IPB5WLB.js} +14 -14
- package/dist/bundle/{chunk-N4EIJ53V.js → chunk-5NIIXJV3.js} +2 -2
- package/dist/bundle/{chunk-QIFCH5DZ.js → chunk-5O5WYSSO.js} +1967 -654
- package/dist/bundle/{chunk-XMWMA2N5.js → chunk-5VTKBGPW.js} +90 -33
- package/dist/bundle/{chunk-M25KVDHA.js → chunk-5WDNG4QE.js} +7 -7
- package/dist/bundle/{chunk-WATDMTDC.js → chunk-67YPTVGP.js} +3 -3
- package/dist/bundle/{chunk-3MUHCLRY.js → chunk-6DABKZYH.js} +143 -8
- package/dist/bundle/{chunk-HVXOA4FO.js → chunk-745FMNI5.js} +1 -1
- package/dist/bundle/{chunk-5KLNBGPU.js → chunk-AKSWXRIU.js} +1 -1
- package/dist/bundle/{chunk-HM6AMYHR.js → chunk-AP3CWDRK.js} +2 -2
- package/dist/bundle/{chunk-HPRKSL5S.js → chunk-BM5F2ZNI.js} +2 -2
- package/dist/bundle/{chunk-FOLKK6FW.js → chunk-BU5CEMUH.js} +20 -14
- package/dist/bundle/{chunk-DBPFHJXX.js → chunk-CTN4DW2F.js} +4 -4
- package/dist/bundle/{chunk-QJHRRJKD.js → chunk-CU76ZACK.js} +3 -3
- package/dist/bundle/{chunk-7QH5BZUG.js → chunk-DIKUPU3T.js} +3 -3
- package/dist/bundle/{chunk-JWO3PB5Z.js → chunk-E27NRLJZ.js} +18 -18
- package/dist/bundle/{chunk-EU7AVWSX.js → chunk-EB53G4HO.js} +2 -2
- package/dist/bundle/{chunk-GJSHLF43.js → chunk-EJZIEBAR.js} +8 -8
- package/dist/bundle/{chunk-HQYJ66ZX.js → chunk-G6LDK6DJ.js} +18 -8
- package/dist/bundle/{chunk-VDAYIXV4.js → chunk-GEJI27GN.js} +6 -6
- package/dist/bundle/{chunk-XJVFXHDI.js → chunk-GHXTNKX2.js} +2 -2
- package/dist/bundle/{chunk-W5X37TBC.js → chunk-GR4HZBWO.js} +2 -2
- package/dist/bundle/{chunk-WBUVNKHJ.js → chunk-GWXTVO43.js} +7 -7
- package/dist/bundle/{chunk-2Q2XIXDL.js → chunk-H4W2OO35.js} +1 -1
- package/dist/bundle/{chunk-3LMW7U7F.js → chunk-H5HBZCEJ.js} +21 -8
- package/dist/bundle/{chunk-JKNUCEII.js → chunk-HX2BE7DO.js} +1 -1
- package/dist/bundle/{chunk-PQUZ2YDC.js → chunk-HYDXA624.js} +6 -6
- package/dist/bundle/{chunk-Z3YOKGVZ.js → chunk-HZIGGAC7.js} +2 -2
- package/dist/bundle/{chunk-AT43MYQL.js → chunk-I75ON7VM.js} +8 -8
- package/dist/bundle/{chunk-PKFLSX5F.js → chunk-ID4GJFE7.js} +8 -8
- package/dist/bundle/{chunk-A6PVEUGN.js → chunk-J2SCELII.js} +17 -17
- package/dist/bundle/{chunk-PMJCZIV4.js → chunk-J4FXBF44.js} +1 -1
- package/dist/bundle/{chunk-DG4RBKIV.js → chunk-J76CMNWQ.js} +1 -1
- package/dist/bundle/{chunk-MQACXJLG.js → chunk-JDCFHZNU.js} +10 -10
- package/dist/bundle/{chunk-K4DWBOO6.js → chunk-JFLKTYH5.js} +6 -6
- package/dist/bundle/{chunk-LS4S7PAP.js → chunk-K4Y2ZWOO.js} +3 -3
- package/dist/bundle/{chunk-5ZVYIA56.js → chunk-KDW7B7AR.js} +5 -5
- package/dist/bundle/{chunk-BXZRSXBL.js → chunk-KKMOKSS5.js} +3 -3
- package/dist/bundle/{chunk-EBJYK7UM.js → chunk-LHY5XGIR.js} +78 -63
- package/dist/bundle/{chunk-V23OHBGM.js → chunk-LTU4BQ4S.js} +3 -3
- package/dist/bundle/{chunk-LX7QMRRG.js → chunk-M3LRSN6J.js} +13 -13
- package/dist/bundle/{chunk-UIWWAT3C.js → chunk-MJ24YFXZ.js} +7 -7
- package/dist/bundle/{chunk-YYYRE4AV.js → chunk-MSQGZHKM.js} +32 -28
- package/dist/bundle/{chunk-6NUXFVJQ.js → chunk-NQOQG7L3.js} +1 -1
- package/dist/bundle/{chunk-WLFYEAZ6.js → chunk-PDVMYIBP.js} +1516 -745
- package/dist/bundle/{chunk-QODPEZC5.js → chunk-PR7ZDMGF.js} +10 -3
- package/dist/bundle/{chunk-2BCWK5BF.js → chunk-PZ3QJDTD.js} +8 -8
- package/dist/bundle/{chunk-OLDIP4CV.js → chunk-Q6AC7WLD.js} +3 -3
- package/dist/bundle/{chunk-X5U7GLHD.js → chunk-QH47G73D.js} +16 -3
- package/dist/bundle/{chunk-RFGIUCKU.js → chunk-QK5HQUHB.js} +3 -3
- package/dist/bundle/{chunk-3MPMYAII.js → chunk-R26OEZOL.js} +1 -1
- package/dist/bundle/{chunk-T3GZKV5A.js → chunk-RLK2EGQD.js} +21 -15
- package/dist/bundle/{chunk-Z4PY5BDP.js → chunk-RLNPTES2.js} +4 -4
- package/dist/bundle/{chunk-XCDRFC6G.js → chunk-T4MZJMEJ.js} +17 -17
- package/dist/bundle/{chunk-TAF4PKDS.js → chunk-TAPQZYXY.js} +1 -1
- package/dist/bundle/{chunk-AV2ZJ4WX.js → chunk-TCSVW7BA.js} +1 -1
- package/dist/bundle/{chunk-E33KM3DB.js → chunk-THGAVPRA.js} +11 -11
- package/dist/bundle/{chunk-XDDTJYGA.js → chunk-TRLV5NWZ.js} +2477 -2140
- package/dist/bundle/{chunk-5OBVICFK.js → chunk-TT75CEYZ.js} +22 -1
- package/dist/bundle/{chunk-7OJ43BAH.js → chunk-TXO4CJW3.js} +7 -7
- package/dist/bundle/{chunk-F4ZLRS4B.js → chunk-UCGZRZJA.js} +1 -1
- package/dist/bundle/{chunk-NLZADZ4F.js → chunk-UVGJL753.js} +61 -61
- package/dist/bundle/{chunk-VMF2UIQI.js → chunk-UZ2CL435.js} +3 -4
- package/dist/bundle/{chunk-IED6MKPU.js → chunk-V7N2K5OT.js} +33 -30
- package/dist/bundle/{chunk-QV4GDVBN.js → chunk-VR2CJFVL.js} +8 -8
- package/dist/bundle/{chunk-7JVKQ6NM.js → chunk-WASBOYI2.js} +4 -4
- package/dist/bundle/{chunk-F3HJ2E3P.js → chunk-WE4JSHIG.js} +6 -6
- package/dist/bundle/{chunk-FWW2CUXH.js → chunk-X2QRCFGJ.js} +4 -4
- package/dist/bundle/{chunk-V2B2OWTC.js → chunk-XRFYVVFU.js} +2 -2
- package/dist/bundle/{chunk-Q7DIEU6L.js → chunk-YDG5FIQB.js} +7 -9
- package/dist/bundle/{chunk-GOOXUCJW.js → chunk-YIH2A2PQ.js} +2 -2
- package/dist/bundle/{chunk-HM72O37C.js → chunk-ZERQSELP.js} +207 -163
- package/dist/bundle/{chunk-QNQ4V4UT.js → chunk-ZKTYTOF4.js} +8 -8
- package/dist/bundle/command-contract-5FXCYQUS.js +40 -0
- package/dist/bundle/{command-server-entry-OJQ55UA2.js → command-server-entry-H6IAJNOF.js} +28 -28
- package/dist/bundle/{decode-CDQDRPRJ.js → decode-TR2EC46M.js} +5 -5
- package/dist/bundle/{dispatch-JQBAZWCL.js → dispatch-B2EP6DDT.js} +8 -8
- package/dist/bundle/{echarts-GJ5JJG2A.js → echarts-7OP7I5B2.js} +2 -2
- package/dist/bundle/{embed-BUQXGMKR.js → embed-FLGS4LN7.js} +6 -6
- package/dist/bundle/{embedder-FCX6LE4O.js → embedder-JIXQXCP3.js} +9 -9
- package/dist/bundle/{failure-I6AAF5R5.js → failure-AOACEURF.js} +2 -2
- package/dist/bundle/{first-run-RPYEXXQK.js → first-run-XJ2NWIK2.js} +12 -12
- package/dist/bundle/first-screen-U73G5CMM.js +40 -0
- package/dist/bundle/hubspot.js +27 -25
- package/dist/bundle/{instructions-LPVTPERS.js → instructions-PYCYV6QE.js} +1 -1
- package/dist/bundle/{mcp-YGOAUNC3.js → mcp-ZNULRPZ4.js} +2 -2
- package/dist/bundle/meeting-combined-IHTM5H5B.js +25 -0
- package/dist/bundle/{meeting-model-TRGBEWCY.js → meeting-model-2PA5WJY5.js} +11 -11
- package/dist/bundle/{meeting-semantic-RSF5KNKD.js → meeting-semantic-5IH63QFV.js} +6 -6
- package/dist/bundle/{node-UAT3EIAP.js → node-6GTNIVBM.js} +2 -2
- package/dist/bundle/{node-sqlite-3HKDQNFD.js → node-sqlite-FBCEHPNT.js} +7 -7
- package/dist/bundle/{oauth-DYW2NSZP.js → oauth-BFP4SCL5.js} +7 -7
- package/dist/bundle/{open-KBRXJ5BC.js → open-MLU4MHGO.js} +5 -5
- package/dist/bundle/{openai-YNCLRTSK.js → openai-R7WJI6SO.js} +15 -15
- package/dist/bundle/{process-63BB7LKP.js → process-NMNQLJHZ.js} +1 -1
- package/dist/bundle/{program-VX52OB3O.js → program-Z735HPFG.js} +517 -343
- package/dist/bundle/{prompt-TWLJ3M2O.js → prompt-A6RM55Q4.js} +5 -5
- package/dist/bundle/{recognize-GQ6DLGE7.js → recognize-ORRDV45M.js} +4 -4
- package/dist/bundle/{remote-RKNSF3TT.js → remote-UF3WSC4X.js} +9 -9
- package/dist/bundle/{rerank-H4HSGQUJ.js → rerank-ZSJORUGH.js} +7 -7
- package/dist/bundle/{schemas-LDK7O6VW.js → schemas-EXBNVPMI.js} +1 -1
- package/dist/bundle/{serve-4ZNIAL7H.js → serve-4KBJ6SIA.js} +9 -9
- package/dist/bundle/{server-4G4QB3QN.js → server-IFK4S6LJ.js} +60 -60
- package/dist/bundle/server-MNUAZWTN.js +86 -0
- package/dist/bundle/source-PBCQAG4C.js +426 -0
- package/dist/bundle/{sqlite-runtime-C2JYC7JF.js → sqlite-runtime-XPDUWOPG.js} +6 -6
- package/dist/bundle/{state-3KDXCXHG.js → state-4M26H7NL.js} +6 -6
- package/dist/bundle/{store-LXLG5HTS.js → store-3W4ZOOIB.js} +28 -24
- package/dist/bundle/store-CDY2PW6J.js +34 -0
- package/dist/bundle/{store-J5FQBZYR.js → store-ICTY3RIF.js} +22 -22
- package/dist/bundle/store-maintenance-command-Y7TC3I43.js +73 -0
- package/dist/bundle/surface-4LNDJZD2.js +72 -0
- package/dist/bundle/writer-WGHWQTC2.js +86 -0
- package/dist/commands/account.d.ts +3 -2
- package/dist/commands/account.d.ts.map +1 -1
- package/dist/commands/account.js +31 -78
- package/dist/commands/account.js.map +1 -1
- package/dist/commands/crm-shared.d.ts.map +1 -1
- package/dist/commands/crm-shared.js +2 -0
- package/dist/commands/crm-shared.js.map +1 -1
- package/dist/commands/session.d.ts +0 -3
- package/dist/commands/session.d.ts.map +1 -1
- package/dist/commands/session.js +4 -31
- package/dist/commands/session.js.map +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +19 -12
- package/dist/config.js.map +1 -1
- package/dist/crm/activities.d.ts +6 -1
- package/dist/crm/activities.d.ts.map +1 -1
- package/dist/crm/activities.js +36 -0
- package/dist/crm/activities.js.map +1 -1
- package/dist/crm/writer.d.ts +1 -1
- package/dist/crm/writer.d.ts.map +1 -1
- package/dist/crm/writer.js +69 -1
- package/dist/crm/writer.js.map +1 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +0 -2
- package/dist/program.js.map +1 -1
- package/dist/reasons.d.ts.map +1 -1
- package/dist/reasons.js +0 -2
- package/dist/reasons.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +4 -4
- package/skills/hubspot-cli/SKILL.md +10 -5
- package/skills/hubspot-cli/references/api/api-basic.md +2 -2
- package/skills/hubspot-cli/references/api/api-batch.md +2 -2
- package/dist/bundle/agent-NST4YXJR.js +0 -40
- package/dist/bundle/command-contract-LYX2QNIA.js +0 -40
- package/dist/bundle/first-screen-Y4EH3HZS.js +0 -40
- package/dist/bundle/meeting-combined-FEEVVUGC.js +0 -25
- package/dist/bundle/server-3IYIZEEQ.js +0 -86
- package/dist/bundle/source-2UCNCCO7.js +0 -917
- package/dist/bundle/store-2MNUHHZC.js +0 -32
- package/dist/bundle/store-maintenance-command-DDB7TR6V.js +0 -73
- package/dist/bundle/surface-ZTZANYKC.js +0 -72
- package/dist/bundle/writer-X7PGBLDH.js +0 -86
|
@@ -15,209 +15,67 @@ import {
|
|
|
15
15
|
profilesOnAccount,
|
|
16
16
|
recipientsPathFor,
|
|
17
17
|
refuseLacking,
|
|
18
|
+
refuseUnknownPermissionKeys,
|
|
18
19
|
servicesFor,
|
|
20
|
+
terminalAsker,
|
|
19
21
|
waitForTurn
|
|
20
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-5O5WYSSO.js";
|
|
21
23
|
import {
|
|
22
24
|
capability,
|
|
23
25
|
throughWrapper
|
|
24
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-BU5CEMUH.js";
|
|
25
27
|
import {
|
|
26
28
|
servingProfiles
|
|
27
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-QH47G73D.js";
|
|
28
30
|
import {
|
|
29
31
|
asFirstWord,
|
|
30
32
|
baseContext,
|
|
31
33
|
codeOf,
|
|
32
34
|
currentOperation,
|
|
33
35
|
environmentOf,
|
|
34
|
-
issueMessage,
|
|
35
36
|
limitBatch,
|
|
36
|
-
permissionIssues,
|
|
37
|
-
publicIssue,
|
|
38
37
|
recalledAccount,
|
|
39
38
|
rememberAccount,
|
|
40
39
|
rootOf2 as rootOf
|
|
41
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-ZERQSELP.js";
|
|
42
41
|
import {
|
|
43
42
|
providerErrorKey
|
|
44
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-I75ON7VM.js";
|
|
45
44
|
import {
|
|
46
45
|
openStore
|
|
47
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-PDVMYIBP.js";
|
|
48
47
|
import {
|
|
49
48
|
isCliFailure
|
|
50
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-HZIGGAC7.js";
|
|
51
50
|
import {
|
|
52
|
-
AUTHORITY_KEY,
|
|
53
51
|
CEILING_KEY,
|
|
54
|
-
DEFAULT_PERMISSIONS,
|
|
55
|
-
KEYED_UNDER_HOUSEKEEPING,
|
|
56
|
-
WRITE_KEYS,
|
|
57
52
|
fetchesUnder,
|
|
58
|
-
keyForCommand,
|
|
59
53
|
levelFor,
|
|
60
|
-
readKeysForCommand
|
|
61
|
-
|
|
62
|
-
} from "./chunk-HQYJ66ZX.js";
|
|
54
|
+
readKeysForCommand
|
|
55
|
+
} from "./chunk-G6LDK6DJ.js";
|
|
63
56
|
import {
|
|
64
57
|
chatReferenceOf,
|
|
65
58
|
ensureAccount,
|
|
66
59
|
foldName,
|
|
67
60
|
isId,
|
|
68
61
|
pickPerson
|
|
69
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-E27NRLJZ.js";
|
|
70
63
|
import {
|
|
71
64
|
CliError
|
|
72
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-AP3CWDRK.js";
|
|
73
66
|
import {
|
|
74
67
|
__name
|
|
75
68
|
} from "./chunk-ZVVMGPBJ.js";
|
|
76
69
|
|
|
77
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
78
|
-
import { openSync } from "node:fs";
|
|
79
|
-
import { createInterface } from "node:readline";
|
|
80
|
-
import { ReadStream } from "node:tty";
|
|
81
|
-
var fromTerminal = /* @__PURE__ */ __name(async (question) => {
|
|
82
|
-
if (!process.stdin.isTTY || !process.stderr.isTTY)
|
|
83
|
-
return null;
|
|
84
|
-
let input;
|
|
85
|
-
try {
|
|
86
|
-
input = new ReadStream(openSync("/dev/tty", "r"));
|
|
87
|
-
} catch {
|
|
88
|
-
return null;
|
|
89
|
-
}
|
|
90
|
-
const reader = createInterface({ input, output: process.stderr, terminal: true });
|
|
91
|
-
try {
|
|
92
|
-
return await new Promise((resolve, reject) => {
|
|
93
|
-
const cancel = /* @__PURE__ */ __name(() => reject(new CliError("cancelled", "cancelled \u2014 nothing was done")), "cancel");
|
|
94
|
-
reader.once("SIGINT", cancel);
|
|
95
|
-
reader.once("close", cancel);
|
|
96
|
-
reader.question(question, resolve);
|
|
97
|
-
});
|
|
98
|
-
} finally {
|
|
99
|
-
reader.close();
|
|
100
|
-
input.destroy();
|
|
101
|
-
}
|
|
102
|
-
}, "fromTerminal");
|
|
103
|
-
var what = /* @__PURE__ */ __name((key, { chatId, count, personIds, forEveryone }) => [
|
|
104
|
-
key,
|
|
105
|
-
forEveryone ? "for everyone" : void 0,
|
|
106
|
-
count !== void 0 ? `${count} ${count === 1 ? "item" : "items"}` : void 0,
|
|
107
|
-
personIds?.length ? `${personIds.length} ${personIds.length === 1 ? "person" : "people"}` : void 0,
|
|
108
|
-
chatId !== null ? `in chat ${chatId}` : void 0
|
|
109
|
-
].filter(Boolean).join(", "), "what");
|
|
110
|
-
var answerOf = /* @__PURE__ */ __name(async (command, question) => {
|
|
111
|
-
const given = command.optsWithGlobals();
|
|
112
|
-
if (given.json === true || given.jsonl === true)
|
|
113
|
-
return null;
|
|
114
|
-
return (environmentOf(command).answer ?? fromTerminal)(question);
|
|
115
|
-
}, "answerOf");
|
|
116
|
-
var terminalAsker = /* @__PURE__ */ __name((command) => async (key, request) => {
|
|
117
|
-
if (environmentOf(command).agent)
|
|
118
|
-
return;
|
|
119
|
-
const flag = skipFlagFor(key);
|
|
120
|
-
const given = command.optsWithGlobals();
|
|
121
|
-
if (flag === "--yes" ? given.yes === true : given.allowDangerous === true)
|
|
122
|
-
return;
|
|
123
|
-
const machine = given.json === true || given.jsonl === true;
|
|
124
|
-
const answer = machine ? null : await (environmentOf(command).answer ?? fromTerminal)(`${what(key, request)} \u2014 go ahead? [y/N] `);
|
|
125
|
-
if (answer === null) {
|
|
126
|
-
throw new CliError("confirmation_required", `${key} asks before it acts (its permission level is ask), and nobody is at a terminal to answer \u2014 add ${flag} to go ahead`, { permission: key });
|
|
127
|
-
}
|
|
128
|
-
if (!/^\s*y(es)?\s*$/i.test(answer))
|
|
129
|
-
throw new CliError("cancelled", `${key}: not done \u2014 the answer was no`);
|
|
130
|
-
}, "terminalAsker");
|
|
131
|
-
|
|
132
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.705.0_@wirecat+cli-base@0.124.0_commander@15.0.0_esbuild@0.28.2_typ_1668a48934ee0d2606b0d61251c2625b/node_modules/@wirecat/cli-core/dist/cli/permission-keys.js
|
|
133
|
-
var HOUSEKEEPING = /* @__PURE__ */ new Set([
|
|
134
|
-
"help",
|
|
135
|
-
"guide",
|
|
136
|
-
"config",
|
|
137
|
-
"session",
|
|
138
|
-
"doctor",
|
|
139
|
-
"commands",
|
|
140
|
-
"complete",
|
|
141
|
-
"upgrade",
|
|
142
|
-
"skill",
|
|
143
|
-
"mcp",
|
|
144
|
-
"runs"
|
|
145
|
-
]);
|
|
146
|
-
var commandPathKey = /* @__PURE__ */ __name((path) => path[0] === void 0 || HOUSEKEEPING.has(path[0]) && !KEYED_UNDER_HOUSEKEEPING.has(path.join(".")) ? null : path.join("."), "commandPathKey");
|
|
147
|
-
var commandPermissions = /* @__PURE__ */ __name(({ keyOf = commandPathKey, extra = [], defaults = {}, alsoChecks } = {}) => ({
|
|
148
|
-
keyOf,
|
|
149
|
-
extra: [AUTHORITY_KEY, ...extra],
|
|
150
|
-
defaults: { ...DEFAULT_PERMISSIONS, ...defaults },
|
|
151
|
-
...alsoChecks ? { alsoChecks } : {}
|
|
152
|
-
}), "commandPermissions");
|
|
153
|
-
var pathOf = /* @__PURE__ */ __name((command) => {
|
|
154
|
-
const words = [];
|
|
155
|
-
for (let at = command; at?.parent; at = at.parent)
|
|
156
|
-
words.unshift(at.name());
|
|
157
|
-
return words;
|
|
158
|
-
}, "pathOf");
|
|
159
|
-
var rootOf2 = /* @__PURE__ */ __name((command) => {
|
|
160
|
-
let at = command;
|
|
161
|
-
while (at.parent)
|
|
162
|
-
at = at.parent;
|
|
163
|
-
return at;
|
|
164
|
-
}, "rootOf");
|
|
165
|
-
var everyCommand = /* @__PURE__ */ __name((command) => [command, ...command.commands.flatMap(everyCommand)], "everyCommand");
|
|
166
|
-
var knownPermissionKeys = /* @__PURE__ */ __name((command, keyOf = (one) => keyForCommand(pathOf(one)), extra = []) => {
|
|
167
|
-
const known = /* @__PURE__ */ new Set();
|
|
168
|
-
const add = /* @__PURE__ */ __name((key) => {
|
|
169
|
-
for (let parts = key.split("."); parts.length > 0; parts = parts.slice(0, -1))
|
|
170
|
-
known.add(parts.join("."));
|
|
171
|
-
}, "add");
|
|
172
|
-
if (typeof keyOf !== "function") {
|
|
173
|
-
for (const one of everyCommand(rootOf2(command))) {
|
|
174
|
-
const key = keyOf.keyOf(pathOf(one));
|
|
175
|
-
if (key)
|
|
176
|
-
add(key);
|
|
177
|
-
}
|
|
178
|
-
for (const key of [...keyOf.extra, ...extra])
|
|
179
|
-
add(key);
|
|
180
|
-
return known;
|
|
181
|
-
}
|
|
182
|
-
for (const one of everyCommand(rootOf2(command))) {
|
|
183
|
-
const own = keyOf(one);
|
|
184
|
-
const key = own === void 0 ? keyForCommand(pathOf(one)) : own;
|
|
185
|
-
if (key)
|
|
186
|
-
add(key);
|
|
187
|
-
}
|
|
188
|
-
for (const key of [...WRITE_KEYS, ...extra])
|
|
189
|
-
add(key);
|
|
190
|
-
return known;
|
|
191
|
-
}, "knownPermissionKeys");
|
|
192
|
-
var knownBeside = /* @__PURE__ */ __name((key, known) => {
|
|
193
|
-
const parent = key.split(".").slice(0, -1).join(".");
|
|
194
|
-
const depth = parent === "" ? 1 : parent.split(".").length + 1;
|
|
195
|
-
return [...known].filter((one) => one.split(".").length === depth && (parent === "" || one.startsWith(`${parent}.`))).sort();
|
|
196
|
-
}, "knownBeside");
|
|
197
|
-
var unknownPermissionKeys = /* @__PURE__ */ __name((levels, known) => Object.keys(levels).filter((key) => key !== CEILING_KEY && !known.has(key)), "unknownPermissionKeys");
|
|
198
|
-
var unknownPermissionIssues = /* @__PURE__ */ __name((command, settings, tool, keyOf) => {
|
|
199
|
-
const saved = settings.savedPermissions ?? Object.keys(settings.permissions).filter((key) => key !== CEILING_KEY && settings.permissionSources[key] !== "flag").map((key) => ({ key, at: ["profiles", settings.profile, "permissions", key] }));
|
|
200
|
-
return permissionIssues(saved, knownPermissionKeys(command, keyOf), { file: settings.configPath, tool }).map(publicIssue);
|
|
201
|
-
}, "unknownPermissionIssues");
|
|
202
|
-
var refuseUnknownPermissionKeys = /* @__PURE__ */ __name((command, settings, tool, keyOf) => {
|
|
203
|
-
const issues = unknownPermissionIssues(command, settings, tool, keyOf);
|
|
204
|
-
if (issues.length > 0)
|
|
205
|
-
throw new CliError("configuration_error", issueMessage(issues), { permission: issues[0]?.key });
|
|
206
|
-
const flagged = Object.keys(settings.permissions).filter((key2) => settings.permissionSources[key2] === "flag");
|
|
207
|
-
const [key] = unknownPermissionKeys(Object.fromEntries(flagged.map((one) => [one, true])), knownPermissionKeys(command, keyOf));
|
|
208
|
-
if (key !== void 0)
|
|
209
|
-
throw new CliError("validation_error", `--permission ${key} names no command`, { permission: key });
|
|
210
|
-
}, "refuseUnknownPermissionKeys");
|
|
211
|
-
|
|
212
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.705.0_@wirecat+cli-base@0.124.0_commander@15.0.0_esbuild@0.28.2_typ_1668a48934ee0d2606b0d61251c2625b/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
|
|
70
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
|
|
213
71
|
var LONG_LIVED = /* @__PURE__ */ new Set(["self", "newSendId", "close", "formatMarkdown", "formatHtml", "storedChats"]);
|
|
214
72
|
var LISTENING = /* @__PURE__ */ new Set(["watch", "feed", "listen", "listenHistory"]);
|
|
215
73
|
var BLOCKING = /* @__PURE__ */ new Set(["frozen", "limited", "banned"]);
|
|
216
74
|
var chatOf = /* @__PURE__ */ __name((args) => typeof args[0] === "string" && /^-?\d+$/.test(args[0]) ? args[0] : void 0, "chatOf");
|
|
217
75
|
var flooded = /* @__PURE__ */ __name((messenger, memory, { name, warn, pacer }) => {
|
|
218
|
-
const kept = /* @__PURE__ */ __name(async (operation,
|
|
76
|
+
const kept = /* @__PURE__ */ __name(async (operation, what) => {
|
|
219
77
|
try {
|
|
220
|
-
await
|
|
78
|
+
await what();
|
|
221
79
|
} catch (error) {
|
|
222
80
|
warn(`could not remember ${name}'s wait (${error instanceof Error ? error.message : String(error)})`, {
|
|
223
81
|
event: "warning",
|
|
@@ -306,7 +164,7 @@ var flooded = /* @__PURE__ */ __name((messenger, memory, { name, warn, pacer })
|
|
|
306
164
|
});
|
|
307
165
|
}, "flooded");
|
|
308
166
|
|
|
309
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
167
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/messenger/observed.js
|
|
310
168
|
var observed = /* @__PURE__ */ __name((messenger, events) => {
|
|
311
169
|
const timed = /* @__PURE__ */ __name(async (operation, named, work, after) => {
|
|
312
170
|
const write = currentOperation();
|
|
@@ -405,7 +263,7 @@ var byPart = /* @__PURE__ */ __name((batch, counts) => {
|
|
|
405
263
|
counts[part] = (counts[part] ?? 0) + items.length;
|
|
406
264
|
}, "byPart");
|
|
407
265
|
|
|
408
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
266
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/messenger/stored.js
|
|
409
267
|
var REKEY_PACING = { lockMs: 50, pauseMs: 25 };
|
|
410
268
|
var stored = /* @__PURE__ */ __name((messenger, { account, store, warn, events, pending, announcing, deletedWithoutChat, profile, rekeyed, rekeyPacing = REKEY_PACING, closing, namesFromStore, recipientIds, countsUnread = false, historyLimits, command = "cli" }) => {
|
|
411
269
|
let warned = false;
|
|
@@ -981,7 +839,7 @@ var keep = /* @__PURE__ */ __name(async (store, account, event, seenAt, among, c
|
|
|
981
839
|
}
|
|
982
840
|
}, "keep");
|
|
983
841
|
|
|
984
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
842
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/messenger/context.js
|
|
985
843
|
var lazyStore = /* @__PURE__ */ __name((env, command, version) => {
|
|
986
844
|
let opened;
|
|
987
845
|
return {
|
|
@@ -1075,7 +933,7 @@ var settled = /* @__PURE__ */ __name(async (pending, ms) => {
|
|
|
1075
933
|
clearTimeout(timer);
|
|
1076
934
|
}
|
|
1077
935
|
}, "settled");
|
|
1078
|
-
var listened = /* @__PURE__ */ __name(({ run, operation, what
|
|
936
|
+
var listened = /* @__PURE__ */ __name(({ run, operation, what }, events, warn, waitMs) => {
|
|
1079
937
|
const abort = new AbortController();
|
|
1080
938
|
let closing = false;
|
|
1081
939
|
const ended = Promise.resolve().then(() => run(abort.signal)).catch((error) => {
|
|
@@ -1083,11 +941,11 @@ var listened = /* @__PURE__ */ __name(({ run, operation, what: what2 }, events,
|
|
|
1083
941
|
return;
|
|
1084
942
|
const warning = { event: "warning", code: "listen_failed", operation };
|
|
1085
943
|
events(warning);
|
|
1086
|
-
warn(`${
|
|
944
|
+
warn(`${what} arriving during this command are not saved: ${error instanceof Error ? error.message : String(error)}`, warning);
|
|
1087
945
|
});
|
|
1088
946
|
return {
|
|
1089
947
|
operation,
|
|
1090
|
-
what
|
|
948
|
+
what,
|
|
1091
949
|
closing: /* @__PURE__ */ __name(() => {
|
|
1092
950
|
closing = true;
|
|
1093
951
|
}, "closing"),
|
|
@@ -1178,10 +1036,10 @@ var connected = /* @__PURE__ */ __name((connection, { app, provider, name, delet
|
|
|
1178
1036
|
events(warning);
|
|
1179
1037
|
warn(text, warning);
|
|
1180
1038
|
}, "warned");
|
|
1181
|
-
passives.forEach(({ operation, what
|
|
1039
|
+
passives.forEach(({ operation, what }, at) => {
|
|
1182
1040
|
if (ended[at])
|
|
1183
1041
|
return;
|
|
1184
|
-
warned({ event: "warning", code: "store_not_written", operation }, `not saved to the local store: the messenger was still handing on ${
|
|
1042
|
+
warned({ event: "warning", code: "store_not_written", operation }, `not saved to the local store: the messenger was still handing on ${what} at exit`);
|
|
1185
1043
|
});
|
|
1186
1044
|
await settled(/* @__PURE__ */ new Set([...pending, ...announcing]), closeWaitMs);
|
|
1187
1045
|
closing.abort();
|
|
@@ -1240,14 +1098,14 @@ var warnUnserved = /* @__PURE__ */ __name(async (messenger, profile, { env, rend
|
|
|
1240
1098
|
const newest = (await store.chats.chatStats(account)).map((one) => one.newestAt).reduce((latest, at) => at !== null && (latest === null || at > latest) ? at : latest, null);
|
|
1241
1099
|
renderer.warn(`no \`${messenger.app.command} ${profile} serve\` keeps profile "${profile}" up to date \u2014 ` + (newest === null ? "the local store holds no messages yet" : `the newest stored message is from ${newest}`));
|
|
1242
1100
|
}, "warnUnserved");
|
|
1243
|
-
var
|
|
1101
|
+
var pathOf = /* @__PURE__ */ __name((command) => {
|
|
1244
1102
|
const words = [];
|
|
1245
1103
|
for (let at = command; at?.parent; at = at.parent)
|
|
1246
1104
|
words.unshift(at.name());
|
|
1247
1105
|
return words;
|
|
1248
1106
|
}, "pathOf");
|
|
1249
1107
|
var refuseDenied = /* @__PURE__ */ __name((command, settings) => {
|
|
1250
|
-
for (const key of readKeysForCommand(
|
|
1108
|
+
for (const key of readKeysForCommand(pathOf(command))) {
|
|
1251
1109
|
const { level, key: named } = levelFor(settings.permissions, key);
|
|
1252
1110
|
if (level !== "deny")
|
|
1253
1111
|
continue;
|
|
@@ -1270,7 +1128,7 @@ var messengerContext = /* @__PURE__ */ __name((command, messenger, resolving = {
|
|
|
1270
1128
|
const base = baseContext(command, (flags, options) => messenger.resolveSettings(flags, { ...options, ...resolving }));
|
|
1271
1129
|
const { profile } = base.settings;
|
|
1272
1130
|
refuseDenied(command, base.settings);
|
|
1273
|
-
refuseLacking(messenger,
|
|
1131
|
+
refuseLacking(messenger, pathOf(command));
|
|
1274
1132
|
refuseUnknownPermissionKeys(command, base.settings, app.command, messenger.permissionKey);
|
|
1275
1133
|
const warn = /* @__PURE__ */ __name((text, warning) => base.renderer.warn(text, warning), "warn");
|
|
1276
1134
|
const accountFor = /* @__PURE__ */ __name(() => {
|
|
@@ -1382,14 +1240,6 @@ var messengerContext = /* @__PURE__ */ __name((command, messenger, resolving = {
|
|
|
1382
1240
|
}, "messengerContext");
|
|
1383
1241
|
|
|
1384
1242
|
export {
|
|
1385
|
-
answerOf,
|
|
1386
|
-
terminalAsker,
|
|
1387
|
-
commandPathKey,
|
|
1388
|
-
commandPermissions,
|
|
1389
|
-
knownPermissionKeys,
|
|
1390
|
-
knownBeside,
|
|
1391
|
-
unknownPermissionIssues,
|
|
1392
|
-
refuseUnknownPermissionKeys,
|
|
1393
1243
|
fill,
|
|
1394
1244
|
connectedFor,
|
|
1395
1245
|
refuseLocalWrite,
|
|
@@ -7,12 +7,12 @@ import {
|
|
|
7
7
|
import {
|
|
8
8
|
singleLine,
|
|
9
9
|
visibleControls
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-AP3CWDRK.js";
|
|
11
11
|
import {
|
|
12
12
|
__name
|
|
13
13
|
} from "./chunk-ZVVMGPBJ.js";
|
|
14
14
|
|
|
15
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
15
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/render/messages.js
|
|
16
16
|
import { styleText } from "node:util";
|
|
17
17
|
var TIME_WIDTH = 8;
|
|
18
18
|
var INDENT = " ".repeat(TIME_WIDTH + 2);
|
|
@@ -2,33 +2,33 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
stdinFieldOf
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-TAPQZYXY.js";
|
|
6
6
|
import {
|
|
7
7
|
commandPathOf
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-2I2KBCS6.js";
|
|
9
9
|
import {
|
|
10
10
|
commandServerRequest,
|
|
11
11
|
metaOf
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-ZERQSELP.js";
|
|
13
13
|
import {
|
|
14
14
|
errorObjectOf,
|
|
15
15
|
renderError
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-H5HBZCEJ.js";
|
|
17
17
|
import {
|
|
18
18
|
CliError
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-AP3CWDRK.js";
|
|
20
20
|
import {
|
|
21
21
|
__name
|
|
22
22
|
} from "./chunk-ZVVMGPBJ.js";
|
|
23
23
|
|
|
24
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
24
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/command-server.js
|
|
25
25
|
import { createInterface } from "node:readline";
|
|
26
26
|
|
|
27
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
27
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/command-server-argv.js
|
|
28
28
|
var COMMAND_SERVER_ARGV = ["commands", "--serve"];
|
|
29
29
|
var isCommandServer = /* @__PURE__ */ __name((args) => args.length === COMMAND_SERVER_ARGV.length && COMMAND_SERVER_ARGV.every((word, at) => args[at] === word), "isCommandServer");
|
|
30
30
|
|
|
31
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
31
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/cli/command-server.js
|
|
32
32
|
var COMMAND_SERVER_PROTOCOL = 1;
|
|
33
33
|
var COMMAND_SERVER_IDLE_MS = 10 * 6e4;
|
|
34
34
|
var COMMAND_SERVER_CONCURRENT = 8;
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__name
|
|
5
5
|
} from "./chunk-ZVVMGPBJ.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
7
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/executable.js
|
|
8
8
|
import { existsSync } from "node:fs";
|
|
9
9
|
import { win32 } from "node:path";
|
|
10
10
|
var variable = /* @__PURE__ */ __name((env, name) => Object.entries(env).find(([key]) => key.toUpperCase() === name)?.[1], "variable");
|
|
@@ -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.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/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,15 +5,15 @@ import {
|
|
|
5
5
|
} from "./chunk-Y5E2WNWB.js";
|
|
6
6
|
import {
|
|
7
7
|
CliError
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-AP3CWDRK.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.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/speech/recognize.js
|
|
14
14
|
import { createRequire } from "node:module";
|
|
15
15
|
|
|
16
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
16
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/speech/ogg-limit.js
|
|
17
17
|
var invalid = /* @__PURE__ */ __name(() => new CliError("validation_error", "local transcription needs a complete mono or stereo Ogg Opus recording"), "invalid");
|
|
18
18
|
var checkOggDuration = /* @__PURE__ */ __name((bytes) => {
|
|
19
19
|
const view = new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength);
|
|
@@ -70,7 +70,7 @@ var checkOggDuration = /* @__PURE__ */ __name((bytes) => {
|
|
|
70
70
|
throw invalid();
|
|
71
71
|
}, "checkOggDuration");
|
|
72
72
|
|
|
73
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
73
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/speech/recognize.js
|
|
74
74
|
var SAMPLE_RATE = 16e3;
|
|
75
75
|
var LEAD = SAMPLE_RATE / 2;
|
|
76
76
|
var toModelRate = /* @__PURE__ */ __name((samples, rate) => {
|
|
@@ -12,31 +12,31 @@ import {
|
|
|
12
12
|
refuseWriteBeforeConnecting,
|
|
13
13
|
registerPrompts,
|
|
14
14
|
syncsFirst
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-MSQGZHKM.js";
|
|
16
16
|
import {
|
|
17
17
|
skillResources
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-WE4JSHIG.js";
|
|
19
19
|
import {
|
|
20
20
|
StdioServerTransport,
|
|
21
21
|
answeredWire,
|
|
22
22
|
serveStdio
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-NQOQG7L3.js";
|
|
24
24
|
import {
|
|
25
25
|
stdinFieldOf
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-TAPQZYXY.js";
|
|
27
27
|
import {
|
|
28
28
|
connectedFor
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-3HS7JTPI.js";
|
|
30
30
|
import {
|
|
31
31
|
wholeList
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-VR2CJFVL.js";
|
|
33
33
|
import {
|
|
34
34
|
runCommandForAgent,
|
|
35
35
|
toolsFromCommands
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-5VTKBGPW.js";
|
|
37
37
|
import {
|
|
38
38
|
instructions
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-UCGZRZJA.js";
|
|
40
40
|
import {
|
|
41
41
|
BinaryResource,
|
|
42
42
|
Picture,
|
|
@@ -55,35 +55,35 @@ import {
|
|
|
55
55
|
tierOf,
|
|
56
56
|
tool,
|
|
57
57
|
toolKey
|
|
58
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-J2SCELII.js";
|
|
59
59
|
import {
|
|
60
60
|
agentJson
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-ID4GJFE7.js";
|
|
62
62
|
import {
|
|
63
63
|
guardFor,
|
|
64
64
|
imageSize,
|
|
65
65
|
lackedNeed,
|
|
66
66
|
servicesFor,
|
|
67
67
|
storedDeps
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-5O5WYSSO.js";
|
|
69
69
|
import {
|
|
70
70
|
callerOf,
|
|
71
71
|
callingAgent
|
|
72
|
-
} from "./chunk-
|
|
72
|
+
} from "./chunk-5NIIXJV3.js";
|
|
73
73
|
import {
|
|
74
74
|
capability,
|
|
75
75
|
dateWindow
|
|
76
|
-
} from "./chunk-
|
|
76
|
+
} from "./chunk-BU5CEMUH.js";
|
|
77
77
|
import {
|
|
78
78
|
McpServer,
|
|
79
79
|
ResourceTemplate
|
|
80
80
|
} from "./chunk-PL5P7UKW.js";
|
|
81
81
|
import {
|
|
82
82
|
mcpHttpMarker
|
|
83
|
-
} from "./chunk-
|
|
83
|
+
} from "./chunk-RLNPTES2.js";
|
|
84
84
|
import {
|
|
85
85
|
findCommand
|
|
86
|
-
} from "./chunk-
|
|
86
|
+
} from "./chunk-2I2KBCS6.js";
|
|
87
87
|
import {
|
|
88
88
|
DEFAULT_OUTPUT_BYTES,
|
|
89
89
|
changesAuthorityAt,
|
|
@@ -98,35 +98,35 @@ import {
|
|
|
98
98
|
rootOf2 as rootOf,
|
|
99
99
|
sealed,
|
|
100
100
|
snakeKeys
|
|
101
|
-
} from "./chunk-
|
|
101
|
+
} from "./chunk-ZERQSELP.js";
|
|
102
102
|
import {
|
|
103
103
|
withCaller
|
|
104
|
-
} from "./chunk-
|
|
104
|
+
} from "./chunk-I75ON7VM.js";
|
|
105
105
|
import {
|
|
106
106
|
openStore,
|
|
107
107
|
pdfPreviewLimits
|
|
108
|
-
} from "./chunk-
|
|
108
|
+
} from "./chunk-PDVMYIBP.js";
|
|
109
109
|
import {
|
|
110
110
|
typedCommand
|
|
111
|
-
} from "./chunk-
|
|
111
|
+
} from "./chunk-V7N2K5OT.js";
|
|
112
112
|
import {
|
|
113
113
|
isCliFailure
|
|
114
|
-
} from "./chunk-
|
|
114
|
+
} from "./chunk-HZIGGAC7.js";
|
|
115
115
|
import {
|
|
116
116
|
warmEmbedders
|
|
117
|
-
} from "./chunk-
|
|
117
|
+
} from "./chunk-JFLKTYH5.js";
|
|
118
118
|
import {
|
|
119
119
|
fetchesAt,
|
|
120
120
|
levelFor,
|
|
121
121
|
readKeysForCommand
|
|
122
|
-
} from "./chunk-
|
|
122
|
+
} from "./chunk-G6LDK6DJ.js";
|
|
123
123
|
import {
|
|
124
124
|
timezoneOf
|
|
125
|
-
} from "./chunk-
|
|
125
|
+
} from "./chunk-UVGJL753.js";
|
|
126
126
|
import {
|
|
127
127
|
errorObjectOf,
|
|
128
128
|
mcpErrorResult
|
|
129
|
-
} from "./chunk-
|
|
129
|
+
} from "./chunk-H5HBZCEJ.js";
|
|
130
130
|
import {
|
|
131
131
|
description,
|
|
132
132
|
integer,
|
|
@@ -145,15 +145,15 @@ import {
|
|
|
145
145
|
import {
|
|
146
146
|
CliError,
|
|
147
147
|
visibleControls
|
|
148
|
-
} from "./chunk-
|
|
148
|
+
} from "./chunk-AP3CWDRK.js";
|
|
149
149
|
import {
|
|
150
150
|
__name
|
|
151
151
|
} from "./chunk-ZVVMGPBJ.js";
|
|
152
152
|
|
|
153
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
153
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/server.js
|
|
154
154
|
import { randomUUID } from "node:crypto";
|
|
155
155
|
|
|
156
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
156
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/agent-log.js
|
|
157
157
|
var agentLog = /* @__PURE__ */ __name((open) => {
|
|
158
158
|
let held;
|
|
159
159
|
return {
|
|
@@ -172,7 +172,7 @@ var agentLog = /* @__PURE__ */ __name((open) => {
|
|
|
172
172
|
};
|
|
173
173
|
}, "agentLog");
|
|
174
174
|
|
|
175
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
175
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/resources.js
|
|
176
176
|
var LISTED = 100;
|
|
177
177
|
var registerResources = /* @__PURE__ */ __name((server, session, { command, name, limit, recorded, withStore, messenger, guard, assertRead }) => {
|
|
178
178
|
server.registerResource("chat", new ResourceTemplate(`${command}://chat/{id}`, {
|
|
@@ -210,7 +210,7 @@ var registerResources = /* @__PURE__ */ __name((server, session, { command, name
|
|
|
210
210
|
});
|
|
211
211
|
}, "registerResources");
|
|
212
212
|
|
|
213
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
213
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/session.js
|
|
214
214
|
var HARMLESS = /* @__PURE__ */ new Set(["validation_error", "not_found", "permission_error", "confirmation_required", "rate_limited"]);
|
|
215
215
|
var harmless = /* @__PURE__ */ __name((code) => HARMLESS.has(code), "harmless");
|
|
216
216
|
var MessengerSession = class {
|
|
@@ -285,7 +285,7 @@ var MessengerSession = class {
|
|
|
285
285
|
}
|
|
286
286
|
};
|
|
287
287
|
|
|
288
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
288
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/tools/attachments.js
|
|
289
289
|
var attachmentsTools = /* @__PURE__ */ __name((messenger) => {
|
|
290
290
|
const _command = messenger.app.command;
|
|
291
291
|
return {
|
|
@@ -339,7 +339,7 @@ var attachmentsTools = /* @__PURE__ */ __name((messenger) => {
|
|
|
339
339
|
};
|
|
340
340
|
}, "attachmentsTools");
|
|
341
341
|
|
|
342
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
342
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/tools/messages-photo.js
|
|
343
343
|
var PHOTO_LIMIT = 512 * 1024;
|
|
344
344
|
var IMAGE_TYPES = [
|
|
345
345
|
["image/jpeg", (b) => b[0] === 255 && b[1] === 216 && b[2] === 255],
|
|
@@ -395,7 +395,7 @@ var readUpTo = /* @__PURE__ */ __name(async (file, limit, saveIt) => {
|
|
|
395
395
|
return new Uint8Array(Buffer.concat(chunks));
|
|
396
396
|
}, "readUpTo");
|
|
397
397
|
|
|
398
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
398
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/tools/stats.js
|
|
399
399
|
var statsTools = /* @__PURE__ */ __name((messenger) => ({
|
|
400
400
|
stats_charts: tool({
|
|
401
401
|
title: "A chart from a chat's statistics",
|
|
@@ -432,14 +432,14 @@ var statsTools = /* @__PURE__ */ __name((messenger) => ({
|
|
|
432
432
|
})
|
|
433
433
|
}), "statsTools");
|
|
434
434
|
|
|
435
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
435
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/tools.js
|
|
436
436
|
var pictureTools = /* @__PURE__ */ __name((messenger) => Object.fromEntries(Object.entries({
|
|
437
437
|
...messagesPhotoTools(messenger),
|
|
438
438
|
...attachmentsTools(messenger),
|
|
439
439
|
...statsTools(messenger)
|
|
440
440
|
}).map(([name, definition]) => [name, { ...definition, input: strictObject(definition.input.entries) }])), "pictureTools");
|
|
441
441
|
|
|
442
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
442
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.734.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_2c8b9986a0059051c16d1a97d78c2d87/node_modules/@wirecat/cli-core/dist/mcp/server.js
|
|
443
443
|
var PER_RUN = /* @__PURE__ */ new Set([
|
|
444
444
|
"streams",
|
|
445
445
|
"stdin",
|
|
@@ -755,7 +755,7 @@ var serveOverStdio = /* @__PURE__ */ __name(async (command, context, messenger,
|
|
|
755
755
|
}, "serveOverStdio");
|
|
756
756
|
var serveOverHttpUntilStopped = /* @__PURE__ */ __name(async (command, context, messenger, options, http) => {
|
|
757
757
|
const { session, embedders, build, log } = createServer(command, context, messenger, options);
|
|
758
|
-
const { serveOverHttp } = await import("./serve-
|
|
758
|
+
const { serveOverHttp } = await import("./serve-4KBJ6SIA.js");
|
|
759
759
|
const appName = messenger.app.command;
|
|
760
760
|
const appEnvPrefix = messenger.app.envPrefix;
|
|
761
761
|
const listening = await serveOverHttp(build, {
|