Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,8 @@ All notable changes to SkillEvaluator are documented in this file.
- `evaluate` and `tier3 evaluate` on a base install (without the `tier3` extra)
now say to install `skillevaluator[tier3]` instead of printing only
`Error: No module named 'harbor'`.
- Tier 3 benchmark headlines use the completed agent's quality verdict, matching
the Tier 3 status row even when another agent fails execution.
- Arms fully denied by a run budget are reported as not run instead of failed
empty Harbor jobs. Budget-partial runs remain incomplete without an execution
error when all admitted attempts succeed, including stop-on-pass runs. Reused
Expand Down
2 changes: 1 addition & 1 deletion src/skillevaluator/reporting/benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def render_all(self, results: list[ValidationResult]) -> str:
budget_reason = budget_incomplete_reason(budget)
if budget_reason:
tier3_callout = f"> **Tier 3: INCOMPLETE** — {budget_reason}"
elif self.report_scope == "tier3" and isinstance(run_verdict, str):
elif self.report_scope == "tier3" and completed is None and isinstance(run_verdict, str):
tier3_callout = f"> **Tier 3 completed-agent result: {run_verdict.upper()}**" + (
f" — {_publication_safe_inline(run_reason, private_labels)}" if run_reason else ""
)
Expand Down
33 changes: 33 additions & 0 deletions tests/reporting/test_tier3_scoped_reports.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,39 @@ def test_scoped_reports_show_completed_agent_and_signed_lift(baseline, lift):
assert assessment.status != "pass"


@pytest.mark.parametrize("peer_failed,quality_failed", [(True, True), (False, False)])
def test_benchmark_headline_matches_completed_agent_row(peer_failed, quality_failed):
result = result_with_completed_peer(peer_failed=peer_failed)
payload = result.metadata["agent_eval"]
if quality_failed:
payload["agents"]["opencode"]["required_checks"] = {
"with_skill": {"passed": 0, "scored": 1, "wrong_answer": 1, "security": 0}
}
assert payload["verdict"] == ("neutral" if peer_failed else "pass")
completed = completed_agent_result(payload)
assert completed["verdict"] == ("fail" if quality_failed else "pass")
benchmark = BenchmarkReporter(report_scope="tier3").render(result)
assert benchmark.startswith(f"> **Tier 3 completed-agent result: {completed['verdict'].upper()}**")
assert f"| Tier 3 | Live agent evaluation | **{completed['verdict'].upper()}** |" in benchmark
if quality_failed:
assert completed["reason"] in benchmark.splitlines()[0]
assert "Needs attention" in benchmark


@pytest.mark.parametrize("run_verdict", ["neutral", None])
def test_benchmark_headline_without_completed_agent_is_unchanged(run_verdict):
result = result_with_completed_peer()
payload = result.metadata["agent_eval"]
payload["agents"]["opencode"]["scored_attempts"] = 0
payload["verdict"] = run_verdict
assert completed_agent_result(payload) is None
benchmark = BenchmarkReporter(report_scope="tier3").render(result)
if run_verdict is None:
assert benchmark.startswith("> **Tier 3: No complete agent result**")
else:
assert benchmark.startswith("> **Tier 3 completed-agent result: NEUTRAL**")


def test_default_report_keeps_publication_gate_and_format():
result = result_with_completed_peer()
benchmark = BenchmarkReporter().render(result)
Expand Down
Loading