@wirecat/mail-cli 0.21.0 → 0.23.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 (121) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +5 -3
  3. package/dist/bin/mail.js +2 -2
  4. package/dist/bundle/{all-profiles-DTUWUCQQ.js → all-profiles-CI32WFEV.js} +9 -9
  5. package/dist/bundle/{anthropic-YJAEQSNT.js → anthropic-ICSOMJIN.js} +9 -7
  6. package/dist/bundle/{app-server-3ZXSTBA3.js → app-server-3F4ZB7DH.js} +46 -46
  7. package/dist/bundle/{bun-34VBM7C5.js → bun-7AHNFZMZ.js} +2 -2
  8. package/dist/bundle/{bun-sqlite-GCT7ROCK.js → bun-sqlite-UIWRS4HI.js} +4 -4
  9. package/dist/bundle/{chunk-NOVBK4SY.js → chunk-2BAO4T4Z.js} +12 -12
  10. package/dist/bundle/{chunk-UWL2IOII.js → chunk-3QVGB2CI.js} +2 -2
  11. package/dist/bundle/{chunk-HN43G27G.js → chunk-4PNIZUEC.js} +45 -27
  12. package/dist/bundle/{chunk-LF5XM4HE.js → chunk-4TKQIXND.js} +1 -1
  13. package/dist/bundle/{chunk-HSBGNVEL.js → chunk-4YTX5YAU.js} +334 -185
  14. package/dist/bundle/{chunk-LTXYJAJK.js → chunk-5AQ4S4TZ.js} +24 -63
  15. package/dist/bundle/{chunk-ODFHIXMA.js → chunk-5AS5N7V5.js} +1 -1
  16. package/dist/bundle/{chunk-WBAA2X3E.js → chunk-5J4WNTTM.js} +11 -11
  17. package/dist/bundle/{chunk-GAPQENMY.js → chunk-5QQOUYNA.js} +22 -4
  18. package/dist/bundle/{chunk-RPCKBXKN.js → chunk-5Y2WRUYP.js} +2 -2
  19. package/dist/bundle/{chunk-AF62BPIW.js → chunk-5Z7LZAVP.js} +5 -5
  20. package/dist/bundle/{chunk-SYEICLTR.js → chunk-6FSLEARF.js} +1 -1
  21. package/dist/bundle/{chunk-QTMVGOSF.js → chunk-7DFWXIY5.js} +1336 -796
  22. package/dist/bundle/{chunk-J4UZXBEV.js → chunk-7OVVX4F4.js} +1 -1
  23. package/dist/bundle/{chunk-QE72KTS7.js → chunk-7SIWMF77.js} +1 -1
  24. package/dist/bundle/{chunk-J2U6LUT5.js → chunk-7ZDH2XEY.js} +3 -3
  25. package/dist/bundle/{chunk-SFC46MP2.js → chunk-AFPETMXZ.js} +10 -10
  26. package/dist/bundle/{chunk-Z7N4MGOQ.js → chunk-AHRHP2H2.js} +5 -5
  27. package/dist/bundle/{chunk-HJ2CXDKJ.js → chunk-B4MWHI2V.js} +12 -12
  28. package/dist/bundle/{chunk-HRRSTIGP.js → chunk-B6GITVDX.js} +10 -6
  29. package/dist/bundle/{chunk-3DSYLE5N.js → chunk-BT7UUI6E.js} +2 -2
  30. package/dist/bundle/{chunk-72N26BQM.js → chunk-CNYQ3TTZ.js} +88 -88
  31. package/dist/bundle/{chunk-RFB27ACZ.js → chunk-D6WTKSRA.js} +2 -2
  32. package/dist/bundle/{chunk-4FWJNIPH.js → chunk-ELGEHZK2.js} +1 -1
  33. package/dist/bundle/{chunk-3HDQVTND.js → chunk-ETIUB2DF.js} +5 -5
  34. package/dist/bundle/{chunk-VDUGE6TH.js → chunk-FHCOGR7S.js} +2 -2
  35. package/dist/bundle/{chunk-VQZCIDSO.js → chunk-FIZWQTUC.js} +3 -3
  36. package/dist/bundle/{chunk-KMQAHDBM.js → chunk-FVKZ55I2.js} +860 -420
  37. package/dist/bundle/{chunk-BHNBWFT5.js → chunk-GOMJNH56.js} +44 -0
  38. package/dist/bundle/{chunk-FTI73RLC.js → chunk-HGV7DSSA.js} +2 -2
  39. package/dist/bundle/{chunk-RY7PBP4F.js → chunk-HN6PB7F5.js} +16 -16
  40. package/dist/bundle/{chunk-R3WPMQYZ.js → chunk-HRIYU2HJ.js} +245 -387
  41. package/dist/bundle/{chunk-ZKLXSVIO.js → chunk-I3YNNSGB.js} +1 -1
  42. package/dist/bundle/{chunk-MDDB7M7Z.js → chunk-IMIY7HQB.js} +1 -1
  43. package/dist/bundle/{chunk-2PPEDB67.js → chunk-JDKC7EXM.js} +30 -30
  44. package/dist/bundle/{chunk-T3DTYJTG.js → chunk-JO4BJYVE.js} +1 -1
  45. package/dist/bundle/{chunk-O3M2S62X.js → chunk-KJQZXCNK.js} +3 -3
  46. package/dist/bundle/{chunk-T4FVIPUJ.js → chunk-KNRONMVG.js} +2 -2
  47. package/dist/bundle/{chunk-BMV56JCL.js → chunk-LLYVBO3R.js} +1 -1
  48. package/dist/bundle/{chunk-TCCN5TON.js → chunk-NEDYKKJJ.js} +24 -2
  49. package/dist/bundle/{chunk-OKO2Q6H6.js → chunk-NKDYHAHP.js} +2 -2
  50. package/dist/bundle/{chunk-P2QJA7S5.js → chunk-OMW37FXK.js} +1 -1
  51. package/dist/bundle/{chunk-P6FT6YYT.js → chunk-R4RAWEMV.js} +16 -16
  52. package/dist/bundle/{chunk-V6OIIVH3.js → chunk-RIAZTS6C.js} +11 -11
  53. package/dist/bundle/{chunk-7XLOWYGD.js → chunk-S2U5BXWS.js} +19 -4
  54. package/dist/bundle/{chunk-566MEXK5.js → chunk-SCH3NC5X.js} +3 -3
  55. package/dist/bundle/{chunk-Z75WYAX6.js → chunk-SETCGPFG.js} +7 -7
  56. package/dist/bundle/{chunk-4WIEVQ2Q.js → chunk-SGMENSI6.js} +127 -9
  57. package/dist/bundle/{chunk-I2SDXWLR.js → chunk-TEL2OMS5.js} +97 -54
  58. package/dist/bundle/{chunk-SCIC2CJS.js → chunk-UA4BOLIY.js} +4 -4
  59. package/dist/bundle/{chunk-VINSQR4X.js → chunk-UTLJQG6Q.js} +7 -7
  60. package/dist/bundle/{chunk-ZZSHGCRC.js → chunk-WQRX4RQS.js} +4 -4
  61. package/dist/bundle/{chunk-MD64ITYO.js → chunk-XP5FBDIG.js} +1 -1
  62. package/dist/bundle/{chunk-RT6SLZBI.js → chunk-XV3M3NAN.js} +1 -1
  63. package/dist/bundle/{chunk-B74SOC4R.js → chunk-ZYHBMDNU.js} +8 -8
  64. package/dist/bundle/command-contract-UIRWJVEY.js +35 -0
  65. package/dist/bundle/{decode-BIOOL5E4.js → decode-BJXABRAN.js} +4 -4
  66. package/dist/bundle/{dispatch-R5OF2FVZ.js → dispatch-G4CYFWQ2.js} +1 -1
  67. package/dist/bundle/{dist-TJVIRLE5.js → dist-LLEA6R4V.js} +36 -22
  68. package/dist/bundle/{echarts-ECPGMKXO.js → echarts-YPTKBOZV.js} +2 -2
  69. package/dist/bundle/{embed-F7JFSLHN.js → embed-DMROTI5M.js} +5 -5
  70. package/dist/bundle/{embedder-U4G74HV3.js → embedder-DWMHXCHJ.js} +8 -8
  71. package/dist/bundle/{failure-WYKVF6RH.js → failure-FFPK2WYB.js} +1 -1
  72. package/dist/bundle/{first-run-JTYPUYQP.js → first-run-FQOEF2IO.js} +8 -8
  73. package/dist/bundle/first-screen-B6LF5464.js +33 -0
  74. package/dist/bundle/{instructions-WNCGZ7OJ.js → instructions-OGKMROLD.js} +1 -1
  75. package/dist/bundle/mail.js +5 -5
  76. package/dist/bundle/{node-UIRGGMGT.js → node-HIKYE546.js} +2 -2
  77. package/dist/bundle/{node-sqlite-4ZM7OPRF.js → node-sqlite-3GJAG7VO.js} +5 -5
  78. package/dist/bundle/{oauth-5RAJZPBW.js → oauth-H3DB6IHI.js} +6 -6
  79. package/dist/bundle/{open-7ORCHOAI.js → open-DJ2PRG74.js} +4 -4
  80. package/dist/bundle/{openai-XSJNXJA7.js → openai-MDBRYB55.js} +12 -12
  81. package/dist/bundle/{process-ZLO72UVZ.js → process-4LBD72JH.js} +1 -1
  82. package/dist/bundle/{program-LBLGFZWU.js → program-F6WK6RX4.js} +3713 -2439
  83. package/dist/bundle/{prompt-IDUPCUGM.js → prompt-UNPUG6SO.js} +6 -4
  84. package/dist/bundle/{recognize-OS3EZKIM.js → recognize-DMIO4PDB.js} +3 -3
  85. package/dist/bundle/{remote-PF4LZR65.js → remote-24HJA72D.js} +6 -6
  86. package/dist/bundle/{rerank-CQNZF3JI.js → rerank-PTNCHHIU.js} +6 -6
  87. package/dist/bundle/{serve-Y2DDLGBT.js → serve-T6JHM2YD.js} +8 -8
  88. package/dist/bundle/{server-TVRT7YEY.js → server-BWEYRUR3.js} +36 -36
  89. package/dist/bundle/server-VUQNR5ZD.js +65 -0
  90. package/dist/bundle/{sqlite-runtime-5343C3OE.js → sqlite-runtime-ZJ4EH5ZM.js} +5 -5
  91. package/dist/bundle/{state-4GBTMPIV.js → state-KSN4OFYW.js} +5 -5
  92. package/dist/bundle/{store-OLBLTQPT.js → store-GVBW2ZFK.js} +24 -16
  93. package/dist/bundle/{store-QA6QJ5BB.js → store-OIEZJEA7.js} +31 -14
  94. package/dist/bundle/store-maintenance-command-KJ54HLUQ.js +54 -0
  95. package/dist/commands/account-remove.d.ts +3 -0
  96. package/dist/commands/account-remove.d.ts.map +1 -0
  97. package/dist/commands/account-remove.js +65 -0
  98. package/dist/commands/account-remove.js.map +1 -0
  99. package/dist/commands/account.d.ts.map +1 -1
  100. package/dist/commands/account.js +3 -1
  101. package/dist/commands/account.js.map +1 -1
  102. package/dist/commands/context.d.ts +3 -1
  103. package/dist/commands/context.d.ts.map +1 -1
  104. package/dist/commands/context.js.map +1 -1
  105. package/dist/commands/session-start.d.ts.map +1 -1
  106. package/dist/commands/session-start.js +17 -4
  107. package/dist/commands/session-start.js.map +1 -1
  108. package/dist/mail/changes.d.ts +1 -0
  109. package/dist/mail/changes.d.ts.map +1 -1
  110. package/dist/mail/changes.js +1 -1
  111. package/dist/mail/changes.js.map +1 -1
  112. package/dist/providers.js +2 -2
  113. package/dist/providers.js.map +1 -1
  114. package/dist/version.d.ts +1 -1
  115. package/dist/version.js +1 -1
  116. package/package.json +2 -2
  117. package/dist/bundle/chunk-QPRXTLMD.js +0 -33
  118. package/dist/bundle/command-contract-Y4ZQAJEC.js +0 -35
  119. package/dist/bundle/first-screen-W6RWTAU7.js +0 -33
  120. package/dist/bundle/server-I3IALQMC.js +0 -65
  121. package/dist/bundle/store-maintenance-command-LB6CMGP4.js +0 -55
@@ -2,18 +2,21 @@ import { createRequire as __bundleRequire } from "node:module";
2
2
  const require = __bundleRequire(import.meta.url);
3
3
  import {
4
4
  renderMessages
5
- } from "./chunk-ZKLXSVIO.js";
5
+ } from "./chunk-I3YNNSGB.js";
6
6
  import {
7
7
  answerOf,
8
8
  messengerContext
9
- } from "./chunk-72N26BQM.js";
9
+ } from "./chunk-CNYQ3TTZ.js";
10
10
  import {
11
11
  FETCHING,
12
12
  RULES_VERSION,
13
13
  applyTaskRulesOnArrival,
14
14
  capability,
15
15
  chatEventAnswer,
16
+ embeddingKeys,
17
+ endpointKeyName,
16
18
  memberAnswer,
19
+ modelGateway,
17
20
  newSendId,
18
21
  onlineDeps,
19
22
  openRequestTask,
@@ -27,19 +30,17 @@ import {
27
30
  typedQuery,
28
31
  withQuery,
29
32
  withTimeLimit
30
- } from "./chunk-QTMVGOSF.js";
31
- import {
32
- checkedOptions,
33
- range
34
- } from "./chunk-QPRXTLMD.js";
33
+ } from "./chunk-7DFWXIY5.js";
35
34
  import {
36
- messagesFor,
37
- systemFor,
38
- validateImages
39
- } from "./chunk-TCCN5TON.js";
35
+ holdLock,
36
+ lockPath,
37
+ releaseLock,
38
+ servingProfiles,
39
+ takeLock
40
+ } from "./chunk-FIZWQTUC.js";
40
41
  import {
41
42
  readSecret
42
- } from "./chunk-GAPQENMY.js";
43
+ } from "./chunk-5QQOUYNA.js";
43
44
  import {
44
45
  Command,
45
46
  LOCAL_READ,
@@ -50,8 +51,6 @@ import {
50
51
  codeOf,
51
52
  currentRun,
52
53
  destroysNothing,
53
- endpoint,
54
- envName,
55
54
  environmentOf,
56
55
  itemOf,
57
56
  jsonlRecords,
@@ -67,27 +66,20 @@ import {
67
66
  snakeKeys,
68
67
  storeTable,
69
68
  withoutProviderRefs
70
- } from "./chunk-HSBGNVEL.js";
69
+ } from "./chunk-4YTX5YAU.js";
71
70
  import {
72
71
  levelFor
73
- } from "./chunk-HRRSTIGP.js";
74
- import {
75
- holdLock,
76
- lockPath,
77
- releaseLock,
78
- servingProfiles,
79
- takeLock
80
- } from "./chunk-VQZCIDSO.js";
72
+ } from "./chunk-B6GITVDX.js";
81
73
  import {
82
74
  holdersOf
83
- } from "./chunk-T3DTYJTG.js";
75
+ } from "./chunk-JO4BJYVE.js";
84
76
  import {
85
77
  QUICK_HEALTH_CHECKS,
86
78
  explainDamage,
87
79
  fts5Tables,
88
80
  invalidJson,
89
81
  storeHealth
90
- } from "./chunk-RY7PBP4F.js";
82
+ } from "./chunk-HN6PB7F5.js";
91
83
  import {
92
84
  CORPORA,
93
85
  MIGRATIONS,
@@ -121,45 +113,41 @@ import {
121
113
  storeClients,
122
114
  storeContents,
123
115
  vectorIndexCounts
124
- } from "./chunk-KMQAHDBM.js";
116
+ } from "./chunk-FVKZ55I2.js";
125
117
  import {
126
118
  formatLocator,
127
119
  parseLocator
128
- } from "./chunk-LTXYJAJK.js";
120
+ } from "./chunk-5AQ4S4TZ.js";
129
121
  import {
130
122
  readDamageMark,
131
123
  readHealthMark,
132
124
  recordDeepCheck
133
- } from "./chunk-HJ2CXDKJ.js";
125
+ } from "./chunk-B4MWHI2V.js";
134
126
  import {
135
127
  queryFieldsOf
136
- } from "./chunk-I2SDXWLR.js";
128
+ } from "./chunk-TEL2OMS5.js";
137
129
  import {
138
130
  failureKey,
139
131
  isStoreDamage
140
- } from "./chunk-SYEICLTR.js";
132
+ } from "./chunk-6FSLEARF.js";
141
133
  import {
142
134
  storePath
143
- } from "./chunk-RPCKBXKN.js";
135
+ } from "./chunk-5Y2WRUYP.js";
144
136
  import {
145
137
  openCache
146
- } from "./chunk-AF62BPIW.js";
138
+ } from "./chunk-5Z7LZAVP.js";
147
139
  import {
148
- Credentials,
149
- pathsAreOverridden,
150
140
  resolvePaths,
151
141
  writeSecurely
152
- } from "./chunk-BMV56JCL.js";
142
+ } from "./chunk-LLYVBO3R.js";
153
143
  import {
154
144
  array,
155
145
  boolean,
156
146
  check,
157
147
  forward,
158
148
  getDotPath,
159
- integer,
160
149
  minLength,
161
150
  nullable,
162
- number,
163
151
  object,
164
152
  optional,
165
153
  parse,
@@ -171,9 +159,8 @@ import {
171
159
  strictObject,
172
160
  string,
173
161
  transform,
174
- trim,
175
- union
176
- } from "./chunk-BHNBWFT5.js";
162
+ trim
163
+ } from "./chunk-GOMJNH56.js";
177
164
  import {
178
165
  CliError
179
166
  } from "./chunk-DALBYUPC.js";
@@ -354,14 +341,14 @@ var require_liquid_node = __commonJS({
354
341
  return value !== null && (type === "object" || type === "function");
355
342
  }
356
343
  __name(isObject, "isObject");
357
- function range2(start, stop, step = 1) {
344
+ function range(start, stop, step = 1) {
358
345
  const arr = [];
359
346
  for (let i = start; i < stop; i += step) {
360
347
  arr.push(i);
361
348
  }
362
349
  return arr;
363
350
  }
364
- __name(range2, "range");
351
+ __name(range, "range");
365
352
  function padStart(str, length, ch = " ") {
366
353
  return pad(str, length, ch, (str2, ch2) => ch2 + str2);
367
354
  }
@@ -555,7 +542,7 @@ var require_liquid_node = __commonJS({
555
542
  const lines = token.input.split("\n");
556
543
  const begin = Math.max(line - 2, 1);
557
544
  const end = Math.min(line + 3, lines.length);
558
- const context = range2(begin, end + 1).map((lineNumber) => {
545
+ const context = range(begin, end + 1).map((lineNumber) => {
559
546
  const rowIndicator = lineNumber === line ? ">> " : " ";
560
547
  const num = padStart(String(lineNumber), String(end).length);
561
548
  let text = `${rowIndicator}${num}| `;
@@ -1133,8 +1120,8 @@ var require_liquid_node = __commonJS({
1133
1120
  valid() {
1134
1121
  return !isNaN(this.getTime());
1135
1122
  }
1136
- format(options2) {
1137
- return this.DateTimeFormat && this.DateTimeFormat(this.locale, options2).format(this.displayDate);
1123
+ format(options) {
1124
+ return this.DateTimeFormat && this.DateTimeFormat(this.locale, options).format(this.displayDate);
1138
1125
  }
1139
1126
  /**
1140
1127
  * Create a Date object fixed to it's declared Timezone. Both
@@ -1218,11 +1205,11 @@ var require_liquid_node = __commonJS({
1218
1205
  static {
1219
1206
  __name(this, "TagToken");
1220
1207
  }
1221
- constructor(input, begin, end, options2, file2) {
1222
- const { trimTagLeft, trimTagRight, tagDelimiterLeft, tagDelimiterRight } = options2;
1208
+ constructor(input, begin, end, options, file2) {
1209
+ const { trimTagLeft, trimTagRight, tagDelimiterLeft, tagDelimiterRight } = options;
1223
1210
  const [valueBegin, valueEnd] = [begin + tagDelimiterLeft.length, end - tagDelimiterRight.length];
1224
1211
  super(exports.TokenKind.Tag, [valueBegin, valueEnd], input, begin, end, trimTagLeft, trimTagRight, file2);
1225
- this.tokenizer = new Tokenizer(input, options2.operators, file2, this.contentRange, options2.groupedExpressions);
1212
+ this.tokenizer = new Tokenizer(input, options.operators, file2, this.contentRange, options.groupedExpressions);
1226
1213
  this.name = this.tokenizer.readTagName();
1227
1214
  this.tokenizer.assert(this.name, `illegal tag syntax, tag name expected`);
1228
1215
  this.tokenizer.skipBlank();
@@ -1233,8 +1220,8 @@ var require_liquid_node = __commonJS({
1233
1220
  static {
1234
1221
  __name(this, "OutputToken");
1235
1222
  }
1236
- constructor(input, begin, end, options2, file2) {
1237
- const { trimOutputLeft, trimOutputRight, outputDelimiterLeft, outputDelimiterRight } = options2;
1223
+ constructor(input, begin, end, options, file2) {
1224
+ const { trimOutputLeft, trimOutputRight, outputDelimiterLeft, outputDelimiterRight } = options;
1238
1225
  const valueRange = [begin + outputDelimiterLeft.length, end - outputDelimiterRight.length];
1239
1226
  super(exports.TokenKind.Output, valueRange, input, begin, end, trimOutputLeft, trimOutputRight, file2);
1240
1227
  }
@@ -1453,9 +1440,9 @@ var require_liquid_node = __commonJS({
1453
1440
  static {
1454
1441
  __name(this, "LiquidTagToken");
1455
1442
  }
1456
- constructor(input, begin, end, options2, file2) {
1443
+ constructor(input, begin, end, options, file2) {
1457
1444
  super(exports.TokenKind.Tag, [begin, end], input, begin, end, false, false, file2);
1458
- this.tokenizer = new Tokenizer(input, options2.operators, file2, this.contentRange, options2.groupedExpressions);
1445
+ this.tokenizer = new Tokenizer(input, options.operators, file2, this.contentRange, options.groupedExpressions);
1459
1446
  this.name = this.tokenizer.readTagName();
1460
1447
  this.tokenizer.assert(this.name, "illegal liquid tag syntax");
1461
1448
  this.tokenizer.skipBlank();
@@ -1529,11 +1516,11 @@ var require_liquid_node = __commonJS({
1529
1516
  static {
1530
1517
  __name(this, "Filter");
1531
1518
  }
1532
- constructor(token, options2, liquid) {
1519
+ constructor(token, options, liquid) {
1533
1520
  this.token = token;
1534
1521
  this.name = token.name;
1535
- this.handler = isFunction(options2) ? options2 : isFunction(options2?.handler) ? options2.handler : identify;
1536
- this.raw = !isFunction(options2) && !!options2?.raw;
1522
+ this.handler = isFunction(options) ? options : isFunction(options?.handler) ? options.handler : identify;
1523
+ this.raw = !isFunction(options) && !!options?.raw;
1537
1524
  this.args = token.args;
1538
1525
  this.liquid = liquid;
1539
1526
  }
@@ -1636,7 +1623,7 @@ var require_liquid_node = __commonJS({
1636
1623
  const low = yield evalTokenValue(token.lhs, ctx);
1637
1624
  const high = yield evalTokenValue(token.rhs, ctx);
1638
1625
  ctx.memoryLimit.use(high - low + 1);
1639
- return range2(+low, +high + 1);
1626
+ return range(+low, +high + 1);
1640
1627
  }
1641
1628
  __name(evalRangeToken, "evalRangeToken");
1642
1629
  function* toPostfix(tokens) {
@@ -2117,41 +2104,41 @@ var require_liquid_node = __commonJS({
2117
2104
  parseLimit: Infinity,
2118
2105
  renderLimit: Infinity
2119
2106
  };
2120
- function normalize(options2) {
2121
- if (options2.hasOwnProperty("root")) {
2122
- if (!options2.hasOwnProperty("partials"))
2123
- options2.partials = options2.root;
2124
- if (!options2.hasOwnProperty("layouts"))
2125
- options2.layouts = options2.root;
2126
- }
2127
- if (options2.hasOwnProperty("cache")) {
2107
+ function normalize(options) {
2108
+ if (options.hasOwnProperty("root")) {
2109
+ if (!options.hasOwnProperty("partials"))
2110
+ options.partials = options.root;
2111
+ if (!options.hasOwnProperty("layouts"))
2112
+ options.layouts = options.root;
2113
+ }
2114
+ if (options.hasOwnProperty("cache")) {
2128
2115
  let cache;
2129
- if (typeof options2.cache === "number")
2130
- cache = options2.cache > 0 ? new LRU(options2.cache) : void 0;
2131
- else if (typeof options2.cache === "object")
2132
- cache = options2.cache;
2116
+ if (typeof options.cache === "number")
2117
+ cache = options.cache > 0 ? new LRU(options.cache) : void 0;
2118
+ else if (typeof options.cache === "object")
2119
+ cache = options.cache;
2133
2120
  else
2134
- cache = options2.cache ? new LRU(1024) : void 0;
2135
- options2.cache = cache;
2121
+ cache = options.cache ? new LRU(1024) : void 0;
2122
+ options.cache = cache;
2136
2123
  }
2137
- options2 = { ...defaultOptions, ...options2.jekyllInclude ? { dynamicPartials: false } : {}, ...options2 };
2138
- if ((!options2.fs.dirname || !options2.fs.sep) && options2.relativeReference) {
2124
+ options = { ...defaultOptions, ...options.jekyllInclude ? { dynamicPartials: false } : {}, ...options };
2125
+ if ((!options.fs.dirname || !options.fs.sep) && options.relativeReference) {
2139
2126
  console.warn("[LiquidJS] `fs.dirname` and `fs.sep` are required for relativeReference, set relativeReference to `false` to suppress this warning");
2140
- options2.relativeReference = false;
2127
+ options.relativeReference = false;
2141
2128
  }
2142
- options2.root = normalizeDirectoryList(options2.root);
2143
- options2.partials = normalizeDirectoryList(options2.partials);
2144
- options2.layouts = normalizeDirectoryList(options2.layouts);
2145
- options2.outputEscape = options2.outputEscape && getOutputEscapeFunction(options2.outputEscape);
2146
- if (!options2.locale) {
2147
- options2.locale = getDateTimeFormat()?.().resolvedOptions().locale ?? "en-US";
2129
+ options.root = normalizeDirectoryList(options.root);
2130
+ options.partials = normalizeDirectoryList(options.partials);
2131
+ options.layouts = normalizeDirectoryList(options.layouts);
2132
+ options.outputEscape = options.outputEscape && getOutputEscapeFunction(options.outputEscape);
2133
+ if (!options.locale) {
2134
+ options.locale = getDateTimeFormat()?.().resolvedOptions().locale ?? "en-US";
2148
2135
  }
2149
- if (options2.templates) {
2150
- options2.fs = new MapFS(options2.templates);
2151
- options2.relativeReference = true;
2152
- options2.root = options2.partials = options2.layouts = ".";
2136
+ if (options.templates) {
2137
+ options.fs = new MapFS(options.templates);
2138
+ options.relativeReference = true;
2139
+ options.root = options.partials = options.layouts = ".";
2153
2140
  }
2154
- return options2;
2141
+ return options;
2155
2142
  }
2156
2143
  __name(normalize, "normalize");
2157
2144
  function getOutputEscapeFunction(nameOrFunction) {
@@ -2172,14 +2159,14 @@ var require_liquid_node = __commonJS({
2172
2159
  return list;
2173
2160
  }
2174
2161
  __name(normalizeDirectoryList, "normalizeDirectoryList");
2175
- function whiteSpaceCtrl(tokens, options2) {
2162
+ function whiteSpaceCtrl(tokens, options) {
2176
2163
  let inRaw = false;
2177
2164
  for (let i = 0; i < tokens.length; i++) {
2178
2165
  const token = tokens[i];
2179
2166
  if (!isDelimitedToken(token))
2180
2167
  continue;
2181
2168
  if (!inRaw && token.trimLeft) {
2182
- trimLeft(tokens[i - 1], options2.greedy);
2169
+ trimLeft(tokens[i - 1], options.greedy);
2183
2170
  }
2184
2171
  if (isTagToken(token)) {
2185
2172
  if (token.name === "raw")
@@ -2188,7 +2175,7 @@ var require_liquid_node = __commonJS({
2188
2175
  inRaw = false;
2189
2176
  }
2190
2177
  if (!inRaw && token.trimRight) {
2191
- trimRight(tokens[i + 1], options2.greedy);
2178
+ trimRight(tokens[i + 1], options.greedy);
2192
2179
  }
2193
2180
  }
2194
2181
  }
@@ -2215,12 +2202,12 @@ var require_liquid_node = __commonJS({
2215
2202
  static {
2216
2203
  __name(this, "Tokenizer");
2217
2204
  }
2218
- constructor(input, operators = defaultOptions.operators, file2, range3, groupedExpressions = false) {
2205
+ constructor(input, operators = defaultOptions.operators, file2, range2, groupedExpressions = false) {
2219
2206
  this.input = input;
2220
2207
  this.file = file2;
2221
2208
  this.rawBeginAt = -1;
2222
- this.p = range3 ? range3[0] : 0;
2223
- this.N = range3 ? range3[1] : input.length;
2209
+ this.p = range2 ? range2[0] : 0;
2210
+ this.N = range2 ? range2[1] : input.length;
2224
2211
  this.opTrie = createTrie(operators);
2225
2212
  this.literalTrie = createTrie(literalValues);
2226
2213
  this.groupedExpressions = groupedExpressions;
@@ -2320,23 +2307,23 @@ var require_liquid_node = __commonJS({
2320
2307
  const value = this.readValue();
2321
2308
  return [key.getText(), value];
2322
2309
  }
2323
- readTopLevelTokens(options2 = defaultOptions) {
2310
+ readTopLevelTokens(options = defaultOptions) {
2324
2311
  const tokens = [];
2325
2312
  while (this.p < this.N) {
2326
- const token = this.readTopLevelToken(options2);
2313
+ const token = this.readTopLevelToken(options);
2327
2314
  tokens.push(token);
2328
2315
  }
2329
- whiteSpaceCtrl(tokens, options2);
2316
+ whiteSpaceCtrl(tokens, options);
2330
2317
  return tokens;
2331
2318
  }
2332
- readTopLevelToken(options2) {
2333
- const { tagDelimiterLeft, outputDelimiterLeft } = options2;
2319
+ readTopLevelToken(options) {
2320
+ const { tagDelimiterLeft, outputDelimiterLeft } = options;
2334
2321
  if (this.rawBeginAt > -1)
2335
- return this.readEndrawOrRawContent(options2);
2322
+ return this.readEndrawOrRawContent(options);
2336
2323
  if (this.match(tagDelimiterLeft))
2337
- return this.readTagToken(options2);
2324
+ return this.readTagToken(options);
2338
2325
  if (this.match(outputDelimiterLeft))
2339
- return this.readOutputToken(options2);
2326
+ return this.readOutputToken(options);
2340
2327
  return this.readHTMLToken([tagDelimiterLeft, outputDelimiterLeft]);
2341
2328
  }
2342
2329
  readHTMLToken(stopStrings) {
@@ -2348,13 +2335,13 @@ var require_liquid_node = __commonJS({
2348
2335
  }
2349
2336
  return new HTMLToken(this.input, begin, this.p, this.file);
2350
2337
  }
2351
- readTagToken(options2) {
2338
+ readTagToken(options) {
2352
2339
  const { file: file2, input } = this;
2353
2340
  const begin = this.p;
2354
- if (this.readToDelimiter(options2.tagDelimiterRight) === -1) {
2341
+ if (this.readToDelimiter(options.tagDelimiterRight) === -1) {
2355
2342
  throw this.error(`tag ${this.snapshot(begin)} not closed`, begin);
2356
2343
  }
2357
- const token = new TagToken(input, begin, this.p, options2, file2);
2344
+ const token = new TagToken(input, begin, this.p, options, file2);
2358
2345
  if (token.name === "raw")
2359
2346
  this.rawBeginAt = begin;
2360
2347
  return token;
@@ -2372,17 +2359,17 @@ var require_liquid_node = __commonJS({
2372
2359
  }
2373
2360
  return -1;
2374
2361
  }
2375
- readOutputToken(options2 = defaultOptions) {
2362
+ readOutputToken(options = defaultOptions) {
2376
2363
  const { file: file2, input } = this;
2377
- const { outputDelimiterRight } = options2;
2364
+ const { outputDelimiterRight } = options;
2378
2365
  const begin = this.p;
2379
2366
  if (this.readToDelimiter(outputDelimiterRight, true) === -1) {
2380
2367
  throw this.error(`output ${this.snapshot(begin)} not closed`, begin);
2381
2368
  }
2382
- return new OutputToken(input, begin, this.p, options2, file2);
2369
+ return new OutputToken(input, begin, this.p, options, file2);
2383
2370
  }
2384
- readEndrawOrRawContent(options2) {
2385
- const { tagDelimiterLeft, tagDelimiterRight } = options2;
2371
+ readEndrawOrRawContent(options) {
2372
+ const { tagDelimiterLeft, tagDelimiterRight } = options;
2386
2373
  const begin = this.p;
2387
2374
  let leftPos = this.readTo(tagDelimiterLeft) - tagDelimiterLeft.length;
2388
2375
  while (this.p < this.N) {
@@ -2395,7 +2382,7 @@ var require_liquid_node = __commonJS({
2395
2382
  const end = this.p;
2396
2383
  if (begin === leftPos) {
2397
2384
  this.rawBeginAt = -1;
2398
- return new TagToken(this.input, begin, end, options2, this.file);
2385
+ return new TagToken(this.input, begin, end, options, this.file);
2399
2386
  } else {
2400
2387
  this.p = leftPos;
2401
2388
  return new HTMLToken(this.input, begin, leftPos, this.file);
@@ -2408,22 +2395,22 @@ var require_liquid_node = __commonJS({
2408
2395
  }
2409
2396
  throw this.error(`raw ${this.snapshot(this.rawBeginAt)} not closed`, begin);
2410
2397
  }
2411
- readLiquidTagTokens(options2 = defaultOptions) {
2398
+ readLiquidTagTokens(options = defaultOptions) {
2412
2399
  const tokens = [];
2413
2400
  while (this.p < this.N) {
2414
- const token = this.readLiquidTagToken(options2);
2401
+ const token = this.readLiquidTagToken(options);
2415
2402
  token && tokens.push(token);
2416
2403
  }
2417
2404
  return tokens;
2418
2405
  }
2419
- readLiquidTagToken(options2) {
2406
+ readLiquidTagToken(options) {
2420
2407
  this.skipBlank();
2421
2408
  if (this.end())
2422
2409
  return;
2423
2410
  const begin = this.p;
2424
2411
  this.readToDelimiter("\n");
2425
2412
  const end = this.p;
2426
- return new LiquidTagToken(this.input, begin, end, options2, this.file);
2413
+ return new LiquidTagToken(this.input, begin, end, options, this.file);
2427
2414
  }
2428
2415
  error(msg, pos = this.p) {
2429
2416
  return new TokenizationError(msg, new IdentifierToken(this.input, pos, this.N, this.file));
@@ -2635,12 +2622,12 @@ var require_liquid_node = __commonJS({
2635
2622
  }
2636
2623
  return new QuotedToken(this.input, begin, this.p, this.file);
2637
2624
  }
2638
- *readFileNameTemplate(options2) {
2639
- const { outputDelimiterLeft } = options2;
2625
+ *readFileNameTemplate(options) {
2626
+ const { outputDelimiterLeft } = options;
2640
2627
  const htmlStopStrings = [",", " ", "\r", "\n", " ", outputDelimiterLeft];
2641
2628
  const htmlStopStringSet = new Set(htmlStopStrings);
2642
2629
  while (this.p < this.N && !htmlStopStringSet.has(this.peek())) {
2643
- yield this.match(outputDelimiterLeft) ? this.readOutputToken(options2) : this.readHTMLToken(htmlStopStrings);
2630
+ yield this.match(outputDelimiterLeft) ? this.readOutputToken(options) : this.readHTMLToken(htmlStopStrings);
2644
2631
  }
2645
2632
  }
2646
2633
  match(word) {
@@ -2715,7 +2702,7 @@ var require_liquid_node = __commonJS({
2715
2702
  this.token = token;
2716
2703
  }
2717
2704
  };
2718
- var Tag2 = class extends TemplateImpl {
2705
+ var Tag3 = class extends TemplateImpl {
2719
2706
  static {
2720
2707
  __name(this, "Tag");
2721
2708
  }
@@ -2745,17 +2732,17 @@ var require_liquid_node = __commonJS({
2745
2732
  return hash;
2746
2733
  }
2747
2734
  };
2748
- function createTagClass(options2) {
2749
- return class extends Tag2 {
2735
+ function createTagClass(options) {
2736
+ return class extends Tag3 {
2750
2737
  constructor(token, tokens, liquid) {
2751
2738
  super(token, tokens, liquid);
2752
- if (isFunction(options2.parse)) {
2753
- options2.parse.call(this, token, tokens);
2739
+ if (isFunction(options.parse)) {
2740
+ options.parse.call(this, token, tokens);
2754
2741
  }
2755
2742
  }
2756
2743
  *render(ctx, emitter) {
2757
2744
  const hash = yield new Hash(this.token.args, ctx.opts.keyValueSeparator).render(ctx);
2758
- return yield options2.render.call(this, ctx, emitter, hash);
2745
+ return yield options.render.call(this, ctx, emitter, hash);
2759
2746
  }
2760
2747
  };
2761
2748
  }
@@ -2972,13 +2959,13 @@ var require_liquid_node = __commonJS({
2972
2959
  };
2973
2960
  }
2974
2961
  __name(_analyze, "_analyze");
2975
- function analyze(template2, options2 = {}) {
2976
- const opts = { ...defaultStaticAnalysisOptions, ...options2 };
2962
+ function analyze(template2, options = {}) {
2963
+ const opts = { ...defaultStaticAnalysisOptions, ...options };
2977
2964
  return toPromise(_analyze(template2, opts.partials, false));
2978
2965
  }
2979
2966
  __name(analyze, "analyze");
2980
- function analyzeSync(template2, options2 = {}) {
2981
- const opts = { ...defaultStaticAnalysisOptions, ...options2 };
2967
+ function analyzeSync(template2, options = {}) {
2968
+ const opts = { ...defaultStaticAnalysisOptions, ...options };
2982
2969
  return toValueSync(_analyze(template2, opts.partials, true));
2983
2970
  }
2984
2971
  __name(analyzeSync, "analyzeSync");
@@ -3154,17 +3141,17 @@ var require_liquid_node = __commonJS({
3154
3141
  static {
3155
3142
  __name(this, "Loader");
3156
3143
  }
3157
- constructor(options2) {
3158
- this.options = options2;
3159
- if (options2.relativeReference) {
3160
- const sep = options2.fs.sep;
3144
+ constructor(options) {
3145
+ this.options = options;
3146
+ if (options.relativeReference) {
3147
+ const sep = options.fs.sep;
3161
3148
  assert(sep, "`fs.sep` is required for relative reference");
3162
3149
  const prefixes = ["." + sep, ".." + sep, "./", "../"];
3163
3150
  this.shouldLoadRelative = (referencedFile) => prefixes.some((prefix) => referencedFile.startsWith(prefix));
3164
3151
  } else {
3165
3152
  this.shouldLoadRelative = (_referencedFile) => false;
3166
3153
  }
3167
- const fs2 = options2.fs;
3154
+ const fs2 = options.fs;
3168
3155
  this.contains = toLiquidAsync(fs2.contains?.bind(fs2) || (async () => true), fs2.containsSync?.bind(fs2) || (() => true));
3169
3156
  this.exists = toLiquidAsync(fs2.exists?.bind(fs2) || (async () => false), fs2.existsSync?.bind(fs2));
3170
3157
  }
@@ -4314,7 +4301,7 @@ var require_liquid_node = __commonJS({
4314
4301
  ...cryptoFilters,
4315
4302
  ...misc
4316
4303
  };
4317
- var AssignTag = class extends Tag2 {
4304
+ var AssignTag = class extends Tag3 {
4318
4305
  static {
4319
4306
  __name(this, "AssignTag");
4320
4307
  }
@@ -4339,7 +4326,7 @@ var require_liquid_node = __commonJS({
4339
4326
  }
4340
4327
  };
4341
4328
  var MODIFIERS = ["offset", "limit", "reversed"];
4342
- var ForTag = class extends Tag2 {
4329
+ var ForTag = class extends Tag3 {
4343
4330
  static {
4344
4331
  __name(this, "ForTag");
4345
4332
  }
@@ -4432,7 +4419,7 @@ var require_liquid_node = __commonJS({
4432
4419
  return arr.slice(0, count3);
4433
4420
  }
4434
4421
  __name(limit2, "limit");
4435
- var CaptureTag = class extends Tag2 {
4422
+ var CaptureTag = class extends Tag3 {
4436
4423
  static {
4437
4424
  __name(this, "CaptureTag");
4438
4425
  }
@@ -4470,7 +4457,7 @@ var require_liquid_node = __commonJS({
4470
4457
  yield this.identifier;
4471
4458
  }
4472
4459
  };
4473
- var CaseTag = class extends Tag2 {
4460
+ var CaseTag = class extends Tag3 {
4474
4461
  static {
4475
4462
  __name(this, "CaseTag");
4476
4463
  }
@@ -4543,7 +4530,7 @@ var require_liquid_node = __commonJS({
4543
4530
  return templates;
4544
4531
  }
4545
4532
  };
4546
- var CommentTag = class extends Tag2 {
4533
+ var CommentTag = class extends Tag3 {
4547
4534
  static {
4548
4535
  __name(this, "CommentTag");
4549
4536
  }
@@ -4559,7 +4546,7 @@ var require_liquid_node = __commonJS({
4559
4546
  render() {
4560
4547
  }
4561
4548
  };
4562
- var RenderTag = class extends Tag2 {
4549
+ var RenderTag = class extends Tag3 {
4563
4550
  static {
4564
4551
  __name(this, "RenderTag");
4565
4552
  }
@@ -4706,7 +4693,7 @@ var require_liquid_node = __commonJS({
4706
4693
  return yield evalToken(file2, ctx);
4707
4694
  }
4708
4695
  __name(renderFilePath, "renderFilePath");
4709
- var IncludeTag = class extends Tag2 {
4696
+ var IncludeTag = class extends Tag3 {
4710
4697
  static {
4711
4698
  __name(this, "IncludeTag");
4712
4699
  }
@@ -4774,7 +4761,7 @@ var require_liquid_node = __commonJS({
4774
4761
  }
4775
4762
  }
4776
4763
  };
4777
- var DecrementTag = class extends Tag2 {
4764
+ var DecrementTag = class extends Tag3 {
4778
4765
  static {
4779
4766
  __name(this, "DecrementTag");
4780
4767
  }
@@ -4794,7 +4781,7 @@ var require_liquid_node = __commonJS({
4794
4781
  yield this.identifier;
4795
4782
  }
4796
4783
  };
4797
- var CycleTag = class extends Tag2 {
4784
+ var CycleTag = class extends Tag3 {
4798
4785
  static {
4799
4786
  __name(this, "CycleTag");
4800
4787
  }
@@ -4838,7 +4825,7 @@ var require_liquid_node = __commonJS({
4838
4825
  }
4839
4826
  }
4840
4827
  };
4841
- var IfTag = class extends Tag2 {
4828
+ var IfTag = class extends Tag3 {
4842
4829
  static {
4843
4830
  __name(this, "IfTag");
4844
4831
  }
@@ -4888,7 +4875,7 @@ var require_liquid_node = __commonJS({
4888
4875
  return this.branches.map((b) => b.value);
4889
4876
  }
4890
4877
  };
4891
- var IncrementTag = class extends Tag2 {
4878
+ var IncrementTag = class extends Tag3 {
4892
4879
  static {
4893
4880
  __name(this, "IncrementTag");
4894
4881
  }
@@ -4910,7 +4897,7 @@ var require_liquid_node = __commonJS({
4910
4897
  yield this.identifier;
4911
4898
  }
4912
4899
  };
4913
- var LayoutTag = class extends Tag2 {
4900
+ var LayoutTag = class extends Tag3 {
4914
4901
  static {
4915
4902
  __name(this, "LayoutTag");
4916
4903
  }
@@ -4965,7 +4952,7 @@ var require_liquid_node = __commonJS({
4965
4952
  }
4966
4953
  }
4967
4954
  };
4968
- var BlockTag = class extends Tag2 {
4955
+ var BlockTag = class extends Tag3 {
4969
4956
  static {
4970
4957
  __name(this, "BlockTag");
4971
4958
  }
@@ -5014,7 +5001,7 @@ var require_liquid_node = __commonJS({
5014
5001
  return ["block"];
5015
5002
  }
5016
5003
  };
5017
- var RawTag = class extends Tag2 {
5004
+ var RawTag = class extends Tag3 {
5018
5005
  static {
5019
5006
  __name(this, "RawTag");
5020
5007
  }
@@ -5058,7 +5045,7 @@ var require_liquid_node = __commonJS({
5058
5045
  return this.col() === this.cols;
5059
5046
  }
5060
5047
  };
5061
- var TablerowTag = class extends Tag2 {
5048
+ var TablerowTag = class extends Tag3 {
5062
5049
  static {
5063
5050
  __name(this, "TablerowTag");
5064
5051
  }
@@ -5122,7 +5109,7 @@ var require_liquid_node = __commonJS({
5122
5109
  return [this.variable, "tablerowloop"];
5123
5110
  }
5124
5111
  };
5125
- var UnlessTag = class extends Tag2 {
5112
+ var UnlessTag = class extends Tag3 {
5126
5113
  static {
5127
5114
  __name(this, "UnlessTag");
5128
5115
  }
@@ -5181,7 +5168,7 @@ var require_liquid_node = __commonJS({
5181
5168
  return this.branches.map((b) => b.value);
5182
5169
  }
5183
5170
  };
5184
- var BreakTag = class extends Tag2 {
5171
+ var BreakTag = class extends Tag3 {
5185
5172
  static {
5186
5173
  __name(this, "BreakTag");
5187
5174
  }
@@ -5189,7 +5176,7 @@ var require_liquid_node = __commonJS({
5189
5176
  ctx.breakCalled = true;
5190
5177
  }
5191
5178
  };
5192
- var ContinueTag = class extends Tag2 {
5179
+ var ContinueTag = class extends Tag3 {
5193
5180
  static {
5194
5181
  __name(this, "ContinueTag");
5195
5182
  }
@@ -5197,7 +5184,7 @@ var require_liquid_node = __commonJS({
5197
5184
  ctx.continueCalled = true;
5198
5185
  }
5199
5186
  };
5200
- var EchoTag = class extends Tag2 {
5187
+ var EchoTag = class extends Tag3 {
5201
5188
  static {
5202
5189
  __name(this, "EchoTag");
5203
5190
  }
@@ -5220,7 +5207,7 @@ var require_liquid_node = __commonJS({
5220
5207
  }
5221
5208
  }
5222
5209
  };
5223
- var LiquidTag = class extends Tag2 {
5210
+ var LiquidTag = class extends Tag3 {
5224
5211
  static {
5225
5212
  __name(this, "LiquidTag");
5226
5213
  }
@@ -5236,7 +5223,7 @@ var require_liquid_node = __commonJS({
5236
5223
  return this.templates;
5237
5224
  }
5238
5225
  };
5239
- var InlineCommentTag = class extends Tag2 {
5226
+ var InlineCommentTag = class extends Tag3 {
5240
5227
  static {
5241
5228
  __name(this, "InlineCommentTag");
5242
5229
  }
@@ -5379,76 +5366,76 @@ var require_liquid_node = __commonJS({
5379
5366
  self.renderFile(filePath, ctx).then((html) => callback(null, html), callback);
5380
5367
  };
5381
5368
  }
5382
- async analyze(template2, options2 = {}) {
5383
- return analyze(template2, options2);
5369
+ async analyze(template2, options = {}) {
5370
+ return analyze(template2, options);
5384
5371
  }
5385
- analyzeSync(template2, options2 = {}) {
5386
- return analyzeSync(template2, options2);
5372
+ analyzeSync(template2, options = {}) {
5373
+ return analyzeSync(template2, options);
5387
5374
  }
5388
- async parseAndAnalyze(html, filename, options2 = {}) {
5389
- return analyze(this.parse(html, filename), options2);
5375
+ async parseAndAnalyze(html, filename, options = {}) {
5376
+ return analyze(this.parse(html, filename), options);
5390
5377
  }
5391
- parseAndAnalyzeSync(html, filename, options2 = {}) {
5392
- return analyzeSync(this.parse(html, filename), options2);
5378
+ parseAndAnalyzeSync(html, filename, options = {}) {
5379
+ return analyzeSync(this.parse(html, filename), options);
5393
5380
  }
5394
5381
  /** Return an array of all variables without their properties. */
5395
- async variables(template2, options2 = {}) {
5396
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5382
+ async variables(template2, options = {}) {
5383
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5397
5384
  return Object.keys(analysis.variables);
5398
5385
  }
5399
5386
  /** Return an array of all variables without their properties. */
5400
- variablesSync(template2, options2 = {}) {
5401
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5387
+ variablesSync(template2, options = {}) {
5388
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5402
5389
  return Object.keys(analysis.variables);
5403
5390
  }
5404
5391
  /** Return an array of all variables including their properties/paths. */
5405
- async fullVariables(template2, options2 = {}) {
5406
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5392
+ async fullVariables(template2, options = {}) {
5393
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5407
5394
  return Array.from(new Set(Object.values(analysis.variables).flatMap((a) => a.map((v) => String(v)))));
5408
5395
  }
5409
5396
  /** Return an array of all variables including their properties/paths. */
5410
- fullVariablesSync(template2, options2 = {}) {
5411
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5397
+ fullVariablesSync(template2, options = {}) {
5398
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5412
5399
  return Array.from(new Set(Object.values(analysis.variables).flatMap((a) => a.map((v) => String(v)))));
5413
5400
  }
5414
5401
  /** Return an array of all variables, each as an array of properties/segments. */
5415
- async variableSegments(template2, options2 = {}) {
5416
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5402
+ async variableSegments(template2, options = {}) {
5403
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5417
5404
  return Array.from(strictUniq(Object.values(analysis.variables).flatMap((a) => a.map((v) => v.toArray()))));
5418
5405
  }
5419
5406
  /** Return an array of all variables, each as an array of properties/segments. */
5420
- variableSegmentsSync(template2, options2 = {}) {
5421
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5407
+ variableSegmentsSync(template2, options = {}) {
5408
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5422
5409
  return Array.from(strictUniq(Object.values(analysis.variables).flatMap((a) => a.map((v) => v.toArray()))));
5423
5410
  }
5424
5411
  /** Return an array of all expected context variables without their properties. */
5425
- async globalVariables(template2, options2 = {}) {
5426
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5412
+ async globalVariables(template2, options = {}) {
5413
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5427
5414
  return Object.keys(analysis.globals);
5428
5415
  }
5429
5416
  /** Return an array of all expected context variables without their properties. */
5430
- globalVariablesSync(template2, options2 = {}) {
5431
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5417
+ globalVariablesSync(template2, options = {}) {
5418
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5432
5419
  return Object.keys(analysis.globals);
5433
5420
  }
5434
5421
  /** Return an array of all expected context variables including their properties/paths. */
5435
- async globalFullVariables(template2, options2 = {}) {
5436
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5422
+ async globalFullVariables(template2, options = {}) {
5423
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5437
5424
  return Array.from(new Set(Object.values(analysis.globals).flatMap((a) => a.map((v) => String(v)))));
5438
5425
  }
5439
5426
  /** Return an array of all expected context variables including their properties/paths. */
5440
- globalFullVariablesSync(template2, options2 = {}) {
5441
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5427
+ globalFullVariablesSync(template2, options = {}) {
5428
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5442
5429
  return Array.from(new Set(Object.values(analysis.globals).flatMap((a) => a.map((v) => String(v)))));
5443
5430
  }
5444
5431
  /** Return an array of all expected context variables, each as an array of properties/segments. */
5445
- async globalVariableSegments(template2, options2 = {}) {
5446
- const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options2);
5432
+ async globalVariableSegments(template2, options = {}) {
5433
+ const analysis = await analyze(isString(template2) ? this.parse(template2) : template2, options);
5447
5434
  return Array.from(strictUniq(Object.values(analysis.globals).flatMap((a) => a.map((v) => v.toArray()))));
5448
5435
  }
5449
5436
  /** Return an array of all expected context variables, each as an array of properties/segments. */
5450
- globalVariableSegmentsSync(template2, options2 = {}) {
5451
- const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options2);
5437
+ globalVariableSegmentsSync(template2, options = {}) {
5438
+ const analysis = analyzeSync(isString(template2) ? this.parse(template2) : template2, options);
5452
5439
  return Array.from(strictUniq(Object.values(analysis.globals).flatMap((a) => a.map((v) => v.toArray()))));
5453
5440
  }
5454
5441
  };
@@ -5486,7 +5473,7 @@ var require_liquid_node = __commonJS({
5486
5473
  exports.RenderError = RenderError;
5487
5474
  exports.RenderTag = RenderTag;
5488
5475
  exports.TablerowTag = TablerowTag;
5489
- exports.Tag = Tag2;
5476
+ exports.Tag = Tag3;
5490
5477
  exports.TagToken = TagToken;
5491
5478
  exports.Token = Token;
5492
5479
  exports.TokenizationError = TokenizationError;
@@ -5516,11 +5503,11 @@ var require_liquid_node = __commonJS({
5516
5503
  }
5517
5504
  });
5518
5505
 
5519
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
5506
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
5520
5507
  import { chmodSync, constants, copyFileSync, existsSync as existsSync9, mkdirSync, realpathSync as realpathSync2, renameSync as renameSync3, rmSync as rmSync3, statfsSync as statfsSync2, statSync as statSync4, writeFileSync as writeFileSync2 } from "node:fs";
5521
5508
  import { dirname as dirname2, resolve } from "node:path";
5522
5509
 
5523
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/sealed.js
5510
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/sealed.js
5524
5511
  import { createCipheriv, createDecipheriv, createHash, randomBytes, scrypt, timingSafeEqual } from "node:crypto";
5525
5512
  import { closeSync, createReadStream, createWriteStream, existsSync, openSync, readSync, renameSync, rmSync, statSync } from "node:fs";
5526
5513
  import { Transform } from "node:stream";
@@ -5627,7 +5614,7 @@ var unsealFile = /* @__PURE__ */ __name(async (from, to, password) => {
5627
5614
  renameSync(pending, to);
5628
5615
  }, "unsealFile");
5629
5616
 
5630
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/store/compatibility.js
5617
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/store/compatibility.js
5631
5618
  var SPEAKS = MIGRATIONS.at(-1)?.version ?? 0;
5632
5619
  var fileSchemaOf = /* @__PURE__ */ __name((database) => {
5633
5620
  const tracked = database.prepare("SELECT 1 FROM sqlite_master WHERE name = 'schema_migrations'").get();
@@ -5651,7 +5638,7 @@ var compatibilityOf = /* @__PURE__ */ __name((file2, migrations = MIGRATIONS) =>
5651
5638
  };
5652
5639
  }, "compatibilityOf");
5653
5640
 
5654
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/store/repair.js
5641
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/store/repair.js
5655
5642
  import { createHash as createHash2 } from "node:crypto";
5656
5643
  var COPY_MARK = "__repair_";
5657
5644
  var COPY_NAME = /__repair_[0-9a-f]{8}(_\d+)?$/;
@@ -5905,13 +5892,13 @@ var deleteCopy = /* @__PURE__ */ __name((database, name) => {
5905
5892
  return found;
5906
5893
  }, "deleteCopy");
5907
5894
 
5908
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/store-info.js
5895
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/store-info.js
5909
5896
  import { existsSync as existsSync4, statSync as statSync3 } from "node:fs";
5910
5897
 
5911
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
5898
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
5912
5899
  import { existsSync as existsSync3 } from "node:fs";
5913
5900
 
5914
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/store/recover.js
5901
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/store/recover.js
5915
5902
  import { execFileSync, spawn } from "node:child_process";
5916
5903
  import { existsSync as existsSync2, readFileSync, realpathSync, renameSync as renameSync2, rmSync as rmSync2, statfsSync, statSync as statSync2, writeFileSync } from "node:fs";
5917
5904
  import { basename, dirname, join } from "node:path";
@@ -6243,7 +6230,7 @@ var recoverLocked = /* @__PURE__ */ __name(async ({ path, command, version, sqli
6243
6230
  let kept;
6244
6231
  let dangling;
6245
6232
  let json;
6246
- let fetch2;
6233
+ let fetch;
6247
6234
  let schema;
6248
6235
  try {
6249
6236
  kept = tableRows(opened.database);
@@ -6253,7 +6240,7 @@ var recoverLocked = /* @__PURE__ */ __name(async ({ path, command, version, sqli
6253
6240
  rebuilt = rebuildDerived(opened.database, { now, note });
6254
6241
  note("looking for rows that point at rows that were lost");
6255
6242
  dangling = danglingRows(opened.database);
6256
- fetch2 = mailToFetch(opened.database);
6243
+ fetch = mailToFetch(opened.database);
6257
6244
  schema = fileSchemaOf(opened.database).version;
6258
6245
  opened.database.exec("PRAGMA wal_checkpoint(TRUNCATE)");
6259
6246
  } catch (error) {
@@ -6292,7 +6279,7 @@ var recoverLocked = /* @__PURE__ */ __name(async ({ path, command, version, sqli
6292
6279
  lost,
6293
6280
  dangling,
6294
6281
  invalidJson: json,
6295
- mailToFetch: fetch2,
6282
+ mailToFetch: fetch,
6296
6283
  rebuilt,
6297
6284
  copyErrors,
6298
6285
  health,
@@ -6308,7 +6295,7 @@ var recoverLocked = /* @__PURE__ */ __name(async ({ path, command, version, sqli
6308
6295
  }
6309
6296
  }, "recoverLocked");
6310
6297
 
6311
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
6298
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/store-recover.js
6312
6299
  var COUNTED = [
6313
6300
  "accounts",
6314
6301
  "chats",
@@ -6441,7 +6428,7 @@ var storeRecoverCommand = /* @__PURE__ */ __name(({ command, version }) => {
6441
6428
  return recover;
6442
6429
  }, "storeRecoverCommand");
6443
6430
 
6444
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/store-info.js
6431
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/store-info.js
6445
6432
  var pendingIfKnown = /* @__PURE__ */ __name((database) => database.prepare("SELECT 1 FROM pragma_table_info('messages') WHERE name = 'normalized_text'").get() ? pendingNormalization(database) : null, "pendingIfKnown");
6446
6433
  var bytesOf = /* @__PURE__ */ __name((path) => existsSync4(path) ? statSync3(path).size : 0, "bytesOf");
6447
6434
  var messageOf = /* @__PURE__ */ __name((error) => error instanceof Error ? error.message : String(error), "messageOf");
@@ -6487,7 +6474,7 @@ var storeInfoCommand = /* @__PURE__ */ __name(() => annotate(new Command("info")
6487
6474
  renderAnswer(this, outputFor(this), itemOf(answer));
6488
6475
  }), "storeInfoCommand");
6489
6476
 
6490
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/password.js
6477
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/password.js
6491
6478
  var ENCRYPT_OPTION = [
6492
6479
  "--encrypt",
6493
6480
  "compress and encrypt with a password, typed at a hidden prompt or piped on stdin; it is never kept \u2014 lose it and the file cannot be opened"
@@ -6506,7 +6493,7 @@ var passwordOf = /* @__PURE__ */ __name(async (command, { twice }) => {
6506
6493
  return password;
6507
6494
  }, "passwordOf");
6508
6495
 
6509
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/rules.js
6496
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/rules.js
6510
6497
  import { existsSync as existsSync5, readFileSync as readFileSync2 } from "node:fs";
6511
6498
  import { join as join2 } from "node:path";
6512
6499
  var REPLY_ACTIONS = ["reply", "task"];
@@ -6677,7 +6664,7 @@ var problem = /* @__PURE__ */ __name((issue) => {
6677
6664
  }, "problem");
6678
6665
  var broken = /* @__PURE__ */ __name((path, why) => new CliError("configuration_error", `the reply rules ${path} cannot be read (${why}) \u2014 fix the file`), "broken");
6679
6666
 
6680
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/state.js
6667
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/state.js
6681
6668
  import { existsSync as existsSync6, readFileSync as readFileSync3 } from "node:fs";
6682
6669
  import { join as join3 } from "node:path";
6683
6670
  var ANSWERED_KEPT = 1e3;
@@ -6730,7 +6717,7 @@ var recordReply = /* @__PURE__ */ __name((state, rule2, message, now) => {
6730
6717
  }, "recordReply");
6731
6718
  var broken2 = /* @__PURE__ */ __name((path, why) => new CliError("configuration_error", `the reply state ${path} cannot be read (${why}) \u2014 fix or move the file`), "broken");
6732
6719
 
6733
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/decide.js
6720
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/decide.js
6734
6721
  var skip = /* @__PURE__ */ __name((why) => ({ skip: why }), "skip");
6735
6722
  var decide = /* @__PURE__ */ __name((rule2, incoming, state, now) => {
6736
6723
  const { message, chat, owner, sender } = incoming;
@@ -6836,8 +6823,37 @@ var filled = /* @__PURE__ */ __name((template2, senderName) => {
6836
6823
  return template2.replaceAll("{firstName}", name.split(/\s+/)[0] ?? name).replaceAll("{name}", name);
6837
6824
  }, "filled");
6838
6825
 
6839
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/template.js
6826
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/template.js
6827
+ var import_liquidjs2 = __toESM(require_liquid_node(), 1);
6828
+
6829
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/render/liquid.js
6840
6830
  var import_liquidjs = __toESM(require_liquid_node(), 1);
6831
+ var safeLiquid = /* @__PURE__ */ __name((limits) => {
6832
+ const engine = new import_liquidjs.Liquid({
6833
+ ownPropertyOnly: true,
6834
+ strictVariables: true,
6835
+ strictFilters: true,
6836
+ lenientIf: false,
6837
+ parseLimit: limits.parse,
6838
+ renderLimit: limits.milliseconds,
6839
+ memoryLimit: limits.memory,
6840
+ preserveTimezones: true
6841
+ });
6842
+ for (const name of ["include", "render", "layout"]) {
6843
+ engine.registerTag(name, class extends import_liquidjs.Tag {
6844
+ constructor(token, tokens, liquid) {
6845
+ super(token, tokens, liquid);
6846
+ throw new Error("templates cannot read files");
6847
+ }
6848
+ render() {
6849
+ return "";
6850
+ }
6851
+ });
6852
+ }
6853
+ return engine;
6854
+ }, "safeLiquid");
6855
+
6856
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/template.js
6841
6857
  var TEMPLATE_LIMITS = {
6842
6858
  parse: 32768,
6843
6859
  renders: 2e3,
@@ -6891,28 +6907,8 @@ var renderReplyTemplate = /* @__PURE__ */ __name(async (reply, input) => {
6891
6907
  hourCycle: "h23"
6892
6908
  }).formatToParts(input.now).map(({ type, value }) => [type, value]));
6893
6909
  const localTime = `${parts.year}-${parts.month}-${parts.day}T${parts.hour}:${parts.minute}:${parts.second}${parts.timeZoneName?.replace("GMT", "") || "+00:00"}`;
6894
- const engine = new import_liquidjs.Liquid({
6895
- ownPropertyOnly: true,
6896
- strictVariables: true,
6897
- strictFilters: true,
6898
- lenientIf: false,
6899
- parseLimit: limits.parse,
6900
- renderLimit: limits.milliseconds,
6901
- memoryLimit: limits.memory,
6902
- preserveTimezones: true
6903
- });
6904
- for (const name2 of ["include", "render", "layout"]) {
6905
- engine.registerTag(name2, class extends import_liquidjs.Tag {
6906
- constructor(token, tokens, liquid) {
6907
- super(token, tokens, liquid);
6908
- throw new Error("reply templates cannot read files");
6909
- }
6910
- render() {
6911
- return "";
6912
- }
6913
- });
6914
- }
6915
- engine.registerTag("ai", class extends import_liquidjs.Tag {
6910
+ const engine = safeLiquid({ parse: limits.parse, memory: limits.memory, milliseconds: limits.milliseconds });
6911
+ engine.registerTag("ai", class extends import_liquidjs2.Tag {
6916
6912
  body = [];
6917
6913
  fallback = null;
6918
6914
  constructor(token, tokens, liquid, parser) {
@@ -6973,7 +6969,7 @@ var renderReplyTemplate = /* @__PURE__ */ __name(async (reply, input) => {
6973
6969
  });
6974
6970
  const templates = engine.parse(source);
6975
6971
  const name = input.senderName?.trim() ?? "";
6976
- const context = new import_liquidjs.Context({
6972
+ const context = new import_liquidjs2.Context({
6977
6973
  sender: { firstName: name.split(/\s+/)[0] ?? "", name },
6978
6974
  chat: { title: input.chat.title ?? "", kind: input.chat.kind },
6979
6975
  now: localTime
@@ -6996,7 +6992,7 @@ var renderReplyTemplate = /* @__PURE__ */ __name(async (reply, input) => {
6996
6992
  }
6997
6993
  }, "renderReplyTemplate");
6998
6994
 
6999
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/dry-run.js
6995
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/dry-run.js
7000
6996
  var DRY_RUN_DAYS = 7;
7001
6997
  var PAGE = 500;
7002
6998
  var dryRun = /* @__PURE__ */ __name(async (store, account, rules, { since, until = Date.now(), only, audience, render }) => {
@@ -7110,143 +7106,7 @@ var storedSince = /* @__PURE__ */ __name(async (store, account, chat, since) =>
7110
7106
  }
7111
7107
  }, "storedSince");
7112
7108
 
7113
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/embeddings/keys.js
7114
- var endpointKeyName = /* @__PURE__ */ __name((baseUrl) => {
7115
- const host = new URL(baseUrl).host;
7116
- return ["openai", "anthropic"].includes(host) ? `endpoint:${host}` : host;
7117
- }, "endpointKeyName");
7118
- var embeddingKeys = /* @__PURE__ */ __name((app, env = process.env, keyring) => {
7119
- const where = { appName: app.appName, prefix: app.envPrefix, env };
7120
- const credentials = /* @__PURE__ */ __name((provider) => new Credentials({
7121
- configDir: resolvePaths(where).config,
7122
- service: app.appName,
7123
- ...["openai", "anthropic"].includes(provider) ? { envVar: envName(app, `${provider.toUpperCase()}_API_KEY`) } : {},
7124
- isolated: pathsAreOverridden(where),
7125
- env,
7126
- ...keyring ? { keyring } : {},
7127
- warn: /* @__PURE__ */ __name((message) => process.stderr.write(`${message}
7128
- `), "warn")
7129
- }), "credentials");
7130
- const account = /* @__PURE__ */ __name((provider) => `embeddings:${provider}`, "account");
7131
- return {
7132
- read: /* @__PURE__ */ __name((provider) => {
7133
- const stored = credentials(provider).read(account(provider));
7134
- if (stored)
7135
- return { key: stored.secret, source: stored.source };
7136
- const shared = ["openai", "anthropic"].includes(provider) ? env[`${provider.toUpperCase()}_API_KEY`]?.trim() : void 0;
7137
- return shared ? { key: shared, source: "env" } : void 0;
7138
- }, "read"),
7139
- write: /* @__PURE__ */ __name((provider, key) => credentials(provider).write(account(provider), key, { signIn: true }), "write"),
7140
- remove: /* @__PURE__ */ __name((provider) => credentials(provider).remove(account(provider)), "remove")
7141
- };
7142
- }, "embeddingKeys");
7143
-
7144
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/models/openai.js
7145
- var options = strictObject({
7146
- temperature: range(0, 2),
7147
- top_p: range(0, 1),
7148
- presence_penalty: range(-2, 2),
7149
- frequency_penalty: range(-2, 2),
7150
- seed: optional(pipe(number(), integer())),
7151
- stop: optional(union([string(), array(string())])),
7152
- response_format: optional(strictObject({ type: picklist(["text", "json_object"]) }))
7153
- });
7154
- var openai = {
7155
- images: true,
7156
- baseUrl: "https://api.openai.com/v1",
7157
- validate: /* @__PURE__ */ __name((given) => checkedOptions("openai", options, given), "validate"),
7158
- complete: /* @__PURE__ */ __name((target, request, checked, apiKey, fetcher) => withTimeLimit(12e4, async (deadline) => {
7159
- const response = await fetcher(`${target.baseUrl.replace(/\/+$/, "")}/chat/completions`, {
7160
- method: "POST",
7161
- headers: { "Content-Type": "application/json", ...apiKey ? { Authorization: `Bearer ${apiKey}` } : {} },
7162
- body: JSON.stringify({
7163
- ...checked,
7164
- model: target.model,
7165
- messages: [
7166
- { role: "system", content: systemFor(request) },
7167
- ...messagesFor(request),
7168
- ...request.images === void 0 ? [] : [
7169
- {
7170
- role: "user",
7171
- content: request.images.map((image) => ({
7172
- type: "image_url",
7173
- image_url: { url: `data:${image.mimeType};base64,${image.data}`, detail: "high" }
7174
- }))
7175
- }
7176
- ]
7177
- ],
7178
- ...new URL(target.baseUrl).hostname === "api.openai.com" ? { max_completion_tokens: request.maxTokens } : { max_tokens: request.maxTokens }
7179
- }),
7180
- signal: deadline,
7181
- redirect: "error"
7182
- });
7183
- if (!response.ok)
7184
- throw new Error("provider rejected request");
7185
- const body = await response.json();
7186
- const choice = body.choices?.[0];
7187
- if (choice?.finish_reason !== "stop" || typeof choice.message?.content !== "string" || !Number.isInteger(body.usage?.total_tokens) || (body.usage?.total_tokens ?? 0) < 1)
7188
- throw new Error("incomplete response");
7189
- return { text: choice.message.content, tokens: body.usage?.total_tokens };
7190
- }), "complete")
7191
- };
7192
-
7193
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/models/index.js
7194
- var modelGateway = /* @__PURE__ */ __name((deps) => ({
7195
- complete: /* @__PURE__ */ __name(async (request) => {
7196
- if (deps.signal?.aborted)
7197
- throw new CliError("cancelled", "model request cancelled");
7198
- const target = deps.resolve(request.purpose);
7199
- if (!target || target.provider === "off")
7200
- throw new CliError("configuration_error", `models.${request.purpose}.provider is not configured; no model was called`);
7201
- if (!request.purpose || !Number.isSafeInteger(request.maxTokens) || request.maxTokens < 1 || typeof request.prompt !== "string")
7202
- throw new CliError("validation_error", "a model request needs a purpose, prompt and positive whole maxTokens");
7203
- validateImages(request.images);
7204
- let adapter = deps.adapters?.[target.provider];
7205
- if (!adapter && target.provider === "openai")
7206
- adapter = openai;
7207
- if (!adapter && target.provider === "anthropic")
7208
- adapter = (await import("./anthropic-YJAEQSNT.js")).anthropic;
7209
- if (!adapter)
7210
- throw new CliError("validation_error", `no model adapter for ${target.provider}`);
7211
- if (request.images !== void 0 && adapter.images !== true)
7212
- throw new CliError("validation_error", "the model adapter does not support image inputs");
7213
- const options2 = adapter.validate(request.options ?? {});
7214
- const baseUrl = target.baseUrl ?? adapter.baseUrl;
7215
- if (!target.model.trim() || !endpoint(baseUrl))
7216
- throw new CliError("validation_error", "a model target needs a model and an HTTP/S endpoint without credentials, query or fragment");
7217
- if (!await deps.consent(request, { ...target, baseUrl }))
7218
- throw new CliError("permission_error", `model consent for ${request.purpose} is missing; no data was sent`);
7219
- const apiKey = await deps.key?.(target.provider, target);
7220
- if (deps.signal?.aborted)
7221
- throw new CliError("cancelled", "model request cancelled");
7222
- const fetcher = deps.fetch ?? fetch;
7223
- let limited = false;
7224
- const cancellable = /* @__PURE__ */ __name(async (input, init) => {
7225
- const signal = init?.signal ?? (input instanceof Request ? input.signal : void 0);
7226
- const response = await fetcher(input, {
7227
- ...init,
7228
- signal: deps.signal ? AbortSignal.any([deps.signal, ...signal ? [signal] : []]) : signal
7229
- });
7230
- if (response.status === 429)
7231
- limited = true;
7232
- return response;
7233
- }, "cancellable");
7234
- try {
7235
- const answer = await adapter.complete({ ...target, baseUrl }, request, options2, apiKey, cancellable);
7236
- if (deps.signal?.aborted)
7237
- throw new Error("cancelled");
7238
- if (typeof answer.text !== "string" || !Number.isSafeInteger(answer.tokens) || answer.tokens < 1)
7239
- throw new Error("incomplete");
7240
- return { ...answer, provider: target.provider, model: target.model };
7241
- } catch {
7242
- if (limited)
7243
- throw new CliError("rate_limited", `${request.purpose} provider rate limit reached; no result was stored`);
7244
- throw new CliError("invalid_response", `${request.purpose} provider failed or returned an incomplete response; no result was stored`);
7245
- }
7246
- }, "complete")
7247
- }), "modelGateway");
7248
-
7249
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/consents.js
7109
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/consents.js
7250
7110
  import { existsSync as existsSync7, readFileSync as readFileSync4 } from "node:fs";
7251
7111
  import { join as join4 } from "node:path";
7252
7112
  var shape = strictObject({
@@ -7271,21 +7131,21 @@ var mayModelReply = /* @__PURE__ */ __name((path, provider, chat) => {
7271
7131
  return consent.provider === provider && !consent.deniedChats.includes(chat);
7272
7132
  }, "mayModelReply");
7273
7133
 
7274
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/rendering.js
7275
- var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, options2 = {
7134
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/rendering.js
7135
+ var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, options = {
7276
7136
  ai: true
7277
7137
  }) => async (rule2, message, chat, now) => {
7278
7138
  let called;
7279
7139
  const gateway = modelGateway({
7280
- signal: options2.signal,
7140
+ signal: options.signal,
7281
7141
  resolve: /* @__PURE__ */ __name((purpose) => {
7282
7142
  called = modelTarget(settings(), purpose);
7283
7143
  return called;
7284
7144
  }, "resolve"),
7285
7145
  consent: /* @__PURE__ */ __name((_request, target) => mayModelReply(replyConsentPathFor(app, profile, env), replyModelIdentity(target.provider, target.baseUrl ?? ""), message.chatId), "consent"),
7286
- key: /* @__PURE__ */ __name((provider, target) => embeddingKeys(app, env, options2.keyring).read(target.baseUrl === void 0 ? provider : endpointKeyName(target.baseUrl))?.key, "key")
7146
+ key: /* @__PURE__ */ __name((provider, target) => embeddingKeys(app, env, options.keyring).read(target.baseUrl === void 0 ? provider : endpointKeyName(target.baseUrl))?.key, "key")
7287
7147
  });
7288
- if (options2.signal?.aborted)
7148
+ if (options.signal?.aborted)
7289
7149
  throw new CliError("cancelled", "reply rendering cancelled");
7290
7150
  const result2 = await renderReplyTemplate(rule2.reply, {
7291
7151
  senderName: message.senderName,
@@ -7293,8 +7153,8 @@ var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, o
7293
7153
  now,
7294
7154
  timezone: rule2.when.hours?.timezone,
7295
7155
  data: message.text,
7296
- allowAI: options2.ai === true,
7297
- preview: options2.preview === true,
7156
+ allowAI: options.ai === true,
7157
+ preview: options.preview === true,
7298
7158
  complete: /* @__PURE__ */ __name(async (prompt, data) => {
7299
7159
  const result3 = await gateway.complete({
7300
7160
  purpose: "replies",
@@ -7303,7 +7163,7 @@ var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, o
7303
7163
  data,
7304
7164
  maxTokens: 512
7305
7165
  });
7306
- if (options2.signal?.aborted)
7166
+ if (options.signal?.aborted)
7307
7167
  throw new CliError("cancelled", "reply rendering cancelled");
7308
7168
  const current = modelTarget(settings(), "replies");
7309
7169
  const baseUrl = called?.baseUrl ?? (called?.provider === "anthropic" ? "https://api.anthropic.com" : "https://api.openai.com/v1");
@@ -7318,7 +7178,7 @@ var replyRenderer = /* @__PURE__ */ __name((app, profile, settings, env, warn, o
7318
7178
  return result2;
7319
7179
  }, "replyRenderer");
7320
7180
 
7321
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/replies/serve.js
7181
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/replies/serve.js
7322
7182
  var NOT_ALLOWED = "replies.send is not allow";
7323
7183
  var NO_RULES = "no rules";
7324
7184
  var ONLY_TASK = "opened a task, sent nothing";
@@ -7411,12 +7271,12 @@ var replyTo = /* @__PURE__ */ __name(async (deps, message) => {
7411
7271
  return { skip: why };
7412
7272
  }, "replyTo");
7413
7273
 
7414
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-catch-up.js
7274
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-catch-up.js
7415
7275
  var START_SYNC_DELAY_MS = 3e4;
7416
7276
  var START_SYNC_BUDGET_MS = 5 * 6e4;
7417
7277
  var START_SYNC_WINDOW_MS = 7 * 864e5;
7418
7278
  var START_SYNC_PER_CHAT = 500;
7419
- var startSync = /* @__PURE__ */ __name(({ chats, newestHeld, fetch: fetch2, note, warn, delayMs = START_SYNC_DELAY_MS, budgetMs = START_SYNC_BUDGET_MS, windowMs = START_SYNC_WINDOW_MS, now = Date.now }) => {
7279
+ var startSync = /* @__PURE__ */ __name(({ chats, newestHeld, fetch, note, warn, delayMs = START_SYNC_DELAY_MS, budgetMs = START_SYNC_BUDGET_MS, windowMs = START_SYNC_WINDOW_MS, now = Date.now }) => {
7420
7280
  const controller = new AbortController();
7421
7281
  let timer;
7422
7282
  let pass = Promise.resolve();
@@ -7444,7 +7304,7 @@ var startSync = /* @__PURE__ */ __name(({ chats, newestHeld, fetch: fetch2, note
7444
7304
  if (stop.aborted)
7445
7305
  break;
7446
7306
  try {
7447
- summary.fetched += (await fetch2(chat.id, Math.max(held ?? anywhere, floor), stop)).fetched;
7307
+ summary.fetched += (await fetch(chat.id, Math.max(held ?? anywhere, floor), stop)).fetched;
7448
7308
  summary.chats += 1;
7449
7309
  } catch (error) {
7450
7310
  if (stop.aborted)
@@ -7488,10 +7348,10 @@ var startSync = /* @__PURE__ */ __name(({ chats, newestHeld, fetch: fetch2, note
7488
7348
  };
7489
7349
  }, "startSync");
7490
7350
 
7491
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-members.js
7351
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-members.js
7492
7352
  var FIRST_FETCH_MS = 6e4;
7493
7353
  var DAY_MS = 864e5;
7494
- var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch: fetch2, warn, firstMs = FIRST_FETCH_MS, everyMs = DAY_MS }) => {
7354
+ var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch, warn, firstMs = FIRST_FETCH_MS, everyMs = DAY_MS }) => {
7495
7355
  let timer;
7496
7356
  let round = Promise.resolve();
7497
7357
  let stopped = false;
@@ -7504,7 +7364,7 @@ var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch: fetch2, warn, fi
7504
7364
  if (lastCount?.day === today)
7505
7365
  continue;
7506
7366
  try {
7507
- await fetch2(store, account, chatId);
7367
+ await fetch(store, account, chatId);
7508
7368
  done.fetched += 1;
7509
7369
  } catch (error) {
7510
7370
  done.failed += 1;
@@ -7542,7 +7402,7 @@ var memberFetches = /* @__PURE__ */ __name(({ withStore, fetch: fetch2, warn, fi
7542
7402
  };
7543
7403
  }, "memberFetches");
7544
7404
 
7545
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-notice.js
7405
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-notice.js
7546
7406
  var record2 = /* @__PURE__ */ __name((context, app, severity, attributes) => recordLogFor(context.streams.diagnostic, app, { command: currentRun().command || "serve" })[severity](attributes), "record");
7547
7407
  var noticeFor = /* @__PURE__ */ __name((context, app, severity = "warn") => ({ text, ...attributes }) => {
7548
7408
  if (context.format === "pretty") {
@@ -7575,7 +7435,7 @@ var recordDiagnostics = /* @__PURE__ */ __name((context, app) => {
7575
7435
  return context;
7576
7436
  }, "recordDiagnostics");
7577
7437
 
7578
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-stems.js
7438
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-stems.js
7579
7439
  var STEMS_EVERY_MS = 3e4;
7580
7440
  var STEMS_SLICE_MS = 2e3;
7581
7441
  var stemFills = /* @__PURE__ */ __name(({ withStore, warn, everyMs = STEMS_EVERY_MS, sliceMs = STEMS_SLICE_MS }) => {
@@ -7615,7 +7475,7 @@ var stemFills = /* @__PURE__ */ __name(({ withStore, warn, everyMs = STEMS_EVERY
7615
7475
  };
7616
7476
  }, "stemFills");
7617
7477
 
7618
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/message-items.js
7478
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/message-items.js
7619
7479
  var defined = /* @__PURE__ */ __name((value) => Object.fromEntries(Object.entries(value).filter(([, one]) => one !== void 0)), "defined");
7620
7480
  var attachmentItem = /* @__PURE__ */ __name((attachment) => defined({
7621
7481
  kind: attachment.kind,
@@ -7710,7 +7570,7 @@ var viewOf = /* @__PURE__ */ __name((context, messenger) => ({
7710
7570
  locale: messenger.app.locale
7711
7571
  }), "viewOf");
7712
7572
 
7713
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-answers.js
7573
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-answers.js
7714
7574
  var observed = /* @__PURE__ */ __name((value) => ({
7715
7575
  value: value.value,
7716
7576
  observed_at: value.observedAt,
@@ -7777,7 +7637,7 @@ var watchEventItem = /* @__PURE__ */ __name((value, account) => {
7777
7637
  }
7778
7638
  }, "watchEventItem");
7779
7639
 
7780
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-command.js
7640
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/watch-command.js
7781
7641
  var watchCommand = /* @__PURE__ */ __name((messenger) => annotate(new Command("watch"), {
7782
7642
  output: { entity: "watch_item" },
7783
7643
  effects: REMOTE_READ,
@@ -7932,7 +7792,7 @@ var describe = /* @__PURE__ */ __name((event, render) => {
7932
7792
  }
7933
7793
  }, "describe");
7934
7794
 
7935
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-command.js
7795
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/serve-command.js
7936
7796
  var serveCommand = /* @__PURE__ */ __name((messenger) => {
7937
7797
  const command = annotate(new Command("serve"), {
7938
7798
  output: { entity: "serve_summary" },
@@ -8196,7 +8056,7 @@ var tasking = /* @__PURE__ */ __name((context, warn) => {
8196
8056
  };
8197
8057
  }, "tasking");
8198
8058
 
8199
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/store-tables-command.js
8059
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/store-tables-command.js
8200
8060
  import { existsSync as existsSync8 } from "node:fs";
8201
8061
  var PATH = "store tables list";
8202
8062
  var STORE_TABLES_QUERY = {
@@ -8239,7 +8099,7 @@ var storeTablesCommand = /* @__PURE__ */ __name((messenger) => {
8239
8099
  return tables;
8240
8100
  }, "storeTablesCommand");
8241
8101
 
8242
- // node_modules/.pnpm/@wirecat+cli-core@0.608.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_2045f8d992dff370989171c93240f8d7/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
8102
+ // node_modules/.pnpm/@wirecat+cli-core@0.614.0_@wirecat+cli-base@0.80.7_commander@15.0.0_esbuild@0.28.2_type_af5f2db22f61976c09fb28de9c7dc33e/node_modules/@wirecat/cli-core/dist/cli/messenger/store-maintenance-command.js
8243
8103
  var SEARCH_INDEXES = ["messages_fts", "chats_fts", "identities_fts"];
8244
8104
  var WORD_INDEX = "message_words";
8245
8105
  var schemaOf = /* @__PURE__ */ __name((database) => {
@@ -8905,6 +8765,7 @@ var isoOf = /* @__PURE__ */ __name((value) => new Date(Number(value)).toISOStrin
8905
8765
  var messageOf2 = /* @__PURE__ */ __name((error) => error instanceof Error ? error.message : String(error), "messageOf");
8906
8766
 
8907
8767
  export {
8768
+ safeLiquid,
8908
8769
  REPLY_ACTIONS,
8909
8770
  REPLY_MODELS,
8910
8771
  REPLY_KINDS,
@@ -8920,9 +8781,6 @@ export {
8920
8781
  paused,
8921
8782
  DRY_RUN_DAYS,
8922
8783
  dryRun,
8923
- endpointKeyName,
8924
- embeddingKeys,
8925
- modelGateway,
8926
8784
  replyConsentPathFor,
8927
8785
  readReplyConsent,
8928
8786
  writeReplyConsent,