agentv 4.31.3 → 4.32.0-next.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.
Files changed (32) hide show
  1. package/README.md +14 -0
  2. package/dist/{artifact-writer-FZ5RUHWC.js → artifact-writer-VDF7KRWL.js} +4 -4
  3. package/dist/{chunk-IJPWTVDU.js → chunk-2ZEY3WBH.js} +3 -3
  4. package/dist/{chunk-CO23UZAA.js → chunk-5JMFFG36.js} +13 -9
  5. package/dist/chunk-5JMFFG36.js.map +1 -0
  6. package/dist/{chunk-4POCDPC2.js → chunk-IGTRNQAM.js} +106 -63
  7. package/dist/chunk-IGTRNQAM.js.map +1 -0
  8. package/dist/{chunk-LOYPSIE7.js → chunk-LX5AK3P7.js} +22 -12
  9. package/dist/chunk-LX5AK3P7.js.map +1 -0
  10. package/dist/{chunk-377GONL7.js → chunk-TAZBCVEZ.js} +66 -62
  11. package/dist/chunk-TAZBCVEZ.js.map +1 -0
  12. package/dist/cli.js +5 -5
  13. package/dist/cli.js.map +1 -1
  14. package/dist/{studio/assets/index-sazn_aO8.js → dashboard/assets/index-BdoQWnyM.js} +1 -1
  15. package/dist/{studio/assets/index-CYUVGyMn.css → dashboard/assets/index-DcPH8PyS.css} +1 -1
  16. package/dist/dashboard/assets/index-EXkiwqam.js +116 -0
  17. package/dist/{studio → dashboard}/index.html +3 -3
  18. package/dist/{dist-CRYAFKLS.js → dist-GICSKMNP.js} +5 -3
  19. package/dist/index.js +9 -7
  20. package/dist/{interactive-QBLQNYDH.js → interactive-GIDBBDYZ.js} +5 -5
  21. package/dist/{ts-eval-loader-XR6DNOZ3-GA7B5N26.js → ts-eval-loader-Z6IUSDNA-YBOE4JIQ.js} +2 -2
  22. package/package.json +1 -1
  23. package/dist/chunk-377GONL7.js.map +0 -1
  24. package/dist/chunk-4POCDPC2.js.map +0 -1
  25. package/dist/chunk-CO23UZAA.js.map +0 -1
  26. package/dist/chunk-LOYPSIE7.js.map +0 -1
  27. package/dist/studio/assets/index-DBSSri9Q.js +0 -116
  28. /package/dist/{artifact-writer-FZ5RUHWC.js.map → artifact-writer-VDF7KRWL.js.map} +0 -0
  29. /package/dist/{chunk-IJPWTVDU.js.map → chunk-2ZEY3WBH.js.map} +0 -0
  30. /package/dist/{dist-CRYAFKLS.js.map → dist-GICSKMNP.js.map} +0 -0
  31. /package/dist/{interactive-QBLQNYDH.js.map → interactive-GIDBBDYZ.js.map} +0 -0
  32. /package/dist/{ts-eval-loader-XR6DNOZ3-GA7B5N26.js.map → ts-eval-loader-Z6IUSDNA-YBOE4JIQ.js.map} +0 -0
@@ -3,7 +3,7 @@ import {
3
3
  external_exports,
4
4
  extractLastAssistantContent,
5
5
  getAgentvConfigDir,
6
- getAgentvHome,
6
+ getAgentvDataDir,
7
7
  interpolateEnv,
8
8
  normalizeToolCall,
9
9
  parseRepoCheckout,
@@ -12,7 +12,7 @@ import {
12
12
  parseYamlValue,
13
13
  toCamelCaseDeep,
14
14
  toSnakeCaseDeep
15
- } from "./chunk-377GONL7.js";
15
+ } from "./chunk-TAZBCVEZ.js";
16
16
 
17
17
  // ../../packages/core/dist/index.js
18
18
  import { readFileSync } from "node:fs";
@@ -595,6 +595,8 @@ function shouldSkipCacheForTemperature(targetConfig) {
595
595
  return false;
596
596
  }
597
597
  var execFileAsync = promisify(execFile);
598
+ var RESULTS_REPO_RESULTS_DIR = ".agentv/results";
599
+ var RESULTS_REPO_RUNS_DIR = `${RESULTS_REPO_RESULTS_DIR}/runs`;
598
600
  function sanitizeRepoSlug(repo) {
599
601
  return repo.trim().replace(/[^A-Za-z0-9._-]+/g, "-");
600
602
  }
@@ -614,7 +616,7 @@ function expandHome(p) {
614
616
  }
615
617
  function normalizeResultsConfig(config) {
616
618
  const repo = config.repo.trim();
617
- const resolvedPath = config.path ? expandHome(config.path.trim()) : path4.join(getAgentvHome(), "results", sanitizeRepoSlug(repo));
619
+ const resolvedPath = config.path ? expandHome(config.path.trim()) : path4.join(getAgentvDataDir(), "results", sanitizeRepoSlug(repo));
618
620
  return {
619
621
  mode: "github",
620
622
  repo,
@@ -630,7 +632,7 @@ function resolveResultsRepoUrl(repo) {
630
632
  return `https://github.com/${repo}.git`;
631
633
  }
632
634
  function getResultsRepoLocalPaths(repo) {
633
- const rootDir = path4.join(getAgentvHome(), "cache", "results-repo", sanitizeRepoSlug(repo));
635
+ const rootDir = path4.join(getAgentvDataDir(), "cache", "results-repo", sanitizeRepoSlug(repo));
634
636
  return {
635
637
  rootDir,
636
638
  repoDir: path4.join(rootDir, "repo"),
@@ -827,7 +829,7 @@ async function stageResultsArtifacts(params) {
827
829
  }
828
830
  function resolveResultsRepoRunsDir(config) {
829
831
  const normalized = normalizeResultsConfig(config);
830
- return path4.join(normalized.path, "runs");
832
+ return path4.join(normalized.path, RESULTS_REPO_RESULTS_DIR, "runs");
831
833
  }
832
834
  async function directorySizeBytes(targetPath) {
833
835
  const entry = await stat(targetPath);
@@ -890,7 +892,12 @@ async function directPushResults(params) {
890
892
  const repoDir = await ensureResultsRepoClone(normalized);
891
893
  const baseBranch = await resolveDefaultBranch(repoDir);
892
894
  await fetchResultsRepo(repoDir);
893
- const destinationDir = path4.join(repoDir, "runs", params.destinationPath);
895
+ const destinationDir = path4.join(
896
+ repoDir,
897
+ RESULTS_REPO_RESULTS_DIR,
898
+ "runs",
899
+ params.destinationPath
900
+ );
894
901
  await stageResultsArtifacts({
895
902
  repoDir,
896
903
  sourceDir: params.sourceDir,
@@ -1038,9 +1045,12 @@ function parseGitBatchBlobs(output) {
1038
1045
  return blobs;
1039
1046
  }
1040
1047
  async function listGitRuns(repoDir, ref = "origin/main") {
1041
- const { stdout: treeOut } = await runGit(["ls-tree", "-r", "--name-only", ref, "runs"], {
1042
- cwd: repoDir
1043
- });
1048
+ const { stdout: treeOut } = await runGit(
1049
+ ["ls-tree", "-r", "--name-only", ref, RESULTS_REPO_RUNS_DIR],
1050
+ {
1051
+ cwd: repoDir
1052
+ }
1053
+ );
1044
1054
  const benchmarkPaths = treeOut.split(/\r?\n/).map((line) => line.trim()).filter((line) => line.endsWith("/benchmark.json"));
1045
1055
  if (benchmarkPaths.length === 0) {
1046
1056
  return [];
@@ -1057,7 +1067,7 @@ async function listGitRuns(repoDir, ref = "origin/main") {
1057
1067
  const benchmarkPath = benchmarkPaths[index];
1058
1068
  const benchmark = JSON.parse(blob.content.toString("utf8"));
1059
1069
  const runDir = path4.posix.dirname(benchmarkPath);
1060
- const relativeRunPath = path4.posix.relative("runs", runDir);
1070
+ const relativeRunPath = path4.posix.relative(RESULTS_REPO_RUNS_DIR, runDir);
1061
1071
  const runId = buildGitRunId(relativeRunPath);
1062
1072
  const timestamp = benchmark.metadata?.timestamp?.trim() || path4.posix.basename(runDir);
1063
1073
  const targets = benchmark.metadata?.targets ?? [];
@@ -1083,7 +1093,7 @@ async function listGitRuns(repoDir, ref = "origin/main") {
1083
1093
  }
1084
1094
  async function materializeGitRun(repoDir, relativeRunPath, ref = "origin/main") {
1085
1095
  const normalizedRunPath = relativeRunPath.split(path4.sep).join("/");
1086
- const runTreePath = path4.posix.join("runs", normalizedRunPath);
1096
+ const runTreePath = path4.posix.join(RESULTS_REPO_RUNS_DIR, normalizedRunPath);
1087
1097
  const targetRunDir = path4.join(repoDir, ...runTreePath.split("/"));
1088
1098
  const { stdout: treeOut } = await runGit(["ls-tree", "-r", "--name-only", ref, runTreePath], {
1089
1099
  cwd: repoDir
@@ -2627,4 +2637,4 @@ export {
2627
2637
  TranscriptProvider,
2628
2638
  createAgentKernel
2629
2639
  };
2630
- //# sourceMappingURL=chunk-LOYPSIE7.js.map
2640
+ //# sourceMappingURL=chunk-LX5AK3P7.js.map