Skip to content

build(webfetch): prepare the v3 dataset pin - #278

Closed
lanyue-llk wants to merge 32 commits into
mainfrom
codex/webfetch-v3-dataset-pin
Closed

lanyue-llk wants to merge 32 commits into
mainfrom
codex/webfetch-v3-dataset-pin

Conversation

@lanyue-llk

Copy link
Copy Markdown
Contributor

Summary

Prepare the separate v3.0.0 Web Fetch data selection requested in #276. Select Hugging Face commit def0249d88e849ab22d6108c0e0341fd54c7d38f through make pin-dataset, refresh the import binding, and register the 530-task annotation export. Keep the previous a71b0b0f snapshot used by diagnostic reports and the released v2.2.0 selection in history.

flowchart LR
  A["Merged HF v3.0.0 content<br/>530 current examples"] --> B["Publish the v3.0.0 tag<br/>upstream release prerequisite"]
  B --> C["Resolve tag to full commit<br/>confirm or refresh this pin"]
  C --> D["Lock archive and file hashes"]
  D --> E["530-task annotation export"]
  D --> F["Historical definitions retained<br/>v2.x scores stay separate"]
Loading

Release prerequisite

This PR stays draft until the upstream owner publishes v3.0.0. No tag is created here. At conversion to ready, resolve that tag and re-run make pin-dataset if its commit differs from the prepared selection. Upstream VERSIONING.md requires tag-based release selection; a merged content commit alone does not complete that release.

The current edition contains 530 distinct examples. The frozen 550-task definitions remain available for historical reproduction. Export suites overlap; their counts are not a total of distinct examples. Compare v3.0.0 separately from v2.x. No Webstone package version, benchmark catalog, provider call or saved score is changed.

Most changed lines are immutable hash bindings for the selected and historical snapshots. Dataset bodies and measured outputs are not copied into Git.

Validation

  • Both pins prepared through the repository owner; archive and member hashes verified.
  • 67 benchmark, release-binding and independent-scope tests; 36 subtests passed.
  • No live provider reruns.

Base: #276. This PR contains only the dataset selection, import binding, export documentation and dataset registry assertion.

@lexmount-ocr lexmount-ocr Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Review complete · 5b2a667

No findings in this review.

Base automatically changed from codex/webfetch-scope-dataset to main November 12, 2026 13:22
@lanyue-llk
lanyue-llk marked this pull request as ready for review November 12, 2026 13:25
@lanyue-llk

Copy link
Copy Markdown
Contributor Author

Review of head 5b2a667b: conditional pass. No P0 or P1. Three P2s block merging, and one is non-blocking.

What holds up:

  • Tag: HF v3.0.0 now exists and resolves to def0249d.
  • The pin: re-pinning def0249d gives 0 binding changes, and the lock matches the HF manifest (archive bc1ff8dd…, source_revision a71b0b0f).
  • Existing scores: the five existing suites' tasks.json are unchanged since v2.2.0, so no per-task score changes. content-scopes-530 holds exactly the 530 population IDs.
  • Tests: after a rebase onto main, 261 focused tests and 11,757 benchmark tests pass.

Blocking:

  1. P2: the PR is stale against main and must be rebased, not merged.
  2. P2: the lock keeps history for a revision main never selected.
    • data-lock.json:307-616 (about 312 lines) and :2548 record a71b0b0f. That's only because the branch stacked on feat(webfetch): score main and full content independently #276, which had pinned it first.
    • Pinning def0249d from main's lock gives the same binding without that entry, and nothing on main names a71b0b0f. AGENTS.md:32 keeps a historical revision only when a current authority names it.
    • Fix: re-run make pin-dataset from main after the rebase.
  3. P2: the version impact is missing, and the body is stale.
    • The pin moves the Web Fetch edition from v2.2.0 (550 tasks) to v3.0.0 (530 tasks). Under docs/releases.md that's a breaking pin, which needs 0.7.0 (minor), with v3.0.0 compared separately from v2.x.
    • Also say that the 530 population is selected through definitions/populations/primary-content-20261103.json.
    • "Base: feat(webfetch): score main and full content independently #276", "stays draft until v3.0.0" and the pending-tag steps in the diagram are out of date.

Non-blocking (tidiness only):

  1. tests/benchmarks/webfetch/test_benchmark.py:22-27 checks the 530 count but not that the cohort equals the population file. One assertion would catch future drift.

Follow-ups for the 0.7.0 release, outside this PR:

  • src/harness/benchmarks/cards/webfetch.md and cards/metadata.json still describe 550 as current and still declare dynamic-examples. Republishing the HF card from Webstone would revert the v3 card.
  • RELEASED_SCORERS needs the 0.7.0 hash.

Taking this over per the owner: I'll rebase, re-pin from main, add the population assertion and update the body, then merge after CI passes. 0.7.0 follows in a separate release PR.

@lexmount-ocr lexmount-ocr Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Review complete · 5b2a667

This review found 4 issue(s), including 4 blocking issue(s).

if diagnostic:
if footprint_by_path:
raise ValueError('Diagnostic publication has unexpected result-stream projections')
rows = diagnostic_scored_views(source)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

bug · medium
P2 — Bind the published diagnostic model to the validated source. This branch reads scored bindings only from the local report.json, but never checks the reconstructed archive's report.json against that source (or its permitted privacy projection). The checks above compare source_sha256 metadata, and the final scan checks bytes against archive-provided hashes; neither proves that the published model matches the source. An archive with changed diagnostic verdicts/summary values and recomputed manifest hashes can therefore pass while publishing different results. The standard branch explicitly prevents this for results.jsonl. Add the corresponding byte/projection comparison for diagnostic report.json before accepting the bundle.

Comment on lines +270 to +271
descriptor = json.loads(raw)
attachment = response.headers.get('content-disposition', '').lower().startswith('attachment')

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

bug · medium
P2 — Check attachment disposition before parsing JSON. A staged original served as application/json with Content-Disposition: attachment may contain malformed/truncated JSON (or non-JSON bytes saved with a .json filename). Here json.loads(raw) raises before the attachment check, so download_export aborts rather than preserving the original bytes, even when they match the manifest size. Export reconstruction should not require artifact contents to be valid JSON. Stream attachments unchanged and parse only potential download descriptors; add a malformed-JSON attachment case alongside the existing valid-JSON attachment test.

'task_content_scopes': {case['id']: case.get('content_scope') for case in saved_dataset['cases']},
'max_failure_retries': manifest.get('parameters', {}).get('max_failure_retries', 0),
})
if dataset_meta.get('scoring_scope') in {'main', 'full', 'both'}:

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

bug · medium
P2: Scope switching still fails for runs with live-reference bindings. This branch accepts the alternate scope, but the subsequent check_case_reference_binding(case, binding, ...) compares that newly selected case against the acquisition scope's frozen prompt, acceptance rules and reference text. Thus a valid rescore --score-scope main on a full-content live_exact run raises ReferenceLifecycleError whenever the profiles differ. Validate the original acquisition case against its capture binding separately from the alternate scoring profile, preserving the existing integrity checks, and add a bound-reference scope-switch test (the current fixture tests have no reference bindings).

})
if dataset_meta.get('scoring_scope') in {'main', 'full', 'both'}:
from lexbench_webfetch.content_scopes import REQUIREMENT_DEFAULTS
acceptance = set(REQUIREMENT_DEFAULTS) | {'content_scope', 'content_scopes', 'scoring_scope'}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

bug · medium
P2: Excluding all of REQUIREMENT_DEFAULTS also excludes the entire source_benchmark object from the retrieval-identity comparison. That object contains retrieval inputs such as input_media_kind, which native_route_cell uses to identify native execution routes. A rescore dataset can change this field in the base task and both profiles and pass both select_content_scope and this comparison, then overwrite the saved task definition without another call. Compare the non-acceptance portion of source_benchmark against the saved case; only the explicitly scope-dependent components should be exempt.

@lanyue-llk

Copy link
Copy Markdown
Contributor Author

Replaced by #279: the same v3.0.0 pin (def0249d), rebased on main after #276 and re-pinned from main's lock (no a71b0b0f history entry), with the cohort-population check and the version impact stated. A force-push here was not allowed, so the rebased commit lives on a new branch.

@lanyue-llk lanyue-llk closed this Nov 12, 2026
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.

1 participant