veryfront 0.1.977 → 0.1.979
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/esm/deno.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"provider-tool-compat.d.ts","sourceRoot":"","sources":["../../../../src/src/agent/runtime/provider-tool-compat.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,6DAA6D;AAC7D,MAAM,MAAM,0BAA0B,GAClC,WAAW,GACX,QAAQ,GACR,UAAU,GACV,QAAQ,GACR,SAAS,CAAC;AAEd,qDAAqD;AACrD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,0BAA0B,CAAC;IACrC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,OAAO,CAAC;CACzB;AAED,gDAAgD;AAChD,MAAM,WAAW,yBAAyB;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACvC;AA2BD,oCAAoC;AACpC,wBAAgB,sBAAsB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,mBAAmB,CAuB1E;AAeD,oDAAoD;AACpD,wBAAgB,iCAAiC,CAC/C,SAAS,EAAE,SAAS,MAAM,EAAE,EAC5B,OAAO,GAAE,yBAA8B,GACtC,MAAM,EAAE,CAsBV;AAED,+CAA+C;AAC/C,wBAAgB,6BAA6B,CAC3C,KAAK,EAAE,SAAS,cAAc,EAAE,EAChC,OAAO,GAAE,yBAA8B,GACtC,cAAc,EAAE,CAclB;
|
|
1
|
+
{"version":3,"file":"provider-tool-compat.d.ts","sourceRoot":"","sources":["../../../../src/src/agent/runtime/provider-tool-compat.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,6DAA6D;AAC7D,MAAM,MAAM,0BAA0B,GAClC,WAAW,GACX,QAAQ,GACR,UAAU,GACV,QAAQ,GACR,SAAS,CAAC;AAEd,qDAAqD;AACrD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,0BAA0B,CAAC;IACrC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,OAAO,CAAC;CACzB;AAED,gDAAgD;AAChD,MAAM,WAAW,yBAAyB;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;CACvC;AA2BD,oCAAoC;AACpC,wBAAgB,sBAAsB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,mBAAmB,CAuB1E;AAeD,oDAAoD;AACpD,wBAAgB,iCAAiC,CAC/C,SAAS,EAAE,SAAS,MAAM,EAAE,EAC5B,OAAO,GAAE,yBAA8B,GACtC,MAAM,EAAE,CAsBV;AAED,+CAA+C;AAC/C,wBAAgB,6BAA6B,CAC3C,KAAK,EAAE,SAAS,cAAc,EAAE,EAChC,OAAO,GAAE,yBAA8B,GACtC,cAAc,EAAE,CAclB;AA6PD;;;;GAIG;AACH,wBAAgB,gCAAgC,CAAC,MAAM,EAAE,UAAU,GAAG,UAAU,CAa/E;AAED,6CAA6C;AAC7C,wBAAgB,0BAA0B,CACxC,MAAM,EAAE,UAAU,EAClB,OAAO,GAAE,IAAI,CAAC,yBAAyB,EAAE,OAAO,CAAM,GACrD,UAAU,CAeZ"}
|
|
@@ -228,13 +228,48 @@ function sanitizeGoogleSchemaValue(value) {
|
|
|
228
228
|
}
|
|
229
229
|
return sanitized;
|
|
230
230
|
}
|
|
231
|
-
function
|
|
231
|
+
function decodeJsonPointerSegment(segment) {
|
|
232
|
+
return segment.replaceAll("~1", "/").replaceAll("~0", "~");
|
|
233
|
+
}
|
|
234
|
+
function resolveLocalJsonPointer(root, ref) {
|
|
235
|
+
if (!ref.startsWith("#/")) {
|
|
236
|
+
return undefined;
|
|
237
|
+
}
|
|
238
|
+
let current = root;
|
|
239
|
+
for (const rawSegment of ref.slice(2).split("/")) {
|
|
240
|
+
if (!isPlainRecord(current) && !Array.isArray(current)) {
|
|
241
|
+
return undefined;
|
|
242
|
+
}
|
|
243
|
+
const segment = decodeJsonPointerSegment(rawSegment);
|
|
244
|
+
current = Reflect.get(current, segment);
|
|
245
|
+
}
|
|
246
|
+
return current;
|
|
247
|
+
}
|
|
248
|
+
function sanitizeMoonshotSchemaValue(value, root = value, seenRefs = new Set()) {
|
|
232
249
|
if (Array.isArray(value)) {
|
|
233
|
-
return value.map((item) => sanitizeMoonshotSchemaValue(item));
|
|
250
|
+
return value.map((item) => sanitizeMoonshotSchemaValue(item, root, seenRefs));
|
|
234
251
|
}
|
|
235
252
|
if (!isPlainRecord(value)) {
|
|
236
253
|
return value;
|
|
237
254
|
}
|
|
255
|
+
if (typeof value.$ref === "string" &&
|
|
256
|
+
!value.$ref.startsWith("#/$defs/") &&
|
|
257
|
+
!value.$ref.startsWith("#/definitions/") &&
|
|
258
|
+
!seenRefs.has(value.$ref)) {
|
|
259
|
+
const resolved = resolveLocalJsonPointer(root, value.$ref);
|
|
260
|
+
if (resolved !== undefined && resolved !== value) {
|
|
261
|
+
const nextSeenRefs = new Set(seenRefs);
|
|
262
|
+
nextSeenRefs.add(value.$ref);
|
|
263
|
+
const sanitizedResolved = sanitizeMoonshotSchemaValue(resolved, root, nextSeenRefs);
|
|
264
|
+
const { $ref: _ref, ...siblings } = value;
|
|
265
|
+
const sanitizedSiblings = Object.keys(siblings).length > 0
|
|
266
|
+
? sanitizeMoonshotSchemaValue(siblings, root, nextSeenRefs)
|
|
267
|
+
: undefined;
|
|
268
|
+
return isPlainRecord(sanitizedResolved) && isPlainRecord(sanitizedSiblings)
|
|
269
|
+
? { ...sanitizedResolved, ...sanitizedSiblings }
|
|
270
|
+
: sanitizedResolved;
|
|
271
|
+
}
|
|
272
|
+
}
|
|
238
273
|
const sanitized = {};
|
|
239
274
|
for (const [key, child] of Object.entries(value)) {
|
|
240
275
|
if (key === "$ref" && typeof child === "string") {
|
|
@@ -242,17 +277,17 @@ function sanitizeMoonshotSchemaValue(value) {
|
|
|
242
277
|
continue;
|
|
243
278
|
}
|
|
244
279
|
if (key === "definitions") {
|
|
245
|
-
sanitized.$defs = sanitizeMoonshotSchemaValue(child);
|
|
280
|
+
sanitized.$defs = sanitizeMoonshotSchemaValue(child, root, seenRefs);
|
|
246
281
|
continue;
|
|
247
282
|
}
|
|
248
283
|
if (key === "properties" && isPlainRecord(child)) {
|
|
249
284
|
sanitized.properties = Object.fromEntries(Object.entries(child).map(([propertyName, propertySchema]) => [
|
|
250
285
|
propertyName,
|
|
251
|
-
sanitizeMoonshotSchemaValue(propertySchema),
|
|
286
|
+
sanitizeMoonshotSchemaValue(propertySchema, root, seenRefs),
|
|
252
287
|
]));
|
|
253
288
|
continue;
|
|
254
289
|
}
|
|
255
|
-
sanitized[key] = sanitizeMoonshotSchemaValue(child);
|
|
290
|
+
sanitized[key] = sanitizeMoonshotSchemaValue(child, root, seenRefs);
|
|
256
291
|
}
|
|
257
292
|
return sanitized;
|
|
258
293
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "veryfront",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.979",
|
|
4
4
|
"description": "The simplest way to build AI-powered apps",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -386,7 +386,7 @@
|
|
|
386
386
|
"@deno/shim-timers": "0.1.0",
|
|
387
387
|
"@types/react": "19.2.14",
|
|
388
388
|
"@types/react-dom": "19.2.3",
|
|
389
|
-
"ws": "8.
|
|
389
|
+
"ws": "8.21.0"
|
|
390
390
|
},
|
|
391
391
|
"peerDependencies": {
|
|
392
392
|
"better-sqlite3": ">=9.0.0",
|
|
@@ -409,7 +409,7 @@
|
|
|
409
409
|
},
|
|
410
410
|
"_generatedBy": "dnt@dev",
|
|
411
411
|
"overrides": {
|
|
412
|
-
"protobufjs": "8.
|
|
412
|
+
"protobufjs": "8.6.5"
|
|
413
413
|
},
|
|
414
414
|
"type": "module",
|
|
415
415
|
"types": "./esm/src/index.d.ts",
|