Eval Capstone: A Coding-Agent Eval Harness
Build an eval harness for the coding agent.
What You Will Learn
- Build an eval harness for the coding agent.
- Define agent-specific tasks.
- Score agent output.
- Track regressions.
- Automate the harness.
Why This Matters
This capstone applies PR-29 to PR-35 into one deliverable: an eval harness that continuously tests the coding agent.
Concept Explained
An agent eval harness: define tasks (issues with acceptance criteria), delegate to agent, score the PR, track over time.
How It Works
Define 10–20 agent-eligible tasks. Each has acceptance criteria. Delegate to agent. Score PR: criteria met? Tests pass? Code quality? Track scores over time.
Step-by-Step Tutorial
1. Define tasks
10–20 agent-eligible issues. Each with acceptance criteria.2. Delegate to agent
Run via agent.3. Score PRs
Criteria met? Tests pass? Quality? (Use rubric from PR-31.)4. Track
Scores over time. Alert on regressions.5. Automate
Scripted: delegate, wait, score, report.Real-World Example
A team built an agent eval harness. 15 tasks. Baseline: 80% pass. After model upgrade: 85%. After prompt template change: 70% — regression caught. Rolled back template.
Example Prompts / Commands / Code
"""[Task definitions (10-20)]
|
v
[Delegation script] -> [Coding agent] -> [PR opened]
|
v
[Scoring script]
- Criteria met? (automated check)
- Tests pass? (run CI)
- Code quality? (LLM-as-judge)
|
v
[Score report] -> [Dashboard]
|
v
[Alerts on regression]
Run: weekly, or before/after model upgrades
"""
"""Task: Add null check to parseDate
Issue:
- Function: src/date.ts:parseDate
- Bug: throws TypeError on null
- Fix: add null check, throw descriptive error
Acceptance criteria:
- [ ] parseDate(null) throws TypeError('input is required')
- [ ] parseDate('2024-01-15') returns Date (unchanged)
- [ ] parseDate('invalid') returns null (unchanged)
- [ ] Test added in tests/date.test.ts
Scoring:
- Criteria met (0-4): automated check
- Tests pass (0/1): run CI
- Code quality (0-5): LLM-as-judge
- Total: 0-10
Pass: total >= 8
Fail: total < 8
"""
Common Mistakes
- Tasks not agent-eligible — agent flails.
- No acceptance criteria — can't score.
- Not automating scoring — manual burden.
- Not tracking over time — regressions slip in.
Best Practices
- Define 10–20 agent-eligible tasks.
- Each with specific acceptance criteria.
- Automate scoring (criteria + tests + LLM-as-judge).
- Track scores over time.
- Alert on regressions; run before/after upgrades.
Troubleshooting
| Problem | How to Fix |
|---|---|
| Agent produces variable results | Run each task 3 times; average score. Reduces noise. |
| LLM-as-judge unreliable | Calibrate against human scoring. Refine judge prompt. |
Practical Exercise
Your Turn
Build an agent eval harness with 5 tasks. Run. Score. Track.
Professional Challenge
Run harness weekly for a quarter. Track agent quality over time. Identify trends.
Key Takeaways
- Agent eval harness: define tasks, delegate, score, track.
- 10–20 agent-eligible tasks with criteria.
- Automate scoring.
- Track over time.
- Alert on regressions.
Frequently Asked Questions
How often to run?
How many tasks?
Further Reading
Official References
SEO Metadata
SEO title: Eval Capstone: A Coding-Agent Eval Harness
Meta description: Build an eval harness for the coding agent.
Primary keyword: eval capstone
Secondary keywords: eval capstone: a coding-agent eval harness
Search intent: Informational
URL slug: /eval-capstone-coding-agent-eval-harness
Categories: AI Tools, GitHub Copilot
Tags: GitHub Copilot, Professional, Capstone, Evaluation, Coding Agent, Harness, IMCSEIAN, Tutorial, IMCSEIAN
Featured image concept: IMCSEIAN lesson card for Eval Capstone: A Coding-Agent Eval Harness
Comments
Comments
Post a Comment