Repository navigation
refactor(research): move adoption survey into harness and fix stale doc paths - #138
Conversation
There was a problem hiding this comment.
Independent review, round 1
Reviewed head f174464e against base 27401304, which is still current main. I found no correctness or data problems. There are two P2 and two P3 findings, all in the new checker, the docs and the PR's test-plan text.
Findings
P2: tests/test_documented_paths.py:52, the checker skips paths inside commands
rooted_token returns None for any code span containing whitespace, and fenced blocks are never scanned. A stale script path in a command therefore passes. I ran missing_paths on these inputs, and all three returned []:
Run `uv run --frozen python scripts/gone.py --x`.- The same command inside a
```shfence Run `scripts/gone.py --flag`.
This is the kind of stale reference the PR fixes by hand. The base evaluation/risk-control/README.md ran scripts/build_risk_control_dataset.py from a fence, and that script is absent at 27401304. Feeding the base README to the checker reports only rule-authoring-guide.md. The "Summary" lists what the checker does not cover, but commands are not on that list.
Fix: extract repository-prefixed path tokens from multi-word spans and fenced blocks too, and add failing cases for both forms. This looks low-noise: a regex scan of all tracked .md files, fences included, found only the current allowlist entries plus a few relative or prose tokens to exempt: scripts/validate_timeline.py in the video-gen skill, data/model.json, data/report-methods.json, evaluation/scoring and the scripts/propose_webarena_ prefix.
P2: evaluation/risk-control/README.md:18, the --definition-dir instruction fails as written
The PR rewrites this paragraph but keeps "pass --definition-dir with an explicit copy of this directory's rules and qualification manifests". This checkout's directory no longer holds them: first-30-rule-review.md, remaining-70-rule-review.md, list-contracts.json, body-contracts.json and qualification/cohort/* are all logical definitions. Calling build(output, Path("evaluation/risk-control"), evidence_home=...) raises FileNotFoundError on evaluation/risk-control/first-30-rule-review.md.
Fix: tell readers to copy the pinned definition directory, the one definition_path("evaluation/risk-control") resolves to. The rule-authoring-guide sentence in the same README already describes these files as living in the pinned definitions.
P3: tests/test_documented_paths.py:11, two maintained documents are outside the inventory
DOCUMENT_ROOTS omits deploy and .github, so deploy/webarena/README.md and .github/workflows/README.md are never checked, even though scripts/README.md cites the deploy guide. Both report no missing paths today, so adding the two roots should not cause a failure. Only the test tuple changes, and nothing under .github/workflows/ is edited.
P3: PR body test plan and docs/trajectory-replay-protocol.md:287, small inaccuracies
- Test plan: it says
docs/provider-contract.mdis the only changed document whose base version the checker does not flag for its stale path. Two others also go unflagged:src/harness/web_fetch/README.mdreports[], becauseevaluation/scoring-regressions.jsonis an exempt logical definition.- The risk-control README's stale script is missed, as described in the first finding.
- Protocol doc:
docs/trajectory-replay-protocol.md:287still uses the barepublic_webarena/qualification.py. The PR expanded the same token inscripts/README.md, so the two documents should match.
What I verified
- Issue scope: "Part of #107" is accurate. Each deferred row matches a real reader or binding, and the only tracked research files still unnamed are the nine receipts the PR defers.
- Deletions:
- There are 31 deleted files, as the PR says.
git grepat the head for each stem and SHA-256 hits onlyadoption-searches, in the new module and its test. I also searchedsrc,scripts,tests,docsand theMakefilefor dynamically built names and found no reader.adoption-searches.jsonparses equal to thesearcheskey ofresearch/provider-adoption.json.- A recursive fixed-string
grepfound no stem or hash in~/.browser-eval/{evidence,reviews,reference-inputs,datasets,builds}. That includes files over 20 MB but skips filesgreptreats as binary. The stem list left outadoption-searches, though its hash was searched. - I did not check published Artifact Site releases, Hugging Face revisions or other machines, so that limit in the PR body still stands.
- Module move: I compared
provider_adoption.pywith the four old scripts line by line.gh,metadata_batch,candidate_union, therefreshflow and blob checks match, and thematchesrules are the same apart from dropping the unusedrepoargument.- The intended changes are the checkpoint location, the English
scopetext and the removal ofdiscoverandverify. - The renderers read no stored
scopevalue from this file.
- Hash bindings: no base SHA-256 of a modified file appears in tracked files, and no tracked
.jsonnames one of their paths.tests/goldenis unchanged. - Doc targets:
src/harness/benchmarks/scoring-regressions.jsonis where new controls belong, perload_scoring_regressionsandAGENTS.md.report-content-binding.jsonbeside the profile matcheswcxb_publication.pyandbuild_report.py.--profileexists inscripts/build_report.py.- The
compile-access-restrictionsflags exist.
- Not confirmed: the documented compile command gets as far as evidence verification, then fails against my local data home with
Missing or changed reference proof: risk-diverse-002. That comes from local evidence and not from this diff, so I could not confirm the README's "rebuilds" claim end to end. - Local runs:
- Both ruff gates pass.
tests/test_documented_paths.py,tests/test_report_methods.pyandtests/test_golden_reports.pygive 42 passed.python -m harness.web_fetch.provider_adoption --helpworks.- I did not run the full suite locally.
- CI on
f174464e: all checks pass, including "Tests and static checks", "Installation and packaging" and "Rendered reference and report checks".
|
Review round 1 is addressed on 355ea7e. All four findings are fixed and none is disputed.
Ruff, |
lanyue-llk
left a comment
There was a problem hiding this comment.
Independent review, round 2
Reviewed head 355ea7e1 against base 27401304. The round 1 fixes hold, and I found no correctness or data problems. There are two remaining findings, both about stale documentation that the PR's scope covers but neither fixes nor lists as remaining.
Findings
P2: evaluation/trajectory-replay/webarena-verified-full/README.md:8 (also lines 10 and 14) and evaluation/trajectory-replay/webarena-verified/README.md:3 (also line 22)
- Problem: Both READMEs describe report instance files as if they were in the checkout. The first says "This directory owns"
current-report.jsonandcurrent-comparison.json, and names../webarena-verified/current-run.json. The second callscurrent-run.jsonthe run authority. #56 (75a37a0a) removed all three files, andsrc/harness/reporting/source_policy.py:42now reports any file with these names underevaluation/as "keep report instances outside Git". This is the stale-path class #107 describes. The checker can't catch it because it skips bare and../tokens, and "Remains open" doesn't list it. - Fix: Reword both READMEs to say these are external instance profiles selected with
--profile, and make the "owns" sentence cover only the files that remain.evaluation/trajectory-replay/webarena-verified/retrieval-candidates/README.md:14only says its definitions are not bound bycurrent-run.json, so it can stay as it is or take the same wording. While updating the PR body, adddocs/trajectory-replay-protocol.mdto the "Stale paths fixed" list, because it was changed in355ea7e1but isn't listed.
P3: evaluation/risk-control/qualification/README.md:5-8
- Problem: It lists
cohort/cohort-manifest.json,cohort/cohort-receipt.json,cohort-policy.jsonandcohort/input-manifest.jsonwith no location, but this directory holds only the README. All four exist in the pinned definitions underevaluation/risk-control/qualification/. Round 1 fixed the same misdirection in the parent README. - Fix: Add one sentence saying these paths are relative to the pinned definition directory that
definition_path("evaluation/risk-control/qualification")resolves to.
What I verified
- Survey move: I ran the base scripts and
harness.web_fetch.provider_adoptionagainst the same fakeghresponses, for bothrefreshandsearch, including removed files, ineligible repositories, absent signatures and private hits. The outputprovider-adoption.jsonfiles are equal once timestamps and the intentionally translatedscopeare excluded. The checkpoint goes to the evidence directory, and nothing is left inresearch/. No code reads thescopekey, and the--helpentry point works. - Survey inputs: The saved
adoption-searches.jsonequals thesearcheskey ofresearch/provider-adoption.json. - Deleted files: I repeated the search at the head for each deleted file's stem and SHA-256. The only stem hits are the new checkpoint path and its test. No hash matches. The 21 task IDs appear in no
task_idfield or correction ID, andtask-corrections.jsoncovers other tasks. research/references: I extracted everyresearch/...token from tracked files. None names a file this PR removed.- Unnamed files: The 9
research/files with no remaining tracked name are exactly the 9 listed as deferred. I did not repeat the data-home scan. - Hash bindings: The base hashes of the modified files appear nowhere in the tracked tree, and their paths appear in no tracked JSON.
- Document edits:
src/harness/benchmarks/scoring-regressions.jsonmatchesload_scoring_regressionsandAGENTS.md.compile-access-restrictionsaccepts the documented arguments.- The pinned risk-control directory holds the files named.
report-content-binding.jsonandmoli-variants.jsonmatch their readers.
- Checker: Base versions of the changed documents report the stale rooted paths.
docs/provider-contract.mdreports nothing, as the PR states, and I found no broken images or reference-style links that it would miss. - Local gates: Both ruff gates pass.
tests/test_documented_paths.py,tests/test_golden_reports.pyandtests/test_report_methods.pypass (53 tests).tests/goldenis unchanged. - CI on
355ea7e1: "Tests and static checks", "Installation and packaging" and "Rendered reference and report checks" all pass.
|
Round 2 review findings, both fixed. Nothing is disputed.
Local checks on efc1279: both ruff gates pass and the targeted tests pass (73 passed, no golden change). I did not rerun the full local suite; CI on this head is the full-suite gate. |
There was a problem hiding this comment.
✅ Re-review complete · efc1279
No findings in this incremental review.
lanyue-llk
left a comment
There was a problem hiding this comment.
Independent review, round 3
Reviewed head efc1279a against base 27401304, which is still the tip of main. No defects found.
What I verified
Round 2 fixes
webarena-verified/README.md,webarena-verified-full/README.mdandretrieval-candidates/README.mdno longer present report instances as checkout files.--profileand--comparison-releaseboth exist incatalog_release.py.--comparison-releaseis the correct flag for the comparison binding, so the author's change from my round 2 suggestion is right.- The sentence "the last profile kept in Git bound
trajectories-corrected.json" matches thecurrent-run.jsonremoved by 75a37a0. - With the old
webarena-verified/README.mdrestored, the new report instance check fails. I restored the file afterwards. REPORT_INSTANCE_NAMESmoved to a module constant with no change to the source policy logic.definition_pathresolvesevaluation/risk-controlandevaluation/risk-control/qualificationto directories. All four files listed in the qualification README andrule-authoring-guide.mdexist there.
harness.web_fetch.provider_adoption
- I compared it with the four old scripts. Queries, signature rules, metadata filter, candidate union, blob integrity check, atomic write and the failed-search and known-positive errors match.
- The intended differences are the English
scopestring, the checkpoint location, and the removal of the two standalone entry points.matchesalso lost its unusedrepoparameter. searchandrefreshare the only commands, and--helpruns. No tracked file still names the removed scripts.- No read of the adoption
scopekey was found insrc/harness/web_fetch/report.py, by search of that file foradoption/adoption_datasubscripts and.get.
Deleted and retained research files
- The counts in the PR body match: 27 data files plus 4 scripts, and 21 numbered tasks.
git grepat the head finds no deleted data file's stem, apart from theadoption-searches.jsoncheckpoint name in the new module and its test.- The retained task reference files I sampled are named by
task-corrections.jsonand related files underevaluation/trajectory-replay/webarena-verified/. - An independent scan of the remaining
research/files found exactly nine with no tracked name, the same nine listed under Deferred. - A fixed-string search for the 27 stems in
~/.browser-eval/{reference-inputs,datasets,reviews}(.json,.md,.jsonl, each with a 90-second limit) found nothing. A hit on the limit would not be visible in that output, so treat this as a partial check. I did not rescanevidence,buildsorreport-builds.
Hash bindings and rules
- None of the 15 modified files has its base SHA-256 or its path in tracked
.jsonfiles, and the hash is not in tracked.pyfiles either. - No changes under
tests/goldenor.github/workflows. - The
## Issuessection says "Part of #107", and its remaining-work and Deferred lists match the files still inresearch/.
Stale paths beyond the checker
- I scanned backticked tokens in the changed documents more broadly than the checker does. The remaining tokens are external or relative artifact names described as such, or logical definitions.
Test results
- Both ruff gates pass.
tests/test_documented_paths.py,tests/test_golden_reports.py,tests/test_report_methods.pyandtests/test_source_language_policy.py: 73 passed.- With
tests/test_storage.pyandtests/test_portable_cli.pyadded: 92 passed. - I did not run the full suite locally; CI is the gate for that.
CI on efc1279a
All checks pass: "Tests and static checks", "Installation and packaging", "Rendered reference and report checks", "Python 3.11", "Select check scope", OCR dispatch and ocr-review.
…oc paths Move the research adoption survey into harness.web_fetch.provider_adoption, delete research files nothing names, correct stale repository paths in docs and skills, and add a test that checks repository paths named in maintained documents.
Reword both WebArena-Verified READMEs and check that no evaluation document names a report instance file that source policy keeps out of the checkout.
efc1279 to
0ebf206
Compare
Issues
Closes #107. Part of the #87 roadmap.
Remaining work moved to #158 (nothing below is touched here; see "Deferred" for the file and reader):
research/report-changes.jsonandresearch/trajectory-replay-content.jsonout of Git and removing their fallbacks.research/initial-reference-audit.json.research/provider-pricing.jsonprose item.Summary
research/*.pytosrc/harness:harness.web_fetch.provider_adoptionreplaces the four scripts, which were outside lint and had callers (tests/test_report_methods.py). It hassearchandrefreshcommands.searchwrites its checkpoint under the research evidence directory instead of the checkout.discover_webfetch_adopters.pyandverify_adoption_sources.pyentry points are gone.research/webfetch-adopters.jsonstays as the frozen inputrefreshreads, andrefreshalready checks blob integrity and signatures.scopestring, written into new survey output only, is now English. The stored Chinese value inresearch/provider-adoption.jsonis unchanged, and no renderer reads that key..agents/skills/benchmark-editorial/(SKILL.md,references/html-delivery.md),docs/architecture.md,docs/provider-contract.md,docs/trajectory-replay-protocol.md,evaluation/risk-control/README.md,evaluation/risk-control/qualification/README.md,evaluation/trajectory-replay/webarena-verified/README.md,evaluation/trajectory-replay/webarena-verified/retrieval-candidates/README.md,evaluation/trajectory-replay/webarena-verified-full/README.md,scripts/README.md,src/harness/web_fetch/README.mdandsrc/harness/web_fetch/WEBMAINBENCH.md.tests/test_documented_paths.pychecks repository-rooted paths in inline code, including multi-word commands, and in fenced blocks, plus relative Markdown links, in maintained documents, includingdeploy/and.github/.providers/x.py, dotted module names, prose paths or any path outside inline code and fences. A skill document's path also resolves against that skill's own directory.NOT_IN_CHECKOUTallowlists four paths owned elsewhere, each with a comment. Dataset cards are excluded because their links resolve on Hugging Face.evaluation/that names a report instance file (current-report.json,current-run.json,current-comparison.json), which source policy keeps out of that directory. Both checks share one list:REPORT_INSTANCE_NAMESmoved from a local variable to a module constant inharness/reporting/source_policy.py, with no behavior change.No rendered report output changed:
tests/goldenhas no changes. No hash-bound file changed either: none of the modified files' SHA-256 values or paths appear in tracked.jsonor.pyfiles.Deleted files and how nothing was found to name them
Deleted data files:
adoption-searches.json, whose parsed content equals thesearcheskey ofresearch/provider-adoption.jsonchromium-markdown-selection.jsondynamic-expansion-checks.jsondynamic-expansion-postchecks.jsonwebarena-mac-expansion.jsontrajectory-replay-magento-configurable-create-options-reference.jsontrajectory-replay-task*-reference.jsonfiles: tasks 265-268, 423, 550, 677-680, 737-743, 745, 746, 759, 760Each file's bytes remain available in Git at 2740130.
Checks run:
git grepfor each file's stem and for its SHA-256 (no hits outside the deleted set), plus partial stems.git grepforwv-<id>-,task<id>-and"task_id": <id>for the 21 numbered tasks underevaluation,srcandtests, plus a search for each file'scorrected*and*sha256values. Neither found a hit.git log -Sshows the route-order and map-live stems sampled were never named by another commit.glob,rglobanditerdircalls touchingresearch. The only one is*-content.jsoninharness/reporting/assets.py, which matches no deleted file.src/lexbench_webfetchis tracked here, so thegit grepcovers it..json,.md,.jsonland.htmlfiles under 20 MB in~/.browser-eval/{evidence,reviews,reference-inputs,datasets,builds,report-builds}found no name or hash of a deleted file.Not scanned:
~/.browser-eval/{implementations,runtime,toolchains,vm,build-cache}The owner should check these if a published report might name one of these files. The local scan changed the outcome for one file:
popular-stable-chinese.jsonhas no tracked name, but it stays because frozen external receipts name it (see below).Deferred
research/report-changes.jsonbrowser_use/report_i18n.py,browser_use/report.py,browser_use/report_check.py,web_fetch/report.py,web_fetch/report_build.py,web_fetch/report_changes.py,web_fetch/webmainbench_report_check.py, testsreport-assets/report-changes.json, and evidence restored by the owner.research/trajectory-replay-content.jsontrajectory_replay/webarena_report.py; named byevaluation/trajectory-replay/webarena-verified/README.mdresearch/initial-reference-audit.jsonscripts/README.md; usage text inscripts/audit_initial_references.pyresearch/provider-pricing.jsonweb_fetch/report_pricing.py,tests/test_report_pricing.pytranslationsmap, and the Chinese strings are the zh edition's rendered text and the keys fordata-report-en. Rewriting them would change reports, so this needs an owner decision.research/popular-stable-chinese.json"source"field in frozenreference-inputs/*/sources/challenge-0{2,3}/stable-page.jsonreceipts in the data home (external, 9 hits)research/reference-freeze-promotions/2026-09-14-mdn-history-footer-scope-correction.json"receipt"field in frozen externaldataset.jsonfiles (6 hits)research/reference-freeze-promotions/,research/browser-native-430-html-record-ownership-scoring-revision.json,research/risk-control-body-scope-revision.jsonapproved_by,correction_provenance,root_cause). The issue lists the promotions as unnamed, but deleting approval provenance is an owner decision, particularly as the scan of one sibling turned up a frozen reference.No workflow changes were needed; nothing under
.github/workflows/is touched.Test plan
tests/test_documented_paths.py,tests/test_golden_reports.py,tests/test_report_methods.pyandtests/test_source_language_policy.pypass on efc1279 (73 passed, no golden change). With the oldwebarena-verified/README.mdrestored, the new report instance check fails as intended. The full local suite was not rerun, since only documents, that test file and one constant changed.tests/test_documented_paths.py,tests/test_golden_reports.pyandtests/test_report_methods.pypass on 355ea7e (53 passed, no golden change). The full local suite below was not rerun, since only that test file and two documents changed.ruff check --config 'include=["*.py"]' --select F,TID252 .andruff check.tests/test_golden_reports.py,tests/test_documented_paths.pyandtests/test_report_methods.pypass on f174464. No golden snapshot changed.evaluation/current-report.json,evaluation/wcxb/report-content-binding.jsonand the fencedscripts/build_risk_control_dataset.py. Three report nothing:docs/provider-contract.mdanddocs/trajectory-replay-protocol.md, whose stale tokens are bare relative paths (providers/hosted_fetch.py,public_webarena/qualification.py) outside what the checker covers, andsrc/harness/web_fetch/README.md, whose oldevaluation/scoring-regressions.jsonis a logical definition in the benchmark binding, so it counts as resolving.research/popular-stable-chinese.json(that file has no test reader). Three chunks passed in the worktree (3,292, 7,971 and 1,920 tests).benchmark_input_pathwalks up into that checkout's binding. Rerun in a copy outside that checkout: 13 failed / 1,883 passed, 5 failed / 2,268 passed, 1,540 passed.tests/test_optional_reports.py:test_rescore_no_report_preserves_existing_html_and_reports_staleness,test_default_rescore_rebuilds_local_report_without_publicationandtest_no_report_rescore_still_rejects_tampered_evidence. Their subprocess imports the shared environment's editable install from another checkout, whose data lock lacks the current revision. This PR's code is not on that path.