polish-dynaword / README.md
kacperwikiel's picture
Clarify stable releases versus validation artifacts
b2c03df
|
Raw
History Blame
17.4 kB
---
license: cc-by-sa-4.0
language:
- pl
pretty_name: Polish DynaWord
task_categories:
- text-generation
size_categories:
- 1M<n<10M
tags:
- polish
- pretraining
- dynaword
---
# Polish DynaWord
A continuously developed, **openly-licensed**, human-text Polish corpus — a Polish
edition in the [Dynaword](https://huggingface.co/datasets/danish-foundation-models/danish-dynaword)
family (Enevoldsen et al., [arXiv:2508.02271](https://arxiv.org/abs/2508.02271)).
> **v0.2.3 stable** · 2,710,974 documents · **6.88B tokens**
> (6,881,277,362 tiktoken cl100k-proxy tokens) · 16 sources
> Updated: **2026-07-26**
> **v0.3-dev experimental track** · quality/diversity workflow, source-gate
> validation and candidate-data audits. This is development work, not a released
> corpus version, and it does not replace the v0.2.3 stable parquets.
> **Europeana validation artifact (2026-07-10)** · first reproducible
> direct-ingestion shard:
> 1,000 API records → 810 quality-gated parquet documents, each preserving
> per-record rights and creator metadata. Stored separately under
> the legacy path `previews/v0.3.1/europeana.parquet`; it is not a release of the
> full dataset and does not alter stable totals.
## Releases
### Stable releases
| version | status | documents | tokens | notes |
|---|---|---:|---:|---|
| `v0.2.3` | stable release | 2,710,974 | 6.88B | Adds community-contributed HPLT v3 Polish WDS 10+9, Global Voices Polish and the NKJP manually annotated 1M-word subcorpus. |
| `v0.2.2` | previous stable | 2,579,963 | 6.36B | Added community-contributed `govpl`: 88,190 docs / 80.7M tokens fetched directly across 133 ministry/agency subsites. |
| `v0.2.1` | previous stable | 2,491,773 | 6.28B | 12-source stable corpus with `license` and `author` metadata columns; adds `1000_novels`. |
| `v0.2.0` | previous stable | 2,490,773 | 6.22B | Provenance-first corpus from 11 open/official sources. |
![Stable dataset size by version](artifacts/dataset_size_by_version.png)
### Development and validation artifacts
| name | type | scope | notes |
|---|---|---|---|
| `v0.3-dev` | experimental development track | workflow and candidate audits | Quality remix, legal-source caps, source QA, deduplication and direct-upstream ingestion. Not a corpus release. |
| `Europeana validation artifact 2026-07-10` | reproducible sample | 810 documents / 140,042 tokens | Stored at the legacy path `previews/v0.3.1/europeana.parquet`; preserves per-record rights and creator metadata. Not a corpus release. |
### Version details
#### v0.2.3 — current stable
Community expansion release. Adds `european_hplt_v3_pl` from
[PR #5](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/5)
and `global_voices` from
[PR #7](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/7),
plus `nkjp1m` from
[PR #8](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/8).
The complete 16-source release contains **2,710,974 documents /
6,881,277,362 cl100k-proxy tokens**, summed from the released per-source parquet
statistics.
#### v0.2.2 — previous stable
Added `govpl` from
[PR #9](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/9):
88,190 Polish government press releases collected directly from 133 gov.pl
ministry and agency subsites. Result: 13 sources, 2,579,963 documents and
6.36B proxy tokens.
#### v0.2.1 — previous stable
Introduced the canonical eight-column release schema:
`id, text, source, added, created, token_count, license, author`. Added the
CC-BY-4.0 `1000_novels` source from
[PR #1](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/1)
and recomputed all release statistics from parquet files.
#### v0.2.0 — initial stable corpus
The provenance-first baseline: 11 reviewed open or official sources,
2,490,773 documents and 6.22B proxy tokens. This version established the
per-source datasheet, traceable-license and exclusion-policy workflow.
#### v0.3-dev — experimental quality workflow
Candidate-only work on a better-balanced training mixture: legal-source caps,
temperature sampling, source QA, deduplication and direct-upstream ingestion.
It is a workflow and validation track, not a replacement for the stable corpus.
#### Europeana validation artifact — 2026-07-10
A separate reproducible 810-document Europeana sample preserving per-record
rights and creator metadata. It validates the direct-ingestion contract without
changing stable-release totals. `v0.3.1-preview` remains only as the legacy
storage-path label.
## What this dataset contributes
The raw texts come from existing open corpora (redistributed via SpeakLeash and,
where applicable, fetched from upstream). **The value added here is the curation,
not the bytes**, following the Dynaword methodology:
1. **License review per source** — each source vetted for an *openly-licensed,
traceable* legal basis (documented in its datasheet); sources that fail the
review are **excluded with a stated reason** (see table below), not silently
kept. This is the core editorial work.
2. **Filtering & normalization** — minimal, reproducible gates (short-doc,
non-Polish, exact cross-source dedup, OCR garble) applied uniformly to one
clean schema: `id, text, source, added, created, token_count, license, author`.
3. **Documentation** — a datasheet per source (Gebru et al. 2021) + this card,
so provenance and licensing are auditable rather than assumed.
4. **Reproducibility & versioning**`src/` rebuilds the corpus from sources;
new sources and removals are tracked in the CHANGELOG.
Credit for the underlying texts belongs to the upstream sources and to SpeakLeash
as the redistributing aggregator; this release does not claim ownership of them
(see Disclaimer).
## Contributors
| contributor | contribution | release / PR |
|---|---|---|
| [Kacper Wikieł](https://huggingface.co/kacperwikiel) | Project maintainer; corpus curation, source and license review, release engineering, documentation, validation and reproducible build workflow. | all releases |
| [Bart Kobyliński](https://huggingface.co/bartoszkobylinski1) | Added `1000_novels`; expanded Biblioteka Nauki and Europeana ingestion with per-document license and author metadata. | `v0.2.1`, [PR #1](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/1) |
| [Paweł Puzio](https://huggingface.co/ppuzio) | Built `govpl`: subsite discovery, direct ingestion pipeline, dataset artifact, contract tests and documentation. | `v0.2.2`, [PR #9](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/9) |
| [Arkadiusz Słota](https://huggingface.co/Maggio33) | Built `european_hplt_v3_pl`: HPLT v3 WDS 10+9 cleaning pipeline, 110,590-document artifact, validation and documentation. | `v0.2.3`, [PR #5](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/5) |
| [Dawid Majewski](https://huggingface.co/dawidmajewski) | Added the reviewed Global Voices Polish corpus with per-document author attribution and documentation. | `v0.2.3`, [PR #7](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/7) |
| [1am](https://huggingface.co/1am) | Added `nkjp1m`: the manually annotated 1-million-word NKJP subcorpus, direct fetch/build pipeline, source documentation and release artifact. | `v0.2.3`, [PR #8](https://huggingface.co/datasets/SlayerLab/polish-dynaword/discussions/8) |
Contributions are credited when they add a verifiable dataset artifact, pipeline,
validation, documentation or release work. A merged discussion with no resulting
files is not listed as a data contribution.
## Guiding principles
1. **Open & traceable licensing** — every source is *openly licensed* with a documented
legal basis (see each datasheet's "traceable basis"), not a vague "public domain".
2. **Reproducibility**`src/build_dynaword.py` rebuilds the corpus from sources.
3. **Documented** — a datasheet per source under `data/<source>/`.
4. **Extensibility** — versioned; new sources via PR.
## Sources
| source | description | license | documents | tokens |
|---|---|---|---:|---:|
| [eurlex](data/eurlex/eurlex.md) | EUR-Lex (EU legal acts, Polish) | `CC-BY-4.0` | 243,060 | 2,378.1M |
| [parliamentary](data/parliamentary/parliamentary.md) | Polish Parliamentary Corpus (Sejm/Senat) | `public-domain (official documents)` | 324,622 | 1,646.8M |
| [wikisource](data/wikisource/wikisource.md) | Polish Wikisource | `CC-BY-SA-3.0` | 632,005 | 801.9M |
| [wikipedia](data/wikipedia/wikipedia.md) | Polish Wikipedia | `CC-BY-SA-3.0` | 1,171,897 | 707.2M |
| [european_hplt_v3_pl](data/european_hplt_v3_pl/european_hplt_v3_pl.md) | HPLT v3.0 Polish — top WDS quality bins 10+9 | `CC0-1.0` | 110,590 | 512.4M |
| [dziennik_ustaw](data/dziennik_ustaw/dziennik_ustaw.md) | Dziennik Ustaw + Monitor Polski (Polish primary legislation) | `public-domain (official documents)` | 35,442 | 486.1M |
| [wolne_lektury](data/wolne_lektury/wolne_lektury.md) | Wolne Lektury (school readings) | `CC-BY-SA-4.0 / Wolna Sztuka 1.3` | 6,141 | 103.0M |
| [govpl](data/govpl/govpl.md) | gov.pl — Polish government press releases | `CC-BY-SA-4.0` | 88,190 | 80.7M |
| [1000_novels](data/1000_novels/1000_novels.md) | 1000 Novels Corpus (CLARIN-PL) | `CC-BY-4.0` | 1,000 | 60.5M |
| [wikiquote](data/wikiquote/wikiquote.md) | Polish Wikiquote (quotations) | `CC-BY-SA-3.0` | 30,363 | 31.9M |
| [eltec_pol](data/eltec_pol/eltec_pol.md) | ELTeC-pol (European Literary Text Collection, Polish) | `CC-BY-4.0` | 100 | 21.5M |
| [wikivoyage](data/wikivoyage/wikivoyage.md) | Polish Wikivoyage (travel guides) | `CC-BY-SA-3.0` | 13,645 | 17.1M |
| [wikibooks](data/wikibooks/wikibooks.md) | Polish Wikibooks (open textbooks) | `CC-BY-SA-3.0` | 9,112 | 15.6M |
| [wikinews](data/wikinews/wikinews.md) | Polish Wikinews | `CC-BY-2.5` | 24,386 | 12.1M |
| [global_voices](data/global_voices/global_voices.md) | Global Voices Polish | `CC-BY-3.0` | 2,040 | 3.7M |
| [nkjp1m](data/nkjp1m/nkjp1m.md) | NKJP manually annotated 1-million-word subcorpus | `CC-BY` | 18,381 | 2.6M |
| **total** | | | **2,710,974** | **6,881.3M** |
## Method
Only **human-authored** text — no synthetic, machine-translated, or auto-transcribed
data. Gates are intentionally minimal (drop short docs, non-Polish, exact duplicates,
OCR garble); heavy quality filtering and mix-weighting are left to downstream training.
Evaluation-set decontamination is applied/marked separately. Schema:
`id, text, source, added, created, token_count, license, author`. The `license`
and `author` columns are per-document metadata when upstream exposes them; older
sources use the source-level license and an empty author field.
## v0.3 quality roadmap and current status
The v0.2.x raw corpus is intentionally provenance-first, but its token mix is too
heavy in legal/parliamentary language for natural general pretraining. The v0.3
workflow therefore separates **source inclusion** from **training mix**:
- cap `eurlex + parliamentary + dziennik_ustaw` to roughly **10-20%** of training
tokens combined;
- use source-level temperature sampling (`sqrt`, alpha `0.5`) instead of raw
token-proportional sampling;
- add traceably licensed contemporary/natural Polish: open web, academic prose,
cultural heritage text, guides, technical documentation/blogs, Q&A, and
dialogue/instruction data;
- run aggressive exact, normalized, and near-duplicate removal;
- reserve the final **5-15%** of training for higher-quality sources rather than
the largest sources;
- evaluate per-source perplexity and style contamination, not only global loss.
Current v0.3 source-ingestion status:
- `biblioteka_nauki`: prepared in the source registry as a direct-upstream
rebuild target with per-document license and author metadata. A live probe
currently returns HTTP 500 and zero records, so it is **not included** in
v0.2.1 or the v0.3 preview candidate data.
- `europeana`: prepared in the source registry as a direct-upstream rebuild
target with per-record rights statements and creator metadata. A 200-record
live direct-rebuild audit found 197 Public Domain Mark records and three
CC-BY-SA-4.0 records; all passed the blocking schema, license, duplicate and
evaluation-overlap gates. It remains candidate-only until a complete rebuild,
date split, and legal review are complete. Raw SpeakLeash Europeana remains
excluded.
- Local SpeakLeash shard audit: 12 reviewed source shards were sampled directly
from the live `.jsonl.zst` inputs and passed the blocking gates; four shards
are explicitly excluded (`open_subtitles_corpus`, raw Europeana,
`1000_novels_corpus_CLARIN-PL`, `project_gutenberg_pl_corpus`) and two talk
shards remain on hold pending a separate source policy. The audit mechanism is
aligned with [slayer-dsbench](https://github.com/slayerlabs/slayer-dsbench).
- Europeana release policy: split conservatively at pre-1929 records for
US-sensitive downstream reuse, and keep later/unknown records separately
labeled or held until legal review.
- `european_hplt_v3_pl`: WDS bins 10+9 are included in v0.2.3 after contract
validation. HPLT packaging is CC0, while underlying crawled web documents can
carry independent rights; downstream near-dedup and web-content review remain
recommended before training.
Current review artifacts:
- `configs/source_candidates_v0_3.json` — candidate decisions and license policy.
- `artifacts/source_license_review_v0_3.md` — source-by-source license review.
- `artifacts/source_candidate_audit_v0_3.md` — generated Hugging Face metadata audit.
- `artifacts/training_mix_v0_3.md` — example 1B-token training mix with legal sources capped at 15%.
- `artifacts/bartek_source_ingestion_plan_2026-07-02.md` — PR contract for
Biblioteka Nauki and Europeana ingestion.
## Excluded sources (transparency)
Sources we reviewed and **deliberately left out** — part of the curation:
| source | reason |
|---|---|
| `open_subtitles_corpus` | Derivative of copyrighted film/TV dialogue; OpenSubtitles uploads largely unlicensed. Same copyright lesson as Danish Gigaword's OpenSubtitles (paper 2508.02271). Not openly licensed. |
| `europeana_eu_pl_corpus_raw_speakleash` | Aggregated items with mixed per-record rights (PD / CC-BY-NC / rights-reserved). The raw SpeakLeash redistribution is excluded; only a direct rebuild preserving per-record rights metadata may be included. |
| `project_gutenberg_pl_corpus` | Only 31 PL books (4.3MB) — PG is ~99% English; Polish PD literature already covered by wolne_lektury + wikisource (so near-redundant after dedup). Dropped to avoid the PD-in-EU per-work check (PG claims PD-in-US only) for negligible token gain. |
## Personal & sensitive data
This corpus contains **only** text that its upstream sources already published
under open licenses or as official public-domain record. It therefore includes
names and statements of **public figures acting in a public capacity** — e.g.
parliamentary speakers (PPC), authorities named in legal acts (EUR-Lex), and
people described in encyclopedic articles (Wikipedia/Wikisource). No private,
non-public personal data was collected or added. If you are a data subject and
want content concerning you removed, contact **k.wikiel@gmail.com** — it will be dropped
from the next version (see retroactive-removal policy below).
## Disclaimer & legal
- **Provenance in good faith.** Per-source licenses are reproduced *as documented
by the upstream sources and by SpeakLeash* (the intermediate aggregator), to the
best of our knowledge. We make no independent legal warranty about the copyright
status of any individual document.
- **No ownership claim.** This release is a *curated, license-reviewed, documented
aggregation*. We claim no ownership of the underlying texts; rights remain with
the original authors/rightsholders under their respective licenses.
- **Provided "as is"**, without warranty of any kind, express or implied. This is
not legal advice.
- **Your compliance is yours.** Downstream users must satisfy each upstream
license themselves — in particular **CC-BY-SA-4.0 attribution and share-alike**
for derivatives of this dataset, and attribution to the upstream sources and to
SpeakLeash.
- **Notice-and-takedown.** Any source or rightsholder raising a substantiated
objection can have material removed: contact **k.wikiel@gmail.com**; it is dropped from
the next version and recorded in the CHANGELOG. Removal is retroactive
going-forward (prior immutable snapshots/commits may persist).
## License & attribution
Released under **CC-BY-SA-4.0** (copyleft inherited from CC-BY-SA sources such as
Wikipedia/Wikisource/Wolne Lektury). Attribution due to each upstream (see datasheets)
and to **SpeakLeash** as the intermediate aggregator. Retroactive-removal policy: a
source that raises an objection is dropped from subsequent versions, recorded in the
CHANGELOG.
## Reproduce
```bash
python3 src/build_dynaword.py --all --speakleash-dir <speakleash_zst_dir> --out .
python3 src/make_docs.py
```
## Results
The corpus-level phrase-frequency recount for the 16-source v0.2.3 release is pending. The previous 15-source tables were removed to avoid presenting stale analysis as current. Release document/token totals above are summed from the validated per-source parquet statistics.