@agentv/core 4.31.3-next.1 → 4.31.4-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.
package/dist/index.d.cts CHANGED
@@ -4272,7 +4272,7 @@ declare function getTraceStateRoot(): string;
4272
4272
  declare function getWorkspacePoolRoot(): string;
4273
4273
 
4274
4274
  /**
4275
- * Project registry for AgentV Studio multi-project support.
4275
+ * Project registry for AgentV Dashboard multi-project support.
4276
4276
  *
4277
4277
  * A Project = any directory containing a `.agentv/` folder. Projects hold
4278
4278
  * eval runs, and (incrementally) traces, spans, and other telemetry —
@@ -4280,7 +4280,7 @@ declare function getWorkspacePoolRoot(): string;
4280
4280
  * Braintrust, W&B Weave, and LangSmith.
4281
4281
  *
4282
4282
  * The registry lives at `~/.agentv/projects.yaml` and is the single source
4283
- * of truth for which projects Studio shows. Studio re-reads the file on every
4283
+ * of truth for which projects Dashboard shows. Dashboard re-reads the file on every
4284
4284
  * `/api/projects` request, so edits (direct, via POST /api/projects, via
4285
4285
  * the CLI's --add/--remove, or via a Kubernetes ConfigMap mount) are reflected
4286
4286
  * without restarting `agentv serve`.
@@ -4302,7 +4302,7 @@ declare function getWorkspacePoolRoot(): string;
4302
4302
  *
4303
4303
  * Concurrency: the registry assumes a single writer. All mutating calls
4304
4304
  * (add/remove/touchProject) do read-modify-write on projects.yaml
4305
- * without a lock. Studio's HTTP handlers are serialized by Node's
4305
+ * without a lock. Dashboard's HTTP handlers are serialized by Node's
4306
4306
  * single-threaded event loop, which satisfies the 24/7 deployment case.
4307
4307
  * Run only one `agentv` process against a given home at a time.
4308
4308
  *
@@ -4362,15 +4362,15 @@ declare function touchProject(projectId: string): void;
4362
4362
  * Scan a directory tree (up to maxDepth levels) for directories containing `.agentv/`.
4363
4363
  * Returns absolute paths of discovered project directories, sorted for
4364
4364
  * deterministic iteration. This is a one-shot helper for bulk registration;
4365
- * Studio does not scan at request time.
4365
+ * Dashboard does not scan at request time.
4366
4366
  */
4367
4367
  declare function discoverProjects(rootDir: string, maxDepth?: number): string[];
4368
4368
 
4369
4369
  /**
4370
4370
  * Project sync — pulls remote git repos to the local path declared in the
4371
- * project registry before Studio/eval startup.
4371
+ * project registry before Dashboard/eval startup.
4372
4372
  *
4373
- * Sync is oneshot only, triggered by the Studio UI "Sync" button or the
4373
+ * Sync is oneshot only, triggered by the Dashboard UI "Sync" button or the
4374
4374
  * `agentv project sync` CLI command. There is no daemon or continuous mode.
4375
4375
  *
4376
4376
  * First run — git clone --depth 1 --filter=blob:none --branch <ref> <url> <path>
@@ -4624,7 +4624,7 @@ declare function runBeforeSessionHook(command: string): void;
4624
4624
  * Tracks long-lived child processes spawned by AgentV providers so that a
4625
4625
  * top-level signal handler can kill them all on Ctrl+C / SIGTERM.
4626
4626
  *
4627
- * Why this exists: when the CLI receives SIGTERM (e.g. from Studio's Stop
4627
+ * Why this exists: when the CLI receives SIGTERM (e.g. from Dashboard's Stop
4628
4628
  * button), Node exits the parent process but does NOT propagate the signal
4629
4629
  * to grandchildren. Without tracking, the spawned `claude`, `codex`, `pi`,
4630
4630
  * `copilot` subprocesses linger as orphans. The CLI's signal handler walks
package/dist/index.d.ts CHANGED
@@ -4272,7 +4272,7 @@ declare function getTraceStateRoot(): string;
4272
4272
  declare function getWorkspacePoolRoot(): string;
4273
4273
 
4274
4274
  /**
4275
- * Project registry for AgentV Studio multi-project support.
4275
+ * Project registry for AgentV Dashboard multi-project support.
4276
4276
  *
4277
4277
  * A Project = any directory containing a `.agentv/` folder. Projects hold
4278
4278
  * eval runs, and (incrementally) traces, spans, and other telemetry —
@@ -4280,7 +4280,7 @@ declare function getWorkspacePoolRoot(): string;
4280
4280
  * Braintrust, W&B Weave, and LangSmith.
4281
4281
  *
4282
4282
  * The registry lives at `~/.agentv/projects.yaml` and is the single source
4283
- * of truth for which projects Studio shows. Studio re-reads the file on every
4283
+ * of truth for which projects Dashboard shows. Dashboard re-reads the file on every
4284
4284
  * `/api/projects` request, so edits (direct, via POST /api/projects, via
4285
4285
  * the CLI's --add/--remove, or via a Kubernetes ConfigMap mount) are reflected
4286
4286
  * without restarting `agentv serve`.
@@ -4302,7 +4302,7 @@ declare function getWorkspacePoolRoot(): string;
4302
4302
  *
4303
4303
  * Concurrency: the registry assumes a single writer. All mutating calls
4304
4304
  * (add/remove/touchProject) do read-modify-write on projects.yaml
4305
- * without a lock. Studio's HTTP handlers are serialized by Node's
4305
+ * without a lock. Dashboard's HTTP handlers are serialized by Node's
4306
4306
  * single-threaded event loop, which satisfies the 24/7 deployment case.
4307
4307
  * Run only one `agentv` process against a given home at a time.
4308
4308
  *
@@ -4362,15 +4362,15 @@ declare function touchProject(projectId: string): void;
4362
4362
  * Scan a directory tree (up to maxDepth levels) for directories containing `.agentv/`.
4363
4363
  * Returns absolute paths of discovered project directories, sorted for
4364
4364
  * deterministic iteration. This is a one-shot helper for bulk registration;
4365
- * Studio does not scan at request time.
4365
+ * Dashboard does not scan at request time.
4366
4366
  */
4367
4367
  declare function discoverProjects(rootDir: string, maxDepth?: number): string[];
4368
4368
 
4369
4369
  /**
4370
4370
  * Project sync — pulls remote git repos to the local path declared in the
4371
- * project registry before Studio/eval startup.
4371
+ * project registry before Dashboard/eval startup.
4372
4372
  *
4373
- * Sync is oneshot only, triggered by the Studio UI "Sync" button or the
4373
+ * Sync is oneshot only, triggered by the Dashboard UI "Sync" button or the
4374
4374
  * `agentv project sync` CLI command. There is no daemon or continuous mode.
4375
4375
  *
4376
4376
  * First run — git clone --depth 1 --filter=blob:none --branch <ref> <url> <path>
@@ -4624,7 +4624,7 @@ declare function runBeforeSessionHook(command: string): void;
4624
4624
  * Tracks long-lived child processes spawned by AgentV providers so that a
4625
4625
  * top-level signal handler can kill them all on Ctrl+C / SIGTERM.
4626
4626
  *
4627
- * Why this exists: when the CLI receives SIGTERM (e.g. from Studio's Stop
4627
+ * Why this exists: when the CLI receives SIGTERM (e.g. from Dashboard's Stop
4628
4628
  * button), Node exits the parent process but does NOT propagate the signal
4629
4629
  * to grandchildren. Without tracking, the spawned `claude`, `codex`, `pi`,
4630
4630
  * `copilot` subprocesses linger as orphans. The CLI's signal handler walks
package/dist/index.js CHANGED
@@ -132,7 +132,7 @@ import {
132
132
  tokensPerTool,
133
133
  trackChild,
134
134
  trackedChildCount
135
- } from "./chunk-A27NE3R7.js";
135
+ } from "./chunk-575K7WRM.js";
136
136
  import {
137
137
  COMMON_TARGET_SETTINGS,
138
138
  TEST_MESSAGE_ROLES,
@@ -735,6 +735,8 @@ import os from "node:os";
735
735
  import path4 from "node:path";
736
736
  import { promisify } from "node:util";
737
737
  var execFileAsync = promisify(execFile);
738
+ var RESULTS_REPO_RESULTS_DIR = ".agentv/results";
739
+ var RESULTS_REPO_RUNS_DIR = `${RESULTS_REPO_RESULTS_DIR}/runs`;
738
740
  function sanitizeRepoSlug(repo) {
739
741
  return repo.trim().replace(/[^A-Za-z0-9._-]+/g, "-");
740
742
  }
@@ -967,7 +969,7 @@ async function stageResultsArtifacts(params) {
967
969
  }
968
970
  function resolveResultsRepoRunsDir(config) {
969
971
  const normalized = normalizeResultsConfig(config);
970
- return path4.join(normalized.path, "runs");
972
+ return path4.join(normalized.path, RESULTS_REPO_RESULTS_DIR, "runs");
971
973
  }
972
974
  async function directorySizeBytes(targetPath) {
973
975
  const entry = await stat(targetPath);
@@ -1030,7 +1032,12 @@ async function directPushResults(params) {
1030
1032
  const repoDir = await ensureResultsRepoClone(normalized);
1031
1033
  const baseBranch = await resolveDefaultBranch(repoDir);
1032
1034
  await fetchResultsRepo(repoDir);
1033
- const destinationDir = path4.join(repoDir, "runs", params.destinationPath);
1035
+ const destinationDir = path4.join(
1036
+ repoDir,
1037
+ RESULTS_REPO_RESULTS_DIR,
1038
+ "runs",
1039
+ params.destinationPath
1040
+ );
1034
1041
  await stageResultsArtifacts({
1035
1042
  repoDir,
1036
1043
  sourceDir: params.sourceDir,
@@ -1178,9 +1185,12 @@ function parseGitBatchBlobs(output) {
1178
1185
  return blobs;
1179
1186
  }
1180
1187
  async function listGitRuns(repoDir, ref = "origin/main") {
1181
- const { stdout: treeOut } = await runGit(["ls-tree", "-r", "--name-only", ref, "runs"], {
1182
- cwd: repoDir
1183
- });
1188
+ const { stdout: treeOut } = await runGit(
1189
+ ["ls-tree", "-r", "--name-only", ref, RESULTS_REPO_RUNS_DIR],
1190
+ {
1191
+ cwd: repoDir
1192
+ }
1193
+ );
1184
1194
  const benchmarkPaths = treeOut.split(/\r?\n/).map((line) => line.trim()).filter((line) => line.endsWith("/benchmark.json"));
1185
1195
  if (benchmarkPaths.length === 0) {
1186
1196
  return [];
@@ -1197,7 +1207,7 @@ async function listGitRuns(repoDir, ref = "origin/main") {
1197
1207
  const benchmarkPath = benchmarkPaths[index];
1198
1208
  const benchmark = JSON.parse(blob.content.toString("utf8"));
1199
1209
  const runDir = path4.posix.dirname(benchmarkPath);
1200
- const relativeRunPath = path4.posix.relative("runs", runDir);
1210
+ const relativeRunPath = path4.posix.relative(RESULTS_REPO_RUNS_DIR, runDir);
1201
1211
  const runId = buildGitRunId(relativeRunPath);
1202
1212
  const timestamp = benchmark.metadata?.timestamp?.trim() || path4.posix.basename(runDir);
1203
1213
  const targets = benchmark.metadata?.targets ?? [];
@@ -1223,7 +1233,7 @@ async function listGitRuns(repoDir, ref = "origin/main") {
1223
1233
  }
1224
1234
  async function materializeGitRun(repoDir, relativeRunPath, ref = "origin/main") {
1225
1235
  const normalizedRunPath = relativeRunPath.split(path4.sep).join("/");
1226
- const runTreePath = path4.posix.join("runs", normalizedRunPath);
1236
+ const runTreePath = path4.posix.join(RESULTS_REPO_RUNS_DIR, normalizedRunPath);
1227
1237
  const targetRunDir = path4.join(repoDir, ...runTreePath.split("/"));
1228
1238
  const { stdout: treeOut } = await runGit(["ls-tree", "-r", "--name-only", ref, runTreePath], {
1229
1239
  cwd: repoDir