Skip to content

Commit 523bedc

Browse files
committed
docs(results): document WIP checkpoints
1 parent a11c50b commit 523bedc

5 files changed

Lines changed: 118 additions & 5 deletions

File tree

apps/web/src/content/docs/docs/evaluation/running-evals.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ agentv eval evals/my-eval.yaml --rerun-failed
301301
agentv eval evals/my-eval.yaml --retry-errors .agentv/results/runs/<timestamp>/index.jsonl
302302
```
303303

304-
After any failing run, the CLI prints the exact `--rerun-failed` command for the run dir that just completed — copy/paste it.
304+
After any failing run, the CLI prints the exact `--rerun-failed` command for the run dir that just completed — copy/paste it. If the process or pod disappeared before you could access the local run directory and results auto-push was enabled, recover the partial run from [WIP checkpoints](/docs/tools/wip-checkpoints/) first, then use the same `--resume` flow.
305305

306306
The interactive wizard (`agentv eval` with no arguments) remembers the last run's artifact directory and surfaces a **"Resume last run"** entry in the main menu when one exists.
307307

apps/web/src/content/docs/docs/index.mdx

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,26 @@ AgentV is a CLI-first AI agent evaluation framework. It evaluates your agents lo
4242
- **Rubrics** — Structured criteria with weights for grading
4343
- **Results** — JSONL output with scores, reasoning, and execution traces
4444

45+
## AI agent navigation map
46+
47+
Use this topic map when you are an AI agent trying to decide which primitive or workflow to compose next:
48+
49+
| Goal | Start here | Why |
50+
| --- | --- | --- |
51+
| Create a first eval | [Quickstart](/docs/getting-started/quickstart/)[Eval files](/docs/evaluation/eval-files/) | Defines the smallest runnable YAML shape before adding advanced fields. |
52+
| Run or resume evals | [Running evals](/docs/evaluation/running-evals/)[WIP checkpoints](/docs/tools/wip-checkpoints/) | Covers `agentv eval`, concurrency, `--resume`, `--rerun-failed`, and remote partial-run recovery. |
53+
| Choose graders | [Rubrics](/docs/evaluation/rubrics/)[Code graders](/docs/graders/code-graders/)[LLM graders](/docs/graders/llm-graders/) | Keeps deterministic checks, rubric scoring, and LLM judgment separate. |
54+
| Evaluate tool use or agents | [Tool trajectory](/docs/graders/tool-trajectory/)[Coding agents](/docs/targets/coding-agents/)[CLI provider](/docs/targets/cli-provider/) | Shows how targets, transcripts, and tool-call assertions compose. |
55+
| Share and inspect results | [Results](/docs/tools/results/)[Dashboard](/docs/tools/dashboard/) | Explains local artifacts, reports, remote result repositories, and Dashboard review flows. |
56+
| Compare runs | [Compare](/docs/tools/compare/)[Dashboard Analytics](/docs/tools/dashboard/#analytics) | Use CLI metrics for automation and Dashboard analytics for interactive inspection. |
57+
| Govern or improve an agent workflow | [Agent eval layers](/docs/guides/agent-eval-layers/)[Skill improvement workflow](/docs/guides/skill-improvement-workflow/)[Enterprise governance](/docs/guides/enterprise-governance/) | Moves from primitive eval design to iterative agent improvement and governance checks. |
58+
59+
### Navigation strategy recommendation
60+
61+
Keep the public Astro/Starlight docs as AgentV's canonical navigation layer, and add lightweight topic-map sections like the one above when agents need a faster path through related pages. This borrows the useful LLM Wiki convention of one-line index entries with dense cross-links, without introducing a separate wiki, custom schema, or runtime navigation code.
62+
63+
That is the smallest fit for the current docs: Starlight already provides the sidebar, URLs, search, and link validation, while the source MDX files remain reviewable in ordinary PRs. A full LLM Wiki-style knowledge graph would add duplicate source-of-truth and maintenance overhead before AgentV has enough public docs or contradictory source material to justify provenance tracking. Revisit a richer topic-map or wiki only if a docs section grows beyond a scannable page index, or if multiple sources need explicit confidence/contradiction metadata.
64+
4565
## Features
4666

4767
- **Multi-objective scoring**: Correctness, latency, cost, safety in one run

apps/web/src/content/docs/docs/tools/dashboard.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ IDs are derived from the directory name (e.g., `/home/user/repos/my-evals` becom
245245

246246
## Remote Results
247247

248-
Dashboard can display runs pushed to a remote git repository by other machines or CI alongside your local runs. Each run in the list carries a source badge: **local** (green) or **remote** (amber).
248+
Dashboard can display runs pushed to a remote git repository by other machines or CI alongside your local runs. Each run in the list carries a source badge: **local** (green) or **remote** (amber). For in-progress eval durability before final publish, AgentV writes [WIP checkpoints](/docs/tools/wip-checkpoints/) to `agentv/inflight/...` branches; Dashboard lists them only after they are recovered locally or published to the normal results branch.
249249

250250
### Configuration
251251

@@ -334,7 +334,7 @@ Each run writes to a unique timestamped directory, so concurrent pushes from mul
334334

335335
Existing runs already present under `.agentv/results/runs/` stay exactly where they are and continue to appear in Dashboard as **local** runs.
336336

337-
Adding a `results` block does **not** backfill those historical runs into the remote repo automatically. Auto-push only affects runs created after the remote results repo is configured.
337+
Adding a `results` block does **not** backfill those historical runs into the remote repo automatically. Auto-push only affects runs created after the remote results repo is configured. The same auto-push setting also enables best-effort WIP checkpoints for in-progress `agentv eval` runs.
338338

339339
If you want older local-only runs in the remote repo, rerun them or copy the run directories into the managed clone manually before syncing the project.
340340

apps/web/src/content/docs/docs/tools/results.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import resultsReportDetails from '../../../../assets/screenshots/results-report-
1111

1212
The `results` command family works on existing local AgentV run workspaces and `index.jsonl` manifests. Use it after an eval run to inspect failures, validate manifests, export artifact layouts, combine/delete local run workspaces, or generate a shareable HTML report.
1313

14-
Remote result repository exchange is intentionally not part of `agentv results`. New eval runs can auto-export to a configured results repo when `auto_push: true`; manual remote status and sync are Dashboard/API workflows. See [Dashboard Remote Results](/docs/tools/dashboard/#remote-results) for configuration and sync behavior.
14+
Remote result repository exchange is intentionally not part of `agentv results`. New eval runs can auto-export to a configured results repo when `auto_push: true`; manual remote status and sync are Dashboard/API workflows. See [Dashboard Remote Results](/docs/tools/dashboard/#remote-results) for configuration and sync behavior, and [WIP checkpoints](/docs/tools/wip-checkpoints/) for recovering in-progress runs before final publish.
1515

1616
## Subcommands
1717

@@ -90,7 +90,7 @@ The CLI contract is deliberately narrow: `agentv results` manages local result a
9090

9191
Use these supported remote workflows instead:
9292

93-
- **Automatic publishing:** configure `projects[].results.sync.auto_push: true`; new `agentv eval` and `agentv pipeline bench` runs push their artifacts after the run completes. Add `projects[].results.branch` when the results repo stores artifacts on a non-default branch.
93+
- **Automatic publishing:** configure `projects[].results.sync.auto_push: true`; new `agentv eval` and `agentv pipeline bench` runs push their artifacts after the run completes. Add `projects[].results.branch` when the results repo stores artifacts on a non-default branch. While an eval is still running, [WIP checkpoints](/docs/tools/wip-checkpoints/) can keep partial run output durable on `agentv/inflight/...` branches.
9494
- **Manual Dashboard sync:** run `agentv dashboard`, open the project, and use **Sync Project**.
9595
- **Manual API sync:** while Dashboard is running, call `GET /api/projects/:projectId/remote/status` or `POST /api/projects/:projectId/remote/sync` for project-scoped automation. Single-project sessions also expose `GET /api/remote/status` and `POST /api/remote/sync`.
9696
- **Git escape hatch:** for advanced recovery, inspect or repair the configured `projects[].results.path` clone with `git` directly, then sync again.
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
title: WIP checkpoints
3+
description: Recover in-progress eval runs from git-backed results repositories.
4+
sidebar:
5+
order: 7
6+
---
7+
8+
WIP checkpoints are best-effort snapshots of an eval run while it is still executing. They are designed for long-running evals in CI, pods, or remote agents where losing the process would otherwise lose the completed test rows that were already written locally.
9+
10+
They are **not** a second results mode. They reuse the existing run workspace format and the configured git-backed results repository.
11+
12+
## When checkpoints run
13+
14+
WIP checkpoints are active only when AgentV can resolve a results repo configuration with auto-push enabled:
15+
16+
- In a registered project: `projects[].results.sync.auto_push: true` in `$AGENTV_HOME/config.yaml`.
17+
- In the top-level fallback config: `results.auto_push: true`.
18+
19+
If no results repo is configured, or auto-push is disabled, `agentv eval` still writes the local run workspace but does not create WIP branches.
20+
21+
## What gets written
22+
23+
| Location | Path or ref | What it contains |
24+
| --- | --- | --- |
25+
| Local project | `.agentv/results/runs/<experiment>/<run-id>/benchmark.json` | A run-start stub with `metadata.planned_test_count` and the eval file path when known. This lets Dashboard recognize incomplete local runs as resumable. |
26+
| Local project | `.agentv/results/runs/<experiment>/<run-id>/index.jsonl` | Result rows appended as test cases finish. Rows use the normal snake_case result JSONL format. |
27+
| Results repo remote | `agentv/inflight/<hostname>/<run-dir-basename>` | A forced-updated branch containing the checkpointed run under `.agentv/results/runs/<same-relative-run-path>/`. |
28+
| Results repo storage branch | Configured `results.branch`, or the repo default branch | The final published run after `agentv eval` completes and the normal auto-export succeeds. |
29+
30+
The WIP branch name is derived from the current host and the run directory basename. Non-branch-safe characters are replaced with `-`; the host component is capped at 40 characters and the run component at 60 characters.
31+
32+
## Lifecycle
33+
34+
1. **Run start** — AgentV creates the local run directory and writes the initial `benchmark.json` stub. If auto-push is enabled, it creates a temporary git worktree for a branch named `agentv/inflight/<hostname>/<run-dir-basename>`, based on the configured results storage branch when `results.branch` is set.
35+
2. **While running** — about every 30 seconds, AgentV copies the current run directory into the WIP worktree, amends a single checkpoint commit, and force-pushes the WIP branch. If nothing changed, it skips the push.
36+
3. **Successful completion** — AgentV publishes the completed run to the normal results branch. After that publish is confirmed as `published` or `already_published`, it deletes the remote WIP branch.
37+
4. **Failure, interrupt, or final export failure** — AgentV stops the checkpoint loop and removes the temporary local worktree, but leaves the remote WIP branch intact for recovery.
38+
39+
Checkpoint failures are warnings only. They never fail the eval run.
40+
41+
## Recover from a WIP branch
42+
43+
Use git to retrieve the WIP branch, copy the run workspace back into the eval project, then resume the run with the normal `--resume` flow.
44+
45+
```bash
46+
# 1. Clone or enter the configured results repo.
47+
git clone <results-repo-url> /tmp/agentv-results-recovery
48+
cd /tmp/agentv-results-recovery
49+
50+
# 2. Find WIP branches.
51+
git fetch origin --prune
52+
git branch -r --list 'origin/agentv/inflight/*'
53+
54+
# 3. Check out the branch for the interrupted run.
55+
git switch --detach origin/agentv/inflight/<hostname>/<run-dir-basename>
56+
57+
# 4. Inspect the checkpointed run path.
58+
find .agentv/results/runs -name benchmark.json
59+
60+
# 5. Copy the run tree into the eval project, preserving paths under runs/.
61+
PROJECT=/path/to/eval-project
62+
mkdir -p "$PROJECT/.agentv/results/runs"
63+
rsync -a .agentv/results/runs/ "$PROJECT/.agentv/results/runs/"
64+
65+
# 6. Resume from the recovered run directory.
66+
cd "$PROJECT"
67+
agentv eval <eval-file> --output .agentv/results/runs/<experiment>/<run-id> --resume
68+
```
69+
70+
If the recovered `benchmark.json` contains `metadata.eval_file`, use that as `<eval-file>`. If the run lives directly under `.agentv/results/runs/<run-id>/` instead of an experiment directory, pass that path to `--output`.
71+
72+
After the resumed run publishes successfully, AgentV cleans up any WIP branch it creates for the resumed run. Delete the original orphaned branch manually when you no longer need it:
73+
74+
```bash
75+
git push origin --delete agentv/inflight/<hostname>/<run-dir-basename>
76+
```
77+
78+
## Dashboard and `results` surfaces
79+
80+
- **Dashboard local runs:** an interrupted local run can show the one-click **Resume run** and **Rerun failed** actions when `benchmark.json` has `metadata.planned_test_count` greater than the number of result rows, or when any row has `execution_status: execution_error`.
81+
- **Dashboard remote runs:** normal remote listing reads the configured results storage branch. It does not list `agentv/inflight/...` WIP branches. Recover the checkpoint into the project-local run directory first, or wait for the final publish branch to receive a completed run.
82+
- **`agentv results` CLI:** the command family manages local run workspaces and reports. It does not have a WIP branch subcommand; use git for remote checkpoint inspection and cleanup.
83+
84+
## Operational caveats
85+
86+
- The first remote checkpoint happens on the periodic interval, so a process that dies immediately after startup may only have the local `benchmark.json` stub.
87+
- The WIP branch is force-pushed and keeps one snapshot commit. Do not treat it as an audit log.
88+
- Checkpoint contents can include prompts, outputs, grader evidence, traces, and generated task bundles. Protect the results repo like any other eval artifact store.
89+
- Authentication and branch permissions are the same as normal results auto-push. If git or GitHub authentication is missing, AgentV warns and keeps evaluating locally.
90+
- If `results.branch` is configured, create that remote storage branch before running evals. WIP worktrees are based on it.
91+
- Failed or interrupted runs intentionally leave WIP branches behind. Periodically delete old `agentv/inflight/...` branches once recovered or obsolete.
92+
93+
See also: [Resume an Interrupted Run](/docs/evaluation/running-evals/#resume-an-interrupted-run), [Results](/docs/tools/results/), and [Dashboard Remote Results](/docs/tools/dashboard/#remote-results).

0 commit comments

Comments
 (0)