@wirecat/tg-cli 0.122.0 → 0.124.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/contracts/wirecat.json +62 -4
- package/dist/bin/tg.js +2 -2
- package/dist/bundle/{adapter-ZI57T2L5.js → adapter-GEIZVMWU.js} +55 -53
- package/dist/bundle/{all-profiles-7VXJF42C.js → all-profiles-EY4GJFWN.js} +10 -10
- package/dist/bundle/{anthropic-DKRXIWVV.js → anthropic-RIANJ7WM.js} +17 -10
- package/dist/bundle/{app-server-F5MKHZ7S.js → app-server-LW7WBFIF.js} +62 -52
- package/dist/bundle/{bot-api-F24NWJT3.js → bot-api-FHIQ66OM.js} +54 -52
- package/dist/bundle/{bot-history-U3WM3A7S.js → bot-history-O34YZEFH.js} +18 -18
- package/dist/bundle/{bun-OMTJAXGK.js → bun-MJWD4VGV.js} +2 -2
- package/dist/bundle/{bun-sqlite-HSYLO46A.js → bun-sqlite-LCHVO3OB.js} +9 -5
- package/dist/bundle/{chunk-DCGGZUNJ.js → chunk-2GFGZDWS.js} +2 -2
- package/dist/bundle/{chunk-7FWU4RON.js → chunk-2NG4JPP7.js} +4 -4
- package/dist/bundle/{chunk-UGEYQWEO.js → chunk-2YLIVDWJ.js} +2 -2
- package/dist/bundle/chunk-3PLMMFP6.js +1068 -0
- package/dist/bundle/{chunk-27SVHRHV.js → chunk-3VVZFBE2.js} +23 -4
- package/dist/bundle/{chunk-FYHFAOPM.js → chunk-42R4YO4L.js} +12064 -9579
- package/dist/bundle/{chunk-U6HEZPCR.js → chunk-4CIVGT4P.js} +57 -28
- package/dist/bundle/{chunk-CB6AHU6H.js → chunk-4EGB7GSW.js} +96 -19
- package/dist/bundle/chunk-54JPEGQA.js +71 -0
- package/dist/bundle/chunk-5EL6E6PW.js +13 -0
- package/dist/bundle/{chunk-QROAXWDU.js → chunk-7AWJZ6NJ.js} +8 -8
- package/dist/bundle/{chunk-2UHANFLM.js → chunk-A5RWKKBZ.js} +3 -3
- package/dist/bundle/{chunk-7I6YVQHW.js → chunk-ASEBKZFY.js} +2 -2
- package/dist/bundle/{chunk-SODUFMDW.js → chunk-BV3HZYOX.js} +7435 -6559
- package/dist/bundle/{chunk-FHWUOFWX.js → chunk-CDSSKK5J.js} +3 -3
- package/dist/bundle/{chunk-6LMEIELG.js → chunk-DFSLHF46.js} +1 -1
- package/dist/bundle/{chunk-Y74WJL3M.js → chunk-E66JBGZZ.js} +6 -6
- package/dist/bundle/{chunk-VUBZFMGP.js → chunk-E6VSARSU.js} +2 -2
- package/dist/bundle/{chunk-MFWWZ6XL.js → chunk-F3GHTPAO.js} +4 -4
- package/dist/bundle/{chunk-NU4RMUMQ.js → chunk-GUL6QLNI.js} +40 -21
- package/dist/bundle/{chunk-E3MFMMVY.js → chunk-HEV23NIB.js} +6 -6
- package/dist/bundle/{chunk-FZKHFTKH.js → chunk-HSRO77SW.js} +35 -29
- package/dist/bundle/{chunk-FATTEYZH.js → chunk-I4JUKRW7.js} +2 -2
- package/dist/bundle/{chunk-YDMKP7PO.js → chunk-IK6XKMLL.js} +1 -1
- package/dist/bundle/{chunk-DDSAJKPO.js → chunk-ISGXVFA4.js} +4 -4
- package/dist/bundle/chunk-IVFUSI7G.js +53 -0
- package/dist/bundle/{chunk-DTTONQW7.js → chunk-KVJSCJGZ.js} +2 -2
- package/dist/bundle/{chunk-NE3EGYPD.js → chunk-LKMZ53GC.js} +4 -7
- package/dist/bundle/{chunk-YFEH7OWG.js → chunk-M4W4Y5YR.js} +132 -40
- package/dist/bundle/{chunk-R2IW6JBV.js → chunk-N5UM63JW.js} +343 -112
- package/dist/bundle/{chunk-V4BPS7MH.js → chunk-NL4COYPY.js} +9 -9
- package/dist/bundle/{chunk-ZNPRTCUO.js → chunk-NQXVZ5WT.js} +15 -117
- package/dist/bundle/{chunk-4MFMUBHH.js → chunk-OH3IZ6GW.js} +2395 -2369
- package/dist/bundle/{chunk-RX5CJ55S.js → chunk-OIF4B526.js} +1 -1
- package/dist/bundle/{chunk-4W4EVVL4.js → chunk-OK4M4MWI.js} +4 -4
- package/dist/bundle/{chunk-W34QQMBK.js → chunk-OVDB5CQM.js} +1 -1
- package/dist/bundle/{chunk-7GCVON7M.js → chunk-PI4XXMPG.js} +6 -6
- package/dist/bundle/{chunk-MCPOZNWG.js → chunk-PJGOQSE5.js} +1 -1
- package/dist/bundle/{chunk-D3ODL4P7.js → chunk-PP4ZBLS4.js} +69 -6
- package/dist/bundle/{chunk-LVGX7VTD.js → chunk-PZ6H65D6.js} +4 -4
- package/dist/bundle/{chunk-ARKB3M5X.js → chunk-QFV36CAH.js} +4 -4
- package/dist/bundle/{chunk-7X6YLKTK.js → chunk-QGCVQRHV.js} +1 -1
- package/dist/bundle/{chunk-O5A4IS2D.js → chunk-QK4T3VN7.js} +1 -1
- package/dist/bundle/{chunk-VC6J7X76.js → chunk-QWAMX6CN.js} +12 -12
- package/dist/bundle/{chunk-ALW7ROTM.js → chunk-RBV4M2TC.js} +1 -1
- package/dist/bundle/{chunk-GJBGZQHN.js → chunk-RHJHOOUL.js} +354 -184
- package/dist/bundle/{chunk-4N2WJYLE.js → chunk-SGBH3D5D.js} +3 -3
- package/dist/bundle/{chunk-N7WDVH2O.js → chunk-UII3D3HR.js} +51 -51
- package/dist/bundle/{chunk-HAR76KJG.js → chunk-UP3J3YXH.js} +6 -6
- package/dist/bundle/{chunk-WGGSFGNZ.js → chunk-UR62DZ7Q.js} +48 -9
- package/dist/bundle/{chunk-RFFU6KQ5.js → chunk-VAKSXD4F.js} +13 -13
- package/dist/bundle/{chunk-TKJZENAZ.js → chunk-VGUWIHXD.js} +1 -1
- package/dist/bundle/chunk-VIIIC5LU.js +32 -0
- package/dist/bundle/{chunk-VDFEWSCS.js → chunk-VMWJGUVV.js} +14 -5
- package/dist/bundle/{chunk-C5CB6RIX.js → chunk-W4LMTNN2.js} +2 -2
- package/dist/bundle/{chunk-33ELXJRR.js → chunk-WKOVQ4OU.js} +14 -12
- package/dist/bundle/{chunk-6DLRATDC.js → chunk-WSLIXJET.js} +3817 -3378
- package/dist/bundle/{chunk-LQRZUNYF.js → chunk-XDHGM2Z7.js} +3 -3
- package/dist/bundle/{chunk-7DPWVKYS.js → chunk-XSGUG5WG.js} +4 -4
- package/dist/bundle/{chunk-CW3C7FSO.js → chunk-YQFO7WXQ.js} +2 -2
- package/dist/bundle/{chunk-2FXA32RJ.js → chunk-ZL5YG2WK.js} +14 -9
- package/dist/bundle/{chunk-VQL4RVXZ.js → chunk-ZNICTHSC.js} +1 -1
- package/dist/bundle/{chunk-PG3V225O.js → chunk-ZTMV5M3D.js} +32 -27
- package/dist/bundle/command-contract-UKOL455D.js +34 -0
- package/dist/bundle/{command-server-entry-N32NX4QW.js → command-server-entry-K52OEKIO.js} +24 -22
- package/dist/bundle/{decode-ZKJWSFXF.js → decode-OAE25LEJ.js} +5 -5
- package/dist/bundle/{dispatch-U2DW6UI7.js → dispatch-6GVTXIZ2.js} +8 -8
- package/dist/bundle/{echarts-QLVLIP73.js → echarts-EO4ZGKMN.js} +2 -2
- package/dist/bundle/{embed-LC6K7P3S.js → embed-TB2AS4AT.js} +6 -6
- package/dist/bundle/{embedder-6C3OQBOV.js → embedder-YKC42G6L.js} +9 -9
- package/dist/bundle/{entry-5H6LB3MP.js → entry-AB6FU7BN.js} +9 -8
- package/dist/bundle/{failure-HJD7S5UA.js → failure-CY7ACT6V.js} +2 -2
- package/dist/bundle/{first-run-IOYQ4XQK.js → first-run-CMQZHDI5.js} +11 -11
- package/dist/bundle/first-screen-XZ73W3VE.js +32 -0
- package/dist/bundle/{instructions-SZUMEDY3.js → instructions-RM3IB6ID.js} +1 -1
- package/dist/bundle/{mcp-7KQUJNFN.js → mcp-M5YCSWJJ.js} +2 -2
- package/dist/bundle/{node-V76RRFIA.js → node-D2PM62TA.js} +2 -2
- package/dist/bundle/{node-sqlite-2DTVOT7L.js → node-sqlite-UK5DE525.js} +10 -6
- package/dist/bundle/{oauth-CT7EBDRY.js → oauth-SKRG67A2.js} +7 -7
- package/dist/bundle/{open-G3VHOOMV.js → open-XP3SY62D.js} +5 -5
- package/dist/bundle/{openai-F4K7MVTZ.js → openai-Q3U46UPA.js} +21 -17
- package/dist/bundle/{process-XH3KEHSF.js → process-YJ4LHMJB.js} +1 -1
- package/dist/bundle/{program-FLGIHTHM.js → program-EEPEFKTR.js} +80 -63
- package/dist/bundle/{prompt-JWQ6UQ6R.js → prompt-WYTODP4U.js} +5 -5
- package/dist/bundle/{proxy-transport-ENU2SJYT.js → proxy-transport-HJMQ5QFT.js} +5 -5
- package/dist/bundle/{recognize-Z26T3SYD.js → recognize-K2S5QQU2.js} +4 -4
- package/dist/bundle/{remote-7KHT6V3O.js → remote-7RSAJ3JC.js} +9 -7
- package/dist/bundle/{rerank-6QVI74QY.js → rerank-RJX77BKD.js} +7 -7
- package/dist/bundle/{serve-WYDZTONY.js → serve-3E7NN3VW.js} +14 -14
- package/dist/bundle/server-ITHYDPWQ.js +62 -0
- package/dist/bundle/{server-Y4J2NCFA.js → server-O3KU56A4.js} +36 -35
- package/dist/bundle/sqlite-runtime-RCS5WSG5.js +19 -0
- package/dist/bundle/{state-YCXBKOD2.js → state-PLWSPSAG.js} +6 -6
- package/dist/bundle/store-3FYLH53Z.js +276 -0
- package/dist/bundle/{store-QECSDJRP.js → store-DWMKCXYL.js} +15 -13
- package/dist/bundle/store-maintenance-command-3UEKINRB.js +52 -0
- package/dist/bundle/tg.js +13 -13
- package/dist/commands/account-removal.d.ts.map +1 -1
- package/dist/commands/account-removal.js +5 -3
- package/dist/commands/account-removal.js.map +1 -1
- package/dist/commands/session.d.ts.map +1 -1
- package/dist/commands/session.js +21 -3
- package/dist/commands/session.js.map +1 -1
- package/dist/paths.d.ts +6 -0
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +23 -2
- package/dist/paths.js.map +1 -1
- package/dist/program.d.ts +4 -1
- package/dist/program.d.ts.map +1 -1
- package/dist/program.js +5 -2
- package/dist/program.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +4 -4
- package/dist/bundle/chunk-GJFICFQB.js +0 -27
- package/dist/bundle/chunk-Y52T5EMB.js +0 -35
- package/dist/bundle/chunk-ZKHXWSKD.js +0 -265
- package/dist/bundle/command-contract-247AKZTE.js +0 -33
- package/dist/bundle/first-screen-NVK7PFX4.js +0 -31
- package/dist/bundle/server-UXQT7LZT.js +0 -61
- package/dist/bundle/store-maintenance-command-5YW6TRJA.js +0 -49
- /package/dist/bundle/{chunk-YVNHQFLC.js → chunk-HVJJWJYQ.js} +0 -0
|
@@ -7,10 +7,10 @@ import {
|
|
|
7
7
|
agentJson,
|
|
8
8
|
commandAvailability,
|
|
9
9
|
failureContext
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-4EGB7GSW.js";
|
|
11
11
|
import {
|
|
12
12
|
callerOf
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2GFGZDWS.js";
|
|
14
14
|
import {
|
|
15
15
|
QUERY_ARGUMENT,
|
|
16
16
|
lentConnection,
|
|
@@ -18,10 +18,10 @@ import {
|
|
|
18
18
|
refuseLacking,
|
|
19
19
|
servicesFor,
|
|
20
20
|
storeModeDeps
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-WSLIXJET.js";
|
|
22
22
|
import {
|
|
23
23
|
MAX_BUFFERED_INPUT
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-W4LMTNN2.js";
|
|
25
25
|
import {
|
|
26
26
|
DEFAULT_OUTPUT_BYTES,
|
|
27
27
|
ENTITIES,
|
|
@@ -41,27 +41,27 @@ import {
|
|
|
41
41
|
refuseStoreChange,
|
|
42
42
|
sealed,
|
|
43
43
|
startRecording
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-RHJHOOUL.js";
|
|
45
45
|
import {
|
|
46
46
|
currentCaller,
|
|
47
47
|
keepsSuccess,
|
|
48
48
|
runContextOf,
|
|
49
49
|
withCaller
|
|
50
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-ZL5YG2WK.js";
|
|
51
51
|
import {
|
|
52
52
|
enclosingTraceId,
|
|
53
53
|
inRun,
|
|
54
54
|
newRunId,
|
|
55
55
|
queryDescription,
|
|
56
56
|
traceOf
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-OH3IZ6GW.js";
|
|
58
58
|
import {
|
|
59
59
|
storeDamaged
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-3VVZFBE2.js";
|
|
61
61
|
import {
|
|
62
62
|
captureStreams,
|
|
63
63
|
traceIdOf
|
|
64
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-4CIVGT4P.js";
|
|
65
65
|
import {
|
|
66
66
|
COMPACT_FLAG,
|
|
67
67
|
SNAKE_CASE,
|
|
@@ -100,25 +100,25 @@ import {
|
|
|
100
100
|
unknown,
|
|
101
101
|
word,
|
|
102
102
|
writes
|
|
103
|
-
} from "./chunk-
|
|
103
|
+
} from "./chunk-UR62DZ7Q.js";
|
|
104
104
|
import {
|
|
105
105
|
CliError,
|
|
106
106
|
errorCodes
|
|
107
|
-
} from "./chunk-
|
|
107
|
+
} from "./chunk-E6VSARSU.js";
|
|
108
108
|
import {
|
|
109
109
|
__name
|
|
110
110
|
} from "./chunk-ZVVMGPBJ.js";
|
|
111
111
|
|
|
112
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
112
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/mcp/agent.js
|
|
113
113
|
import { Readable } from "node:stream";
|
|
114
114
|
|
|
115
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
115
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/lint.js
|
|
116
116
|
var LINT_SEVERITIES = ["high", "medium", "low"];
|
|
117
117
|
var lintRuleSchema = strictObject({
|
|
118
118
|
id: word,
|
|
119
119
|
severity: picklist(LINT_SEVERITIES),
|
|
120
120
|
/** What the rule looks at; a violation's target names one of these. */
|
|
121
|
-
scope: picklist(["command", "group", "argument", "option", "flag", "key", "source"]),
|
|
121
|
+
scope: picklist(["command", "group", "argument", "option", "flag", "key", "source", "type"]),
|
|
122
122
|
summary: text
|
|
123
123
|
});
|
|
124
124
|
var defineLintRules = /* @__PURE__ */ __name((input) => parseRegistry("lint rules", array(lintRuleSchema), input, (rules) => duplicates(rules.map((rule) => rule.id)).map((id) => `"${id}" is listed twice`)), "defineLintRules");
|
|
@@ -156,7 +156,7 @@ var LINT_RULES = defineLintRules([
|
|
|
156
156
|
},
|
|
157
157
|
{
|
|
158
158
|
id: "command-example-count",
|
|
159
|
-
severity: "
|
|
159
|
+
severity: "low",
|
|
160
160
|
scope: "command",
|
|
161
161
|
summary: "a leaf command has one to three examples; generated commands are exempt"
|
|
162
162
|
},
|
|
@@ -239,6 +239,12 @@ var LINT_RULES = defineLintRules([
|
|
|
239
239
|
severity: "medium",
|
|
240
240
|
scope: "source",
|
|
241
241
|
summary: "every `http(s)://` host in the CLI's own source is in the manifest's `network.hosts`"
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
id: "result-shape",
|
|
245
|
+
severity: "medium",
|
|
246
|
+
scope: "type",
|
|
247
|
+
summary: "a list or search in the published TypeScript API returns `{ items, hasMore, nextOffset?, total? }`: no bare array, no `hits` or `has_more`"
|
|
242
248
|
}
|
|
243
249
|
]);
|
|
244
250
|
var baselineSchema = array(text);
|
|
@@ -252,7 +258,7 @@ var overrideSchema = strictObject({
|
|
|
252
258
|
});
|
|
253
259
|
var overridesSchema = array(overrideSchema);
|
|
254
260
|
|
|
255
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
261
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/audit.js
|
|
256
262
|
var auditRuleSchema = strictObject({ id: word, severity: picklist(LINT_SEVERITIES), summary: text });
|
|
257
263
|
var defineAuditRules = /* @__PURE__ */ __name((input) => parseRegistry("audit rules", array(auditRuleSchema), input, (rules) => duplicates(rules.map((rule) => rule.id)).map((id) => `"${id}" is listed twice`)), "defineAuditRules");
|
|
258
264
|
var AUDIT_RULES = defineAuditRules([
|
|
@@ -304,7 +310,9 @@ var parityGroupSchema = strictObject({
|
|
|
304
310
|
absent: optional(word),
|
|
305
311
|
/** The one CLI that has the path or flag by design; every other CLI compared must lack it. */
|
|
306
312
|
only: optional(word),
|
|
307
|
-
reason: pipe(text, minLength(10, "say why, in a sentence"))
|
|
313
|
+
reason: pipe(text, minLength(10, "say why, in a sentence")),
|
|
314
|
+
/** Warns from 14 days before and fails 14 days after, as a lint override does. */
|
|
315
|
+
review_after: optional(pipe(string(), isoDate("a date, YYYY-MM-DD")))
|
|
308
316
|
}))
|
|
309
317
|
});
|
|
310
318
|
var defineParityGroups = /* @__PURE__ */ __name((input) => parseRegistry("parity groups", array(parityGroupSchema), input, (groups) => [
|
|
@@ -378,7 +386,7 @@ var REQUIRED_ROOTS = defineRequiredRoots([
|
|
|
378
386
|
{ path: ["upgrade"], meaning: "updates the CLI" }
|
|
379
387
|
]);
|
|
380
388
|
|
|
381
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
389
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/fields.js
|
|
382
390
|
var fieldRuleSchema = strictObject({ id: word, rule: text });
|
|
383
391
|
var defineFieldRules = /* @__PURE__ */ __name((input) => parseRegistry("output field rules", array(fieldRuleSchema), input, (rules) => duplicates(rules.map((rule) => rule.id)).map((id) => `"${id}" is listed twice`)), "defineFieldRules");
|
|
384
392
|
var FIELD_RULES = defineFieldRules([
|
|
@@ -394,7 +402,7 @@ var FIELD_RULES = defineFieldRules([
|
|
|
394
402
|
}
|
|
395
403
|
]);
|
|
396
404
|
|
|
397
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
405
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/identifiers.js
|
|
398
406
|
var key = pipe(string(), regex(SNAKE_CASE, "a snake_case key"));
|
|
399
407
|
var identifierSchema = strictObject({ key, meaning: text, replaces: optional(array(key)) });
|
|
400
408
|
var defineIdentifiers = /* @__PURE__ */ __name((input) => parseRegistry("identifiers", array(identifierSchema), input, (identifiers) => {
|
|
@@ -416,7 +424,44 @@ var IDENTIFIERS = defineIdentifiers([
|
|
|
416
424
|
{ key: "trace_id", meaning: "the distributed trace a run belongs to, from `traceparent`" }
|
|
417
425
|
]);
|
|
418
426
|
|
|
419
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
427
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-account.js
|
|
428
|
+
var ACCOUNT_FLAGS = [
|
|
429
|
+
{
|
|
430
|
+
name: "--client-id",
|
|
431
|
+
value: "<id>",
|
|
432
|
+
role: "mode",
|
|
433
|
+
type: "id",
|
|
434
|
+
meaning: "sign in through the owner's own OAuth app with this client ID instead of WireCat's (WC-SECR-25)"
|
|
435
|
+
},
|
|
436
|
+
{
|
|
437
|
+
name: "--client-file",
|
|
438
|
+
value: "<file>",
|
|
439
|
+
role: "mode",
|
|
440
|
+
type: "path",
|
|
441
|
+
meaning: "sign in through the owner's own OAuth app read from this client JSON instead of WireCat's (WC-SECR-25)"
|
|
442
|
+
},
|
|
443
|
+
{
|
|
444
|
+
name: "--keep-data",
|
|
445
|
+
role: "mode",
|
|
446
|
+
type: "switch",
|
|
447
|
+
meaning: "remove the account but leave what the store holds of it, still searchable"
|
|
448
|
+
},
|
|
449
|
+
{
|
|
450
|
+
name: "--delete-data",
|
|
451
|
+
role: "mode",
|
|
452
|
+
type: "switch",
|
|
453
|
+
meaning: "remove the account and delete what the store and the tool's files hold of it"
|
|
454
|
+
},
|
|
455
|
+
{
|
|
456
|
+
name: "--answer-stdin",
|
|
457
|
+
role: "mode",
|
|
458
|
+
type: "switch",
|
|
459
|
+
meaning: "a sign-in step asks its question as a JSON line and reads the answer from stdin"
|
|
460
|
+
},
|
|
461
|
+
{ name: "--hide-phone", role: "output", type: "switch", meaning: "leave the phone number out of the answer" }
|
|
462
|
+
];
|
|
463
|
+
|
|
464
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-calendar.js
|
|
420
465
|
var CALENDAR_FLAGS = [
|
|
421
466
|
{ name: "--end-time", value: "<time>", role: "value", type: "time", meaning: "when it ends" },
|
|
422
467
|
{
|
|
@@ -490,7 +535,7 @@ var CALENDAR_FLAGS = [
|
|
|
490
535
|
}
|
|
491
536
|
];
|
|
492
537
|
|
|
493
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
538
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-crm.js
|
|
494
539
|
var CRM_FLAGS = [
|
|
495
540
|
{
|
|
496
541
|
name: "--pipeline",
|
|
@@ -640,7 +685,7 @@ var CRM_FLAGS = [
|
|
|
640
685
|
}
|
|
641
686
|
];
|
|
642
687
|
|
|
643
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
688
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-how.js
|
|
644
689
|
var HOW_FLAGS = [
|
|
645
690
|
{
|
|
646
691
|
name: "--limit",
|
|
@@ -867,7 +912,6 @@ var HOW_FLAGS = [
|
|
|
867
912
|
meaning: "expose meeting preparation tools, including their remote schedule reads"
|
|
868
913
|
},
|
|
869
914
|
{ name: "--dry-run", role: "mode", type: "switch", meaning: "judge and plan; do nothing", replaces: ["--estimate"] },
|
|
870
|
-
{ name: "--accept-terms", role: "mode", type: "switch", meaning: "accept the model's licence terms" },
|
|
871
915
|
{
|
|
872
916
|
name: "--as-owner",
|
|
873
917
|
role: "mode",
|
|
@@ -1638,8 +1682,14 @@ var HOW_FLAGS = [
|
|
|
1638
1682
|
}
|
|
1639
1683
|
];
|
|
1640
1684
|
|
|
1641
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1685
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-knowledge.js
|
|
1642
1686
|
var KNOWLEDGE_FLAGS = [
|
|
1687
|
+
{
|
|
1688
|
+
name: "--accept-terms",
|
|
1689
|
+
role: "mode",
|
|
1690
|
+
type: "switch",
|
|
1691
|
+
meaning: "no longer needed; kept so older scripts still run"
|
|
1692
|
+
},
|
|
1643
1693
|
{
|
|
1644
1694
|
name: "--quote",
|
|
1645
1695
|
value: "<ref=words...>",
|
|
@@ -1670,7 +1720,7 @@ var KNOWLEDGE_FLAGS = [
|
|
|
1670
1720
|
}
|
|
1671
1721
|
];
|
|
1672
1722
|
|
|
1673
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1723
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-mail.js
|
|
1674
1724
|
var MAIL_FLAGS = [
|
|
1675
1725
|
{
|
|
1676
1726
|
name: "--cc",
|
|
@@ -1700,7 +1750,7 @@ var MAIL_FLAGS = [
|
|
|
1700
1750
|
}
|
|
1701
1751
|
];
|
|
1702
1752
|
|
|
1703
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1753
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-privacy.js
|
|
1704
1754
|
var PRIVACY_FLAGS = [
|
|
1705
1755
|
{
|
|
1706
1756
|
name: "--about-text",
|
|
@@ -1761,7 +1811,7 @@ var PRIVACY_FLAGS = [
|
|
|
1761
1811
|
{ name: "--read-receipts", value: "<on|off>", role: "value", type: "choice", meaning: "send read receipts" }
|
|
1762
1812
|
];
|
|
1763
1813
|
|
|
1764
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1814
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-schedule.js
|
|
1765
1815
|
var SCHEDULE_FLAGS = [
|
|
1766
1816
|
{
|
|
1767
1817
|
name: "--locale",
|
|
@@ -1794,7 +1844,7 @@ var SCHEDULE_FLAGS = [
|
|
|
1794
1844
|
}
|
|
1795
1845
|
];
|
|
1796
1846
|
|
|
1797
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1847
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/flags-what.js
|
|
1798
1848
|
var WHAT_FLAGS = [
|
|
1799
1849
|
{
|
|
1800
1850
|
name: "--analysis-provider",
|
|
@@ -2110,6 +2160,13 @@ var WHAT_FLAGS = [
|
|
|
2110
2160
|
type: "list",
|
|
2111
2161
|
meaning: "the agents to install for, comma-separated"
|
|
2112
2162
|
},
|
|
2163
|
+
{
|
|
2164
|
+
name: "--from",
|
|
2165
|
+
value: "<person>",
|
|
2166
|
+
role: "target",
|
|
2167
|
+
type: "id",
|
|
2168
|
+
meaning: "a person: the one identities leave, or the one who sent it; a search takes it repeated for any of several"
|
|
2169
|
+
},
|
|
2113
2170
|
{
|
|
2114
2171
|
name: "--from-dir",
|
|
2115
2172
|
value: "<dir>",
|
|
@@ -2784,7 +2841,7 @@ var WHAT_FLAGS = [
|
|
|
2784
2841
|
}
|
|
2785
2842
|
];
|
|
2786
2843
|
|
|
2787
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
2844
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.98.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/vocabulary.js
|
|
2788
2845
|
var FLAG_TYPES = [
|
|
2789
2846
|
"switch",
|
|
2790
2847
|
"count",
|
|
@@ -2938,6 +2995,7 @@ var verbs = [
|
|
|
2938
2995
|
"look at a source before taking anything from it: a chat link without joining, a mailbox without importing"
|
|
2939
2996
|
],
|
|
2940
2997
|
["send", "send a message"],
|
|
2998
|
+
["call", "call one provider API method by its own name, generated from the provider's method list"],
|
|
2941
2999
|
["edit", "change a sent message"],
|
|
2942
3000
|
["forward", "send an existing message on to another chat"],
|
|
2943
3001
|
["pin", "pin a message or chat"],
|
|
@@ -3144,6 +3202,7 @@ var views = [
|
|
|
3144
3202
|
["categories", "the categories a thing takes, with what each means"],
|
|
3145
3203
|
["domains", "the internet domains links point to, most linked first"],
|
|
3146
3204
|
["places", "the street addresses confirmed as places, most mentioned first"],
|
|
3205
|
+
["mentions", "the people and organizations named in a selected thing's text"],
|
|
3147
3206
|
["comments", "replies attached to a selected source item"],
|
|
3148
3207
|
["links", "links held for a selected thing"],
|
|
3149
3208
|
["voters", "people whose recorded votes are visible for a selected poll"],
|
|
@@ -3192,6 +3251,7 @@ var VOCABULARY = defineVocabulary({
|
|
|
3192
3251
|
...HOW_FLAGS,
|
|
3193
3252
|
...WHAT_FLAGS,
|
|
3194
3253
|
...PRIVACY_FLAGS,
|
|
3254
|
+
...ACCOUNT_FLAGS,
|
|
3195
3255
|
...CALENDAR_FLAGS,
|
|
3196
3256
|
...MAIL_FLAGS,
|
|
3197
3257
|
...KNOWLEDGE_FLAGS,
|
|
@@ -3200,7 +3260,7 @@ var VOCABULARY = defineVocabulary({
|
|
|
3200
3260
|
]
|
|
3201
3261
|
});
|
|
3202
3262
|
|
|
3203
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3263
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/mcp/agent.js
|
|
3204
3264
|
var TYPES = new Map(VOCABULARY.flags.map((flag) => [flag.name, flag.type]));
|
|
3205
3265
|
var snake = /* @__PURE__ */ __name((name) => name.replaceAll("|", "_or_").replace(/[^a-z0-9]+/gi, "_"), "snake");
|
|
3206
3266
|
var longOf = /* @__PURE__ */ __name((option) => option.flags.match(/--[a-z0-9][a-z0-9-]*/)?.[0], "longOf");
|
|
@@ -3310,6 +3370,9 @@ var fieldsOf = /* @__PURE__ */ __name((info, { omit = [], offline = false, stdin
|
|
|
3310
3370
|
}, "fieldsOf");
|
|
3311
3371
|
var schemaOf = /* @__PURE__ */ __name((fields) => object(Object.fromEntries(fields.map((field) => [field.name, field.required ? field.schema : optional(field.schema)]))), "schemaOf");
|
|
3312
3372
|
var startsWith = /* @__PURE__ */ __name((path, prefix) => prefix.every((word2, at) => path[at] === word2), "startsWith");
|
|
3373
|
+
var keywordsOf = /* @__PURE__ */ __name((examples) => [
|
|
3374
|
+
...new Set(examples.flatMap((example) => example.split(/\s+/u).filter((word2) => word2 !== "" && !word2.startsWith("-"))))
|
|
3375
|
+
], "keywordsOf");
|
|
3313
3376
|
var toolsFromCommands = /* @__PURE__ */ __name((commands, options = {}) => {
|
|
3314
3377
|
const { root = [], exclude = [], levels, keyOf, authority, readOnly = false, permissions } = options;
|
|
3315
3378
|
return flatten(commands).filter((info) => (
|
|
@@ -3321,6 +3384,7 @@ var toolsFromCommands = /* @__PURE__ */ __name((commands, options = {}) => {
|
|
|
3321
3384
|
path: info.path,
|
|
3322
3385
|
title: info.summary ?? info.description,
|
|
3323
3386
|
description: info.description,
|
|
3387
|
+
...info.examples?.length ? { keywords: keywordsOf(info.examples) } : {},
|
|
3324
3388
|
writes: writes(info.effects) && options.fetchOnly?.(info.path) !== true,
|
|
3325
3389
|
input: schemaOf(fieldsOf(info, options)),
|
|
3326
3390
|
...info.output ? { output: info.output } : {}
|
|
@@ -3423,7 +3487,7 @@ var runCommandForAgent = /* @__PURE__ */ __name(async (program, path, input, ctx
|
|
|
3423
3487
|
}
|
|
3424
3488
|
}, "runCommandForAgent");
|
|
3425
3489
|
|
|
3426
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3490
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/mcp/tool.js
|
|
3427
3491
|
var limit = optional(pipe(number(), integer(), minValue(1), maxValue(100), description("how many")));
|
|
3428
3492
|
var page = optional(pipe(number(), integer(), minValue(1), description("which page, from 1")));
|
|
3429
3493
|
var message = pipe(
|
|
@@ -3682,7 +3746,7 @@ var failed = /* @__PURE__ */ __name((error, errors, effects) => {
|
|
|
3682
3746
|
return mcpErrorResult(JSON.parse(agentJson(errorObjectOf(storeDamaged(error), context))));
|
|
3683
3747
|
}, "failed");
|
|
3684
3748
|
|
|
3685
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3749
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.648.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.98.0_commander@15._22e948f6f1aa7f4572ea465a838ccfd1/node_modules/@wirecat/cli-core/dist/mcp/surface.js
|
|
3686
3750
|
import { randomUUID } from "node:crypto";
|
|
3687
3751
|
var MATCHES = 8;
|
|
3688
3752
|
var ANSWER = answerSchema();
|
|
@@ -3704,15 +3768,43 @@ var listedAs = /* @__PURE__ */ __name((prefix, writes2) => {
|
|
|
3704
3768
|
return { "~standard": { ...checked["~standard"], jsonSchema: shown } };
|
|
3705
3769
|
}, "listedAs");
|
|
3706
3770
|
var normal = /* @__PURE__ */ __name((command) => command.trim().toLowerCase().split(/[\s_-]+/).join(" "), "normal");
|
|
3707
|
-
var
|
|
3771
|
+
var STOP_WORDS = new Set("a an the to of in on at by for from with into out about and or but is are be been was were it its this that these those which who whom whose what when where how do does did can could should would will my our your their his her them they we you i one some any all each every another other".split(" "));
|
|
3772
|
+
var wordsOf = /* @__PURE__ */ __name((text3) => text3.toLowerCase().split(/[^\p{L}\p{N}]+/u).filter(Boolean), "wordsOf");
|
|
3773
|
+
var stem = /* @__PURE__ */ __name((word2) => {
|
|
3774
|
+
const bare = word2.replace(/'s$/u, "");
|
|
3775
|
+
if (bare.length > 4 && bare.endsWith("ies"))
|
|
3776
|
+
return `${bare.slice(0, -3)}y`;
|
|
3777
|
+
for (const ending of ["ing", "ed", "es", "s"])
|
|
3778
|
+
if (bare.length - ending.length >= 3 && bare.endsWith(ending))
|
|
3779
|
+
return bare.slice(0, -ending.length);
|
|
3780
|
+
return bare;
|
|
3781
|
+
}, "stem");
|
|
3782
|
+
var sameWord = /* @__PURE__ */ __name((asked, known) => {
|
|
3783
|
+
if (asked === known)
|
|
3784
|
+
return true;
|
|
3785
|
+
const [short, long] = asked.length <= known.length ? [asked, known] : [known, asked];
|
|
3786
|
+
return short.length >= 3 && long.startsWith(short);
|
|
3787
|
+
}, "sameWord");
|
|
3788
|
+
var fieldsOf2 = /* @__PURE__ */ __name((command, one) => [
|
|
3789
|
+
[4, [...wordsOf(command), ...(one.aliases ?? []).flatMap(wordsOf)]],
|
|
3790
|
+
[2, wordsOf(one.title)],
|
|
3791
|
+
[1, [...wordsOf(one.description), ...(one.keywords ?? []).flatMap(wordsOf), ...Object.keys(one.input.entries)]]
|
|
3792
|
+
].map(([weight, words]) => [weight, [...new Set(words.map(stem))]]), "fieldsOf");
|
|
3708
3793
|
var search = /* @__PURE__ */ __name((commands, query) => {
|
|
3709
|
-
const
|
|
3710
|
-
|
|
3711
|
-
|
|
3712
|
-
|
|
3713
|
-
|
|
3714
|
-
|
|
3715
|
-
|
|
3794
|
+
const named = normal(query);
|
|
3795
|
+
const all = Object.entries(commands);
|
|
3796
|
+
if (!named)
|
|
3797
|
+
return all.map((entry) => entry).sort((a, b) => a[0].localeCompare(b[0]));
|
|
3798
|
+
const words = [
|
|
3799
|
+
...new Set(wordsOf(query).filter((word2) => word2.length > 1 && !STOP_WORDS.has(word2)).map(stem))
|
|
3800
|
+
];
|
|
3801
|
+
return all.map((entry) => {
|
|
3802
|
+
const fields = fieldsOf2(entry[0], entry[1]);
|
|
3803
|
+
const weights = words.map((word2) => fields.reduce((best, [weight, known]) => known.some((one) => sameWord(word2, one)) ? Math.max(best, weight) : best, 0));
|
|
3804
|
+
const matched = weights.filter((weight) => weight > 0).length;
|
|
3805
|
+
const exact = normal(entry[0]) === named || (entry[1].aliases ?? []).some((alias) => normal(alias) === named);
|
|
3806
|
+
return { entry, matched, rank: (exact ? 1e3 : 0) + matched * 10 + weights.reduce((a, b) => a + b, 0) };
|
|
3807
|
+
}).filter(({ matched, rank }) => matched > 0 || rank >= 1e3).sort((a, b) => b.rank - a.rank || a.entry[0].localeCompare(b.entry[0])).map(({ entry }) => entry);
|
|
3716
3808
|
}, "search");
|
|
3717
3809
|
var nearest = /* @__PURE__ */ __name((commands, asked) => {
|
|
3718
3810
|
const words = normal(asked).split(" ");
|