@wirecat/cli-memo 0.131.51 → 0.131.52

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.
Files changed (117) hide show
  1. package/dist/bin/memo.js +2 -2
  2. package/dist/bundle/{all-profiles-3R3VE3W2.js → all-profiles-ZFVBLT2D.js} +5 -5
  3. package/dist/bundle/{anthropic-QVYJRACM.js → anthropic-UG2YHOT7.js} +3 -3
  4. package/dist/bundle/{app-server-T3D2PIGZ.js → app-server-AQYA4TB6.js} +35 -35
  5. package/dist/bundle/auto-2AY6K6DI.js +86 -0
  6. package/dist/bundle/{bun-DTDD2OHK.js → bun-QJUFWKEZ.js} +2 -2
  7. package/dist/bundle/{bun-sqlite-DWICJAH3.js → bun-sqlite-GWVRHYF4.js} +2 -2
  8. package/dist/bundle/{chunk-SXVPRYEF.js → chunk-2CBOPOC7.js} +15 -12
  9. package/dist/bundle/{chunk-ECLBZGWI.js → chunk-2GEV2TXW.js} +3 -3
  10. package/dist/bundle/{chunk-PX2B5ZRL.js → chunk-3O46NA2H.js} +102 -60
  11. package/dist/bundle/{chunk-6MEVHKIO.js → chunk-4ISZPK6D.js} +1 -1
  12. package/dist/bundle/{chunk-JBSMBHTM.js → chunk-55GFDV24.js} +5 -5
  13. package/dist/bundle/{chunk-QIFK3EZM.js → chunk-5WT6SEXS.js} +25 -9
  14. package/dist/bundle/{chunk-4MWP6Z3W.js → chunk-65576OCE.js} +1 -1
  15. package/dist/bundle/{chunk-5ZGOT57S.js → chunk-6BVWU2UM.js} +2 -2
  16. package/dist/bundle/{chunk-REROHDUR.js → chunk-6GF4TIVM.js} +1 -1
  17. package/dist/bundle/{chunk-RL2DSQCD.js → chunk-6PQIXQFD.js} +8 -8
  18. package/dist/bundle/{chunk-PWYCF76F.js → chunk-6ZQK3L35.js} +2 -2
  19. package/dist/bundle/{chunk-E3WIMCV5.js → chunk-7SVHEGRO.js} +1 -1
  20. package/dist/bundle/{chunk-XN5YDZY7.js → chunk-A36ASW3I.js} +1 -1
  21. package/dist/bundle/{chunk-ZC2LNXGO.js → chunk-A7DXLOMS.js} +1 -1
  22. package/dist/bundle/{chunk-6O37NSG6.js → chunk-AGOUP5AH.js} +4 -4
  23. package/dist/bundle/{chunk-OBVKXHOH.js → chunk-AU5GAMGM.js} +413 -357
  24. package/dist/bundle/{chunk-H65NWA3X.js → chunk-EEEZGK2J.js} +1 -1
  25. package/dist/bundle/{chunk-O5Z74SBZ.js → chunk-EKQNL6VJ.js} +23 -21
  26. package/dist/bundle/{chunk-7C3MP5LH.js → chunk-EQUPZVV6.js} +5 -5
  27. package/dist/bundle/{chunk-LYUVULFK.js → chunk-ERZBEQAY.js} +267 -259
  28. package/dist/bundle/{chunk-HRLQQLVD.js → chunk-ETYAJPIT.js} +20 -20
  29. package/dist/bundle/{chunk-GSCGRBEQ.js → chunk-FWCFEJWD.js} +173 -153
  30. package/dist/bundle/{chunk-E7TMOUWZ.js → chunk-G4Z4WSIG.js} +1 -1
  31. package/dist/bundle/{chunk-56BBTOS2.js → chunk-G52Y3KOO.js} +1 -1
  32. package/dist/bundle/{chunk-GBWOMPZ7.js → chunk-G7K4J3NS.js} +3 -3
  33. package/dist/bundle/{chunk-ROP27ZJU.js → chunk-GJWNHWG7.js} +31 -31
  34. package/dist/bundle/{chunk-4A6JOJLR.js → chunk-I4LXP4HQ.js} +4 -4
  35. package/dist/bundle/{chunk-XGNNI3S3.js → chunk-IALGFO44.js} +2 -2
  36. package/dist/bundle/{chunk-MVV32ZTO.js → chunk-IKG2OPHU.js} +7 -15
  37. package/dist/bundle/{chunk-JCNBJ3FN.js → chunk-KGPD3OCD.js} +170 -57
  38. package/dist/bundle/{chunk-PNNM72BO.js → chunk-LUHMRW3P.js} +7 -4
  39. package/dist/bundle/{chunk-YPLKNKAD.js → chunk-LX65W7IK.js} +4 -4
  40. package/dist/bundle/{chunk-OJFRMK2W.js → chunk-M64NVDB4.js} +3 -3
  41. package/dist/bundle/{chunk-5JY464PN.js → chunk-MICF3K6S.js} +12 -12
  42. package/dist/bundle/{chunk-AEVTXHTY.js → chunk-N5J6GT7C.js} +4 -4
  43. package/dist/bundle/{chunk-4RHIJMRX.js → chunk-NIUWQP7F.js} +30 -28
  44. package/dist/bundle/{chunk-O5UP2KZL.js → chunk-NNUP36UQ.js} +1 -1
  45. package/dist/bundle/{chunk-UDAATSWZ.js → chunk-NOEXRGYH.js} +10 -10
  46. package/dist/bundle/{chunk-CZOBBAXM.js → chunk-NUQ3N3V3.js} +7 -7
  47. package/dist/bundle/{chunk-ETD2DRJD.js → chunk-NZKDNBYE.js} +6 -6
  48. package/dist/bundle/{chunk-CPLYNBAJ.js → chunk-OIPJYDLZ.js} +1 -1
  49. package/dist/bundle/{chunk-526KVXRI.js → chunk-OWS67HTV.js} +2 -2
  50. package/dist/bundle/{chunk-FZ4GVE36.js → chunk-PBM5GH7S.js} +2 -2
  51. package/dist/bundle/{chunk-4GWFRZ2U.js → chunk-PKVXZZTM.js} +58 -1
  52. package/dist/bundle/{chunk-QFC7V5VW.js → chunk-RYY4YRKQ.js} +5 -5
  53. package/dist/bundle/{chunk-WPW6ULD7.js → chunk-S7X5ZMQN.js} +2 -2
  54. package/dist/bundle/{chunk-BUHTAMPF.js → chunk-TM6R3Z45.js} +1 -1
  55. package/dist/bundle/{chunk-H7RSMNHL.js → chunk-TQS6ZKC3.js} +483 -402
  56. package/dist/bundle/{chunk-V3TELYLZ.js → chunk-U4ZD5SYO.js} +1 -1
  57. package/dist/bundle/{chunk-N3UA5PO4.js → chunk-U6E3BGHO.js} +9 -9
  58. package/dist/bundle/{chunk-FJ3DAE4M.js → chunk-VOWEZBOJ.js} +1 -1
  59. package/dist/bundle/{chunk-3OL3QRFS.js → chunk-X6XIW76O.js} +5 -5
  60. package/dist/bundle/{chunk-JINNS3FI.js → chunk-XIHQOSCT.js} +1 -1
  61. package/dist/bundle/{chunk-UQ2OA6EM.js → chunk-ZKXIZD4C.js} +4 -4
  62. package/dist/bundle/{chunk-AWLAMVNY.js → chunk-ZVJAZXME.js} +4 -4
  63. package/dist/bundle/{chunk-66A646SL.js → chunk-ZVR6S4XB.js} +7 -7
  64. package/dist/bundle/{chunk-YZB5IL4L.js → chunk-ZYQEWB6P.js} +2 -2
  65. package/dist/bundle/{command-contract-OTVOQLZS.js → command-contract-7AADJ3UC.js} +11 -11
  66. package/dist/bundle/{decode-ISKRNDDM.js → decode-XMIBTI5O.js} +2 -2
  67. package/dist/bundle/{echarts-TINXXXCB.js → echarts-W7DPDJA5.js} +2 -2
  68. package/dist/bundle/{embed-R2KJDGEX.js → embed-EP3KKO6Y.js} +3 -3
  69. package/dist/bundle/{embedder-X2Y5RLKE.js → embedder-ENGCALJ7.js} +6 -6
  70. package/dist/bundle/{entry-2MUKT36Z.js → entry-BGSKREOS.js} +4 -4
  71. package/dist/bundle/failure-ZKQVXWAB.js +66 -0
  72. package/dist/bundle/{first-run-6BSAM4BD.js → first-run-4EBMV2EM.js} +5 -5
  73. package/dist/bundle/{first-screen-ALXB4ONR.js → first-screen-2TM3BF2Y.js} +12 -12
  74. package/dist/bundle/{instructions-E5NBM2NJ.js → instructions-A42XETMK.js} +1 -1
  75. package/dist/bundle/{mcp-YUPBMZPV.js → mcp-5LAWRSJK.js} +35 -35
  76. package/dist/bundle/memo.js +6 -6
  77. package/dist/bundle/{node-NBHZ4XWV.js → node-IRL66JK2.js} +2 -2
  78. package/dist/bundle/{node-sqlite-3CBWCPNC.js → node-sqlite-SOGTH72B.js} +3 -3
  79. package/dist/bundle/{oauth-L5XC2THD.js → oauth-RB5W3AC7.js} +4 -4
  80. package/dist/bundle/{open-WR6QQPVB.js → open-552EJ4JC.js} +2 -2
  81. package/dist/bundle/{openai-MCPELYCJ.js → openai-ZLOHEEDH.js} +7 -7
  82. package/dist/bundle/{process-EAEC2FBD.js → process-46SUXGWW.js} +1 -1
  83. package/dist/bundle/{program-WKKBFQIW.js → program-ZLWKMT65.js} +59 -57
  84. package/dist/bundle/{prompt-M4Z35LQ5.js → prompt-2NHJSYKX.js} +2 -2
  85. package/dist/bundle/{recognize-VT6NKW6D.js → recognize-2LDM6KHL.js} +1 -1
  86. package/dist/bundle/{remote-6QTPH5PJ.js → remote-DBYHHENF.js} +4 -4
  87. package/dist/bundle/{rerank-MJYLXZ4K.js → rerank-N5T2TIIY.js} +4 -4
  88. package/dist/bundle/{serve-KQ6OL3OH.js → serve-S6B54R2F.js} +6 -6
  89. package/dist/bundle/server-KZZHFPTZ.js +61 -0
  90. package/dist/bundle/{server-UJIH2SBV.js → server-QH6AKPRV.js} +50 -50
  91. package/dist/bundle/server-WAIPBBM7.js +48 -0
  92. package/dist/bundle/{state-2PDCOSJN.js → state-ZXZGIIJW.js} +3 -3
  93. package/dist/bundle/{store-SXYAS5EI.js → store-PNJNDMQ4.js} +9 -9
  94. package/dist/bundle/store-maintenance-command-2ZVV3DGA.js +48 -0
  95. package/dist/bundle/update-6HXLLGTQ.js +69 -0
  96. package/dist/doctor/command.d.ts +30 -0
  97. package/dist/doctor/command.d.ts.map +1 -1
  98. package/dist/doctor/command.js +1 -1
  99. package/dist/doctor/command.js.map +1 -1
  100. package/dist/failure.js +2 -2
  101. package/dist/failure.js.map +1 -1
  102. package/dist/knowledge/relationships-scan.d.ts.map +1 -1
  103. package/dist/knowledge/relationships-scan.js +4 -3
  104. package/dist/knowledge/relationships-scan.js.map +1 -1
  105. package/dist/run/import.d.ts.map +1 -1
  106. package/dist/run/import.js +3 -2
  107. package/dist/run/import.js.map +1 -1
  108. package/dist/version.d.ts +1 -1
  109. package/dist/version.js +1 -1
  110. package/package.json +2 -2
  111. package/dist/bundle/auto-XJCSM7WE.js +0 -86
  112. package/dist/bundle/failure-KYUARIL2.js +0 -66
  113. package/dist/bundle/server-AVAJTC5G.js +0 -61
  114. package/dist/bundle/server-QAFF3RP5.js +0 -48
  115. package/dist/bundle/store-maintenance-command-ARTXRVYD.js +0 -48
  116. package/dist/bundle/update-MOZKRB2Z.js +0 -69
  117. /package/dist/bundle/{chunk-4ZSY3MKL.js → chunk-DPRGC5YX.js} +0 -0
@@ -1,10 +1,61 @@
1
1
  import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ CliError,
5
+ errorCodes
6
+ } from "./chunk-4ZW6ZJ2V.js";
3
7
  import {
4
8
  __name
5
9
  } from "./chunk-ZVVMGPBJ.js";
6
10
 
7
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/runs/secrets.js
11
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/errors/failures.js
12
+ var isCliFailure = /* @__PURE__ */ __name((value) => value instanceof Error && value.name === "CliError" && errorCodes.includes(value.code), "isCliFailure");
13
+ var isCommanderFailure = /* @__PURE__ */ __name((value) => {
14
+ const { code, exitCode } = value ?? {};
15
+ return value instanceof Error && typeof code === "string" && code.startsWith("commander.") && typeof exitCode === "number";
16
+ }, "isCommanderFailure");
17
+ var failureKey = /* @__PURE__ */ __name((error) => isCliFailure(error) ? error.code : error instanceof Error ? error.name : "error", "failureKey");
18
+ var SQLITE_CORRUPT = 11;
19
+ var SQLITE_NOTADB = 26;
20
+ var DAMAGED_TEXT = /database disk image is malformed|file is not a database|fts5: corruption/i;
21
+ var sqliteCode = /* @__PURE__ */ __name((error) => {
22
+ const { errcode, errno, name } = error ?? {};
23
+ const code = typeof errcode === "number" ? errcode : name === "SQLiteError" && typeof errno === "number" ? errno : null;
24
+ return code === null ? void 0 : code & 255;
25
+ }, "sqliteCode");
26
+ var damageIn = /* @__PURE__ */ __name((error) => {
27
+ if (isCliFailure(error) || isCommanderFailure(error))
28
+ return void 0;
29
+ let at = error;
30
+ for (let depth = 0; depth < 5 && at instanceof Error; depth += 1) {
31
+ const code = sqliteCode(at);
32
+ if (code !== void 0 && [SQLITE_CORRUPT, SQLITE_NOTADB].includes(code) || DAMAGED_TEXT.test(at.message))
33
+ return at;
34
+ at = at.cause;
35
+ }
36
+ return void 0;
37
+ }, "damageIn");
38
+ var wrapping = /* @__PURE__ */ __name((error, original) => {
39
+ Object.defineProperty(error, "cause", { value: original, configurable: true, writable: true });
40
+ if (original instanceof Error && original.stack)
41
+ error.stack = original.stack;
42
+ return error;
43
+ }, "wrapping");
44
+ var storeDamaged = /* @__PURE__ */ __name((error, next) => damageIn(error) ? wrapping(new CliError("configuration_error", `the store file is damaged${next ? `; \`${next}\` says what is damaged and what to do` : ""}`, { reason: "store.damaged" }), error) : error, "storeDamaged");
45
+ var damagedFile = /* @__PURE__ */ __name(async (files, work) => {
46
+ try {
47
+ return await work();
48
+ } catch (error) {
49
+ if (!damageIn(error))
50
+ throw error;
51
+ throw wrapping(new CliError("validation_error", `${files.join(" or ")} is damaged or not a database`, {
52
+ reason: "store.file-damaged"
53
+ }), error);
54
+ }
55
+ }, "damagedFile");
56
+ var isStoreDamage = /* @__PURE__ */ __name((error) => damageIn(error) !== void 0, "isStoreDamage");
57
+
58
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/runs/secrets.js
8
59
  var SECRET_WORDS = /* @__PURE__ */ new Set([
9
60
  "authorization",
10
61
  "cookie",
@@ -87,6 +138,12 @@ var RUN = /(?<![A-Za-z0-9_+/-])[A-Za-z0-9_+/-]{20,}/g;
87
138
  var HEX = /(?<![A-Za-z0-9])(?=[0-9]*[a-f])[0-9a-f]{20,}(?![A-Za-z0-9])/g;
88
139
 
89
140
  export {
141
+ isCliFailure,
142
+ failureKey,
143
+ sqliteCode,
144
+ storeDamaged,
145
+ damagedFile,
146
+ isStoreDamage,
90
147
  secretNamed,
91
148
  holdsCredential,
92
149
  withoutSecrets
@@ -5,7 +5,7 @@ import {
5
5
  installFiles,
6
6
  megabytes,
7
7
  sharedModelsDirectory
8
- } from "./chunk-GBWOMPZ7.js";
8
+ } from "./chunk-G7K4J3NS.js";
9
9
  import {
10
10
  importFrom
11
11
  } from "./chunk-Y5E2WNWB.js";
@@ -16,12 +16,12 @@ import {
16
16
  __name
17
17
  } from "./chunk-ZVVMGPBJ.js";
18
18
 
19
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/embeddings/embed.js
19
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/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.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/embeddings/onnx-runtime.js
24
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/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.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/embeddings/onnx-runtime.js
681
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/embeddings/onnx-runtime.js
682
682
  var ONNX_RUNTIME_VERSION = "1.30.0";
683
683
  var release = /* @__PURE__ */ __name((name, sha256, bytes) => ({
684
684
  name,
@@ -858,7 +858,7 @@ var openSession = /* @__PURE__ */ __name(async (bytes, threads, options = {}) =>
858
858
  return { ort, session: await ort.InferenceSession.create(bytes, options) };
859
859
  }, "openSession");
860
860
 
861
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/embeddings/embed.js
861
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/embeddings/embed.js
862
862
  var textModelsDirectory = /* @__PURE__ */ __name((env = process.env) => sharedModelsDirectory("text", env), "textModelsDirectory");
863
863
  var placedText = /* @__PURE__ */ __name((model, directory) => model.files.map((file) => [file, join2(directory, model.id, file.name)]), "placedText");
864
864
  var isTextModelInstalled = /* @__PURE__ */ __name((model, directory) => filesPresent(placedText(model, directory)), "isTextModelInstalled");
@@ -4,7 +4,7 @@ import {
4
4
  MAX_SECRET_INPUT,
5
5
  bufferedInput,
6
6
  inputPolicy
7
- } from "./chunk-CPLYNBAJ.js";
7
+ } from "./chunk-OIPJYDLZ.js";
8
8
  import {
9
9
  CliError
10
10
  } from "./chunk-4ZW6ZJ2V.js";
@@ -12,7 +12,7 @@ import {
12
12
  __name
13
13
  } from "./chunk-ZVVMGPBJ.js";
14
14
 
15
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/terminal/prompt.js
15
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/terminal/prompt.js
16
16
  import { createInterface } from "node:readline";
17
17
  import { Writable } from "node:stream";
18
18
  var readSecret = /* @__PURE__ */ __name(async (prompt, { input = process.stdin, output = process.stderr, echo = false, signal: givenSignal } = {}) => {
@@ -4,7 +4,7 @@ import {
4
4
  __name
5
5
  } from "./chunk-ZVVMGPBJ.js";
6
6
 
7
- // node_modules/.pnpm/@wirecat+cli-core@0.604.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_d9de6622c75caef4cd0a02912b39a001/node_modules/@wirecat/cli-core/dist/store/sqlite/drizzle/shared-55XJMTPA.js
7
+ // node_modules/.pnpm/@wirecat+cli-core@0.605.0_@wirecat+cli-base@0.82.0_commander@15.0.0_esbuild@0.28.2_type_eae6fabbffc2c6fec7070a9f7231a4be/node_modules/@wirecat/cli-core/dist/store/sqlite/drizzle/shared-55XJMTPA.js
8
8
  var entityKind = /* @__PURE__ */ Symbol.for("drizzle:entityKind");
9
9
  var kindsByConstructor = /* @__PURE__ */ new WeakMap();
10
10
  function collectKinds(ctor) {