Add evaluation troubleshooting guide for AI agents - #440
Conversation
Add InvestigatingResults.md with: - How to find and download evaluation artifacts from workflow runs - Full results.json schema documentation - Common failure patterns (timeouts, empty output, variance, rubric issues, skill not activated) with diagnosis steps and fixes - Example analysis script for AI agents to parse results Link the doc from: - Reporter.cs: show a link in the PR comment when any skill fails - skill-validator README.md: Output section - CONTRIBUTING.md: CI evaluation section Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Note This PR is from a fork and modifies infrastructure files ( Changes to infrastructure typically need to be submitted from a branch in Please consider recreating this PR from an upstream branch. If you don't have push access to |
There was a problem hiding this comment.
Pull request overview
Adds a troubleshooting guide to help diagnose skill evaluation failures and surfaces it from the evaluation outputs/PR comment, so authors (and AI agents) have a documented path to interpret results.json and act on common failure modes.
Changes:
- Add a new
InvestigatingResults.mdguide documentingresults.json, scoring, and common failure patterns. - Link the guide from skill-validator docs (
README.md) and repo contributor docs (CONTRIBUTING.md). - Surface the guide link (and an AI copy/paste investigation prompt) in evaluation PR comments when failures occur.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
eng/skill-validator/src/Evaluate/Reporter.cs |
Adds a failure-only note in the generated markdown summary pointing to the troubleshooting guide. |
eng/skill-validator/README.md |
Links to the new troubleshooting guide from the output documentation. |
eng/skill-validator/InvestigatingResults.md |
New end-to-end guide for downloading artifacts and interpreting failures via results.json. |
CONTRIBUTING.md |
Adds a link to the troubleshooting guide from the CI evaluation section. |
.github/workflows/evaluation.yml |
Appends an AI-agent copy/paste investigation prompt to the consolidated PR comment when failures are detected. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| | Field | Description | | ||
| |-------|-------------| | ||
| | `model` | Model used for agent runs | | ||
| | `judgeModel` | Model used for judging | | ||
| | `timestamp` | When the run started | | ||
| | `verdicts[]` | Array of per-skill results | | ||
|
|
There was a problem hiding this comment.
The markdown tables in this guide start with || (e.g., || Field | Description |), which renders as an extra empty column in standard GitHub Markdown. Remove the extra leading | so the tables render correctly (and apply consistently to the other tables in this file).
| Each scenario contains three runs and their comparison: | ||
|
|
||
| | Field | Description | | ||
| |-------|-------------| | ||
| | `scenarioName` | Human-readable scenario name | | ||
| | `baseline` | Run without the skill | | ||
| | `skilledIsolated` | Run with only this skill loaded | | ||
| | `skilledPlugin` | Run with the full plugin loaded | |
There was a problem hiding this comment.
This section says each scenario contains three runs, but skilledPlugin is optional (only present when plugin runs are enabled). Consider rewording to "two runs (baseline + isolated) plus an optional plugin run" to match the actual results.json structure.
| Each scenario contains three runs and their comparison: | |
| | Field | Description | | |
| |-------|-------------| | |
| | `scenarioName` | Human-readable scenario name | | |
| | `baseline` | Run without the skill | | |
| | `skilledIsolated` | Run with only this skill loaded | | |
| | `skilledPlugin` | Run with the full plugin loaded | | |
| Each scenario includes two runs (baseline + isolated) plus an optional plugin run, and their comparison: | |
| | Field | Description | | |
| |-------|-------------| | |
| | `scenarioName` | Human-readable scenario name | | |
| | `baseline` | Run without the skill | | |
| | `skilledIsolated` | Run with only this skill loaded | | |
| | `skilledPlugin` | Run with the full plugin loaded (present only when plugin runs are enabled) | |
|
|
||
| bool anyFailure = verdicts.Any(v => !v.Passed); | ||
| if (anyFailure) | ||
| sb.AppendLine("\n> 📖 See [InvestigatingResults.md](https://github.com/dotnet/skills/blob/main/eng/skill-validator/InvestigatingResults.md) for how to diagnose failures — or use the copy-paste prompt below."); |
There was a problem hiding this comment.
This adds a hard-coded link to dotnet/skills/blob/main/... and mentions a "copy-paste prompt below". When the markdown summary is generated outside the PR-comment workflow (e.g., local runs, or other consumers of summary.md), there may be no prompt below; and the hard-coded repo/branch makes the link stale if the default branch or repository differs. Consider linking more robustly (e.g., a repo-relative path, or injecting repo+ref from the workflow) and rewording so it doesn’t assume the prompt is present.
| sb.AppendLine("\n> 📖 See [InvestigatingResults.md](https://github.com/dotnet/skills/blob/main/eng/skill-validator/InvestigatingResults.md) for how to diagnose failures — or use the copy-paste prompt below."); | |
| sb.AppendLine("\n> 📖 See [InvestigatingResults.md](/eng/skill-validator/InvestigatingResults.md) for how to diagnose failures. Additional debugging guidance may be provided by your workflow."); |
| echo "" | ||
| echo "> **To investigate failures**, paste this to your AI coding agent:" | ||
| echo ">" | ||
| echo "> _Download eval artifacts with \`gh run download ${RUN_ID} --repo ${{ github.repository }} --dir /tmp/eval-results\`, then fetch https://raw.githubusercontent.com/${{ github.repository }}/main/eng/skill-validator/InvestigatingResults.md and follow it to analyze the results.json files. Diagnose each failure, suggest fixes to the eval.yaml and skill content, and tell me what to fix first._" |
There was a problem hiding this comment.
The troubleshooting prompt fetches the guide from a hard-coded .../main/... URL. Using the repository’s default branch (or a specific ref/sha associated with the run) would make this more robust and avoid breaking if the default branch name changes.
| echo "> _Download eval artifacts with \`gh run download ${RUN_ID} --repo ${{ github.repository }} --dir /tmp/eval-results\`, then fetch https://raw.githubusercontent.com/${{ github.repository }}/main/eng/skill-validator/InvestigatingResults.md and follow it to analyze the results.json files. Diagnose each failure, suggest fixes to the eval.yaml and skill content, and tell me what to fix first._" | |
| echo "> _Download eval artifacts with \`gh run download ${RUN_ID} --repo ${{ github.repository }} --dir /tmp/eval-results\`, then fetch https://raw.githubusercontent.com/${{ github.repository }}/${{ github.sha }}/eng/skill-validator/InvestigatingResults.md and follow it to analyze the results.json files. Diagnose each failure, suggest fixes to the eval.yaml and skill content, and tell me what to fix first._" |
|
Superseded by #441 (same branch pushed to upstream so CI runs with correct permissions). Review feedback addressed there. |
Add evaluation troubleshooting guide for AI agents
Note
This PR was generated with Copilot assistance.
Problem
When skill evaluation produces failures, PR authors have no clear path to diagnose the cause. The eval results table shows scores and verdicts, but doesn't explain what went wrong or how to fix it. Investigating requires manually downloading artifacts from workflow logs, reverse-engineering the
results.jsonschema, and pattern-matching against undocumented failure modes.Solution
Add
eng/skill-validator/InvestigatingResults.md— a troubleshooting guide designed primarily for AI coding agents to read and follow. When any skill fails evaluation, the PR comment now includes a ready-to-use prompt that the PR author can copy-paste to their AI agent. The agent downloads the artifacts, reads the guide, analyzes the results, and suggests fixes.What's in the guide
results.jsonschema documentation — verdict, scenario, breakdown, and run metrics fields with descriptionsgh run downloadinstructions for artifact retrievalChanges
eng/skill-validator/InvestigatingResults.mdeng/skill-validator/README.mdCONTRIBUTING.mdeng/skill-validator/src/Evaluate/Reporter.cs.github/workflows/evaluation.ymlValidation
Tested the guide by launching 4 fresh AI agents (clean context, no prior analysis) against eval artifacts from 2 different PRs (PR #317 and PR #428). Across 19 failing scenarios: