# How to test whether harness edits lift your agent on legal tasks with harness2

Repo: [google-research/harness2](https://github.com/google-research/harness2) | Difficulty: Intermediate | Time: 1 hour | Basis: From the README

Run one LAB legal-work task with refinement, then judge and report, to see if edits beat the base harness.

**Who it is for:** Legal-tech engineer whose agent drafts antitrust or competition analysis and who wants evidence that prompt and tool edits help

**The problem:** You cannot tell if rewriting your agent's prompts and guardrails improves legal output without a repeatable before/after run.

**The outcome:** A judged and reported result for one LAB task, with the adopted harness and reflection notes saved under runs/.

## Steps

1. Install the benchmark: harness2-setup lab
2. Check prerequisites: harness2-check --bench lab
3. Refine one task: harness2 --bench lab --k 1 --mode parallel --only-domains antitrust-competition --max-tasks 1
4. Judge the result: harness2-judge --bench lab --k 1 --mode parallel
5. Read the summary: harness2-report --bench lab --k 1 --mode parallel

## Prompt to paste into your agent

```text
In google-research/harness2, run the LAB benchmark for one antitrust-competition task with --k 1 --mode parallel, then run harness2-judge and harness2-report with the same flags. Confirm judge and report used identical benchmark, k, mode and seed as the refinement run.
```

## Caveat

Judge and report must use the same benchmark, executor, subset, --k, --mode and seed as the refinement run, and model-backed runs cost real API money, so keep --max-tasks at 1.

Dual-use notice: only use this on software, sites and systems you own or are authorized to test.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/google-research-harness2/test-harness-refinement-on-legal-tasks/
