agentv 0.15.0 → 0.17.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.
- package/README.md +8 -6
- package/dist/{chunk-D44RV4HN.js → chunk-BRXRFISD.js} +6 -6
- package/dist/chunk-BRXRFISD.js.map +1 -0
- package/dist/{chunk-LVLBPRCV.js → chunk-KL3Y2C6J.js} +761 -569
- package/dist/chunk-KL3Y2C6J.js.map +1 -0
- package/dist/{chunk-7XYYGJAC.js → chunk-UE4GLFVL.js} +3 -3
- package/dist/chunk-UE4GLFVL.js.map +1 -0
- package/dist/cli.js +2 -2
- package/dist/cli.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/templates/.claude/skills/agentv-eval-builder/references/config-schema.json +27 -27
- package/dist/templates/.claude/skills/agentv-eval-builder/references/eval-schema.json +217 -217
- package/dist/{token-O4PKPL7Y.js → token-S7Q7YUO6.js} +5 -5
- package/dist/token-S7Q7YUO6.js.map +1 -0
- package/dist/token-util-KCWYFARR.js +6 -0
- package/package.json +18 -18
- package/LICENSE +0 -21
- package/dist/chunk-7XYYGJAC.js.map +0 -1
- package/dist/chunk-D44RV4HN.js.map +0 -1
- package/dist/chunk-LVLBPRCV.js.map +0 -1
- package/dist/token-O4PKPL7Y.js.map +0 -1
- package/dist/token-util-SOXXDYPK.js +0 -6
- /package/dist/{token-util-SOXXDYPK.js.map → token-util-KCWYFARR.js.map} +0 -0
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
__export,
|
|
4
4
|
__toESM,
|
|
5
5
|
require_token_error
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-UE4GLFVL.js";
|
|
7
7
|
|
|
8
|
-
// ../../node_modules/.
|
|
8
|
+
// ../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/get-context.js
|
|
9
9
|
var require_get_context = __commonJS({
|
|
10
|
-
"../../node_modules/.
|
|
10
|
+
"../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/get-context.js"(exports, module) {
|
|
11
11
|
"use strict";
|
|
12
12
|
var __defProp2 = Object.defineProperty;
|
|
13
13
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -40,9 +40,9 @@ var require_get_context = __commonJS({
|
|
|
40
40
|
}
|
|
41
41
|
});
|
|
42
42
|
|
|
43
|
-
// ../../node_modules/.
|
|
43
|
+
// ../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/get-vercel-oidc-token.js
|
|
44
44
|
var require_get_vercel_oidc_token = __commonJS({
|
|
45
|
-
"../../node_modules/.
|
|
45
|
+
"../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/get-vercel-oidc-token.js"(exports, module) {
|
|
46
46
|
"use strict";
|
|
47
47
|
var __defProp2 = Object.defineProperty;
|
|
48
48
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -79,8 +79,8 @@ var require_get_vercel_oidc_token = __commonJS({
|
|
|
79
79
|
}
|
|
80
80
|
try {
|
|
81
81
|
const [{ getTokenPayload, isExpired }, { refreshToken }] = await Promise.all([
|
|
82
|
-
await import("./token-util-
|
|
83
|
-
await import("./token-
|
|
82
|
+
await import("./token-util-KCWYFARR.js"),
|
|
83
|
+
await import("./token-S7Q7YUO6.js")
|
|
84
84
|
]);
|
|
85
85
|
if (!token2 || isExpired(getTokenPayload(token2))) {
|
|
86
86
|
await refreshToken();
|
|
@@ -107,9 +107,9 @@ ${error40.message}`;
|
|
|
107
107
|
}
|
|
108
108
|
});
|
|
109
109
|
|
|
110
|
-
// ../../node_modules/.
|
|
110
|
+
// ../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/index.js
|
|
111
111
|
var require_dist = __commonJS({
|
|
112
|
-
"../../node_modules/.
|
|
112
|
+
"../../node_modules/.bun/@vercel+oidc@3.0.5/node_modules/@vercel/oidc/dist/index.js"(exports, module) {
|
|
113
113
|
"use strict";
|
|
114
114
|
var __defProp2 = Object.defineProperty;
|
|
115
115
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -141,20 +141,26 @@ var require_dist = __commonJS({
|
|
|
141
141
|
});
|
|
142
142
|
|
|
143
143
|
// src/index.ts
|
|
144
|
-
import { Command } from "commander";
|
|
145
144
|
import { readFileSync as readFileSync2 } from "node:fs";
|
|
145
|
+
import { Command } from "commander";
|
|
146
146
|
|
|
147
147
|
// src/commands/eval/index.ts
|
|
148
|
-
import fg from "fast-glob";
|
|
149
148
|
import { stat as stat3 } from "node:fs/promises";
|
|
150
149
|
import path19 from "node:path";
|
|
150
|
+
import fg from "fast-glob";
|
|
151
151
|
|
|
152
|
-
//
|
|
152
|
+
// src/commands/eval/run-eval.ts
|
|
153
|
+
import { constants as constants6 } from "node:fs";
|
|
154
|
+
import { access as access6, mkdir as mkdir6 } from "node:fs/promises";
|
|
155
|
+
import path18 from "node:path";
|
|
156
|
+
import { pathToFileURL } from "node:url";
|
|
157
|
+
|
|
158
|
+
// ../../packages/core/dist/chunk-YCIZ33BO.js
|
|
153
159
|
import { constants } from "node:fs";
|
|
154
160
|
import { access, readFile } from "node:fs/promises";
|
|
155
161
|
import path from "node:path";
|
|
156
162
|
|
|
157
|
-
// ../../node_modules/.
|
|
163
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/external.js
|
|
158
164
|
var external_exports = {};
|
|
159
165
|
__export(external_exports, {
|
|
160
166
|
BRAND: () => BRAND,
|
|
@@ -266,7 +272,7 @@ __export(external_exports, {
|
|
|
266
272
|
void: () => voidType
|
|
267
273
|
});
|
|
268
274
|
|
|
269
|
-
// ../../node_modules/.
|
|
275
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/util.js
|
|
270
276
|
var util;
|
|
271
277
|
(function(util3) {
|
|
272
278
|
util3.assertEqual = (_) => {
|
|
@@ -400,7 +406,7 @@ var getParsedType = (data) => {
|
|
|
400
406
|
}
|
|
401
407
|
};
|
|
402
408
|
|
|
403
|
-
// ../../node_modules/.
|
|
409
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/ZodError.js
|
|
404
410
|
var ZodIssueCode = util.arrayToEnum([
|
|
405
411
|
"invalid_type",
|
|
406
412
|
"invalid_literal",
|
|
@@ -518,7 +524,7 @@ ZodError.create = (issues) => {
|
|
|
518
524
|
return error40;
|
|
519
525
|
};
|
|
520
526
|
|
|
521
|
-
// ../../node_modules/.
|
|
527
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/locales/en.js
|
|
522
528
|
var errorMap = (issue2, _ctx) => {
|
|
523
529
|
let message;
|
|
524
530
|
switch (issue2.code) {
|
|
@@ -621,7 +627,7 @@ var errorMap = (issue2, _ctx) => {
|
|
|
621
627
|
};
|
|
622
628
|
var en_default = errorMap;
|
|
623
629
|
|
|
624
|
-
// ../../node_modules/.
|
|
630
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/errors.js
|
|
625
631
|
var overrideErrorMap = en_default;
|
|
626
632
|
function setErrorMap(map2) {
|
|
627
633
|
overrideErrorMap = map2;
|
|
@@ -630,7 +636,7 @@ function getErrorMap() {
|
|
|
630
636
|
return overrideErrorMap;
|
|
631
637
|
}
|
|
632
638
|
|
|
633
|
-
// ../../node_modules/.
|
|
639
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/parseUtil.js
|
|
634
640
|
var makeIssue = (params) => {
|
|
635
641
|
const { data, path: path25, errorMaps, issueData } = params;
|
|
636
642
|
const fullPath = [...path25, ...issueData.path || []];
|
|
@@ -740,14 +746,14 @@ var isDirty = (x) => x.status === "dirty";
|
|
|
740
746
|
var isValid = (x) => x.status === "valid";
|
|
741
747
|
var isAsync = (x) => typeof Promise !== "undefined" && x instanceof Promise;
|
|
742
748
|
|
|
743
|
-
// ../../node_modules/.
|
|
749
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/helpers/errorUtil.js
|
|
744
750
|
var errorUtil;
|
|
745
751
|
(function(errorUtil2) {
|
|
746
752
|
errorUtil2.errToObj = (message) => typeof message === "string" ? { message } : message || {};
|
|
747
753
|
errorUtil2.toString = (message) => typeof message === "string" ? message : message?.message;
|
|
748
754
|
})(errorUtil || (errorUtil = {}));
|
|
749
755
|
|
|
750
|
-
// ../../node_modules/.
|
|
756
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v3/types.js
|
|
751
757
|
var ParseInputLazyPath = class {
|
|
752
758
|
constructor(parent, value, path25, key2) {
|
|
753
759
|
this._cachedPath = [];
|
|
@@ -4195,7 +4201,7 @@ var coerce = {
|
|
|
4195
4201
|
};
|
|
4196
4202
|
var NEVER = INVALID;
|
|
4197
4203
|
|
|
4198
|
-
// ../../packages/core/dist/chunk-
|
|
4204
|
+
// ../../packages/core/dist/chunk-YCIZ33BO.js
|
|
4199
4205
|
async function fileExists(filePath) {
|
|
4200
4206
|
try {
|
|
4201
4207
|
await access(filePath, constants.F_OK);
|
|
@@ -4302,7 +4308,14 @@ async function resolveFileReference(rawValue, searchRoots) {
|
|
|
4302
4308
|
}
|
|
4303
4309
|
return { displayPath, attempted };
|
|
4304
4310
|
}
|
|
4305
|
-
var CLI_PLACEHOLDERS = /* @__PURE__ */ new Set([
|
|
4311
|
+
var CLI_PLACEHOLDERS = /* @__PURE__ */ new Set([
|
|
4312
|
+
"PROMPT",
|
|
4313
|
+
"GUIDELINES",
|
|
4314
|
+
"EVAL_ID",
|
|
4315
|
+
"ATTEMPT",
|
|
4316
|
+
"FILES",
|
|
4317
|
+
"OUTPUT_FILE"
|
|
4318
|
+
]);
|
|
4306
4319
|
var BASE_TARGET_SCHEMA = external_exports.object({
|
|
4307
4320
|
name: external_exports.string().min(1, "target name is required"),
|
|
4308
4321
|
provider: external_exports.string().min(1, "provider is required"),
|
|
@@ -4547,11 +4560,18 @@ function resolveMockConfig(target) {
|
|
|
4547
4560
|
return { response };
|
|
4548
4561
|
}
|
|
4549
4562
|
function resolveVSCodeConfig(target, env, insiders) {
|
|
4550
|
-
const workspaceTemplateEnvVar = resolveOptionalLiteralString(
|
|
4551
|
-
|
|
4552
|
-
|
|
4553
|
-
|
|
4554
|
-
|
|
4563
|
+
const workspaceTemplateEnvVar = resolveOptionalLiteralString(
|
|
4564
|
+
target.workspace_template ?? target.workspaceTemplate
|
|
4565
|
+
);
|
|
4566
|
+
const workspaceTemplate = workspaceTemplateEnvVar ? resolveOptionalString(
|
|
4567
|
+
workspaceTemplateEnvVar,
|
|
4568
|
+
env,
|
|
4569
|
+
`${target.name} workspace template path`,
|
|
4570
|
+
{
|
|
4571
|
+
allowLiteral: false,
|
|
4572
|
+
optionalEnv: true
|
|
4573
|
+
}
|
|
4574
|
+
) : void 0;
|
|
4555
4575
|
const commandSource = target.vscode_cmd ?? target.command;
|
|
4556
4576
|
const waitSource = target.wait;
|
|
4557
4577
|
const dryRunSource = target.dry_run ?? target.dryRun;
|
|
@@ -4578,7 +4598,10 @@ function resolveCliConfig(target, env) {
|
|
|
4578
4598
|
allowLiteral: true,
|
|
4579
4599
|
optionalEnv: true
|
|
4580
4600
|
});
|
|
4581
|
-
const timeoutMs = resolveTimeoutMs(
|
|
4601
|
+
const timeoutMs = resolveTimeoutMs(
|
|
4602
|
+
target.timeout_seconds ?? target.timeoutSeconds,
|
|
4603
|
+
`${target.name} timeout`
|
|
4604
|
+
);
|
|
4582
4605
|
const healthcheck = resolveCliHealthcheck(target.healthcheck, env, target.name);
|
|
4583
4606
|
const commandTemplate = resolveString(
|
|
4584
4607
|
commandTemplateSource,
|
|
@@ -4706,7 +4729,9 @@ function resolveOptionalString(source2, env, description, options) {
|
|
|
4706
4729
|
}
|
|
4707
4730
|
const allowLiteral = options?.allowLiteral ?? false;
|
|
4708
4731
|
if (!allowLiteral) {
|
|
4709
|
-
throw new Error(
|
|
4732
|
+
throw new Error(
|
|
4733
|
+
`${description} must use \${{ VARIABLE_NAME }} syntax for environment variables or be marked as allowing literals`
|
|
4734
|
+
);
|
|
4710
4735
|
}
|
|
4711
4736
|
return trimmed;
|
|
4712
4737
|
}
|
|
@@ -4841,29 +4866,29 @@ var PROVIDER_ALIASES = [
|
|
|
4841
4866
|
"vertex"
|
|
4842
4867
|
// legacy/future support
|
|
4843
4868
|
];
|
|
4844
|
-
var TARGETS_SCHEMA_V2 = "agentv-targets-v2.2";
|
|
4845
4869
|
function isAgentProvider(provider) {
|
|
4846
4870
|
return provider ? AGENT_PROVIDER_KINDS.includes(provider.kind) : false;
|
|
4847
4871
|
}
|
|
4848
4872
|
|
|
4849
4873
|
// ../../packages/core/dist/index.js
|
|
4850
|
-
import { readFile as
|
|
4874
|
+
import { readFile as readFile5 } from "node:fs/promises";
|
|
4851
4875
|
import path62 from "node:path";
|
|
4852
4876
|
import { parse as parse22 } from "yaml";
|
|
4853
|
-
import micromatch from "micromatch";
|
|
4854
4877
|
import { readFile as readFile3 } from "node:fs/promises";
|
|
4855
4878
|
import path22 from "node:path";
|
|
4879
|
+
import micromatch from "micromatch";
|
|
4856
4880
|
import { parse as parse5 } from "yaml";
|
|
4857
4881
|
import { constants as constants3 } from "node:fs";
|
|
4858
4882
|
import { access as access3 } from "node:fs/promises";
|
|
4859
4883
|
import path8 from "node:path";
|
|
4860
4884
|
import path32 from "node:path";
|
|
4861
4885
|
import { readFile as readFile22 } from "node:fs/promises";
|
|
4862
|
-
import path42 from "node:path";
|
|
4863
4886
|
import { readFile as readFile32 } from "node:fs/promises";
|
|
4887
|
+
import path42 from "node:path";
|
|
4888
|
+
import { readFile as readFile4 } from "node:fs/promises";
|
|
4864
4889
|
import path52 from "node:path";
|
|
4865
4890
|
|
|
4866
|
-
// ../../node_modules/.
|
|
4891
|
+
// ../../node_modules/.bun/@ai-sdk+provider@2.0.0/node_modules/@ai-sdk/provider/dist/index.mjs
|
|
4867
4892
|
var marker = "vercel.ai.error";
|
|
4868
4893
|
var symbol = Symbol.for(marker);
|
|
4869
4894
|
var _a;
|
|
@@ -5172,7 +5197,7 @@ var UnsupportedFunctionalityError = class extends AISDKError {
|
|
|
5172
5197
|
};
|
|
5173
5198
|
_a14 = symbol14;
|
|
5174
5199
|
|
|
5175
|
-
// ../../node_modules/.
|
|
5200
|
+
// ../../node_modules/.bun/eventsource-parser@3.0.6/node_modules/eventsource-parser/dist/index.js
|
|
5176
5201
|
var ParseError = class extends Error {
|
|
5177
5202
|
constructor(message, options) {
|
|
5178
5203
|
super(message), this.name = "ParseError", this.type = options.type, this.field = options.field, this.value = options.value, this.line = options.line;
|
|
@@ -5275,7 +5300,7 @@ function splitLines(chunk) {
|
|
|
5275
5300
|
return [lines, incompleteLine];
|
|
5276
5301
|
}
|
|
5277
5302
|
|
|
5278
|
-
// ../../node_modules/.
|
|
5303
|
+
// ../../node_modules/.bun/eventsource-parser@3.0.6/node_modules/eventsource-parser/dist/stream.js
|
|
5279
5304
|
var EventSourceParserStream = class extends TransformStream {
|
|
5280
5305
|
constructor({ onError, onRetry, onComment } = {}) {
|
|
5281
5306
|
let parser;
|
|
@@ -5299,7 +5324,7 @@ var EventSourceParserStream = class extends TransformStream {
|
|
|
5299
5324
|
}
|
|
5300
5325
|
};
|
|
5301
5326
|
|
|
5302
|
-
// ../../node_modules/.
|
|
5327
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/external.js
|
|
5303
5328
|
var external_exports2 = {};
|
|
5304
5329
|
__export(external_exports2, {
|
|
5305
5330
|
$brand: () => $brand,
|
|
@@ -5511,7 +5536,7 @@ __export(external_exports2, {
|
|
|
5511
5536
|
xid: () => xid2
|
|
5512
5537
|
});
|
|
5513
5538
|
|
|
5514
|
-
// ../../node_modules/.
|
|
5539
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/index.js
|
|
5515
5540
|
var core_exports2 = {};
|
|
5516
5541
|
__export(core_exports2, {
|
|
5517
5542
|
$ZodAny: () => $ZodAny,
|
|
@@ -5755,7 +5780,7 @@ __export(core_exports2, {
|
|
|
5755
5780
|
version: () => version
|
|
5756
5781
|
});
|
|
5757
5782
|
|
|
5758
|
-
// ../../node_modules/.
|
|
5783
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/core.js
|
|
5759
5784
|
var NEVER2 = Object.freeze({
|
|
5760
5785
|
status: "aborted"
|
|
5761
5786
|
});
|
|
@@ -5815,7 +5840,7 @@ function config(newConfig) {
|
|
|
5815
5840
|
return globalConfig;
|
|
5816
5841
|
}
|
|
5817
5842
|
|
|
5818
|
-
// ../../node_modules/.
|
|
5843
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/util.js
|
|
5819
5844
|
var util_exports = {};
|
|
5820
5845
|
__export(util_exports, {
|
|
5821
5846
|
BIGINT_FORMAT_RANGES: () => BIGINT_FORMAT_RANGES,
|
|
@@ -6336,7 +6361,7 @@ var Class = class {
|
|
|
6336
6361
|
}
|
|
6337
6362
|
};
|
|
6338
6363
|
|
|
6339
|
-
// ../../node_modules/.
|
|
6364
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/errors.js
|
|
6340
6365
|
var initializer = (inst, def) => {
|
|
6341
6366
|
inst.name = "$ZodError";
|
|
6342
6367
|
Object.defineProperty(inst, "_zod", {
|
|
@@ -6483,7 +6508,7 @@ function prettifyError(error40) {
|
|
|
6483
6508
|
return lines.join("\n");
|
|
6484
6509
|
}
|
|
6485
6510
|
|
|
6486
|
-
// ../../node_modules/.
|
|
6511
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/parse.js
|
|
6487
6512
|
var _parse = (_Err) => (schema, value, _ctx, _params) => {
|
|
6488
6513
|
const ctx = _ctx ? Object.assign(_ctx, { async: false }) : { async: false };
|
|
6489
6514
|
const result = schema._zod.run({ value, issues: [] }, ctx);
|
|
@@ -6535,7 +6560,7 @@ var _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
|
|
|
6535
6560
|
};
|
|
6536
6561
|
var safeParseAsync = /* @__PURE__ */ _safeParseAsync($ZodRealError);
|
|
6537
6562
|
|
|
6538
|
-
// ../../node_modules/.
|
|
6563
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/regexes.js
|
|
6539
6564
|
var regexes_exports = {};
|
|
6540
6565
|
__export(regexes_exports, {
|
|
6541
6566
|
_emoji: () => _emoji,
|
|
@@ -6648,7 +6673,7 @@ var _undefined = /undefined/i;
|
|
|
6648
6673
|
var lowercase = /^[^A-Z]*$/;
|
|
6649
6674
|
var uppercase = /^[^a-z]*$/;
|
|
6650
6675
|
|
|
6651
|
-
// ../../node_modules/.
|
|
6676
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/checks.js
|
|
6652
6677
|
var $ZodCheck = /* @__PURE__ */ $constructor("$ZodCheck", (inst, def) => {
|
|
6653
6678
|
var _a17;
|
|
6654
6679
|
inst._zod ?? (inst._zod = {});
|
|
@@ -7186,7 +7211,7 @@ var $ZodCheckOverwrite = /* @__PURE__ */ $constructor("$ZodCheckOverwrite", (ins
|
|
|
7186
7211
|
};
|
|
7187
7212
|
});
|
|
7188
7213
|
|
|
7189
|
-
// ../../node_modules/.
|
|
7214
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/doc.js
|
|
7190
7215
|
var Doc = class {
|
|
7191
7216
|
constructor(args = []) {
|
|
7192
7217
|
this.content = [];
|
|
@@ -7222,14 +7247,14 @@ var Doc = class {
|
|
|
7222
7247
|
}
|
|
7223
7248
|
};
|
|
7224
7249
|
|
|
7225
|
-
// ../../node_modules/.
|
|
7250
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/versions.js
|
|
7226
7251
|
var version = {
|
|
7227
7252
|
major: 4,
|
|
7228
7253
|
minor: 0,
|
|
7229
7254
|
patch: 0
|
|
7230
7255
|
};
|
|
7231
7256
|
|
|
7232
|
-
// ../../node_modules/.
|
|
7257
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/schemas.js
|
|
7233
7258
|
var $ZodType = /* @__PURE__ */ $constructor("$ZodType", (inst, def) => {
|
|
7234
7259
|
var _a17;
|
|
7235
7260
|
inst ?? (inst = {});
|
|
@@ -8856,7 +8881,7 @@ function handleRefineResult(result, payload, input, inst) {
|
|
|
8856
8881
|
}
|
|
8857
8882
|
}
|
|
8858
8883
|
|
|
8859
|
-
// ../../node_modules/.
|
|
8884
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/index.js
|
|
8860
8885
|
var locales_exports = {};
|
|
8861
8886
|
__export(locales_exports, {
|
|
8862
8887
|
ar: () => ar_default,
|
|
@@ -8900,7 +8925,7 @@ __export(locales_exports, {
|
|
|
8900
8925
|
zhTW: () => zh_TW_default
|
|
8901
8926
|
});
|
|
8902
8927
|
|
|
8903
|
-
// ../../node_modules/.
|
|
8928
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ar.js
|
|
8904
8929
|
var error = () => {
|
|
8905
8930
|
const Sizable = {
|
|
8906
8931
|
string: { unit: "\u062D\u0631\u0641", verb: "\u0623\u0646 \u064A\u062D\u0648\u064A" },
|
|
@@ -9017,7 +9042,7 @@ function ar_default() {
|
|
|
9017
9042
|
};
|
|
9018
9043
|
}
|
|
9019
9044
|
|
|
9020
|
-
// ../../node_modules/.
|
|
9045
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/az.js
|
|
9021
9046
|
var error2 = () => {
|
|
9022
9047
|
const Sizable = {
|
|
9023
9048
|
string: { unit: "simvol", verb: "olmal\u0131d\u0131r" },
|
|
@@ -9133,7 +9158,7 @@ function az_default() {
|
|
|
9133
9158
|
};
|
|
9134
9159
|
}
|
|
9135
9160
|
|
|
9136
|
-
// ../../node_modules/.
|
|
9161
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/be.js
|
|
9137
9162
|
function getBelarusianPlural(count, one, few, many) {
|
|
9138
9163
|
const absCount = Math.abs(count);
|
|
9139
9164
|
const lastDigit = absCount % 10;
|
|
@@ -9298,7 +9323,7 @@ function be_default() {
|
|
|
9298
9323
|
};
|
|
9299
9324
|
}
|
|
9300
9325
|
|
|
9301
|
-
// ../../node_modules/.
|
|
9326
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ca.js
|
|
9302
9327
|
var error4 = () => {
|
|
9303
9328
|
const Sizable = {
|
|
9304
9329
|
string: { unit: "car\xE0cters", verb: "contenir" },
|
|
@@ -9418,7 +9443,7 @@ function ca_default() {
|
|
|
9418
9443
|
};
|
|
9419
9444
|
}
|
|
9420
9445
|
|
|
9421
|
-
// ../../node_modules/.
|
|
9446
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/cs.js
|
|
9422
9447
|
var error5 = () => {
|
|
9423
9448
|
const Sizable = {
|
|
9424
9449
|
string: { unit: "znak\u016F", verb: "m\xEDt" },
|
|
@@ -9554,7 +9579,7 @@ function cs_default() {
|
|
|
9554
9579
|
};
|
|
9555
9580
|
}
|
|
9556
9581
|
|
|
9557
|
-
// ../../node_modules/.
|
|
9582
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/de.js
|
|
9558
9583
|
var error6 = () => {
|
|
9559
9584
|
const Sizable = {
|
|
9560
9585
|
string: { unit: "Zeichen", verb: "zu haben" },
|
|
@@ -9671,7 +9696,7 @@ function de_default() {
|
|
|
9671
9696
|
};
|
|
9672
9697
|
}
|
|
9673
9698
|
|
|
9674
|
-
// ../../node_modules/.
|
|
9699
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/en.js
|
|
9675
9700
|
var parsedType = (data) => {
|
|
9676
9701
|
const t = typeof data;
|
|
9677
9702
|
switch (t) {
|
|
@@ -9789,7 +9814,7 @@ function en_default2() {
|
|
|
9789
9814
|
};
|
|
9790
9815
|
}
|
|
9791
9816
|
|
|
9792
|
-
// ../../node_modules/.
|
|
9817
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/eo.js
|
|
9793
9818
|
var parsedType2 = (data) => {
|
|
9794
9819
|
const t = typeof data;
|
|
9795
9820
|
switch (t) {
|
|
@@ -9906,7 +9931,7 @@ function eo_default() {
|
|
|
9906
9931
|
};
|
|
9907
9932
|
}
|
|
9908
9933
|
|
|
9909
|
-
// ../../node_modules/.
|
|
9934
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/es.js
|
|
9910
9935
|
var error9 = () => {
|
|
9911
9936
|
const Sizable = {
|
|
9912
9937
|
string: { unit: "caracteres", verb: "tener" },
|
|
@@ -10024,7 +10049,7 @@ function es_default() {
|
|
|
10024
10049
|
};
|
|
10025
10050
|
}
|
|
10026
10051
|
|
|
10027
|
-
// ../../node_modules/.
|
|
10052
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/fa.js
|
|
10028
10053
|
var error10 = () => {
|
|
10029
10054
|
const Sizable = {
|
|
10030
10055
|
string: { unit: "\u06A9\u0627\u0631\u0627\u06A9\u062A\u0631", verb: "\u062F\u0627\u0634\u062A\u0647 \u0628\u0627\u0634\u062F" },
|
|
@@ -10147,7 +10172,7 @@ function fa_default() {
|
|
|
10147
10172
|
};
|
|
10148
10173
|
}
|
|
10149
10174
|
|
|
10150
|
-
// ../../node_modules/.
|
|
10175
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/fi.js
|
|
10151
10176
|
var error11 = () => {
|
|
10152
10177
|
const Sizable = {
|
|
10153
10178
|
string: { unit: "merkki\xE4", subject: "merkkijonon" },
|
|
@@ -10270,7 +10295,7 @@ function fi_default() {
|
|
|
10270
10295
|
};
|
|
10271
10296
|
}
|
|
10272
10297
|
|
|
10273
|
-
// ../../node_modules/.
|
|
10298
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/fr.js
|
|
10274
10299
|
var error12 = () => {
|
|
10275
10300
|
const Sizable = {
|
|
10276
10301
|
string: { unit: "caract\xE8res", verb: "avoir" },
|
|
@@ -10387,7 +10412,7 @@ function fr_default() {
|
|
|
10387
10412
|
};
|
|
10388
10413
|
}
|
|
10389
10414
|
|
|
10390
|
-
// ../../node_modules/.
|
|
10415
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/fr-CA.js
|
|
10391
10416
|
var error13 = () => {
|
|
10392
10417
|
const Sizable = {
|
|
10393
10418
|
string: { unit: "caract\xE8res", verb: "avoir" },
|
|
@@ -10505,7 +10530,7 @@ function fr_CA_default() {
|
|
|
10505
10530
|
};
|
|
10506
10531
|
}
|
|
10507
10532
|
|
|
10508
|
-
// ../../node_modules/.
|
|
10533
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/he.js
|
|
10509
10534
|
var error14 = () => {
|
|
10510
10535
|
const Sizable = {
|
|
10511
10536
|
string: { unit: "\u05D0\u05D5\u05EA\u05D9\u05D5\u05EA", verb: "\u05DC\u05DB\u05DC\u05D5\u05DC" },
|
|
@@ -10623,7 +10648,7 @@ function he_default() {
|
|
|
10623
10648
|
};
|
|
10624
10649
|
}
|
|
10625
10650
|
|
|
10626
|
-
// ../../node_modules/.
|
|
10651
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/hu.js
|
|
10627
10652
|
var error15 = () => {
|
|
10628
10653
|
const Sizable = {
|
|
10629
10654
|
string: { unit: "karakter", verb: "legyen" },
|
|
@@ -10741,7 +10766,7 @@ function hu_default() {
|
|
|
10741
10766
|
};
|
|
10742
10767
|
}
|
|
10743
10768
|
|
|
10744
|
-
// ../../node_modules/.
|
|
10769
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/id.js
|
|
10745
10770
|
var error16 = () => {
|
|
10746
10771
|
const Sizable = {
|
|
10747
10772
|
string: { unit: "karakter", verb: "memiliki" },
|
|
@@ -10858,7 +10883,7 @@ function id_default() {
|
|
|
10858
10883
|
};
|
|
10859
10884
|
}
|
|
10860
10885
|
|
|
10861
|
-
// ../../node_modules/.
|
|
10886
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/it.js
|
|
10862
10887
|
var error17 = () => {
|
|
10863
10888
|
const Sizable = {
|
|
10864
10889
|
string: { unit: "caratteri", verb: "avere" },
|
|
@@ -10976,7 +11001,7 @@ function it_default() {
|
|
|
10976
11001
|
};
|
|
10977
11002
|
}
|
|
10978
11003
|
|
|
10979
|
-
// ../../node_modules/.
|
|
11004
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ja.js
|
|
10980
11005
|
var error18 = () => {
|
|
10981
11006
|
const Sizable = {
|
|
10982
11007
|
string: { unit: "\u6587\u5B57", verb: "\u3067\u3042\u308B" },
|
|
@@ -11092,7 +11117,7 @@ function ja_default() {
|
|
|
11092
11117
|
};
|
|
11093
11118
|
}
|
|
11094
11119
|
|
|
11095
|
-
// ../../node_modules/.
|
|
11120
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/kh.js
|
|
11096
11121
|
var error19 = () => {
|
|
11097
11122
|
const Sizable = {
|
|
11098
11123
|
string: { unit: "\u178F\u17BD\u17A2\u1780\u17D2\u179F\u179A", verb: "\u1782\u17BD\u179A\u1798\u17B6\u1793" },
|
|
@@ -11210,7 +11235,7 @@ function kh_default() {
|
|
|
11210
11235
|
};
|
|
11211
11236
|
}
|
|
11212
11237
|
|
|
11213
|
-
// ../../node_modules/.
|
|
11238
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ko.js
|
|
11214
11239
|
var error20 = () => {
|
|
11215
11240
|
const Sizable = {
|
|
11216
11241
|
string: { unit: "\uBB38\uC790", verb: "to have" },
|
|
@@ -11332,7 +11357,7 @@ function ko_default() {
|
|
|
11332
11357
|
};
|
|
11333
11358
|
}
|
|
11334
11359
|
|
|
11335
|
-
// ../../node_modules/.
|
|
11360
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/mk.js
|
|
11336
11361
|
var error21 = () => {
|
|
11337
11362
|
const Sizable = {
|
|
11338
11363
|
string: { unit: "\u0437\u043D\u0430\u0446\u0438", verb: "\u0434\u0430 \u0438\u043C\u0430\u0430\u0442" },
|
|
@@ -11451,7 +11476,7 @@ function mk_default() {
|
|
|
11451
11476
|
};
|
|
11452
11477
|
}
|
|
11453
11478
|
|
|
11454
|
-
// ../../node_modules/.
|
|
11479
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ms.js
|
|
11455
11480
|
var error22 = () => {
|
|
11456
11481
|
const Sizable = {
|
|
11457
11482
|
string: { unit: "aksara", verb: "mempunyai" },
|
|
@@ -11568,7 +11593,7 @@ function ms_default() {
|
|
|
11568
11593
|
};
|
|
11569
11594
|
}
|
|
11570
11595
|
|
|
11571
|
-
// ../../node_modules/.
|
|
11596
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/nl.js
|
|
11572
11597
|
var error23 = () => {
|
|
11573
11598
|
const Sizable = {
|
|
11574
11599
|
string: { unit: "tekens" },
|
|
@@ -11686,7 +11711,7 @@ function nl_default() {
|
|
|
11686
11711
|
};
|
|
11687
11712
|
}
|
|
11688
11713
|
|
|
11689
|
-
// ../../node_modules/.
|
|
11714
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/no.js
|
|
11690
11715
|
var error24 = () => {
|
|
11691
11716
|
const Sizable = {
|
|
11692
11717
|
string: { unit: "tegn", verb: "\xE5 ha" },
|
|
@@ -11803,7 +11828,7 @@ function no_default() {
|
|
|
11803
11828
|
};
|
|
11804
11829
|
}
|
|
11805
11830
|
|
|
11806
|
-
// ../../node_modules/.
|
|
11831
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ota.js
|
|
11807
11832
|
var error25 = () => {
|
|
11808
11833
|
const Sizable = {
|
|
11809
11834
|
string: { unit: "harf", verb: "olmal\u0131d\u0131r" },
|
|
@@ -11921,7 +11946,7 @@ function ota_default() {
|
|
|
11921
11946
|
};
|
|
11922
11947
|
}
|
|
11923
11948
|
|
|
11924
|
-
// ../../node_modules/.
|
|
11949
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ps.js
|
|
11925
11950
|
var error26 = () => {
|
|
11926
11951
|
const Sizable = {
|
|
11927
11952
|
string: { unit: "\u062A\u0648\u06A9\u064A", verb: "\u0648\u0644\u0631\u064A" },
|
|
@@ -12044,7 +12069,7 @@ function ps_default() {
|
|
|
12044
12069
|
};
|
|
12045
12070
|
}
|
|
12046
12071
|
|
|
12047
|
-
// ../../node_modules/.
|
|
12072
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/pl.js
|
|
12048
12073
|
var error27 = () => {
|
|
12049
12074
|
const Sizable = {
|
|
12050
12075
|
string: { unit: "znak\xF3w", verb: "mie\u0107" },
|
|
@@ -12162,7 +12187,7 @@ function pl_default() {
|
|
|
12162
12187
|
};
|
|
12163
12188
|
}
|
|
12164
12189
|
|
|
12165
|
-
// ../../node_modules/.
|
|
12190
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/pt.js
|
|
12166
12191
|
var error28 = () => {
|
|
12167
12192
|
const Sizable = {
|
|
12168
12193
|
string: { unit: "caracteres", verb: "ter" },
|
|
@@ -12279,7 +12304,7 @@ function pt_default() {
|
|
|
12279
12304
|
};
|
|
12280
12305
|
}
|
|
12281
12306
|
|
|
12282
|
-
// ../../node_modules/.
|
|
12307
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ru.js
|
|
12283
12308
|
function getRussianPlural(count, one, few, many) {
|
|
12284
12309
|
const absCount = Math.abs(count);
|
|
12285
12310
|
const lastDigit = absCount % 10;
|
|
@@ -12444,7 +12469,7 @@ function ru_default() {
|
|
|
12444
12469
|
};
|
|
12445
12470
|
}
|
|
12446
12471
|
|
|
12447
|
-
// ../../node_modules/.
|
|
12472
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/sl.js
|
|
12448
12473
|
var error30 = () => {
|
|
12449
12474
|
const Sizable = {
|
|
12450
12475
|
string: { unit: "znakov", verb: "imeti" },
|
|
@@ -12562,7 +12587,7 @@ function sl_default() {
|
|
|
12562
12587
|
};
|
|
12563
12588
|
}
|
|
12564
12589
|
|
|
12565
|
-
// ../../node_modules/.
|
|
12590
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/sv.js
|
|
12566
12591
|
var error31 = () => {
|
|
12567
12592
|
const Sizable = {
|
|
12568
12593
|
string: { unit: "tecken", verb: "att ha" },
|
|
@@ -12681,7 +12706,7 @@ function sv_default() {
|
|
|
12681
12706
|
};
|
|
12682
12707
|
}
|
|
12683
12708
|
|
|
12684
|
-
// ../../node_modules/.
|
|
12709
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ta.js
|
|
12685
12710
|
var error32 = () => {
|
|
12686
12711
|
const Sizable = {
|
|
12687
12712
|
string: { unit: "\u0B8E\u0BB4\u0BC1\u0BA4\u0BCD\u0BA4\u0BC1\u0B95\u0BCD\u0B95\u0BB3\u0BCD", verb: "\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95 \u0BB5\u0BC7\u0BA3\u0BCD\u0B9F\u0BC1\u0BAE\u0BCD" },
|
|
@@ -12799,7 +12824,7 @@ function ta_default() {
|
|
|
12799
12824
|
};
|
|
12800
12825
|
}
|
|
12801
12826
|
|
|
12802
|
-
// ../../node_modules/.
|
|
12827
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/th.js
|
|
12803
12828
|
var error33 = () => {
|
|
12804
12829
|
const Sizable = {
|
|
12805
12830
|
string: { unit: "\u0E15\u0E31\u0E27\u0E2D\u0E31\u0E01\u0E29\u0E23", verb: "\u0E04\u0E27\u0E23\u0E21\u0E35" },
|
|
@@ -12917,7 +12942,7 @@ function th_default() {
|
|
|
12917
12942
|
};
|
|
12918
12943
|
}
|
|
12919
12944
|
|
|
12920
|
-
// ../../node_modules/.
|
|
12945
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/tr.js
|
|
12921
12946
|
var parsedType3 = (data) => {
|
|
12922
12947
|
const t = typeof data;
|
|
12923
12948
|
switch (t) {
|
|
@@ -13033,7 +13058,7 @@ function tr_default() {
|
|
|
13033
13058
|
};
|
|
13034
13059
|
}
|
|
13035
13060
|
|
|
13036
|
-
// ../../node_modules/.
|
|
13061
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ua.js
|
|
13037
13062
|
var error35 = () => {
|
|
13038
13063
|
const Sizable = {
|
|
13039
13064
|
string: { unit: "\u0441\u0438\u043C\u0432\u043E\u043B\u0456\u0432", verb: "\u043C\u0430\u0442\u0438\u043C\u0435" },
|
|
@@ -13151,7 +13176,7 @@ function ua_default() {
|
|
|
13151
13176
|
};
|
|
13152
13177
|
}
|
|
13153
13178
|
|
|
13154
|
-
// ../../node_modules/.
|
|
13179
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/ur.js
|
|
13155
13180
|
var error36 = () => {
|
|
13156
13181
|
const Sizable = {
|
|
13157
13182
|
string: { unit: "\u062D\u0631\u0648\u0641", verb: "\u06C1\u0648\u0646\u0627" },
|
|
@@ -13269,7 +13294,7 @@ function ur_default() {
|
|
|
13269
13294
|
};
|
|
13270
13295
|
}
|
|
13271
13296
|
|
|
13272
|
-
// ../../node_modules/.
|
|
13297
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/vi.js
|
|
13273
13298
|
var error37 = () => {
|
|
13274
13299
|
const Sizable = {
|
|
13275
13300
|
string: { unit: "k\xFD t\u1EF1", verb: "c\xF3" },
|
|
@@ -13386,7 +13411,7 @@ function vi_default() {
|
|
|
13386
13411
|
};
|
|
13387
13412
|
}
|
|
13388
13413
|
|
|
13389
|
-
// ../../node_modules/.
|
|
13414
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/zh-CN.js
|
|
13390
13415
|
var error38 = () => {
|
|
13391
13416
|
const Sizable = {
|
|
13392
13417
|
string: { unit: "\u5B57\u7B26", verb: "\u5305\u542B" },
|
|
@@ -13503,7 +13528,7 @@ function zh_CN_default() {
|
|
|
13503
13528
|
};
|
|
13504
13529
|
}
|
|
13505
13530
|
|
|
13506
|
-
// ../../node_modules/.
|
|
13531
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/locales/zh-TW.js
|
|
13507
13532
|
var error39 = () => {
|
|
13508
13533
|
const Sizable = {
|
|
13509
13534
|
string: { unit: "\u5B57\u5143", verb: "\u64C1\u6709" },
|
|
@@ -13621,7 +13646,7 @@ function zh_TW_default() {
|
|
|
13621
13646
|
};
|
|
13622
13647
|
}
|
|
13623
13648
|
|
|
13624
|
-
// ../../node_modules/.
|
|
13649
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/registries.js
|
|
13625
13650
|
var $output = Symbol("ZodOutput");
|
|
13626
13651
|
var $input = Symbol("ZodInput");
|
|
13627
13652
|
var $ZodRegistry = class {
|
|
@@ -13671,7 +13696,7 @@ function registry() {
|
|
|
13671
13696
|
}
|
|
13672
13697
|
var globalRegistry = /* @__PURE__ */ registry();
|
|
13673
13698
|
|
|
13674
|
-
// ../../node_modules/.
|
|
13699
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/api.js
|
|
13675
13700
|
function _string(Class2, params) {
|
|
13676
13701
|
return new Class2({
|
|
13677
13702
|
type: "string",
|
|
@@ -14529,7 +14554,7 @@ function _stringFormat(Class2, format, fnOrRegex, _params = {}) {
|
|
|
14529
14554
|
return inst;
|
|
14530
14555
|
}
|
|
14531
14556
|
|
|
14532
|
-
// ../../node_modules/.
|
|
14557
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/function.js
|
|
14533
14558
|
var $ZodFunction = class {
|
|
14534
14559
|
constructor(def) {
|
|
14535
14560
|
this._def = def;
|
|
@@ -14599,7 +14624,7 @@ function _function(params) {
|
|
|
14599
14624
|
});
|
|
14600
14625
|
}
|
|
14601
14626
|
|
|
14602
|
-
// ../../node_modules/.
|
|
14627
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/to-json-schema.js
|
|
14603
14628
|
var JSONSchemaGenerator = class {
|
|
14604
14629
|
constructor(params) {
|
|
14605
14630
|
this.counter = 0;
|
|
@@ -15366,10 +15391,10 @@ function isTransforming(_schema, _ctx) {
|
|
|
15366
15391
|
throw new Error(`Unknown schema type: ${def.type}`);
|
|
15367
15392
|
}
|
|
15368
15393
|
|
|
15369
|
-
// ../../node_modules/.
|
|
15394
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/core/json-schema.js
|
|
15370
15395
|
var json_schema_exports = {};
|
|
15371
15396
|
|
|
15372
|
-
// ../../node_modules/.
|
|
15397
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/iso.js
|
|
15373
15398
|
var iso_exports = {};
|
|
15374
15399
|
__export(iso_exports, {
|
|
15375
15400
|
ZodISODate: () => ZodISODate,
|
|
@@ -15410,7 +15435,7 @@ function duration2(params) {
|
|
|
15410
15435
|
return _isoDuration(ZodISODuration, params);
|
|
15411
15436
|
}
|
|
15412
15437
|
|
|
15413
|
-
// ../../node_modules/.
|
|
15438
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/errors.js
|
|
15414
15439
|
var initializer2 = (inst, issues) => {
|
|
15415
15440
|
$ZodError.init(inst, issues);
|
|
15416
15441
|
inst.name = "ZodError";
|
|
@@ -15444,13 +15469,13 @@ var ZodRealError = $constructor("ZodError", initializer2, {
|
|
|
15444
15469
|
Parent: Error
|
|
15445
15470
|
});
|
|
15446
15471
|
|
|
15447
|
-
// ../../node_modules/.
|
|
15472
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/parse.js
|
|
15448
15473
|
var parse2 = /* @__PURE__ */ _parse(ZodRealError);
|
|
15449
15474
|
var parseAsync2 = /* @__PURE__ */ _parseAsync(ZodRealError);
|
|
15450
15475
|
var safeParse2 = /* @__PURE__ */ _safeParse(ZodRealError);
|
|
15451
15476
|
var safeParseAsync2 = /* @__PURE__ */ _safeParseAsync(ZodRealError);
|
|
15452
15477
|
|
|
15453
|
-
// ../../node_modules/.
|
|
15478
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/schemas.js
|
|
15454
15479
|
var ZodType2 = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
15455
15480
|
$ZodType.init(inst, def);
|
|
15456
15481
|
inst.def = def;
|
|
@@ -16387,7 +16412,7 @@ function preprocess(fn, schema) {
|
|
|
16387
16412
|
return pipe(transform(fn), schema);
|
|
16388
16413
|
}
|
|
16389
16414
|
|
|
16390
|
-
// ../../node_modules/.
|
|
16415
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/compat.js
|
|
16391
16416
|
var ZodIssueCode2 = {
|
|
16392
16417
|
invalid_type: "invalid_type",
|
|
16393
16418
|
too_big: "too_big",
|
|
@@ -16410,7 +16435,7 @@ function getErrorMap2() {
|
|
|
16410
16435
|
return config().customError;
|
|
16411
16436
|
}
|
|
16412
16437
|
|
|
16413
|
-
// ../../node_modules/.
|
|
16438
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/coerce.js
|
|
16414
16439
|
var coerce_exports = {};
|
|
16415
16440
|
__export(coerce_exports, {
|
|
16416
16441
|
bigint: () => bigint3,
|
|
@@ -16435,10 +16460,10 @@ function date4(params) {
|
|
|
16435
16460
|
return _coercedDate(ZodDate2, params);
|
|
16436
16461
|
}
|
|
16437
16462
|
|
|
16438
|
-
// ../../node_modules/.
|
|
16463
|
+
// ../../node_modules/.bun/zod@3.25.76/node_modules/zod/v4/classic/external.js
|
|
16439
16464
|
config(en_default2());
|
|
16440
16465
|
|
|
16441
|
-
// ../../node_modules/.
|
|
16466
|
+
// ../../node_modules/.bun/@ai-sdk+provider-utils@3.0.19+27912429049419a2/node_modules/@ai-sdk/provider-utils/dist/index.mjs
|
|
16442
16467
|
function combineHeaders(...headers) {
|
|
16443
16468
|
return headers.reduce(
|
|
16444
16469
|
(combinedHeaders, currentHeaders) => ({
|
|
@@ -16591,7 +16616,7 @@ function withUserAgentSuffix(headers, ...userAgentSuffixParts) {
|
|
|
16591
16616
|
);
|
|
16592
16617
|
return Object.fromEntries(normalizedHeaders.entries());
|
|
16593
16618
|
}
|
|
16594
|
-
var VERSION = true ? "3.0.
|
|
16619
|
+
var VERSION = true ? "3.0.19" : "0.0.0-test";
|
|
16595
16620
|
var getOriginalFetch = () => globalThis.fetch;
|
|
16596
16621
|
var getFromApi = async ({
|
|
16597
16622
|
url: url2,
|
|
@@ -17253,6 +17278,31 @@ var createBinaryResponseHandler = () => async ({ response, url: url2, requestBod
|
|
|
17253
17278
|
});
|
|
17254
17279
|
}
|
|
17255
17280
|
};
|
|
17281
|
+
function addAdditionalPropertiesToJsonSchema(jsonSchema2) {
|
|
17282
|
+
if (jsonSchema2.type === "object") {
|
|
17283
|
+
jsonSchema2.additionalProperties = false;
|
|
17284
|
+
const properties = jsonSchema2.properties;
|
|
17285
|
+
if (properties != null) {
|
|
17286
|
+
for (const property in properties) {
|
|
17287
|
+
properties[property] = addAdditionalPropertiesToJsonSchema(
|
|
17288
|
+
properties[property]
|
|
17289
|
+
);
|
|
17290
|
+
}
|
|
17291
|
+
}
|
|
17292
|
+
}
|
|
17293
|
+
if (jsonSchema2.type === "array" && jsonSchema2.items != null) {
|
|
17294
|
+
if (Array.isArray(jsonSchema2.items)) {
|
|
17295
|
+
jsonSchema2.items = jsonSchema2.items.map(
|
|
17296
|
+
(item) => addAdditionalPropertiesToJsonSchema(item)
|
|
17297
|
+
);
|
|
17298
|
+
} else {
|
|
17299
|
+
jsonSchema2.items = addAdditionalPropertiesToJsonSchema(
|
|
17300
|
+
jsonSchema2.items
|
|
17301
|
+
);
|
|
17302
|
+
}
|
|
17303
|
+
}
|
|
17304
|
+
return jsonSchema2;
|
|
17305
|
+
}
|
|
17256
17306
|
var getRelativePath = (pathA, pathB) => {
|
|
17257
17307
|
let i = 0;
|
|
17258
17308
|
for (; i < pathA.length && i < pathB.length; i++) {
|
|
@@ -18374,11 +18424,13 @@ function zod4Schema(zodSchema2, options) {
|
|
|
18374
18424
|
const useReferences = (_a17 = options == null ? void 0 : options.useReferences) != null ? _a17 : false;
|
|
18375
18425
|
return jsonSchema(
|
|
18376
18426
|
// defer json schema creation to avoid unnecessary computation when only validation is needed
|
|
18377
|
-
() =>
|
|
18378
|
-
|
|
18379
|
-
|
|
18380
|
-
|
|
18381
|
-
|
|
18427
|
+
() => addAdditionalPropertiesToJsonSchema(
|
|
18428
|
+
toJSONSchema(zodSchema2, {
|
|
18429
|
+
target: "draft-7",
|
|
18430
|
+
io: "input",
|
|
18431
|
+
reused: useReferences ? "ref" : "inline"
|
|
18432
|
+
})
|
|
18433
|
+
),
|
|
18382
18434
|
{
|
|
18383
18435
|
validate: async (value) => {
|
|
18384
18436
|
const result = await safeParseAsync2(zodSchema2, value);
|
|
@@ -18473,8 +18525,8 @@ async function* executeTool({
|
|
|
18473
18525
|
}
|
|
18474
18526
|
}
|
|
18475
18527
|
|
|
18476
|
-
// ../../node_modules/.
|
|
18477
|
-
var VERSION2 = true ? "2.0.
|
|
18528
|
+
// ../../node_modules/.bun/@ai-sdk+anthropic@2.0.56+27912429049419a2/node_modules/@ai-sdk/anthropic/dist/index.mjs
|
|
18529
|
+
var VERSION2 = true ? "2.0.56" : "0.0.0-test";
|
|
18478
18530
|
var anthropicErrorDataSchema = lazySchema(
|
|
18479
18531
|
() => zodSchema(
|
|
18480
18532
|
external_exports2.object({
|
|
@@ -18562,11 +18614,18 @@ var anthropicMessagesResponseSchema = lazySchema(
|
|
|
18562
18614
|
type: external_exports2.literal("document"),
|
|
18563
18615
|
title: external_exports2.string().nullable(),
|
|
18564
18616
|
citations: external_exports2.object({ enabled: external_exports2.boolean() }).optional(),
|
|
18565
|
-
source: external_exports2.
|
|
18566
|
-
|
|
18567
|
-
|
|
18568
|
-
|
|
18569
|
-
|
|
18617
|
+
source: external_exports2.union([
|
|
18618
|
+
external_exports2.object({
|
|
18619
|
+
type: external_exports2.literal("base64"),
|
|
18620
|
+
media_type: external_exports2.literal("application/pdf"),
|
|
18621
|
+
data: external_exports2.string()
|
|
18622
|
+
}),
|
|
18623
|
+
external_exports2.object({
|
|
18624
|
+
type: external_exports2.literal("text"),
|
|
18625
|
+
media_type: external_exports2.literal("text/plain"),
|
|
18626
|
+
data: external_exports2.string()
|
|
18627
|
+
})
|
|
18628
|
+
])
|
|
18570
18629
|
})
|
|
18571
18630
|
}),
|
|
18572
18631
|
external_exports2.object({
|
|
@@ -18745,11 +18804,18 @@ var anthropicMessagesChunkSchema = lazySchema(
|
|
|
18745
18804
|
type: external_exports2.literal("document"),
|
|
18746
18805
|
title: external_exports2.string().nullable(),
|
|
18747
18806
|
citations: external_exports2.object({ enabled: external_exports2.boolean() }).optional(),
|
|
18748
|
-
source: external_exports2.
|
|
18749
|
-
|
|
18750
|
-
|
|
18751
|
-
|
|
18752
|
-
|
|
18807
|
+
source: external_exports2.union([
|
|
18808
|
+
external_exports2.object({
|
|
18809
|
+
type: external_exports2.literal("base64"),
|
|
18810
|
+
media_type: external_exports2.literal("application/pdf"),
|
|
18811
|
+
data: external_exports2.string()
|
|
18812
|
+
}),
|
|
18813
|
+
external_exports2.object({
|
|
18814
|
+
type: external_exports2.literal("text"),
|
|
18815
|
+
media_type: external_exports2.literal("text/plain"),
|
|
18816
|
+
data: external_exports2.string()
|
|
18817
|
+
})
|
|
18818
|
+
])
|
|
18753
18819
|
})
|
|
18754
18820
|
}),
|
|
18755
18821
|
external_exports2.object({
|
|
@@ -19120,7 +19186,7 @@ var webSearch_20250305OutputSchema = lazySchema(
|
|
|
19120
19186
|
external_exports2.array(
|
|
19121
19187
|
external_exports2.object({
|
|
19122
19188
|
url: external_exports2.string(),
|
|
19123
|
-
title: external_exports2.string(),
|
|
19189
|
+
title: external_exports2.string().nullable(),
|
|
19124
19190
|
pageAge: external_exports2.string().nullable(),
|
|
19125
19191
|
encryptedContent: external_exports2.string(),
|
|
19126
19192
|
type: external_exports2.literal("web_search_result")
|
|
@@ -19162,7 +19228,7 @@ var webFetch_20250910OutputSchema = lazySchema(
|
|
|
19162
19228
|
url: external_exports2.string(),
|
|
19163
19229
|
content: external_exports2.object({
|
|
19164
19230
|
type: external_exports2.literal("document"),
|
|
19165
|
-
title: external_exports2.string(),
|
|
19231
|
+
title: external_exports2.string().nullable(),
|
|
19166
19232
|
citations: external_exports2.object({ enabled: external_exports2.boolean() }).optional(),
|
|
19167
19233
|
source: external_exports2.union([
|
|
19168
19234
|
external_exports2.object({
|
|
@@ -21631,7 +21697,7 @@ function createAnthropic(options = {}) {
|
|
|
21631
21697
|
}
|
|
21632
21698
|
var anthropic = createAnthropic();
|
|
21633
21699
|
|
|
21634
|
-
// ../../node_modules/.
|
|
21700
|
+
// ../../node_modules/.bun/@ai-sdk+openai@2.0.85+27912429049419a2/node_modules/@ai-sdk/openai/dist/internal/index.mjs
|
|
21635
21701
|
var openaiErrorDataSchema = external_exports2.object({
|
|
21636
21702
|
error: external_exports2.object({
|
|
21637
21703
|
message: external_exports2.string(),
|
|
@@ -21647,6 +21713,20 @@ var openaiFailedResponseHandler = createJsonErrorResponseHandler({
|
|
|
21647
21713
|
errorSchema: openaiErrorDataSchema,
|
|
21648
21714
|
errorToMessage: (data) => data.error.message
|
|
21649
21715
|
});
|
|
21716
|
+
function getOpenAILanguageModelCapabilities(modelId) {
|
|
21717
|
+
const supportsFlexProcessing = modelId.startsWith("o3") || modelId.startsWith("o4-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-chat");
|
|
21718
|
+
const supportsPriorityProcessing = modelId.startsWith("gpt-4") || modelId.startsWith("gpt-5-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-nano") && !modelId.startsWith("gpt-5-chat") || modelId.startsWith("o3") || modelId.startsWith("o4-mini");
|
|
21719
|
+
const isReasoningModel = !(modelId.startsWith("gpt-3") || modelId.startsWith("gpt-4") || modelId.startsWith("chatgpt-4o") || modelId.startsWith("gpt-5-chat"));
|
|
21720
|
+
const supportsNonReasoningParameters = modelId.startsWith("gpt-5.1");
|
|
21721
|
+
const systemMessageMode = isReasoningModel ? "developer" : "system";
|
|
21722
|
+
return {
|
|
21723
|
+
supportsFlexProcessing,
|
|
21724
|
+
supportsPriorityProcessing,
|
|
21725
|
+
isReasoningModel,
|
|
21726
|
+
systemMessageMode,
|
|
21727
|
+
supportsNonReasoningParameters
|
|
21728
|
+
};
|
|
21729
|
+
}
|
|
21650
21730
|
function convertToOpenAIChatMessages({
|
|
21651
21731
|
prompt,
|
|
21652
21732
|
systemMessageMode = "system"
|
|
@@ -22013,7 +22093,7 @@ var openaiChatLanguageModelOptions = lazyValidator(
|
|
|
22013
22093
|
/**
|
|
22014
22094
|
* Reasoning effort for reasoning models. Defaults to `medium`.
|
|
22015
22095
|
*/
|
|
22016
|
-
reasoningEffort: external_exports2.enum(["none", "minimal", "low", "medium", "high"]).optional(),
|
|
22096
|
+
reasoningEffort: external_exports2.enum(["none", "minimal", "low", "medium", "high", "xhigh"]).optional(),
|
|
22017
22097
|
/**
|
|
22018
22098
|
* Maximum number of completion tokens to generate. Useful for reasoning models.
|
|
22019
22099
|
*/
|
|
@@ -22176,6 +22256,7 @@ var OpenAIChatLanguageModel = class {
|
|
|
22176
22256
|
schema: openaiChatLanguageModelOptions
|
|
22177
22257
|
})) != null ? _a17 : {};
|
|
22178
22258
|
const structuredOutputs = (_b8 = openaiOptions.structuredOutputs) != null ? _b8 : true;
|
|
22259
|
+
const modelCapabilities = getOpenAILanguageModelCapabilities(this.modelId);
|
|
22179
22260
|
if (topK != null) {
|
|
22180
22261
|
warnings.push({
|
|
22181
22262
|
type: "unsupported-setting",
|
|
@@ -22192,7 +22273,7 @@ var OpenAIChatLanguageModel = class {
|
|
|
22192
22273
|
const { messages, warnings: messageWarnings } = convertToOpenAIChatMessages(
|
|
22193
22274
|
{
|
|
22194
22275
|
prompt,
|
|
22195
|
-
systemMessageMode:
|
|
22276
|
+
systemMessageMode: modelCapabilities.systemMessageMode
|
|
22196
22277
|
}
|
|
22197
22278
|
);
|
|
22198
22279
|
warnings.push(...messageWarnings);
|
|
@@ -22238,22 +22319,31 @@ var OpenAIChatLanguageModel = class {
|
|
|
22238
22319
|
// messages:
|
|
22239
22320
|
messages
|
|
22240
22321
|
};
|
|
22241
|
-
if (isReasoningModel
|
|
22242
|
-
if (
|
|
22243
|
-
baseArgs.temperature
|
|
22244
|
-
|
|
22245
|
-
|
|
22246
|
-
|
|
22247
|
-
|
|
22248
|
-
|
|
22249
|
-
|
|
22250
|
-
|
|
22251
|
-
baseArgs.top_p
|
|
22252
|
-
|
|
22253
|
-
|
|
22254
|
-
|
|
22255
|
-
|
|
22256
|
-
|
|
22322
|
+
if (modelCapabilities.isReasoningModel) {
|
|
22323
|
+
if (openaiOptions.reasoningEffort !== "none" || !modelCapabilities.supportsNonReasoningParameters) {
|
|
22324
|
+
if (baseArgs.temperature != null) {
|
|
22325
|
+
baseArgs.temperature = void 0;
|
|
22326
|
+
warnings.push({
|
|
22327
|
+
type: "unsupported-setting",
|
|
22328
|
+
setting: "temperature",
|
|
22329
|
+
details: "temperature is not supported for reasoning models"
|
|
22330
|
+
});
|
|
22331
|
+
}
|
|
22332
|
+
if (baseArgs.top_p != null) {
|
|
22333
|
+
baseArgs.top_p = void 0;
|
|
22334
|
+
warnings.push({
|
|
22335
|
+
type: "unsupported-setting",
|
|
22336
|
+
setting: "topP",
|
|
22337
|
+
details: "topP is not supported for reasoning models"
|
|
22338
|
+
});
|
|
22339
|
+
}
|
|
22340
|
+
if (baseArgs.logprobs != null) {
|
|
22341
|
+
baseArgs.logprobs = void 0;
|
|
22342
|
+
warnings.push({
|
|
22343
|
+
type: "other",
|
|
22344
|
+
message: "logprobs is not supported for reasoning models"
|
|
22345
|
+
});
|
|
22346
|
+
}
|
|
22257
22347
|
}
|
|
22258
22348
|
if (baseArgs.frequency_penalty != null) {
|
|
22259
22349
|
baseArgs.frequency_penalty = void 0;
|
|
@@ -22278,13 +22368,6 @@ var OpenAIChatLanguageModel = class {
|
|
|
22278
22368
|
message: "logitBias is not supported for reasoning models"
|
|
22279
22369
|
});
|
|
22280
22370
|
}
|
|
22281
|
-
if (baseArgs.logprobs != null) {
|
|
22282
|
-
baseArgs.logprobs = void 0;
|
|
22283
|
-
warnings.push({
|
|
22284
|
-
type: "other",
|
|
22285
|
-
message: "logprobs is not supported for reasoning models"
|
|
22286
|
-
});
|
|
22287
|
-
}
|
|
22288
22371
|
if (baseArgs.top_logprobs != null) {
|
|
22289
22372
|
baseArgs.top_logprobs = void 0;
|
|
22290
22373
|
warnings.push({
|
|
@@ -22308,7 +22391,7 @@ var OpenAIChatLanguageModel = class {
|
|
|
22308
22391
|
});
|
|
22309
22392
|
}
|
|
22310
22393
|
}
|
|
22311
|
-
if (openaiOptions.serviceTier === "flex" && !supportsFlexProcessing
|
|
22394
|
+
if (openaiOptions.serviceTier === "flex" && !modelCapabilities.supportsFlexProcessing) {
|
|
22312
22395
|
warnings.push({
|
|
22313
22396
|
type: "unsupported-setting",
|
|
22314
22397
|
setting: "serviceTier",
|
|
@@ -22316,7 +22399,7 @@ var OpenAIChatLanguageModel = class {
|
|
|
22316
22399
|
});
|
|
22317
22400
|
baseArgs.service_tier = void 0;
|
|
22318
22401
|
}
|
|
22319
|
-
if (openaiOptions.serviceTier === "priority" && !supportsPriorityProcessing
|
|
22402
|
+
if (openaiOptions.serviceTier === "priority" && !modelCapabilities.supportsPriorityProcessing) {
|
|
22320
22403
|
warnings.push({
|
|
22321
22404
|
type: "unsupported-setting",
|
|
22322
22405
|
setting: "serviceTier",
|
|
@@ -22637,42 +22720,6 @@ var OpenAIChatLanguageModel = class {
|
|
|
22637
22720
|
};
|
|
22638
22721
|
}
|
|
22639
22722
|
};
|
|
22640
|
-
function isReasoningModel(modelId) {
|
|
22641
|
-
return (modelId.startsWith("o") || modelId.startsWith("gpt-5")) && !modelId.startsWith("gpt-5-chat");
|
|
22642
|
-
}
|
|
22643
|
-
function supportsFlexProcessing(modelId) {
|
|
22644
|
-
return modelId.startsWith("o3") || modelId.startsWith("o4-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-chat");
|
|
22645
|
-
}
|
|
22646
|
-
function supportsPriorityProcessing(modelId) {
|
|
22647
|
-
return modelId.startsWith("gpt-4") || modelId.startsWith("gpt-5-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-nano") && !modelId.startsWith("gpt-5-chat") || modelId.startsWith("o3") || modelId.startsWith("o4-mini");
|
|
22648
|
-
}
|
|
22649
|
-
function getSystemMessageMode(modelId) {
|
|
22650
|
-
var _a17, _b8;
|
|
22651
|
-
if (!isReasoningModel(modelId)) {
|
|
22652
|
-
return "system";
|
|
22653
|
-
}
|
|
22654
|
-
return (_b8 = (_a17 = reasoningModels[modelId]) == null ? void 0 : _a17.systemMessageMode) != null ? _b8 : "developer";
|
|
22655
|
-
}
|
|
22656
|
-
var reasoningModels = {
|
|
22657
|
-
o3: {
|
|
22658
|
-
systemMessageMode: "developer"
|
|
22659
|
-
},
|
|
22660
|
-
"o3-2025-04-16": {
|
|
22661
|
-
systemMessageMode: "developer"
|
|
22662
|
-
},
|
|
22663
|
-
"o3-mini": {
|
|
22664
|
-
systemMessageMode: "developer"
|
|
22665
|
-
},
|
|
22666
|
-
"o3-mini-2025-01-31": {
|
|
22667
|
-
systemMessageMode: "developer"
|
|
22668
|
-
},
|
|
22669
|
-
"o4-mini": {
|
|
22670
|
-
systemMessageMode: "developer"
|
|
22671
|
-
},
|
|
22672
|
-
"o4-mini-2025-04-16": {
|
|
22673
|
-
systemMessageMode: "developer"
|
|
22674
|
-
}
|
|
22675
|
-
};
|
|
22676
22723
|
function convertToOpenAICompletionPrompt({
|
|
22677
22724
|
prompt,
|
|
22678
22725
|
user = "user",
|
|
@@ -24096,12 +24143,12 @@ var openaiResponsesChunkSchema = lazyValidator(
|
|
|
24096
24143
|
}),
|
|
24097
24144
|
external_exports2.object({
|
|
24098
24145
|
type: external_exports2.literal("open_page"),
|
|
24099
|
-
url: external_exports2.string()
|
|
24146
|
+
url: external_exports2.string().nullish()
|
|
24100
24147
|
}),
|
|
24101
24148
|
external_exports2.object({
|
|
24102
|
-
type: external_exports2.literal("
|
|
24103
|
-
url: external_exports2.string(),
|
|
24104
|
-
pattern: external_exports2.string()
|
|
24149
|
+
type: external_exports2.literal("find_in_page"),
|
|
24150
|
+
url: external_exports2.string().nullish(),
|
|
24151
|
+
pattern: external_exports2.string().nullish()
|
|
24105
24152
|
})
|
|
24106
24153
|
])
|
|
24107
24154
|
}),
|
|
@@ -24306,12 +24353,12 @@ var openaiResponsesResponseSchema = lazyValidator(
|
|
|
24306
24353
|
}),
|
|
24307
24354
|
external_exports2.object({
|
|
24308
24355
|
type: external_exports2.literal("open_page"),
|
|
24309
|
-
url: external_exports2.string()
|
|
24356
|
+
url: external_exports2.string().nullish()
|
|
24310
24357
|
}),
|
|
24311
24358
|
external_exports2.object({
|
|
24312
|
-
type: external_exports2.literal("
|
|
24313
|
-
url: external_exports2.string(),
|
|
24314
|
-
pattern: external_exports2.string()
|
|
24359
|
+
type: external_exports2.literal("find_in_page"),
|
|
24360
|
+
url: external_exports2.string().nullish(),
|
|
24361
|
+
pattern: external_exports2.string().nullish()
|
|
24315
24362
|
})
|
|
24316
24363
|
])
|
|
24317
24364
|
}),
|
|
@@ -24426,7 +24473,11 @@ var openaiResponsesReasoningModelIds = [
|
|
|
24426
24473
|
"gpt-5.1",
|
|
24427
24474
|
"gpt-5.1-chat-latest",
|
|
24428
24475
|
"gpt-5.1-codex-mini",
|
|
24429
|
-
"gpt-5.1-codex"
|
|
24476
|
+
"gpt-5.1-codex",
|
|
24477
|
+
"gpt-5.1-codex-max",
|
|
24478
|
+
"gpt-5.2",
|
|
24479
|
+
"gpt-5.2-chat-latest",
|
|
24480
|
+
"gpt-5.2-pro"
|
|
24430
24481
|
];
|
|
24431
24482
|
var openaiResponsesModelIds = [
|
|
24432
24483
|
"gpt-4.1",
|
|
@@ -24509,6 +24560,16 @@ var openaiResponsesProviderOptionsSchema = lazyValidator(
|
|
|
24509
24560
|
* @default 'in_memory'
|
|
24510
24561
|
*/
|
|
24511
24562
|
promptCacheRetention: external_exports2.enum(["in_memory", "24h"]).nullish(),
|
|
24563
|
+
/**
|
|
24564
|
+
* Reasoning effort for reasoning models. Defaults to `medium`. If you use
|
|
24565
|
+
* `providerOptions` to set the `reasoningEffort` option, this model setting will be ignored.
|
|
24566
|
+
* Valid values: 'none' | 'minimal' | 'low' | 'medium' | 'high' | 'xhigh'
|
|
24567
|
+
*
|
|
24568
|
+
* The 'none' type for `reasoningEffort` is only available for OpenAI's GPT-5.1
|
|
24569
|
+
* models. Also, the 'xhigh' type for `reasoningEffort` is only available for
|
|
24570
|
+
* OpenAI's GPT-5.1-Codex-Max model. Setting `reasoningEffort` to 'none' or 'xhigh' with unsupported models will result in
|
|
24571
|
+
* an error.
|
|
24572
|
+
*/
|
|
24512
24573
|
reasoningEffort: external_exports2.string().nullish(),
|
|
24513
24574
|
reasoningSummary: external_exports2.string().nullish(),
|
|
24514
24575
|
safetyIdentifier: external_exports2.string().nullish(),
|
|
@@ -24564,8 +24625,8 @@ var codeInterpreter = (args = {}) => {
|
|
|
24564
24625
|
};
|
|
24565
24626
|
var comparisonFilterSchema = external_exports2.object({
|
|
24566
24627
|
key: external_exports2.string(),
|
|
24567
|
-
type: external_exports2.enum(["eq", "ne", "gt", "gte", "lt", "lte"]),
|
|
24568
|
-
value: external_exports2.union([external_exports2.string(), external_exports2.number(), external_exports2.boolean()])
|
|
24628
|
+
type: external_exports2.enum(["eq", "ne", "gt", "gte", "lt", "lte", "in", "nin"]),
|
|
24629
|
+
value: external_exports2.union([external_exports2.string(), external_exports2.number(), external_exports2.boolean(), external_exports2.array(external_exports2.string())])
|
|
24569
24630
|
});
|
|
24570
24631
|
var compoundFilterSchema = external_exports2.object({
|
|
24571
24632
|
type: external_exports2.enum(["and", "or"]),
|
|
@@ -24635,12 +24696,12 @@ var webSearchOutputSchema = lazySchema(
|
|
|
24635
24696
|
}),
|
|
24636
24697
|
external_exports2.object({
|
|
24637
24698
|
type: external_exports2.literal("openPage"),
|
|
24638
|
-
url: external_exports2.string()
|
|
24699
|
+
url: external_exports2.string().nullish()
|
|
24639
24700
|
}),
|
|
24640
24701
|
external_exports2.object({
|
|
24641
|
-
type: external_exports2.literal("
|
|
24642
|
-
url: external_exports2.string(),
|
|
24643
|
-
pattern: external_exports2.string()
|
|
24702
|
+
type: external_exports2.literal("findInPage"),
|
|
24703
|
+
url: external_exports2.string().nullish(),
|
|
24704
|
+
pattern: external_exports2.string().nullish()
|
|
24644
24705
|
})
|
|
24645
24706
|
]),
|
|
24646
24707
|
sources: external_exports2.array(
|
|
@@ -24685,12 +24746,12 @@ var webSearchPreviewOutputSchema = lazySchema(
|
|
|
24685
24746
|
}),
|
|
24686
24747
|
external_exports2.object({
|
|
24687
24748
|
type: external_exports2.literal("openPage"),
|
|
24688
|
-
url: external_exports2.string()
|
|
24749
|
+
url: external_exports2.string().nullish()
|
|
24689
24750
|
}),
|
|
24690
24751
|
external_exports2.object({
|
|
24691
|
-
type: external_exports2.literal("
|
|
24692
|
-
url: external_exports2.string(),
|
|
24693
|
-
pattern: external_exports2.string()
|
|
24752
|
+
type: external_exports2.literal("findInPage"),
|
|
24753
|
+
url: external_exports2.string().nullish(),
|
|
24754
|
+
pattern: external_exports2.string().nullish()
|
|
24694
24755
|
})
|
|
24695
24756
|
])
|
|
24696
24757
|
})
|
|
@@ -24901,7 +24962,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
24901
24962
|
}) {
|
|
24902
24963
|
var _a17, _b8, _c, _d;
|
|
24903
24964
|
const warnings = [];
|
|
24904
|
-
const
|
|
24965
|
+
const modelCapabilities = getOpenAILanguageModelCapabilities(this.modelId);
|
|
24905
24966
|
if (topK != null) {
|
|
24906
24967
|
warnings.push({ type: "unsupported-setting", setting: "topK" });
|
|
24907
24968
|
}
|
|
@@ -24937,7 +24998,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
24937
24998
|
}
|
|
24938
24999
|
const { input, warnings: inputWarnings } = await convertToOpenAIResponsesInput({
|
|
24939
25000
|
prompt,
|
|
24940
|
-
systemMessageMode:
|
|
25001
|
+
systemMessageMode: modelCapabilities.systemMessageMode,
|
|
24941
25002
|
fileIdPrefixes: this.config.fileIdPrefixes,
|
|
24942
25003
|
store: (_a17 = openaiOptions == null ? void 0 : openaiOptions.store) != null ? _a17 : true,
|
|
24943
25004
|
hasLocalShellTool: hasOpenAITool("openai.local_shell")
|
|
@@ -24971,7 +25032,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
24971
25032
|
addInclude("code_interpreter_call.outputs");
|
|
24972
25033
|
}
|
|
24973
25034
|
const store = openaiOptions == null ? void 0 : openaiOptions.store;
|
|
24974
|
-
if (store === false &&
|
|
25035
|
+
if (store === false && modelCapabilities.isReasoningModel) {
|
|
24975
25036
|
addInclude("reasoning.encrypted_content");
|
|
24976
25037
|
}
|
|
24977
25038
|
const baseArgs = {
|
|
@@ -25013,7 +25074,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
25013
25074
|
top_logprobs: topLogprobs,
|
|
25014
25075
|
truncation: openaiOptions == null ? void 0 : openaiOptions.truncation,
|
|
25015
25076
|
// model-specific settings:
|
|
25016
|
-
...
|
|
25077
|
+
...modelCapabilities.isReasoningModel && ((openaiOptions == null ? void 0 : openaiOptions.reasoningEffort) != null || (openaiOptions == null ? void 0 : openaiOptions.reasoningSummary) != null) && {
|
|
25017
25078
|
reasoning: {
|
|
25018
25079
|
...(openaiOptions == null ? void 0 : openaiOptions.reasoningEffort) != null && {
|
|
25019
25080
|
effort: openaiOptions.reasoningEffort
|
|
@@ -25024,22 +25085,24 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
25024
25085
|
}
|
|
25025
25086
|
}
|
|
25026
25087
|
};
|
|
25027
|
-
if (
|
|
25028
|
-
if (
|
|
25029
|
-
baseArgs.temperature
|
|
25030
|
-
|
|
25031
|
-
|
|
25032
|
-
|
|
25033
|
-
|
|
25034
|
-
|
|
25035
|
-
|
|
25036
|
-
|
|
25037
|
-
baseArgs.top_p
|
|
25038
|
-
|
|
25039
|
-
|
|
25040
|
-
|
|
25041
|
-
|
|
25042
|
-
|
|
25088
|
+
if (modelCapabilities.isReasoningModel) {
|
|
25089
|
+
if (!((openaiOptions == null ? void 0 : openaiOptions.reasoningEffort) === "none" && modelCapabilities.supportsNonReasoningParameters)) {
|
|
25090
|
+
if (baseArgs.temperature != null) {
|
|
25091
|
+
baseArgs.temperature = void 0;
|
|
25092
|
+
warnings.push({
|
|
25093
|
+
type: "unsupported-setting",
|
|
25094
|
+
setting: "temperature",
|
|
25095
|
+
details: "temperature is not supported for reasoning models"
|
|
25096
|
+
});
|
|
25097
|
+
}
|
|
25098
|
+
if (baseArgs.top_p != null) {
|
|
25099
|
+
baseArgs.top_p = void 0;
|
|
25100
|
+
warnings.push({
|
|
25101
|
+
type: "unsupported-setting",
|
|
25102
|
+
setting: "topP",
|
|
25103
|
+
details: "topP is not supported for reasoning models"
|
|
25104
|
+
});
|
|
25105
|
+
}
|
|
25043
25106
|
}
|
|
25044
25107
|
} else {
|
|
25045
25108
|
if ((openaiOptions == null ? void 0 : openaiOptions.reasoningEffort) != null) {
|
|
@@ -25057,7 +25120,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
25057
25120
|
});
|
|
25058
25121
|
}
|
|
25059
25122
|
}
|
|
25060
|
-
if ((openaiOptions == null ? void 0 : openaiOptions.serviceTier) === "flex" && !
|
|
25123
|
+
if ((openaiOptions == null ? void 0 : openaiOptions.serviceTier) === "flex" && !modelCapabilities.supportsFlexProcessing) {
|
|
25061
25124
|
warnings.push({
|
|
25062
25125
|
type: "unsupported-setting",
|
|
25063
25126
|
setting: "serviceTier",
|
|
@@ -25065,7 +25128,7 @@ var OpenAIResponsesLanguageModel = class {
|
|
|
25065
25128
|
});
|
|
25066
25129
|
delete baseArgs.service_tier;
|
|
25067
25130
|
}
|
|
25068
|
-
if ((openaiOptions == null ? void 0 : openaiOptions.serviceTier) === "priority" && !
|
|
25131
|
+
if ((openaiOptions == null ? void 0 : openaiOptions.serviceTier) === "priority" && !modelCapabilities.supportsPriorityProcessing) {
|
|
25069
25132
|
warnings.push({
|
|
25070
25133
|
type: "unsupported-setting",
|
|
25071
25134
|
setting: "serviceTier",
|
|
@@ -25922,32 +25985,6 @@ function isResponseAnnotationAddedChunk(chunk) {
|
|
|
25922
25985
|
function isErrorChunk(chunk) {
|
|
25923
25986
|
return chunk.type === "error";
|
|
25924
25987
|
}
|
|
25925
|
-
function getResponsesModelConfig(modelId) {
|
|
25926
|
-
const supportsFlexProcessing2 = modelId.startsWith("o3") || modelId.startsWith("o4-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-chat");
|
|
25927
|
-
const supportsPriorityProcessing2 = modelId.startsWith("gpt-4") || modelId.startsWith("gpt-5-mini") || modelId.startsWith("gpt-5") && !modelId.startsWith("gpt-5-nano") && !modelId.startsWith("gpt-5-chat") || modelId.startsWith("o3") || modelId.startsWith("o4-mini");
|
|
25928
|
-
const defaults = {
|
|
25929
|
-
systemMessageMode: "system",
|
|
25930
|
-
supportsFlexProcessing: supportsFlexProcessing2,
|
|
25931
|
-
supportsPriorityProcessing: supportsPriorityProcessing2
|
|
25932
|
-
};
|
|
25933
|
-
if (modelId.startsWith("gpt-5-chat")) {
|
|
25934
|
-
return {
|
|
25935
|
-
...defaults,
|
|
25936
|
-
isReasoningModel: false
|
|
25937
|
-
};
|
|
25938
|
-
}
|
|
25939
|
-
if (modelId.startsWith("o") || modelId.startsWith("gpt-5") || modelId.startsWith("codex-") || modelId.startsWith("computer-use")) {
|
|
25940
|
-
return {
|
|
25941
|
-
...defaults,
|
|
25942
|
-
isReasoningModel: true,
|
|
25943
|
-
systemMessageMode: "developer"
|
|
25944
|
-
};
|
|
25945
|
-
}
|
|
25946
|
-
return {
|
|
25947
|
-
...defaults,
|
|
25948
|
-
isReasoningModel: false
|
|
25949
|
-
};
|
|
25950
|
-
}
|
|
25951
25988
|
function mapWebSearchOutput(action) {
|
|
25952
25989
|
var _a17;
|
|
25953
25990
|
switch (action.type) {
|
|
@@ -25959,21 +25996,25 @@ function mapWebSearchOutput(action) {
|
|
|
25959
25996
|
};
|
|
25960
25997
|
case "open_page":
|
|
25961
25998
|
return { action: { type: "openPage", url: action.url } };
|
|
25962
|
-
case "
|
|
25999
|
+
case "find_in_page":
|
|
25963
26000
|
return {
|
|
25964
|
-
action: {
|
|
26001
|
+
action: {
|
|
26002
|
+
type: "findInPage",
|
|
26003
|
+
url: action.url,
|
|
26004
|
+
pattern: action.pattern
|
|
26005
|
+
}
|
|
25965
26006
|
};
|
|
25966
26007
|
}
|
|
25967
26008
|
}
|
|
25968
26009
|
|
|
25969
|
-
// ../../node_modules/.
|
|
26010
|
+
// ../../node_modules/.bun/@ai-sdk+azure@2.0.87+27912429049419a2/node_modules/@ai-sdk/azure/dist/index.mjs
|
|
25970
26011
|
var azureOpenaiTools = {
|
|
25971
26012
|
codeInterpreter,
|
|
25972
26013
|
fileSearch,
|
|
25973
26014
|
imageGeneration,
|
|
25974
26015
|
webSearchPreview
|
|
25975
26016
|
};
|
|
25976
|
-
var VERSION3 = true ? "2.0.
|
|
26017
|
+
var VERSION3 = true ? "2.0.87" : "0.0.0-test";
|
|
25977
26018
|
function createAzure(options = {}) {
|
|
25978
26019
|
var _a17;
|
|
25979
26020
|
const getHeaders = () => {
|
|
@@ -26073,8 +26114,8 @@ function createAzure(options = {}) {
|
|
|
26073
26114
|
}
|
|
26074
26115
|
var azure = createAzure();
|
|
26075
26116
|
|
|
26076
|
-
// ../../node_modules/.
|
|
26077
|
-
var VERSION4 = true ? "2.0.
|
|
26117
|
+
// ../../node_modules/.bun/@ai-sdk+google@2.0.46+27912429049419a2/node_modules/@ai-sdk/google/dist/index.mjs
|
|
26118
|
+
var VERSION4 = true ? "2.0.46" : "0.0.0-test";
|
|
26078
26119
|
var googleErrorDataSchema = lazySchema(
|
|
26079
26120
|
() => zodSchema(
|
|
26080
26121
|
external_exports2.object({
|
|
@@ -27758,7 +27799,7 @@ function createGoogleGenerativeAI(options = {}) {
|
|
|
27758
27799
|
}
|
|
27759
27800
|
var google = createGoogleGenerativeAI();
|
|
27760
27801
|
|
|
27761
|
-
// ../../node_modules/.
|
|
27802
|
+
// ../../node_modules/.bun/@ai-sdk+gateway@2.0.21+27912429049419a2/node_modules/@ai-sdk/gateway/dist/index.mjs
|
|
27762
27803
|
var import_oidc = __toESM(require_dist(), 1);
|
|
27763
27804
|
var import_oidc2 = __toESM(require_dist(), 1);
|
|
27764
27805
|
var marker15 = "vercel.ai.gateway.error";
|
|
@@ -28474,7 +28515,7 @@ async function getVercelRequestId() {
|
|
|
28474
28515
|
var _a83;
|
|
28475
28516
|
return (_a83 = (0, import_oidc.getContext)().headers) == null ? void 0 : _a83["x-vercel-id"];
|
|
28476
28517
|
}
|
|
28477
|
-
var VERSION5 = true ? "2.0.
|
|
28518
|
+
var VERSION5 = true ? "2.0.21" : "0.0.0-test";
|
|
28478
28519
|
var AI_GATEWAY_PROTOCOL_VERSION = "0.0.1";
|
|
28479
28520
|
function createGatewayProvider(options = {}) {
|
|
28480
28521
|
var _a83, _b8;
|
|
@@ -28621,13 +28662,13 @@ async function getGatewayAuthToken(options) {
|
|
|
28621
28662
|
}
|
|
28622
28663
|
}
|
|
28623
28664
|
|
|
28624
|
-
// ../../node_modules/.
|
|
28665
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/platform/node/globalThis.js
|
|
28625
28666
|
var _globalThis = typeof globalThis === "object" ? globalThis : global;
|
|
28626
28667
|
|
|
28627
|
-
// ../../node_modules/.
|
|
28668
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/version.js
|
|
28628
28669
|
var VERSION6 = "1.9.0";
|
|
28629
28670
|
|
|
28630
|
-
// ../../node_modules/.
|
|
28671
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/internal/semver.js
|
|
28631
28672
|
var re = /^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;
|
|
28632
28673
|
function _makeCompatibilityCheck(ownVersion) {
|
|
28633
28674
|
var acceptedVersions = /* @__PURE__ */ new Set([ownVersion]);
|
|
@@ -28694,7 +28735,7 @@ function _makeCompatibilityCheck(ownVersion) {
|
|
|
28694
28735
|
}
|
|
28695
28736
|
var isCompatible = _makeCompatibilityCheck(VERSION6);
|
|
28696
28737
|
|
|
28697
|
-
// ../../node_modules/.
|
|
28738
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/internal/global-utils.js
|
|
28698
28739
|
var major = VERSION6.split(".")[0];
|
|
28699
28740
|
var GLOBAL_OPENTELEMETRY_API_KEY = Symbol.for("opentelemetry.js.api." + major);
|
|
28700
28741
|
var _global = _globalThis;
|
|
@@ -28736,7 +28777,7 @@ function unregisterGlobal(type, diag) {
|
|
|
28736
28777
|
}
|
|
28737
28778
|
}
|
|
28738
28779
|
|
|
28739
|
-
// ../../node_modules/.
|
|
28780
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/diag/ComponentLogger.js
|
|
28740
28781
|
var __read = function(o, n) {
|
|
28741
28782
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
28742
28783
|
if (!m) return o;
|
|
@@ -28816,7 +28857,7 @@ function logProxy(funcName, namespace, args) {
|
|
|
28816
28857
|
return logger[funcName].apply(logger, __spreadArray([], __read(args), false));
|
|
28817
28858
|
}
|
|
28818
28859
|
|
|
28819
|
-
// ../../node_modules/.
|
|
28860
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/diag/types.js
|
|
28820
28861
|
var DiagLogLevel;
|
|
28821
28862
|
(function(DiagLogLevel2) {
|
|
28822
28863
|
DiagLogLevel2[DiagLogLevel2["NONE"] = 0] = "NONE";
|
|
@@ -28828,7 +28869,7 @@ var DiagLogLevel;
|
|
|
28828
28869
|
DiagLogLevel2[DiagLogLevel2["ALL"] = 9999] = "ALL";
|
|
28829
28870
|
})(DiagLogLevel || (DiagLogLevel = {}));
|
|
28830
28871
|
|
|
28831
|
-
// ../../node_modules/.
|
|
28872
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/diag/internal/logLevelLogger.js
|
|
28832
28873
|
function createLogLevelDiagLogger(maxLevel, logger) {
|
|
28833
28874
|
if (maxLevel < DiagLogLevel.NONE) {
|
|
28834
28875
|
maxLevel = DiagLogLevel.NONE;
|
|
@@ -28853,7 +28894,7 @@ function createLogLevelDiagLogger(maxLevel, logger) {
|
|
|
28853
28894
|
};
|
|
28854
28895
|
}
|
|
28855
28896
|
|
|
28856
|
-
// ../../node_modules/.
|
|
28897
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/api/diag.js
|
|
28857
28898
|
var __read2 = function(o, n) {
|
|
28858
28899
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
28859
28900
|
if (!m) return o;
|
|
@@ -28945,7 +28986,7 @@ var DiagAPI = (
|
|
|
28945
28986
|
}()
|
|
28946
28987
|
);
|
|
28947
28988
|
|
|
28948
|
-
// ../../node_modules/.
|
|
28989
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/context/context.js
|
|
28949
28990
|
function createContextKey(description) {
|
|
28950
28991
|
return Symbol.for(description);
|
|
28951
28992
|
}
|
|
@@ -28974,7 +29015,7 @@ var BaseContext = (
|
|
|
28974
29015
|
);
|
|
28975
29016
|
var ROOT_CONTEXT = new BaseContext();
|
|
28976
29017
|
|
|
28977
|
-
// ../../node_modules/.
|
|
29018
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/context/NoopContextManager.js
|
|
28978
29019
|
var __read3 = function(o, n) {
|
|
28979
29020
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
28980
29021
|
if (!m) return o;
|
|
@@ -29029,7 +29070,7 @@ var NoopContextManager = (
|
|
|
29029
29070
|
}()
|
|
29030
29071
|
);
|
|
29031
29072
|
|
|
29032
|
-
// ../../node_modules/.
|
|
29073
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/api/context.js
|
|
29033
29074
|
var __read4 = function(o, n) {
|
|
29034
29075
|
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
29035
29076
|
if (!m) return o;
|
|
@@ -29097,14 +29138,14 @@ var ContextAPI = (
|
|
|
29097
29138
|
}()
|
|
29098
29139
|
);
|
|
29099
29140
|
|
|
29100
|
-
// ../../node_modules/.
|
|
29141
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/trace_flags.js
|
|
29101
29142
|
var TraceFlags;
|
|
29102
29143
|
(function(TraceFlags2) {
|
|
29103
29144
|
TraceFlags2[TraceFlags2["NONE"] = 0] = "NONE";
|
|
29104
29145
|
TraceFlags2[TraceFlags2["SAMPLED"] = 1] = "SAMPLED";
|
|
29105
29146
|
})(TraceFlags || (TraceFlags = {}));
|
|
29106
29147
|
|
|
29107
|
-
// ../../node_modules/.
|
|
29148
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/invalid-span-constants.js
|
|
29108
29149
|
var INVALID_SPANID = "0000000000000000";
|
|
29109
29150
|
var INVALID_TRACEID = "00000000000000000000000000000000";
|
|
29110
29151
|
var INVALID_SPAN_CONTEXT = {
|
|
@@ -29113,7 +29154,7 @@ var INVALID_SPAN_CONTEXT = {
|
|
|
29113
29154
|
traceFlags: TraceFlags.NONE
|
|
29114
29155
|
};
|
|
29115
29156
|
|
|
29116
|
-
// ../../node_modules/.
|
|
29157
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/NonRecordingSpan.js
|
|
29117
29158
|
var NonRecordingSpan = (
|
|
29118
29159
|
/** @class */
|
|
29119
29160
|
function() {
|
|
@@ -29158,7 +29199,7 @@ var NonRecordingSpan = (
|
|
|
29158
29199
|
}()
|
|
29159
29200
|
);
|
|
29160
29201
|
|
|
29161
|
-
// ../../node_modules/.
|
|
29202
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/context-utils.js
|
|
29162
29203
|
var SPAN_KEY = createContextKey("OpenTelemetry Context Key SPAN");
|
|
29163
29204
|
function getSpan(context) {
|
|
29164
29205
|
return context.getValue(SPAN_KEY) || void 0;
|
|
@@ -29180,7 +29221,7 @@ function getSpanContext(context) {
|
|
|
29180
29221
|
return (_a17 = getSpan(context)) === null || _a17 === void 0 ? void 0 : _a17.spanContext();
|
|
29181
29222
|
}
|
|
29182
29223
|
|
|
29183
|
-
// ../../node_modules/.
|
|
29224
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/spancontext-utils.js
|
|
29184
29225
|
var VALID_TRACEID_REGEX = /^([0-9a-f]{32})$/i;
|
|
29185
29226
|
var VALID_SPANID_REGEX = /^[0-9a-f]{16}$/i;
|
|
29186
29227
|
function isValidTraceId(traceId) {
|
|
@@ -29196,7 +29237,7 @@ function wrapSpanContext(spanContext) {
|
|
|
29196
29237
|
return new NonRecordingSpan(spanContext);
|
|
29197
29238
|
}
|
|
29198
29239
|
|
|
29199
|
-
// ../../node_modules/.
|
|
29240
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/NoopTracer.js
|
|
29200
29241
|
var contextApi = ContextAPI.getInstance();
|
|
29201
29242
|
var NoopTracer = (
|
|
29202
29243
|
/** @class */
|
|
@@ -29246,7 +29287,7 @@ function isSpanContext(spanContext) {
|
|
|
29246
29287
|
return typeof spanContext === "object" && typeof spanContext["spanId"] === "string" && typeof spanContext["traceId"] === "string" && typeof spanContext["traceFlags"] === "number";
|
|
29247
29288
|
}
|
|
29248
29289
|
|
|
29249
|
-
// ../../node_modules/.
|
|
29290
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/ProxyTracer.js
|
|
29250
29291
|
var NOOP_TRACER = new NoopTracer();
|
|
29251
29292
|
var ProxyTracer = (
|
|
29252
29293
|
/** @class */
|
|
@@ -29279,7 +29320,7 @@ var ProxyTracer = (
|
|
|
29279
29320
|
}()
|
|
29280
29321
|
);
|
|
29281
29322
|
|
|
29282
|
-
// ../../node_modules/.
|
|
29323
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/NoopTracerProvider.js
|
|
29283
29324
|
var NoopTracerProvider = (
|
|
29284
29325
|
/** @class */
|
|
29285
29326
|
function() {
|
|
@@ -29292,7 +29333,7 @@ var NoopTracerProvider = (
|
|
|
29292
29333
|
}()
|
|
29293
29334
|
);
|
|
29294
29335
|
|
|
29295
|
-
// ../../node_modules/.
|
|
29336
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/ProxyTracerProvider.js
|
|
29296
29337
|
var NOOP_TRACER_PROVIDER = new NoopTracerProvider();
|
|
29297
29338
|
var ProxyTracerProvider = (
|
|
29298
29339
|
/** @class */
|
|
@@ -29318,7 +29359,7 @@ var ProxyTracerProvider = (
|
|
|
29318
29359
|
}()
|
|
29319
29360
|
);
|
|
29320
29361
|
|
|
29321
|
-
// ../../node_modules/.
|
|
29362
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace/status.js
|
|
29322
29363
|
var SpanStatusCode;
|
|
29323
29364
|
(function(SpanStatusCode2) {
|
|
29324
29365
|
SpanStatusCode2[SpanStatusCode2["UNSET"] = 0] = "UNSET";
|
|
@@ -29326,7 +29367,7 @@ var SpanStatusCode;
|
|
|
29326
29367
|
SpanStatusCode2[SpanStatusCode2["ERROR"] = 2] = "ERROR";
|
|
29327
29368
|
})(SpanStatusCode || (SpanStatusCode = {}));
|
|
29328
29369
|
|
|
29329
|
-
// ../../node_modules/.
|
|
29370
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/api/trace.js
|
|
29330
29371
|
var API_NAME3 = "trace";
|
|
29331
29372
|
var TraceAPI = (
|
|
29332
29373
|
/** @class */
|
|
@@ -29369,10 +29410,10 @@ var TraceAPI = (
|
|
|
29369
29410
|
}()
|
|
29370
29411
|
);
|
|
29371
29412
|
|
|
29372
|
-
// ../../node_modules/.
|
|
29413
|
+
// ../../node_modules/.bun/@opentelemetry+api@1.9.0/node_modules/@opentelemetry/api/build/esm/trace-api.js
|
|
29373
29414
|
var trace = TraceAPI.getInstance();
|
|
29374
29415
|
|
|
29375
|
-
// ../../node_modules/.
|
|
29416
|
+
// ../../node_modules/.bun/ai@5.0.112+27912429049419a2/node_modules/ai/dist/index.mjs
|
|
29376
29417
|
var __defProp = Object.defineProperty;
|
|
29377
29418
|
var __export2 = (target, all) => {
|
|
29378
29419
|
for (var name16 in all)
|
|
@@ -29775,7 +29816,7 @@ function detectMediaType({
|
|
|
29775
29816
|
}
|
|
29776
29817
|
return void 0;
|
|
29777
29818
|
}
|
|
29778
|
-
var VERSION7 = true ? "5.0.
|
|
29819
|
+
var VERSION7 = true ? "5.0.112" : "0.0.0-test";
|
|
29779
29820
|
var download = async ({ url: url2 }) => {
|
|
29780
29821
|
var _a162;
|
|
29781
29822
|
const urlText = url2.toString();
|
|
@@ -30421,7 +30462,7 @@ function wrapGatewayError(error40) {
|
|
|
30421
30462
|
if (GatewayAuthenticationError.isInstance(error40) || GatewayModelNotFoundError.isInstance(error40)) {
|
|
30422
30463
|
return new AISDKError({
|
|
30423
30464
|
name: "GatewayError",
|
|
30424
|
-
message: "
|
|
30465
|
+
message: "Unauthenticated. Configure AI_GATEWAY_API_KEY or configure and use a provider module. Learn more: https://vercel.link/unauthenticated-ai-gateway",
|
|
30425
30466
|
cause: error40
|
|
30426
30467
|
});
|
|
30427
30468
|
}
|
|
@@ -32440,20 +32481,20 @@ import { promisify as promisify2 } from "node:util";
|
|
|
32440
32481
|
import { exec as execCallback, spawn as spawn2 } from "node:child_process";
|
|
32441
32482
|
import { randomUUID } from "node:crypto";
|
|
32442
32483
|
import { constants as constants22, createWriteStream } from "node:fs";
|
|
32443
|
-
import { access as access22,
|
|
32484
|
+
import { access as access22, mkdir as mkdir3, mkdtemp, rm as rm2, writeFile as writeFile3 } from "node:fs/promises";
|
|
32444
32485
|
import { tmpdir } from "node:os";
|
|
32445
32486
|
import path9 from "node:path";
|
|
32446
32487
|
import { promisify as promisify22 } from "node:util";
|
|
32447
32488
|
import path82 from "node:path";
|
|
32448
32489
|
import path10 from "node:path";
|
|
32449
32490
|
|
|
32450
|
-
// ../../node_modules/.
|
|
32491
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/vscode/agentDispatch.js
|
|
32451
32492
|
import { exec, spawn } from "child_process";
|
|
32452
32493
|
import { copyFile, mkdir as mkdir2, readdir as readdir2, readFile as readFile2, stat as stat2, writeFile } from "fs/promises";
|
|
32453
32494
|
import path6 from "path";
|
|
32454
32495
|
import { promisify } from "util";
|
|
32455
32496
|
|
|
32456
|
-
// ../../node_modules/.
|
|
32497
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/vscode/constants.js
|
|
32457
32498
|
import os from "os";
|
|
32458
32499
|
import path2 from "path";
|
|
32459
32500
|
var DEFAULT_LOCK_NAME = "subagent.lock";
|
|
@@ -32464,7 +32505,7 @@ function getDefaultSubagentRoot(vscodeCmd = "code") {
|
|
|
32464
32505
|
}
|
|
32465
32506
|
var DEFAULT_SUBAGENT_ROOT = getDefaultSubagentRoot();
|
|
32466
32507
|
|
|
32467
|
-
// ../../node_modules/.
|
|
32508
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/utils/fs.js
|
|
32468
32509
|
import { constants as constants2 } from "fs";
|
|
32469
32510
|
import { access as access2, mkdir, readdir, rm, stat } from "fs/promises";
|
|
32470
32511
|
import path3 from "path";
|
|
@@ -32497,7 +32538,7 @@ async function removeIfExists(target) {
|
|
|
32497
32538
|
}
|
|
32498
32539
|
}
|
|
32499
32540
|
|
|
32500
|
-
// ../../node_modules/.
|
|
32541
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/utils/path.js
|
|
32501
32542
|
import path4 from "path";
|
|
32502
32543
|
function pathToFileUri(filePath) {
|
|
32503
32544
|
const absolutePath = path4.isAbsolute(filePath) ? filePath : path4.resolve(filePath);
|
|
@@ -32508,17 +32549,17 @@ function pathToFileUri(filePath) {
|
|
|
32508
32549
|
return `file://${normalizedPath}`;
|
|
32509
32550
|
}
|
|
32510
32551
|
|
|
32511
|
-
// ../../node_modules/.
|
|
32552
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/utils/time.js
|
|
32512
32553
|
function sleep(ms) {
|
|
32513
32554
|
return new Promise((resolve2) => {
|
|
32514
32555
|
setTimeout(resolve2, ms);
|
|
32515
32556
|
});
|
|
32516
32557
|
}
|
|
32517
32558
|
|
|
32518
|
-
// ../../node_modules/.
|
|
32559
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/utils/workspace.js
|
|
32519
32560
|
import path5 from "path";
|
|
32520
32561
|
|
|
32521
|
-
// ../../node_modules/.
|
|
32562
|
+
// ../../node_modules/.bun/json5@2.2.3/node_modules/json5/dist/index.mjs
|
|
32522
32563
|
var Space_Separator = /[\u1680\u2000-\u200A\u202F\u205F\u3000]/;
|
|
32523
32564
|
var ID_Start = /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/;
|
|
32524
32565
|
var ID_Continue = /[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/;
|
|
@@ -33603,7 +33644,7 @@ var JSON5 = {
|
|
|
33603
33644
|
var lib = JSON5;
|
|
33604
33645
|
var dist_default = lib;
|
|
33605
33646
|
|
|
33606
|
-
// ../../node_modules/.
|
|
33647
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/utils/workspace.js
|
|
33607
33648
|
function transformWorkspacePaths(workspaceContent, templateDir) {
|
|
33608
33649
|
let workspace;
|
|
33609
33650
|
try {
|
|
@@ -33676,7 +33717,7 @@ function transformWorkspacePaths(workspaceContent, templateDir) {
|
|
|
33676
33717
|
return JSON.stringify(transformedWorkspace, null, 2);
|
|
33677
33718
|
}
|
|
33678
33719
|
|
|
33679
|
-
// ../../node_modules/.
|
|
33720
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/vscode/agentDispatch.js
|
|
33680
33721
|
var execAsync = promisify(exec);
|
|
33681
33722
|
function generateTimestamp() {
|
|
33682
33723
|
return (/* @__PURE__ */ new Date()).toISOString().replace(/[-:TZ.]/g, "").slice(0, 14);
|
|
@@ -34258,7 +34299,7 @@ async function dispatchBatchAgent(options) {
|
|
|
34258
34299
|
}
|
|
34259
34300
|
}
|
|
34260
34301
|
|
|
34261
|
-
// ../../node_modules/.
|
|
34302
|
+
// ../../node_modules/.bun/subagent@0.4.7/node_modules/subagent/dist/vscode/provision.js
|
|
34262
34303
|
import { writeFile as writeFile2 } from "fs/promises";
|
|
34263
34304
|
import path7 from "path";
|
|
34264
34305
|
var DEFAULT_WORKSPACE_TEMPLATE2 = {
|
|
@@ -34384,7 +34425,7 @@ async function provisionSubagents(options) {
|
|
|
34384
34425
|
|
|
34385
34426
|
// ../../packages/core/dist/index.js
|
|
34386
34427
|
import { constants as constants32 } from "node:fs";
|
|
34387
|
-
import { access as access32, readFile as
|
|
34428
|
+
import { access as access32, readFile as readFile6 } from "node:fs/promises";
|
|
34388
34429
|
import path11 from "node:path";
|
|
34389
34430
|
import { parse as parse32 } from "yaml";
|
|
34390
34431
|
import { createHash, randomUUID as randomUUID2 } from "node:crypto";
|
|
@@ -34438,11 +34479,11 @@ function extractCodeBlocks(segments) {
|
|
|
34438
34479
|
const CODE_BLOCK_PATTERN = /```[\s\S]*?```/g;
|
|
34439
34480
|
const codeBlocks = [];
|
|
34440
34481
|
for (const segment of segments) {
|
|
34441
|
-
const typeValue = segment
|
|
34482
|
+
const typeValue = segment.type;
|
|
34442
34483
|
if (typeof typeValue !== "string" || typeValue !== "text") {
|
|
34443
34484
|
continue;
|
|
34444
34485
|
}
|
|
34445
|
-
const textValue = segment
|
|
34486
|
+
const textValue = segment.value;
|
|
34446
34487
|
if (typeof textValue !== "string") {
|
|
34447
34488
|
continue;
|
|
34448
34489
|
}
|
|
@@ -34467,7 +34508,7 @@ ${part.content}
|
|
|
34467
34508
|
}
|
|
34468
34509
|
return parts.map((p) => p.content).join(" ");
|
|
34469
34510
|
}
|
|
34470
|
-
function formatSegment(segment) {
|
|
34511
|
+
function formatSegment(segment, mode = "lm") {
|
|
34471
34512
|
const type = asString(segment.type);
|
|
34472
34513
|
if (type === "text") {
|
|
34473
34514
|
return asString(segment.value);
|
|
@@ -34477,8 +34518,14 @@ function formatSegment(segment) {
|
|
|
34477
34518
|
return refPath ? `<Attached: ${refPath}>` : void 0;
|
|
34478
34519
|
}
|
|
34479
34520
|
if (type === "file") {
|
|
34480
|
-
const text2 = asString(segment.text);
|
|
34481
34521
|
const filePath = asString(segment.path);
|
|
34522
|
+
if (!filePath) {
|
|
34523
|
+
return void 0;
|
|
34524
|
+
}
|
|
34525
|
+
if (mode === "agent") {
|
|
34526
|
+
return `<file: path="${filePath}">`;
|
|
34527
|
+
}
|
|
34528
|
+
const text2 = asString(segment.text);
|
|
34482
34529
|
if (text2 && filePath) {
|
|
34483
34530
|
return formatFileContents([{ content: text2.trim(), isFile: true, displayPath: filePath }]);
|
|
34484
34531
|
}
|
|
@@ -34638,8 +34685,9 @@ Please add '$schema: ${SCHEMA_CONFIG_V2}' at the top of the file.`;
|
|
|
34638
34685
|
guideline_patterns: guidelinePatterns
|
|
34639
34686
|
};
|
|
34640
34687
|
} catch (error40) {
|
|
34641
|
-
logWarning(
|
|
34642
|
-
|
|
34688
|
+
logWarning(
|
|
34689
|
+
`Could not read .agentv/config.yaml at ${configPath}: ${error40.message}`
|
|
34690
|
+
);
|
|
34643
34691
|
}
|
|
34644
34692
|
}
|
|
34645
34693
|
return null;
|
|
@@ -34666,8 +34714,57 @@ function extractTargetFromSuite(suite) {
|
|
|
34666
34714
|
function logWarning(message) {
|
|
34667
34715
|
console.warn(`${ANSI_YELLOW}Warning: ${message}${ANSI_RESET}`);
|
|
34668
34716
|
}
|
|
34717
|
+
var TEMPLATE_VARIABLES = {
|
|
34718
|
+
CANDIDATE_ANSWER: "candidate_answer",
|
|
34719
|
+
EXPECTED_MESSAGES: "expected_messages",
|
|
34720
|
+
QUESTION: "question",
|
|
34721
|
+
EXPECTED_OUTCOME: "expected_outcome",
|
|
34722
|
+
REFERENCE_ANSWER: "reference_answer",
|
|
34723
|
+
INPUT_MESSAGES: "input_messages"
|
|
34724
|
+
};
|
|
34725
|
+
var VALID_TEMPLATE_VARIABLES = new Set(Object.values(TEMPLATE_VARIABLES));
|
|
34726
|
+
var REQUIRED_TEMPLATE_VARIABLES = /* @__PURE__ */ new Set([
|
|
34727
|
+
TEMPLATE_VARIABLES.CANDIDATE_ANSWER,
|
|
34728
|
+
TEMPLATE_VARIABLES.EXPECTED_MESSAGES
|
|
34729
|
+
]);
|
|
34669
34730
|
var ANSI_YELLOW2 = "\x1B[33m";
|
|
34670
34731
|
var ANSI_RESET2 = "\x1B[0m";
|
|
34732
|
+
async function validateCustomPromptContent(promptPath) {
|
|
34733
|
+
const content = await readFile22(promptPath, "utf8");
|
|
34734
|
+
validateTemplateVariables(content, promptPath);
|
|
34735
|
+
}
|
|
34736
|
+
function validateTemplateVariables(content, source2) {
|
|
34737
|
+
const variablePattern = /\{\{\s*([a-zA-Z0-9_]+)\s*\}\}/g;
|
|
34738
|
+
const foundVariables = /* @__PURE__ */ new Set();
|
|
34739
|
+
const invalidVariables = [];
|
|
34740
|
+
let match = variablePattern.exec(content);
|
|
34741
|
+
while (match !== null) {
|
|
34742
|
+
const varName = match[1];
|
|
34743
|
+
foundVariables.add(varName);
|
|
34744
|
+
if (!VALID_TEMPLATE_VARIABLES.has(varName)) {
|
|
34745
|
+
invalidVariables.push(varName);
|
|
34746
|
+
}
|
|
34747
|
+
match = variablePattern.exec(content);
|
|
34748
|
+
}
|
|
34749
|
+
const hasCandidateAnswer = foundVariables.has(TEMPLATE_VARIABLES.CANDIDATE_ANSWER);
|
|
34750
|
+
const hasExpectedMessages = foundVariables.has(TEMPLATE_VARIABLES.EXPECTED_MESSAGES);
|
|
34751
|
+
const hasRequiredFields = hasCandidateAnswer || hasExpectedMessages;
|
|
34752
|
+
if (!hasRequiredFields) {
|
|
34753
|
+
throw new Error(
|
|
34754
|
+
`Missing required fields. Must include at least one of:
|
|
34755
|
+
- {{ ${TEMPLATE_VARIABLES.CANDIDATE_ANSWER} }}
|
|
34756
|
+
- {{ ${TEMPLATE_VARIABLES.EXPECTED_MESSAGES} }}`
|
|
34757
|
+
);
|
|
34758
|
+
}
|
|
34759
|
+
if (invalidVariables.length > 0) {
|
|
34760
|
+
const warningMessage = `${ANSI_YELLOW2}Warning: Custom evaluator template at ${source2}
|
|
34761
|
+
Contains invalid variables: ${invalidVariables.map((v) => `{{ ${v} }}`).join(", ")}
|
|
34762
|
+
Valid variables: ${Array.from(VALID_TEMPLATE_VARIABLES).map((v) => `{{ ${v} }}`).join(", ")}${ANSI_RESET2}`;
|
|
34763
|
+
console.warn(warningMessage);
|
|
34764
|
+
}
|
|
34765
|
+
}
|
|
34766
|
+
var ANSI_YELLOW3 = "\x1B[33m";
|
|
34767
|
+
var ANSI_RESET3 = "\x1B[0m";
|
|
34671
34768
|
async function parseEvaluators(rawEvalCase, globalExecution, searchRoots, evalId) {
|
|
34672
34769
|
const execution = rawEvalCase.execution;
|
|
34673
34770
|
const candidateEvaluators = isJsonObject2(execution) ? execution.evaluators ?? rawEvalCase.evaluators : rawEvalCase.evaluators ?? globalExecution?.evaluators;
|
|
@@ -34726,6 +34823,12 @@ async function parseEvaluators(rawEvalCase, globalExecution, searchRoots, evalId
|
|
|
34726
34823
|
const resolved = await resolveFileReference2(prompt, searchRoots);
|
|
34727
34824
|
if (resolved.resolvedPath) {
|
|
34728
34825
|
promptPath = path32.resolve(resolved.resolvedPath);
|
|
34826
|
+
try {
|
|
34827
|
+
await validateCustomPromptContent(promptPath);
|
|
34828
|
+
} catch (error40) {
|
|
34829
|
+
const message = error40 instanceof Error ? error40.message : String(error40);
|
|
34830
|
+
throw new Error(`Evaluator '${name16}' template (${promptPath}): ${message}`);
|
|
34831
|
+
}
|
|
34729
34832
|
} else {
|
|
34730
34833
|
logWarning2(
|
|
34731
34834
|
`Inline prompt used for evaluator '${name16}' in '${evalId}' (file not found: ${resolved.displayPath})`,
|
|
@@ -34762,14 +34865,14 @@ function isJsonObject2(value) {
|
|
|
34762
34865
|
function logWarning2(message, details) {
|
|
34763
34866
|
if (details && details.length > 0) {
|
|
34764
34867
|
const detailBlock = details.join("\n");
|
|
34765
|
-
console.warn(`${
|
|
34766
|
-
${detailBlock}${
|
|
34868
|
+
console.warn(`${ANSI_YELLOW3}Warning: ${message}
|
|
34869
|
+
${detailBlock}${ANSI_RESET3}`);
|
|
34767
34870
|
} else {
|
|
34768
|
-
console.warn(`${
|
|
34871
|
+
console.warn(`${ANSI_YELLOW3}Warning: ${message}${ANSI_RESET3}`);
|
|
34769
34872
|
}
|
|
34770
34873
|
}
|
|
34771
|
-
var
|
|
34772
|
-
var
|
|
34874
|
+
var ANSI_YELLOW4 = "\x1B[33m";
|
|
34875
|
+
var ANSI_RESET4 = "\x1B[0m";
|
|
34773
34876
|
async function processMessages(options) {
|
|
34774
34877
|
const {
|
|
34775
34878
|
messages,
|
|
@@ -34812,7 +34915,7 @@ async function processMessages(options) {
|
|
|
34812
34915
|
continue;
|
|
34813
34916
|
}
|
|
34814
34917
|
try {
|
|
34815
|
-
const fileContent = (await
|
|
34918
|
+
const fileContent = (await readFile32(resolvedPath, "utf8")).replace(/\r\n/g, "\n");
|
|
34816
34919
|
if (messageType === "input" && guidelinePatterns && guidelinePaths) {
|
|
34817
34920
|
const relativeToRepo = path42.relative(repoRootPath, resolvedPath);
|
|
34818
34921
|
if (isGuidelineFile(relativeToRepo, guidelinePatterns)) {
|
|
@@ -34883,7 +34986,7 @@ async function resolveAssistantContent(content, searchRoots, verbose) {
|
|
|
34883
34986
|
continue;
|
|
34884
34987
|
}
|
|
34885
34988
|
try {
|
|
34886
|
-
const fileContent = (await
|
|
34989
|
+
const fileContent = (await readFile32(resolvedPath, "utf8")).replace(/\r\n/g, "\n").trim();
|
|
34887
34990
|
parts.push({ content: fileContent, isFile: true, displayPath });
|
|
34888
34991
|
if (verbose) {
|
|
34889
34992
|
console.log(` [Expected Assistant File] Found: ${displayPath}`);
|
|
@@ -34933,15 +35036,15 @@ function cloneJsonValue(value) {
|
|
|
34933
35036
|
function logWarning3(message, details) {
|
|
34934
35037
|
if (details && details.length > 0) {
|
|
34935
35038
|
const detailBlock = details.join("\n");
|
|
34936
|
-
console.warn(`${
|
|
34937
|
-
${detailBlock}${
|
|
35039
|
+
console.warn(`${ANSI_YELLOW4}Warning: ${message}
|
|
35040
|
+
${detailBlock}${ANSI_RESET4}`);
|
|
34938
35041
|
} else {
|
|
34939
|
-
console.warn(`${
|
|
35042
|
+
console.warn(`${ANSI_YELLOW4}Warning: ${message}${ANSI_RESET4}`);
|
|
34940
35043
|
}
|
|
34941
35044
|
}
|
|
34942
|
-
var
|
|
34943
|
-
var
|
|
34944
|
-
async function buildPromptInputs(testCase) {
|
|
35045
|
+
var ANSI_YELLOW5 = "\x1B[33m";
|
|
35046
|
+
var ANSI_RESET5 = "\x1B[0m";
|
|
35047
|
+
async function buildPromptInputs(testCase, mode = "lm") {
|
|
34945
35048
|
const guidelineParts = [];
|
|
34946
35049
|
for (const rawPath of testCase.guideline_paths) {
|
|
34947
35050
|
const absolutePath = path52.resolve(rawPath);
|
|
@@ -34950,7 +35053,7 @@ async function buildPromptInputs(testCase) {
|
|
|
34950
35053
|
continue;
|
|
34951
35054
|
}
|
|
34952
35055
|
try {
|
|
34953
|
-
const content = (await
|
|
35056
|
+
const content = (await readFile4(absolutePath, "utf8")).replace(/\r\n/g, "\n").trim();
|
|
34954
35057
|
guidelineParts.push({
|
|
34955
35058
|
content,
|
|
34956
35059
|
isFile: true,
|
|
@@ -35017,7 +35120,7 @@ async function buildPromptInputs(testCase) {
|
|
|
35017
35120
|
const roleLabel = message.role.charAt(0).toUpperCase() + message.role.slice(1);
|
|
35018
35121
|
const contentParts = [];
|
|
35019
35122
|
for (const segment of segments) {
|
|
35020
|
-
const formattedContent = formatSegment(segment);
|
|
35123
|
+
const formattedContent = formatSegment(segment, mode);
|
|
35021
35124
|
if (formattedContent) {
|
|
35022
35125
|
contentParts.push(formattedContent);
|
|
35023
35126
|
}
|
|
@@ -35032,7 +35135,11 @@ ${messageContent}`);
|
|
|
35032
35135
|
} else {
|
|
35033
35136
|
const questionParts = [];
|
|
35034
35137
|
for (const segment of testCase.input_segments) {
|
|
35035
|
-
|
|
35138
|
+
if (segment.type === "file" && typeof segment.path === "string" && testCase.guideline_patterns && isGuidelineFile(segment.path, testCase.guideline_patterns)) {
|
|
35139
|
+
questionParts.push(`<Attached: ${segment.path}>`);
|
|
35140
|
+
continue;
|
|
35141
|
+
}
|
|
35142
|
+
const formattedContent = formatSegment(segment, mode);
|
|
35036
35143
|
if (formattedContent) {
|
|
35037
35144
|
questionParts.push(formattedContent);
|
|
35038
35145
|
}
|
|
@@ -35046,7 +35153,8 @@ ${messageContent}`);
|
|
|
35046
35153
|
messages: testCase.input_messages,
|
|
35047
35154
|
segmentsByMessage,
|
|
35048
35155
|
guidelinePatterns: testCase.guideline_patterns,
|
|
35049
|
-
guidelineContent: guidelines
|
|
35156
|
+
guidelineContent: guidelines,
|
|
35157
|
+
mode
|
|
35050
35158
|
}) : void 0;
|
|
35051
35159
|
return { question, guidelines, chatPrompt };
|
|
35052
35160
|
}
|
|
@@ -35063,7 +35171,14 @@ function needsRoleMarkers(messages, processedSegmentsByMessage) {
|
|
|
35063
35171
|
return messagesWithContent > 1;
|
|
35064
35172
|
}
|
|
35065
35173
|
function buildChatPromptFromSegments(options) {
|
|
35066
|
-
const {
|
|
35174
|
+
const {
|
|
35175
|
+
messages,
|
|
35176
|
+
segmentsByMessage,
|
|
35177
|
+
guidelinePatterns,
|
|
35178
|
+
guidelineContent,
|
|
35179
|
+
systemPrompt,
|
|
35180
|
+
mode = "lm"
|
|
35181
|
+
} = options;
|
|
35067
35182
|
if (messages.length === 0) {
|
|
35068
35183
|
return void 0;
|
|
35069
35184
|
}
|
|
@@ -35081,7 +35196,7 @@ ${guidelineContent.trim()}`);
|
|
|
35081
35196
|
const segments = segmentsByMessage[startIndex];
|
|
35082
35197
|
const contentParts = [];
|
|
35083
35198
|
for (const segment of segments) {
|
|
35084
|
-
const formatted = formatSegment(segment);
|
|
35199
|
+
const formatted = formatSegment(segment, mode);
|
|
35085
35200
|
if (formatted) {
|
|
35086
35201
|
contentParts.push(formatted);
|
|
35087
35202
|
}
|
|
@@ -35114,7 +35229,7 @@ ${guidelineContent.trim()}`);
|
|
|
35114
35229
|
if (segment.type === "guideline_ref") {
|
|
35115
35230
|
continue;
|
|
35116
35231
|
}
|
|
35117
|
-
const formatted = formatSegment(segment);
|
|
35232
|
+
const formatted = formatSegment(segment, mode);
|
|
35118
35233
|
if (formatted) {
|
|
35119
35234
|
const isGuidelineRef = segment.type === "file" && typeof segment.path === "string" && guidelinePatterns && isGuidelineFile(segment.path, guidelinePatterns);
|
|
35120
35235
|
if (isGuidelineRef) {
|
|
@@ -35138,15 +35253,15 @@ function asString4(value) {
|
|
|
35138
35253
|
return typeof value === "string" ? value : void 0;
|
|
35139
35254
|
}
|
|
35140
35255
|
function logWarning4(message) {
|
|
35141
|
-
console.warn(`${
|
|
35256
|
+
console.warn(`${ANSI_YELLOW5}Warning: ${message}${ANSI_RESET5}`);
|
|
35142
35257
|
}
|
|
35143
|
-
var
|
|
35144
|
-
var
|
|
35145
|
-
var
|
|
35258
|
+
var ANSI_YELLOW6 = "\x1B[33m";
|
|
35259
|
+
var ANSI_RED = "\x1B[31m";
|
|
35260
|
+
var ANSI_RESET6 = "\x1B[0m";
|
|
35146
35261
|
async function readTestSuiteMetadata(testFilePath) {
|
|
35147
35262
|
try {
|
|
35148
35263
|
const absolutePath = path62.resolve(testFilePath);
|
|
35149
|
-
const content = await
|
|
35264
|
+
const content = await readFile5(absolutePath, "utf8");
|
|
35150
35265
|
const parsed = parse22(content);
|
|
35151
35266
|
if (!isJsonObject(parsed)) {
|
|
35152
35267
|
return {};
|
|
@@ -35164,7 +35279,7 @@ async function loadEvalCases(evalFilePath, repoRoot, options) {
|
|
|
35164
35279
|
const searchRoots = buildSearchRoots2(absoluteTestPath, repoRootPath);
|
|
35165
35280
|
const config2 = await loadConfig(absoluteTestPath, repoRootPath);
|
|
35166
35281
|
const guidelinePatterns = config2?.guideline_patterns;
|
|
35167
|
-
const rawFile = await
|
|
35282
|
+
const rawFile = await readFile5(absoluteTestPath, "utf8");
|
|
35168
35283
|
const parsed = parse22(rawFile);
|
|
35169
35284
|
if (!isJsonObject(parsed)) {
|
|
35170
35285
|
throw new Error(`Invalid test file format: ${evalFilePath}`);
|
|
@@ -35173,12 +35288,6 @@ async function loadEvalCases(evalFilePath, repoRoot, options) {
|
|
|
35173
35288
|
const datasetNameFromSuite = asString5(suite.dataset)?.trim();
|
|
35174
35289
|
const fallbackDataset = path62.basename(absoluteTestPath).replace(/\.ya?ml$/i, "") || "eval";
|
|
35175
35290
|
const datasetName = datasetNameFromSuite && datasetNameFromSuite.length > 0 ? datasetNameFromSuite : fallbackDataset;
|
|
35176
|
-
const schema = suite.$schema;
|
|
35177
|
-
if (schema !== SCHEMA_EVAL_V2) {
|
|
35178
|
-
const message = typeof schema === "string" ? `Invalid $schema value '${schema}' in ${evalFilePath}. Expected '${SCHEMA_EVAL_V2}'` : `Missing required field '$schema' in ${evalFilePath}.
|
|
35179
|
-
Please add '$schema: ${SCHEMA_EVAL_V2}' at the top of the file.`;
|
|
35180
|
-
throw new Error(message);
|
|
35181
|
-
}
|
|
35182
35291
|
const rawTestcases = suite.evalcases;
|
|
35183
35292
|
if (!Array.isArray(rawTestcases)) {
|
|
35184
35293
|
throw new Error(`Invalid test file format: ${evalFilePath} - missing 'evalcases' field`);
|
|
@@ -35202,14 +35311,18 @@ Please add '$schema: ${SCHEMA_EVAL_V2}' at the top of the file.`;
|
|
|
35202
35311
|
const inputMessagesValue = evalcase.input_messages;
|
|
35203
35312
|
const expectedMessagesValue = evalcase.expected_messages;
|
|
35204
35313
|
if (!id || !outcome || !Array.isArray(inputMessagesValue)) {
|
|
35205
|
-
|
|
35314
|
+
logError(
|
|
35315
|
+
`Skipping incomplete eval case: ${id ?? "unknown"}. Missing required fields: id, outcome, and/or input_messages`
|
|
35316
|
+
);
|
|
35206
35317
|
continue;
|
|
35207
35318
|
}
|
|
35208
35319
|
const hasExpectedMessages = Array.isArray(expectedMessagesValue) && expectedMessagesValue.length > 0;
|
|
35209
|
-
const inputMessages = inputMessagesValue.filter(
|
|
35320
|
+
const inputMessages = inputMessagesValue.filter(
|
|
35321
|
+
(msg) => isTestMessage(msg)
|
|
35322
|
+
);
|
|
35210
35323
|
const expectedMessages = hasExpectedMessages ? expectedMessagesValue.filter((msg) => isTestMessage(msg)) : [];
|
|
35211
35324
|
if (hasExpectedMessages && expectedMessages.length === 0) {
|
|
35212
|
-
|
|
35325
|
+
logError(`No valid expected message found for eval case: ${id}`);
|
|
35213
35326
|
continue;
|
|
35214
35327
|
}
|
|
35215
35328
|
if (expectedMessages.length > 1) {
|
|
@@ -35240,7 +35353,14 @@ Please add '$schema: ${SCHEMA_EVAL_V2}' at the top of the file.`;
|
|
|
35240
35353
|
const referenceAnswer = expectedContent ? await resolveAssistantContent(expectedContent, searchRoots, verbose) : "";
|
|
35241
35354
|
const question = inputTextParts.map((part) => part.trim()).filter((part) => part.length > 0).join(" ");
|
|
35242
35355
|
const evalCaseEvaluatorKind = coerceEvaluator(evalcase.evaluator, id) ?? globalEvaluator;
|
|
35243
|
-
|
|
35356
|
+
let evaluators;
|
|
35357
|
+
try {
|
|
35358
|
+
evaluators = await parseEvaluators(evalcase, globalExecution, searchRoots, id ?? "unknown");
|
|
35359
|
+
} catch (error40) {
|
|
35360
|
+
const message = error40 instanceof Error ? error40.message : String(error40);
|
|
35361
|
+
logError(`Skipping eval case '${id}': ${message}`);
|
|
35362
|
+
continue;
|
|
35363
|
+
}
|
|
35244
35364
|
const userFilePaths = [];
|
|
35245
35365
|
for (const segment of inputSegments) {
|
|
35246
35366
|
if (segment.type === "file" && typeof segment.resolvedPath === "string") {
|
|
@@ -35258,7 +35378,7 @@ Please add '$schema: ${SCHEMA_EVAL_V2}' at the top of the file.`;
|
|
|
35258
35378
|
question,
|
|
35259
35379
|
input_messages: inputMessages,
|
|
35260
35380
|
input_segments: inputSegments,
|
|
35261
|
-
|
|
35381
|
+
expected_segments: outputSegments,
|
|
35262
35382
|
reference_answer: referenceAnswer,
|
|
35263
35383
|
guideline_paths: guidelinePaths.map((guidelinePath) => path62.resolve(guidelinePath)),
|
|
35264
35384
|
guideline_patterns: guidelinePatterns,
|
|
@@ -35290,10 +35410,19 @@ function asString5(value) {
|
|
|
35290
35410
|
function logWarning5(message, details) {
|
|
35291
35411
|
if (details && details.length > 0) {
|
|
35292
35412
|
const detailBlock = details.join("\n");
|
|
35293
|
-
console.warn(`${
|
|
35294
|
-
${detailBlock}${
|
|
35413
|
+
console.warn(`${ANSI_YELLOW6}Warning: ${message}
|
|
35414
|
+
${detailBlock}${ANSI_RESET6}`);
|
|
35295
35415
|
} else {
|
|
35296
|
-
console.warn(`${
|
|
35416
|
+
console.warn(`${ANSI_YELLOW6}Warning: ${message}${ANSI_RESET6}`);
|
|
35417
|
+
}
|
|
35418
|
+
}
|
|
35419
|
+
function logError(message, details) {
|
|
35420
|
+
if (details && details.length > 0) {
|
|
35421
|
+
const detailBlock = details.join("\n");
|
|
35422
|
+
console.error(`${ANSI_RED}Error: ${message}
|
|
35423
|
+
${detailBlock}${ANSI_RESET6}`);
|
|
35424
|
+
} else {
|
|
35425
|
+
console.error(`${ANSI_RED}Error: ${message}${ANSI_RESET6}`);
|
|
35297
35426
|
}
|
|
35298
35427
|
}
|
|
35299
35428
|
var DEFAULT_SYSTEM_PROMPT = "You are a careful assistant. Follow all provided instructions and do not fabricate results.";
|
|
@@ -35897,9 +36026,7 @@ function buildPromptDocument(request, inputFiles, options) {
|
|
|
35897
36026
|
options?.guidelineOverrides
|
|
35898
36027
|
);
|
|
35899
36028
|
const inputFilesList = collectInputFiles(inputFiles);
|
|
35900
|
-
const nonGuidelineInputFiles = inputFilesList.filter(
|
|
35901
|
-
(file2) => !guidelineFiles.includes(file2)
|
|
35902
|
-
);
|
|
36029
|
+
const nonGuidelineInputFiles = inputFilesList.filter((file2) => !guidelineFiles.includes(file2));
|
|
35903
36030
|
const prereadBlock = buildMandatoryPrereadBlock(guidelineFiles, nonGuidelineInputFiles);
|
|
35904
36031
|
if (prereadBlock.length > 0) {
|
|
35905
36032
|
parts.push("\n", prereadBlock);
|
|
@@ -36069,7 +36196,15 @@ var CodexProvider = class {
|
|
|
36069
36196
|
return path9.resolve(this.config.cwd);
|
|
36070
36197
|
}
|
|
36071
36198
|
buildCodexArgs() {
|
|
36072
|
-
const args = [
|
|
36199
|
+
const args = [
|
|
36200
|
+
"--ask-for-approval",
|
|
36201
|
+
"never",
|
|
36202
|
+
"exec",
|
|
36203
|
+
"--json",
|
|
36204
|
+
"--color",
|
|
36205
|
+
"never",
|
|
36206
|
+
"--skip-git-repo-check"
|
|
36207
|
+
];
|
|
36073
36208
|
if (this.config.args && this.config.args.length > 0) {
|
|
36074
36209
|
args.push(...this.config.args);
|
|
36075
36210
|
}
|
|
@@ -36804,9 +36939,7 @@ function buildPromptDocument2(request, attachments, guidelinePatterns) {
|
|
|
36804
36939
|
}
|
|
36805
36940
|
const guidelineFiles = collectGuidelineFiles2(attachments, guidelinePatterns);
|
|
36806
36941
|
const attachmentFiles = collectAttachmentFiles(attachments);
|
|
36807
|
-
const nonGuidelineAttachments = attachmentFiles.filter(
|
|
36808
|
-
(file2) => !guidelineFiles.includes(file2)
|
|
36809
|
-
);
|
|
36942
|
+
const nonGuidelineAttachments = attachmentFiles.filter((file2) => !guidelineFiles.includes(file2));
|
|
36810
36943
|
const prereadBlock = buildMandatoryPrereadBlock2(guidelineFiles, nonGuidelineAttachments);
|
|
36811
36944
|
if (prereadBlock.length > 0) {
|
|
36812
36945
|
parts.push("\n", prereadBlock);
|
|
@@ -36915,8 +37048,10 @@ async function ensureVSCodeSubagents(options) {
|
|
|
36915
37048
|
if (result.skippedExisting.length > 0) {
|
|
36916
37049
|
console.log(`Reusing ${result.skippedExisting.length} existing unlocked subagent(s)`);
|
|
36917
37050
|
}
|
|
36918
|
-
console.log(
|
|
36919
|
-
|
|
37051
|
+
console.log(
|
|
37052
|
+
`
|
|
37053
|
+
total unlocked subagents available: ${result.created.length + result.skippedExisting.length}`
|
|
37054
|
+
);
|
|
36920
37055
|
}
|
|
36921
37056
|
return {
|
|
36922
37057
|
provisioned: true,
|
|
@@ -36936,27 +37071,6 @@ total unlocked subagents available: ${result.created.length + result.skippedExis
|
|
|
36936
37071
|
function isRecord(value) {
|
|
36937
37072
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
36938
37073
|
}
|
|
36939
|
-
function checkSchema(parsed, absolutePath) {
|
|
36940
|
-
const schema = parsed.$schema;
|
|
36941
|
-
if (schema === void 0) {
|
|
36942
|
-
throw new Error(
|
|
36943
|
-
`Missing $schema field in targets.yaml at ${absolutePath}.
|
|
36944
|
-
Please add '$schema: ${TARGETS_SCHEMA_V2}' at the top of the file.`
|
|
36945
|
-
);
|
|
36946
|
-
}
|
|
36947
|
-
if (typeof schema !== "string") {
|
|
36948
|
-
throw new Error(
|
|
36949
|
-
`Invalid $schema field in targets.yaml at ${absolutePath}.
|
|
36950
|
-
Expected a string value '${TARGETS_SCHEMA_V2}'.`
|
|
36951
|
-
);
|
|
36952
|
-
}
|
|
36953
|
-
if (schema !== TARGETS_SCHEMA_V2) {
|
|
36954
|
-
throw new Error(
|
|
36955
|
-
`Invalid $schema '${schema}' in targets.yaml at ${absolutePath}.
|
|
36956
|
-
Expected '${TARGETS_SCHEMA_V2}'.`
|
|
36957
|
-
);
|
|
36958
|
-
}
|
|
36959
|
-
}
|
|
36960
37074
|
function extractTargetsArray(parsed, absolutePath) {
|
|
36961
37075
|
const targets = parsed.targets;
|
|
36962
37076
|
if (!Array.isArray(targets)) {
|
|
@@ -36971,7 +37085,9 @@ function assertTargetDefinition(value, index, filePath) {
|
|
|
36971
37085
|
const name16 = value.name;
|
|
36972
37086
|
const provider = value.provider;
|
|
36973
37087
|
if (typeof name16 !== "string" || name16.trim().length === 0) {
|
|
36974
|
-
throw new Error(
|
|
37088
|
+
throw new Error(
|
|
37089
|
+
`targets.yaml entry at index ${index} in ${filePath} is missing a valid 'name'`
|
|
37090
|
+
);
|
|
36975
37091
|
}
|
|
36976
37092
|
if (typeof provider !== "string" || provider.trim().length === 0) {
|
|
36977
37093
|
throw new Error(`targets.yaml entry '${name16}' in ${filePath} is missing a valid 'provider'`);
|
|
@@ -36991,14 +37107,15 @@ async function readTargetDefinitions(filePath) {
|
|
|
36991
37107
|
if (!await fileExists3(absolutePath)) {
|
|
36992
37108
|
throw new Error(`targets.yaml not found at ${absolutePath}`);
|
|
36993
37109
|
}
|
|
36994
|
-
const raw = await
|
|
37110
|
+
const raw = await readFile6(absolutePath, "utf8");
|
|
36995
37111
|
const parsed = parse32(raw);
|
|
36996
37112
|
if (!isRecord(parsed)) {
|
|
36997
|
-
throw new Error(`targets.yaml at ${absolutePath} must be a YAML object with
|
|
37113
|
+
throw new Error(`targets.yaml at ${absolutePath} must be a YAML object with a 'targets' field`);
|
|
36998
37114
|
}
|
|
36999
|
-
checkSchema(parsed, absolutePath);
|
|
37000
37115
|
const targets = extractTargetsArray(parsed, absolutePath);
|
|
37001
|
-
const definitions = targets.map(
|
|
37116
|
+
const definitions = targets.map(
|
|
37117
|
+
(entry, index) => assertTargetDefinition(entry, index, absolutePath)
|
|
37118
|
+
);
|
|
37002
37119
|
return definitions;
|
|
37003
37120
|
}
|
|
37004
37121
|
function listTargetNames(definitions) {
|
|
@@ -37034,16 +37151,16 @@ Use the reference_answer as a gold standard for a high-quality response (if prov
|
|
|
37034
37151
|
Be concise and focused in your evaluation. Provide succinct, specific feedback rather than verbose explanations.
|
|
37035
37152
|
|
|
37036
37153
|
[[ ## expected_outcome ## ]]
|
|
37037
|
-
{{
|
|
37154
|
+
{{${TEMPLATE_VARIABLES.EXPECTED_OUTCOME}}}
|
|
37038
37155
|
|
|
37039
37156
|
[[ ## question ## ]]
|
|
37040
|
-
{{
|
|
37157
|
+
{{${TEMPLATE_VARIABLES.QUESTION}}}
|
|
37041
37158
|
|
|
37042
37159
|
[[ ## reference_answer ## ]]
|
|
37043
|
-
{{
|
|
37160
|
+
{{${TEMPLATE_VARIABLES.REFERENCE_ANSWER}}}
|
|
37044
37161
|
|
|
37045
37162
|
[[ ## candidate_answer ## ]]
|
|
37046
|
-
{{
|
|
37163
|
+
{{${TEMPLATE_VARIABLES.CANDIDATE_ANSWER}}}`;
|
|
37047
37164
|
var LlmJudgeEvaluator = class {
|
|
37048
37165
|
kind = "llm_judge";
|
|
37049
37166
|
resolveJudgeProvider;
|
|
@@ -37066,12 +37183,16 @@ var LlmJudgeEvaluator = class {
|
|
|
37066
37183
|
async evaluateWithPrompt(context, judgeProvider) {
|
|
37067
37184
|
const formattedQuestion = context.promptInputs.question && context.promptInputs.question.trim().length > 0 ? context.promptInputs.question : context.evalCase.question;
|
|
37068
37185
|
const variables = {
|
|
37069
|
-
|
|
37070
|
-
|
|
37071
|
-
|
|
37072
|
-
|
|
37073
|
-
|
|
37074
|
-
|
|
37186
|
+
[TEMPLATE_VARIABLES.INPUT_MESSAGES]: JSON.stringify(context.evalCase.input_segments, null, 2),
|
|
37187
|
+
[TEMPLATE_VARIABLES.EXPECTED_MESSAGES]: JSON.stringify(
|
|
37188
|
+
context.evalCase.expected_segments,
|
|
37189
|
+
null,
|
|
37190
|
+
2
|
|
37191
|
+
),
|
|
37192
|
+
[TEMPLATE_VARIABLES.CANDIDATE_ANSWER]: context.candidate.trim(),
|
|
37193
|
+
[TEMPLATE_VARIABLES.REFERENCE_ANSWER]: (context.evalCase.reference_answer ?? "").trim(),
|
|
37194
|
+
[TEMPLATE_VARIABLES.EXPECTED_OUTCOME]: context.evalCase.expected_outcome.trim(),
|
|
37195
|
+
[TEMPLATE_VARIABLES.QUESTION]: formattedQuestion.trim()
|
|
37075
37196
|
};
|
|
37076
37197
|
const systemPrompt = buildOutputSchema();
|
|
37077
37198
|
const evaluatorTemplate = context.evaluatorTemplateOverride ?? this.evaluatorTemplate ?? DEFAULT_EVALUATOR_TEMPLATE;
|
|
@@ -37303,7 +37424,7 @@ function parseJsonSafe(payload) {
|
|
|
37303
37424
|
}
|
|
37304
37425
|
}
|
|
37305
37426
|
function substituteVariables(template, variables) {
|
|
37306
|
-
return template.replace(/\{\{([a-zA-Z0-9_]+)\}\}/g, (match, varName) => {
|
|
37427
|
+
return template.replace(/\{\{\s*([a-zA-Z0-9_]+)\s*\}\}/g, (match, varName) => {
|
|
37307
37428
|
return variables[varName] ?? match;
|
|
37308
37429
|
});
|
|
37309
37430
|
}
|
|
@@ -37339,6 +37460,9 @@ var Queue = class {
|
|
|
37339
37460
|
}
|
|
37340
37461
|
this.#head = this.#head.next;
|
|
37341
37462
|
this.#size--;
|
|
37463
|
+
if (!this.#head) {
|
|
37464
|
+
this.#tail = void 0;
|
|
37465
|
+
}
|
|
37342
37466
|
return current.value;
|
|
37343
37467
|
}
|
|
37344
37468
|
peek() {
|
|
@@ -37456,11 +37580,11 @@ async function runEvaluation(options) {
|
|
|
37456
37580
|
now,
|
|
37457
37581
|
evalId,
|
|
37458
37582
|
verbose,
|
|
37583
|
+
evalCases: preloadedEvalCases,
|
|
37459
37584
|
onResult,
|
|
37460
37585
|
onProgress
|
|
37461
37586
|
} = options;
|
|
37462
|
-
const
|
|
37463
|
-
const evalCases = await load(evalFilePath, repoRoot, { verbose, evalId });
|
|
37587
|
+
const evalCases = preloadedEvalCases ?? await loadEvalCases(evalFilePath, repoRoot, { verbose, evalId });
|
|
37464
37588
|
const filteredEvalCases = filterEvalCases(evalCases, evalId);
|
|
37465
37589
|
if (filteredEvalCases.length === 0) {
|
|
37466
37590
|
if (evalId) {
|
|
@@ -37541,7 +37665,9 @@ async function runEvaluation(options) {
|
|
|
37541
37665
|
} catch (error40) {
|
|
37542
37666
|
if (verbose) {
|
|
37543
37667
|
const message = error40 instanceof Error ? error40.message : String(error40);
|
|
37544
|
-
console.warn(
|
|
37668
|
+
console.warn(
|
|
37669
|
+
`Provider batch execution failed, falling back to per-case dispatch: ${message}`
|
|
37670
|
+
);
|
|
37545
37671
|
}
|
|
37546
37672
|
}
|
|
37547
37673
|
}
|
|
@@ -37644,8 +37770,9 @@ async function runBatchEvaluation(options) {
|
|
|
37644
37770
|
agentTimeoutMs
|
|
37645
37771
|
} = options;
|
|
37646
37772
|
const promptInputsList = [];
|
|
37773
|
+
const formattingMode = isAgentProvider(provider) ? "agent" : "lm";
|
|
37647
37774
|
for (const evalCase of evalCases) {
|
|
37648
|
-
const promptInputs = await buildPromptInputs(evalCase);
|
|
37775
|
+
const promptInputs = await buildPromptInputs(evalCase, formattingMode);
|
|
37649
37776
|
if (promptDumpDir) {
|
|
37650
37777
|
await dumpPrompt(promptDumpDir, evalCase, promptInputs);
|
|
37651
37778
|
}
|
|
@@ -37704,7 +37831,14 @@ async function runBatchEvaluation(options) {
|
|
|
37704
37831
|
agentTimeoutMs
|
|
37705
37832
|
});
|
|
37706
37833
|
} catch (error40) {
|
|
37707
|
-
const errorResult = buildErrorResult(
|
|
37834
|
+
const errorResult = buildErrorResult(
|
|
37835
|
+
evalCase,
|
|
37836
|
+
target.name,
|
|
37837
|
+
nowFn(),
|
|
37838
|
+
error40,
|
|
37839
|
+
promptInputs,
|
|
37840
|
+
provider
|
|
37841
|
+
);
|
|
37708
37842
|
results.push(errorResult);
|
|
37709
37843
|
if (onResult) {
|
|
37710
37844
|
await onResult(errorResult);
|
|
@@ -37751,7 +37885,8 @@ async function runEvalCase(options) {
|
|
|
37751
37885
|
signal,
|
|
37752
37886
|
judgeProvider
|
|
37753
37887
|
} = options;
|
|
37754
|
-
const
|
|
37888
|
+
const formattingMode = isAgentProvider(provider) ? "agent" : "lm";
|
|
37889
|
+
const promptInputs = await buildPromptInputs(evalCase, formattingMode);
|
|
37755
37890
|
if (promptDumpDir) {
|
|
37756
37891
|
await dumpPrompt(promptDumpDir, evalCase, promptInputs);
|
|
37757
37892
|
}
|
|
@@ -37881,7 +38016,18 @@ async function evaluateCandidate(options) {
|
|
|
37881
38016
|
};
|
|
37882
38017
|
}
|
|
37883
38018
|
async function runEvaluatorsForCase(options) {
|
|
37884
|
-
const {
|
|
38019
|
+
const {
|
|
38020
|
+
evalCase,
|
|
38021
|
+
candidate,
|
|
38022
|
+
target,
|
|
38023
|
+
provider,
|
|
38024
|
+
evaluators,
|
|
38025
|
+
attempt,
|
|
38026
|
+
promptInputs,
|
|
38027
|
+
now,
|
|
38028
|
+
judgeProvider,
|
|
38029
|
+
agentTimeoutMs
|
|
38030
|
+
} = options;
|
|
37885
38031
|
if (evalCase.evaluators && evalCase.evaluators.length > 0) {
|
|
37886
38032
|
return runEvaluatorList({
|
|
37887
38033
|
evalCase,
|
|
@@ -37982,7 +38128,6 @@ async function runEvaluatorList(options) {
|
|
|
37982
38128
|
reasoning: score2.reasoning,
|
|
37983
38129
|
evaluator_provider_request: score2.evaluatorRawRequest
|
|
37984
38130
|
});
|
|
37985
|
-
continue;
|
|
37986
38131
|
}
|
|
37987
38132
|
} catch (error40) {
|
|
37988
38133
|
const message = error40 instanceof Error ? error40.message : String(error40);
|
|
@@ -37993,7 +38138,11 @@ async function runEvaluatorList(options) {
|
|
|
37993
38138
|
expectedAspectCount: 1,
|
|
37994
38139
|
reasoning: message
|
|
37995
38140
|
};
|
|
37996
|
-
scored.push({
|
|
38141
|
+
scored.push({
|
|
38142
|
+
score: fallbackScore,
|
|
38143
|
+
name: evaluator.name ?? "unknown",
|
|
38144
|
+
type: evaluator.type ?? "unknown"
|
|
38145
|
+
});
|
|
37997
38146
|
evaluatorResults.push({
|
|
37998
38147
|
name: evaluator.name ?? "unknown",
|
|
37999
38148
|
type: evaluator.type ?? "unknown",
|
|
@@ -38007,7 +38156,10 @@ async function runEvaluatorList(options) {
|
|
|
38007
38156
|
const aggregateScore = scored.length > 0 ? scored.reduce((total, entry) => total + entry.score.score, 0) / scored.length : 0;
|
|
38008
38157
|
const hits = scored.flatMap((entry) => entry.score.hits);
|
|
38009
38158
|
const misses = scored.flatMap((entry) => entry.score.misses);
|
|
38010
|
-
const expectedAspectCount = scored.reduce(
|
|
38159
|
+
const expectedAspectCount = scored.reduce(
|
|
38160
|
+
(total, entry) => total + (entry.score.expectedAspectCount ?? 0),
|
|
38161
|
+
0
|
|
38162
|
+
);
|
|
38011
38163
|
const rawAspects = scored.flatMap((entry) => entry.score.rawAspects ?? []);
|
|
38012
38164
|
const reasoningParts = scored.map((entry) => entry.score.reasoning ? `${entry.name}: ${entry.score.reasoning}` : void 0).filter(isNonEmptyString2);
|
|
38013
38165
|
const reasoning = reasoningParts.length > 0 ? reasoningParts.join(" | ") : void 0;
|
|
@@ -38022,7 +38174,18 @@ async function runEvaluatorList(options) {
|
|
|
38022
38174
|
return { score, evaluatorResults };
|
|
38023
38175
|
}
|
|
38024
38176
|
async function runLlmJudgeEvaluator(options) {
|
|
38025
|
-
const {
|
|
38177
|
+
const {
|
|
38178
|
+
config: config2,
|
|
38179
|
+
evalCase,
|
|
38180
|
+
candidate,
|
|
38181
|
+
target,
|
|
38182
|
+
provider,
|
|
38183
|
+
evaluatorRegistry,
|
|
38184
|
+
attempt,
|
|
38185
|
+
promptInputs,
|
|
38186
|
+
now,
|
|
38187
|
+
judgeProvider
|
|
38188
|
+
} = options;
|
|
38026
38189
|
const customPrompt = await resolveCustomPrompt(config2);
|
|
38027
38190
|
return evaluatorRegistry.llm_judge.evaluate({
|
|
38028
38191
|
evalCase,
|
|
@@ -38040,7 +38203,8 @@ async function runLlmJudgeEvaluator(options) {
|
|
|
38040
38203
|
async function resolveCustomPrompt(config2) {
|
|
38041
38204
|
if (config2.promptPath) {
|
|
38042
38205
|
try {
|
|
38043
|
-
|
|
38206
|
+
const content = await readTextFile(config2.promptPath);
|
|
38207
|
+
return content;
|
|
38044
38208
|
} catch (error40) {
|
|
38045
38209
|
const message = error40 instanceof Error ? error40.message : String(error40);
|
|
38046
38210
|
console.warn(`Could not read custom prompt at ${config2.promptPath}: ${message}`);
|
|
@@ -38192,17 +38356,11 @@ function createAgentKernel() {
|
|
|
38192
38356
|
return { status: "stub" };
|
|
38193
38357
|
}
|
|
38194
38358
|
|
|
38195
|
-
// src/commands/eval/run-eval.ts
|
|
38196
|
-
import { constants as constants6 } from "node:fs";
|
|
38197
|
-
import { access as access6, mkdir as mkdir6 } from "node:fs/promises";
|
|
38198
|
-
import path18 from "node:path";
|
|
38199
|
-
import { pathToFileURL } from "node:url";
|
|
38200
|
-
|
|
38201
38359
|
// src/commands/eval/env.ts
|
|
38202
|
-
import { config as loadDotenv } from "dotenv";
|
|
38203
38360
|
import { constants as constants4 } from "node:fs";
|
|
38204
38361
|
import { access as access4 } from "node:fs/promises";
|
|
38205
38362
|
import path13 from "node:path";
|
|
38363
|
+
import { config as loadDotenv } from "dotenv";
|
|
38206
38364
|
function uniqueDirs(directories) {
|
|
38207
38365
|
const seen = /* @__PURE__ */ new Set();
|
|
38208
38366
|
const result = [];
|
|
@@ -38245,11 +38403,7 @@ async function loadEnvFromHierarchy(options) {
|
|
|
38245
38403
|
const { testFilePath, repoRoot, verbose } = options;
|
|
38246
38404
|
const testDir = path13.dirname(path13.resolve(testFilePath));
|
|
38247
38405
|
const cwd = process.cwd();
|
|
38248
|
-
const searchDirs = uniqueDirs([
|
|
38249
|
-
...collectAncestorDirectories(testDir, repoRoot),
|
|
38250
|
-
repoRoot,
|
|
38251
|
-
cwd
|
|
38252
|
-
]);
|
|
38406
|
+
const searchDirs = uniqueDirs([...collectAncestorDirectories(testDir, repoRoot), repoRoot, cwd]);
|
|
38253
38407
|
for (const dir of searchDirs) {
|
|
38254
38408
|
const candidate = path13.join(dir, ".env");
|
|
38255
38409
|
if (await fileExists4(candidate)) {
|
|
@@ -38266,7 +38420,13 @@ async function loadEnvFromHierarchy(options) {
|
|
|
38266
38420
|
return void 0;
|
|
38267
38421
|
}
|
|
38268
38422
|
|
|
38269
|
-
//
|
|
38423
|
+
// src/commands/eval/jsonl-writer.ts
|
|
38424
|
+
import { createWriteStream as createWriteStream2 } from "node:fs";
|
|
38425
|
+
import { mkdir as mkdir4 } from "node:fs/promises";
|
|
38426
|
+
import path14 from "node:path";
|
|
38427
|
+
import { finished } from "node:stream/promises";
|
|
38428
|
+
|
|
38429
|
+
// ../../node_modules/.bun/async-mutex@0.5.0/node_modules/async-mutex/index.mjs
|
|
38270
38430
|
var E_TIMEOUT = new Error("timeout while waiting for mutex to become available");
|
|
38271
38431
|
var E_ALREADY_LOCKED = new Error("mutex already locked");
|
|
38272
38432
|
var E_CANCELED = new Error("request for lock canceled");
|
|
@@ -38473,10 +38633,6 @@ var Mutex = class {
|
|
|
38473
38633
|
};
|
|
38474
38634
|
|
|
38475
38635
|
// src/commands/eval/jsonl-writer.ts
|
|
38476
|
-
import { createWriteStream as createWriteStream2 } from "node:fs";
|
|
38477
|
-
import { mkdir as mkdir4 } from "node:fs/promises";
|
|
38478
|
-
import path14 from "node:path";
|
|
38479
|
-
import { finished } from "node:stream/promises";
|
|
38480
38636
|
var JsonlWriter = class _JsonlWriter {
|
|
38481
38637
|
stream;
|
|
38482
38638
|
mutex = new Mutex();
|
|
@@ -38645,7 +38801,9 @@ var ProgressDisplay = class {
|
|
|
38645
38801
|
if (progress.status === "completed") {
|
|
38646
38802
|
console.log(`\u2713 Eval ${progress.evalId}${targetSuffix} completed`);
|
|
38647
38803
|
} else if (progress.status === "failed") {
|
|
38648
|
-
console.log(
|
|
38804
|
+
console.log(
|
|
38805
|
+
`\u2717 Eval ${progress.evalId}${targetSuffix} failed${progress.error ? `: ${progress.error}` : ""}`
|
|
38806
|
+
);
|
|
38649
38807
|
}
|
|
38650
38808
|
}
|
|
38651
38809
|
}
|
|
@@ -38772,7 +38930,8 @@ var ProgressDisplay = class {
|
|
|
38772
38930
|
(a, b) => a.workerId - b.workerId
|
|
38773
38931
|
);
|
|
38774
38932
|
for (const worker of sortedWorkers) {
|
|
38775
|
-
this.write(this.formatWorkerLine(worker)
|
|
38933
|
+
this.write(`${this.formatWorkerLine(worker)}
|
|
38934
|
+
`);
|
|
38776
38935
|
}
|
|
38777
38936
|
this.write("\n");
|
|
38778
38937
|
}
|
|
@@ -38888,11 +39047,11 @@ function formatEvaluationSummary(summary) {
|
|
|
38888
39047
|
lines.push("\n==================================================");
|
|
38889
39048
|
lines.push("ERRORS");
|
|
38890
39049
|
lines.push("==================================================");
|
|
38891
|
-
summary.errors
|
|
39050
|
+
for (const error40 of summary.errors) {
|
|
38892
39051
|
lines.push(`
|
|
38893
39052
|
\u274C ${error40.evalId}`);
|
|
38894
39053
|
lines.push(` ${error40.error}`);
|
|
38895
|
-
}
|
|
39054
|
+
}
|
|
38896
39055
|
lines.push("");
|
|
38897
39056
|
}
|
|
38898
39057
|
lines.push("\n==================================================");
|
|
@@ -38926,8 +39085,13 @@ function formatEvaluationSummary(summary) {
|
|
|
38926
39085
|
return lines.join("\n");
|
|
38927
39086
|
}
|
|
38928
39087
|
|
|
39088
|
+
// src/commands/eval/targets.ts
|
|
39089
|
+
import { constants as constants5 } from "node:fs";
|
|
39090
|
+
import { access as access5 } from "node:fs/promises";
|
|
39091
|
+
import path17 from "node:path";
|
|
39092
|
+
|
|
38929
39093
|
// ../../packages/core/dist/evaluation/validation/index.js
|
|
38930
|
-
import { readFile as
|
|
39094
|
+
import { readFile as readFile7 } from "node:fs/promises";
|
|
38931
39095
|
import { parse as parse6 } from "yaml";
|
|
38932
39096
|
import { readFile as readFile23 } from "node:fs/promises";
|
|
38933
39097
|
import path16 from "node:path";
|
|
@@ -38940,23 +39104,23 @@ import { parse as parse42 } from "yaml";
|
|
|
38940
39104
|
import { readFile as readFile52 } from "node:fs/promises";
|
|
38941
39105
|
import path33 from "node:path";
|
|
38942
39106
|
import { parse as parse52 } from "yaml";
|
|
38943
|
-
var
|
|
39107
|
+
var SCHEMA_EVAL_V2 = "agentv-eval-v2";
|
|
38944
39108
|
var SCHEMA_TARGETS_V2 = "agentv-targets-v2.2";
|
|
38945
39109
|
var SCHEMA_CONFIG_V22 = "agentv-config-v2";
|
|
38946
39110
|
async function detectFileType(filePath) {
|
|
38947
39111
|
try {
|
|
38948
|
-
const content = await
|
|
39112
|
+
const content = await readFile7(filePath, "utf8");
|
|
38949
39113
|
const parsed = parse6(content);
|
|
38950
39114
|
if (typeof parsed !== "object" || parsed === null) {
|
|
38951
39115
|
return "unknown";
|
|
38952
39116
|
}
|
|
38953
39117
|
const record2 = parsed;
|
|
38954
|
-
const schema = record2
|
|
39118
|
+
const schema = record2.$schema;
|
|
38955
39119
|
if (typeof schema !== "string") {
|
|
38956
39120
|
return "unknown";
|
|
38957
39121
|
}
|
|
38958
39122
|
switch (schema) {
|
|
38959
|
-
case
|
|
39123
|
+
case SCHEMA_EVAL_V2:
|
|
38960
39124
|
return "eval";
|
|
38961
39125
|
case SCHEMA_TARGETS_V2:
|
|
38962
39126
|
return "targets";
|
|
@@ -38969,7 +39133,6 @@ async function detectFileType(filePath) {
|
|
|
38969
39133
|
return "unknown";
|
|
38970
39134
|
}
|
|
38971
39135
|
}
|
|
38972
|
-
var SCHEMA_EVAL_V222 = "agentv-eval-v2";
|
|
38973
39136
|
function isObject2(value) {
|
|
38974
39137
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
38975
39138
|
}
|
|
@@ -39006,17 +39169,7 @@ async function validateEvalFile(filePath) {
|
|
|
39006
39169
|
errors
|
|
39007
39170
|
};
|
|
39008
39171
|
}
|
|
39009
|
-
const
|
|
39010
|
-
if (schema !== SCHEMA_EVAL_V222) {
|
|
39011
|
-
const message = typeof schema === "string" ? `Invalid $schema value '${schema}'. Expected '${SCHEMA_EVAL_V222}'` : `Missing required field '$schema'. Expected '${SCHEMA_EVAL_V222}'`;
|
|
39012
|
-
errors.push({
|
|
39013
|
-
severity: "error",
|
|
39014
|
-
filePath: absolutePath,
|
|
39015
|
-
location: "$schema",
|
|
39016
|
-
message
|
|
39017
|
-
});
|
|
39018
|
-
}
|
|
39019
|
-
const evalcases = parsed["evalcases"];
|
|
39172
|
+
const evalcases = parsed.evalcases;
|
|
39020
39173
|
if (!Array.isArray(evalcases)) {
|
|
39021
39174
|
errors.push({
|
|
39022
39175
|
severity: "error",
|
|
@@ -39043,7 +39196,7 @@ async function validateEvalFile(filePath) {
|
|
|
39043
39196
|
});
|
|
39044
39197
|
continue;
|
|
39045
39198
|
}
|
|
39046
|
-
const id = evalCase
|
|
39199
|
+
const id = evalCase.id;
|
|
39047
39200
|
if (typeof id !== "string" || id.trim().length === 0) {
|
|
39048
39201
|
errors.push({
|
|
39049
39202
|
severity: "error",
|
|
@@ -39052,7 +39205,7 @@ async function validateEvalFile(filePath) {
|
|
|
39052
39205
|
message: "Missing or invalid 'id' field (must be a non-empty string)"
|
|
39053
39206
|
});
|
|
39054
39207
|
}
|
|
39055
|
-
const outcome = evalCase
|
|
39208
|
+
const outcome = evalCase.outcome;
|
|
39056
39209
|
if (typeof outcome !== "string" || outcome.trim().length === 0) {
|
|
39057
39210
|
errors.push({
|
|
39058
39211
|
severity: "error",
|
|
@@ -39061,7 +39214,7 @@ async function validateEvalFile(filePath) {
|
|
|
39061
39214
|
message: "Missing or invalid 'outcome' field (must be a non-empty string)"
|
|
39062
39215
|
});
|
|
39063
39216
|
}
|
|
39064
|
-
const inputMessages = evalCase
|
|
39217
|
+
const inputMessages = evalCase.input_messages;
|
|
39065
39218
|
if (!Array.isArray(inputMessages)) {
|
|
39066
39219
|
errors.push({
|
|
39067
39220
|
severity: "error",
|
|
@@ -39072,7 +39225,7 @@ async function validateEvalFile(filePath) {
|
|
|
39072
39225
|
} else {
|
|
39073
39226
|
validateMessages(inputMessages, `${location}.input_messages`, absolutePath, errors);
|
|
39074
39227
|
}
|
|
39075
|
-
const expectedMessages = evalCase
|
|
39228
|
+
const expectedMessages = evalCase.expected_messages;
|
|
39076
39229
|
if (expectedMessages !== void 0 && !Array.isArray(expectedMessages)) {
|
|
39077
39230
|
errors.push({
|
|
39078
39231
|
severity: "error",
|
|
@@ -39104,7 +39257,7 @@ function validateMessages(messages, location, filePath, errors) {
|
|
|
39104
39257
|
});
|
|
39105
39258
|
continue;
|
|
39106
39259
|
}
|
|
39107
|
-
const role = message
|
|
39260
|
+
const role = message.role;
|
|
39108
39261
|
const validRoles = ["system", "user", "assistant"];
|
|
39109
39262
|
if (!validRoles.includes(role)) {
|
|
39110
39263
|
errors.push({
|
|
@@ -39114,7 +39267,7 @@ function validateMessages(messages, location, filePath, errors) {
|
|
|
39114
39267
|
message: `Invalid role '${role}'. Must be one of: ${validRoles.join(", ")}`
|
|
39115
39268
|
});
|
|
39116
39269
|
}
|
|
39117
|
-
const content = message
|
|
39270
|
+
const content = message.content;
|
|
39118
39271
|
if (typeof content === "string") {
|
|
39119
39272
|
validateContentForRoleMarkers(content, `${msgLocation}.content`, filePath, errors);
|
|
39120
39273
|
} else if (Array.isArray(content)) {
|
|
@@ -39124,7 +39277,7 @@ function validateMessages(messages, location, filePath, errors) {
|
|
|
39124
39277
|
if (typeof contentItem === "string") {
|
|
39125
39278
|
validateContentForRoleMarkers(contentItem, contentLocation, filePath, errors);
|
|
39126
39279
|
} else if (isObject2(contentItem)) {
|
|
39127
|
-
const type = contentItem
|
|
39280
|
+
const type = contentItem.type;
|
|
39128
39281
|
if (typeof type !== "string") {
|
|
39129
39282
|
errors.push({
|
|
39130
39283
|
severity: "error",
|
|
@@ -39134,7 +39287,7 @@ function validateMessages(messages, location, filePath, errors) {
|
|
|
39134
39287
|
});
|
|
39135
39288
|
}
|
|
39136
39289
|
if (type === "text") {
|
|
39137
|
-
const value = contentItem
|
|
39290
|
+
const value = contentItem.value;
|
|
39138
39291
|
if (typeof value !== "string") {
|
|
39139
39292
|
errors.push({
|
|
39140
39293
|
severity: "error",
|
|
@@ -39181,10 +39334,7 @@ function validateContentForRoleMarkers(content, location, filePath, errors) {
|
|
|
39181
39334
|
function isObject22(value) {
|
|
39182
39335
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
39183
39336
|
}
|
|
39184
|
-
var COMMON_SETTINGS = /* @__PURE__ */ new Set([
|
|
39185
|
-
"provider_batching",
|
|
39186
|
-
"providerBatching"
|
|
39187
|
-
]);
|
|
39337
|
+
var COMMON_SETTINGS = /* @__PURE__ */ new Set(["provider_batching", "providerBatching"]);
|
|
39188
39338
|
var RETRY_SETTINGS = /* @__PURE__ */ new Set([
|
|
39189
39339
|
"max_retries",
|
|
39190
39340
|
"maxRetries",
|
|
@@ -39356,7 +39506,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39356
39506
|
};
|
|
39357
39507
|
}
|
|
39358
39508
|
function validateCliSettings(target, absolutePath2, location, errors2) {
|
|
39359
|
-
const commandTemplate = target
|
|
39509
|
+
const commandTemplate = target.command_template ?? target.commandTemplate;
|
|
39360
39510
|
if (typeof commandTemplate !== "string" || commandTemplate.trim().length === 0) {
|
|
39361
39511
|
errors2.push({
|
|
39362
39512
|
severity: "error",
|
|
@@ -39365,9 +39515,14 @@ async function validateTargetsFile(filePath) {
|
|
|
39365
39515
|
message: "CLI provider requires 'commandTemplate' as a non-empty string"
|
|
39366
39516
|
});
|
|
39367
39517
|
} else {
|
|
39368
|
-
recordUnknownPlaceholders(
|
|
39518
|
+
recordUnknownPlaceholders(
|
|
39519
|
+
commandTemplate,
|
|
39520
|
+
absolutePath2,
|
|
39521
|
+
`${location}.commandTemplate`,
|
|
39522
|
+
errors2
|
|
39523
|
+
);
|
|
39369
39524
|
}
|
|
39370
|
-
const attachmentsFormat = target
|
|
39525
|
+
const attachmentsFormat = target.attachments_format ?? target.attachmentsFormat;
|
|
39371
39526
|
if (attachmentsFormat !== void 0 && typeof attachmentsFormat !== "string") {
|
|
39372
39527
|
errors2.push({
|
|
39373
39528
|
severity: "error",
|
|
@@ -39376,7 +39531,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39376
39531
|
message: "'attachmentsFormat' must be a string when provided"
|
|
39377
39532
|
});
|
|
39378
39533
|
}
|
|
39379
|
-
const filesFormat = target
|
|
39534
|
+
const filesFormat = target.files_format ?? target.filesFormat;
|
|
39380
39535
|
if (filesFormat !== void 0 && typeof filesFormat !== "string") {
|
|
39381
39536
|
errors2.push({
|
|
39382
39537
|
severity: "error",
|
|
@@ -39385,7 +39540,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39385
39540
|
message: "'filesFormat' must be a string when provided"
|
|
39386
39541
|
});
|
|
39387
39542
|
}
|
|
39388
|
-
const cwd = target
|
|
39543
|
+
const cwd = target.cwd;
|
|
39389
39544
|
if (cwd !== void 0 && typeof cwd !== "string") {
|
|
39390
39545
|
errors2.push({
|
|
39391
39546
|
severity: "error",
|
|
@@ -39394,7 +39549,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39394
39549
|
message: "'cwd' must be a string when provided"
|
|
39395
39550
|
});
|
|
39396
39551
|
}
|
|
39397
|
-
const timeoutSeconds = target
|
|
39552
|
+
const timeoutSeconds = target.timeout_seconds ?? target.timeoutSeconds;
|
|
39398
39553
|
if (timeoutSeconds !== void 0) {
|
|
39399
39554
|
const numericTimeout = Number(timeoutSeconds);
|
|
39400
39555
|
if (!Number.isFinite(numericTimeout) || numericTimeout <= 0) {
|
|
@@ -39406,7 +39561,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39406
39561
|
});
|
|
39407
39562
|
}
|
|
39408
39563
|
}
|
|
39409
|
-
const healthcheck = target
|
|
39564
|
+
const healthcheck = target.healthcheck;
|
|
39410
39565
|
if (healthcheck !== void 0) {
|
|
39411
39566
|
validateCliHealthcheck(healthcheck, absolutePath2, `${location}.healthcheck`, errors2);
|
|
39412
39567
|
}
|
|
@@ -39421,7 +39576,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39421
39576
|
});
|
|
39422
39577
|
return;
|
|
39423
39578
|
}
|
|
39424
|
-
const type = healthcheck
|
|
39579
|
+
const type = healthcheck.type;
|
|
39425
39580
|
if (type !== "http" && type !== "command") {
|
|
39426
39581
|
errors2.push({
|
|
39427
39582
|
severity: "error",
|
|
@@ -39431,7 +39586,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39431
39586
|
});
|
|
39432
39587
|
return;
|
|
39433
39588
|
}
|
|
39434
|
-
const timeoutSeconds = healthcheck
|
|
39589
|
+
const timeoutSeconds = healthcheck.timeout_seconds ?? healthcheck.timeoutSeconds;
|
|
39435
39590
|
if (timeoutSeconds !== void 0) {
|
|
39436
39591
|
const numericTimeout = Number(timeoutSeconds);
|
|
39437
39592
|
if (!Number.isFinite(numericTimeout) || numericTimeout <= 0) {
|
|
@@ -39444,7 +39599,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39444
39599
|
}
|
|
39445
39600
|
}
|
|
39446
39601
|
if (type === "http") {
|
|
39447
|
-
const url2 = healthcheck
|
|
39602
|
+
const url2 = healthcheck.url;
|
|
39448
39603
|
if (typeof url2 !== "string" || url2.trim().length === 0) {
|
|
39449
39604
|
errors2.push({
|
|
39450
39605
|
severity: "error",
|
|
@@ -39455,7 +39610,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39455
39610
|
}
|
|
39456
39611
|
return;
|
|
39457
39612
|
}
|
|
39458
|
-
const commandTemplate = healthcheck
|
|
39613
|
+
const commandTemplate = healthcheck.command_template ?? healthcheck.commandTemplate;
|
|
39459
39614
|
if (typeof commandTemplate !== "string" || commandTemplate.trim().length === 0) {
|
|
39460
39615
|
errors2.push({
|
|
39461
39616
|
severity: "error",
|
|
@@ -39464,9 +39619,14 @@ async function validateTargetsFile(filePath) {
|
|
|
39464
39619
|
message: "healthcheck.commandTemplate must be a non-empty string for command checks"
|
|
39465
39620
|
});
|
|
39466
39621
|
} else {
|
|
39467
|
-
recordUnknownPlaceholders(
|
|
39622
|
+
recordUnknownPlaceholders(
|
|
39623
|
+
commandTemplate,
|
|
39624
|
+
absolutePath2,
|
|
39625
|
+
`${location}.commandTemplate`,
|
|
39626
|
+
errors2
|
|
39627
|
+
);
|
|
39468
39628
|
}
|
|
39469
|
-
const cwd = healthcheck
|
|
39629
|
+
const cwd = healthcheck.cwd;
|
|
39470
39630
|
if (cwd !== void 0 && typeof cwd !== "string") {
|
|
39471
39631
|
errors2.push({
|
|
39472
39632
|
severity: "error",
|
|
@@ -39513,17 +39673,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39513
39673
|
errors
|
|
39514
39674
|
};
|
|
39515
39675
|
}
|
|
39516
|
-
const
|
|
39517
|
-
if (schema !== TARGETS_SCHEMA_V2) {
|
|
39518
|
-
const message = typeof schema === "string" ? `Invalid $schema value '${schema}'. Expected '${TARGETS_SCHEMA_V2}'` : `Missing required field '$schema'. Expected '${TARGETS_SCHEMA_V2}'`;
|
|
39519
|
-
errors.push({
|
|
39520
|
-
severity: "error",
|
|
39521
|
-
filePath: absolutePath,
|
|
39522
|
-
location: "$schema",
|
|
39523
|
-
message
|
|
39524
|
-
});
|
|
39525
|
-
}
|
|
39526
|
-
const targets = parsed["targets"];
|
|
39676
|
+
const targets = parsed.targets;
|
|
39527
39677
|
if (!Array.isArray(targets)) {
|
|
39528
39678
|
errors.push({
|
|
39529
39679
|
severity: "error",
|
|
@@ -39551,7 +39701,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39551
39701
|
});
|
|
39552
39702
|
continue;
|
|
39553
39703
|
}
|
|
39554
|
-
const name16 = target
|
|
39704
|
+
const name16 = target.name;
|
|
39555
39705
|
if (typeof name16 !== "string" || name16.trim().length === 0) {
|
|
39556
39706
|
errors.push({
|
|
39557
39707
|
severity: "error",
|
|
@@ -39560,7 +39710,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39560
39710
|
message: "Missing or invalid 'name' field (must be a non-empty string)"
|
|
39561
39711
|
});
|
|
39562
39712
|
}
|
|
39563
|
-
const provider = target
|
|
39713
|
+
const provider = target.provider;
|
|
39564
39714
|
const providerValue = typeof provider === "string" ? provider.trim().toLowerCase() : void 0;
|
|
39565
39715
|
if (typeof provider !== "string" || provider.trim().length === 0) {
|
|
39566
39716
|
errors.push({
|
|
@@ -39583,7 +39733,7 @@ async function validateTargetsFile(filePath) {
|
|
|
39583
39733
|
if (typeof provider === "string") {
|
|
39584
39734
|
validateUnknownSettings(target, provider, absolutePath, location, errors);
|
|
39585
39735
|
}
|
|
39586
|
-
const judgeTarget = target
|
|
39736
|
+
const judgeTarget = target.judge_target;
|
|
39587
39737
|
if (judgeTarget !== void 0 && typeof judgeTarget !== "string") {
|
|
39588
39738
|
errors.push({
|
|
39589
39739
|
severity: "error",
|
|
@@ -39615,7 +39765,7 @@ async function validateConfigFile(filePath) {
|
|
|
39615
39765
|
return { valid: false, filePath, fileType: "config", errors };
|
|
39616
39766
|
}
|
|
39617
39767
|
const config2 = parsed;
|
|
39618
|
-
const schema = config2
|
|
39768
|
+
const schema = config2.$schema;
|
|
39619
39769
|
if (schema !== SCHEMA_CONFIG_V222) {
|
|
39620
39770
|
const message = typeof schema === "string" ? `Invalid $schema value '${schema}'. Expected '${SCHEMA_CONFIG_V222}'` : `Missing required field '$schema'. Please add '$schema: ${SCHEMA_CONFIG_V222}' at the top of the file.`;
|
|
39621
39771
|
errors.push({
|
|
@@ -39625,7 +39775,7 @@ async function validateConfigFile(filePath) {
|
|
|
39625
39775
|
message
|
|
39626
39776
|
});
|
|
39627
39777
|
}
|
|
39628
|
-
const guidelinePatterns = config2
|
|
39778
|
+
const guidelinePatterns = config2.guideline_patterns;
|
|
39629
39779
|
if (guidelinePatterns !== void 0) {
|
|
39630
39780
|
if (!Array.isArray(guidelinePatterns)) {
|
|
39631
39781
|
errors.push({
|
|
@@ -39700,7 +39850,7 @@ async function validateFileReferences(evalFilePath) {
|
|
|
39700
39850
|
if (!isObject3(parsed)) {
|
|
39701
39851
|
return errors;
|
|
39702
39852
|
}
|
|
39703
|
-
const evalcases = parsed
|
|
39853
|
+
const evalcases = parsed.evalcases;
|
|
39704
39854
|
if (!Array.isArray(evalcases)) {
|
|
39705
39855
|
return errors;
|
|
39706
39856
|
}
|
|
@@ -39709,13 +39859,25 @@ async function validateFileReferences(evalFilePath) {
|
|
|
39709
39859
|
if (!isObject3(evalCase)) {
|
|
39710
39860
|
continue;
|
|
39711
39861
|
}
|
|
39712
|
-
const inputMessages = evalCase
|
|
39862
|
+
const inputMessages = evalCase.input_messages;
|
|
39713
39863
|
if (Array.isArray(inputMessages)) {
|
|
39714
|
-
await validateMessagesFileRefs(
|
|
39864
|
+
await validateMessagesFileRefs(
|
|
39865
|
+
inputMessages,
|
|
39866
|
+
`evalcases[${i}].input_messages`,
|
|
39867
|
+
searchRoots,
|
|
39868
|
+
absolutePath,
|
|
39869
|
+
errors
|
|
39870
|
+
);
|
|
39715
39871
|
}
|
|
39716
|
-
const expectedMessages = evalCase
|
|
39872
|
+
const expectedMessages = evalCase.expected_messages;
|
|
39717
39873
|
if (Array.isArray(expectedMessages)) {
|
|
39718
|
-
await validateMessagesFileRefs(
|
|
39874
|
+
await validateMessagesFileRefs(
|
|
39875
|
+
expectedMessages,
|
|
39876
|
+
`evalcases[${i}].expected_messages`,
|
|
39877
|
+
searchRoots,
|
|
39878
|
+
absolutePath,
|
|
39879
|
+
errors
|
|
39880
|
+
);
|
|
39719
39881
|
}
|
|
39720
39882
|
}
|
|
39721
39883
|
return errors;
|
|
@@ -39726,7 +39888,7 @@ async function validateMessagesFileRefs(messages, location, searchRoots, filePat
|
|
|
39726
39888
|
if (!isObject3(message)) {
|
|
39727
39889
|
continue;
|
|
39728
39890
|
}
|
|
39729
|
-
const content = message
|
|
39891
|
+
const content = message.content;
|
|
39730
39892
|
if (typeof content === "string") {
|
|
39731
39893
|
continue;
|
|
39732
39894
|
}
|
|
@@ -39738,11 +39900,11 @@ async function validateMessagesFileRefs(messages, location, searchRoots, filePat
|
|
|
39738
39900
|
if (!isObject3(contentItem)) {
|
|
39739
39901
|
continue;
|
|
39740
39902
|
}
|
|
39741
|
-
const type = contentItem
|
|
39903
|
+
const type = contentItem.type;
|
|
39742
39904
|
if (type !== "file") {
|
|
39743
39905
|
continue;
|
|
39744
39906
|
}
|
|
39745
|
-
const value = contentItem
|
|
39907
|
+
const value = contentItem.value;
|
|
39746
39908
|
if (typeof value !== "string") {
|
|
39747
39909
|
errors.push({
|
|
39748
39910
|
severity: "error",
|
|
@@ -39785,18 +39947,15 @@ async function validateMessagesFileRefs(messages, location, searchRoots, filePat
|
|
|
39785
39947
|
}
|
|
39786
39948
|
|
|
39787
39949
|
// src/commands/eval/targets.ts
|
|
39788
|
-
import { constants as constants5 } from "node:fs";
|
|
39789
|
-
import { access as access5 } from "node:fs/promises";
|
|
39790
|
-
import path17 from "node:path";
|
|
39791
39950
|
var TARGET_FILE_CANDIDATES = [
|
|
39792
39951
|
"targets.yaml",
|
|
39793
39952
|
"targets.yml",
|
|
39794
39953
|
path17.join(".agentv", "targets.yaml"),
|
|
39795
39954
|
path17.join(".agentv", "targets.yml")
|
|
39796
39955
|
];
|
|
39797
|
-
var
|
|
39798
|
-
var
|
|
39799
|
-
var
|
|
39956
|
+
var ANSI_YELLOW7 = "\x1B[33m";
|
|
39957
|
+
var ANSI_RED2 = "\x1B[31m";
|
|
39958
|
+
var ANSI_RESET7 = "\x1B[0m";
|
|
39800
39959
|
function isTTY() {
|
|
39801
39960
|
return process.stdout.isTTY ?? false;
|
|
39802
39961
|
}
|
|
@@ -39854,7 +40013,18 @@ function pickTargetName(options) {
|
|
|
39854
40013
|
return { name: "default", source: "default" };
|
|
39855
40014
|
}
|
|
39856
40015
|
async function selectTarget(options) {
|
|
39857
|
-
const {
|
|
40016
|
+
const {
|
|
40017
|
+
testFilePath,
|
|
40018
|
+
repoRoot,
|
|
40019
|
+
cwd,
|
|
40020
|
+
explicitTargetsPath,
|
|
40021
|
+
cliTargetName,
|
|
40022
|
+
dryRun,
|
|
40023
|
+
dryRunDelay,
|
|
40024
|
+
dryRunDelayMin,
|
|
40025
|
+
dryRunDelayMax,
|
|
40026
|
+
env
|
|
40027
|
+
} = options;
|
|
39858
40028
|
const targetsFilePath = await discoverTargetsFile({
|
|
39859
40029
|
explicitPath: explicitTargetsPath,
|
|
39860
40030
|
testFilePath,
|
|
@@ -39869,8 +40039,8 @@ async function selectTarget(options) {
|
|
|
39869
40039
|
Warnings in ${targetsFilePath}:`);
|
|
39870
40040
|
for (const warning of warnings) {
|
|
39871
40041
|
const location = warning.location ? ` [${warning.location}]` : "";
|
|
39872
|
-
const prefix = useColors ? `${
|
|
39873
|
-
const message = useColors ? `${
|
|
40042
|
+
const prefix = useColors ? `${ANSI_YELLOW7} \u26A0${ANSI_RESET7}` : " \u26A0";
|
|
40043
|
+
const message = useColors ? `${ANSI_YELLOW7}${warning.message}${ANSI_RESET7}` : warning.message;
|
|
39874
40044
|
console.warn(`${prefix}${location} ${message}`);
|
|
39875
40045
|
}
|
|
39876
40046
|
console.warn("");
|
|
@@ -39881,8 +40051,8 @@ Warnings in ${targetsFilePath}:`);
|
|
|
39881
40051
|
Errors in ${targetsFilePath}:`);
|
|
39882
40052
|
for (const error40 of errors) {
|
|
39883
40053
|
const location = error40.location ? ` [${error40.location}]` : "";
|
|
39884
|
-
const prefix = useColors ? `${
|
|
39885
|
-
const message = useColors ? `${
|
|
40054
|
+
const prefix = useColors ? `${ANSI_RED2} \u2717${ANSI_RESET7}` : " \u2717";
|
|
40055
|
+
const message = useColors ? `${ANSI_RED2}${error40.message}${ANSI_RESET7}` : error40.message;
|
|
39886
40056
|
console.error(`${prefix}${location} ${message}`);
|
|
39887
40057
|
}
|
|
39888
40058
|
throw new Error(`Targets file validation failed with ${errors.length} error(s)`);
|
|
@@ -39890,7 +40060,9 @@ Errors in ${targetsFilePath}:`);
|
|
|
39890
40060
|
const definitions = await readTargetDefinitions(targetsFilePath);
|
|
39891
40061
|
const fileTargetName = await readTestSuiteTarget(testFilePath);
|
|
39892
40062
|
const targetChoice = pickTargetName({ cliTargetName, fileTargetName });
|
|
39893
|
-
const targetDefinition = definitions.find(
|
|
40063
|
+
const targetDefinition = definitions.find(
|
|
40064
|
+
(definition) => definition.name === targetChoice.name
|
|
40065
|
+
);
|
|
39894
40066
|
if (!targetDefinition) {
|
|
39895
40067
|
const available = listTargetNames(definitions).join(", ");
|
|
39896
40068
|
throw new Error(
|
|
@@ -40080,9 +40252,12 @@ async function prepareFileMetadata(params) {
|
|
|
40080
40252
|
});
|
|
40081
40253
|
const providerLabel = options.dryRun ? `${selection.resolvedTarget.kind} (dry-run)` : selection.resolvedTarget.kind;
|
|
40082
40254
|
const inlineTargetLabel = `${selection.targetName} [provider=${providerLabel}]`;
|
|
40083
|
-
const evalCases = await loadEvalCases(testFilePath, repoRoot, {
|
|
40255
|
+
const evalCases = await loadEvalCases(testFilePath, repoRoot, {
|
|
40256
|
+
verbose: options.verbose,
|
|
40257
|
+
evalId: options.evalId
|
|
40258
|
+
});
|
|
40084
40259
|
const filteredIds = options.evalId ? evalCases.filter((value) => value.id === options.evalId).map((value) => value.id) : evalCases.map((value) => value.id);
|
|
40085
|
-
return { evalIds: filteredIds, selection, inlineTargetLabel };
|
|
40260
|
+
return { evalIds: filteredIds, evalCases, selection, inlineTargetLabel };
|
|
40086
40261
|
}
|
|
40087
40262
|
async function runWithLimit(items, limit, task) {
|
|
40088
40263
|
const safeLimit = Math.max(1, limit);
|
|
@@ -40110,7 +40285,8 @@ async function runSingleEvalFile(params) {
|
|
|
40110
40285
|
seenEvalCases,
|
|
40111
40286
|
displayIdTracker,
|
|
40112
40287
|
selection,
|
|
40113
|
-
inlineTargetLabel
|
|
40288
|
+
inlineTargetLabel,
|
|
40289
|
+
evalCases
|
|
40114
40290
|
} = params;
|
|
40115
40291
|
await ensureFileExists(testFilePath, "Test file");
|
|
40116
40292
|
const resolvedTargetSelection = selection;
|
|
@@ -40136,7 +40312,9 @@ async function runSingleEvalFile(params) {
|
|
|
40136
40312
|
resolvedTargetSelection.resolvedTarget.kind
|
|
40137
40313
|
);
|
|
40138
40314
|
if (isVSCodeProvider && resolvedWorkers > 1) {
|
|
40139
|
-
console.warn(
|
|
40315
|
+
console.warn(
|
|
40316
|
+
`Warning: VSCode providers require window focus. Limiting workers from ${resolvedWorkers} to 1 to prevent race conditions.`
|
|
40317
|
+
);
|
|
40140
40318
|
resolvedWorkers = 1;
|
|
40141
40319
|
}
|
|
40142
40320
|
if (options.verbose) {
|
|
@@ -40162,6 +40340,7 @@ async function runSingleEvalFile(params) {
|
|
|
40162
40340
|
cache,
|
|
40163
40341
|
useCache: options.cache,
|
|
40164
40342
|
evalId: options.evalId,
|
|
40343
|
+
evalCases,
|
|
40165
40344
|
verbose: options.verbose,
|
|
40166
40345
|
maxConcurrency: resolvedWorkers,
|
|
40167
40346
|
onResult: async (result) => {
|
|
@@ -40205,7 +40384,10 @@ async function runEvalCommand(input) {
|
|
|
40205
40384
|
const resolvedTestFiles = input.testFiles.map((file2) => path18.resolve(file2));
|
|
40206
40385
|
const displayIdTracker = createDisplayIdTracker();
|
|
40207
40386
|
const totalWorkers = options.workers ?? DEFAULT_WORKERS;
|
|
40208
|
-
const fileConcurrency = Math.min(
|
|
40387
|
+
const fileConcurrency = Math.min(
|
|
40388
|
+
Math.max(1, totalWorkers),
|
|
40389
|
+
Math.max(1, resolvedTestFiles.length)
|
|
40390
|
+
);
|
|
40209
40391
|
const perFileWorkers = options.workers ? Math.max(1, Math.floor(totalWorkers / fileConcurrency)) : void 0;
|
|
40210
40392
|
const fileMetadata = /* @__PURE__ */ new Map();
|
|
40211
40393
|
for (const testFilePath of resolvedTestFiles) {
|
|
@@ -40267,7 +40449,8 @@ async function runEvalCommand(input) {
|
|
|
40267
40449
|
seenEvalCases,
|
|
40268
40450
|
displayIdTracker,
|
|
40269
40451
|
selection: targetPrep.selection,
|
|
40270
|
-
inlineTargetLabel: targetPrep.inlineTargetLabel
|
|
40452
|
+
inlineTargetLabel: targetPrep.inlineTargetLabel,
|
|
40453
|
+
evalCases: targetPrep.evalCases
|
|
40271
40454
|
});
|
|
40272
40455
|
allResults.push(...result.results);
|
|
40273
40456
|
if (result.promptDumpDir) {
|
|
@@ -40388,7 +40571,9 @@ async function resolveEvalPaths(evalPaths, cwd) {
|
|
|
40388
40571
|
unmatched.push(pattern);
|
|
40389
40572
|
continue;
|
|
40390
40573
|
}
|
|
40391
|
-
|
|
40574
|
+
for (const filePath of yamlMatches) {
|
|
40575
|
+
results.add(path19.normalize(filePath));
|
|
40576
|
+
}
|
|
40392
40577
|
}
|
|
40393
40578
|
if (unmatched.length > 0) {
|
|
40394
40579
|
throw new Error(
|
|
@@ -40411,47 +40596,45 @@ import * as readline from "node:readline/promises";
|
|
|
40411
40596
|
import { readFileSync, readdirSync, statSync } from "node:fs";
|
|
40412
40597
|
import path20 from "node:path";
|
|
40413
40598
|
import { fileURLToPath } from "node:url";
|
|
40414
|
-
|
|
40415
|
-
|
|
40416
|
-
|
|
40417
|
-
|
|
40418
|
-
|
|
40419
|
-
|
|
40420
|
-
|
|
40421
|
-
|
|
40422
|
-
|
|
40423
|
-
|
|
40424
|
-
|
|
40425
|
-
|
|
40426
|
-
|
|
40427
|
-
|
|
40428
|
-
|
|
40599
|
+
function getGithubTemplates() {
|
|
40600
|
+
return getTemplatesFromDir(".github");
|
|
40601
|
+
}
|
|
40602
|
+
function getAgentvTemplates() {
|
|
40603
|
+
return getTemplatesFromDir(".agentv");
|
|
40604
|
+
}
|
|
40605
|
+
function getClaudeTemplates() {
|
|
40606
|
+
return getTemplatesFromDir(".claude");
|
|
40607
|
+
}
|
|
40608
|
+
function getTemplatesFromDir(subdir) {
|
|
40609
|
+
const currentDir = path20.dirname(fileURLToPath(import.meta.url));
|
|
40610
|
+
let templatesDir;
|
|
40611
|
+
if (currentDir.includes(`${path20.sep}dist`)) {
|
|
40612
|
+
templatesDir = path20.join(currentDir, "templates", subdir);
|
|
40613
|
+
} else {
|
|
40614
|
+
templatesDir = path20.join(currentDir, subdir);
|
|
40615
|
+
}
|
|
40616
|
+
return readTemplatesRecursively(templatesDir, "");
|
|
40617
|
+
}
|
|
40618
|
+
function readTemplatesRecursively(dir, relativePath) {
|
|
40619
|
+
const templates = [];
|
|
40620
|
+
const entries = readdirSync(dir);
|
|
40621
|
+
for (const entry of entries) {
|
|
40622
|
+
const fullPath = path20.join(dir, entry);
|
|
40623
|
+
const stat5 = statSync(fullPath);
|
|
40624
|
+
const entryRelativePath = relativePath ? path20.join(relativePath, entry) : entry;
|
|
40625
|
+
if (stat5.isDirectory()) {
|
|
40626
|
+
templates.push(...readTemplatesRecursively(fullPath, entryRelativePath));
|
|
40429
40627
|
} else {
|
|
40430
|
-
|
|
40431
|
-
|
|
40432
|
-
|
|
40433
|
-
|
|
40434
|
-
|
|
40435
|
-
|
|
40436
|
-
const entries = readdirSync(dir);
|
|
40437
|
-
for (const entry of entries) {
|
|
40438
|
-
const fullPath = path20.join(dir, entry);
|
|
40439
|
-
const stat5 = statSync(fullPath);
|
|
40440
|
-
const entryRelativePath = relativePath ? path20.join(relativePath, entry) : entry;
|
|
40441
|
-
if (stat5.isDirectory()) {
|
|
40442
|
-
templates.push(...this.readTemplatesRecursively(fullPath, entryRelativePath));
|
|
40443
|
-
} else {
|
|
40444
|
-
const content = readFileSync(fullPath, "utf-8");
|
|
40445
|
-
templates.push({
|
|
40446
|
-
path: entryRelativePath.split(path20.sep).join("/"),
|
|
40447
|
-
// Normalize to forward slashes
|
|
40448
|
-
content
|
|
40449
|
-
});
|
|
40450
|
-
}
|
|
40628
|
+
const content = readFileSync(fullPath, "utf-8");
|
|
40629
|
+
templates.push({
|
|
40630
|
+
path: entryRelativePath.split(path20.sep).join("/"),
|
|
40631
|
+
// Normalize to forward slashes
|
|
40632
|
+
content
|
|
40633
|
+
});
|
|
40451
40634
|
}
|
|
40452
|
-
return templates;
|
|
40453
40635
|
}
|
|
40454
|
-
|
|
40636
|
+
return templates;
|
|
40637
|
+
}
|
|
40455
40638
|
|
|
40456
40639
|
// src/commands/init/index.ts
|
|
40457
40640
|
async function promptYesNo(message) {
|
|
@@ -40471,9 +40654,9 @@ async function initCommand(options = {}) {
|
|
|
40471
40654
|
const githubDir = path21.join(targetPath, ".github");
|
|
40472
40655
|
const agentvDir = path21.join(targetPath, ".agentv");
|
|
40473
40656
|
const claudeDir = path21.join(targetPath, ".claude");
|
|
40474
|
-
const githubTemplates =
|
|
40475
|
-
const agentvTemplates =
|
|
40476
|
-
const claudeTemplates =
|
|
40657
|
+
const githubTemplates = getGithubTemplates();
|
|
40658
|
+
const agentvTemplates = getAgentvTemplates();
|
|
40659
|
+
const claudeTemplates = getClaudeTemplates();
|
|
40477
40660
|
const envTemplate = agentvTemplates.find((t) => t.path === ".env.template");
|
|
40478
40661
|
const otherAgentvTemplates = agentvTemplates.filter((t) => t.path !== ".env.template");
|
|
40479
40662
|
const existingFiles = [];
|
|
@@ -40509,7 +40692,9 @@ async function initCommand(options = {}) {
|
|
|
40509
40692
|
}
|
|
40510
40693
|
if (existingFiles.length > 0) {
|
|
40511
40694
|
console.log("We detected an existing setup:");
|
|
40512
|
-
|
|
40695
|
+
for (const file2 of existingFiles) {
|
|
40696
|
+
console.log(` - ${file2}`);
|
|
40697
|
+
}
|
|
40513
40698
|
console.log();
|
|
40514
40699
|
const shouldReplace = await promptYesNo("Do you want to replace these files?");
|
|
40515
40700
|
if (!shouldReplace) {
|
|
@@ -40560,20 +40745,25 @@ async function initCommand(options = {}) {
|
|
|
40560
40745
|
console.log(`Created ${path21.relative(targetPath, targetFilePath)}`);
|
|
40561
40746
|
}
|
|
40562
40747
|
console.log("\nAgentV initialized successfully!");
|
|
40563
|
-
console.log(
|
|
40564
|
-
Files installed to root:`);
|
|
40748
|
+
console.log("\nFiles installed to root:");
|
|
40565
40749
|
if (envTemplate) {
|
|
40566
|
-
console.log(
|
|
40750
|
+
console.log(" - .env.template");
|
|
40567
40751
|
}
|
|
40568
40752
|
console.log(`
|
|
40569
40753
|
Files installed to ${path21.relative(targetPath, githubDir)}:`);
|
|
40570
|
-
|
|
40754
|
+
for (const t of githubTemplates) {
|
|
40755
|
+
console.log(` - ${t.path}`);
|
|
40756
|
+
}
|
|
40571
40757
|
console.log(`
|
|
40572
40758
|
Files installed to ${path21.relative(targetPath, agentvDir)}:`);
|
|
40573
|
-
|
|
40759
|
+
for (const t of otherAgentvTemplates) {
|
|
40760
|
+
console.log(` - ${t.path}`);
|
|
40761
|
+
}
|
|
40574
40762
|
console.log(`
|
|
40575
40763
|
Files installed to ${path21.relative(targetPath, claudeDir)}:`);
|
|
40576
|
-
|
|
40764
|
+
for (const t of claudeTemplates) {
|
|
40765
|
+
console.log(` - ${t.path}`);
|
|
40766
|
+
}
|
|
40577
40767
|
console.log("\nYou can now:");
|
|
40578
40768
|
console.log(" 1. Copy .env.template to .env and add your API credentials");
|
|
40579
40769
|
console.log(" 2. Configure targets in .agentv/targets.yaml");
|
|
@@ -40590,12 +40780,12 @@ function registerStatusCommand(program) {
|
|
|
40590
40780
|
}
|
|
40591
40781
|
|
|
40592
40782
|
// src/commands/validate/format-output.ts
|
|
40593
|
-
var
|
|
40594
|
-
var
|
|
40783
|
+
var ANSI_RED3 = "\x1B[31m";
|
|
40784
|
+
var ANSI_YELLOW8 = "\x1B[33m";
|
|
40595
40785
|
var ANSI_GREEN = "\x1B[32m";
|
|
40596
40786
|
var ANSI_CYAN = "\x1B[36m";
|
|
40597
40787
|
var ANSI_BOLD = "\x1B[1m";
|
|
40598
|
-
var
|
|
40788
|
+
var ANSI_RESET8 = "\x1B[0m";
|
|
40599
40789
|
function formatSummary(summary, useColors) {
|
|
40600
40790
|
const lines = [];
|
|
40601
40791
|
lines.push("");
|
|
@@ -40611,15 +40801,15 @@ function formatSummary(summary, useColors) {
|
|
|
40611
40801
|
}
|
|
40612
40802
|
function formatHeader(text2, useColors) {
|
|
40613
40803
|
if (useColors) {
|
|
40614
|
-
return `${ANSI_BOLD}${ANSI_CYAN}${text2}${
|
|
40804
|
+
return `${ANSI_BOLD}${ANSI_CYAN}${text2}${ANSI_RESET8}`;
|
|
40615
40805
|
}
|
|
40616
40806
|
return text2;
|
|
40617
40807
|
}
|
|
40618
40808
|
function formatFileResult(result, useColors) {
|
|
40619
40809
|
const lines = [];
|
|
40620
40810
|
const status = result.valid ? "\u2713" : "\u2717";
|
|
40621
|
-
const statusColor = result.valid ? ANSI_GREEN :
|
|
40622
|
-
const statusText = useColors ? `${statusColor}${status}${
|
|
40811
|
+
const statusColor = result.valid ? ANSI_GREEN : ANSI_RED3;
|
|
40812
|
+
const statusText = useColors ? `${statusColor}${status}${ANSI_RESET8}` : status;
|
|
40623
40813
|
const fileName = result.filePath;
|
|
40624
40814
|
lines.push(`${statusText} ${fileName}`);
|
|
40625
40815
|
if (result.errors.length > 0) {
|
|
@@ -40631,8 +40821,8 @@ function formatFileResult(result, useColors) {
|
|
|
40631
40821
|
}
|
|
40632
40822
|
function formatError2(error40, useColors) {
|
|
40633
40823
|
const prefix = error40.severity === "error" ? " \u2717" : " \u26A0";
|
|
40634
|
-
const color = error40.severity === "error" ?
|
|
40635
|
-
const coloredPrefix = useColors ? `${color}${prefix}${
|
|
40824
|
+
const color = error40.severity === "error" ? ANSI_RED3 : ANSI_YELLOW8;
|
|
40825
|
+
const coloredPrefix = useColors ? `${color}${prefix}${ANSI_RESET8}` : prefix;
|
|
40636
40826
|
const location = error40.location ? ` [${error40.location}]` : "";
|
|
40637
40827
|
return `${coloredPrefix}${location} ${error40.message}`;
|
|
40638
40828
|
}
|
|
@@ -40645,15 +40835,15 @@ function formatStats(summary, useColors) {
|
|
|
40645
40835
|
(r) => r.errors.some((e) => e.severity === "warning")
|
|
40646
40836
|
).length;
|
|
40647
40837
|
if (useColors) {
|
|
40648
|
-
lines.push(`${ANSI_BOLD}${totalText}${
|
|
40649
|
-
lines.push(`${ANSI_GREEN}${validText}${
|
|
40838
|
+
lines.push(`${ANSI_BOLD}${totalText}${ANSI_RESET8}`);
|
|
40839
|
+
lines.push(`${ANSI_GREEN}${validText}${ANSI_RESET8}`);
|
|
40650
40840
|
if (summary.invalidFiles > 0) {
|
|
40651
|
-
lines.push(`${
|
|
40841
|
+
lines.push(`${ANSI_RED3}${invalidText}${ANSI_RESET8}`);
|
|
40652
40842
|
} else {
|
|
40653
40843
|
lines.push(invalidText);
|
|
40654
40844
|
}
|
|
40655
40845
|
if (filesWithWarnings > 0) {
|
|
40656
|
-
lines.push(`${
|
|
40846
|
+
lines.push(`${ANSI_YELLOW8}Files with warnings: ${filesWithWarnings}${ANSI_RESET8}`);
|
|
40657
40847
|
}
|
|
40658
40848
|
} else {
|
|
40659
40849
|
lines.push(totalText);
|
|
@@ -40807,7 +40997,9 @@ function createProgram() {
|
|
|
40807
40997
|
registerStatusCommand(program);
|
|
40808
40998
|
registerEvalCommand(program);
|
|
40809
40999
|
registerValidateCommand(program);
|
|
40810
|
-
program.command("init [path]").description(
|
|
41000
|
+
program.command("init [path]").description(
|
|
41001
|
+
"Initialize AgentV in your project (installs prompt templates and schema to .github)"
|
|
41002
|
+
).action(async (targetPath) => {
|
|
40811
41003
|
try {
|
|
40812
41004
|
await initCommand({ targetPath });
|
|
40813
41005
|
} catch (error40) {
|
|
@@ -40827,4 +41019,4 @@ export {
|
|
|
40827
41019
|
createProgram,
|
|
40828
41020
|
runCli
|
|
40829
41021
|
};
|
|
40830
|
-
//# sourceMappingURL=chunk-
|
|
41022
|
+
//# sourceMappingURL=chunk-KL3Y2C6J.js.map
|