@wirecat/zoom-cli 0.71.0 → 0.72.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/answers.d.ts +56 -0
- package/dist/answers.d.ts.map +1 -1
- package/dist/bin/zm.js +2 -2
- package/dist/bundle/{all-profiles-O4YNVPZX.js → all-profiles-XFIPF4GF.js} +12 -12
- package/dist/bundle/answer-policy-AT6CDEE5.js +110 -0
- package/dist/bundle/{anthropic-7GGRX3RX.js → anthropic-SSUBR3BC.js} +18 -11
- package/dist/bundle/{app-server-CPMKM3HI.js → app-server-7DJHHF2F.js} +68 -56
- package/dist/bundle/{bun-POHZKEPV.js → bun-6HBYWQIX.js} +2 -2
- package/dist/bundle/{bun-sqlite-PGYMBPEL.js → bun-sqlite-4L3Q55NB.js} +10 -6
- package/dist/bundle/{chunk-Q2SUFGSH.js → chunk-23J2ANZ7.js} +2 -2
- package/dist/bundle/{chunk-FSHCAWZS.js → chunk-24OFZNRC.js} +13119 -10386
- package/dist/bundle/{chunk-LE7MDAQG.js → chunk-2MIBRVSV.js} +2 -2
- package/dist/bundle/{chunk-DIQLXAAZ.js → chunk-37NF5CBJ.js} +4 -4
- package/dist/bundle/chunk-3KRTEX5M.js +53 -0
- package/dist/bundle/{chunk-IED3NS7G.js → chunk-4SY67IUA.js} +30 -30
- package/dist/bundle/{chunk-CKPCVEXU.js → chunk-4XQWF3U2.js} +6 -6
- package/dist/bundle/{chunk-CT4WVR4N.js → chunk-4YIGXTBP.js} +3 -3
- package/dist/bundle/{chunk-YPO2U2YB.js → chunk-5AELTC52.js} +388 -143
- package/dist/bundle/{chunk-USQ23X5V.js → chunk-5MGICK47.js} +750 -734
- package/dist/bundle/{chunk-DK6ICIGL.js → chunk-5X4IY5JH.js} +2025 -1302
- package/dist/bundle/{chunk-EOSVN2ER.js → chunk-63QXCE5Z.js} +242 -242
- package/dist/bundle/{chunk-OE7EIP5L.js → chunk-6DCLZLGX.js} +1 -1
- package/dist/bundle/chunk-7GLJSJ7M.js +16 -0
- package/dist/bundle/{chunk-X3ZDN3U7.js → chunk-7IFO43Q5.js} +2 -2
- package/dist/bundle/{chunk-YD2RYVMK.js → chunk-7JYMGXLI.js} +41 -39
- package/dist/bundle/{chunk-DSVZEXYJ.js → chunk-7OD3522V.js} +3541 -3346
- package/dist/bundle/{chunk-2FV5JUQU.js → chunk-7S4D5SM2.js} +41 -35
- package/dist/bundle/{chunk-VRH7VRTK.js → chunk-7SUWPMZG.js} +10 -15
- package/dist/bundle/{chunk-4QPQ7MDA.js → chunk-ADKMBXY4.js} +1 -1
- package/dist/bundle/{chunk-MRI6QMZ3.js → chunk-B3SILJBU.js} +18 -18
- package/dist/bundle/{chunk-7ROXXRGG.js → chunk-CANRIRNZ.js} +6678 -5185
- package/dist/bundle/{chunk-DRBQDCDU.js → chunk-CW46FWKW.js} +38 -123
- package/dist/bundle/{chunk-GXF5HFFP.js → chunk-D24OQAHM.js} +4 -4
- package/dist/bundle/{chunk-ZBKWRYRS.js → chunk-D5EUMWD5.js} +3 -3
- package/dist/bundle/{chunk-QVSLSWAL.js → chunk-DEPXZJ2V.js} +21 -150
- package/dist/bundle/{chunk-TM4JSVGQ.js → chunk-DOCVEKP2.js} +39 -44
- package/dist/bundle/{chunk-BBTQIVFP.js → chunk-EFF2XBHP.js} +2 -2
- package/dist/bundle/{chunk-XRFHQGOD.js → chunk-EG25AY4L.js} +1 -1
- package/dist/bundle/{chunk-FEM2JQN2.js → chunk-ELJUBPY4.js} +1 -1
- package/dist/bundle/{chunk-2U6SER67.js → chunk-ERJYJ36F.js} +2 -2
- package/dist/bundle/chunk-FSCPQQS5.js +244 -0
- package/dist/bundle/{chunk-P3XC6EDU.js → chunk-H53WFZBN.js} +11 -130
- package/dist/bundle/{chunk-RN4EHCC5.js → chunk-I7CUMZD6.js} +3 -3
- package/dist/bundle/{chunk-ALIT5QFT.js → chunk-IACWKZWS.js} +1 -1
- package/dist/bundle/{chunk-MW4EGDDV.js → chunk-IFBIXU6C.js} +2 -2
- package/dist/bundle/{chunk-5K7OGPGA.js → chunk-IU4DUUB3.js} +7 -7
- package/dist/bundle/{chunk-INVTDIF6.js → chunk-IXO4SCKE.js} +1 -1
- package/dist/bundle/{chunk-OHWMIUCT.js → chunk-JAEPK457.js} +244 -245
- package/dist/bundle/{chunk-HB6XJQ3Y.js → chunk-JFPUYQSP.js} +5 -5
- package/dist/bundle/{chunk-IAV5BG3I.js → chunk-JG4MNYG2.js} +1 -1
- package/dist/bundle/{chunk-ZBFL5JPT.js → chunk-JRCH4YZP.js} +16 -10
- package/dist/bundle/{chunk-M76MXMLY.js → chunk-JZ4XNNL7.js} +1 -1
- package/dist/bundle/chunk-K6HR6HCO.js +32 -0
- package/dist/bundle/{chunk-DHWBSXG3.js → chunk-KFZL67JP.js} +323 -55
- package/dist/bundle/{chunk-X4GWR6GO.js → chunk-KPIQXFNB.js} +375 -10
- package/dist/bundle/{chunk-OWEBWDHV.js → chunk-KWURWGGB.js} +80 -5
- package/dist/bundle/{chunk-Q5PI72CR.js → chunk-LA6QUVGQ.js} +3 -2
- package/dist/bundle/{chunk-5J4AMBMM.js → chunk-LLUNHAZ7.js} +4 -4
- package/dist/bundle/{chunk-2RUAMDVV.js → chunk-LTWJM3ED.js} +17 -17
- package/dist/bundle/{chunk-2U27KIKU.js → chunk-M3DMXDX6.js} +6 -6
- package/dist/bundle/{chunk-VW6BF6M7.js → chunk-MCPOZNWG.js} +1 -1
- package/dist/bundle/{chunk-CRFOGYDG.js → chunk-MSQHSW4C.js} +2 -2
- package/dist/bundle/chunk-N4QNYWWG.js +71 -0
- package/dist/bundle/chunk-NMZQTYKJ.js +18 -0
- package/dist/bundle/{chunk-2KESWII5.js → chunk-OHCLQJOV.js} +3 -3
- package/dist/bundle/{chunk-4QUFFB2U.js → chunk-OP5PGE2N.js} +4 -4
- package/dist/bundle/{chunk-Q3XLZIY3.js → chunk-OY6N2ABP.js} +29 -23
- package/dist/bundle/chunk-PJWSGXOB.js +185 -0
- package/dist/bundle/{chunk-633QXP57.js → chunk-QA6KIL7Q.js} +10 -8
- package/dist/bundle/{chunk-N2FNMION.js → chunk-QQUY4MZY.js} +1 -1
- package/dist/bundle/{chunk-X277FBTF.js → chunk-QW7YTRV2.js} +3 -3
- package/dist/bundle/chunk-RJTGENHZ.js +109 -0
- package/dist/bundle/{chunk-ULDXZ6LH.js → chunk-RLCVPECY.js} +63 -63
- package/dist/bundle/{chunk-BGTEVIW4.js → chunk-RN5SU2RN.js} +6 -6
- package/dist/bundle/{chunk-P3ASN72F.js → chunk-RX5CJ55S.js} +1 -1
- package/dist/bundle/{chunk-7QC4M4HS.js → chunk-RZUJMAMK.js} +4 -4
- package/dist/bundle/{chunk-OORMSM6O.js → chunk-S7SXSHRC.js} +21 -21
- package/dist/bundle/{chunk-GGS6D4W4.js → chunk-SXZGCD6E.js} +3 -3
- package/dist/bundle/{chunk-64ZHF6PJ.js → chunk-T27IMG6X.js} +3 -1
- package/dist/bundle/{chunk-VJXHIUFP.js → chunk-TF2WKPNW.js} +15 -15
- package/dist/bundle/{chunk-QTHIU7CO.js → chunk-U32VL3MA.js} +1 -1
- package/dist/bundle/{chunk-RQG5VOGH.js → chunk-U3NJBGLA.js} +3 -3
- package/dist/bundle/{chunk-WOIHSQAL.js → chunk-UVZLK3M4.js} +33 -9
- package/dist/bundle/{chunk-XI3VIQKW.js → chunk-VIV64MQM.js} +560 -537
- package/dist/bundle/{chunk-CFQF6IGY.js → chunk-W3YTVEWV.js} +69 -6
- package/dist/bundle/{chunk-54YDWBYG.js → chunk-WLVG4RBZ.js} +1 -1
- package/dist/bundle/{chunk-77TCCHMP.js → chunk-WOAYHCM2.js} +1 -1
- package/dist/bundle/{chunk-5LJTU4LY.js → chunk-WXTYYWZI.js} +13 -13
- package/dist/bundle/{chunk-MEED7YFG.js → chunk-WZGKHTA4.js} +2 -2
- package/dist/bundle/{chunk-I4DFFR7F.js → chunk-X2MP634F.js} +14 -5
- package/dist/bundle/{chunk-RGJ7OWHU.js → chunk-XPWZSW6Y.js} +61 -21
- package/dist/bundle/{chunk-SELXER2Q.js → chunk-YVVJ6Y5C.js} +7 -7
- package/dist/bundle/{chunk-4LAQDZXU.js → chunk-ZHA56THL.js} +790 -70
- package/dist/bundle/{chunk-ZVI6TFQR.js → chunk-ZVFYGTGJ.js} +17 -17
- package/dist/bundle/{chunk-GL3MYFMX.js → chunk-ZW5KHKMA.js} +5 -5
- package/dist/bundle/{cli-KHMEUXNG.js → cli-IYYI7GAM.js} +158 -96
- package/dist/bundle/command-contract-TX7NSUBM.js +42 -0
- package/dist/bundle/command-server-entry-FXX4LJWF.js +171 -0
- package/dist/bundle/config-YKNM33J7.js +96 -0
- package/dist/bundle/{decode-7RP4HSVE.js → decode-SRGOOGBW.js} +6 -6
- package/dist/bundle/{dispatch-IZCAK47P.js → dispatch-OUHRPFUL.js} +11 -11
- package/dist/bundle/{dist-BFT2SUBV.js → dist-UZLNLAIO.js} +52 -31
- package/dist/bundle/{echarts-T2BSQ2YV.js → echarts-7CM2MCMW.js} +2 -2
- package/dist/bundle/{embed-BAS6YPDT.js → embed-VEE56BOB.js} +7 -7
- package/dist/bundle/{embedder-5XD5FCAO.js → embedder-SZFYR543.js} +10 -10
- package/dist/bundle/{failure-R2OIHCE5.js → failure-MZBNM7M5.js} +3 -3
- package/dist/bundle/first-run-KWC7RKF2.js +29 -0
- package/dist/bundle/first-screen-DWKMNSEI.js +40 -0
- package/dist/bundle/{folders-ZXTOFY4T.js → folders-UQXRSDJJ.js} +5 -5
- package/dist/bundle/{instructions-XZPROPKY.js → instructions-R7OHVAWH.js} +1 -1
- package/dist/bundle/{main-TZXKGL3L.js → main-EFUN2O3K.js} +21 -20
- package/dist/bundle/{mcp-M4QN2E7R.js → mcp-7KQUJNFN.js} +2 -2
- package/dist/bundle/{meetings-JB2ISPND.js → meetings-5I2BDNTA.js} +7 -7
- package/dist/bundle/{node-A3B3MJWX.js → node-3N2JGZ7V.js} +2 -2
- package/dist/bundle/{node-sqlite-QVWDLGDX.js → node-sqlite-2UVEE2WM.js} +11 -7
- package/dist/bundle/{oauth-YA6IYV4O.js → oauth-AYGD7UU3.js} +8 -8
- package/dist/bundle/{open-SY7TXJBS.js → open-3GUVDLGD.js} +6 -6
- package/dist/bundle/openai-NHCDLWWY.js +28 -0
- package/dist/bundle/{output-file-YGQYZCBJ.js → output-file-72JFXVHQ.js} +6 -6
- package/dist/bundle/{process-6HNBTJIY.js → process-YAHHUFR5.js} +1 -1
- package/dist/bundle/{program-77BUCJ4H.js → program-OSZROCTK.js} +97 -91
- package/dist/bundle/{prompt-YDG73YDS.js → prompt-HMCW4XQJ.js} +6 -6
- package/dist/bundle/{recognize-ECXDGTB7.js → recognize-VF5CA7EM.js} +5 -5
- package/dist/bundle/{remote-K4JHGBVJ.js → remote-5C6VTPR2.js} +10 -8
- package/dist/bundle/{rerank-IU2YYD4T.js → rerank-ER7NEDOI.js} +8 -8
- package/dist/bundle/run-log-JKTLKXSK.js +124 -0
- package/dist/bundle/{serve-3XWIF3HI.js → serve-QJWXJOM7.js} +10 -10
- package/dist/bundle/{server-56VYOHWP.js → server-KCIK3Y2P.js} +50 -48
- package/dist/bundle/server-LLGFDLLJ.js +75 -0
- package/dist/bundle/{services-X7IPEGQ5.js → services-LQMYJQG3.js} +62 -45
- package/dist/bundle/{speech-E2OBQWYA.js → speech-74GJQNQH.js} +20 -17
- package/dist/bundle/{state-4GMJYK4H.js → state-4XDGCHDF.js} +7 -7
- package/dist/bundle/{store-LA4TV4DM.js → store-5Y5HK2L2.js} +22 -19
- package/dist/bundle/{store-KPI7GB5Y.js → store-Y56AHJ2Y.js} +42 -27
- package/dist/bundle/store-connection-4WI32AYU.js +89 -0
- package/dist/bundle/store-maintenance-command-PCXO5AH4.js +65 -0
- package/dist/bundle/{streaming-EJ3NM2C2.js → streaming-E5CR6HSR.js} +7 -7
- package/dist/bundle/{tokens-BE6CJMR5.js → tokens-E2QNVC4F.js} +7 -7
- package/dist/bundle/zm.js +34 -10
- package/dist/bundle/{zoom-app-QEJBTIJ4.js → zoom-app-NVL7HEAX.js} +8 -8
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/dist/bundle/answer-policy-PPSPMCLH.js +0 -104
- package/dist/bundle/chunk-KMV7GZB6.js +0 -35
- package/dist/bundle/chunk-UG447QY2.js +0 -27
- package/dist/bundle/command-contract-4K6XXZYE.js +0 -41
- package/dist/bundle/config-EEDB632I.js +0 -90
- package/dist/bundle/first-run-23WWZ2PW.js +0 -28
- package/dist/bundle/first-screen-6HFUYVFR.js +0 -39
- package/dist/bundle/openai-2AU24NRN.js +0 -25
- package/dist/bundle/run-log-LFEXNZ74.js +0 -118
- package/dist/bundle/server-YSTMUZ22.js +0 -72
- package/dist/bundle/store-connection-AZTIF6IH.js +0 -83
- package/dist/bundle/store-maintenance-command-LR572PS4.js +0 -61
- /package/dist/bundle/{chunk-VOXIGICJ.js → chunk-YVNHQFLC.js} +0 -0
|
@@ -2,26 +2,31 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
validateFormattedText
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-H53WFZBN.js";
|
|
6
6
|
import {
|
|
7
7
|
inputPolicy
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-EFF2XBHP.js";
|
|
9
|
+
import {
|
|
10
|
+
RECORDS_SCHEMA_VERSION,
|
|
11
|
+
RECORD_TYPES,
|
|
12
|
+
pointerOf
|
|
13
|
+
} from "./chunk-ZHA56THL.js";
|
|
9
14
|
import {
|
|
10
15
|
indent
|
|
11
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-S7SXSHRC.js";
|
|
12
17
|
import {
|
|
13
18
|
CliError
|
|
14
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-ELJUBPY4.js";
|
|
15
20
|
import {
|
|
16
21
|
__name
|
|
17
22
|
} from "./chunk-ZVVMGPBJ.js";
|
|
18
23
|
|
|
19
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
24
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/checks.js
|
|
20
25
|
var spelled = /* @__PURE__ */ __name((check, args) => `${check.replaceAll(".", " ")}${args === void 0 ? "" : ` ${args}`}`, "spelled");
|
|
21
26
|
var bareCheck = /* @__PURE__ */ __name((check, args) => `\`${spelled(check, args)}\``, "bareCheck");
|
|
22
27
|
var checkWords = /* @__PURE__ */ __name((command, profile) => (check, args) => `\`${command} ${profile === void 0 ? "" : `${profile} `}${spelled(check, args)}\``, "checkWords");
|
|
23
28
|
|
|
24
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
29
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/markdown.js
|
|
25
30
|
var MARKERS = [
|
|
26
31
|
["**", "bold"],
|
|
27
32
|
["~~", "strike"],
|
|
@@ -67,7 +72,7 @@ var closing = /* @__PURE__ */ __name((input, open, marker) => {
|
|
|
67
72
|
return end;
|
|
68
73
|
}, "closing");
|
|
69
74
|
|
|
70
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
75
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/markdown-spans.js
|
|
71
76
|
var STYLES = [
|
|
72
77
|
["**", "bold"],
|
|
73
78
|
["__", "underline"],
|
|
@@ -227,7 +232,7 @@ var parseMarkdownSpans = /* @__PURE__ */ __name((input) => {
|
|
|
227
232
|
return validateFormattedText(result);
|
|
228
233
|
}, "parseMarkdownSpans");
|
|
229
234
|
|
|
230
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
235
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/polls.js
|
|
231
236
|
var countedPoll = /* @__PURE__ */ __name((poll, votes, self) => {
|
|
232
237
|
const cast = votes.filter((vote) => vote.answers.length > 0);
|
|
233
238
|
const mine = self === null ? void 0 : votes.find((vote) => vote.person.id === self);
|
|
@@ -242,6 +247,361 @@ var countedPoll = /* @__PURE__ */ __name((poll, votes, self) => {
|
|
|
242
247
|
};
|
|
243
248
|
}, "countedPoll");
|
|
244
249
|
|
|
250
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/records-table.js
|
|
251
|
+
var TABLE_RECORD_TYPES = Object.keys(RECORD_TYPES).filter((type) => !RECORD_TYPES[type].importOnly);
|
|
252
|
+
var TableError = class extends Error {
|
|
253
|
+
static {
|
|
254
|
+
__name(this, "TableError");
|
|
255
|
+
}
|
|
256
|
+
errors;
|
|
257
|
+
constructor(errors) {
|
|
258
|
+
super(errors.map((e) => e.message).join("; "));
|
|
259
|
+
this.errors = errors;
|
|
260
|
+
}
|
|
261
|
+
};
|
|
262
|
+
var LIST_SEPARATOR = "|";
|
|
263
|
+
var BOM = "\uFEFF";
|
|
264
|
+
var specOf = /* @__PURE__ */ __name((type) => RECORD_TYPES[type], "specOf");
|
|
265
|
+
var typesOf = /* @__PURE__ */ __name((schema) => schema.type === void 0 ? [] : typeof schema.type === "string" ? [schema.type] : [...schema.type], "typesOf");
|
|
266
|
+
var shapeOf = /* @__PURE__ */ __name((schema) => {
|
|
267
|
+
const types = typesOf(schema);
|
|
268
|
+
if (types.includes("integer"))
|
|
269
|
+
return "integer";
|
|
270
|
+
if (types.includes("boolean"))
|
|
271
|
+
return "boolean";
|
|
272
|
+
if (types.includes("array"))
|
|
273
|
+
return "list";
|
|
274
|
+
if (schema.pattern?.includes("T[0-9]{2}"))
|
|
275
|
+
return "instant";
|
|
276
|
+
if (schema.pattern?.startsWith("^[0-9]{4}-"))
|
|
277
|
+
return "day";
|
|
278
|
+
if (schema.pattern?.includes("[A-Za-z]{3}"))
|
|
279
|
+
return "currency";
|
|
280
|
+
if (schema.pattern?.includes("(\\.[0-9]"))
|
|
281
|
+
return "decimal";
|
|
282
|
+
return "text";
|
|
283
|
+
}, "shapeOf");
|
|
284
|
+
var valuesOf = /* @__PURE__ */ __name((schema) => schema.enum?.filter((v) => v !== null), "valuesOf");
|
|
285
|
+
var flat = /* @__PURE__ */ __name((schema) => {
|
|
286
|
+
const types = typesOf(schema);
|
|
287
|
+
return !types.includes("object") && !(types.includes("array") && schema.items?.type === "object");
|
|
288
|
+
}, "flat");
|
|
289
|
+
var fieldColumn = /* @__PURE__ */ __name((name, schema, required, kind) => {
|
|
290
|
+
const values = valuesOf(schema);
|
|
291
|
+
const shape = shapeOf(schema);
|
|
292
|
+
return {
|
|
293
|
+
name,
|
|
294
|
+
kind,
|
|
295
|
+
required,
|
|
296
|
+
shape,
|
|
297
|
+
description: schema.description ?? "",
|
|
298
|
+
...values ? { values } : {},
|
|
299
|
+
...shape === "list" ? { many: true } : {}
|
|
300
|
+
};
|
|
301
|
+
}, "fieldColumn");
|
|
302
|
+
var roleColumn = /* @__PURE__ */ __name((name, role) => ({
|
|
303
|
+
name,
|
|
304
|
+
kind: "role",
|
|
305
|
+
required: role.required === true,
|
|
306
|
+
shape: "text",
|
|
307
|
+
description: role.targets.length === 1 ? `The ${role.targets[0]}'s external id` : `<type>:<external id>, the type one of ${role.targets.join(", ")}`,
|
|
308
|
+
targets: role.targets,
|
|
309
|
+
...role.many ? { many: true } : {}
|
|
310
|
+
}), "roleColumn");
|
|
311
|
+
var recordColumns = /* @__PURE__ */ __name((type) => {
|
|
312
|
+
const spec = specOf(type);
|
|
313
|
+
if (!spec || spec.importOnly)
|
|
314
|
+
return [];
|
|
315
|
+
const fields = spec.fields.properties ?? {};
|
|
316
|
+
const required = spec.fields.required ?? [];
|
|
317
|
+
const lists = Object.entries(fields).filter(([, schema]) => !flat(schema));
|
|
318
|
+
return [
|
|
319
|
+
{ name: "external_id", kind: "id", required: true, shape: "text", description: "Its id in your system" },
|
|
320
|
+
...Object.entries(fields).filter(([, schema]) => flat(schema)).map(([name, schema]) => fieldColumn(name, schema, required.includes(name), "field")),
|
|
321
|
+
...Object.entries(spec.roles).filter(([, role]) => !role.linked).map(([name, role]) => roleColumn(name, role)),
|
|
322
|
+
...lists.flatMap(([list, schema]) => {
|
|
323
|
+
const item = schema.items ?? {};
|
|
324
|
+
const own = item.required ?? [];
|
|
325
|
+
return Object.entries(item.properties ?? {}).map(([key, s]) => fieldColumn(`${list}.${key}`, s, required.includes(list) && own.includes(key), "item"));
|
|
326
|
+
})
|
|
327
|
+
];
|
|
328
|
+
}, "recordColumns");
|
|
329
|
+
var csvCell = /* @__PURE__ */ __name((value, separator) => /["\r\n]/.test(value) || value.includes(separator) ? `"${value.replaceAll('"', '""')}"` : value, "csvCell");
|
|
330
|
+
var example = /* @__PURE__ */ __name((column) => {
|
|
331
|
+
if (column.values?.[0])
|
|
332
|
+
return column.values[0];
|
|
333
|
+
switch (column.shape) {
|
|
334
|
+
case "decimal":
|
|
335
|
+
return "100.00";
|
|
336
|
+
case "day":
|
|
337
|
+
return "2026-01-31";
|
|
338
|
+
case "instant":
|
|
339
|
+
return "2026-01-31T09:00:00Z";
|
|
340
|
+
case "currency":
|
|
341
|
+
return "EUR";
|
|
342
|
+
case "integer":
|
|
343
|
+
return 1;
|
|
344
|
+
case "boolean":
|
|
345
|
+
return true;
|
|
346
|
+
case "list":
|
|
347
|
+
return ["\u2026"];
|
|
348
|
+
default:
|
|
349
|
+
return column.description || "\u2026";
|
|
350
|
+
}
|
|
351
|
+
}, "example");
|
|
352
|
+
var exampleRef = /* @__PURE__ */ __name((column) => ({
|
|
353
|
+
role: column.name,
|
|
354
|
+
type: column.targets?.[0] ?? "",
|
|
355
|
+
external_id: `${column.targets?.[0] ?? "record"}-1`
|
|
356
|
+
}), "exampleRef");
|
|
357
|
+
var recordTemplate = /* @__PURE__ */ __name((type, format, { source, separator = "," } = {}) => {
|
|
358
|
+
const columns = recordColumns(type);
|
|
359
|
+
if (columns.length === 0)
|
|
360
|
+
throw new TableError([unknownType(type)]);
|
|
361
|
+
if (format === "csv")
|
|
362
|
+
return `${BOM}${columns.map((c) => csvCell(c.name, separator)).join(separator)}\r
|
|
363
|
+
`;
|
|
364
|
+
const fields = {};
|
|
365
|
+
for (const c of columns.filter((c2) => c2.kind === "field"))
|
|
366
|
+
fields[c.name] = example(c);
|
|
367
|
+
for (const c of columns.filter((c2) => c2.kind === "item")) {
|
|
368
|
+
const [list = "", key = ""] = c.name.split(".");
|
|
369
|
+
fields[list] ??= [{}];
|
|
370
|
+
const [first] = fields[list];
|
|
371
|
+
if (first)
|
|
372
|
+
first[key] = example(c);
|
|
373
|
+
}
|
|
374
|
+
const envelope = {
|
|
375
|
+
schema_version: RECORDS_SCHEMA_VERSION,
|
|
376
|
+
source: {
|
|
377
|
+
provider: source?.provider ?? "sheet",
|
|
378
|
+
account: source?.account ?? "main",
|
|
379
|
+
batch_id: source?.batch_id ?? "first-import"
|
|
380
|
+
},
|
|
381
|
+
records: [
|
|
382
|
+
{
|
|
383
|
+
key: `${type}-1`,
|
|
384
|
+
type,
|
|
385
|
+
external_id: `${type}-1`,
|
|
386
|
+
operation: "upsert",
|
|
387
|
+
fields,
|
|
388
|
+
relations: columns.filter((c) => c.kind === "role").map(exampleRef)
|
|
389
|
+
}
|
|
390
|
+
]
|
|
391
|
+
};
|
|
392
|
+
return `${JSON.stringify(envelope, null, 2)}
|
|
393
|
+
`;
|
|
394
|
+
}, "recordTemplate");
|
|
395
|
+
var csvRows = /* @__PURE__ */ __name((text, separator) => {
|
|
396
|
+
const rows = [];
|
|
397
|
+
let cells = [];
|
|
398
|
+
let cell = "";
|
|
399
|
+
let quoted = false;
|
|
400
|
+
let line = 1;
|
|
401
|
+
let start = 1;
|
|
402
|
+
const end = /* @__PURE__ */ __name(() => {
|
|
403
|
+
cells.push(cell);
|
|
404
|
+
cell = "";
|
|
405
|
+
}, "end");
|
|
406
|
+
for (let i = 0; i < text.length; i++) {
|
|
407
|
+
const c = text[i];
|
|
408
|
+
if (quoted) {
|
|
409
|
+
if (c === '"' && text[i + 1] === '"') {
|
|
410
|
+
cell += '"';
|
|
411
|
+
i++;
|
|
412
|
+
} else if (c === '"')
|
|
413
|
+
quoted = false;
|
|
414
|
+
else {
|
|
415
|
+
if (c === "\n")
|
|
416
|
+
line++;
|
|
417
|
+
cell += c;
|
|
418
|
+
}
|
|
419
|
+
} else if (c === '"' && cell === "")
|
|
420
|
+
quoted = true;
|
|
421
|
+
else if (c === separator)
|
|
422
|
+
end();
|
|
423
|
+
else if (c === "\n" || c === "\r") {
|
|
424
|
+
if (c === "\r" && text[i + 1] === "\n")
|
|
425
|
+
i++;
|
|
426
|
+
end();
|
|
427
|
+
rows.push({ cells, line: start });
|
|
428
|
+
cells = [];
|
|
429
|
+
line++;
|
|
430
|
+
start = line;
|
|
431
|
+
} else
|
|
432
|
+
cell += c;
|
|
433
|
+
}
|
|
434
|
+
if (cell !== "" || cells.length > 0) {
|
|
435
|
+
end();
|
|
436
|
+
rows.push({ cells, line: start });
|
|
437
|
+
}
|
|
438
|
+
return rows.filter((r) => r.cells.some((c) => c.trim() !== ""));
|
|
439
|
+
}, "csvRows");
|
|
440
|
+
var csvSeparator = /* @__PURE__ */ __name((header) => {
|
|
441
|
+
const count = /* @__PURE__ */ __name((s) => header.split(s).length - 1, "count");
|
|
442
|
+
return [";", " ", ","].reduce((best, s) => count(s) > count(best) ? s : best, ",");
|
|
443
|
+
}, "csvSeparator");
|
|
444
|
+
var DAY_DOTTED = /^(\d{1,2})[./](\d{1,2})[./](\d{4})$/;
|
|
445
|
+
var normalized = /* @__PURE__ */ __name((column, raw) => {
|
|
446
|
+
const value = raw.trim();
|
|
447
|
+
switch (column.shape) {
|
|
448
|
+
case "decimal": {
|
|
449
|
+
const plain = value.replace(/[\s ]/g, "");
|
|
450
|
+
return /^\d+,\d+$/.test(plain) ? plain.replace(",", ".") : plain;
|
|
451
|
+
}
|
|
452
|
+
case "day": {
|
|
453
|
+
const dotted = DAY_DOTTED.exec(value);
|
|
454
|
+
return dotted ? `${dotted[3]}-${dotted[2]?.padStart(2, "0")}-${dotted[1]?.padStart(2, "0")}` : value;
|
|
455
|
+
}
|
|
456
|
+
case "currency":
|
|
457
|
+
return value.toUpperCase();
|
|
458
|
+
case "integer":
|
|
459
|
+
return /^-?\d+$/.test(value) ? Number(value) : value;
|
|
460
|
+
case "boolean":
|
|
461
|
+
return /^(true|yes|1|да|sí|si)$/i.test(value) ? true : /^(false|no|0|нет)$/i.test(value) ? false : value;
|
|
462
|
+
case "list":
|
|
463
|
+
return value.split(LIST_SEPARATOR).map((v) => v.trim()).filter(Boolean);
|
|
464
|
+
default:
|
|
465
|
+
return column.many ? value.split(LIST_SEPARATOR).map((v) => v.trim()).filter(Boolean) : value;
|
|
466
|
+
}
|
|
467
|
+
}, "normalized");
|
|
468
|
+
var unknownType = /* @__PURE__ */ __name((type) => ({
|
|
469
|
+
pointer: "",
|
|
470
|
+
code: "record.type",
|
|
471
|
+
message: `no table for ${type}: use one of ${TABLE_RECORD_TYPES.join(", ")}`
|
|
472
|
+
}), "unknownType");
|
|
473
|
+
var relationsOf = /* @__PURE__ */ __name((column, raw) => {
|
|
474
|
+
const targets = column.targets ?? [];
|
|
475
|
+
const values = column.many ? raw.split(LIST_SEPARATOR) : [raw];
|
|
476
|
+
const out = [];
|
|
477
|
+
for (const value of values.map((v) => v.trim()).filter(Boolean)) {
|
|
478
|
+
const at = value.indexOf(":");
|
|
479
|
+
const named = at > 0 ? value.slice(0, at) : "";
|
|
480
|
+
if (targets.length === 1 && !targets.includes(named)) {
|
|
481
|
+
out.push({ role: column.name, type: targets[0], external_id: value });
|
|
482
|
+
continue;
|
|
483
|
+
}
|
|
484
|
+
if (!targets.includes(named) || at === value.length - 1)
|
|
485
|
+
return {
|
|
486
|
+
pointer: "",
|
|
487
|
+
code: "record.invalid",
|
|
488
|
+
message: `${column.name} takes <type>:<external id>, the type one of ${targets.join(", ")}: not ${value}`
|
|
489
|
+
};
|
|
490
|
+
out.push({ role: column.name, type: named, external_id: value.slice(at + 1) });
|
|
491
|
+
}
|
|
492
|
+
return out;
|
|
493
|
+
}, "relationsOf");
|
|
494
|
+
var envelopeOfCsv = /* @__PURE__ */ __name((text, { type, source, options }) => {
|
|
495
|
+
const columns = recordColumns(type);
|
|
496
|
+
if (columns.length === 0)
|
|
497
|
+
throw new TableError([unknownType(type)]);
|
|
498
|
+
const body = text.startsWith(BOM) ? text.slice(1) : text;
|
|
499
|
+
const separator = csvSeparator(body.slice(0, body.search(/\r?\n|$/)));
|
|
500
|
+
const [head, ...rows] = csvRows(body, separator);
|
|
501
|
+
if (!head)
|
|
502
|
+
throw new TableError([{ pointer: "", code: "envelope.invalid", message: "the file has no header row" }]);
|
|
503
|
+
const byName = new Map(columns.map((c) => [c.name, c]));
|
|
504
|
+
const header = head.cells.map((name) => name.trim());
|
|
505
|
+
const unknown = header.filter((name) => name !== "" && !byName.has(name));
|
|
506
|
+
if (unknown.length > 0)
|
|
507
|
+
throw new TableError([
|
|
508
|
+
{
|
|
509
|
+
pointer: "",
|
|
510
|
+
code: "envelope.invalid",
|
|
511
|
+
message: `columns ${type} has no field for: ${unknown.join(", ")}. Download the ${type} template for the list`,
|
|
512
|
+
place: { line: 1, column: unknown[0] }
|
|
513
|
+
}
|
|
514
|
+
]);
|
|
515
|
+
if (!header.includes("external_id"))
|
|
516
|
+
throw new TableError([
|
|
517
|
+
{ pointer: "", code: "envelope.invalid", message: "the header has no external_id column", place: { line: 1 } }
|
|
518
|
+
]);
|
|
519
|
+
const records = [];
|
|
520
|
+
const indexById = /* @__PURE__ */ new Map();
|
|
521
|
+
const places = /* @__PURE__ */ new Map();
|
|
522
|
+
const errors = [];
|
|
523
|
+
for (const row of rows) {
|
|
524
|
+
const cell = /* @__PURE__ */ __name((name) => row.cells[header.indexOf(name)] ?? "", "cell");
|
|
525
|
+
const id = cell("external_id").trim();
|
|
526
|
+
if (!id) {
|
|
527
|
+
errors.push({
|
|
528
|
+
pointer: "",
|
|
529
|
+
code: "record.invalid",
|
|
530
|
+
message: "a row has no external_id",
|
|
531
|
+
place: { line: row.line, column: "external_id" }
|
|
532
|
+
});
|
|
533
|
+
continue;
|
|
534
|
+
}
|
|
535
|
+
const known = indexById.get(id);
|
|
536
|
+
const index = known ?? records.length;
|
|
537
|
+
const record = records[index] ?? {
|
|
538
|
+
key: `${type}:${id}`,
|
|
539
|
+
type,
|
|
540
|
+
external_id: id,
|
|
541
|
+
operation: "upsert",
|
|
542
|
+
fields: {},
|
|
543
|
+
relations: []
|
|
544
|
+
};
|
|
545
|
+
if (known === void 0) {
|
|
546
|
+
records.push(record);
|
|
547
|
+
indexById.set(id, index);
|
|
548
|
+
places.set(pointerOf("records", index), { line: row.line });
|
|
549
|
+
}
|
|
550
|
+
const fields = record.fields;
|
|
551
|
+
const item = {};
|
|
552
|
+
let list = "";
|
|
553
|
+
header.forEach((name, i) => {
|
|
554
|
+
const column = byName.get(name);
|
|
555
|
+
const raw = row.cells[i] ?? "";
|
|
556
|
+
if (!column || column.kind === "id" || raw.trim() === "")
|
|
557
|
+
return;
|
|
558
|
+
const at = { line: row.line, column: name };
|
|
559
|
+
if (column.kind === "field") {
|
|
560
|
+
fields[name] = normalized(column, raw);
|
|
561
|
+
places.set(pointerOf("records", index, "fields", name), at);
|
|
562
|
+
} else if (column.kind === "role") {
|
|
563
|
+
const relations = relationsOf(column, raw);
|
|
564
|
+
if (!Array.isArray(relations)) {
|
|
565
|
+
errors.push({ ...relations, pointer: pointerOf("records", index, "relations"), key: record.key, place: at });
|
|
566
|
+
return;
|
|
567
|
+
}
|
|
568
|
+
record.relations = [...(record.relations ?? []).filter((r) => r.role !== name), ...relations];
|
|
569
|
+
places.set(pointerOf("records", index, "relations"), at);
|
|
570
|
+
} else {
|
|
571
|
+
const [of = "", key = ""] = name.split(".");
|
|
572
|
+
list = of;
|
|
573
|
+
item[key] = normalized(column, raw);
|
|
574
|
+
}
|
|
575
|
+
});
|
|
576
|
+
if (list) {
|
|
577
|
+
fields[list] ??= [];
|
|
578
|
+
const items = fields[list];
|
|
579
|
+
places.set(pointerOf("records", index, "fields", list, items.length), { line: row.line });
|
|
580
|
+
items.push(item);
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
if (errors.length > 0)
|
|
584
|
+
throw new TableError(errors);
|
|
585
|
+
const envelope = {
|
|
586
|
+
schema_version: RECORDS_SCHEMA_VERSION,
|
|
587
|
+
source,
|
|
588
|
+
...options ? { options } : {},
|
|
589
|
+
records
|
|
590
|
+
};
|
|
591
|
+
return {
|
|
592
|
+
envelope,
|
|
593
|
+
placeOf(pointer) {
|
|
594
|
+
const item = /^\/records\/\d+\/fields\/([^/]+)\/\d+\/([^/]+)/.exec(pointer);
|
|
595
|
+
for (let at = pointer; at !== ""; at = at.slice(0, at.lastIndexOf("/"))) {
|
|
596
|
+
const place = places.get(at);
|
|
597
|
+
if (place)
|
|
598
|
+
return item && !place.column ? { ...place, column: `${item[1]}.${item[2]}` } : place;
|
|
599
|
+
}
|
|
600
|
+
return void 0;
|
|
601
|
+
}
|
|
602
|
+
};
|
|
603
|
+
}, "envelopeOfCsv");
|
|
604
|
+
|
|
245
605
|
// node_modules/.pnpm/qrcode-generator@2.0.4/node_modules/qrcode-generator/dist/qrcode.mjs
|
|
246
606
|
var qrcode = /* @__PURE__ */ __name(function(typeNumber, errorCorrectionLevel) {
|
|
247
607
|
const PAD0 = 236;
|
|
@@ -1876,7 +2236,7 @@ var createDataURL = /* @__PURE__ */ __name(function(width, height, getPixel) {
|
|
|
1876
2236
|
var qrcode_default = qrcode;
|
|
1877
2237
|
var stringToBytes = qrcode.stringToBytes;
|
|
1878
2238
|
|
|
1879
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2239
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/terminal/qr.js
|
|
1880
2240
|
var QUIET_ZONE = 4;
|
|
1881
2241
|
var BLACK_ON_WHITE = "\x1B[30;107m";
|
|
1882
2242
|
var RESET = "\x1B[0m";
|
|
@@ -1923,7 +2283,7 @@ var plainQr = /* @__PURE__ */ __name((link) => {
|
|
|
1923
2283
|
return lines.join("\n");
|
|
1924
2284
|
}, "plainQr");
|
|
1925
2285
|
|
|
1926
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2286
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/terminal/login-qr.js
|
|
1927
2287
|
var MARGIN = 2;
|
|
1928
2288
|
var atTerminal = /* @__PURE__ */ __name((input) => input.isTTY === true && !inputPolicy(input).noInput, "atTerminal");
|
|
1929
2289
|
var PASTE_QR = "agents: paste the QR code above into the chat as a code block, exactly as printed; when a new one is printed, paste it and say the old one expired";
|
|
@@ -1964,6 +2324,11 @@ export {
|
|
|
1964
2324
|
parseMarkdown,
|
|
1965
2325
|
parseMarkdownSpans,
|
|
1966
2326
|
countedPoll,
|
|
2327
|
+
TABLE_RECORD_TYPES,
|
|
2328
|
+
TableError,
|
|
2329
|
+
recordColumns,
|
|
2330
|
+
recordTemplate,
|
|
2331
|
+
envelopeOfCsv,
|
|
1967
2332
|
terminalQr,
|
|
1968
2333
|
plainQr,
|
|
1969
2334
|
atTerminal,
|
|
@@ -2,15 +2,15 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
QUERY_REASONS
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-63QXCE5Z.js";
|
|
6
6
|
import {
|
|
7
7
|
defineReasons
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-UVZLK3M4.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.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/errors/reasons.js
|
|
14
14
|
var validation = /* @__PURE__ */ __name((reason, message) => [reason, "validation_error", message], "validation");
|
|
15
15
|
var QUERY = [
|
|
16
16
|
["query.aborted", "the search was stopped before it finished"],
|
|
@@ -23,8 +23,10 @@ var QUERY = [
|
|
|
23
23
|
["query.invalid-reference", "a reference in the query is not valid"],
|
|
24
24
|
["query.invalid-tag", "a tag in the query is not valid"],
|
|
25
25
|
["query.invalid-topic", "a topic in the query is not valid"],
|
|
26
|
-
["query.topic-scope", "a topic needs its chat in the query"]
|
|
27
|
-
|
|
26
|
+
["query.topic-scope", "a topic needs its chat in the query"],
|
|
27
|
+
["query.short-text", "a search by part of a name or a title needs three characters or more"],
|
|
28
|
+
["query.legacy-date-field", "after: and before: are written date>= and date<"]
|
|
29
|
+
].map(([reason, message]) => validation(reason, message)).concat([["query.no-match", "not_found", "no person or chat in the store fits a name in the query"]]);
|
|
28
30
|
var SIGN_IN = [
|
|
29
31
|
["oauth.declined", "authentication_error", "the provider's consent was declined"],
|
|
30
32
|
["oauth.timeout", "timeout", "the sign-in was not finished in time"],
|
|
@@ -72,6 +74,37 @@ var OTHERS = [
|
|
|
72
74
|
["model.offline", "permission_error", "downloading a model needs the network; --offline was requested"],
|
|
73
75
|
["model.key-rejected", "invalid_response", "the model provider refused the API key (401 or 403)"],
|
|
74
76
|
["model.unreachable", "invalid_response", "the model provider could not be reached over the network"],
|
|
77
|
+
[
|
|
78
|
+
"model.empty-answer",
|
|
79
|
+
"invalid_response",
|
|
80
|
+
"the model answered nothing; given a picture, it may not read pictures \u2014 choose a vision model"
|
|
81
|
+
],
|
|
82
|
+
validation("model.address-refused", "the model address must be https, or http only on this computer"),
|
|
83
|
+
[
|
|
84
|
+
"local-only.refused",
|
|
85
|
+
"permission_error",
|
|
86
|
+
"local only is on and the address is not on this computer; nothing was sent"
|
|
87
|
+
],
|
|
88
|
+
["local-only.owner-only", "permission_error", "only the owner turns local only off, not an agent"],
|
|
89
|
+
["ai.images-not-allowed", "permission_error", "the AI model may not read pictures; models ai set --allow-remote"],
|
|
90
|
+
["picture-reading.off", "permission_error", "picture reading is never; models picture-reading set request"],
|
|
91
|
+
["picture-reading.owner-only", "permission_error", "only the owner turns picture reading on, not an agent"],
|
|
92
|
+
validation("picture-reading.agent-missing", "choose the agent that reads: --agent claude or --agent codex"),
|
|
93
|
+
validation("picture-reading.not-a-picture", "the file is not a PNG, JPEG or WebP picture"),
|
|
94
|
+
["picture-reading.unavailable-file", "not_found", "the picture could not be fetched, or is over the size limit"],
|
|
95
|
+
["picture-reading.unavailable", "configuration_error", "the chosen coding agent is not installed"],
|
|
96
|
+
["picture-reading.failed", "invalid_response", "the coding agent failed or answered nothing"],
|
|
97
|
+
["picture-reading.timeout", "timeout", "the coding agent gave no answer in time"],
|
|
98
|
+
[
|
|
99
|
+
"ai.owner-only",
|
|
100
|
+
"permission_error",
|
|
101
|
+
"only the owner chooses, unsets, checks or removes the AI model and its key, or revokes its consent"
|
|
102
|
+
],
|
|
103
|
+
["ai.setting-invalid", "configuration_error", "the ai section or the model given is not one WireCat can use"],
|
|
104
|
+
validation("ai.address-refused", "the AI model setting names an address WireCat refuses: plain http to another computer, or Ollama off this computer"),
|
|
105
|
+
["ai.not-set", "configuration_error", "no AI model is chosen; models ai set chooses one"],
|
|
106
|
+
["ai.key-missing", "configuration_error", "no API key is stored for the AI model's address"],
|
|
107
|
+
["ai.ok", "invalid_response", "models ai check: the model answered (a result, never raised)"],
|
|
75
108
|
[
|
|
76
109
|
"contract.unacknowledged-override",
|
|
77
110
|
"configuration_error",
|
|
@@ -96,6 +129,18 @@ var OTHERS = [
|
|
|
96
129
|
validation("finding.unknown-field", "a finding has a field its kind does not take"),
|
|
97
130
|
validation("finding.quote-not-found", "a finding's quote is not in the text it cites, word for word"),
|
|
98
131
|
validation("finding.missing-field", "a finding leaves out a field its kind needs"),
|
|
132
|
+
[
|
|
133
|
+
"agent.unrestricted",
|
|
134
|
+
"permission_error",
|
|
135
|
+
"nothing holds this agent to the CLI's commands, so no schedule starts it"
|
|
136
|
+
],
|
|
137
|
+
["read-only.output-outside", "permission_error", "a read-only process writes files only inside its working folder"],
|
|
138
|
+
[
|
|
139
|
+
"agent.refused",
|
|
140
|
+
"permission_error",
|
|
141
|
+
"the schedule changed since it was saved, or starts no agent a schedule may run"
|
|
142
|
+
],
|
|
143
|
+
validation("agent.cost-unknown", "the agent reports no cost, so a cost cap cannot stop it"),
|
|
99
144
|
validation("document.changed", "the document changed while it was read; nothing was saved"),
|
|
100
145
|
["document.not-imported", "not_found", "the document is not imported in this source account"],
|
|
101
146
|
["extraction.invalid-proposals", "invalid_response", "the model's memory proposals could not be used"],
|
|
@@ -312,6 +357,13 @@ var OTHERS = [
|
|
|
312
357
|
["stage.owner-only", "permission_error", "only the owner confirms mappings and edits a base set, not an agent"],
|
|
313
358
|
validation("stage.unmapped", "no stage of the row's pipeline maps to that base stage; map one first"),
|
|
314
359
|
["stage.not-found", "not_found", "no stored stage has that reference or name"],
|
|
360
|
+
validation("stage.answer-invalid", "the agent's answer to stages suggest is not the JSON stage map it asks for"),
|
|
361
|
+
["stage.model-answer-invalid", "invalid_response", "the AI model's answer to stages suggest is not the stage map"],
|
|
362
|
+
[
|
|
363
|
+
"stage.model-agent",
|
|
364
|
+
"permission_error",
|
|
365
|
+
"an agent's run does not send stages to the AI model; it answers the task itself with --dry-run and --text-file"
|
|
366
|
+
],
|
|
315
367
|
validation("pipeline.ambiguous", "more than one pipeline has that name; name it by its pipeline: reference"),
|
|
316
368
|
validation("pipeline.duplicate", "a pipeline of that name and kind is already stored"),
|
|
317
369
|
validation("pipeline.field", "a pipeline needs a name and at least one stage, each named once"),
|
|
@@ -326,9 +378,11 @@ var OTHERS = [
|
|
|
326
378
|
validation("crm.write-unsupported", "the CRM does not take this write, or does not recognise a repeated one"),
|
|
327
379
|
validation("crm.unlisted-held", "a list of every id would mark most of a kind deleted; nothing was, until --rescan"),
|
|
328
380
|
validation("crm.narrowing-held", "the default scope mine would mark most of a kind's stored rows deleted; none is, until the owner sets the scope"),
|
|
381
|
+
validation("crm.unassigned-dropped", "the CRM does not let this sign-in count a user in unassigned as nobody's; that user's deals are not copied"),
|
|
329
382
|
validation("crm.not-reported", "the CRM did not list users or departments; what they would say is unknown, nothing withdrawn"),
|
|
330
383
|
validation("crm.reference-unknown", "a CRM row names a contact, company or user the store does not hold; that link was not made"),
|
|
331
384
|
validation("crm.pending-dropped", "relationships waited too long for an end that never came; they were dropped"),
|
|
385
|
+
validation("crm.activities-failed", "the activities and tasks could not be read; the deals and leads were synced"),
|
|
332
386
|
validation("crm.email-ambiguous", "a CRM contact's email belongs to more than one person; the owner decides"),
|
|
333
387
|
validation("crm.own-unknown", "no own company of the CRM account is stored, so its users are no one's employees yet"),
|
|
334
388
|
validation("relationship.reference-unknown", "a reported relationship names something the store does not hold"),
|
|
@@ -367,6 +421,11 @@ var OTHERS = [
|
|
|
367
421
|
validation("order.status", "a rejected or deleted order's status does not change"),
|
|
368
422
|
["model.not-downloaded", "not_found", "the model is not downloaded on this machine"],
|
|
369
423
|
["person.no-owner", "not_found", "no person is marked as the owner in the store"],
|
|
424
|
+
["person.unknown", "not_found", "the store has no person by that reference; people list gives person:<uid>"],
|
|
425
|
+
["person.no-doubt", "not_found", "nothing about that person is in doubt; people links check lists who is"],
|
|
426
|
+
validation("person.owner", "the owner's own person is not test data"),
|
|
427
|
+
validation("person.no-identity", "a person with no identity is not test data; there is nothing to hide"),
|
|
428
|
+
validation("person.from-required", "say whom the identity leaves: --from person:<uid>, or person:me for the owner"),
|
|
370
429
|
[
|
|
371
430
|
"identity.separated",
|
|
372
431
|
"conflict",
|
|
@@ -382,15 +441,31 @@ var OTHERS = [
|
|
|
382
441
|
"conflict",
|
|
383
442
|
"the people a merge or a proposed link names changed since; undo the later merge, or propose the link again"
|
|
384
443
|
],
|
|
444
|
+
["identity.no-merge", "not_found", "nothing of that person is merged into the other; people show lists the merges"],
|
|
445
|
+
validation("identity.held-elsewhere", "the identity sits on another person than the one named; name that person to take it off them"),
|
|
446
|
+
validation("identity.several-persons", "the identities that leave a person are all of that one person"),
|
|
447
|
+
validation("identity.nothing-left", "a split leaves at least one identity with the person"),
|
|
448
|
+
[
|
|
449
|
+
"identity.kept-together",
|
|
450
|
+
"conflict",
|
|
451
|
+
"the owner kept these identities together by turning down their split; only the owner splits them"
|
|
452
|
+
],
|
|
385
453
|
[
|
|
386
454
|
"identity.rejected",
|
|
387
455
|
"conflict",
|
|
388
456
|
"the owner rejected linking these people on this evidence; only a new signal or identity proposes them again"
|
|
389
457
|
],
|
|
390
458
|
validation("identity.same", "the two identities are one person already"),
|
|
459
|
+
validation("identity.not-shared", "only a match on a shared mailbox can say the mailbox is a company's"),
|
|
460
|
+
["organization.not-found", "not_found", "no stored organization has that id"],
|
|
461
|
+
validation("organization.unnamed", "a free mailbox names no company; name the organization or the company"),
|
|
462
|
+
validation("organization.ambiguous", "more than one organization matches; name the one meant as a reference"),
|
|
391
463
|
validation("identity.shared-phone", "more than six people share the phone number, so it proposes no one"),
|
|
464
|
+
validation("identity.common-name", "more than six people have the name, so it proposes no one"),
|
|
465
|
+
validation("identity.owner", "one side is the owner's person, and only the owner joins anyone to themselves"),
|
|
392
466
|
validation("identity.shared-email", "more than six people share the address, so it proposes no one"),
|
|
393
467
|
validation("identity-link.dedicated-review", "an identity link is staged and decided through the people review"),
|
|
468
|
+
validation("identity-split.dedicated-review", "a split of a person is staged and decided through the people review"),
|
|
394
469
|
["transcription.no-key", "authentication_error", "no OpenAI key is set for transcription"],
|
|
395
470
|
validation("transcription.too-large", "the audio is over the transcription provider's size limit"),
|
|
396
471
|
[
|
|
@@ -2,12 +2,12 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
CliError
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-ELJUBPY4.js";
|
|
6
6
|
import {
|
|
7
7
|
__name
|
|
8
8
|
} from "./chunk-ZVVMGPBJ.js";
|
|
9
9
|
|
|
10
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
10
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/sends/permissions.js
|
|
11
11
|
var LEVELS = ["deny", "readonly", "ask", "allow"];
|
|
12
12
|
var DANGEROUS = /* @__PURE__ */ new Set(["messages.delete", "bot.messages.delete", "topics.delete", "chats.delete", "chats.clear"]);
|
|
13
13
|
var skipFlagFor = /* @__PURE__ */ __name((key) => DANGEROUS.has(key) ? "--allow-dangerous" : "--yes", "skipFlagFor");
|
|
@@ -29,6 +29,7 @@ var DEFAULT_PERMISSIONS = {
|
|
|
29
29
|
"store.migrate": "ask",
|
|
30
30
|
"store.repair": "ask",
|
|
31
31
|
"store.reset": "ask",
|
|
32
|
+
"store.import": "ask",
|
|
32
33
|
"store.clear": "ask",
|
|
33
34
|
"store.decrypt": "ask",
|
|
34
35
|
"store.copies.delete": "ask",
|
|
@@ -5,15 +5,15 @@ import {
|
|
|
5
5
|
readLock,
|
|
6
6
|
releaseLock,
|
|
7
7
|
takeLock
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-SXZGCD6E.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.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/mcp/http/state.js
|
|
14
14
|
import { existsSync as existsSync2, readFileSync as readFileSync2 } from "node:fs";
|
|
15
15
|
|
|
16
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
16
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/mcp/http/activity.js
|
|
17
17
|
import { randomBytes } from "node:crypto";
|
|
18
18
|
import { chmodSync, existsSync, mkdirSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
19
19
|
import { dirname } from "node:path";
|
|
@@ -86,7 +86,7 @@ var activityRecorder = /* @__PURE__ */ __name((path, now = Date.now) => {
|
|
|
86
86
|
};
|
|
87
87
|
}, "activityRecorder");
|
|
88
88
|
|
|
89
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
89
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/mcp/http/state.js
|
|
90
90
|
var ACCESS_SECONDS = 60 * 60;
|
|
91
91
|
var REFRESH_SECONDS = 30 * 24 * 60 * 60;
|
|
92
92
|
var readStored = /* @__PURE__ */ __name((path) => existsSync2(path) ? JSON.parse(readFileSync2(path, "utf8")) : { clients: [], tokens: [] }, "readStored");
|