agentv 4.9.0 → 4.9.1
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/dist/{chunk-6HQCMEGO.js → chunk-2IKIOZ4Z.js} +5 -5
- package/dist/{chunk-6HQCMEGO.js.map → chunk-2IKIOZ4Z.js.map} +1 -1
- package/dist/{chunk-MTXZDEVR.js → chunk-2JW4HVCX.js} +4 -4
- package/dist/{chunk-7K5LYK5B.js → chunk-RHAXSXIY.js} +36 -21
- package/dist/chunk-RHAXSXIY.js.map +1 -0
- package/dist/cli.js +3 -3
- package/dist/{dist-2VDI64IM.js → dist-DDFE3W2A.js} +2 -2
- package/dist/index.js +3 -3
- package/dist/{interactive-UDDXUKAU.js → interactive-VMDBXBRL.js} +3 -3
- package/package.json +1 -1
- package/dist/chunk-7K5LYK5B.js.map +0 -1
- /package/dist/{chunk-MTXZDEVR.js.map → chunk-2JW4HVCX.js.map} +0 -0
- /package/dist/{dist-2VDI64IM.js.map → dist-DDFE3W2A.js.map} +0 -0
- /package/dist/{interactive-UDDXUKAU.js.map → interactive-VMDBXBRL.js.map} +0 -0
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
validateFileReferences,
|
|
28
28
|
validateTargetsFile,
|
|
29
29
|
writeArtifactsFromResults
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-2IKIOZ4Z.js";
|
|
31
31
|
import {
|
|
32
32
|
DEFAULT_CATEGORY,
|
|
33
33
|
DEFAULT_THRESHOLD,
|
|
@@ -61,7 +61,7 @@ import {
|
|
|
61
61
|
toTranscriptJsonLine,
|
|
62
62
|
transpileEvalYamlFile,
|
|
63
63
|
trimBaselineResult
|
|
64
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-RHAXSXIY.js";
|
|
65
65
|
import {
|
|
66
66
|
__commonJS,
|
|
67
67
|
__require,
|
|
@@ -3892,7 +3892,7 @@ var evalRunCommand = command({
|
|
|
3892
3892
|
},
|
|
3893
3893
|
handler: async (args) => {
|
|
3894
3894
|
if (args.evalPaths.length === 0 && process.stdin.isTTY) {
|
|
3895
|
-
const { launchInteractiveWizard } = await import("./interactive-
|
|
3895
|
+
const { launchInteractiveWizard } = await import("./interactive-VMDBXBRL.js");
|
|
3896
3896
|
await launchInteractiveWizard();
|
|
3897
3897
|
return;
|
|
3898
3898
|
}
|
|
@@ -9446,4 +9446,4 @@ export {
|
|
|
9446
9446
|
preprocessArgv,
|
|
9447
9447
|
runCli
|
|
9448
9448
|
};
|
|
9449
|
-
//# sourceMappingURL=chunk-
|
|
9449
|
+
//# sourceMappingURL=chunk-2JW4HVCX.js.map
|
|
@@ -14528,6 +14528,7 @@ import { createServer } from "node:http";
|
|
|
14528
14528
|
import fs2 from "node:fs/promises";
|
|
14529
14529
|
import path35 from "node:path";
|
|
14530
14530
|
import { createHash as createHash2, randomUUID as randomUUID9 } from "node:crypto";
|
|
14531
|
+
import { existsSync as existsSync5 } from "node:fs";
|
|
14531
14532
|
import { copyFile as copyFile2, mkdir as mkdir14, readdir as readdir7, stat as stat8 } from "node:fs/promises";
|
|
14532
14533
|
import path44 from "node:path";
|
|
14533
14534
|
import micromatch3 from "micromatch";
|
|
@@ -14554,14 +14555,14 @@ import path422 from "node:path";
|
|
|
14554
14555
|
import { promisify as promisify6 } from "node:util";
|
|
14555
14556
|
import { readdir as readdir6, stat as stat7 } from "node:fs/promises";
|
|
14556
14557
|
import path43 from "node:path";
|
|
14557
|
-
import { existsSync as
|
|
14558
|
+
import { existsSync as existsSync6 } from "node:fs";
|
|
14558
14559
|
import path45 from "node:path";
|
|
14559
14560
|
import { readFile as readFile13 } from "node:fs/promises";
|
|
14560
14561
|
import path46 from "node:path";
|
|
14561
14562
|
import { parse as parse5 } from "yaml";
|
|
14562
14563
|
import { mkdir as mkdir15, readFile as readFile14, writeFile as writeFile8 } from "node:fs/promises";
|
|
14563
14564
|
import path47 from "node:path";
|
|
14564
|
-
import { existsSync as
|
|
14565
|
+
import { existsSync as existsSync7, mkdirSync as mkdirSync2, readFileSync as readFileSync3, readdirSync as readdirSync3, statSync as statSync2, writeFileSync } from "node:fs";
|
|
14565
14566
|
import path48 from "node:path";
|
|
14566
14567
|
import { parse as parseYaml3, stringify as stringifyYaml } from "yaml";
|
|
14567
14568
|
import { readdir as readdir8, stat as stat9 } from "node:fs/promises";
|
|
@@ -30384,8 +30385,8 @@ async function runEvaluation(options) {
|
|
|
30384
30385
|
const poolSlotBaselines = /* @__PURE__ */ new Map();
|
|
30385
30386
|
const poolMaxSlots = Math.min(configPoolMaxSlots ?? 10, 50);
|
|
30386
30387
|
let staticMaterialised = false;
|
|
30388
|
+
const isYamlConfiguredPath = !cliWorkspacePath && !!yamlWorkspacePath;
|
|
30387
30389
|
if (useStaticWorkspace && configuredStaticPath) {
|
|
30388
|
-
const isYamlConfiguredPath = !cliWorkspacePath && !!yamlWorkspacePath;
|
|
30389
30390
|
const dirExists = await stat8(configuredStaticPath).then(
|
|
30390
30391
|
(s) => s.isDirectory(),
|
|
30391
30392
|
() => false
|
|
@@ -30450,14 +30451,28 @@ async function runEvaluation(options) {
|
|
|
30450
30451
|
} catch {
|
|
30451
30452
|
}
|
|
30452
30453
|
}
|
|
30453
|
-
const
|
|
30454
|
-
const
|
|
30455
|
-
|
|
30456
|
-
|
|
30457
|
-
|
|
30458
|
-
);
|
|
30454
|
+
const hasReposToMaterialize = !!suiteWorkspace?.repos?.length && !usePool && !isPerTestIsolation;
|
|
30455
|
+
const needsRepoMaterialisation = hasReposToMaterialize && (!useStaticWorkspace || staticMaterialised);
|
|
30456
|
+
const needsPerRepoCheck = hasReposToMaterialize && useStaticWorkspace && !staticMaterialised && isYamlConfiguredPath;
|
|
30457
|
+
const repoManager = needsRepoMaterialisation || needsPerRepoCheck ? new RepoManager(verbose) : void 0;
|
|
30458
|
+
if (repoManager && sharedWorkspacePath && suiteWorkspace?.repos) {
|
|
30459
30459
|
try {
|
|
30460
|
-
|
|
30460
|
+
if (needsPerRepoCheck) {
|
|
30461
|
+
for (const repo of suiteWorkspace.repos) {
|
|
30462
|
+
const targetDir = path44.join(sharedWorkspacePath, repo.path);
|
|
30463
|
+
if (existsSync5(targetDir)) {
|
|
30464
|
+
setupLog(`reusing existing repo at: ${targetDir}`);
|
|
30465
|
+
continue;
|
|
30466
|
+
}
|
|
30467
|
+
setupLog(`materializing missing repo: ${repo.path}`);
|
|
30468
|
+
await repoManager.materialize(repo, sharedWorkspacePath);
|
|
30469
|
+
}
|
|
30470
|
+
} else {
|
|
30471
|
+
setupLog(
|
|
30472
|
+
`materializing ${suiteWorkspace.repos.length} shared repo(s) into ${sharedWorkspacePath}`
|
|
30473
|
+
);
|
|
30474
|
+
await repoManager.materializeAll(suiteWorkspace.repos, sharedWorkspacePath);
|
|
30475
|
+
}
|
|
30461
30476
|
setupLog("shared repo materialization complete");
|
|
30462
30477
|
} catch (error) {
|
|
30463
30478
|
const message = error instanceof Error ? error.message : String(error);
|
|
@@ -32280,7 +32295,7 @@ async function discoverDefaultTarget(repoRoot) {
|
|
|
32280
32295
|
for (const dir of chain) {
|
|
32281
32296
|
for (const candidate of TARGET_FILE_CANDIDATES) {
|
|
32282
32297
|
const targetsPath = path45.join(dir, candidate);
|
|
32283
|
-
if (!
|
|
32298
|
+
if (!existsSync6(targetsPath)) continue;
|
|
32284
32299
|
try {
|
|
32285
32300
|
const definitions = await readTargetDefinitions(targetsPath);
|
|
32286
32301
|
const defaultTarget = definitions.find((d) => d.name === "default");
|
|
@@ -32297,7 +32312,7 @@ async function loadEnvHierarchy(repoRoot, startPath) {
|
|
|
32297
32312
|
const envFiles = [];
|
|
32298
32313
|
for (const dir of chain) {
|
|
32299
32314
|
const envPath = path45.join(dir, ".env");
|
|
32300
|
-
if (
|
|
32315
|
+
if (existsSync6(envPath)) envFiles.push(envPath);
|
|
32301
32316
|
}
|
|
32302
32317
|
for (let i = 0; i < envFiles.length; i++) {
|
|
32303
32318
|
try {
|
|
@@ -32370,12 +32385,12 @@ var CONFIG_FILE_NAMES = [
|
|
|
32370
32385
|
".agentv/config.js"
|
|
32371
32386
|
];
|
|
32372
32387
|
async function loadTsConfig(projectRoot) {
|
|
32373
|
-
const { existsSync:
|
|
32388
|
+
const { existsSync: existsSync8 } = await import("node:fs");
|
|
32374
32389
|
const { pathToFileURL: pathToFileURL2 } = await import("node:url");
|
|
32375
32390
|
const { join: join2 } = await import("node:path");
|
|
32376
32391
|
for (const fileName of CONFIG_FILE_NAMES) {
|
|
32377
32392
|
const filePath = join2(projectRoot, fileName);
|
|
32378
|
-
if (!
|
|
32393
|
+
if (!existsSync8(filePath)) {
|
|
32379
32394
|
continue;
|
|
32380
32395
|
}
|
|
32381
32396
|
try {
|
|
@@ -32600,7 +32615,7 @@ function getProjectsRegistryPath() {
|
|
|
32600
32615
|
}
|
|
32601
32616
|
function loadProjectRegistry() {
|
|
32602
32617
|
const registryPath = getProjectsRegistryPath();
|
|
32603
|
-
if (!
|
|
32618
|
+
if (!existsSync7(registryPath)) {
|
|
32604
32619
|
return { projects: [] };
|
|
32605
32620
|
}
|
|
32606
32621
|
try {
|
|
@@ -32617,7 +32632,7 @@ function loadProjectRegistry() {
|
|
|
32617
32632
|
function saveProjectRegistry(registry) {
|
|
32618
32633
|
const registryPath = getProjectsRegistryPath();
|
|
32619
32634
|
const dir = path48.dirname(registryPath);
|
|
32620
|
-
if (!
|
|
32635
|
+
if (!existsSync7(dir)) {
|
|
32621
32636
|
mkdirSync2(dir, { recursive: true });
|
|
32622
32637
|
}
|
|
32623
32638
|
writeFileSync(registryPath, stringifyYaml(registry), "utf-8");
|
|
@@ -32634,10 +32649,10 @@ function deriveProjectId(dirPath, existingIds) {
|
|
|
32634
32649
|
}
|
|
32635
32650
|
function addProject(projectPath) {
|
|
32636
32651
|
const absPath = path48.resolve(projectPath);
|
|
32637
|
-
if (!
|
|
32652
|
+
if (!existsSync7(absPath)) {
|
|
32638
32653
|
throw new Error(`Directory not found: ${absPath}`);
|
|
32639
32654
|
}
|
|
32640
|
-
if (!
|
|
32655
|
+
if (!existsSync7(path48.join(absPath, ".agentv"))) {
|
|
32641
32656
|
throw new Error(`No .agentv/ directory found in ${absPath}. Run an evaluation first.`);
|
|
32642
32657
|
}
|
|
32643
32658
|
const registry = loadProjectRegistry();
|
|
@@ -32681,13 +32696,13 @@ function touchProject(projectId) {
|
|
|
32681
32696
|
}
|
|
32682
32697
|
function discoverProjects(rootDir, maxDepth = 2) {
|
|
32683
32698
|
const absRoot = path48.resolve(rootDir);
|
|
32684
|
-
if (!
|
|
32699
|
+
if (!existsSync7(absRoot) || !statSync2(absRoot).isDirectory()) {
|
|
32685
32700
|
return [];
|
|
32686
32701
|
}
|
|
32687
32702
|
const results = [];
|
|
32688
32703
|
function scan(dir, depth) {
|
|
32689
32704
|
if (depth > maxDepth) return;
|
|
32690
|
-
if (
|
|
32705
|
+
if (existsSync7(path48.join(dir, ".agentv"))) {
|
|
32691
32706
|
results.push(dir);
|
|
32692
32707
|
return;
|
|
32693
32708
|
}
|
|
@@ -33966,4 +33981,4 @@ export {
|
|
|
33966
33981
|
TranscriptProvider,
|
|
33967
33982
|
createAgentKernel
|
|
33968
33983
|
};
|
|
33969
|
-
//# sourceMappingURL=chunk-
|
|
33984
|
+
//# sourceMappingURL=chunk-RHAXSXIY.js.map
|