@far-world-labs/verblets 0.6.3 → 0.6.4
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/README.md +32 -7
- package/dist/index.browser.js +234 -224
- package/dist/index.js +448 -443
- package/dist/shared-CsrVgt_K.js +11483 -0
- package/package.json +1 -1
- package/dist/shared-BSAzZOFX.js +0 -11644
package/dist/index.js
CHANGED
|
@@ -1,34 +1,33 @@
|
|
|
1
1
|
import ne from "dotenv";
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
2
|
+
import { i as re, n as $, c as L, g as X, a as oe, w as B, r as U, j as Y, b as ie, O as k, s as Q, d as ce, e as le, f as ue } from "./shared-CsrVgt_K.js";
|
|
3
|
+
import { cR as At, N as Pt, K as Et, P as Rt, cg as Tt, aX as Dt, M as $t, cf as Lt, L as Ft, ci as Mt, cj as Nt, av as _t, c7 as Bt, cQ as Ut, cl as Ot, cm as zt, Q as jt, bn as qt, ck as Vt, bq as Wt, ch as Gt, cc as Ht, bH as Jt, bC as Kt, bD as Xt, cb as Yt, a6 as Qt, I as Zt, af as es, a5 as ts, bd as ss, y as as, aB as ns, aL as rs, bF as os, o as is, aU as cs, bE as ls, ac as us, G as ps, H as ds, aT as ms, bA as hs, a8 as gs, a9 as fs, cz as bs, c4 as ys, q as ws, h as Ss, aV as xs, c2 as vs, aW as Is, cA as Cs, bs as ks, cT as As, m as Ps, aY as Es, cB as Rs, c6 as Ts, J as Ds, R as $s, ag as Ls, be as Fs, z as Ms, aM as Ns, aN as _s, Y as Bs, p as Us, c5 as Os, W as zs, aa as js, ab as qs, aw as Vs, aZ as Ws, a$ as Gs, b1 as Hs, b2 as Js, bN as Ks, c0 as Xs, bO as Ys, b_ as Qs, bP as Zs, b$ as ea, bU as ta, bZ as sa, bY as aa, bT as na, bX as ra, bS as oa, c1 as ia, bV as ca, bW as la, bQ as ua, ad as pa, ai as da, ak as ma, al as ha, ah as ga, aj as fa, ae as ba, a3 as ya, a4 as wa, Z as Sa, bG as xa, am as va, cq as Ia, b3 as Ca, an as ka, b4 as Aa, ao as Pa, at as Ea, a_ as Ra, U as Ta, V as Da, ap as $a, aq as La, cS as Fa, bI as Ma, ar as Na, b5 as _a, cC as Ba, as as Ua, au as Oa, ax as za, bJ as ja, bK as qa, ay as Va, b6 as Wa, b7 as Ga, c8 as Ha, t as Ja, u as Ka, S as Xa, T as Ya, cD as Qa, c9 as Za, ca as en, cy as tn, bf as sn, bg as an, b8 as nn, bK as rn, cE as on, cK as cn, b9 as ln, F as un, cN as pn, cO as dn, cL as mn, ba as hn, c3 as gn, bc as fn, bb as bn, bi as yn, bk as wn, bl as Sn, bh as xn, bj as vn, cP as In, k as Cn, ce as kn, v as An, B as Pn, D as En, E as Rn, A as Tn, C as Dn, x as $n, bm as Ln, cM as Fn, bz as Mn, az as Nn, aE as _n, aG as Bn, aH as Un, aC as On, aD as zn, aF as jn, aA as qn, bL as Vn, bR as Wn, l as Gn, bM as Hn, cJ as Jn, b0 as Kn, bo as Xn, bB as Yn, aI as Qn, cF as Zn, bp as er, cs as tr, cr as sr, a7 as ar, aK as nr, br as rr, aJ as or, aP as ir, aR as cr, aS as lr, aO as ur, aQ as pr, $ as dr, a0 as mr, _ as hr, a2 as gr, cd as fr, bt as br, bu as yr, ct as wr, cv as Sr, cw as xr, cu as vr, cx as Ir, bv as Cr, bw as kr, cG as Ar, a1 as Pr, X as Er, cH as Rr, by as Tr, bx as Dr, cn as $r, co as Lr, cp as Fr, cI as Mr } from "./shared-CsrVgt_K.js";
|
|
4
|
+
import * as j from "playwright-core";
|
|
5
|
+
import I from "node:fs";
|
|
6
|
+
import "node:path";
|
|
7
7
|
import "glob";
|
|
8
|
-
import
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
high: { width: 50, quality: M, format: "jpeg" }
|
|
8
|
+
import pe from "node:fs/promises";
|
|
9
|
+
const N = 60, de = (t) => ({
|
|
10
|
+
low: { width: 300, quality: N, format: "jpeg" },
|
|
11
|
+
med: { width: 100, quality: N, format: "jpeg" },
|
|
12
|
+
high: { width: 50, quality: N, format: "jpeg" }
|
|
14
13
|
})[t], O = (t) => () => {
|
|
15
14
|
throw new Error(`${t} is not available in browser environment`);
|
|
16
|
-
},
|
|
15
|
+
}, ft = O("resizeImage"), bt = O("tileImages"), yt = O("imageToBase64"), wt = () => {
|
|
17
16
|
throw new Error("webScrape is not available in browser environment");
|
|
18
|
-
},
|
|
17
|
+
}, me = async (t, a) => (await t.evaluate(() => {
|
|
19
18
|
const s = /* @__PURE__ */ new Set();
|
|
20
19
|
return [...document.querySelectorAll("a[href]")].map((n) => {
|
|
21
|
-
const
|
|
22
|
-
if (s.has(
|
|
23
|
-
s.add(
|
|
24
|
-
const
|
|
20
|
+
const o = n.href;
|
|
21
|
+
if (s.has(o)) return;
|
|
22
|
+
s.add(o);
|
|
23
|
+
const i = n.getBoundingClientRect();
|
|
25
24
|
return {
|
|
26
|
-
href:
|
|
25
|
+
href: o,
|
|
27
26
|
text: n.textContent?.trim()?.slice(0, 120) || "",
|
|
28
27
|
ariaLabel: n.getAttribute("aria-label") || "",
|
|
29
28
|
rel: n.getAttribute("rel") || "",
|
|
30
29
|
target: n.getAttribute("target") || "",
|
|
31
|
-
isVisible:
|
|
30
|
+
isVisible: i.width > 0 && i.height > 0,
|
|
32
31
|
classes: n.className?.slice?.(0, 120) || "",
|
|
33
32
|
dataAttrs: Object.fromEntries(
|
|
34
33
|
[...n.attributes].filter((r) => r.name.startsWith("data-")).map((r) => [r.name, r.value?.slice(0, 80)])
|
|
@@ -43,7 +42,7 @@ const he = (t) => {
|
|
|
43
42
|
isExternal: !s.href.startsWith(a),
|
|
44
43
|
isSameDomain: s.href.startsWith(a),
|
|
45
44
|
isAnchor: s.href.includes("#") && new URL(s.href).pathname === new URL(t.url()).pathname
|
|
46
|
-
})),
|
|
45
|
+
})), he = (t) => t.evaluate(
|
|
47
46
|
() => [...document.querySelectorAll("form")].map((a) => ({
|
|
48
47
|
action: a.action || "",
|
|
49
48
|
method: (a.method || "GET").toUpperCase(),
|
|
@@ -68,7 +67,7 @@ const he = (t) => {
|
|
|
68
67
|
})) : void 0
|
|
69
68
|
}))
|
|
70
69
|
}))
|
|
71
|
-
),
|
|
70
|
+
), ge = (t) => t.evaluate(() => {
|
|
72
71
|
const a = [
|
|
73
72
|
...document.querySelectorAll(
|
|
74
73
|
'button, [role="button"], input[type="button"], input[type="submit"]'
|
|
@@ -77,7 +76,7 @@ const he = (t) => {
|
|
|
77
76
|
...document.querySelectorAll("[onclick], [data-action], [data-toggle], [data-target]")
|
|
78
77
|
];
|
|
79
78
|
return [.../* @__PURE__ */ new Set([...a, ...e])].map((n) => {
|
|
80
|
-
const
|
|
79
|
+
const o = n.getBoundingClientRect();
|
|
81
80
|
return {
|
|
82
81
|
tag: n.tagName.toLowerCase(),
|
|
83
82
|
type: n.type || "",
|
|
@@ -85,16 +84,16 @@ const he = (t) => {
|
|
|
85
84
|
id: n.id || "",
|
|
86
85
|
classes: (typeof n.className == "string" ? n.className : n.className?.baseVal || "").slice(0, 120),
|
|
87
86
|
ariaLabel: n.getAttribute("aria-label") || "",
|
|
88
|
-
isVisible:
|
|
87
|
+
isVisible: o.width > 0 && o.height > 0,
|
|
89
88
|
disabled: n.disabled || n.getAttribute("aria-disabled") === "true",
|
|
90
89
|
hasOnclick: !!n.getAttribute("onclick"),
|
|
91
90
|
onclick: n.getAttribute("onclick")?.slice(0, 120) || "",
|
|
92
91
|
dataAttrs: Object.fromEntries(
|
|
93
|
-
[...n.attributes].filter((
|
|
92
|
+
[...n.attributes].filter((i) => i.name.startsWith("data-")).map((i) => [i.name, i.value?.slice(0, 80)])
|
|
94
93
|
)
|
|
95
94
|
};
|
|
96
95
|
});
|
|
97
|
-
}),
|
|
96
|
+
}), fe = (t) => t.evaluate(() => [...document.querySelectorAll("script")].map((e) => ({
|
|
98
97
|
src: e.src || "",
|
|
99
98
|
type: e.type || "",
|
|
100
99
|
isModule: e.type === "module",
|
|
@@ -102,7 +101,7 @@ const he = (t) => {
|
|
|
102
101
|
size: e.textContent?.length || 0,
|
|
103
102
|
// First 200 chars of inline scripts to identify patterns
|
|
104
103
|
preview: e.src ? "" : e.textContent?.trim()?.slice(0, 200)
|
|
105
|
-
}))),
|
|
104
|
+
}))), be = (t) => t.evaluate(() => {
|
|
106
105
|
const a = (e) => document.querySelector(`meta[name="${e}"], meta[property="${e}"]`)?.content || "";
|
|
107
106
|
return {
|
|
108
107
|
title: document.title || "",
|
|
@@ -129,7 +128,7 @@ const he = (t) => {
|
|
|
129
128
|
content: e.content?.slice(0, 120)
|
|
130
129
|
}))
|
|
131
130
|
};
|
|
132
|
-
}),
|
|
131
|
+
}), ye = (t) => t.evaluate(() => {
|
|
133
132
|
const a = [...document.querySelectorAll("h1, h2, h3, h4, h5, h6")].slice(0, 30).map((l) => ({
|
|
134
133
|
level: parseInt(l.tagName[1], 10),
|
|
135
134
|
text: l.textContent?.trim()?.slice(0, 100)
|
|
@@ -146,16 +145,16 @@ const he = (t) => {
|
|
|
146
145
|
document.querySelectorAll("*").forEach((l) => {
|
|
147
146
|
[...l.attributes].filter((d) => d.name.startsWith("data-")).forEach((d) => s.add(d.name));
|
|
148
147
|
});
|
|
149
|
-
const n = [...document.querySelectorAll('link[rel="stylesheet"]')].map((l) => l.href),
|
|
148
|
+
const n = [...document.querySelectorAll('link[rel="stylesheet"]')].map((l) => l.href), o = /* @__PURE__ */ new Set(), i = (l) => {
|
|
150
149
|
const d = l.className;
|
|
151
150
|
return typeof d == "string" ? d : d?.baseVal || "";
|
|
152
151
|
};
|
|
153
152
|
document.querySelectorAll("[class]").forEach((l) => {
|
|
154
|
-
|
|
155
|
-
d &&
|
|
153
|
+
i(l).split(/\s+/).slice(0, 5).forEach((d) => {
|
|
154
|
+
d && o.add(d);
|
|
156
155
|
});
|
|
157
156
|
});
|
|
158
|
-
const r = [...
|
|
157
|
+
const r = [...o].slice(0, 200), c = {}, u = [
|
|
159
158
|
"jQuery",
|
|
160
159
|
"$",
|
|
161
160
|
"React",
|
|
@@ -212,30 +211,30 @@ const he = (t) => {
|
|
|
212
211
|
iframeCount: document.querySelectorAll("iframe").length,
|
|
213
212
|
shadowRootCount: [...document.querySelectorAll("*")].filter((l) => l.shadowRoot).length
|
|
214
213
|
};
|
|
215
|
-
}),
|
|
216
|
-
const a = t.url(), e = new URL(a).origin, [s, n,
|
|
217
|
-
|
|
214
|
+
}), we = async (t) => {
|
|
215
|
+
const a = t.url(), e = new URL(a).origin, [s, n, o, i, r, c] = await Promise.all([
|
|
216
|
+
me(t, e),
|
|
217
|
+
he(t),
|
|
218
|
+
ge(t),
|
|
219
|
+
fe(t),
|
|
218
220
|
be(t),
|
|
219
|
-
ye(t)
|
|
220
|
-
we(t),
|
|
221
|
-
Se(t),
|
|
222
|
-
xe(t)
|
|
221
|
+
ye(t)
|
|
223
222
|
]);
|
|
224
|
-
return { url: a, links: s, forms: n, buttons:
|
|
225
|
-
},
|
|
223
|
+
return { url: a, links: s, forms: n, buttons: o, scripts: i, meta: r, structure: c };
|
|
224
|
+
}, E = (t) => {
|
|
226
225
|
const a = new URL(t);
|
|
227
226
|
a.hash = "";
|
|
228
|
-
const e = [...a.searchParams.entries()].sort(([n], [
|
|
227
|
+
const e = [...a.searchParams.entries()].sort(([n], [o]) => n.localeCompare(o));
|
|
229
228
|
a.search = new URLSearchParams(e).toString();
|
|
230
229
|
const s = a.toString();
|
|
231
230
|
return s.endsWith("/") && a.pathname !== "/" ? s.slice(0, -1) : s;
|
|
232
|
-
},
|
|
233
|
-
const e = new URL(t).origin, s = a.sameDomain !== !1, n = a.maxDepth ?? 10,
|
|
234
|
-
return
|
|
231
|
+
}, Se = (t, a = 2) => `/${new URL(t).pathname.split("/").filter(Boolean).slice(0, a).join("/")}`, xe = (t, a = {}) => {
|
|
232
|
+
const e = new URL(t).origin, s = a.sameDomain !== !1, n = a.maxDepth ?? 10, o = [], i = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Map(), c = /* @__PURE__ */ new Set(), u = E(t);
|
|
233
|
+
return o.push({ url: t, normalized: u, depth: 0, source: "(start)" }), c.add(u), {
|
|
235
234
|
addLinks: (b, p, y) => {
|
|
236
235
|
let f = 0;
|
|
237
236
|
for (const S of b) {
|
|
238
|
-
const x = S.href || S, w =
|
|
237
|
+
const x = S.href || S, w = E(x);
|
|
239
238
|
if (c.has(w)) continue;
|
|
240
239
|
if (c.add(w), s && !x.startsWith(e)) {
|
|
241
240
|
r.set(w, "external");
|
|
@@ -245,8 +244,8 @@ const he = (t) => {
|
|
|
245
244
|
r.set(w, "max-depth");
|
|
246
245
|
continue;
|
|
247
246
|
}
|
|
248
|
-
const
|
|
249
|
-
if (/\.(png|jpg|jpeg|gif|svg|ico|css|js|woff2?|ttf|eot|pdf|zip|mp[34])$/i.test(
|
|
247
|
+
const M = new URL(x).pathname;
|
|
248
|
+
if (/\.(png|jpg|jpeg|gif|svg|ico|css|js|woff2?|ttf|eot|pdf|zip|mp[34])$/i.test(M)) {
|
|
250
249
|
r.set(w, "resource");
|
|
251
250
|
continue;
|
|
252
251
|
}
|
|
@@ -254,13 +253,13 @@ const he = (t) => {
|
|
|
254
253
|
r.set(w, "scheme");
|
|
255
254
|
continue;
|
|
256
255
|
}
|
|
257
|
-
|
|
256
|
+
o.push({ url: x, normalized: w, depth: p + 1, source: y }), f++;
|
|
258
257
|
}
|
|
259
258
|
return f;
|
|
260
259
|
},
|
|
261
260
|
next: () => {
|
|
262
|
-
const b =
|
|
263
|
-
return b &&
|
|
261
|
+
const b = o.shift();
|
|
262
|
+
return b && i.set(b.normalized, {
|
|
264
263
|
url: b.url,
|
|
265
264
|
depth: b.depth,
|
|
266
265
|
source: b.source
|
|
@@ -268,30 +267,30 @@ const he = (t) => {
|
|
|
268
267
|
},
|
|
269
268
|
skip: (b, p) => {
|
|
270
269
|
for (const x of b) {
|
|
271
|
-
const w =
|
|
270
|
+
const w = E(x);
|
|
272
271
|
r.set(w, p);
|
|
273
272
|
}
|
|
274
|
-
const y = new Set(b.map(
|
|
275
|
-
return
|
|
273
|
+
const y = new Set(b.map(E)), f = o.length, S = o.filter((x) => !y.has(x.normalized));
|
|
274
|
+
return o.length = 0, o.push(...S), f - S.length;
|
|
276
275
|
},
|
|
277
276
|
pendingByPrefix: (b = 2) => {
|
|
278
277
|
const p = /* @__PURE__ */ new Map();
|
|
279
|
-
for (const y of
|
|
280
|
-
const f =
|
|
278
|
+
for (const y of o) {
|
|
279
|
+
const f = Se(y.url, b), S = p.get(f) || [];
|
|
281
280
|
S.push(y), p.set(f, S);
|
|
282
281
|
}
|
|
283
282
|
return p;
|
|
284
283
|
},
|
|
285
|
-
size: () =>
|
|
286
|
-
visitedCount: () =>
|
|
287
|
-
isEmpty: () =>
|
|
284
|
+
size: () => o.length,
|
|
285
|
+
visitedCount: () => i.size,
|
|
286
|
+
isEmpty: () => o.length === 0,
|
|
288
287
|
summary: () => ({
|
|
289
|
-
pending:
|
|
290
|
-
visited:
|
|
288
|
+
pending: o.length,
|
|
289
|
+
visited: i.size,
|
|
291
290
|
skipped: r.size,
|
|
292
291
|
seen: c.size
|
|
293
292
|
}),
|
|
294
|
-
visitedUrls: () => [...
|
|
293
|
+
visitedUrls: () => [...i.entries()].map(([b, p]) => ({
|
|
295
294
|
normalized: b,
|
|
296
295
|
...p
|
|
297
296
|
})),
|
|
@@ -312,37 +311,37 @@ const he = (t) => {
|
|
|
312
311
|
// up to 6 retries (~5m20s total at 2x backoff from 5s)
|
|
313
312
|
jitter: 0.2
|
|
314
313
|
// ±20% randomization to avoid thundering herd
|
|
315
|
-
},
|
|
314
|
+
}, ve = async (t) => {
|
|
316
315
|
const a = t.url(), e = await t.evaluate(() => document.body?.innerText?.slice(0, 500)).catch(() => "");
|
|
317
316
|
if (e.includes("Access Denied")) return "access-denied";
|
|
318
317
|
if (e.includes("Rate limit") || e.includes("Too many requests")) return "rate-limit";
|
|
319
318
|
if (e.includes("Please verify you are a human")) return "captcha";
|
|
320
319
|
if (e.includes("Checking your browser")) return "challenge";
|
|
321
320
|
if (a.includes("errors.edgesuite.net")) return "akamai-block";
|
|
322
|
-
},
|
|
321
|
+
}, Ie = (t, a) => {
|
|
323
322
|
const e = t * a;
|
|
324
323
|
return t + (Math.random() * 2 - 1) * e;
|
|
325
|
-
},
|
|
324
|
+
}, Ce = (t, a) => {
|
|
326
325
|
const e = a.baseDelay * Math.pow(a.backoffFactor, t), s = Math.min(e, a.maxDelay);
|
|
327
|
-
return Math.round(
|
|
328
|
-
},
|
|
329
|
-
const n = Date.now(),
|
|
330
|
-
let
|
|
331
|
-
for (;
|
|
332
|
-
const r = t -
|
|
333
|
-
await new Promise((u) => setTimeout(u, c)),
|
|
326
|
+
return Math.round(Ie(s, a.jitter));
|
|
327
|
+
}, ke = async (t, a, e, s) => {
|
|
328
|
+
const n = Date.now(), o = n + t;
|
|
329
|
+
let i = 0;
|
|
330
|
+
for (; i < t; ) {
|
|
331
|
+
const r = t - i, c = Math.min(e, r);
|
|
332
|
+
await new Promise((u) => setTimeout(u, c)), i = Date.now() - n, a.emit({
|
|
334
333
|
event: "cooldown:tick",
|
|
335
|
-
elapsedMs:
|
|
336
|
-
remainingMs: Math.max(0,
|
|
334
|
+
elapsedMs: i,
|
|
335
|
+
remainingMs: Math.max(0, o - Date.now()),
|
|
337
336
|
totalMs: t,
|
|
338
337
|
...s
|
|
339
338
|
});
|
|
340
339
|
}
|
|
341
|
-
},
|
|
340
|
+
}, Ae = async (t, a, e, s, n, o, i) => {
|
|
342
341
|
const r = { ...Z, ...n };
|
|
343
342
|
let c = 0;
|
|
344
343
|
for (let u = 0; u <= r.maxRetries; u++) {
|
|
345
|
-
const m = await t(a, e), h = await
|
|
344
|
+
const m = await t(a, e), h = await o(a);
|
|
346
345
|
if (!h)
|
|
347
346
|
return { pageData: m, retries: u, totalCooldownMs: c };
|
|
348
347
|
if (u >= r.maxRetries)
|
|
@@ -353,7 +352,7 @@ const he = (t) => {
|
|
|
353
352
|
attempts: u + 1,
|
|
354
353
|
totalCooldownMs: c
|
|
355
354
|
}), { pageData: m, retries: u, totalCooldownMs: c, blocked: h };
|
|
356
|
-
const l =
|
|
355
|
+
const l = Ce(u, r);
|
|
357
356
|
c += l, s.emit({
|
|
358
357
|
event: "cooldown:start",
|
|
359
358
|
url: e,
|
|
@@ -362,7 +361,7 @@ const he = (t) => {
|
|
|
362
361
|
maxRetries: r.maxRetries,
|
|
363
362
|
delayMs: l,
|
|
364
363
|
totalCooldownMs: c
|
|
365
|
-
}), await
|
|
364
|
+
}), await ke(l, s, i, {
|
|
366
365
|
url: e,
|
|
367
366
|
reason: h,
|
|
368
367
|
attempt: u + 1
|
|
@@ -372,7 +371,7 @@ const he = (t) => {
|
|
|
372
371
|
attempt: u + 1
|
|
373
372
|
});
|
|
374
373
|
}
|
|
375
|
-
},
|
|
374
|
+
}, Pe = (t, a, e) => {
|
|
376
375
|
const s = setInterval(() => {
|
|
377
376
|
t.emit({
|
|
378
377
|
event: "heartbeat",
|
|
@@ -382,7 +381,7 @@ const he = (t) => {
|
|
|
382
381
|
return {
|
|
383
382
|
stop: () => clearInterval(s)
|
|
384
383
|
};
|
|
385
|
-
}, q = "site-crawl",
|
|
384
|
+
}, q = "site-crawl", Ee = "Browser support is disabled. Call init({ browser: true }) to enable.", Re = (t, a) => {
|
|
386
385
|
const e = a.summary(), s = t.map((n) => `${new URL(n.url).pathname} — ${n.meta.title || "(no title)"} [${n.links.length} links, ${n.forms.length} forms, ${n.buttons.length} buttons]`);
|
|
387
386
|
return [
|
|
388
387
|
`Crawled ${e.visited} pages, ${e.pending} pending, ${e.skipped} skipped.`,
|
|
@@ -391,11 +390,11 @@ const he = (t) => {
|
|
|
391
390
|
...s.map((n) => ` ${n}`)
|
|
392
391
|
].join(`
|
|
393
392
|
`);
|
|
394
|
-
},
|
|
393
|
+
}, Te = (t, a, e) => {
|
|
395
394
|
const s = [];
|
|
396
|
-
for (const [n,
|
|
397
|
-
const
|
|
398
|
-
s.push(` ${n} (${
|
|
395
|
+
for (const [n, o] of t) {
|
|
396
|
+
const i = o.slice(0, 5).map((c) => ` ${c.url}`), r = o.length > 5 ? ` ... and ${o.length - 5} more` : "";
|
|
397
|
+
s.push(` ${n} (${o.length} URLs):`), s.push(...i), r && s.push(r);
|
|
399
398
|
}
|
|
400
399
|
return [
|
|
401
400
|
"You are a site crawler deciding which URL branches to explore next.",
|
|
@@ -413,7 +412,7 @@ const he = (t) => {
|
|
|
413
412
|
"Skip groups that are clearly non-functional (help/support, legal, marketing pages)."
|
|
414
413
|
].join(`
|
|
415
414
|
`);
|
|
416
|
-
},
|
|
415
|
+
}, De = Y("crawl_gate", {
|
|
417
416
|
type: "object",
|
|
418
417
|
properties: {
|
|
419
418
|
decisions: {
|
|
@@ -440,12 +439,12 @@ const he = (t) => {
|
|
|
440
439
|
},
|
|
441
440
|
required: ["decisions"],
|
|
442
441
|
additionalProperties: !1
|
|
443
|
-
}),
|
|
442
|
+
}), $e = async (t, a, e, s) => {
|
|
444
443
|
const n = t.pendingByPrefix(2);
|
|
445
444
|
if (n.size === 0) return { explore: [], skip: [], decisions: [] };
|
|
446
|
-
const
|
|
445
|
+
const o = Re(a, t), i = Te(n, o, e), c = (await U(i, {
|
|
447
446
|
...s,
|
|
448
|
-
response_format:
|
|
447
|
+
response_format: De,
|
|
449
448
|
temperature: 0.2
|
|
450
449
|
}))?.decisions || [], u = [], m = [];
|
|
451
450
|
for (const h of c) {
|
|
@@ -461,37 +460,37 @@ const he = (t) => {
|
|
|
461
460
|
for (const [h, l] of n)
|
|
462
461
|
c.some((g) => g.prefix === h) || (u.push(l[0].url), l.length > 1 && m.push(...l.slice(1).map((g) => g.url)));
|
|
463
462
|
return { explore: u, skip: m, decisions: c };
|
|
464
|
-
},
|
|
463
|
+
}, Le = async (t, a, e, s, n, o) => {
|
|
465
464
|
await t.goto(a, { waitUntil: "domcontentloaded", timeout: 3e4 }), await t.waitForTimeout(1500);
|
|
466
|
-
const
|
|
465
|
+
const i = await we(t);
|
|
467
466
|
if (n.screenshots) {
|
|
468
467
|
const c = `${s.dir}/crawl-${Date.now()}.png`;
|
|
469
468
|
if (await t.screenshot({ path: c, fullPage: !1 }), s.track(c), n.imageShrink) {
|
|
470
|
-
const u = await
|
|
469
|
+
const u = await ie(c, {
|
|
471
470
|
...n.imageShrink,
|
|
472
471
|
outputDir: s.dir
|
|
473
472
|
});
|
|
474
|
-
s.track(u.path),
|
|
473
|
+
s.track(u.path), i.screenshot = u.path;
|
|
475
474
|
} else
|
|
476
|
-
|
|
475
|
+
i.screenshot = c;
|
|
477
476
|
}
|
|
478
477
|
const r = e.responses();
|
|
479
|
-
return
|
|
478
|
+
return i.apis = r.filter((c) => {
|
|
480
479
|
const u = c.url();
|
|
481
480
|
return u.includes("/api/") || u.includes("/v1/") || u.includes("/v2/") || u.includes("/graphql");
|
|
482
481
|
}).map((c) => ({
|
|
483
482
|
url: c.url(),
|
|
484
483
|
status: c.status(),
|
|
485
484
|
method: c.request().method()
|
|
486
|
-
})), e.clear(),
|
|
487
|
-
},
|
|
485
|
+
})), e.clear(), i;
|
|
486
|
+
}, Fe = (t) => {
|
|
488
487
|
const a = {};
|
|
489
488
|
for (const e of t) {
|
|
490
489
|
const s = e.links.filter((n) => n.isSameDomain && !n.isAnchor).map((n) => n.href);
|
|
491
490
|
a[e.url] = [...new Set(s)];
|
|
492
491
|
}
|
|
493
492
|
return a;
|
|
494
|
-
},
|
|
493
|
+
}, Me = (t) => {
|
|
495
494
|
const a = /* @__PURE__ */ new Map();
|
|
496
495
|
for (const e of t)
|
|
497
496
|
for (const s of e.apis || []) {
|
|
@@ -499,11 +498,11 @@ const he = (t) => {
|
|
|
499
498
|
a.has(n) ? a.get(n).seenOn.push(e.url) : a.set(n, { ...s, seenOn: [e.url] });
|
|
500
499
|
}
|
|
501
500
|
return [...a.values()];
|
|
502
|
-
},
|
|
503
|
-
if (!
|
|
501
|
+
}, St = async (t, a = {}) => {
|
|
502
|
+
if (!re()) throw new Error(Ee);
|
|
504
503
|
const e = $(q, a), s = L(q, e.onProgress, e);
|
|
505
504
|
s.start();
|
|
506
|
-
const n = await
|
|
505
|
+
const n = await X(e, {
|
|
507
506
|
maxPages: 20,
|
|
508
507
|
maxDepth: 5,
|
|
509
508
|
sameDomain: !0,
|
|
@@ -511,12 +510,12 @@ const he = (t) => {
|
|
|
511
510
|
headless: !0,
|
|
512
511
|
screenshots: !1,
|
|
513
512
|
errorPosture: "resilient",
|
|
514
|
-
imageShrink: B(
|
|
513
|
+
imageShrink: B(de),
|
|
515
514
|
heartbeatInterval: 1e3
|
|
516
|
-
}),
|
|
515
|
+
}), o = { ...Z, ...e.cooldown }, i = e.isBlocked || ve, r = xe(t, {
|
|
517
516
|
sameDomain: n.sameDomain,
|
|
518
517
|
maxDepth: n.maxDepth
|
|
519
|
-
}), c = await
|
|
518
|
+
}), c = await oe("site-crawl", e.outputDir), m = await (e.browserEngine ? j[e.browserEngine] : j.chromium).launch({
|
|
520
519
|
headless: n.headless,
|
|
521
520
|
...e.launchOptions
|
|
522
521
|
});
|
|
@@ -537,7 +536,7 @@ const he = (t) => {
|
|
|
537
536
|
};
|
|
538
537
|
})(), g = [];
|
|
539
538
|
let v = 0, C = t;
|
|
540
|
-
const P =
|
|
539
|
+
const P = Pe(s, n.heartbeatInterval, () => ({
|
|
541
540
|
pagesVisited: g.length,
|
|
542
541
|
maxPages: n.maxPages,
|
|
543
542
|
pending: r.size(),
|
|
@@ -549,7 +548,7 @@ const he = (t) => {
|
|
|
549
548
|
if (g.length > 0 && g.length % n.gateInterval === 0 && r.size() > 0) {
|
|
550
549
|
const y = n.maxPages - g.length;
|
|
551
550
|
s.emit({ event: "gate:start", pending: r.size(), budget: y });
|
|
552
|
-
const f = await
|
|
551
|
+
const f = await $e(r, g, y, e);
|
|
553
552
|
v++, f.skip.length > 0 && r.skip(f.skip, "llm-gate"), s.emit({
|
|
554
553
|
event: "gate:complete",
|
|
555
554
|
explored: f.explore.length,
|
|
@@ -567,13 +566,13 @@ const he = (t) => {
|
|
|
567
566
|
maxPages: n.maxPages
|
|
568
567
|
});
|
|
569
568
|
try {
|
|
570
|
-
const y = (w,
|
|
569
|
+
const y = (w, M) => Le(w, M, d, c, n, s), { pageData: f, blocked: S } = await Ae(
|
|
571
570
|
y,
|
|
572
571
|
l,
|
|
573
572
|
p.url,
|
|
574
573
|
s,
|
|
575
|
-
i,
|
|
576
574
|
o,
|
|
575
|
+
i,
|
|
577
576
|
n.heartbeatInterval
|
|
578
577
|
);
|
|
579
578
|
f.depth = p.depth, f.source = p.source, S && (f.blocked = S), g.push(f);
|
|
@@ -607,9 +606,9 @@ const he = (t) => {
|
|
|
607
606
|
s.emit({ event: "teardown" });
|
|
608
607
|
}
|
|
609
608
|
await h.close();
|
|
610
|
-
const
|
|
609
|
+
const z = Fe(g), F = Me(g), b = {
|
|
611
610
|
pages: g,
|
|
612
|
-
graph:
|
|
611
|
+
graph: z,
|
|
613
612
|
apis: F,
|
|
614
613
|
frontier: r.summary(),
|
|
615
614
|
skipped: r.skippedUrls(),
|
|
@@ -628,11 +627,11 @@ const he = (t) => {
|
|
|
628
627
|
} finally {
|
|
629
628
|
await m.close();
|
|
630
629
|
}
|
|
631
|
-
}, ee = 1,
|
|
630
|
+
}, ee = 1, R = 20, T = 5, Ne = 0.5, _e = 5, V = 8e3, _ = 5, D = {
|
|
632
631
|
INDIVIDUAL: "individual",
|
|
633
632
|
BULK: "bulk"
|
|
634
|
-
},
|
|
635
|
-
function
|
|
633
|
+
}, Be = (t) => t === void 0 ? R : typeof t == "number" ? t : { small: 10, med: R, large: 40 }[t] ?? R, Ue = (t) => t === void 0 ? T : typeof t == "number" ? t : { low: 2, med: T, high: 10 }[t] ?? T;
|
|
634
|
+
function Oe(t, a) {
|
|
636
635
|
const e = [];
|
|
637
636
|
for (let s = 0; s < t.length; s += a)
|
|
638
637
|
e.push({
|
|
@@ -642,7 +641,7 @@ function qe(t, a) {
|
|
|
642
641
|
});
|
|
643
642
|
return e;
|
|
644
643
|
}
|
|
645
|
-
function W(t, a, e, s, n,
|
|
644
|
+
function W(t, a, e, s, n, o) {
|
|
646
645
|
return {
|
|
647
646
|
chunkIndex: t.index,
|
|
648
647
|
totalChunks: a,
|
|
@@ -651,64 +650,64 @@ function W(t, a, e, s, n, i) {
|
|
|
651
650
|
status: s,
|
|
652
651
|
bulkSize: n.bulkSize,
|
|
653
652
|
maxConcurrency: n.maxConcurrency,
|
|
654
|
-
processingMode:
|
|
653
|
+
processingMode: o,
|
|
655
654
|
parallelMode: !0
|
|
656
655
|
};
|
|
657
656
|
}
|
|
658
|
-
async function
|
|
657
|
+
async function ze(t, a, e, s, n, o = {}) {
|
|
659
658
|
try {
|
|
660
|
-
const
|
|
659
|
+
const i = e.map((m) => ae(m(t))).filter(Boolean).join(`
|
|
661
660
|
|
|
662
|
-
`), r = [a,
|
|
661
|
+
`), r = [a, i].filter(Boolean).join(`
|
|
663
662
|
|
|
664
|
-
`), c =
|
|
665
|
-
...
|
|
663
|
+
`), c = Qe(r, t, s, n === "files"), u = await U(c, {
|
|
664
|
+
...o,
|
|
666
665
|
response_format: {
|
|
667
666
|
type: "json_schema",
|
|
668
667
|
json_schema: {
|
|
669
668
|
name: "arch_result",
|
|
670
|
-
schema:
|
|
669
|
+
schema: Ke
|
|
671
670
|
}
|
|
672
671
|
}
|
|
673
672
|
});
|
|
674
673
|
return { item: t, ...u, error: void 0 };
|
|
675
|
-
} catch (
|
|
676
|
-
return { item: t, passed: !1, reason: `Analysis failed: ${
|
|
674
|
+
} catch (i) {
|
|
675
|
+
return { item: t, passed: !1, reason: `Analysis failed: ${i.message}`, error: i };
|
|
677
676
|
}
|
|
678
677
|
}
|
|
679
|
-
function
|
|
680
|
-
const n = [],
|
|
681
|
-
let
|
|
678
|
+
function je(t, a, e, s) {
|
|
679
|
+
const n = [], o = [];
|
|
680
|
+
let i = s;
|
|
682
681
|
for (const r of t)
|
|
683
|
-
if (n.push(r), r.passed || (
|
|
682
|
+
if (n.push(r), r.passed || (i++, o.push(r.error || new Error(r.reason))), !a && i >= e)
|
|
684
683
|
break;
|
|
685
684
|
return {
|
|
686
685
|
results: n,
|
|
687
|
-
errors:
|
|
688
|
-
failures:
|
|
689
|
-
shouldStop: !a &&
|
|
686
|
+
errors: o,
|
|
687
|
+
failures: i,
|
|
688
|
+
shouldStop: !a && i >= e
|
|
690
689
|
};
|
|
691
690
|
}
|
|
692
691
|
function A(t, a, e, s) {
|
|
693
692
|
t && t(a, e, s);
|
|
694
693
|
}
|
|
695
|
-
async function te(t, a, e, s, n,
|
|
694
|
+
async function te(t, a, e, s, n, o = {}) {
|
|
696
695
|
A(s, t, void 0, {
|
|
697
696
|
...n,
|
|
698
697
|
status: k.start
|
|
699
698
|
});
|
|
700
699
|
try {
|
|
701
|
-
const
|
|
702
|
-
...
|
|
700
|
+
const i = Ze(a, t, e), r = {
|
|
701
|
+
...o,
|
|
703
702
|
responseFormat: {
|
|
704
703
|
type: "json_schema",
|
|
705
704
|
json_schema: {
|
|
706
705
|
name: "arch_bulk_result",
|
|
707
|
-
schema:
|
|
706
|
+
schema: Xe
|
|
708
707
|
}
|
|
709
708
|
},
|
|
710
|
-
onProgress: Q(
|
|
711
|
-
}, c = await
|
|
709
|
+
onProgress: Q(o.onProgress, "reduce")
|
|
710
|
+
}, c = await ce(t, i, r), u = c.results || c;
|
|
712
711
|
let m = [];
|
|
713
712
|
Array.isArray(u) ? m = u : m = t.map((d) => ({
|
|
714
713
|
path: d,
|
|
@@ -727,34 +726,34 @@ async function te(t, a, e, s, n, i = {}) {
|
|
|
727
726
|
failed: h
|
|
728
727
|
}
|
|
729
728
|
), m;
|
|
730
|
-
} catch (
|
|
729
|
+
} catch (i) {
|
|
731
730
|
const r = t.map((c) => ({
|
|
732
731
|
path: c,
|
|
733
732
|
passed: !1,
|
|
734
|
-
reason: `Processing error: ${
|
|
733
|
+
reason: `Processing error: ${i.message}`
|
|
735
734
|
}));
|
|
736
|
-
return A(s, t,
|
|
735
|
+
return A(s, t, i, {
|
|
737
736
|
...n,
|
|
738
737
|
status: k.error
|
|
739
738
|
}), r;
|
|
740
739
|
}
|
|
741
740
|
}
|
|
742
|
-
function
|
|
743
|
-
const e = a.filter((r) => r.passed).length, s = a.length - e, n = s === 0,
|
|
741
|
+
function qe(t, a) {
|
|
742
|
+
const e = a.filter((r) => r.passed).length, s = a.length - e, n = s === 0, o = a.length < t.length, i = a.filter((r) => !r.passed);
|
|
744
743
|
return {
|
|
745
744
|
passed: e,
|
|
746
745
|
failed: s,
|
|
747
746
|
allPassed: n,
|
|
748
|
-
stoppedEarly:
|
|
749
|
-
failures:
|
|
747
|
+
stoppedEarly: o,
|
|
748
|
+
failures: i,
|
|
750
749
|
total: t.length,
|
|
751
750
|
processed: a.length
|
|
752
751
|
};
|
|
753
752
|
}
|
|
754
|
-
function
|
|
753
|
+
function Ve(t, a, e) {
|
|
755
754
|
if (t.allPassed)
|
|
756
755
|
return `All ${t.processed}/${t.total} items satisfy: ${a}`;
|
|
757
|
-
const s = t.failures.slice(0, _).map((
|
|
756
|
+
const s = t.failures.slice(0, _).map((o) => ` • ${o.item}: ${o.reason || "Failed"}`).join(`
|
|
758
757
|
`), n = t.failures.length > _ ? `
|
|
759
758
|
... and ${t.failures.length - _} more failures` : "";
|
|
760
759
|
return `${t.failed}/${t.processed} items failed: ${a}${t.stoppedEarly && e !== ee ? ` (stopped after ${e} failures)` : ""}
|
|
@@ -762,7 +761,7 @@ function He(t, a, e) {
|
|
|
762
761
|
Failures:
|
|
763
762
|
${s}${n}`;
|
|
764
763
|
}
|
|
765
|
-
function
|
|
764
|
+
function We(t, a) {
|
|
766
765
|
return {
|
|
767
766
|
passed: t.allPassed,
|
|
768
767
|
message: a,
|
|
@@ -775,14 +774,14 @@ function Je(t, a) {
|
|
|
775
774
|
}
|
|
776
775
|
};
|
|
777
776
|
}
|
|
778
|
-
function
|
|
779
|
-
const n = a || e.length > 0 || s <=
|
|
777
|
+
function Ge(t, a, e, s) {
|
|
778
|
+
const n = a || e.length > 0 || s <= _e;
|
|
780
779
|
return {
|
|
781
780
|
mode: n ? D.INDIVIDUAL : D.BULK,
|
|
782
781
|
batchSize: n ? t.maxConcurrency : t.bulkSize,
|
|
783
|
-
processor: n ? (
|
|
784
|
-
|
|
785
|
-
|
|
782
|
+
processor: n ? (o, i, r) => se(o, i, r) : (o, i, r) => te(
|
|
783
|
+
o.items,
|
|
784
|
+
i,
|
|
786
785
|
r.description,
|
|
787
786
|
r.onProgress,
|
|
788
787
|
r.metadata
|
|
@@ -791,7 +790,7 @@ function Xe(t, a, e, s) {
|
|
|
791
790
|
}
|
|
792
791
|
async function se(t, a, e) {
|
|
793
792
|
const s = t.items.map(
|
|
794
|
-
(n) =>
|
|
793
|
+
(n) => ze(
|
|
795
794
|
n,
|
|
796
795
|
a,
|
|
797
796
|
e.itemContextFns,
|
|
@@ -802,9 +801,9 @@ async function se(t, a, e) {
|
|
|
802
801
|
);
|
|
803
802
|
return await Promise.all(s);
|
|
804
803
|
}
|
|
805
|
-
function
|
|
804
|
+
function He(t, a, e) {
|
|
806
805
|
if (a === D.INDIVIDUAL) {
|
|
807
|
-
const { results: s, errors: n, failures:
|
|
806
|
+
const { results: s, errors: n, failures: o, shouldStop: i } = je(
|
|
808
807
|
t,
|
|
809
808
|
e.isCoverageTest,
|
|
810
809
|
e.maxFailures,
|
|
@@ -813,8 +812,8 @@ function Ke(t, a, e) {
|
|
|
813
812
|
return {
|
|
814
813
|
results: s,
|
|
815
814
|
errors: n,
|
|
816
|
-
failures:
|
|
817
|
-
shouldStop:
|
|
815
|
+
failures: o,
|
|
816
|
+
shouldStop: i,
|
|
818
817
|
progressData: {
|
|
819
818
|
passed: s.filter((r) => r.passed).length,
|
|
820
819
|
failed: n.length
|
|
@@ -838,11 +837,11 @@ function Ke(t, a, e) {
|
|
|
838
837
|
};
|
|
839
838
|
}
|
|
840
839
|
}
|
|
841
|
-
async function
|
|
842
|
-
const n =
|
|
843
|
-
let
|
|
840
|
+
async function Je(t, a, e, s) {
|
|
841
|
+
const n = Oe(t, e.batchSize), o = [];
|
|
842
|
+
let i = 0;
|
|
844
843
|
for (const r of n) {
|
|
845
|
-
if (!s.isCoverageTest &&
|
|
844
|
+
if (!s.isCoverageTest && i >= s.maxFailures)
|
|
846
845
|
break;
|
|
847
846
|
const c = W(
|
|
848
847
|
r,
|
|
@@ -866,11 +865,11 @@ async function Ye(t, a, e, s) {
|
|
|
866
865
|
c,
|
|
867
866
|
s.runConfig
|
|
868
867
|
);
|
|
869
|
-
const m =
|
|
868
|
+
const m = He(u, e.mode, {
|
|
870
869
|
...s,
|
|
871
|
-
currentFailures:
|
|
870
|
+
currentFailures: i
|
|
872
871
|
});
|
|
873
|
-
if (
|
|
872
|
+
if (o.push(...m.results), i = m.failures, A(
|
|
874
873
|
s.onChunkProcessed,
|
|
875
874
|
r.items,
|
|
876
875
|
m.errors.length > 0 ? m.errors[0] : void 0,
|
|
@@ -888,16 +887,16 @@ async function Ye(t, a, e, s) {
|
|
|
888
887
|
), m.shouldStop)
|
|
889
888
|
break;
|
|
890
889
|
}
|
|
891
|
-
return
|
|
890
|
+
return o;
|
|
892
891
|
}
|
|
893
|
-
const
|
|
892
|
+
const Ke = {
|
|
894
893
|
type: "object",
|
|
895
894
|
properties: {
|
|
896
895
|
passed: { type: "boolean" },
|
|
897
896
|
reason: { type: "string" }
|
|
898
897
|
},
|
|
899
898
|
required: ["passed", "reason"]
|
|
900
|
-
},
|
|
899
|
+
}, Xe = {
|
|
901
900
|
type: "object",
|
|
902
901
|
properties: {
|
|
903
902
|
results: {
|
|
@@ -938,7 +937,7 @@ ${a}
|
|
|
938
937
|
return "";
|
|
939
938
|
}
|
|
940
939
|
}
|
|
941
|
-
function
|
|
940
|
+
function Ye(t) {
|
|
942
941
|
if (!I.existsSync(t)) return "Item does not exist";
|
|
943
942
|
if (I.statSync(t).isDirectory())
|
|
944
943
|
return I.readdirSync(t).join(", ");
|
|
@@ -948,8 +947,8 @@ function et(t) {
|
|
|
948
947
|
... (truncated)` : e;
|
|
949
948
|
}
|
|
950
949
|
}
|
|
951
|
-
function
|
|
952
|
-
const n =
|
|
950
|
+
function Qe(t, a, e, s) {
|
|
951
|
+
const n = Ye(a);
|
|
953
952
|
return `${t}
|
|
954
953
|
Analyze this ${s ? "file" : "directory"}: ${a}
|
|
955
954
|
|
|
@@ -960,16 +959,16 @@ Does it satisfy: "${e}"?
|
|
|
960
959
|
|
|
961
960
|
Return JSON with "passed" (boolean) and "reason" (string).`;
|
|
962
961
|
}
|
|
963
|
-
function
|
|
962
|
+
function Ze(t, a, e) {
|
|
964
963
|
return `${t}
|
|
965
964
|
Analyze each item and determine if it satisfies: "${e}"
|
|
966
965
|
Items: ${a.join(", ")}
|
|
967
966
|
|
|
968
967
|
Return JSON with "results" array containing objects with "path", "passed" (boolean), and "reason" (string).`;
|
|
969
968
|
}
|
|
970
|
-
class
|
|
969
|
+
class et {
|
|
971
970
|
constructor(a, e = {}) {
|
|
972
|
-
this.target = a, this.options = e, this.contexts = [], this.itemContextFns = [], this.maxFailures = e.maxFailures || ee, this.bulkSize = e.bulkSize ||
|
|
971
|
+
this.target = a, this.options = e, this.contexts = [], this.itemContextFns = [], this.maxFailures = e.maxFailures || ee, this.bulkSize = e.bulkSize || R, this.maxConcurrency = e.maxConcurrency || T, this.onChunkProcessed = void 0, this.description = void 0, this.threshold = void 0, this.isCoverageTest = !1;
|
|
973
972
|
}
|
|
974
973
|
withContext(a) {
|
|
975
974
|
return this.contexts.push(a), this;
|
|
@@ -982,7 +981,7 @@ class at {
|
|
|
982
981
|
return this.description = a, this;
|
|
983
982
|
}
|
|
984
983
|
// Set up for a coverage test
|
|
985
|
-
coverage(a =
|
|
984
|
+
coverage(a = Ne) {
|
|
986
985
|
return this.threshold = a, this.isCoverageTest = !0, this;
|
|
987
986
|
}
|
|
988
987
|
// Start processing - this is the fluent terminator
|
|
@@ -994,17 +993,17 @@ class at {
|
|
|
994
993
|
throw new Error("Must call satisfies() before start()");
|
|
995
994
|
const s = await this.target.resolve(), n = this.contexts.map(ae).filter(Boolean).join(`
|
|
996
995
|
|
|
997
|
-
`),
|
|
996
|
+
`), o = Ge(
|
|
998
997
|
this,
|
|
999
998
|
this.onChunkProcessed,
|
|
1000
999
|
this.itemContextFns,
|
|
1001
1000
|
s.length
|
|
1002
|
-
), { bulkSize:
|
|
1003
|
-
bulkSize: B(
|
|
1004
|
-
maxConcurrency: B(
|
|
1001
|
+
), { bulkSize: i, maxConcurrency: r, maxFailures: c } = await X(a, {
|
|
1002
|
+
bulkSize: B(Be),
|
|
1003
|
+
maxConcurrency: B(Ue),
|
|
1005
1004
|
maxFailures: this.maxFailures
|
|
1006
1005
|
}), u = {
|
|
1007
|
-
bulkSize:
|
|
1006
|
+
bulkSize: i,
|
|
1008
1007
|
maxConcurrency: r,
|
|
1009
1008
|
description: this.description,
|
|
1010
1009
|
onChunkProcessed: this.onChunkProcessed,
|
|
@@ -1013,7 +1012,7 @@ class at {
|
|
|
1013
1012
|
maxFailures: c,
|
|
1014
1013
|
isCoverageTest: this.isCoverageTest,
|
|
1015
1014
|
runConfig: a
|
|
1016
|
-
}, m = e.batch(s.length), h = await
|
|
1015
|
+
}, m = e.batch(s.length), h = await Je(s, n, o, u);
|
|
1017
1016
|
if (m(h.length), this.isCoverageTest) {
|
|
1018
1017
|
const d = h.filter((P) => P.passed).length, g = s.length > 0 ? d / s.length : 0, v = g >= this.threshold, C = `Coverage: ${d}/${s.length} (${(g * 100).toFixed(1)}%) - ${v ? "meets" : "below"} ${(this.threshold * 100).toFixed(1)}% threshold`;
|
|
1019
1018
|
if (!v)
|
|
@@ -1027,16 +1026,16 @@ class at {
|
|
|
1027
1026
|
}
|
|
1028
1027
|
}
|
|
1029
1028
|
summarize(a, e) {
|
|
1030
|
-
const s =
|
|
1029
|
+
const s = qe(a, e), n = Ve(s, this.description, this.maxFailures);
|
|
1031
1030
|
if (!s.allPassed)
|
|
1032
1031
|
throw new Error(n);
|
|
1033
|
-
return
|
|
1032
|
+
return We(s, n);
|
|
1034
1033
|
}
|
|
1035
1034
|
}
|
|
1036
|
-
function
|
|
1037
|
-
return new
|
|
1035
|
+
function xt(t, a = {}) {
|
|
1036
|
+
return new et(t, a);
|
|
1038
1037
|
}
|
|
1039
|
-
function
|
|
1038
|
+
function vt() {
|
|
1040
1039
|
return console.warn("scanJS is not available in browser environment"), Promise.resolve({});
|
|
1041
1040
|
}
|
|
1042
1041
|
const G = {
|
|
@@ -1061,13 +1060,13 @@ const G = {
|
|
|
1061
1060
|
additionalProperties: !1
|
|
1062
1061
|
}
|
|
1063
1062
|
}, H = "test";
|
|
1064
|
-
async function
|
|
1063
|
+
async function tt(t, a, e = {}) {
|
|
1065
1064
|
const s = $(H, e), n = L(H, s.onProgress, s);
|
|
1066
1065
|
n.start();
|
|
1067
1066
|
try {
|
|
1068
|
-
const
|
|
1067
|
+
const o = await pe.readFile(t, "utf-8"), i = `Analyze this code and ${a}:
|
|
1069
1068
|
|
|
1070
|
-
${
|
|
1069
|
+
${le(o, { tag: "code-to-analyze" })}
|
|
1071
1070
|
|
|
1072
1071
|
Return a JSON object with:
|
|
1073
1072
|
- "hasIssues": boolean indicating if any issues were found
|
|
@@ -1078,8 +1077,8 @@ GUIDELINES:
|
|
|
1078
1077
|
- Provide specific line numbers or code references when possible
|
|
1079
1078
|
- Suggest concrete fixes for each issue identified
|
|
1080
1079
|
- Be concise but clear in your feedback
|
|
1081
|
-
- If no issues are found, return {"hasIssues": false, "issues": []}`, r = await
|
|
1082
|
-
() => U(
|
|
1080
|
+
- If no issues are found, return {"hasIssues": false, "issues": []}`, r = await ue(
|
|
1081
|
+
() => U(i, {
|
|
1083
1082
|
...s,
|
|
1084
1083
|
response_format: Y(G.name, G.schema)
|
|
1085
1084
|
}),
|
|
@@ -1089,285 +1088,291 @@ GUIDELINES:
|
|
|
1089
1088
|
}
|
|
1090
1089
|
), c = r.hasIssues ? r.issues : [];
|
|
1091
1090
|
return n.complete({ outcome: "success" }), c;
|
|
1092
|
-
} catch (
|
|
1093
|
-
throw n.error(
|
|
1091
|
+
} catch (o) {
|
|
1092
|
+
throw n.error(o), o;
|
|
1094
1093
|
}
|
|
1095
1094
|
}
|
|
1096
|
-
const J = "test-advice",
|
|
1095
|
+
const J = "test-advice", st = "Run the code with 5 boundary value test cases and report any that fail", at = "Identify 5 passing scenarios and significant boundary conditions in this code. Provide minimal input examples for each scenario to demonstrate correctness.", nt = "Identify 5 failing scenarios and significant boundary conditions in this code. Provide minimal input examples for each scenario to demonstrate the failure. Assume DBC, and don't complain when types are specified in jsDoc.", rt = "Identify 5 defects in this code. Provide minimal input examples to demonstrate each defect.", ot = "Suggest 5 best practices improvements for this code.", it = 'Suggest 5 "clean code" improvements for this code.', ct = "Identify 5 specific issues related to code quality, readability, and maintainability.", lt = "Suggest 5 refactors that would most improve the composibility of this code.", K = [
|
|
1096
|
+
st,
|
|
1097
|
+
at,
|
|
1098
|
+
nt,
|
|
1097
1099
|
rt,
|
|
1098
|
-
it,
|
|
1099
1100
|
ot,
|
|
1101
|
+
it,
|
|
1100
1102
|
ct,
|
|
1101
|
-
lt
|
|
1102
|
-
ut,
|
|
1103
|
-
pt,
|
|
1104
|
-
dt
|
|
1103
|
+
lt
|
|
1105
1104
|
];
|
|
1106
|
-
async function
|
|
1105
|
+
async function It(t, a = {}) {
|
|
1107
1106
|
const e = $(J, a), s = L(J, e.onProgress, e);
|
|
1108
1107
|
s.start();
|
|
1109
1108
|
try {
|
|
1110
|
-
const n = s.batch(
|
|
1111
|
-
for (const
|
|
1112
|
-
const r = await
|
|
1109
|
+
const n = s.batch(K.length), o = [];
|
|
1110
|
+
for (const i of K) {
|
|
1111
|
+
const r = await tt(t, i, {
|
|
1113
1112
|
...e,
|
|
1114
1113
|
onProgress: Q(e.onProgress, "test-advice:test")
|
|
1115
1114
|
});
|
|
1116
|
-
|
|
1115
|
+
o.push(...r), n(1);
|
|
1117
1116
|
}
|
|
1118
|
-
return s.complete({ outcome: "success", totalIssues:
|
|
1117
|
+
return s.complete({ outcome: "success", totalIssues: o.length }), o;
|
|
1119
1118
|
} catch (n) {
|
|
1120
1119
|
throw s.error(n), n;
|
|
1121
1120
|
}
|
|
1122
1121
|
}
|
|
1123
1122
|
ne.config();
|
|
1124
|
-
try {
|
|
1125
|
-
he(JSON.parse(re(ie(process.cwd(), ".verblets.json"), "utf8")));
|
|
1126
|
-
} catch {
|
|
1127
|
-
}
|
|
1128
1123
|
export {
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1124
|
+
At as CAPABILITY_KEYS,
|
|
1125
|
+
Pt as COMPLIANCE,
|
|
1126
|
+
Et as CONTEXT_KINDS,
|
|
1127
|
+
Rt as COST_POSTURE,
|
|
1128
|
+
Tt as ChainEvent,
|
|
1129
|
+
Dt as Conversation,
|
|
1130
|
+
$t as DOMAIN,
|
|
1131
|
+
Lt as DomainEvent,
|
|
1132
|
+
Ft as ENVIRONMENT,
|
|
1133
|
+
Mt as Kind,
|
|
1134
|
+
Nt as Level,
|
|
1135
|
+
_t as ListStyle,
|
|
1136
|
+
Bt as MODEL_KEYS,
|
|
1137
|
+
Ut as ModelService,
|
|
1138
|
+
Ot as ModelSource,
|
|
1139
|
+
k as OpEvent,
|
|
1140
|
+
zt as OptionSource,
|
|
1141
|
+
jt as QUALITY_INTENT,
|
|
1142
|
+
qt as SocraticMethod,
|
|
1143
|
+
Vt as StatusCode,
|
|
1144
|
+
Wt as SummaryMap,
|
|
1145
|
+
Gt as TelemetryEvent,
|
|
1146
|
+
Ht as TimedAbortController,
|
|
1147
|
+
xt as aiArchExpect,
|
|
1148
|
+
Jt as aiExpect,
|
|
1149
|
+
Kt as analyzeImage,
|
|
1150
|
+
Xt as analyzeImageMapDetail,
|
|
1151
|
+
Yt as anySignal,
|
|
1152
|
+
Qt as applyAllTargetingRules,
|
|
1153
|
+
Zt as applyCalibrate,
|
|
1154
|
+
es as applyEntities,
|
|
1155
|
+
ts as applyFirstTargetingRule,
|
|
1156
|
+
ss as applyRelations,
|
|
1157
|
+
as as applyScale,
|
|
1158
|
+
ns as applyScore,
|
|
1159
|
+
rs as applyTags,
|
|
1160
|
+
os as auto,
|
|
1161
|
+
is as bool,
|
|
1162
|
+
cs as buildSeedGenerationPrompt,
|
|
1163
|
+
ls as buildVisionPrompt,
|
|
1164
|
+
us as calculateStatistics,
|
|
1165
|
+
ps as calibrate,
|
|
1166
|
+
ds as calibrateSpec,
|
|
1167
|
+
ms as categorySamples,
|
|
1168
|
+
hs as causalFramePrompt,
|
|
1169
|
+
gs as centralTendency,
|
|
1170
|
+
fs as centralTendencyLines,
|
|
1171
|
+
bs as chunk,
|
|
1172
|
+
ys as chunkSentences,
|
|
1173
|
+
ws as classify,
|
|
1174
|
+
Ss as cleanupPaths,
|
|
1175
|
+
xs as collectTerms,
|
|
1176
|
+
vs as combinations,
|
|
1177
|
+
Is as commonalities,
|
|
1178
|
+
Cs as compact,
|
|
1179
|
+
ks as computeTagStatistics,
|
|
1180
|
+
As as config,
|
|
1181
|
+
Ps as constants,
|
|
1182
|
+
Es as conversationTurnReduce,
|
|
1183
|
+
Rs as cosineSimilarity,
|
|
1184
|
+
Ts as createBatches,
|
|
1185
|
+
Ds as createCalibratedClassifier,
|
|
1186
|
+
$s as createContextBuilder,
|
|
1187
|
+
Ls as createEntityExtractor,
|
|
1182
1188
|
L as createProgressEmitter,
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1189
|
+
Fs as createRelationExtractor,
|
|
1190
|
+
Ms as createScale,
|
|
1191
|
+
Ns as createTagExtractor,
|
|
1192
|
+
_s as createTagger,
|
|
1193
|
+
oe as createTempDir,
|
|
1194
|
+
Bs as createTraceCollector,
|
|
1195
|
+
Us as date,
|
|
1196
|
+
Os as debug,
|
|
1191
1197
|
U as default,
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1198
|
+
zs as descriptorToSchema,
|
|
1199
|
+
js as detectPatterns,
|
|
1200
|
+
qs as detectThreshold,
|
|
1201
|
+
Vs as determineStyle,
|
|
1202
|
+
Ws as disambiguate,
|
|
1203
|
+
Gs as dismantle,
|
|
1204
|
+
Hs as dismantleFactory,
|
|
1205
|
+
Js as documentShrink,
|
|
1206
|
+
Ks as embed,
|
|
1207
|
+
Xs as embedAssembleSpan,
|
|
1208
|
+
Ys as embedBatch,
|
|
1209
|
+
Qs as embedBuildIndex,
|
|
1210
|
+
Zs as embedChunked,
|
|
1211
|
+
ea as embedMergeRanges,
|
|
1212
|
+
ta as embedMultiQuery,
|
|
1213
|
+
sa as embedNeighborChunks,
|
|
1214
|
+
aa as embedNormalizeText,
|
|
1215
|
+
na as embedRewriteQuery,
|
|
1216
|
+
ra as embedRewriteToOutputDoc,
|
|
1217
|
+
oa as embedScore,
|
|
1218
|
+
ia as embedStandaloneSpan,
|
|
1219
|
+
ca as embedStepBack,
|
|
1220
|
+
la as embedSubquestions,
|
|
1221
|
+
ua as embedWarmup,
|
|
1222
|
+
pa as entities,
|
|
1223
|
+
da as entitiesFilterInstructions,
|
|
1224
|
+
ma as entitiesFindInstructions,
|
|
1225
|
+
ha as entitiesGroupInstructions,
|
|
1226
|
+
ga as entitiesMapInstructions,
|
|
1227
|
+
fa as entitiesReduceInstructions,
|
|
1228
|
+
ba as entitySpec,
|
|
1229
|
+
ya as evaluateTargetingClause,
|
|
1230
|
+
wa as evaluateTargetingRule,
|
|
1231
|
+
Sa as eventToTrace,
|
|
1232
|
+
xa as expect,
|
|
1233
|
+
va as extractBlocks,
|
|
1234
|
+
ge as extractButtons,
|
|
1235
|
+
he as extractForms,
|
|
1236
|
+
Ia as extractJson,
|
|
1237
|
+
me as extractLinks,
|
|
1238
|
+
be as extractMeta,
|
|
1239
|
+
we as extractPage,
|
|
1240
|
+
fe as extractScripts,
|
|
1241
|
+
ye as extractStructure,
|
|
1242
|
+
Ca as fillMissing,
|
|
1243
|
+
ka as filter,
|
|
1244
|
+
Aa as filterAmbiguous,
|
|
1245
|
+
Pa as find,
|
|
1246
|
+
Ea as generateList,
|
|
1247
|
+
Ra as getMeanings,
|
|
1248
|
+
Ta as getOption,
|
|
1249
|
+
Da as getOptionDetail,
|
|
1250
|
+
X as getOptions,
|
|
1251
|
+
$a as glossary,
|
|
1252
|
+
La as group,
|
|
1253
|
+
yt as imageToBase64,
|
|
1254
|
+
Fa as init,
|
|
1255
|
+
Ma as intent,
|
|
1256
|
+
Na as intersections,
|
|
1257
|
+
_a as join,
|
|
1258
|
+
Y as jsonSchema,
|
|
1259
|
+
Ba as last,
|
|
1260
|
+
Ua as list,
|
|
1261
|
+
Oa as listBatch,
|
|
1262
|
+
za as listExpand,
|
|
1257
1263
|
U as llm,
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
+
ja as llmLogger,
|
|
1265
|
+
qa as makePrompt,
|
|
1266
|
+
Va as map,
|
|
1267
|
+
de as mapImageShrink,
|
|
1268
|
+
Wa as name,
|
|
1269
|
+
Ga as nameSimilarTo,
|
|
1264
1270
|
$ as nameStep,
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1271
|
+
Ha as normalizeLlm,
|
|
1272
|
+
Ja as number,
|
|
1273
|
+
Ka as numberWithUnits,
|
|
1274
|
+
Xa as observeApplication,
|
|
1275
|
+
Ya as observeProviders,
|
|
1276
|
+
Qa as omit,
|
|
1277
|
+
Za as parallel,
|
|
1278
|
+
en as parallelMap,
|
|
1279
|
+
tn as parseLLMList,
|
|
1280
|
+
sn as parseRDFLiteral,
|
|
1281
|
+
an as parseRelations,
|
|
1282
|
+
nn as people,
|
|
1283
|
+
rn as phailForge,
|
|
1284
|
+
on as pick,
|
|
1285
|
+
cn as pipe,
|
|
1286
|
+
ln as popReference,
|
|
1287
|
+
un as probeScan,
|
|
1288
|
+
pn as promptCache,
|
|
1289
|
+
dn as promptPiece,
|
|
1290
|
+
mn as prompts,
|
|
1291
|
+
hn as questions,
|
|
1292
|
+
gn as rangeCombinations,
|
|
1293
|
+
ce as reduce,
|
|
1294
|
+
fn as relationSpec,
|
|
1295
|
+
bn as relations,
|
|
1296
|
+
yn as relationsFilterInstructions,
|
|
1297
|
+
wn as relationsFindInstructions,
|
|
1298
|
+
Sn as relationsGroupInstructions,
|
|
1299
|
+
xn as relationsMapInstructions,
|
|
1300
|
+
vn as relationsReduceInstructions,
|
|
1301
|
+
ft as resizeImage,
|
|
1302
|
+
In as resolveModel,
|
|
1303
|
+
Cn as resolveOutputDir,
|
|
1304
|
+
ue as retry,
|
|
1305
|
+
kn as ringBuffer,
|
|
1306
|
+
An as scale,
|
|
1307
|
+
Pn as scaleFilterInstructions,
|
|
1308
|
+
En as scaleFindInstructions,
|
|
1309
|
+
Rn as scaleGroupInstructions,
|
|
1310
|
+
Tn as scaleMapInstructions,
|
|
1311
|
+
Dn as scaleReduceInstructions,
|
|
1312
|
+
$n as scaleSpec,
|
|
1313
|
+
vt as scanJS,
|
|
1314
|
+
Ln as schemaOrg,
|
|
1315
|
+
Fn as schemas,
|
|
1316
|
+
Mn as scientificFramingPrompt,
|
|
1311
1317
|
Q as scopePhase,
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
Tr as withInactivityTimeout,
|
|
1318
|
+
Nn as score,
|
|
1319
|
+
_n as scoreFilterInstructions,
|
|
1320
|
+
Bn as scoreFindInstructions,
|
|
1321
|
+
Un as scoreGroupInstructions,
|
|
1322
|
+
On as scoreItem,
|
|
1323
|
+
zn as scoreMapInstructions,
|
|
1324
|
+
jn as scoreReduceInstructions,
|
|
1325
|
+
qn as scoreSpec,
|
|
1326
|
+
Vn as sentiment,
|
|
1327
|
+
Wn as setEmbedEnabled,
|
|
1328
|
+
Gn as setImageProcessingEnabled,
|
|
1329
|
+
Hn as setInterval,
|
|
1330
|
+
Jn as shuffle,
|
|
1331
|
+
Kn as simplifyTree,
|
|
1332
|
+
St as siteCrawl,
|
|
1333
|
+
Xn as socratic,
|
|
1334
|
+
Yn as softCoverPrompt,
|
|
1335
|
+
Qn as sort,
|
|
1336
|
+
Zn as sortBy,
|
|
1337
|
+
er as split,
|
|
1338
|
+
tr as stripNumeric,
|
|
1339
|
+
sr as stripResponse,
|
|
1340
|
+
ar as suggestTargetingRules,
|
|
1341
|
+
nr as tagSpec,
|
|
1342
|
+
rr as tagVocabulary,
|
|
1343
|
+
or as tags,
|
|
1344
|
+
ir as tagsFilterInstructions,
|
|
1345
|
+
cr as tagsFindInstructions,
|
|
1346
|
+
lr as tagsGroupInstructions,
|
|
1347
|
+
ur as tagsMapInstructions,
|
|
1348
|
+
pr as tagsReduceInstructions,
|
|
1349
|
+
dr as targetingClause,
|
|
1350
|
+
mr as targetingRule,
|
|
1351
|
+
hr as targetingRuleOps,
|
|
1352
|
+
gr as targetingRuleSchema,
|
|
1353
|
+
fr as templateReplace,
|
|
1354
|
+
tt as test,
|
|
1355
|
+
It as testAdvice,
|
|
1356
|
+
br as themes,
|
|
1357
|
+
bt as tileImages,
|
|
1358
|
+
yr as timeline,
|
|
1359
|
+
wr as toBool,
|
|
1360
|
+
Sr as toDate,
|
|
1361
|
+
xr as toEnum,
|
|
1362
|
+
vr as toNumber,
|
|
1363
|
+
Ir as toNumberWithUnits,
|
|
1364
|
+
Cr as toObject,
|
|
1365
|
+
kr as truncate,
|
|
1366
|
+
Ar as unionBy,
|
|
1367
|
+
Pr as validateTargetingRules,
|
|
1368
|
+
Er as valueArbitrate,
|
|
1369
|
+
Rr as vectorSearch,
|
|
1370
|
+
Tr as veiledVariantStrategies,
|
|
1371
|
+
Dr as veiledVariants,
|
|
1372
|
+
$r as version,
|
|
1373
|
+
wt as webScrape,
|
|
1374
|
+
Lr as windowFor,
|
|
1375
|
+
Fr as withInactivityTimeout,
|
|
1371
1376
|
B as withPolicy,
|
|
1372
|
-
|
|
1377
|
+
Mr as zipWith
|
|
1373
1378
|
};
|