@wirecat/hubspot-cli 0.5.0 → 0.7.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 +50 -0
- package/README.md +73 -52
- package/contracts/wirecat.json +39 -13
- package/dist/bin/hubspot.js +2 -2
- package/dist/bundle/agent-JXICB6TB.js +40 -0
- package/dist/bundle/{all-profiles-PGFXLOKN.js → all-profiles-GVEX5MXB.js} +11 -11
- package/dist/bundle/{anthropic-LPOJ3TYF.js → anthropic-GK6VBQUD.js} +5 -5
- package/dist/bundle/{app-server-EYWGCSRY.js → app-server-JRROE463.js} +68 -68
- package/dist/bundle/{bun-ZJOOKIIW.js → bun-B7XTFPUF.js} +2 -2
- package/dist/bundle/{bun-sqlite-Y6KKH2OW.js → bun-sqlite-QSNZ2YP4.js} +6 -6
- package/dist/bundle/{chunk-DEUCWBBH.js → chunk-2FLLS5IL.js} +97 -24
- package/dist/bundle/{chunk-5ENY4POG.js → chunk-2HSYAKWO.js} +61 -61
- package/dist/bundle/{chunk-QLFD3MOL.js → chunk-2IRBXFIU.js} +2165 -839
- package/dist/bundle/{chunk-AIQT2GGK.js → chunk-2K5BAY32.js} +19 -19
- package/dist/bundle/{chunk-ZMHD76RE.js → chunk-2PCVKD27.js} +2 -2
- package/dist/bundle/{chunk-MENMD5Y5.js → chunk-2V5KOOJV.js} +8 -8
- package/dist/bundle/{chunk-QDNYJOWJ.js → chunk-3WG4MTQI.js} +1 -1
- package/dist/bundle/{chunk-MPNMEWHA.js → chunk-4F62XXF6.js} +2081 -711
- package/dist/bundle/{chunk-OFOA6VJ2.js → chunk-4HZQ5UIY.js} +3 -3
- package/dist/bundle/{chunk-QIHJKE4K.js → chunk-4LHNA6LJ.js} +7 -7
- package/dist/bundle/{chunk-7Q64D56R.js → chunk-52NC5E42.js} +11 -11
- package/dist/bundle/{chunk-ZLWQPUPB.js → chunk-5AVU5SF6.js} +2 -2
- package/dist/bundle/{chunk-MKBQFD37.js → chunk-5EJ3C3JG.js} +1 -1
- package/dist/bundle/{chunk-AVBKXCEY.js → chunk-5ISQ4KJM.js} +8 -8
- package/dist/bundle/{chunk-CWCJEAHZ.js → chunk-5MFZYHPO.js} +3 -3
- package/dist/bundle/{chunk-5WADRBQG.js → chunk-63YWTFZF.js} +3 -3
- package/dist/bundle/{chunk-I334AT2H.js → chunk-6EHX762H.js} +7 -7
- package/dist/bundle/{chunk-6S422S22.js → chunk-6IHXKMY6.js} +7 -9
- package/dist/bundle/{chunk-QCHW7R7L.js → chunk-6WKK4UZP.js} +1 -1
- package/dist/bundle/{chunk-VIJV474N.js → chunk-745FMNI5.js} +1 -1
- package/dist/bundle/{chunk-6PWRJGX4.js → chunk-A7KGBXBT.js} +4 -4
- package/dist/bundle/{chunk-HPRGUUHY.js → chunk-ALOPYWYY.js} +1 -1
- package/dist/bundle/{chunk-PMGAU6AP.js → chunk-AP3CWDRK.js} +2 -2
- package/dist/bundle/{chunk-LXLXF2OE.js → chunk-B3JVNOTB.js} +3 -3
- package/dist/bundle/{chunk-QPTHEZZ5.js → chunk-BQPAIGAF.js} +2 -2
- package/dist/bundle/{chunk-DDMBPYHP.js → chunk-BRBBZDMZ.js} +2 -2
- package/dist/bundle/{chunk-POTS24SH.js → chunk-BXXU4EXK.js} +18 -18
- package/dist/bundle/{chunk-34HDRZIL.js → chunk-BY3NKT34.js} +12 -12
- package/dist/bundle/{chunk-3CHJYWA2.js → chunk-CBTWKTWN.js} +6 -6
- package/dist/bundle/{chunk-RZS7N3OZ.js → chunk-CEHBT7QX.js} +7 -7
- package/dist/bundle/{chunk-NLPGUYCG.js → chunk-DBHJIFDS.js} +37 -18
- package/dist/bundle/{chunk-DJUUQG6Y.js → chunk-DIHVN5IC.js} +8 -8
- package/dist/bundle/{chunk-4RZ4DUQT.js → chunk-DIKUPU3T.js} +3 -3
- package/dist/bundle/{chunk-WEM4FZPM.js → chunk-DMYLQX2O.js} +2 -2
- package/dist/bundle/{chunk-LWS5AO3H.js → chunk-DWWZAQ4N.js} +16 -16
- package/dist/bundle/{chunk-NEP67GLY.js → chunk-GD5JTKLS.js} +6 -6
- package/dist/bundle/{chunk-KC4ILAKO.js → chunk-GHBJBDTW.js} +1 -1
- package/dist/bundle/{chunk-KRTXJMCD.js → chunk-GYH2AXPO.js} +27 -177
- package/dist/bundle/{chunk-K3WCBNH4.js → chunk-GZD6BYO7.js} +6 -6
- package/dist/bundle/{chunk-KAW5VEER.js → chunk-H5HBZCEJ.js} +8 -8
- package/dist/bundle/{chunk-VCYUYFIV.js → chunk-HX2BE7DO.js} +1 -1
- package/dist/bundle/{chunk-KXWRVLSU.js → chunk-I5WHQH5K.js} +1 -1
- package/dist/bundle/{chunk-R7ZOCDNG.js → chunk-INT5JXGP.js} +1 -1
- package/dist/bundle/{chunk-YZ5MULJM.js → chunk-IRFFXKKK.js} +3 -3
- package/dist/bundle/{chunk-SBNZYRVZ.js → chunk-J5HHB27S.js} +4 -4
- package/dist/bundle/{chunk-V5VMAHDQ.js → chunk-JEUYZCWF.js} +6 -6
- package/dist/bundle/{chunk-BH5FEFZB.js → chunk-JQUS4KFV.js} +2 -2
- package/dist/bundle/{chunk-5HGS65I3.js → chunk-KGLMYQXM.js} +2 -2
- package/dist/bundle/{chunk-AHZQMSXW.js → chunk-L3DUZVBP.js} +8 -8
- package/dist/bundle/{chunk-RJBKDZGV.js → chunk-LGGBKAVQ.js} +8 -8
- package/dist/bundle/{chunk-ODRF47VS.js → chunk-LJ52BS6C.js} +8 -8
- package/dist/bundle/{chunk-7RIE3DAW.js → chunk-M3JDGRXM.js} +221 -163
- package/dist/bundle/{chunk-BCW7DAVV.js → chunk-MR2BNER3.js} +2 -2
- package/dist/bundle/{chunk-OCISQFMW.js → chunk-NUPAXK4Z.js} +1 -1
- package/dist/bundle/{chunk-MW4ROXQ6.js → chunk-OX37ZK27.js} +3 -3
- package/dist/bundle/{chunk-MFWECOO3.js → chunk-P7N3TZLH.js} +59 -59
- package/dist/bundle/{chunk-L6WSFVTD.js → chunk-QAQK2WXJ.js} +5 -5
- package/dist/bundle/{chunk-EPBHJMF6.js → chunk-QY7EOB66.js} +13 -13
- package/dist/bundle/{chunk-HBFSGL5E.js → chunk-RE55EPBX.js} +33 -28
- package/dist/bundle/{chunk-ABPZOI3C.js → chunk-SBORPDIQ.js} +4 -4
- package/dist/bundle/{chunk-YQBGPBYN.js → chunk-SFFV2F3Y.js} +2 -2
- package/dist/bundle/{chunk-WQZENAPE.js → chunk-SMEEFN65.js} +63 -4
- package/dist/bundle/{chunk-GZJP3KQQ.js → chunk-SVRCPPNI.js} +1 -1
- package/dist/bundle/{chunk-BW7NPFVC.js → chunk-SZZVNPTI.js} +7 -7
- package/dist/bundle/{chunk-HPSESLOZ.js → chunk-TCSVW7BA.js} +1 -1
- package/dist/bundle/{chunk-L4SVHQ7H.js → chunk-TXCINEH6.js} +7 -7
- package/dist/bundle/{chunk-BGUGTMTS.js → chunk-UMXA357W.js} +8 -8
- package/dist/bundle/{chunk-PPQRWFJZ.js → chunk-VJQLJQHT.js} +5 -5
- package/dist/bundle/{chunk-EGR3YUWD.js → chunk-WASBOYI2.js} +4 -4
- package/dist/bundle/{chunk-Z7FC6VVM.js → chunk-WSTF2MWW.js} +1 -1
- package/dist/bundle/{chunk-BVK4GUUI.js → chunk-WSUS3MUK.js} +1853 -1874
- package/dist/bundle/{chunk-A5UTNGI4.js → chunk-WWIYZN67.js} +13 -13
- package/dist/bundle/{chunk-STTHRJBX.js → chunk-XL3NAXZY.js} +5 -5
- package/dist/bundle/{chunk-23CLSKY7.js → chunk-XWYYFAML.js} +3 -3
- package/dist/bundle/{chunk-MPQ4SPZG.js → chunk-XZLOQNS7.js} +74 -31
- package/dist/bundle/{chunk-MGMLSPIY.js → chunk-YDTFPDAJ.js} +1 -1
- package/dist/bundle/{chunk-ZKPM53YG.js → chunk-YFHCKAGU.js} +4 -4
- package/dist/bundle/{chunk-WDR77HPO.js → chunk-YGZ37OEN.js} +8 -1
- package/dist/bundle/{chunk-YJLJZMEA.js → chunk-YOVIH4QI.js} +33 -30
- package/dist/bundle/{chunk-NEDV6RCQ.js → chunk-YVMLFHWS.js} +3 -3
- package/dist/bundle/{chunk-K5S7MKBB.js → chunk-ZH76HQDA.js} +17 -17
- package/dist/bundle/{chunk-WXEN6AXQ.js → chunk-ZNNGK73C.js} +3 -3
- package/dist/bundle/{chunk-NKIKMG33.js → chunk-ZNRZJIRM.js} +35 -35
- package/dist/bundle/{chunk-5UPNDUAA.js → chunk-ZS6T2PYQ.js} +2 -2
- package/dist/bundle/command-contract-7EWUA6E6.js +40 -0
- package/dist/bundle/{command-server-entry-B7S5AUE6.js → command-server-entry-BFXXPNJO.js} +28 -28
- package/dist/bundle/{decode-7L33C5UJ.js → decode-5M7R44BR.js} +5 -5
- package/dist/bundle/{dispatch-BIGHHSXV.js → dispatch-B2EP6DDT.js} +8 -8
- package/dist/bundle/{echarts-CWR3QH55.js → echarts-7MBFY6SZ.js} +2 -2
- package/dist/bundle/{embed-GXQ3HOQ6.js → embed-Y4GYNHRX.js} +6 -6
- package/dist/bundle/{embedder-47OYXGLS.js → embedder-FI4T4LQB.js} +9 -9
- package/dist/bundle/{failure-VMZOU5GZ.js → failure-AOACEURF.js} +2 -2
- package/dist/bundle/{first-run-YVQQOUQG.js → first-run-YY66AKKG.js} +12 -12
- package/dist/bundle/first-screen-U7Z63VXE.js +40 -0
- package/dist/bundle/hubspot.js +27 -27
- package/dist/bundle/{instructions-QFS2MPK3.js → instructions-SM7TKV6L.js} +1 -1
- package/dist/bundle/{mcp-Z2KZNCXB.js → mcp-ZNULRPZ4.js} +2 -2
- package/dist/bundle/meeting-combined-B444C4NF.js +25 -0
- package/dist/bundle/{meeting-model-GLF2HVJG.js → meeting-model-DKLMBQXX.js} +11 -11
- package/dist/bundle/{meeting-semantic-RG56F4YX.js → meeting-semantic-C5T6UDVB.js} +6 -6
- package/dist/bundle/{node-3TSWTXGI.js → node-OS6OQF3F.js} +2 -2
- package/dist/bundle/{node-sqlite-UPQCG7DJ.js → node-sqlite-2XTWZ4HL.js} +7 -7
- package/dist/bundle/{oauth-MCVEENW3.js → oauth-BSSJ66FC.js} +7 -7
- package/dist/bundle/{open-JMUTKUYJ.js → open-UZ3TKWDY.js} +5 -5
- package/dist/bundle/{openai-HT7YDOK7.js → openai-POVKFBTC.js} +15 -15
- package/dist/bundle/{process-7RC6DAGM.js → process-A7ZJGQ6G.js} +1 -1
- package/dist/bundle/{program-3DLBMOEJ.js → program-Q3JFUVC6.js} +582 -337
- package/dist/bundle/{prompt-7EROPXPF.js → prompt-TYOYTRJM.js} +5 -5
- package/dist/bundle/{recognize-B232GXD2.js → recognize-GGFRONZT.js} +4 -4
- package/dist/bundle/{remote-HGV64VRC.js → remote-K4SLWHMI.js} +9 -9
- package/dist/bundle/{rerank-5S6TDXHD.js → rerank-2QTKDUBV.js} +7 -7
- package/dist/bundle/{schemas-SB42IXEX.js → schemas-EXBNVPMI.js} +1 -1
- package/dist/bundle/{serve-D2WFCV6Z.js → serve-FG2G2X6Y.js} +9 -9
- package/dist/bundle/{server-4AXPTJPV.js → server-KRDHBT5Q.js} +60 -60
- package/dist/bundle/server-VFKK6OS4.js +86 -0
- package/dist/bundle/source-XP2JNUVU.js +426 -0
- package/dist/bundle/{sqlite-runtime-DAFMZNLI.js → sqlite-runtime-TWV7KFLA.js} +6 -6
- package/dist/bundle/{state-7OEBDXVV.js → state-EFX5ZQED.js} +6 -6
- package/dist/bundle/store-LON2XRIS.js +34 -0
- package/dist/bundle/{store-2ZWSWF76.js → store-MNQ6YQIS.js} +28 -24
- package/dist/bundle/{store-KC6US326.js → store-QPVH5VPJ.js} +22 -22
- package/dist/bundle/store-maintenance-command-YEMPRNJX.js +73 -0
- package/dist/bundle/surface-UJRMT6QT.js +72 -0
- package/dist/bundle/writer-NOSHE7ZI.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 +16 -10
- 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/records.d.ts.map +1 -1
- package/dist/crm/records.js +3 -0
- package/dist/crm/records.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 +3 -3
- package/skills/hubspot-cli/SKILL.md +17 -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-RBQMA24N.js +0 -40
- package/dist/bundle/command-contract-O2UKYHLD.js +0 -40
- package/dist/bundle/first-screen-TU3KE2B5.js +0 -40
- package/dist/bundle/meeting-combined-WBEOLQMP.js +0 -25
- package/dist/bundle/server-FFHVNABP.js +0 -86
- package/dist/bundle/source-DF63EC2B.js +0 -945
- package/dist/bundle/store-Q3ZKD4FJ.js +0 -34
- package/dist/bundle/store-maintenance-command-24A4GBRP.js +0 -73
- package/dist/bundle/surface-SPTM57EP.js +0 -72
- package/dist/bundle/writer-EQQ55HOS.js +0 -86
|
@@ -5,16 +5,16 @@ import {
|
|
|
5
5
|
UNTRUSTED_NEUTRAL,
|
|
6
6
|
agentArguments,
|
|
7
7
|
agentJson
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-LJ52BS6C.js";
|
|
9
9
|
import {
|
|
10
10
|
onlineDeps,
|
|
11
11
|
refuseLacking,
|
|
12
12
|
servicesFor,
|
|
13
13
|
storeModeDeps
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-4F62XXF6.js";
|
|
15
15
|
import {
|
|
16
16
|
callerOf
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-BQPAIGAF.js";
|
|
18
18
|
import {
|
|
19
19
|
DEFAULT_OUTPUT_BYTES,
|
|
20
20
|
ENTITIES,
|
|
@@ -27,35 +27,35 @@ import {
|
|
|
27
27
|
refuseStoreChange,
|
|
28
28
|
sealed,
|
|
29
29
|
startRecording
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-M3JDGRXM.js";
|
|
31
31
|
import {
|
|
32
32
|
currentCaller,
|
|
33
33
|
keepsSuccess,
|
|
34
34
|
runContextOf,
|
|
35
35
|
withCaller
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-LGGBKAVQ.js";
|
|
37
37
|
import {
|
|
38
38
|
inRun,
|
|
39
39
|
newRunId
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-YOVIH4QI.js";
|
|
41
41
|
import {
|
|
42
42
|
storeDamaged
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-BRBBZDMZ.js";
|
|
44
44
|
import {
|
|
45
45
|
failureContext
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-2FLLS5IL.js";
|
|
47
47
|
import {
|
|
48
48
|
fetchesAt,
|
|
49
49
|
keyForCommand,
|
|
50
50
|
levelFor,
|
|
51
51
|
readKeysForCommand
|
|
52
|
-
} from "./chunk-
|
|
52
|
+
} from "./chunk-SZZVNPTI.js";
|
|
53
53
|
import {
|
|
54
54
|
MAX_BUFFERED_INPUT
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-ZS6T2PYQ.js";
|
|
56
56
|
import {
|
|
57
57
|
traceIdOf
|
|
58
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-2K5BAY32.js";
|
|
59
59
|
import {
|
|
60
60
|
errorObjectOf,
|
|
61
61
|
itemEnvelopeSchema,
|
|
@@ -63,7 +63,7 @@ import {
|
|
|
63
63
|
mcpErrorResult,
|
|
64
64
|
toJsonSchema,
|
|
65
65
|
toStandardJsonSchema
|
|
66
|
-
} from "./chunk-
|
|
66
|
+
} from "./chunk-H5HBZCEJ.js";
|
|
67
67
|
import {
|
|
68
68
|
array,
|
|
69
69
|
boolean,
|
|
@@ -88,15 +88,15 @@ import {
|
|
|
88
88
|
import {
|
|
89
89
|
CliError,
|
|
90
90
|
errorCodes
|
|
91
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-AP3CWDRK.js";
|
|
92
92
|
import {
|
|
93
93
|
__name
|
|
94
94
|
} from "./chunk-ZVVMGPBJ.js";
|
|
95
95
|
|
|
96
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
96
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/mcp/surface.js
|
|
97
97
|
import { randomUUID } from "node:crypto";
|
|
98
98
|
|
|
99
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
99
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/mcp/tool.js
|
|
100
100
|
var limit = optional(pipe(number(), integer(), minValue(1), maxValue(100), description("how many")));
|
|
101
101
|
var page = optional(pipe(number(), integer(), minValue(1), description("which page, from 1")));
|
|
102
102
|
var message = pipe(
|
|
@@ -355,7 +355,7 @@ var failed = /* @__PURE__ */ __name((error, errors, effects) => {
|
|
|
355
355
|
return mcpErrorResult(JSON.parse(agentJson(errorObjectOf(storeDamaged(error), context))));
|
|
356
356
|
}, "failed");
|
|
357
357
|
|
|
358
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
358
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/mcp/surface.js
|
|
359
359
|
var MATCHES = 8;
|
|
360
360
|
var ANSWER = answerSchema();
|
|
361
361
|
var agentAnswer = /* @__PURE__ */ __name((prefix, writes) => {
|
|
@@ -5,31 +5,31 @@ import {
|
|
|
5
5
|
isNewer,
|
|
6
6
|
readNoticeState,
|
|
7
7
|
writeUpdateState
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-DIKUPU3T.js";
|
|
9
9
|
import {
|
|
10
10
|
executableEnvironment,
|
|
11
11
|
executableOnPath
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-3WG4MTQI.js";
|
|
13
13
|
import {
|
|
14
14
|
Command,
|
|
15
15
|
Option,
|
|
16
16
|
annotate
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-M3JDGRXM.js";
|
|
18
18
|
import {
|
|
19
19
|
require_cross_spawn
|
|
20
20
|
} from "./chunk-D72URWJE.js";
|
|
21
21
|
import {
|
|
22
22
|
refuseOwnerHomeInTests
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-2K5BAY32.js";
|
|
24
24
|
import {
|
|
25
25
|
CliError
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-AP3CWDRK.js";
|
|
27
27
|
import {
|
|
28
28
|
__name,
|
|
29
29
|
__toESM
|
|
30
30
|
} from "./chunk-ZVVMGPBJ.js";
|
|
31
31
|
|
|
32
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
32
|
+
// 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/skill/index.js
|
|
33
33
|
import { existsSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
34
34
|
import { homedir } from "node:os";
|
|
35
35
|
import { basename, dirname, join, relative, resolve, sep } from "node: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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/runs/secrets.js
|
|
8
8
|
var SECRET_WORDS = /* @__PURE__ */ new Set([
|
|
9
9
|
"authorization",
|
|
10
10
|
"cookie",
|
|
@@ -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-4F62XXF6.js";
|
|
21
23
|
import {
|
|
22
24
|
capability,
|
|
23
25
|
throughWrapper
|
|
24
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-QY7EOB66.js";
|
|
25
27
|
import {
|
|
26
28
|
servingProfiles
|
|
27
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-ZNNGK73C.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-M3JDGRXM.js";
|
|
42
41
|
import {
|
|
43
42
|
providerErrorKey
|
|
44
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-LGGBKAVQ.js";
|
|
45
44
|
import {
|
|
46
45
|
openStore
|
|
47
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-2IRBXFIU.js";
|
|
48
47
|
import {
|
|
49
48
|
isCliFailure
|
|
50
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-BRBBZDMZ.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-BW7NPFVC.js";
|
|
54
|
+
readKeysForCommand
|
|
55
|
+
} from "./chunk-SZZVNPTI.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-BXXU4EXK.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.715.0_@wirecat+cli-base@0.125.1_commander@15.0.0_esbuild@0.28.2_typ_f3540c99972bb5f0aa92997a79a368b4/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.715.0_@wirecat+cli-base@0.125.1_commander@15.0.0_esbuild@0.28.2_typ_f3540c99972bb5f0aa92997a79a368b4/node_modules/@wirecat/cli-core/dist/cli/messenger/flooded.js
|
|
70
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/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,
|
|
@@ -5,23 +5,23 @@ import {
|
|
|
5
5
|
installFiles,
|
|
6
6
|
megabytes,
|
|
7
7
|
sharedModelsDirectory
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-A7KGBXBT.js";
|
|
9
9
|
import {
|
|
10
10
|
importFrom
|
|
11
11
|
} from "./chunk-Y5E2WNWB.js";
|
|
12
12
|
import {
|
|
13
13
|
CliError
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-AP3CWDRK.js";
|
|
15
15
|
import {
|
|
16
16
|
__name
|
|
17
17
|
} from "./chunk-ZVVMGPBJ.js";
|
|
18
18
|
|
|
19
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
19
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/embeddings/embed.js
|
|
20
20
|
import { readFileSync as readFileSync2 } from "node:fs";
|
|
21
21
|
import { availableParallelism } from "node:os";
|
|
22
22
|
import { basename, join as join2 } from "node:path";
|
|
23
23
|
|
|
24
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
24
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/embeddings/onnx-runtime.js
|
|
25
25
|
import { createHash } from "node:crypto";
|
|
26
26
|
import { copyFileSync, mkdirSync, mkdtempSync, readFileSync, renameSync, rmSync, statSync, writeFileSync } from "node:fs";
|
|
27
27
|
import { join } from "node:path";
|
|
@@ -678,7 +678,7 @@ var Unzip = /* @__PURE__ */ (function() {
|
|
|
678
678
|
return Unzip2;
|
|
679
679
|
})();
|
|
680
680
|
|
|
681
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
681
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/embeddings/onnx-runtime.js
|
|
682
682
|
var ONNX_RUNTIME_VERSION = "1.30.0";
|
|
683
683
|
var REGISTRY = "https://registry.npmjs.org";
|
|
684
684
|
var wirecat = /* @__PURE__ */ __name((target, sha256, bytes, library) => ({
|
|
@@ -837,7 +837,7 @@ var openSession = /* @__PURE__ */ __name(async (bytes, threads, options = {}) =>
|
|
|
837
837
|
return { ort, session: await ort.InferenceSession.create(bytes, options) };
|
|
838
838
|
}, "openSession");
|
|
839
839
|
|
|
840
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
840
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/embeddings/embed.js
|
|
841
841
|
var textModelsDirectory = /* @__PURE__ */ __name((env = process.env) => sharedModelsDirectory("text", env), "textModelsDirectory");
|
|
842
842
|
var placedText = /* @__PURE__ */ __name((model, directory) => model.files.map((file) => [file, join2(directory, model.id, file.name)]), "placedText");
|
|
843
843
|
var isTextModelInstalled = /* @__PURE__ */ __name((model, directory) => filesPresent(placedText(model, directory)), "isTextModelInstalled");
|
|
@@ -29,12 +29,12 @@ import {
|
|
|
29
29
|
errorCodes,
|
|
30
30
|
isCliError,
|
|
31
31
|
visibleControls
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-AP3CWDRK.js";
|
|
33
33
|
import {
|
|
34
34
|
__name
|
|
35
35
|
} from "./chunk-ZVVMGPBJ.js";
|
|
36
36
|
|
|
37
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
37
|
+
// 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/exit-codes.js
|
|
38
38
|
var EXIT_CODES = {
|
|
39
39
|
validation_error: 2,
|
|
40
40
|
configuration_error: 3,
|
|
@@ -55,7 +55,7 @@ var EXIT_CODES = {
|
|
|
55
55
|
var exitCodeFor = /* @__PURE__ */ __name((code) => EXIT_CODES[code], "exitCodeFor");
|
|
56
56
|
var GENERIC_FAILURE = 1;
|
|
57
57
|
|
|
58
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
58
|
+
// 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/standards/effects.js
|
|
59
59
|
var EFFECT_LEVELS = ["none", "read", "write"];
|
|
60
60
|
var effectsSchema = strictObject({
|
|
61
61
|
remote: picklist(EFFECT_LEVELS),
|
|
@@ -692,7 +692,7 @@ function toStandardJsonSchema(schema) {
|
|
|
692
692
|
}
|
|
693
693
|
__name(toStandardJsonSchema, "toStandardJsonSchema");
|
|
694
694
|
|
|
695
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
695
|
+
// 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/standards/registry.js
|
|
696
696
|
var word = pipe(string(), regex(/^[a-z][a-z0-9]*(-[a-z0-9]+)*$/, "a lower-case word, words joined by -"));
|
|
697
697
|
var SNAKE_CASE = /^[a-z][a-z0-9]*(_[a-z0-9]+)*$/;
|
|
698
698
|
var text = pipe(string(), regex(/\S/, "must not be empty"));
|
|
@@ -734,7 +734,7 @@ var fill = /* @__PURE__ */ __name((template, values) => template.replace(PLACEHO
|
|
|
734
734
|
return String(value);
|
|
735
735
|
}), "fill");
|
|
736
736
|
|
|
737
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
737
|
+
// 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/standards/output.js
|
|
738
738
|
var MAX_NEXT_STEPS = 2;
|
|
739
739
|
var COMPACT_FLAG = "--compact";
|
|
740
740
|
var isoTime = pipe(string(), isoTimestamp("an ISO 8601 time in UTC"), endsWith("Z", "an ISO 8601 time in UTC, ending in `Z`"));
|
|
@@ -879,7 +879,7 @@ var jsonlOf = /* @__PURE__ */ __name(({ items, page, meta }) => [
|
|
|
879
879
|
JSON.stringify({ type: "end", complete: meta.complete, ...meta.issues ? { issues: meta.issues } : {}, page })
|
|
880
880
|
].join("\n"), "jsonlOf");
|
|
881
881
|
|
|
882
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
882
|
+
// 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/standards/errors.js
|
|
883
883
|
var CRASH_CODE = "internal_error";
|
|
884
884
|
var CRASH_REASON = "command.crashed";
|
|
885
885
|
var errorObjectSchema = strictObject({
|
|
@@ -978,7 +978,7 @@ var BASE_REASONS = defineReasons([
|
|
|
978
978
|
{ reason: CRASH_REASON, code: CRASH_CODE, message: "the command failed; this is a bug", details: [] }
|
|
979
979
|
]);
|
|
980
980
|
|
|
981
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
981
|
+
// 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/standards/steps.js
|
|
982
982
|
var SAME_COMMAND = "*";
|
|
983
983
|
var commandPath = pipe(string(), regex(/^[a-z][a-z0-9-]*( [a-z][a-z0-9-]*)*$/, "a command path such as `messages sync`"));
|
|
984
984
|
var stepSchema = union([
|
|
@@ -1057,7 +1057,7 @@ var STEPS = defineSteps([
|
|
|
1057
1057
|
}
|
|
1058
1058
|
]);
|
|
1059
1059
|
|
|
1060
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1060
|
+
// 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/failure.js
|
|
1061
1061
|
var recognise = /* @__PURE__ */ __name((failure) => {
|
|
1062
1062
|
if (isCliError(failure))
|
|
1063
1063
|
return failure;
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
__name
|
|
11
11
|
} from "./chunk-ZVVMGPBJ.js";
|
|
12
12
|
|
|
13
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
13
|
+
// 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/codegen/runtime.js
|
|
14
14
|
var isLossless = /* @__PURE__ */ __name((input) => typeof input === "object" && input !== null && input.isLosslessNumber === true && typeof input.value === "string", "isLossless");
|
|
15
15
|
var INTEGER = /^-?\d+$/;
|
|
16
16
|
var INT64_MIN = -(2n ** 63n);
|
|
@@ -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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/store/normalize.js
|
|
8
8
|
var NORMALIZER_VERSION = 1;
|
|
9
9
|
var fold = /* @__PURE__ */ __name((text) => text.normalize("NFKD").replace(new RegExp("\\p{M}+", "gu"), "").normalize("NFC").toLowerCase(), "fold");
|
|
10
10
|
var normalize = /* @__PURE__ */ __name((text) => fold(text).replace(new RegExp("\\p{Cc}", "gu"), " ").replace(/\s+/gu, " ").trim(), "normalize");
|
|
@@ -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.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/background/processes.js
|
|
8
8
|
import { execFileSync } from "node:child_process";
|
|
9
9
|
import { readdirSync, readFileSync, readlinkSync } from "node:fs";
|
|
10
10
|
var alive = /* @__PURE__ */ __name((pid) => {
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
id,
|
|
6
6
|
text,
|
|
7
7
|
time
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-YOVIH4QI.js";
|
|
9
9
|
import {
|
|
10
10
|
reference
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-H5HBZCEJ.js";
|
|
12
12
|
import {
|
|
13
13
|
array,
|
|
14
14
|
nullable,
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
unknown
|
|
21
21
|
} from "./chunk-S4UUN6LD.js";
|
|
22
22
|
|
|
23
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
23
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.748.0_@wirecat+cli-base@0.127.0_commander@15.0.0_esbuild@0.28.2_typ_80da9f03871bc395375181cc05991961/node_modules/@wirecat/cli-core/dist/entities/note.js
|
|
24
24
|
var link = {
|
|
25
25
|
target_text: nullable(text),
|
|
26
26
|
kind: text,
|