Skip to content
Closed
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
8 changes: 4 additions & 4 deletions evaluation/risk-control/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This cohort asks whether Moli 1.1.11 can retrieve the declared content present o

The scope is 100 URL cases across 74 distinct sites. The executable `dataset.json` is external and bound by `source-inputs.json`; `dataset-catalog.json` retains the inventory and definition hashes. Import approved full references using the [reference-input guide](../../docs/reference-inputs.md); they are not distributed with source.

Every case requires all declared stable text from initial load, including registered navigation, buttons and sidebars. Missing any required phrase fails. Another 79 cases require complete body regions; 21 cases use 27 independent count groups for names, real links, paths, deduplication and same-record fields. Human rules, machine contracts, qualification and replacement provenance are held in `first-30-rule-review.md`, `remaining-70-rule-review.md`, `body-contracts.json`, `list-contracts.json` and `qualification/`. Qualification explains historical cohort admission; it is not a scoring input. Raw investigations remain outside Git. `run-profile.json` binds authoritative inputs, provider configuration, execution parameters and binary identity.
Body extraction is accepted against the declared body regions and composite record contracts. The compiler marks stable text as diagnostic for the 97 cases with either contract; the remaining three cases still require every stable-text group. All 1,600 independently observed stable-text items remain available for diagnostics. There are 79 body-region cases and 23 composite cases, including 21 quantity cases with 27 independent count groups for names, real links, paths, deduplication and same-record fields. Human rules, machine contracts, qualification and replacement provenance are held in `first-30-rule-review.md`, `remaining-70-rule-review.md`, `body-contracts.json`, `list-contracts.json` and `qualification/`. Qualification explains historical cohort admission; it is not a scoring input. Raw investigations remain outside Git. `run-profile.json` binds authoritative inputs, provider configuration, execution parameters and binary identity.

## Deterministic build and validation without calls

Expand All @@ -13,7 +13,7 @@ uv run --frozen python scripts/build_risk_control_dataset.py --output /tmp/risk-
uv run --frozen python scripts/run_certified_benchmark.py risk-control --env-file .env
```

The first command rebuilds from hash-bound independent evidence under `BROWSER_EVAL_DATA_HOME` (default `~/.browser-eval`). Output must match the bound external dataset byte for byte. Supply a new output path; frozen inputs cannot be overwritten. The second command validates the profile, dataset, Moli 1.1.11 version and binary hash without provider calls.
The first command rebuilds from hash-bound independent evidence under `BROWSER_EVAL_DATA_HOME` (default `~/.browser-eval`). The compiler emits the corrected stable-text roles. The historical profile and bound external dataset retain their original bytes; they must not be overwritten or treated as a certificate for the revised contract. Supply a new output path; frozen inputs cannot be overwritten. The second command validates the profile, dataset, Moli 1.1.11 version and binary hash without provider calls.

The compiler is `harness.web_fetch.risk_control_dataset`. When installed or called from another directory, pass `--definition-dir` with an explicit copy of this directory's rules and qualification manifests. Frozen-rule hashes are still enforced.

Expand All @@ -31,11 +31,11 @@ Moli identity must remain unchanged before and after calls. Each of the 100 decl

This directory contains no measured Moli outputs, raw provider artifacts, debug logs or credentials. Use the existing report builder with complete certified evidence. Historical results lacking pre/post-call reference certification cannot be promoted by writing a receipt afterward.

“Full page” means the declared stable text, body and list requirements within initial load. It does not claim every undeclared character or content revealed by interaction. Registered navigation text is as mandatory as body text.
“Page body” means the declared body and record requirements within initial load. Missing navigation, login links or footer text cannot reject content that satisfies those requirements. Blocked-page detection, record counts, same-record fields and real links remain acceptance gates. Cases without a body or composite contract retain their stable-text gate.

## Current contract and historical results

The current contract requires 1,600 stable-text items. `research/risk-control-full-page-rule-revision.json` binds prior contracts and the full-page revision, retaining all registered peripheral text without rewriting earlier receipts or provider outputs. The historical 31/100 belongs to earlier inputs and evidence and is not a score for the current contract.
The historical full-page contract required all 1,600 stable-text items. The body-scope correction assigns their acceptance role without changing the observed text or reference content. `research/risk-control-full-page-rule-revision.json` binds prior contracts and the full-page revision, retaining all registered peripheral text without rewriting earlier receipts or provider outputs. The historical 31/100 belongs to earlier inputs and evidence and is not a score for the current contract.

The current adapter obtains identity from `final_url`, status and final HTML in the same `fetch --dump json` response, then converts to Markdown within the same deadline. GET completion order in old debug logs cannot prove redirect ownership; insufficient identity evidence remains unknown. A changed call route needs new execution over the complete affected scope for formal scores and timing; old-route logs and timings cannot substitute.

Expand Down
10 changes: 5 additions & 5 deletions evaluation/risk-control/rule-authoring-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Initially loaded iframe/subdocument content can qualify with declared ownership.

Do not use OCR, text within images/posters/icons/image buttons, alt text, hidden templates, scripts or still-collapsed content. Exclude content requiring clicks, expansion, typing, pagination or scroll-triggered loading. Challenges, access-denied pages, login notices and loading placeholders are not target body text. A browser-tab title absent from visible page content is not visible stable text.

Ordinary text buttons can qualify without being clicked when visible, stable and relevant. Once selected they are mandatory, but cannot replace body or list completeness.
Ordinary text buttons can qualify without being clicked when visible, stable and relevant. Their acceptance role follows the content contract: diagnostic when body or composite requirements exist, mandatory otherwise. They cannot replace body or list completeness.

### No interaction during supplementary capture

Expand Down Expand Up @@ -95,7 +95,7 @@ Do not freeze current leaderboard members, news headlines, prices, ranks, stock,

There is no universal minimum or maximum group count. Do not stop at three or add unsuitable phrases to reach three. Overlapping fragments of one sentence are not independent identity items. Each group needs a meaningful phrase, original text, position, purpose and stability evidence; avoid large spans containing volatile dates or prices.

All registered groups are mandatory. A selected footer or button missing from otherwise complete body text still fails. Select peripheral text carefully; stability alone does not require freezing every peripheral string. Navigation/footer matches do not prove body or list completeness.
The compiler sets `stable_text_role` to `diagnostic` whenever a body or composite contract exists, and to `required` for the remaining cases. Missing diagnostic groups remains visible in coverage and per-group results but does not reject complete target content. Select peripheral text carefully; navigation and footer matches cannot establish body or list completeness.

### Formatting and variants

Expand Down Expand Up @@ -202,13 +202,13 @@ These are design examples, not frozen answers for actual cases.
| Short post | Post/author identity, suitable phrases and short-body check | Arbitrary phrase quotas or replies used as post text |
| iframe page | Parent identity and actual subdocument target | Parent title or embed tag only |

All selected requirements apply. Complete stable footers do not replace body; sufficient links do not replace another declared body region. Alternative wording inside one group does not make whole-page rule types alternatives.
Every declared body region and composite group applies. Stable-text groups are diagnostics when either contract exists; cases with neither retain mandatory stable text. Complete footers cannot replace body content, and sufficient links cannot replace a declared body region.

## 12. Validate both error directions

Exercise the shared scoring entry point, not only visual inspection of configuration. The guide itself does not execute these checks. Complete independent references should pass, including reasonable spaces, line breaks, case, Markdown tables/lists, real relative-link resolution and verified irrelevant tracking differences.

Construct applicable negative controls for missing any stable phrase, including footers/buttons; site/navigation/footer-only outputs; wrong target/language; challenge-only or loading-shell responses; empty names; ownership mismatch; wrong hosts/paths; incomplete or invented links; IDs without links; missing or borrowed fields; duplicate records; wrong-region records; counts one below threshold; missing middle/end; repeated openings; and capture duplicates creating false coverage.
Include positive controls for complete body or records without peripheral phrases. Construct applicable negative controls for missing mandatory stable phrases in anchor-only cases; site/navigation/footer-only outputs; wrong target/language; challenge-only or loading-shell responses; empty names; ownership mismatch; wrong hosts/paths; incomplete or invented links; IDs without links; missing or borrowed fields; duplicate records; wrong-region records; counts one below threshold; missing middle/end; repeated openings; and capture duplicates creating false coverage.

Normal articles discussing login or CAPTCHA must not fail solely for those words. Exact threshold boundaries use unrounded values; display rounding cannot change verdicts. URL syntax alone cannot establish every new member's authenticity: require the declared provenance and ownership checks.

Expand All @@ -224,4 +224,4 @@ Keep original pages and observations in external evidence storage. Do not copy p

The final cohort inventory, original evidence, per-case scope and mappings to historical material are bound by paths and hashes. Unused reserves stay outside Git. Dynamic-task methodology supplies independent evidence, rule combinations, link/field/count/body techniques and bidirectional checks, but not its dataset-specific counts or qualification criteria.

Consult the [shared body implementation](../../harness/web_fetch/body_coverage.py) and [format handling](../../harness/web_fetch/metrics.py) for actual metric semantics. This cohort does not inherit an older three-phrase minimum, a mandatory extra visit per case or old candidate counts. It uses only the formal 100 cases, predeclared random reserve selection when needed, page-specific stable text without quotas, necessary evidenced variants, all-selected-item acceptance, evidence reuse, real links and at least 80% valid name-link count.
Consult the [shared body implementation](../../harness/web_fetch/body_coverage.py) and [format handling](../../harness/web_fetch/metrics.py) for actual metric semantics. This cohort does not inherit an older three-phrase minimum, a mandatory extra visit per case or old candidate counts. It uses only the formal 100 cases, predeclared random reserve selection when needed, page-specific stable text without quotas, necessary evidenced variants, explicit body/record acceptance with stable-text diagnostics, anchor-only fallback, evidence reuse, real links and at least 80% valid name-link count.
13 changes: 11 additions & 2 deletions evaluation/scoring-regressions.json
Original file line number Diff line number Diff line change
Expand Up @@ -21777,6 +21777,15 @@
"expected_metrics": {
"stable_unique_record_count": 0
}
}
]
},
{"id":"explicit-body-without-page-shell-passes","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-negative","case":{"url":"https://example.test/article","ground_truth_main_content":"alpha bravo charlie delta echo foxtrot golf hotel","body_requirements":{"version":3,"unit":"region_compact_hexagram_recall","minimum_coverage":0.8,"minimum_floor":0.6,"minimum_region_passes":2,"regions":[{"id":"opening","text":"alpha bravo charlie delta"},{"id":"ending","text":"echo foxtrot golf hotel"}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"alpha bravo charlie delta echo foxtrot golf hotel","ok":true,"expected_task_pass":true,"expected_metrics":{"stable_anchors_required":false,"stable_anchor_hits":0,"body_coverage_pass":true}},
{"id":"page-shell-without-complete-body-fails","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/article","ground_truth_main_content":"alpha bravo charlie delta echo foxtrot golf hotel","body_requirements":{"version":3,"unit":"region_compact_hexagram_recall","minimum_coverage":0.8,"minimum_floor":0.6,"minimum_region_passes":2,"regions":[{"id":"opening","text":"alpha bravo charlie delta"},{"id":"ending","text":"echo foxtrot golf hotel"}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"Account login and site footer alpha bravo charlie delta","ok":true,"expected_task_pass":false},
{"id":"explicit-record-without-page-shell-passes","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-negative","case":{"url":"https://example.test/homes","task_kind":"body","composite_acceptance":{"version":1,"groups":[{"id":"homes","kind":"named_link","minimum_records":1,"hosts":["example.test"],"entry_path":"/item/[0-9]+","required_fields":[{"id":"price","kind":"price"},{"id":"beds","kind":"integer","pattern":"\\b(?:bds|beds?)\\b"},{"id":"baths","kind":"integer","pattern":"\\b(?:ba|baths?)\\b"},{"id":"area","kind":"area"}]}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"[One Main Street](https://example.test/item/1)\n$900,000\n3 beds · 2 baths · 1,200 sqft","ok":true,"expected_task_pass":true},
{"id":"page-shell-with-incomplete-record-fails","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/homes","task_kind":"body","composite_acceptance":{"version":1,"groups":[{"id":"homes","kind":"named_link","minimum_records":1,"hosts":["example.test"],"entry_path":"/item/[0-9]+","required_fields":[{"id":"price","kind":"price"},{"id":"beds","kind":"integer","pattern":"\\b(?:bds|beds?)\\b"},{"id":"baths","kind":"integer","pattern":"\\b(?:ba|baths?)\\b"},{"id":"area","kind":"area"}]}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"Account login and site footer\n[One Main Street](https://example.test/item/1)\n$900,000","ok":true,"expected_task_pass":false},
{"id":"explicit-record-placeholder-link-fails","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/homes","task_kind":"body","composite_acceptance":{"version":1,"groups":[{"id":"homes","kind":"named_link","minimum_records":1,"hosts":["example.test"],"entry_path":"/item/[0-9]+","required_fields":[{"id":"price","kind":"price"},{"id":"beds","kind":"integer","pattern":"\\b(?:bds|beds?)\\b"},{"id":"baths","kind":"integer","pattern":"\\b(?:ba|baths?)\\b"},{"id":"area","kind":"area"}]}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"[One Main Street](#)\n$900,000\n3 beds · 2 baths · 1,200 sqft","ok":true,"expected_task_pass":false},
{"id":"anchor-only-contract-missing-shell-fails","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/page","acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"required","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"Some other body text","ok":true,"expected_task_pass":false,"expected_metrics":{"stable_anchors_required":true}},
{"id":"anchor-only-contract-present-shell-passes","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-negative","case":{"url":"https://example.test/page","acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"required","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"Account login and site footer","ok":true,"expected_task_pass":true},
{"id":"explicit-body-request-failure-stays-failed","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/article","ground_truth_main_content":"alpha bravo charlie delta echo foxtrot golf hotel","body_requirements":{"version":3,"unit":"region_compact_hexagram_recall","minimum_coverage":0.8,"minimum_floor":0.6,"minimum_region_passes":2,"regions":[{"id":"opening","text":"alpha bravo charlie delta"},{"id":"ending","text":"echo foxtrot golf hotel"}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]}},"artifact":"alpha bravo charlie delta echo foxtrot golf hotel","ok":false,"expected_task_pass":false},
{"id":"body-and-record-both-remain-required","category":"acceptance-contract","root_cause":"page_shell_anchors_veto_explicit_body_or_record_contract","failure_mode":"false-positive","case":{"url":"https://example.test/article","ground_truth_main_content":"alpha bravo charlie delta echo foxtrot golf hotel","body_requirements":{"version":3,"unit":"region_compact_hexagram_recall","minimum_coverage":0.8,"minimum_floor":0.6,"minimum_region_passes":2,"regions":[{"id":"opening","text":"alpha bravo charlie delta"},{"id":"ending","text":"echo foxtrot golf hotel"}]},"acceptance_contract":{"version":1,"schema":"body_text","stable_text_role":"diagnostic","minimum_records":0,"stable_text_anchors":[{"id":"footer","alternatives":["Account login and site footer"]}]},"composite_acceptance":{"version":1,"groups":[{"id":"homes","kind":"named_link","minimum_records":1,"hosts":["example.test"],"entry_path":"/item/[0-9]+","required_fields":[{"id":"price","kind":"price"},{"id":"beds","kind":"integer","pattern":"\\b(?:bds|beds?)\\b"},{"id":"baths","kind":"integer","pattern":"\\b(?:ba|baths?)\\b"},{"id":"area","kind":"area"}]}]}},"artifact":"alpha bravo charlie delta echo foxtrot golf hotel","ok":true,"expected_task_pass":false}
]
}
Loading
Loading