|
Download README.md from jkorstad/temporal-context-gap-e1: direct link, hf CLI and curl.
- Browser
- Download file 5.46 kB
-
https://huggingface.co/datasets/jkorstad/temporal-context-gap-e1/resolve/main/README.md
- Command line
-
hf download hf://datasets/jkorstad/temporal-context-gap-e1/README.md
-
curl -L -o README.md https://huggingface.co/datasets/jkorstad/temporal-context-gap-e1/resolve/main/README.md
5.46 kB
| # temporal-context-gap-e1 | |
| Code and results for **E1: temporal-provenance audit** and **E2: era-classification | |
| probe** — the first two empirical experiments of the position paper *"The Temporal | |
| Context Gap: What Meaning Is Lost Between a Corpus and Its Consumer"* (draft, | |
| September 2026, §6). | |
| ## E1 result (measured 2026-09-11, job 6aa330505527934177ec3185) | |
| Temporal metadata is **fully present and fully crawl-time** in every corpus audited: | |
| | Stratum | Docs sampled | % with temporal field | Distinct years | Years seen | | |
| |---|---:|---:|---:|---| | |
| | c4/en | 900,000 | 100.0% | 1 | 2019 only | | |
| | c4/realnewslike | 80,858 | 100.0% | 1 | 2019 only | | |
| | c4/en.noclean | 445,231 | 100.0% | 1 | 2019 only | | |
| | fineweb/CC-MAIN-2013-20 | 900,000 | 100.0% | 1 | 2013 only | | |
| | fineweb/CC-MAIN-2016-18 | 900,000 | 100.0% | 1 | 2016 only | | |
| | fineweb/CC-MAIN-2019-18 | 900,000 | 100.0% | 1 | 2019 only | | |
| | fineweb/CC-MAIN-2022-21 | 900,000 | 100.0% | 1 | 2022 only | | |
| | fineweb/CC-MAIN-2025-26 | 900,000 | 100.0% | 1 | 2025 only | | |
| | dolma3/common_crawl-{adult_content,art_and_design,crime_and_law} | ~67k each | 0% top-level; per-record `metadata.warc_date` confirmed | varies | 2015–2020 | | |
| **Finding.** The headline was not "metadata is missing" but something stronger: | |
| every temporal field that survives curation is a **fetch/crawl timestamp** | |
| (C4's `timestamp` is the April-2019 crawl snapshot for all 1.43M sampled docs; | |
| FineWeb's `date` is the WARC fetch date of its dump — a single year per | |
| snapshot config; Dolma3's is `metadata.warc_date`, the per-record WARC fetch | |
| time, nested under `metadata`). **The consumer side of the temporal context gap | |
| survives curation; the production side — the authorship `time` a temporal key | |
| needs (paper §5.2) — is absent everywhere.** A model trained on these corpora | |
| can in principle know *when it fetched a document* but not *when it was | |
| written*, except through self-anchoring expressions inside the text itself | |
| (paper §4, Level 1 — measurable with `temporal_keys.selfanchor_density`). | |
| Notes and caveats: | |
| - c4/realnewslike and c4/en.noclean sampled fewer docs than c4/en because those | |
| configs' shard files contain fewer records per shard (3 shards × ~80–150k), not | |
| because of sampling failures. | |
| - FineWeb's `date` column name suggests document dates; it is the crawl date | |
| (verified: within-week spread, one year per snapshot config). | |
| - Dolma3's top-level schema is `{id, metadata, text}`; `created` (Dolma v1) is gone. | |
| The E1 audit script's `created`-top-level check returned 0% — the corrected | |
| measurement is the nested `metadata.warc_date`, verified in job | |
| 6aa343175527934177ec364f. | |
| ## E2 result (measured 2026-09-11, job 6aa3644e5527934177ec410b) | |
| Era-classification probe: TF-IDF + logistic regression predicting dump year from | |
| raw text (first 4,000 chars, 100k features), FineWeb `sample-10BT` file 0, | |
| 15,000 docs per year cap. The sampled file contained 8 dump years | |
| (2013, 2015–2020, 2022); 120,000 docs, 24,000-doc test set. | |
| - **Year-from-text accuracy: 22.83%** vs. 12.5% majority baseline (1.8×, 8 balanced classes) | |
| - **Within ±1 year: 41.35%; within ±2 years: 61.8%; mean abs year error: 2.27** | |
| - Per-year accuracy flat (0.151–0.269; lowest 2017/2018) | |
| - **Month probe not implementable on FineWeb**: each dump's fetch dates concentrate | |
| in the crawl window, so the corpus provides no fine-granularity time labels — | |
| itself a gap datum (consumer-side metadata cannot even define authorship-month labels) | |
| - **Self-anchor density by year** (`temporal_keys.selfanchor_density`): | |
| declines monotonically, 0.588 (2013) → 0.415 (2022) | |
| - **E1b — C4 URL-year heuristic (100k docs): 19.37%** of URLs carry a path-encoded | |
| year. Histogram concentrates 2009–2019 (peak 3,092 in 2018), collapsing after 2019 | |
| (40 at 2020) — a validation: a URL year cannot postdate the April-2019 C4 crawl. | |
| A small id-like tail (years ≤1900 / far-future) is regex noise. | |
| **Reading.** Coarse era signal survives curation and is measurable in raw text | |
| alone (±2-year precision at 62%); fine granularity is unrecoverable — the corpus | |
| cannot even supply its labels. The declining self-anchor trend suggests the | |
| Level-1 anchor (paper §4) is eroding in web text. | |
| ## Files | |
| - `temporal_keys.py` — the TemporalKey dataclass, `<KEY ... />` serialization and | |
| parsing (round-trip), K2 key-dropout masking, SemEval-2020-Task-1-style LSC | |
| drift-data annotation, and self-anchoring density. Paper §5.2/§5.3 implemented. | |
| - `test_temporal_keys.py` — unit checks (run `python test_temporal_keys.py`). | |
| - `audit_temporal_provenance.py` — the E1 audit script | |
| (`--quick` for validation, `--files N --rows M` for deep sampling). | |
| - `e2_era_probe.py` — the E2 + E1b probe script (year probe, month probe, | |
| self-anchor density, URL-year heuristic). | |
| - `RESULTS.md` / `results.json` — E1 deep-audit results (written by the job). | |
| - `E2_RESULTS.md` / `E2_results.json` — E2 + E1b results (written by the job). | |
| ## Reproduce | |
| ```bash | |
| pip install pyarrow zstandard huggingface_hub | |
| python audit_temporal_provenance.py --files 3 --rows 300000 --out results.json --md RESULTS.md | |
| pip install scikit-learn pyarrow numpy huggingface_hub | |
| python e2_era_probe.py --per-year 15000 --out E2_results.json --md E2_RESULTS.md | |
| ``` | |
| ## Costs | |
| - E1 deep audit: ~$1.13 (cpu-xl, 67.5 min actual) | |
| - Dolma3 follow-up + sandbox validation: ~$0.01 | |
| - E2 probe: ~$0.004 (cpu-upgrade, 7 min actual vs 60m ceiling) |