Retroactive Agent Runs
Without the harness
A new model ships on Friday. You want to re-score yesterday's 500,000 documents with it and compare against the old verdicts. The script you have re-reads the files from the bucket, re-decodes them, re-runs the embedding step the new judge needs, and re-scores everything. The base work you did yesterday is paid for again. With LLM API calls at fractions of a cent per call, a single re-run can cost thousands of dollars.
With DataChain
The expensive base work is already a saved dataset, and saved datasets are immutable. The retroactive run does not change dialog_verdicts; it produces a new dataset derived from it, carrying every existing column plus one new column for the new judge. The file references live in the parent dataset, so no bytes are re-downloaded; only the new judge call pays per row. Checkpoints make even the new column resumable mid-run.
dialog_verdicts is unchanged. dialog_verdicts_claude is a new derived dataset that carries the file references, the original verdict column, and the new claude_verdict column side by side. Lineage records that it depends on dialog_verdicts.
Both verdict columns live on the new dataset, so comparing them is one filter, not a join:
For an incremental run over only files added since the last save, delta=True skips processed rows automatically:
What this enables
- The model upgrade gets cheap. A new judge, a new embedding model, or a new prompt produces a new dataset derived from the prior one; only the new column pays per-row LLM cost. File reads and prior columns come for free from the parent.
- Prior runs stay intact. The original dataset is immutable. The retroactive run never overwrites it, so older experiments remain reproducible against the exact rows they were run on.
- Comparisons are first-class. Old and new columns sit side by side on the derived dataset; the diff is a filter, not a join across two ad-hoc tables.
See also
- Checkpoints: mid-run resume
- Delta processing: incremental updates over new files
- Dataset DB: why prior work is recoverable instead of recomputed