Skip to content

fix: target dependency coverage and Tier 3 result integrity - #196

Merged
rng1995 merged 13 commits into
mainfrom
feat/christopherk/tier-integrity
Oct 16, 2026
Merged

rng1995 merged 13 commits into
mainfrom
feat/christopherk/tier-integrity

Conversation

@chrisknvidia

@chrisknvidia chrisknvidia commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Closes #195.

Tier 1 pyproject audits inspect the evaluator environment, and Tier 3 can penalize correct negative cases for not identifying a skill. This change makes target coverage and criterion applicability explicit and separates measured resources from routing/tool-productivity efficiency.

  • Tier 1: audit static PEP 621 target pins, including optional groups, without installing packages or executing target build scripts. Unsupported/unresolved declarations and missing or invalid scanner evidence are incomplete. Preserve per-target requested and actually audited inventories through validator aggregation, JSON and HTML exports. Coverage is direct declarations on the scanner platform; transitive dependencies require a resolved requirements file.
  • Tier 1: include .mdc rules/workflows in PII scans.
  • Tier 3: exclude SKILL_IDENTIFIED when should_trigger is false or no expected skill is declared. Derive negative-case accuracy from the other four verdicts and retain its exclusion/scoring policy. Preserve the positive-case contract and task/evidence literals.
  • Tier 3/reporting: show agent prompt+completion tokens and measured agent execution seconds independently of efficiency scoring. Deltas require complete successful arms, complete telemetry and matching case counts. Unknown data stays null/N/A; optional timing does not degrade score-evidence coverage.

The positive-case arithmetic changes in #190 and general publication/skipped-report work in #77 remain separate.

Verification

  • Familiar with contributing guidelines; focused regressions added
  • Updated documentation, dependency notices and CHANGELOG.md
  • Full regression run after primary fixes: 11,300 passed, 19 skipped; final advisory hardening passed 72 focused dependency/security tests. A later full run had 11,304 passes and one 0.1-second timeout-diagnostic test failure; that test passed focused rerun
  • make lint; make build; pinned fern check (0 errors; 1 warning: authenticated redirects check skipped); base-only wheel installation and real keyless PII command
  • Real pip-audit/advisory-service and CLI/JSON/HTML checks: vulnerable target, fixed clean target, unresolved declarations and unavailable package version evidence
  • Real .mdc direct scans and combined rules/workflow validation, with positive and clean controls
  • Live host and standalone-verifier inference: correct negative answer scores 1.0 with the excluded criterion
  • Real local Harbor/OpenCode evaluation: four successful trials, positive/negative cases with and without the skill; actual counters reach canonical JSON and rendered HTML
  • Successful real one-case --skip-baseline run: numeric skill-arm resources, null baseline totals/deltas
  • Browser inspection of resource table: values match JSON; no page errors
  • Review Guru/Test GURU author inspection across source, output contracts and real execution; findings fixed and regressions rerun
  • Final export/validator/reporting suite: 315 passed; actual clean/incomplete CLI JSON and HTML retain per-target inventories
  • 17/17 final-head CI checks passed on 8073f932382658699a585a4a776e20b94d161e48, including full Python 3.12/3.13 suites, packaging/platform checks, CodeQL, Gitleaks and dependency review
  • Dedicated code-review/Bugbot and Security Review passes
  • No credentials, private datasets or proprietary benchmark content added

Review findings addressed

Package canonicalization, optional timing-load isolation, evidence-preserving rubric changes, negative-case retry fixture correctness, malformed advisory/counter handling, and requested-versus-completed audit coverage were checked and corrected. The full suite initially exposed the timing-loader regression and an outdated negative-case mock; three timing-sensitive failures passed focused rerun and the subsequent full run without unrelated changes.

Real-run observations and limits

The completed paired local run used 41,963 tokens with the skill versus 29,684 without (+12,279), and 20.99 versus 20.73 seconds of agent execution (+0.26). These observations are separate from efficiency scores and are not a statistical savings claim.

The Docker run encountered agent-installation timeouts before inference; remaining work in that run was interrupted, so no successful complete Docker E2E is claimed. A separate local --skip-baseline run encountered an agent timeout and correctly retained unavailable resource totals/deltas for the incomplete arm. Missing telemetry, absent baselines, unequal case counts, unsupported multi-step timing and malformed artifacts are covered by regressions. Credentialed testing uses one OpenAI-compatible model/provider path; other provider production paths are not claimed as verified.

Review gate

Retain draft status until the required review gate is resolved. Dedicated bot reviewers are unavailable in the current authoring session; ordinary author inspection, static scans and CI diagnostics are supplementary and are not represented as those dedicated reviews. The requested review-gate decision remains pending.

Release impact

Pyproject ranges now produce explicit incomplete coverage rather than an unrelated environment pass. Negative-case accuracy records applicable-accuracy-criteria/v1; default activation thresholds and positive-case grading are unchanged. Updated CHANGELOG.md.

chrisknvidia and others added 3 commits October 11, 2026 17:41
Resolved the CHANGELOG.md conflict under Unreleased by keeping both sides' Fixed entries.

Signed-off-by: Narendran Raghavan <[email protected]>
…rashing

A target pyproject.toml with an environment marker that packaging cannot
evaluate (for example `python_version ~= "3"`), or with deeply nested TOML
or marker parentheses, raised UndefinedComparison or RecursionError out of
the dependency audit and aborted the whole validate run. These inputs now
leave the pyproject audit INCOMPLETE, as the docs describe for malformed
declarations, and the other pins are still audited.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>

@rng1995 rng1995 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review: 4 findings (0 P1, 0 P2, 4 P3); 4 posted inline.

Comment thread src/skillevaluator/constants.py Resolved
rng1995 and others added 4 commits October 13, 2026 19:01
Optional groups can pin different versions of one package. All pins went
into one requirements file, which pip-audit rejects as duplicate
requirements, so the whole pyproject audit became INCOMPLETE with nothing
audited. Pins are now split into batches with at most one pin per
package name, each batch is audited and validated as before, and
audited_pins lists the pins from completed batches. Projects without
conflicting pins still make one pip-audit call.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
.mdc rules and workflows were added to the PII scan, but comment skipping
only treated .md and .markdown as Markdown. Other suffixes drop every
line that starts with `#` or `//`, so headings in .mdc files were never
scanned. .mdc now uses the Markdown comment rules: only frontmatter and
fenced-code comments are skipped.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
Negative cases record SKILL_IDENTIFIED in excluded_criteria and the judge
is told to set it to false, but the Harbor findings report listed every
false criterion as "<name> failed". "SKILL_IDENTIFIED failed" then took
one of the four reason slots in the terminal findings panel,
findings.json and the suggestion prompt, even though it did not affect
the score. Pass and fail reasons now skip the criteria the verifier
excluded, so the report matches how the accuracy score was computed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
Resolve the CHANGELOG.md conflict with #188 and #193 by keeping both
sides' Fixed entries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
@rng1995
rng1995 marked this pull request as ready for review October 14, 2026 03:14
rng1995 and others added 2 commits October 14, 2026 03:51
Resolve the CHANGELOG.md conflict with #199 by keeping both sides' Fixed entries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
Resolve the CHANGELOG.md conflict with #203 by keeping both sides' Fixed entries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
@rng1995
rng1995 merged commit 472c12f into main Oct 16, 2026
17 checks passed
@rng1995
rng1995 deleted the feat/christopherk/tier-integrity branch October 16, 2026 04:56
rng1995 added a commit to YMuskrat/SkillEvaluator that referenced this pull request Oct 16, 2026
Resolve the CHANGELOG.md conflict with NVIDIA#196 by keeping both sides' Fixed entries.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
rng1995 added a commit to mavericksea-ai/SkillEvaluator that referenced this pull request Oct 16, 2026
Bring in main through NVIDIA#196 (472c12f), which excludes the inapplicable
SKILL_IDENTIFIED criterion from negative-case accuracy and records
excluded_criteria/scoring_policy.

Conflicts:
- CHANGELOG.md: kept every Unreleased ### Fixed entry from both sides;
  the PR entry now states the applicable-criteria formula.
- src/skillevaluator/tier3/eval_core/llm_judge.py and
  src/skillevaluator/tier3/harbor/templates/eval.py: combined both
  rules. Complete criteria always determine the score as passing
  applicable criteria / applicable criteria (5 for positive cases, 4
  with SKILL_IDENTIFIED excluded for negative cases); the model's
  numeric score is used only for score-only payloads, which NVIDIA#196's
  validator still rejects for negative cases. NVIDIA#196's
  excluded_criteria/scoring_policy fields are kept. Host and verifier
  share identical scoring code. Dropped the template's negative-case
  '"score": 0.8' -> '"score": 1.0' prompt rewrite, which is a no-op
  now that this PR's example already scores five passes as 1.0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
rng1995 added a commit that referenced this pull request Oct 16, 2026
Resolve the CHANGELOG.md conflict with #196 by keeping both sides' Fixed
entries. uv.lock merged without conflict and `uv lock --check` passes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
rng1995 added a commit that referenced this pull request Oct 16, 2026
Brings in #196 (tier integrity) and #203 (ATIF structured answers).

Conflict: src/skillevaluator/validators/dependencies.py. Main reworked
target pyproject audits to read static PEP 621 declarations, audit exact
pins without installing the target, put conflicting pins in separate
batches, and mark malformed metadata incomplete. This branch replaced the
pip-audit result handling with a trusted-process contract that records
pip_audit success evidence for publication.

Resolution: keep main's pyproject audit as written and run each batch
through this branch's contract. A batch now also needs a successful
process and an integer exit code of 0 or 1, and its report goes through
_process_pip_audit(exit_code=...). A batch that this check marks
incomplete is not counted in audited_pins. Static metadata that parses
cleanly but has no applicable exact pins records a
pyproject_dependency_discovery success, like a target with no dependency
files, so it still counts as executed Tier 1 work. Two tests in
tests/validators/test_target_dependencies.py cover both cases.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
rng1995 added a commit that referenced this pull request Oct 19, 2026
Brings in #77 (publication evidence: required-tier rule, source digest
and publication target identity, recognized Tier 1/2 producers, Tier 3
run ID, report-output isolation, runtime binding), #182 (Kata), #196
(target dependency audits, negative-case accuracy, resource usage),
#190 (criterion-derived accuracy), #201 (failed skill reads earn no
credit) and the third-party notice updates. Conflicts:

- CHANGELOG.md: every entry from both sides under one Unreleased Added,
  Changed, Fixed and Security heading. The PR entry saying NEUTRAL never
  fails --block-on-agent-eval is dropped for main's PASS-only rule.
- THIRD_PARTY_NOTICES.md: no generator exists, so merged by hand: the
  Base row lists Packaging (main) and regex (PR); both the OpenClaw
  fixture and the Unicode data notices are kept.
- docs/ci-integration.mdx, cli-reference.mdx, tier1-validation.mdx,
  tier3-live-evaluation.mdx: both sides' rows and text. The blocking
  Tier 3 rule is main's (only a completed PASS with complete coverage
  passes); the PR's regression, partial-run and gated-skip wording stays.
  Kata and Hermes rows are both kept. The dependency audit text describes
  the merged audit below.
- cli.py: the PR's target resolution and plugin dispatch, with main's
  publication_name, report-output isolation (on the resolved content
  root, plugins included), pre-Tier 1 autopilot generation, sanitized
  Tier 3 skip reasons, repo-context exclusions and expected_skill_name.
- deduplication/utils/skill_collector.py: the PR's descriptor-anchored
  collector; generated files are matched with main's
  matches_filesystem_name, since main renamed the constant to
  BENCHMARK.md.
- evaluation/tier3_report.py: the PR's dataset source and HTML helper,
  with main's persisted publication target, skill name and agent
  seconds.
- reporting/base.py, cli.py, console_ui.py, json_reporter.py: main's
  publication assessment, skip-reason and display hardening, with the
  PR's plugin helpers and run-status rows. The PR's lift-basis line is
  limited to finite in-range scores.
- reporting/html.py and templates/report.html.j2: the PR's run-status
  cards and rows with main's publication badge, cleanly-skipped filter
  and data-attribute handlers. A completed Tier 3 card can only become
  more conservative from main's evidence status. _results_to_dict takes
  an optional run status.
- reporting/markdown.py: the PR's run-status headline and rows, with
  main's publication status line, Validators Run and advisory-skip rows,
  and main's inline, code-span and number hardening.
- reporting/benchmark.py: the PR's run-status card and plugin card. The
  skill card's verdict and each Tier Status row are the more
  conservative of the run status and main's publication assessment
  (_publication_evidence_tier_status keeps main's row rules whole).
  Main's metadata lines (source digest, Tier 3 run ID, Tier 2 policy) and
  text hardening are kept.
- tier1/commands.py: main's per-check producer stamps and target binding
  on the PR's plugin flow. Skill-scoped plugin checks scan skills/ but
  bind the plugin root.
- tier2/commands.py, tier3/commands.py: imports and keyword arguments
  from both sides.
- tier3/eval_core/atif_helpers.py, llm_judge.py, harbor/templates/eval.py:
  the PR's tool-call iteration and N/A judges, with main's is_error
  marking and skill-identification applicability on accuracy.
- tier3/harbor/report_data.py: imports from both sides.
- tier3/harbor/runner.py: main's Docker-engine env modes and repo-context
  exclusions in the PR's shared task inputs. Every arm's staged tasks
  are checked for publication-target binding.
- validators/base.py, schema.py: main's filesystem-aware exclusions with
  the PR's plugin-tree pruning.
- validators/dependencies.py: the PR's no-install engine for
  requirements, npm, container and MCP pins, with main's #196 rules.
  pyproject.toml follows main's static PEP 621 contract; anything it
  cannot audit is INCOMPLETE. pip-audit evidence is validated strictly
  and missing or failed evidence is INCOMPLETE in every run. Clean runs
  record success details and per-target dependency_coverage.
- tests/reporting/test_advisory_skip_verdict.py: main's Markdown counts.
- tests/reporting/test_reporters.py: both sides' new tests.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
rng1995 added a commit that referenced this pull request Oct 19, 2026
Main's #196 makes the Python dependency audit fail closed. The merged
audit keeps the PR's no-install engine and now follows these rules too:

- A pip-audit run with no trustworthy evidence leaves the audit
  INCOMPLETE for a standalone skill as well as for a plugin. That covers
  a missing scanner, a failed run or unexpected exit, a malformed or
  contradictory report, an unreadable manifest, and a pin pip-audit
  skipped (which still gets its MEDIUM dependency-not-audited finding,
  plus main's "scan coverage is incomplete" warning).
- pyproject.toml follows main's static PEP 621 contract. Ranges, URL,
  Poetry and dynamic metadata are INCOMPLETE rather than INFO findings.
  Pins keep their declared spelling, and markers are evaluated for the
  scanner platform.
- A report with no JSON keeps the PR's "produced no JSON report"
  wording.

Main's two requirements tests now use exact pins, since the audit never
resolves ranges. The PR's tests now expect INCOMPLETE where main's
rules say so. The marker-split batch test moves to requirements.txt,
where both pins are audited.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
@rng1995 rng1995 mentioned this pull request Oct 20, 2026
11 tasks done
chrisknvidia added a commit that referenced this pull request Oct 30, 2026
* fix: make target coverage and negative-case scoring explicit
* fix: isolate optional timing evidence and preserve judge input text
* fix: distinguish requested dependency pins from completed audit coverage
* fix: reject malformed target advisory fields
* fix: retain per-target dependency coverage in report exports

Signed-off-by: Christopher Kevin <[email protected]>
chrisknvidia pushed a commit that referenced this pull request Oct 30, 2026
* fix(tier1): mark malformed pyproject metadata incomplete instead of crashing
* fix(tier1): audit conflicting pyproject pins in separate batches
* fix(tier1): scan .mdc headings for PII like Markdown
* fix(tier3): omit excluded accuracy criteria from report reasons

Signed-off-by: Narendran Raghavan <[email protected]>
chrisknvidia pushed a commit that referenced this pull request Oct 30, 2026
Brings in #77 (publication evidence: required-tier rule, source digest
and publication target identity, recognized Tier 1/2 producers, Tier 3
run ID, report-output isolation, runtime binding), #182 (Kata), #196
(target dependency audits, negative-case accuracy, resource usage),
#190 (criterion-derived accuracy), #201 (failed skill reads earn no
credit) and the third-party notice updates. Conflicts:

- CHANGELOG.md: every entry from both sides under one Unreleased Added,
  Changed, Fixed and Security heading. The PR entry saying NEUTRAL never
  fails --block-on-agent-eval is dropped for main's PASS-only rule.
- THIRD_PARTY_NOTICES.md: no generator exists, so merged by hand: the
  Base row lists Packaging (main) and regex (PR); both the OpenClaw
  fixture and the Unicode data notices are kept.
- docs/ci-integration.mdx, cli-reference.mdx, tier1-validation.mdx,
  tier3-live-evaluation.mdx: both sides' rows and text. The blocking
  Tier 3 rule is main's (only a completed PASS with complete coverage
  passes); the PR's regression, partial-run and gated-skip wording stays.
  Kata and Hermes rows are both kept. The dependency audit text describes
  the merged audit below.
- cli.py: the PR's target resolution and plugin dispatch, with main's
  publication_name, report-output isolation (on the resolved content
  root, plugins included), pre-Tier 1 autopilot generation, sanitized
  Tier 3 skip reasons, repo-context exclusions and expected_skill_name.
- deduplication/utils/skill_collector.py: the PR's descriptor-anchored
  collector; generated files are matched with main's
  matches_filesystem_name, since main renamed the constant to
  BENCHMARK.md.
- evaluation/tier3_report.py: the PR's dataset source and HTML helper,
  with main's persisted publication target, skill name and agent
  seconds.
- reporting/base.py, cli.py, console_ui.py, json_reporter.py: main's
  publication assessment, skip-reason and display hardening, with the
  PR's plugin helpers and run-status rows. The PR's lift-basis line is
  limited to finite in-range scores.
- reporting/html.py and templates/report.html.j2: the PR's run-status
  cards and rows with main's publication badge, cleanly-skipped filter
  and data-attribute handlers. A completed Tier 3 card can only become
  more conservative from main's evidence status. _results_to_dict takes
  an optional run status.
- reporting/markdown.py: the PR's run-status headline and rows, with
  main's publication status line, Validators Run and advisory-skip rows,
  and main's inline, code-span and number hardening.
- reporting/benchmark.py: the PR's run-status card and plugin card. The
  skill card's verdict and each Tier Status row are the more
  conservative of the run status and main's publication assessment
  (_publication_evidence_tier_status keeps main's row rules whole).
  Main's metadata lines (source digest, Tier 3 run ID, Tier 2 policy) and
  text hardening are kept.
- tier1/commands.py: main's per-check producer stamps and target binding
  on the PR's plugin flow. Skill-scoped plugin checks scan skills/ but
  bind the plugin root.
- tier2/commands.py, tier3/commands.py: imports and keyword arguments
  from both sides.
- tier3/eval_core/atif_helpers.py, llm_judge.py, harbor/templates/eval.py:
  the PR's tool-call iteration and N/A judges, with main's is_error
  marking and skill-identification applicability on accuracy.
- tier3/harbor/report_data.py: imports from both sides.
- tier3/harbor/runner.py: main's Docker-engine env modes and repo-context
  exclusions in the PR's shared task inputs. Every arm's staged tasks
  are checked for publication-target binding.
- validators/base.py, schema.py: main's filesystem-aware exclusions with
  the PR's plugin-tree pruning.
- validators/dependencies.py: the PR's no-install engine for
  requirements, npm, container and MCP pins, with main's #196 rules.
  pyproject.toml follows main's static PEP 621 contract; anything it
  cannot audit is INCOMPLETE. pip-audit evidence is validated strictly
  and missing or failed evidence is INCOMPLETE in every run. Clean runs
  record success details and per-target dependency_coverage.
- tests/reporting/test_advisory_skip_verdict.py: main's Markdown counts.
- tests/reporting/test_reporters.py: both sides' new tests.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
chrisknvidia pushed a commit that referenced this pull request Oct 30, 2026
Main's #196 makes the Python dependency audit fail closed. The merged
audit keeps the PR's no-install engine and now follows these rules too:

- A pip-audit run with no trustworthy evidence leaves the audit
  INCOMPLETE for a standalone skill as well as for a plugin. That covers
  a missing scanner, a failed run or unexpected exit, a malformed or
  contradictory report, an unreadable manifest, and a pin pip-audit
  skipped (which still gets its MEDIUM dependency-not-audited finding,
  plus main's "scan coverage is incomplete" warning).
- pyproject.toml follows main's static PEP 621 contract. Ranges, URL,
  Poetry and dynamic metadata are INCOMPLETE rather than INFO findings.
  Pins keep their declared spelling, and markers are evaluated for the
  scanner platform.
- A report with no JSON keeps the PR's "produced no JSON report"
  wording.

Main's two requirements tests now use exact pins, since the audit never
resolves ranges. The PR's tests now expect INCOMPLETE where main's
rules say so. The marker-split batch test moves to requirements.txt,
where both pins are audited.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: Narendran Raghavan <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve Tier 1 target coverage and Tier 3 negative-case/resource reporting

2 participants