@devness/useai 0.5.35 → 0.5.36

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 (2) hide show
  1. package/dist/index.js +31 -32
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -656,7 +656,7 @@ var VERSION;
656
656
  var init_version = __esm({
657
657
  "../shared/dist/constants/version.js"() {
658
658
  "use strict";
659
- VERSION = "0.5.35";
659
+ VERSION = "0.5.36";
660
660
  }
661
661
  });
662
662
 
@@ -1540,9 +1540,9 @@ function createZodEnum(values, params) {
1540
1540
  });
1541
1541
  }
1542
1542
  function cleanParams(params, data) {
1543
- const p2 = typeof params === "function" ? params(data) : typeof params === "string" ? { message: params } : params;
1544
- const p22 = typeof p2 === "string" ? { message: p2 } : p2;
1545
- return p22;
1543
+ const p = typeof params === "function" ? params(data) : typeof params === "string" ? { message: params } : params;
1544
+ const p2 = typeof p === "string" ? { message: p } : p;
1545
+ return p2;
1546
1546
  }
1547
1547
  function custom(check2, _params = {}, fatal) {
1548
1548
  if (check2)
@@ -5262,9 +5262,9 @@ function resolveNpxPath() {
5262
5262
  } catch {
5263
5263
  }
5264
5264
  }
5265
- for (const p2 of KNOWN_PATHS) {
5266
- if (existsSync2(p2))
5267
- return p2;
5265
+ for (const p of KNOWN_PATHS) {
5266
+ if (existsSync2(p))
5267
+ return p;
5268
5268
  }
5269
5269
  throw new Error("Could not find npx. Ensure Node.js is installed and npx is in your PATH.");
5270
5270
  }
@@ -5391,7 +5391,7 @@ async function killDaemon() {
5391
5391
  }
5392
5392
  const pids = findPidsByPort(port);
5393
5393
  if (pids.length > 0) {
5394
- await Promise.all(pids.map((p2) => killPid(p2)));
5394
+ await Promise.all(pids.map((p) => killPid(p)));
5395
5395
  }
5396
5396
  try {
5397
5397
  if (existsSync3(DAEMON_PID_FILE))
@@ -6497,7 +6497,6 @@ var init_setup = __esm({
6497
6497
  init_source();
6498
6498
  init_dist();
6499
6499
  init_tools();
6500
- p;
6501
6500
  }
6502
6501
  });
6503
6502
 
@@ -8593,7 +8592,7 @@ var init_schemas2 = __esm({
8593
8592
  defineLazy(inst._zod, "pattern", () => {
8594
8593
  if (def.options.every((o) => o._zod.pattern)) {
8595
8594
  const patterns = def.options.map((o) => o._zod.pattern);
8596
- return new RegExp(`^(${patterns.map((p2) => cleanRegex(p2.source)).join("|")})$`);
8595
+ return new RegExp(`^(${patterns.map((p) => cleanRegex(p.source)).join("|")})$`);
8597
8596
  }
8598
8597
  return void 0;
8599
8598
  });
@@ -9180,9 +9179,9 @@ var init_registries = __esm({
9180
9179
  return this;
9181
9180
  }
9182
9181
  get(schema) {
9183
- const p2 = schema._zod.parent;
9184
- if (p2) {
9185
- const pm = { ...this.get(p2) ?? {} };
9182
+ const p = schema._zod.parent;
9183
+ if (p) {
9184
+ const pm = { ...this.get(p) ?? {} };
9186
9185
  delete pm.id;
9187
9186
  return { ...pm, ...this._map.get(schema) };
9188
9187
  }
@@ -16809,7 +16808,7 @@ var require_util = __commonJS({
16809
16808
  }
16810
16809
  exports.evaluatedPropsToName = evaluatedPropsToName;
16811
16810
  function setEvaluated(gen, props, ps) {
16812
- Object.keys(ps).forEach((p2) => gen.assign((0, codegen_1._)`${props}${(0, codegen_1.getProperty)(p2)}`, true));
16811
+ Object.keys(ps).forEach((p) => gen.assign((0, codegen_1._)`${props}${(0, codegen_1.getProperty)(p)}`, true));
16813
16812
  }
16814
16813
  exports.setEvaluated = setEvaluated;
16815
16814
  var snippets = {};
@@ -17382,11 +17381,11 @@ var require_code2 = __commonJS({
17382
17381
  }
17383
17382
  exports.noPropertyInData = noPropertyInData;
17384
17383
  function allSchemaProperties(schemaMap) {
17385
- return schemaMap ? Object.keys(schemaMap).filter((p2) => p2 !== "__proto__") : [];
17384
+ return schemaMap ? Object.keys(schemaMap).filter((p) => p !== "__proto__") : [];
17386
17385
  }
17387
17386
  exports.allSchemaProperties = allSchemaProperties;
17388
17387
  function schemaProperties(it, schemaMap) {
17389
- return allSchemaProperties(schemaMap).filter((p2) => !(0, util_1.alwaysValidSchema)(it, schemaMap[p2]));
17388
+ return allSchemaProperties(schemaMap).filter((p) => !(0, util_1.alwaysValidSchema)(it, schemaMap[p]));
17390
17389
  }
17391
17390
  exports.schemaProperties = schemaProperties;
17392
17391
  function callValidateCode({ schemaCode, data, it: { gen, topSchemaRef, schemaPath, errorPath }, it }, func, context, passSchema) {
@@ -17864,12 +17863,12 @@ var require_resolve = __commonJS({
17864
17863
  function getFullPath(resolver, id = "", normalize) {
17865
17864
  if (normalize !== false)
17866
17865
  id = normalizeId(id);
17867
- const p2 = resolver.parse(id);
17868
- return _getFullPath(resolver, p2);
17866
+ const p = resolver.parse(id);
17867
+ return _getFullPath(resolver, p);
17869
17868
  }
17870
17869
  exports.getFullPath = getFullPath;
17871
- function _getFullPath(resolver, p2) {
17872
- const serialized = resolver.serialize(p2);
17870
+ function _getFullPath(resolver, p) {
17871
+ const serialized = resolver.serialize(p);
17873
17872
  return serialized.split("#")[0] + "#";
17874
17873
  }
17875
17874
  exports._getFullPath = _getFullPath;
@@ -18644,11 +18643,11 @@ var require_compile = __commonJS({
18644
18643
  return sch || this.schemas[ref] || resolveSchema.call(this, root, ref);
18645
18644
  }
18646
18645
  function resolveSchema(root, ref) {
18647
- const p2 = this.opts.uriResolver.parse(ref);
18648
- const refPath = (0, resolve_1._getFullPath)(this.opts.uriResolver, p2);
18646
+ const p = this.opts.uriResolver.parse(ref);
18647
+ const refPath = (0, resolve_1._getFullPath)(this.opts.uriResolver, p);
18649
18648
  let baseId = (0, resolve_1.getFullPath)(this.opts.uriResolver, root.baseId, void 0);
18650
18649
  if (Object.keys(root.schema).length > 0 && refPath === baseId) {
18651
- return getJsonPointer.call(this, p2, root);
18650
+ return getJsonPointer.call(this, p, root);
18652
18651
  }
18653
18652
  const id = (0, resolve_1.normalizeId)(refPath);
18654
18653
  const schOrRef = this.refs[id] || this.schemas[id];
@@ -18656,7 +18655,7 @@ var require_compile = __commonJS({
18656
18655
  const sch = resolveSchema.call(this, root, schOrRef);
18657
18656
  if (typeof (sch === null || sch === void 0 ? void 0 : sch.schema) !== "object")
18658
18657
  return;
18659
- return getJsonPointer.call(this, p2, sch);
18658
+ return getJsonPointer.call(this, p, sch);
18660
18659
  }
18661
18660
  if (typeof (schOrRef === null || schOrRef === void 0 ? void 0 : schOrRef.schema) !== "object")
18662
18661
  return;
@@ -18670,7 +18669,7 @@ var require_compile = __commonJS({
18670
18669
  baseId = (0, resolve_1.resolveUrl)(this.opts.uriResolver, baseId, schId);
18671
18670
  return new SchemaEnv({ schema, schemaId, root, baseId });
18672
18671
  }
18673
- return getJsonPointer.call(this, p2, schOrRef);
18672
+ return getJsonPointer.call(this, p, schOrRef);
18674
18673
  }
18675
18674
  exports.resolveSchema = resolveSchema;
18676
18675
  var PREVENT_SCOPE_CHANGE = /* @__PURE__ */ new Set([
@@ -19675,9 +19674,9 @@ var require_core = __commonJS({
19675
19674
  this.addSchema(_schema, ref, meta);
19676
19675
  }
19677
19676
  async function _loadSchema(ref) {
19678
- const p2 = this._loading[ref];
19679
- if (p2)
19680
- return p2;
19677
+ const p = this._loading[ref];
19678
+ if (p)
19679
+ return p;
19681
19680
  try {
19682
19681
  return await (this._loading[ref] = loadSchema(ref));
19683
19682
  } finally {
@@ -21159,12 +21158,12 @@ var require_additionalProperties = __commonJS({
21159
21158
  const propsSchema = (0, util_1.schemaRefOrVal)(it, parentSchema.properties, "properties");
21160
21159
  definedProp = (0, code_1.isOwnProperty)(gen, propsSchema, key);
21161
21160
  } else if (props.length) {
21162
- definedProp = (0, codegen_1.or)(...props.map((p2) => (0, codegen_1._)`${key} === ${p2}`));
21161
+ definedProp = (0, codegen_1.or)(...props.map((p) => (0, codegen_1._)`${key} === ${p}`));
21163
21162
  } else {
21164
21163
  definedProp = codegen_1.nil;
21165
21164
  }
21166
21165
  if (patProps.length) {
21167
- definedProp = (0, codegen_1.or)(definedProp, ...patProps.map((p2) => (0, codegen_1._)`${(0, code_1.usePattern)(cxt, p2)}.test(${key})`));
21166
+ definedProp = (0, codegen_1.or)(definedProp, ...patProps.map((p) => (0, codegen_1._)`${(0, code_1.usePattern)(cxt, p)}.test(${key})`));
21168
21167
  }
21169
21168
  return (0, codegen_1.not)(definedProp);
21170
21169
  }
@@ -21244,7 +21243,7 @@ var require_properties = __commonJS({
21244
21243
  if (it.opts.unevaluated && allProps.length && it.props !== true) {
21245
21244
  it.props = util_1.mergeEvaluated.props(gen, (0, util_1.toHash)(allProps), it.props);
21246
21245
  }
21247
- const properties = allProps.filter((p2) => !(0, util_1.alwaysValidSchema)(it, schema[p2]));
21246
+ const properties = allProps.filter((p) => !(0, util_1.alwaysValidSchema)(it, schema[p]));
21248
21247
  if (properties.length === 0)
21249
21248
  return;
21250
21249
  const valid = gen.name("valid");
@@ -21294,7 +21293,7 @@ var require_patternProperties = __commonJS({
21294
21293
  const { gen, schema, data, parentSchema, it } = cxt;
21295
21294
  const { opts } = it;
21296
21295
  const patterns = (0, code_1.allSchemaProperties)(schema);
21297
- const alwaysValidPatterns = patterns.filter((p2) => (0, util_1.alwaysValidSchema)(it, schema[p2]));
21296
+ const alwaysValidPatterns = patterns.filter((p) => (0, util_1.alwaysValidSchema)(it, schema[p]));
21298
21297
  if (patterns.length === 0 || alwaysValidPatterns.length === patterns.length && (!it.opts.unevaluated || it.props === true)) {
21299
21298
  return;
21300
21299
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devness/useai",
3
- "version": "0.5.35",
3
+ "version": "0.5.36",
4
4
  "description": "Track your AI-assisted development workflow. MCP server that records usage metrics across all your AI tools.",
5
5
  "keywords": [
6
6
  "mcp",