@wirecat/zoom-cli 0.70.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.
Files changed (180) hide show
  1. package/dist/answer-entities.d.ts +2 -0
  2. package/dist/answer-entities.d.ts.map +1 -1
  3. package/dist/answers.d.ts +56 -0
  4. package/dist/answers.d.ts.map +1 -1
  5. package/dist/bin/zm.js +2 -2
  6. package/dist/bundle/{all-profiles-GE2TFJJP.js → all-profiles-XFIPF4GF.js} +12 -12
  7. package/dist/bundle/answer-policy-AT6CDEE5.js +110 -0
  8. package/dist/bundle/{anthropic-FA6NHENI.js → anthropic-SSUBR3BC.js} +29 -13
  9. package/dist/bundle/{app-server-IRADMSNX.js → app-server-7DJHHF2F.js} +68 -56
  10. package/dist/bundle/{bun-ZYZGGCX5.js → bun-6HBYWQIX.js} +2 -2
  11. package/dist/bundle/{bun-sqlite-Y24TUIGS.js → bun-sqlite-4L3Q55NB.js} +10 -6
  12. package/dist/bundle/{chunk-JULBAECW.js → chunk-23J2ANZ7.js} +16 -6
  13. package/dist/bundle/{chunk-4DSIWYGO.js → chunk-24OFZNRC.js} +39296 -24139
  14. package/dist/bundle/{chunk-LXXCLQCW.js → chunk-2MIBRVSV.js} +2 -2
  15. package/dist/bundle/{chunk-CHGUNZ3L.js → chunk-37NF5CBJ.js} +4 -4
  16. package/dist/bundle/chunk-3KRTEX5M.js +53 -0
  17. package/dist/bundle/{chunk-VNU5L37V.js → chunk-4SY67IUA.js} +34 -42
  18. package/dist/bundle/{chunk-XWQNJKTP.js → chunk-4XQWF3U2.js} +6 -6
  19. package/dist/bundle/{chunk-OAQLVV6W.js → chunk-4YIGXTBP.js} +3 -3
  20. package/dist/bundle/{chunk-RB33VTUW.js → chunk-5AELTC52.js} +810 -210
  21. package/dist/bundle/chunk-5MGICK47.js +1243 -0
  22. package/dist/bundle/{chunk-RRRJCHUC.js → chunk-5X4IY5JH.js} +4504 -1622
  23. package/dist/bundle/{chunk-EOSVN2ER.js → chunk-63QXCE5Z.js} +242 -242
  24. package/dist/bundle/{chunk-OE7EIP5L.js → chunk-6DCLZLGX.js} +1 -1
  25. package/dist/bundle/chunk-7GLJSJ7M.js +16 -0
  26. package/dist/bundle/{chunk-KM736RMJ.js → chunk-7IFO43Q5.js} +2 -2
  27. package/dist/bundle/{chunk-IWPXWGF7.js → chunk-7JYMGXLI.js} +44 -42
  28. package/dist/bundle/{chunk-LAG5O2FV.js → chunk-7OD3522V.js} +4162 -3769
  29. package/dist/bundle/{chunk-DCUWJITQ.js → chunk-7S4D5SM2.js} +60 -608
  30. package/dist/bundle/{chunk-3KC7C465.js → chunk-7SUWPMZG.js} +10 -15
  31. package/dist/bundle/{chunk-6IF5ZHDS.js → chunk-ADKMBXY4.js} +1 -1
  32. package/dist/bundle/{chunk-56OV5ASY.js → chunk-B3SILJBU.js} +18 -18
  33. package/dist/bundle/{chunk-CIZ25UPK.js → chunk-CANRIRNZ.js} +8241 -5553
  34. package/dist/bundle/{chunk-YUHM2OJM.js → chunk-CW46FWKW.js} +38 -123
  35. package/dist/bundle/{chunk-VSLDWT4E.js → chunk-D24OQAHM.js} +4 -4
  36. package/dist/bundle/{chunk-ZBKWRYRS.js → chunk-D5EUMWD5.js} +3 -3
  37. package/dist/bundle/{chunk-CSEBB4OP.js → chunk-DEPXZJ2V.js} +21 -150
  38. package/dist/bundle/{chunk-YJSPBUGB.js → chunk-DOCVEKP2.js} +51 -67
  39. package/dist/bundle/{chunk-V2E7QFZ3.js → chunk-EFF2XBHP.js} +2 -2
  40. package/dist/bundle/{chunk-XRFHQGOD.js → chunk-EG25AY4L.js} +1 -1
  41. package/dist/bundle/{chunk-FEM2JQN2.js → chunk-ELJUBPY4.js} +1 -1
  42. package/dist/bundle/{chunk-2U6SER67.js → chunk-ERJYJ36F.js} +2 -2
  43. package/dist/bundle/chunk-FSCPQQS5.js +244 -0
  44. package/dist/bundle/{chunk-BVWF4B33.js → chunk-H53WFZBN.js} +16 -139
  45. package/dist/bundle/{chunk-VJ5ZU4UF.js → chunk-I7CUMZD6.js} +3 -3
  46. package/dist/bundle/{chunk-OA37BWE5.js → chunk-IACWKZWS.js} +1 -1
  47. package/dist/bundle/{chunk-BSS6HX4O.js → chunk-IFBIXU6C.js} +2 -2
  48. package/dist/bundle/{chunk-UVPL7YAY.js → chunk-IU4DUUB3.js} +7 -7
  49. package/dist/bundle/{chunk-W7ZEEC4K.js → chunk-IXO4SCKE.js} +1 -1
  50. package/dist/bundle/{chunk-J3SKXICS.js → chunk-JAEPK457.js} +359 -765
  51. package/dist/bundle/{chunk-ZV3INEKM.js → chunk-JFPUYQSP.js} +5 -5
  52. package/dist/bundle/{chunk-ZS55EERO.js → chunk-JG4MNYG2.js} +1 -1
  53. package/dist/bundle/{chunk-IINZIP73.js → chunk-JRCH4YZP.js} +17 -10
  54. package/dist/bundle/{chunk-2JEM2YNV.js → chunk-JZ4XNNL7.js} +1 -1
  55. package/dist/bundle/chunk-K6HR6HCO.js +32 -0
  56. package/dist/bundle/{chunk-SNIY3JDN.js → chunk-KFZL67JP.js} +328 -60
  57. package/dist/bundle/{chunk-CEJJBZAE.js → chunk-KPIQXFNB.js} +375 -10
  58. package/dist/bundle/{chunk-M7VUXXGS.js → chunk-KWURWGGB.js} +137 -7
  59. package/dist/bundle/{chunk-M6JIXMQZ.js → chunk-LA6QUVGQ.js} +3 -2
  60. package/dist/bundle/{chunk-AISJCF7A.js → chunk-LLUNHAZ7.js} +4 -4
  61. package/dist/bundle/{chunk-KWRCP55G.js → chunk-LTWJM3ED.js} +17 -17
  62. package/dist/bundle/{chunk-IS3ZTT2Z.js → chunk-M3DMXDX6.js} +6 -6
  63. package/dist/bundle/{chunk-VW6BF6M7.js → chunk-MCPOZNWG.js} +1 -1
  64. package/dist/bundle/{chunk-L24UOUWG.js → chunk-MSQHSW4C.js} +2 -2
  65. package/dist/bundle/chunk-N4QNYWWG.js +71 -0
  66. package/dist/bundle/chunk-NMZQTYKJ.js +18 -0
  67. package/dist/bundle/{chunk-DNR4B5YV.js → chunk-OHCLQJOV.js} +3 -3
  68. package/dist/bundle/{chunk-MVOMLJYQ.js → chunk-OP5PGE2N.js} +4 -4
  69. package/dist/bundle/{chunk-QL7EMFIC.js → chunk-OY6N2ABP.js} +29 -23
  70. package/dist/bundle/chunk-PJWSGXOB.js +185 -0
  71. package/dist/bundle/{chunk-YTN2JN6N.js → chunk-QA6KIL7Q.js} +12 -8
  72. package/dist/bundle/{chunk-6HJFIMT7.js → chunk-QQUY4MZY.js} +1 -1
  73. package/dist/bundle/{chunk-ZSKE7N2U.js → chunk-QW7YTRV2.js} +3 -3
  74. package/dist/bundle/chunk-RJTGENHZ.js +109 -0
  75. package/dist/bundle/{chunk-RIPAUCKJ.js → chunk-RLCVPECY.js} +74 -67
  76. package/dist/bundle/{chunk-M7E44TMT.js → chunk-RN5SU2RN.js} +6 -6
  77. package/dist/bundle/{chunk-P3ASN72F.js → chunk-RX5CJ55S.js} +1 -1
  78. package/dist/bundle/{chunk-7QC4M4HS.js → chunk-RZUJMAMK.js} +4 -4
  79. package/dist/bundle/{chunk-OORMSM6O.js → chunk-S7SXSHRC.js} +21 -21
  80. package/dist/bundle/{chunk-SVF3NDAO.js → chunk-SXZGCD6E.js} +3 -3
  81. package/dist/bundle/{chunk-DXCTW3MV.js → chunk-T27IMG6X.js} +3 -1
  82. package/dist/bundle/{chunk-PV6OHXHN.js → chunk-TF2WKPNW.js} +18 -18
  83. package/dist/bundle/{chunk-X4ZF4XXI.js → chunk-U32VL3MA.js} +1 -1
  84. package/dist/bundle/{chunk-RQG5VOGH.js → chunk-U3NJBGLA.js} +3 -3
  85. package/dist/bundle/{chunk-WOIHSQAL.js → chunk-UVZLK3M4.js} +33 -9
  86. package/dist/bundle/chunk-VIV64MQM.js +779 -0
  87. package/dist/bundle/{chunk-2QFPVUM3.js → chunk-W3YTVEWV.js} +69 -6
  88. package/dist/bundle/{chunk-AUNW7N4I.js → chunk-WLVG4RBZ.js} +1 -1
  89. package/dist/bundle/{chunk-JRO2FWO2.js → chunk-WOAYHCM2.js} +1 -1
  90. package/dist/bundle/{chunk-RO3ZR4VP.js → chunk-WXTYYWZI.js} +13 -13
  91. package/dist/bundle/{chunk-RWIILYKW.js → chunk-WZGKHTA4.js} +2 -2
  92. package/dist/bundle/{chunk-GB5X3GBE.js → chunk-X2MP634F.js} +14 -5
  93. package/dist/bundle/{chunk-RGJ7OWHU.js → chunk-XPWZSW6Y.js} +61 -21
  94. package/dist/bundle/{chunk-D3PNCJD5.js → chunk-YVVJ6Y5C.js} +7 -7
  95. package/dist/bundle/chunk-ZHA56THL.js +2355 -0
  96. package/dist/bundle/{chunk-QO2KPU26.js → chunk-ZVFYGTGJ.js} +101 -44
  97. package/dist/bundle/{chunk-V5GRSOCZ.js → chunk-ZW5KHKMA.js} +5 -5
  98. package/dist/bundle/{cli-VRSQ7HAE.js → cli-IYYI7GAM.js} +215 -100
  99. package/dist/bundle/command-contract-TX7NSUBM.js +42 -0
  100. package/dist/bundle/command-server-entry-FXX4LJWF.js +171 -0
  101. package/dist/bundle/config-YKNM33J7.js +96 -0
  102. package/dist/bundle/{decode-523PUQMR.js → decode-SRGOOGBW.js} +6 -6
  103. package/dist/bundle/{dispatch-IZCAK47P.js → dispatch-OUHRPFUL.js} +11 -11
  104. package/dist/bundle/{dist-6WWKPEVW.js → dist-UZLNLAIO.js} +97 -56
  105. package/dist/bundle/{echarts-S5UMX2D3.js → echarts-7CM2MCMW.js} +2 -2
  106. package/dist/bundle/{embed-ODPDVHUK.js → embed-VEE56BOB.js} +7 -7
  107. package/dist/bundle/{embedder-PAXRBSZE.js → embedder-SZFYR543.js} +10 -10
  108. package/dist/bundle/{failure-R2OIHCE5.js → failure-MZBNM7M5.js} +3 -3
  109. package/dist/bundle/first-run-KWC7RKF2.js +29 -0
  110. package/dist/bundle/first-screen-DWKMNSEI.js +40 -0
  111. package/dist/bundle/{folders-ZXTOFY4T.js → folders-UQXRSDJJ.js} +5 -5
  112. package/dist/bundle/{instructions-DUB7E6C5.js → instructions-R7OHVAWH.js} +1 -1
  113. package/dist/bundle/{main-A7JSYQI6.js → main-EFUN2O3K.js} +21 -20
  114. package/dist/bundle/{mcp-M4QN2E7R.js → mcp-7KQUJNFN.js} +2 -2
  115. package/dist/bundle/{meetings-BDZQV3HR.js → meetings-5I2BDNTA.js} +9 -7
  116. package/dist/bundle/{node-E25KP53H.js → node-3N2JGZ7V.js} +2 -2
  117. package/dist/bundle/{node-sqlite-PHWDFZCP.js → node-sqlite-2UVEE2WM.js} +11 -7
  118. package/dist/bundle/{oauth-G2K46IYP.js → oauth-AYGD7UU3.js} +8 -8
  119. package/dist/bundle/{open-INWS5HIZ.js → open-3GUVDLGD.js} +6 -6
  120. package/dist/bundle/openai-NHCDLWWY.js +28 -0
  121. package/dist/bundle/{output-file-YGQYZCBJ.js → output-file-72JFXVHQ.js} +6 -6
  122. package/dist/bundle/{process-UJ2JHMJN.js → process-YAHHUFR5.js} +1 -1
  123. package/dist/bundle/{program-LYTGFV6L.js → program-OSZROCTK.js} +113 -118
  124. package/dist/bundle/{prompt-VTUCRCE4.js → prompt-HMCW4XQJ.js} +6 -6
  125. package/dist/bundle/{recognize-3CEPOW2F.js → recognize-VF5CA7EM.js} +5 -5
  126. package/dist/bundle/{remote-DRQEXEZL.js → remote-5C6VTPR2.js} +10 -8
  127. package/dist/bundle/{rerank-UL4KNNVN.js → rerank-ER7NEDOI.js} +8 -8
  128. package/dist/bundle/run-log-JKTLKXSK.js +124 -0
  129. package/dist/bundle/{serve-P5UWUOWQ.js → serve-QJWXJOM7.js} +10 -10
  130. package/dist/bundle/{server-M6XK2Y3X.js → server-KCIK3Y2P.js} +50 -48
  131. package/dist/bundle/server-LLGFDLLJ.js +75 -0
  132. package/dist/bundle/{services-4HRYNY62.js → services-LQMYJQG3.js} +121 -52
  133. package/dist/bundle/{speech-BBPBMFAO.js → speech-74GJQNQH.js} +20 -17
  134. package/dist/bundle/{state-GDSUNUSY.js → state-4XDGCHDF.js} +7 -7
  135. package/dist/bundle/{store-LBQ6FZP2.js → store-5Y5HK2L2.js} +28 -19
  136. package/dist/bundle/{store-VWLABMLF.js → store-Y56AHJ2Y.js} +64 -31
  137. package/dist/bundle/store-connection-4WI32AYU.js +89 -0
  138. package/dist/bundle/store-maintenance-command-PCXO5AH4.js +65 -0
  139. package/dist/bundle/{streaming-EJ3NM2C2.js → streaming-E5CR6HSR.js} +7 -7
  140. package/dist/bundle/{tokens-BE6CJMR5.js → tokens-E2QNVC4F.js} +7 -7
  141. package/dist/bundle/zm.js +34 -10
  142. package/dist/bundle/{zoom-app-YIEJLWCW.js → zoom-app-NVL7HEAX.js} +8 -8
  143. package/dist/contract-overrides.d.ts.map +1 -1
  144. package/dist/contract-overrides.js +0 -6
  145. package/dist/contract-overrides.js.map +1 -1
  146. package/dist/ingestion-search-commands.d.ts.map +1 -1
  147. package/dist/ingestion-search-commands.js +0 -10
  148. package/dist/ingestion-search-commands.js.map +1 -1
  149. package/dist/meeting-integration-commands.d.ts.map +1 -1
  150. package/dist/meeting-integration-commands.js +8 -6
  151. package/dist/meeting-integration-commands.js.map +1 -1
  152. package/dist/meeting-integration.d.ts +3 -1
  153. package/dist/meeting-integration.d.ts.map +1 -1
  154. package/dist/store-connection.d.ts.map +1 -1
  155. package/dist/store-connection.js +4 -3
  156. package/dist/store-connection.js.map +1 -1
  157. package/dist/unified-search.d.ts +4 -4
  158. package/dist/unified-search.d.ts.map +1 -1
  159. package/dist/unified-search.js +1 -24
  160. package/dist/unified-search.js.map +1 -1
  161. package/dist/version.d.ts +1 -1
  162. package/dist/version.js +1 -1
  163. package/package.json +4 -4
  164. package/skills/zoom-cli/SKILL.md +2 -2
  165. package/dist/bundle/answer-policy-GOXSDYDD.js +0 -104
  166. package/dist/bundle/chunk-5XWCBLUR.js +0 -27
  167. package/dist/bundle/chunk-AT2XKNFN.js +0 -342
  168. package/dist/bundle/chunk-GVT5363M.js +0 -35
  169. package/dist/bundle/chunk-VE2VNECR.js +0 -380
  170. package/dist/bundle/chunk-Y6C3N7YG.js +0 -12434
  171. package/dist/bundle/command-contract-RPRKHVU6.js +0 -41
  172. package/dist/bundle/config-QU6A6VIO.js +0 -90
  173. package/dist/bundle/first-run-NVTDR5VO.js +0 -28
  174. package/dist/bundle/first-screen-5RWZDWLK.js +0 -39
  175. package/dist/bundle/openai-T44ORVGQ.js +0 -25
  176. package/dist/bundle/run-log-UZAB5CWF.js +0 -118
  177. package/dist/bundle/server-F3NPVMS2.js +0 -72
  178. package/dist/bundle/store-connection-XEBFP56U.js +0 -83
  179. package/dist/bundle/store-maintenance-command-G43JN57J.js +0 -61
  180. /package/dist/bundle/{chunk-VOXIGICJ.js → chunk-YVNHQFLC.js} +0 -0
@@ -19,205 +19,16 @@ import {
19
19
  reference,
20
20
  string,
21
21
  variant
22
- } from "./chunk-WOIHSQAL.js";
22
+ } from "./chunk-UVZLK3M4.js";
23
23
  import {
24
24
  CliError,
25
25
  isCliError
26
- } from "./chunk-FEM2JQN2.js";
26
+ } from "./chunk-ELJUBPY4.js";
27
27
  import {
28
28
  __name
29
29
  } from "./chunk-ZVVMGPBJ.js";
30
30
 
31
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/types.js
32
- var QUERY_LIMITS = {
33
- bytes: 8192,
34
- depth: 32,
35
- nodes: 256
36
- };
37
- var spanSchema = object({ start: number(), end: number() });
38
- var predicateSchema = object({
39
- kind: literal("predicate"),
40
- field: string(),
41
- operator: picklist(["term", "phrase", "wildcard", "regex", "range"]),
42
- value: string(),
43
- upper: optional(string()),
44
- lower_inclusive: optional(boolean()),
45
- upper_inclusive: optional(boolean()),
46
- span: spanSchema,
47
- implicit: optional(literal(true)),
48
- slop: optional(pipe(number(), integer(), minValue(0)))
49
- });
50
- var queryNodeSchema = variant("kind", [
51
- predicateSchema,
52
- object({
53
- kind: literal("boolean"),
54
- clauses: array(object({ occur: picklist(["must", "should", "must_not"]), node: lazy(() => queryNodeSchema) })),
55
- span: spanSchema
56
- })
57
- ]);
58
- var queryAstSchema = object({
59
- version: literal(1),
60
- language: literal("lucene-v1"),
61
- root: queryNodeSchema
62
- });
63
- function queryError(reason, span, alternative, context = {}, details = {}) {
64
- throw new CliError("validation_error", `${context.command ?? "query"}: ${reason} at position ${span.start + 1}${alternative ? ` \u2014 ${alternative}` : ""}`, {
65
- reason,
66
- span,
67
- ...alternative ? { alternative } : {},
68
- ...context.guide ? { guide: context.guide } : {},
69
- ...details
70
- });
71
- }
72
- __name(queryError, "queryError");
73
- var walkQuery = /* @__PURE__ */ __name((node) => node.kind === "predicate" ? [node] : node.clauses.flatMap(({ node: node2 }) => walkQuery(node2)), "walkQuery");
74
-
75
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/dates.js
76
- var timezoneOf = /* @__PURE__ */ __name((given) => {
77
- const zone = given ?? Intl.DateTimeFormat().resolvedOptions().timeZone ?? "UTC";
78
- try {
79
- new Intl.DateTimeFormat("en", { timeZone: zone }).format(0);
80
- } catch {
81
- queryError("query.invalid-timezone", { start: 0, end: 0 }, "use an IANA timezone such as Europe/Madrid");
82
- }
83
- return zone;
84
- }, "timezoneOf");
85
- var calendar = /* @__PURE__ */ __name((value, span) => {
86
- if (!/^\d{4}-\d{2}-\d{2}$/u.test(value))
87
- queryError("query.invalid-date", span, "use an ISO date or a quoted timestamp with offset");
88
- const year = Number(value.slice(0, 4)), month = Number(value.slice(5, 7)), day = Number(value.slice(8, 10));
89
- const date = /* @__PURE__ */ new Date(0);
90
- date.setUTCFullYear(year, month - 1, day);
91
- date.setUTCHours(0, 0, 0, 0);
92
- if (date.getUTCFullYear() !== year || date.getUTCMonth() !== month - 1 || date.getUTCDate() !== day)
93
- queryError("query.invalid-date", span);
94
- return date;
95
- }, "calendar");
96
- var dayBoundary = /* @__PURE__ */ __name((value, zone, next, span) => {
97
- const date = calendar(value, span);
98
- if (next)
99
- date.setUTCDate(date.getUTCDate() + 1);
100
- const wanted = date.getUTCFullYear() * 1e4 + (date.getUTCMonth() + 1) * 100 + date.getUTCDate();
101
- const formatter = new Intl.DateTimeFormat("en-CA", {
102
- timeZone: zone,
103
- year: "numeric",
104
- month: "2-digit",
105
- day: "2-digit",
106
- era: "short"
107
- });
108
- const dayAt = /* @__PURE__ */ __name((time) => {
109
- const parts = formatter.formatToParts(time);
110
- const value2 = /* @__PURE__ */ __name((name) => Number(parts.find((p) => p.type === name)?.value), "value");
111
- const year = parts.find((p) => p.type === "era")?.value === "BC" ? 1 - value2("year") : value2("year");
112
- return year * 1e4 + value2("month") * 100 + value2("day");
113
- }, "dayAt");
114
- let lo = date.getTime() - 2 * 864e5, hi = date.getTime() + 2 * 864e5;
115
- while (lo < hi) {
116
- const mid = Math.floor((lo + hi) / 2);
117
- if (dayAt(mid) < wanted)
118
- lo = mid + 1;
119
- else
120
- hi = mid;
121
- }
122
- if (dayAt(lo) !== wanted)
123
- queryError("query.invalid-date", span, "this calendar day does not exist in the selected timezone");
124
- return lo;
125
- }, "dayBoundary");
126
- var WALL = /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2})(?:\.(\d{1,3}))?)?$/u;
127
- var wallTime = /* @__PURE__ */ __name((value, zone, span) => {
128
- const [, year, month, day, hour, minute, second = "0", fraction = "0"] = WALL.exec(value) ?? [];
129
- if (year === void 0)
130
- queryError("query.invalid-date", span, "use YYYY-MM-DDTHH:mm, with optional seconds");
131
- const wanted = Date.UTC(Number(year), Number(month) - 1, Number(day), Number(hour), Number(minute), Number(second), Number(fraction.padEnd(3, "0")));
132
- const check = new Date(wanted);
133
- if (check.getUTCDate() !== Number(day) || check.getUTCHours() !== Number(hour) || check.getUTCMinutes() !== Number(minute) || check.getUTCSeconds() !== Number(second))
134
- queryError("query.invalid-date", span);
135
- const formatter = new Intl.DateTimeFormat("en-CA", {
136
- timeZone: zone,
137
- year: "numeric",
138
- month: "2-digit",
139
- day: "2-digit",
140
- hour: "2-digit",
141
- minute: "2-digit",
142
- second: "2-digit",
143
- hourCycle: "h23"
144
- });
145
- const shown = /* @__PURE__ */ __name((instant) => {
146
- const parts = Object.fromEntries(formatter.formatToParts(instant).map((part) => [part.type, Number(part.value)]));
147
- return Date.UTC(parts.year ?? 0, (parts.month ?? 1) - 1, parts.day, parts.hour, parts.minute, parts.second) + (instant % 1e3 + 1e3) % 1e3;
148
- }, "shown");
149
- const found = /* @__PURE__ */ new Set();
150
- for (const probe of [wanted - 864e5, wanted, wanted + 864e5]) {
151
- const candidate = wanted - (shown(probe) - probe);
152
- if (shown(candidate) === wanted)
153
- found.add(candidate);
154
- }
155
- if (found.size !== 1)
156
- queryError("query.invalid-date", span, "this local time is skipped or repeated by daylight saving; add an offset");
157
- return [...found][0];
158
- }, "wallTime");
159
- var ZONED = /(?:Z|[+-]\d{2}:?\d{2})$/iu;
160
- var zonedMoment = /* @__PURE__ */ __name((value, zone, span, { end = false } = {}) => {
161
- if (/^\d{4}-\d{2}-\d{2}$/u.test(value))
162
- return dayBoundary(value, zone, end, span) - (end ? 1 : 0);
163
- if (!ZONED.test(value))
164
- return wallTime(value, zone, span);
165
- const time = Date.parse(value);
166
- if (!/^\d{4}-\d{2}-\d{2}T/u.test(value) || !Number.isFinite(time))
167
- queryError("query.invalid-date", span);
168
- calendar(value.slice(0, 10), span);
169
- return time;
170
- }, "zonedMoment");
171
- var AGO = /^(\d+)(m|h|d)$/u;
172
- var AGO_MS = { m: 6e4, h: 36e5, d: 864e5 };
173
- var dayOf = /* @__PURE__ */ __name((word, zone, now, span) => {
174
- const today = new Intl.DateTimeFormat("en-CA", {
175
- timeZone: zone,
176
- year: "numeric",
177
- month: "2-digit",
178
- day: "2-digit"
179
- }).format(now);
180
- if (word === "today")
181
- return today;
182
- const date = calendar(today, span);
183
- date.setUTCDate(date.getUTCDate() - 1);
184
- return date.toISOString().slice(0, 10);
185
- }, "dayOf");
186
- var dateEndpoint = /* @__PURE__ */ __name((value, zone, side, inclusive, span, now = Date.now()) => {
187
- if (value === "*")
188
- return { inclusive };
189
- const word = value.toLowerCase();
190
- if (word === "today" || word === "yesterday")
191
- return dateEndpoint(dayOf(word, zone, now, span), zone, side, inclusive, span);
192
- const [, amount, unit] = AGO.exec(word) ?? [];
193
- if (amount && unit)
194
- return { time: now - Number(amount) * (AGO_MS[unit] ?? 0), inclusive };
195
- if (/^\d{4}-\d{2}-\d{2}$/u.test(value))
196
- return {
197
- time: dayBoundary(value, zone, side === "lower" ? !inclusive : inclusive, span),
198
- inclusive: side === "lower"
199
- };
200
- if (!/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d{1,3})?(?:Z|[+-]\d{2}:\d{2})$/u.test(value))
201
- queryError("query.invalid-date", span, "use an ISO date, today, yesterday, 30m/2h/7d ago, or a quoted timestamp with offset");
202
- calendar(value.slice(0, 10), span);
203
- const time = Date.parse(value);
204
- if (!Number.isFinite(time) || Number(value.slice(11, 13)) > 23 || Number(value.slice(14, 16)) > 59 || Number(value.slice(17, 19)) > 59)
205
- queryError("query.invalid-date", span);
206
- return { time, inclusive };
207
- }, "dateEndpoint");
208
- var dateRange = /* @__PURE__ */ __name((lower, upper, lowerInclusive, upperInclusive, zone, span, now = Date.now()) => {
209
- const since = lower === upper && AGO.test(lower.toLowerCase());
210
- const lo = dateEndpoint(lower, zone, "lower", lowerInclusive, span, now);
211
- const hi = dateEndpoint(since ? "*" : upper, zone, "upper", upperInclusive, span, now);
212
- return {
213
- ...lo.time === void 0 ? {} : { lower: lo.time },
214
- ...hi.time === void 0 ? {} : { upper: hi.time },
215
- lower_inclusive: lo.inclusive,
216
- upper_inclusive: hi.inclusive
217
- };
218
- }, "dateRange");
219
-
220
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/fields.js
31
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/fields.js
221
32
  var FIELD_TYPES = ["kw", "txt", "enum", "num", "time", "bool", "ref"];
222
33
  var OPERATORS_BY_TYPE = {
223
34
  kw: ["term", "phrase", "wildcard"],
@@ -296,44 +107,51 @@ var queryFieldsOf = /* @__PURE__ */ __name((schema, annotations = {}) => {
296
107
  return [...own, ...relations, ...states];
297
108
  }, "queryFieldsOf");
298
109
 
299
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/help.js
300
- var shownOf = /* @__PURE__ */ __name((registry) => registry.backend === "native" ? registry.fields.filter((field) => field.native) : registry.fields, "shownOf");
301
- var leftOut = /* @__PURE__ */ __name((fields) => fields.filter((field) => field.negatable).map((field) => field.name), "leftOut");
302
- var has = /* @__PURE__ */ __name((fields, operator) => fields.some((field) => field.operators.includes(operator)), "has");
303
- var syntaxOf = /* @__PURE__ */ __name((shown, backend) => [
304
- "field:value",
305
- ...has(shown, "phrase") ? ['"a phrase"'] : [],
306
- ...has(shown, "wildcard") ? ["word*"] : [],
307
- ...backend === "native" ? ["terms joined by AND"] : ["AND OR NOT", "( )"],
308
- ...has(shown, "range") ? ["[a TO b] \xB7 > >= < <="] : []
309
- ].join(" \xB7 "), "syntaxOf");
310
- var kindOf = /* @__PURE__ */ __name((field) => field.values ? `${field.type}: ${field.values.join("|")}` : `${field.type}: ${field.operators.join(", ")}`, "kindOf");
311
- var fieldsHelp = /* @__PURE__ */ __name((registry, guide) => {
312
- const shown = shownOf(registry);
313
- const negatable = leftOut(shown);
314
- const rows = shown.map((field) => [field.name, kindOf(field), field.example]);
315
- const widths = [0, 1].map((at) => Math.max(...rows.map((row) => (row[at] ?? "").length)));
316
- return [
317
- "Fields:",
318
- ...rows.map(([name = "", kind = "", example = ""]) => ` ${name.padEnd(widths[0] ?? 0)} ${kind.padEnd(widths[1] ?? 0)} ${example}`.trimEnd()),
319
- ...registry.defaults && registry.defaults.length > 0 ? [`Defaults: ${registry.defaults.join(" ")} \u2014 name the field to change it`] : [],
320
- ...negatable.length > 0 ? [`Leave out: -${negatable[0]}:value or NOT ${negatable[0]}:value, for ${negatable.join(", ")}`] : [],
321
- `Syntax: ${syntaxOf(shown, registry.backend)}`,
322
- ...guide ? [`Guide: ${guide}`] : []
323
- ].join("\n");
324
- }, "fieldsHelp");
325
- var queryDescription = /* @__PURE__ */ __name((registry) => {
326
- const shown = shownOf(registry);
327
- if (shown.length === 0)
328
- return "field:value terms; this list filters by none yet, so any term is refused";
329
- const negatable = leftOut(shown);
330
- const terms = registry.backend === "native" ? `field:value terms joined by AND that narrow the list${negatable.length > 0 ? `; -field:value or NOT field:value leaves out what matches, for ${negatable.join(", ")} only` : ""}` : `field:value terms that narrow the list (Lucene: AND OR NOT, -field:value${has(shown, "range") ? ", [a TO b], > <" : ""})`;
331
- const fields = shown.map((field) => field.values ? `${field.name} (${field.values.join("|")})` : field.name);
332
- const defaults = registry.defaults?.length ? `; unless named: ${registry.defaults.join(" ")}` : "";
333
- return `${terms}; fields: ${fields.join(", ")}; e.g. ${shown[0]?.example ?? ""}${defaults}`;
334
- }, "queryDescription");
110
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/types.js
111
+ var QUERY_LIMITS = {
112
+ bytes: 8192,
113
+ depth: 32,
114
+ nodes: 256
115
+ };
116
+ var spanSchema = object({ start: number(), end: number() });
117
+ var predicateSchema = object({
118
+ kind: literal("predicate"),
119
+ field: string(),
120
+ operator: picklist(["term", "phrase", "wildcard", "regex", "range"]),
121
+ value: string(),
122
+ upper: optional(string()),
123
+ lower_inclusive: optional(boolean()),
124
+ upper_inclusive: optional(boolean()),
125
+ span: spanSchema,
126
+ implicit: optional(literal(true)),
127
+ slop: optional(pipe(number(), integer(), minValue(0)))
128
+ });
129
+ var queryNodeSchema = variant("kind", [
130
+ predicateSchema,
131
+ object({
132
+ kind: literal("boolean"),
133
+ clauses: array(object({ occur: picklist(["must", "should", "must_not"]), node: lazy(() => queryNodeSchema) })),
134
+ span: spanSchema
135
+ })
136
+ ]);
137
+ var queryAstSchema = object({
138
+ version: literal(1),
139
+ language: literal("lucene-v1"),
140
+ root: queryNodeSchema
141
+ });
142
+ function queryError(reason, span, alternative, context = {}, details = {}) {
143
+ throw new CliError("validation_error", `${context.command ?? "query"}: ${reason} at position ${span.start + 1}${alternative ? ` \u2014 ${alternative}` : ""}`, {
144
+ reason,
145
+ span,
146
+ ...alternative ? { alternative } : {},
147
+ ...context.guide ? { guide: context.guide } : {},
148
+ ...details
149
+ });
150
+ }
151
+ __name(queryError, "queryError");
152
+ var walkQuery = /* @__PURE__ */ __name((node) => node.kind === "predicate" ? [node] : node.clauses.flatMap(({ node: node2 }) => walkQuery(node2)), "walkQuery");
335
153
 
336
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/parser.js
154
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/parser.js
337
155
  var whitespace = /* @__PURE__ */ __name((c) => /[ \t\n\r\u3000]/u.test(c), "whitespace");
338
156
  var reserved = /* @__PURE__ */ new Set([
339
157
  "+",
@@ -642,7 +460,152 @@ var implicitTextTerms = /* @__PURE__ */ __name((text) => {
642
460
  return new Set(tokens.flatMap((token, index) => (token.kind === "term" || token.kind === "number") && ![":", "=", "<", ">", "<=", ">="].includes(tokens[index - 1]?.kind ?? "") && ![":", "=", "<", ">", "<=", ">="].includes(tokens[index + 1]?.kind ?? "") ? [token.span.start] : []));
643
461
  }, "implicitTextTerms");
644
462
 
645
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/validate.js
463
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/dates.js
464
+ var timezoneOf = /* @__PURE__ */ __name((given) => {
465
+ const zone = given ?? Intl.DateTimeFormat().resolvedOptions().timeZone ?? "UTC";
466
+ try {
467
+ new Intl.DateTimeFormat("en", { timeZone: zone }).format(0);
468
+ } catch {
469
+ queryError("query.invalid-timezone", { start: 0, end: 0 }, "use an IANA timezone such as Europe/Madrid");
470
+ }
471
+ return zone;
472
+ }, "timezoneOf");
473
+ var calendar = /* @__PURE__ */ __name((value, span) => {
474
+ if (!/^\d{4}-\d{2}-\d{2}$/u.test(value))
475
+ queryError("query.invalid-date", span, "use an ISO date or a quoted timestamp with offset");
476
+ const year = Number(value.slice(0, 4)), month = Number(value.slice(5, 7)), day = Number(value.slice(8, 10));
477
+ const date = /* @__PURE__ */ new Date(0);
478
+ date.setUTCFullYear(year, month - 1, day);
479
+ date.setUTCHours(0, 0, 0, 0);
480
+ if (date.getUTCFullYear() !== year || date.getUTCMonth() !== month - 1 || date.getUTCDate() !== day)
481
+ queryError("query.invalid-date", span);
482
+ return date;
483
+ }, "calendar");
484
+ var dayBoundary = /* @__PURE__ */ __name((value, zone, next, span) => {
485
+ const date = calendar(value, span);
486
+ if (next)
487
+ date.setUTCDate(date.getUTCDate() + 1);
488
+ const wanted = date.getUTCFullYear() * 1e4 + (date.getUTCMonth() + 1) * 100 + date.getUTCDate();
489
+ const formatter = new Intl.DateTimeFormat("en-CA", {
490
+ timeZone: zone,
491
+ year: "numeric",
492
+ month: "2-digit",
493
+ day: "2-digit",
494
+ era: "short"
495
+ });
496
+ const dayAt = /* @__PURE__ */ __name((time) => {
497
+ const parts = formatter.formatToParts(time);
498
+ const value2 = /* @__PURE__ */ __name((name) => Number(parts.find((p) => p.type === name)?.value), "value");
499
+ const year = parts.find((p) => p.type === "era")?.value === "BC" ? 1 - value2("year") : value2("year");
500
+ return year * 1e4 + value2("month") * 100 + value2("day");
501
+ }, "dayAt");
502
+ let lo = date.getTime() - 2 * 864e5, hi = date.getTime() + 2 * 864e5;
503
+ while (lo < hi) {
504
+ const mid = Math.floor((lo + hi) / 2);
505
+ if (dayAt(mid) < wanted)
506
+ lo = mid + 1;
507
+ else
508
+ hi = mid;
509
+ }
510
+ if (dayAt(lo) !== wanted)
511
+ queryError("query.invalid-date", span, "this calendar day does not exist in the selected timezone");
512
+ return lo;
513
+ }, "dayBoundary");
514
+ var WALL = /^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2})(?::(\d{2})(?:\.(\d{1,3}))?)?$/u;
515
+ var wallTime = /* @__PURE__ */ __name((value, zone, span) => {
516
+ const [, year, month, day, hour, minute, second = "0", fraction = "0"] = WALL.exec(value) ?? [];
517
+ if (year === void 0)
518
+ queryError("query.invalid-date", span, "use YYYY-MM-DDTHH:mm, with optional seconds");
519
+ const wanted = Date.UTC(Number(year), Number(month) - 1, Number(day), Number(hour), Number(minute), Number(second), Number(fraction.padEnd(3, "0")));
520
+ const check = new Date(wanted);
521
+ if (check.getUTCDate() !== Number(day) || check.getUTCHours() !== Number(hour) || check.getUTCMinutes() !== Number(minute) || check.getUTCSeconds() !== Number(second))
522
+ queryError("query.invalid-date", span);
523
+ const formatter = new Intl.DateTimeFormat("en-CA", {
524
+ timeZone: zone,
525
+ year: "numeric",
526
+ month: "2-digit",
527
+ day: "2-digit",
528
+ hour: "2-digit",
529
+ minute: "2-digit",
530
+ second: "2-digit",
531
+ hourCycle: "h23"
532
+ });
533
+ const shown = /* @__PURE__ */ __name((instant) => {
534
+ const parts = Object.fromEntries(formatter.formatToParts(instant).map((part) => [part.type, Number(part.value)]));
535
+ return Date.UTC(parts.year ?? 0, (parts.month ?? 1) - 1, parts.day, parts.hour, parts.minute, parts.second) + (instant % 1e3 + 1e3) % 1e3;
536
+ }, "shown");
537
+ const found = /* @__PURE__ */ new Set();
538
+ for (const probe of [wanted - 864e5, wanted, wanted + 864e5]) {
539
+ const candidate = wanted - (shown(probe) - probe);
540
+ if (shown(candidate) === wanted)
541
+ found.add(candidate);
542
+ }
543
+ if (found.size !== 1)
544
+ queryError("query.invalid-date", span, "this local time is skipped or repeated by daylight saving; add an offset");
545
+ return [...found][0];
546
+ }, "wallTime");
547
+ var ZONED = /(?:Z|[+-]\d{2}:?\d{2})$/iu;
548
+ var zonedMoment = /* @__PURE__ */ __name((value, zone, span, { end = false } = {}) => {
549
+ if (/^\d{4}-\d{2}-\d{2}$/u.test(value))
550
+ return dayBoundary(value, zone, end, span) - (end ? 1 : 0);
551
+ if (!ZONED.test(value))
552
+ return wallTime(value, zone, span);
553
+ const time = Date.parse(value);
554
+ if (!/^\d{4}-\d{2}-\d{2}T/u.test(value) || !Number.isFinite(time))
555
+ queryError("query.invalid-date", span);
556
+ calendar(value.slice(0, 10), span);
557
+ return time;
558
+ }, "zonedMoment");
559
+ var AGO = /^(\d+)(m|h|d)$/u;
560
+ var AGO_MS = { m: 6e4, h: 36e5, d: 864e5 };
561
+ var dayOf = /* @__PURE__ */ __name((word, zone, now, span) => {
562
+ const today = new Intl.DateTimeFormat("en-CA", {
563
+ timeZone: zone,
564
+ year: "numeric",
565
+ month: "2-digit",
566
+ day: "2-digit"
567
+ }).format(now);
568
+ if (word === "today")
569
+ return today;
570
+ const date = calendar(today, span);
571
+ date.setUTCDate(date.getUTCDate() - 1);
572
+ return date.toISOString().slice(0, 10);
573
+ }, "dayOf");
574
+ var dateEndpoint = /* @__PURE__ */ __name((value, zone, side, inclusive, span, now = Date.now()) => {
575
+ if (value === "*")
576
+ return { inclusive };
577
+ const word = value.toLowerCase();
578
+ if (word === "today" || word === "yesterday")
579
+ return dateEndpoint(dayOf(word, zone, now, span), zone, side, inclusive, span);
580
+ const [, amount, unit] = AGO.exec(word) ?? [];
581
+ if (amount && unit)
582
+ return { time: now - Number(amount) * (AGO_MS[unit] ?? 0), inclusive };
583
+ if (/^\d{4}-\d{2}-\d{2}$/u.test(value))
584
+ return {
585
+ time: dayBoundary(value, zone, side === "lower" ? !inclusive : inclusive, span),
586
+ inclusive: side === "lower"
587
+ };
588
+ if (!/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(?:\.\d{1,3})?(?:Z|[+-]\d{2}:\d{2})$/u.test(value))
589
+ queryError("query.invalid-date", span, "use an ISO date, today, yesterday, 30m/2h/7d ago, or a quoted timestamp with offset");
590
+ calendar(value.slice(0, 10), span);
591
+ const time = Date.parse(value);
592
+ if (!Number.isFinite(time) || Number(value.slice(11, 13)) > 23 || Number(value.slice(14, 16)) > 59 || Number(value.slice(17, 19)) > 59)
593
+ queryError("query.invalid-date", span);
594
+ return { time, inclusive };
595
+ }, "dateEndpoint");
596
+ var dateRange = /* @__PURE__ */ __name((lower, upper, lowerInclusive, upperInclusive, zone, span, now = Date.now()) => {
597
+ const since = lower === upper && AGO.test(lower.toLowerCase());
598
+ const lo = dateEndpoint(lower, zone, "lower", lowerInclusive, span, now);
599
+ const hi = dateEndpoint(since ? "*" : upper, zone, "upper", upperInclusive, span, now);
600
+ return {
601
+ ...lo.time === void 0 ? {} : { lower: lo.time },
602
+ ...hi.time === void 0 ? {} : { upper: hi.time },
603
+ lower_inclusive: lo.inclusive,
604
+ upper_inclusive: hi.inclusive
605
+ };
606
+ }, "dateRange");
607
+
608
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/validate.js
646
609
  var inContext = /* @__PURE__ */ __name((context, run) => {
647
610
  try {
648
611
  run();
@@ -717,7 +680,7 @@ var validateQuery = /* @__PURE__ */ __name((ast, registry, options = {}) => {
717
680
  }, "validateQuery");
718
681
  var fieldsNamed = /* @__PURE__ */ __name((ast) => new Set(walkQuery(ast.root).map((node) => node.field)), "fieldsNamed");
719
682
 
720
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/registry.js
683
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/registry.js
721
684
  var describeQuery = /* @__PURE__ */ __name((registry) => ({
722
685
  entity: registry.entity,
723
686
  backend: registry.backend,
@@ -788,7 +751,44 @@ var QUERY_REASONS = defineReasons([
788
751
  details: [...SPAN, ...details]
789
752
  })));
790
753
 
791
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/evaluate.js
754
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/help.js
755
+ var shownOf = /* @__PURE__ */ __name((registry) => registry.backend === "native" ? registry.fields.filter((field) => field.native) : registry.fields, "shownOf");
756
+ var leftOut = /* @__PURE__ */ __name((fields) => fields.filter((field) => field.negatable).map((field) => field.name), "leftOut");
757
+ var has = /* @__PURE__ */ __name((fields, operator) => fields.some((field) => field.operators.includes(operator)), "has");
758
+ var syntaxOf = /* @__PURE__ */ __name((shown, backend) => [
759
+ "field:value",
760
+ ...has(shown, "phrase") ? ['"a phrase"'] : [],
761
+ ...has(shown, "wildcard") ? ["word*"] : [],
762
+ ...backend === "native" ? ["terms joined by AND"] : ["AND OR NOT", "( )"],
763
+ ...has(shown, "range") ? ["[a TO b] \xB7 > >= < <="] : []
764
+ ].join(" \xB7 "), "syntaxOf");
765
+ var kindOf = /* @__PURE__ */ __name((field) => field.values ? `${field.type}: ${field.values.join("|")}` : `${field.type}: ${field.operators.join(", ")}`, "kindOf");
766
+ var fieldsHelp = /* @__PURE__ */ __name((registry, guide) => {
767
+ const shown = shownOf(registry);
768
+ const negatable = leftOut(shown);
769
+ const rows = shown.map((field) => [field.name, kindOf(field), field.example]);
770
+ const widths = [0, 1].map((at) => Math.max(...rows.map((row) => (row[at] ?? "").length)));
771
+ return [
772
+ "Fields:",
773
+ ...rows.map(([name = "", kind = "", example = ""]) => ` ${name.padEnd(widths[0] ?? 0)} ${kind.padEnd(widths[1] ?? 0)} ${example}`.trimEnd()),
774
+ ...registry.defaults && registry.defaults.length > 0 ? [`Defaults: ${registry.defaults.join(" ")} \u2014 name the field to change it`] : [],
775
+ ...negatable.length > 0 ? [`Leave out: -${negatable[0]}:value or NOT ${negatable[0]}:value, for ${negatable.join(", ")}`] : [],
776
+ `Syntax: ${syntaxOf(shown, registry.backend)}`,
777
+ ...guide ? [`Guide: ${guide}`] : []
778
+ ].join("\n");
779
+ }, "fieldsHelp");
780
+ var queryDescription = /* @__PURE__ */ __name((registry) => {
781
+ const shown = shownOf(registry);
782
+ if (shown.length === 0)
783
+ return "field:value terms; this list filters by none yet, so any term is refused";
784
+ const negatable = leftOut(shown);
785
+ const terms = registry.backend === "native" ? `field:value terms joined by AND that narrow the list${negatable.length > 0 ? `; -field:value or NOT field:value leaves out what matches, for ${negatable.join(", ")} only` : ""}` : `field:value terms that narrow the list (Lucene: AND OR NOT, -field:value${has(shown, "range") ? ", [a TO b], > <" : ""})`;
786
+ const fields = shown.map((field) => field.values ? `${field.name} (${field.values.join("|")})` : field.name);
787
+ const defaults = registry.defaults?.length ? `; unless named: ${registry.defaults.join(" ")}` : "";
788
+ return `${terms}; fields: ${fields.join(", ")}; e.g. ${shown[0]?.example ?? ""}${defaults}`;
789
+ }, "queryDescription");
790
+
791
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/evaluate.js
792
792
  var wordsOf = /* @__PURE__ */ __name((text) => text.toLowerCase().match(/[\p{L}\p{N}]+/gu) ?? [], "wordsOf");
793
793
  var pattern = /* @__PURE__ */ __name((value) => new RegExp(`^${[...value].map((char) => char === "*" ? ".*" : char === "?" ? "." : char.replace(/[.+^${}()|[\]\\]/, "\\$&")).join("")}$`, "iu"), "pattern");
794
794
  var present = /* @__PURE__ */ __name((value) => value !== void 0 && value !== null && value !== "", "present");
@@ -844,27 +844,27 @@ var matches = /* @__PURE__ */ __name((node, item, byName, options) => {
844
844
  var evaluate = /* @__PURE__ */ __name((ast, fields, item, options = {}) => matches(ast.root, item, new Map(fields.map((field) => [field.name, field])), options), "evaluate");
845
845
 
846
846
  export {
847
+ FIELD_TYPES,
848
+ OPERATORS_BY_TYPE,
849
+ QUERY_BACKENDS,
850
+ queryFieldsOf,
847
851
  QUERY_LIMITS,
848
852
  queryAstSchema,
849
853
  queryError,
850
854
  walkQuery,
855
+ parseLucene,
856
+ implicitTextTerms,
851
857
  timezoneOf,
852
858
  dayBoundary,
853
859
  wallTime,
854
860
  zonedMoment,
855
861
  dateRange,
856
- evaluate,
857
- FIELD_TYPES,
858
- OPERATORS_BY_TYPE,
859
- QUERY_BACKENDS,
860
- queryFieldsOf,
861
- fieldsHelp,
862
- queryDescription,
863
- parseLucene,
864
- implicitTextTerms,
865
862
  validateQuery,
866
863
  fieldsNamed,
867
864
  describeQuery,
868
865
  defineQuery,
869
- QUERY_REASONS
866
+ QUERY_REASONS,
867
+ evaluate,
868
+ fieldsHelp,
869
+ queryDescription
870
870
  };
@@ -4,7 +4,7 @@ import {
4
4
  __name
5
5
  } from "./chunk-ZVVMGPBJ.js";
6
6
 
7
- // node_modules/.pnpm/@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/sanitize.js
7
+ // node_modules/.pnpm/@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/sanitize.js
8
8
  var CONTROL = (
9
9
  // biome-ignore lint/suspicious/noControlCharactersInRegex: matching them is the whole point
10
10
  /[\u0000-\u0008\u000B-\u001F\u007F-\u009F\u200B\u200E\u200F\u202A-\u202E\u2066-\u2069\uFEFF\u{E0000}-\u{E007F}]/gu
@@ -0,0 +1,16 @@
1
+ import { createRequire as __bundleRequire } from "node:module";
2
+ const require = __bundleRequire(import.meta.url);
3
+ import {
4
+ __name
5
+ } from "./chunk-ZVVMGPBJ.js";
6
+
7
+ // 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/store/normalize.js
8
+ var NORMALIZER_VERSION = 1;
9
+ var fold = /* @__PURE__ */ __name((text) => text.normalize("NFKD").replace(new RegExp("\\p{M}+", "gu"), "").normalize("NFC").toLowerCase(), "fold");
10
+ var normalize = /* @__PURE__ */ __name((text) => fold(text).replace(new RegExp("\\p{Cc}", "gu"), " ").replace(/\s+/gu, " ").trim(), "normalize");
11
+
12
+ export {
13
+ NORMALIZER_VERSION,
14
+ fold,
15
+ normalize
16
+ };
@@ -7,12 +7,12 @@ import {
7
7
  import {
8
8
  singleLine,
9
9
  visibleControls
10
- } from "./chunk-OE7EIP5L.js";
10
+ } from "./chunk-6DCLZLGX.js";
11
11
  import {
12
12
  __name
13
13
  } from "./chunk-ZVVMGPBJ.js";
14
14
 
15
- // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_3bb6323e04e526bd9df39f840434b06b/node_modules/@wirecat/cli-core/dist/render/messages.js
15
+ // 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/render/messages.js
16
16
  import { styleText } from "node:util";
17
17
  var TIME_WIDTH = 8;
18
18
  var INDENT = " ".repeat(TIME_WIDTH + 2);