File size: 12,276 Bytes
d73e094 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 | ---
license: other
license_name: per-source
language:
- pl
task_categories:
- text-generation
pretty_name: GoLLeM Corpus v4 PL (16B tokens)
size_categories:
- 10M<n<100M
configs:
- config_name: default
data_files: "data/default/*.parquet"
- config_name: cc-by-sa
data_files: "data/cc-by-sa/*.parquet"
- config_name: web
data_files: "data/web/*.parquet"
tags:
- pretraining
- polish
- gollem
- from-scratch
- pii-scrubbed
- deduplicated
---
# GoLLeM Corpus v4 PL — SlayerLab/gollem-corpus-16b-pl
**The exact pretraining corpus of the Polish base model GoLLeM v4 (250M, trained from
scratch)** — released *before* training, so the published bytes are byte-identical
(sha-tied) to what the model will see. Successor of
[`SlayerLab/gollem-corpus-2b-pl`](https://huggingface.co/datasets/SlayerLab/gollem-corpus-2b-pl)
(the v2/v3 corpus), scaled ~7.5x with per-record provenance this time.
- **16.58B unique tokens** (GoLLeM V32k tokenizer, measured) =
~1.96B curated + 14.62B cleaned Polish web.
- **Per-record `license`, `is_share_alike`, `register`, `source_id` columns** — no blanket license.
- **Three partitions** (Dynaword-style): `default` (permissive), `cc-by-sa` (share-alike
sources), `web` (HPLT v3 PL, TDM basis — see [License](#license)).
- PII-scrubbed (two-stage pipeline + independent gate), deduplicated (license-aware
MinHash+LSH), decontaminated against our evaluation sets.
## Composition
Register sizes (V32k tokens, measured this build; sha256 = train `.bin` per register, full set in
[`_manifest.json`](./_manifest.json)):
| register | V32k tokens | docs | train-bin sha256 | main sources |
|---|---:|---:|---|---|
| encyclopedic | 984,163,312 | 1,707,741 | `98a3da0e979c` | Wikipedia PL, Wikisource (CC-BY-SA) |
| science | 522,045,834 | 41,484 | `a5449de3307f` | Biblioteka Nauki (per-record license) |
| news | 210,859,436 | 355,740 | `cf156a47cc20` | polish_news, elka, Wikinews, Global Voices |
| legal/gov | 176,224,723 | 99,152 | `25a5fe007936` | Dziennik Ustaw, gov.pl (PD; 15% register cap) |
| literary | 60,405,659 | 4,228 | `b91f051fc579` | Wolne Lektury, ELTeC-pol (PD/CC-BY-SA) |
| mixed | 1,621,359 | 18,348 | `992d76483f8d` | NKJP-1M |
| **web** | **14,624,198,792** | 17,092,459 | `5045b38564b5` | HPLT v3 PL, cleaned + scrubbed |
| **total** | **16,579,519,115** | 19,319,152 | | train 16,495,148,611 + heldout 84,467,087 |
Held-out (val split, NEVER trained): 84,467,087 V32k tokens / 96,583 docs (sha256 `c4b4990fef60`,
deterministic `sha1(document_id) % 200`). 18 parquet shards across 3 partitions.
Design decisions (documented in the build experiment, DS25B-EXP1):
- **QA sources excluded from base:** PoQuAD is a published Polish QA benchmark — its
documents in pretraining data would leak evaluation (held out as eval-only). PolQA is
deferred to the SFT stage (Q/A format skews base-model style).
- **1000 Novels excluded** — residual-author-rights concern despite the CC-BY label
(mirrors upstream Dynaword's own handling).
- **Legal register capped at 15%** — the dominant failure mode of open Polish corpora is
legalese skew (71.8% in polish-dynaword v0.2.1); this corpus caps it by construction.
- **Token counts** are reported in the GoLLeM V32k tokenizer (vocab 32,000). Document
counts are tokenizer-agnostic; re-tokenize with your own tokenizer as needed.
## Quality benchmarks (this corpus)
All numbers from **full-corpus scans of the published artifact** (not samples), pipeline scripts in the build repo:
| check | method | result |
|---|---|---|
| exact duplicates | blake2b/sha8, normalized | 575 docs (0.003%) removed |
| near duplicates | MinHash K=32, 8 bands, word 5-grams (J≈0.6) | 4.80% removed (974,277 of 20,296,635 docs; total removal incl. exact+decontam 4.82%, full-web scan; a 15k sample had estimated 0.03–0.14% — sampling *underestimates* long-tail web duplication, which is why we only report full scans) |
| eval decontamination | exact + word 8-gram fingerprints vs d3_eval, llmzszl, MultiBLiMP, eval_admission | 2,632 docs (0.013%) removed |
| retention | | 95.18% kept (19,319,152 / 20,296,635; falsification threshold pre-registered at >15% removal — not met) |
| license-aware dedup | duplicate survivor chosen by permissiveness (CC0 > CC-BY > CC-BY-SA) | implemented; effect small here (cross-license dups pre-excluded), method contributed for general corpora |
| PII residual (post-gate) | independent full scan, `check ⊋ scrub` | 0.0018% (≤351 / 19,319,152 docs; sha-tie 8/8 verified) |
| trainability smoke | 300 docs/register schema+content audit | schema OK, 0 empty docs, scrub markers present, registers consistent |
## Reference downstream results (predecessor models)
The v4 model trained on this corpus will publish its own benchmarks. For calibration,
models trained on this pipeline's predecessor corpus (gollem-corpus-2b-pl, same source
family and cleaning approach):
- **GoLLeM-110M-PL-v3** (2 epochs / ~2B V32k): PL sentiment polemo2 56.5 acc /
8tags 37.2 (bench_pl harness; +9.3/+5.7 over an independently built 45M PL model on the
same harness). Cross-lingual control (lm-eval 0.4.12 zero-shot): BLiMP .546,
SciQ .620, LAMBADA-EN ppl 10508 — i.e. a genuinely Polish model, near-random on
English, as expected.
- Honest framing: at 110M/2B tokens these are fluency/completion models, ~random on
zero-shot classification (8tags .11 vs random .125). v4 (250M / 24B seen tokens,
DataDecide-style 100:1 overtraining) is the scale-up this corpus exists for.
## PII Statement
<!-- === SEKCJA WARTOWNIKA (verbatim) === -->
### Personal Data / PII Processing
All text passed a two-stage PII pipeline before inclusion:
1. **Scrubbing** (`scrub_pii.py`, Paweł, PR#28 + international-format extension): emails → `[PII]`,
phone numbers (Polish and international formats, label-anchored and self-labelling `+CC`) → `[Telefon]`,
PESEL/NIP/REGON/KRS and identity-document numbers (checksum-validated, label-anchored) → `[PII]`,
bank accounts / IBAN (MOD-97 validated) → `[PII]`. Placeholders are semantic tags, not fake values,
so no synthetic high-frequency numbers poison the corpus.
2. **Independent gate** (second reviewer, lens strictly wider than the scrubber — `check ⊋ scrub`):
full-corpus residual scan on the exact artifact being published (sha-tied, `verify == publish`).
Residual after independent gate on the published artifacts: ≤351 documents with unredacted contact data out of 19,319,152 (**0.0018%**), all triaged as institutional/business contacts (university department listings, ministry switchboards, travel-guide venues) in edge formats (+0-trunk, legacy 8-digit); no private-person data found in any triaged sample. Verified sha-tied: all 8 manifest checksums independently recomputed and matched.
Out of scope by explicit decision (ADR): public-institution donation account numbers, court registry
numbers (KRS as bare references), emergency numbers (112/997/998/999), timestamps, coordinates, ISBNs.
Names of public officials in official/government documents are left intact by design (public-interest
information, consistent with the source datasets' practice).
### Known limitations
- Numbers damaged at the source (truncated 8-digit forms) may survive scrubbing; measured share is
included in the residual figure above.
- The scrubber is regex-based; free-form descriptions of persons are not redacted. The corpus is
web/official text — downstream users training generative models should apply their own output filters.
## License
This dataset is a compilation of sources with **per-record license tracking** (`license` and
`is_share_alike` columns). It is NOT distributed under a single blanket license.
| Partition | Sources | License basis |
|---|---|---|
| `default` | Wikisource, Wikinews, Wikivoyage (PD/CC0 parts), gov.pl documents, Dziennik Ustaw, Wolne Lektury (PD), NKJP-1M, PoQuAD, ELTeC-pol, Global Voices, news (per-source) | CC0 / public domain / permissive per-source — see per-record `license` column |
| `cc-by-sa` | Wikipedia (994M tok), Wikibooks, Wikiquote, Biblioteka Nauki (SA parts) | CC-BY-SA-4.0 — share-alike applies to derivatives of the TEXT |
| `web` | HPLT v3 PL (cleaned web crawl) | see below |
**HPLT web partition — legal basis statement (important):** the HPLT project releases its *compilation*
under CC0, but explicitly does not own the underlying texts ("we do not own any of the text"). We therefore
do NOT claim CC0 on the web texts themselves. Our redistribution relies on the text-and-data-mining
framework (Directive (EU) 2019/790, art. 4 — lawful access, opt-out respected at crawl level by HPLT);
training use falls under the same TDM basis. Users redistributing or re-publishing the raw texts are
responsible for their own legal review. This mirrors the approach of the Danish Dynaword project.
Attribution for curated sources is provided per-source in the table above and per-record in the
`provenance` column.
<!-- === KONIEC SEKCJI WARTOWNIKA === -->
## How to use
```python
from datasets import load_dataset
# permissive partition only
ds = load_dataset("SlayerLab/gollem-corpus-16b-pl", "default", split="train")
# full corpus (all partitions; mind per-partition licenses)
for cfg in ("default", "cc-by-sa", "web"):
part = load_dataset("SlayerLab/gollem-corpus-16b-pl", cfg, split="train")
```
Columns (curated partitions `default`, `cc-by-sa`): `document_id`, `source_id`, `text`,
`register`, `license`, `is_share_alike`, `provenance`, `n_tokens_v32k`.
The `web` partition carries the same fields **except `n_tokens_v32k`** (its per-record V32k
count is not materialized — web tokens were counted at corpus level; see `_manifest.json`
for the web token total and per-shard sha). Load each partition via its own config
(`load_dataset("SlayerLab/gollem-corpus-16b-pl", "<default|cc-by-sa|web>")`), so the schema
difference never surfaces in a single load.
## Provenance & reproducibility
- Build pipeline (scrub → uniform web subsample → license-aware dedup → decontam →
assembly) is documented step-by-step with parameters in the build experiment log;
every shard ships a sha256 in the manifest. Published bytes ARE the verified bytes
(`verify == publish`, checked post-upload by independent re-download).
- Curated layer provenance per-source: [`SlayerLab/polish-dynaword`](https://huggingface.co/datasets/SlayerLab/polish-dynaword).
- Predecessor corpus (v2/v3, 2B): [`SlayerLab/gollem-corpus-2b-pl`](https://huggingface.co/datasets/SlayerLab/gollem-corpus-2b-pl).
- Design predecessor / scaffold: [`SlayerLab/slayer-pl-8x3b`](https://huggingface.co/datasets/SlayerLab/slayer-pl-8x3b) — same design and source selection (8-pack, ~24B-token plan); this corpus is the **materialized + cleaned** realization of that plan (adds full-scan near-dedup and the PII gate the scaffold did not have).
- Model line: [`SlayerLab/GoLLeM-110M-PL-v3`](https://huggingface.co/SlayerLab/GoLLeM-110M-PL-v3) → GoLLeM v4 (250M, this corpus).
## Acknowledgements
- PII scrubbing: Paweł Puzio ([ppuzio](https://huggingface.co/ppuzio), PR#28 in polish-dynaword)
- Independent PII gate + international-format fix: Wartownik (N-04, Slayer Kolektyw)
- License-aware dedup + per-license partitions: Monter (N-03, Slayer Kolektyw)
- Card integration & training: Hart (N-02, Slayer Kolektyw)
**Author:** Arkadiusz Słota / SlayerLab.
## Podsumowanie (PL)
Dokładny korpus pretreningowy polskiego modelu bazowego **GoLLeM v4 (250M, od zera)** —
publikowany PRZED treningiem, bajt-w-bajt ten sam zbiór (sha-tied), na którym model będzie
uczony. 16.58B unikatowych tokenów V32k: ~1.96B kuratorowanych (encyklopedia, nauka, news,
legal z capem 15%, literatura) + 14.62B oczyszczonego polskiego weba (HPLT v3). Licencje
per-rekord w trzech partycjach (permissive / CC-BY-SA / web-TDM), PII po dwustopniowym
scrubie z niezależną bramką (residual 0.0018%), dedup license-aware z pełnego skanu (retencja 95.18%),
dekontaminacja względem naszych zbiorów ewaluacyjnych.
|