Datasets:
Tasks:
Text Classification
Modalities:
Text
Formats:
parquet
Languages:
multilingual
Size:
1M - 10M
License:
upload README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: other
|
| 3 |
+
license_name: per-source
|
| 4 |
+
language:
|
| 5 |
+
- multilingual
|
| 6 |
+
size_categories:
|
| 7 |
+
- 1M<n<10M
|
| 8 |
+
task_categories:
|
| 9 |
+
- text-classification
|
| 10 |
+
tags:
|
| 11 |
+
- language-identification
|
| 12 |
+
- common-corpus
|
| 13 |
+
- african-languages
|
| 14 |
+
pretty_name: CommonLingua-Train
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# CommonLingua-Train
|
| 18 |
+
|
| 19 |
+
The training data for [PleIAs/CommonLingua](https://huggingface.co/PleIAs/CommonLingua) — a byte-level language identification model for 334 languages. **2.48 M paragraphs**, sourced exclusively from open-licensed and public-domain corpora.
|
| 20 |
+
|
| 21 |
+
| | |
|
| 22 |
+
|---|---|
|
| 23 |
+
| **Train rows** | 2,482,568 |
|
| 24 |
+
| **Val rows** | ~270 k |
|
| 25 |
+
| **Languages** | 334 (ISO 639-3) |
|
| 26 |
+
| **Sources** | 30 distinct |
|
| 27 |
+
| **Format** | Apache Parquet |
|
| 28 |
+
| **License** | Per-source (see attribution table below) |
|
| 29 |
+
|
| 30 |
+
## Files
|
| 31 |
+
|
| 32 |
+
| File | Rows | Size | Description |
|
| 33 |
+
|---|---:|---:|---|
|
| 34 |
+
| `train.parquet` | 2,482,568 | 1.31 GB | Full provenance schema (12 columns) |
|
| 35 |
+
| `val.parquet` | ~270 k | 144 MB | Validation split, same schema |
|
| 36 |
+
| `train_text_lang.parquet` | 2,482,568 | 1.14 GB | Training-time projection (`text`, `lang`) |
|
| 37 |
+
| `val_text_lang.parquet` | ~270 k | 125 MB | Same projection for val |
|
| 38 |
+
|
| 39 |
+
The provenance files are the **canonical artefact**. The two-column projections are convenience copies for users who only want to retrain a classifier and don't care about source / license / metadata; they were derived from the provenance files at the moment training launched.
|
| 40 |
+
|
| 41 |
+
## Schema (provenance files)
|
| 42 |
+
|
| 43 |
+
| Column | Type | Description |
|
| 44 |
+
|---|---|---|
|
| 45 |
+
| `text` | string | Paragraph text, raw UTF-8 (truncated to 512 bytes by the trainer) |
|
| 46 |
+
| `lang` | string | ISO 639-3 label (the training target) |
|
| 47 |
+
| `language_method` | string | How `lang` was assigned: `metadata` / `LLM` / `consensus` / `provenance` / `journal_provenance` / `manual_latex` |
|
| 48 |
+
| `source` | string | Top-level source identifier (e.g. `Wikipedia`, `Pralekha`, `VOA_Africa`) |
|
| 49 |
+
| `identifier` | string | Item-level identifier within the source (URL / DOI / shelfmark / file id), nullable |
|
| 50 |
+
| `title` | string | Item title, nullable |
|
| 51 |
+
| `collection` | string | Sub-collection within the source (e.g. `Voice of America`, `Comprehensive Edition of Tocharian Manuscripts`) |
|
| 52 |
+
| `license` | string | Per-row license string |
|
| 53 |
+
| `open_type` | string | `public_domain`, `cc_by`, `cc_by_sa`, etc. |
|
| 54 |
+
| `creator` | string | Author / organisation, nullable |
|
| 55 |
+
| `date` | string | Publication / extraction date, nullable |
|
| 56 |
+
| `section_name` | string | Sub-section within the document (e.g. Wikipedia article section), nullable |
|
| 57 |
+
|
| 58 |
+
## `language_method` values
|
| 59 |
+
|
| 60 |
+
| Method | Rows | Meaning |
|
| 61 |
+
|---|---:|---|
|
| 62 |
+
| `metadata` | 2,184,648 | Label inherited from the source's collection-level metadata (e.g. Wikipedia language code) |
|
| 63 |
+
| `LLM` | 183,071 | Label assigned (or verified) by Gemini 2.5 Flash row-by-row |
|
| 64 |
+
| `consensus` | 67,624 | Label confirmed by agreement between multiple LID models on a Wikipedia resample |
|
| 65 |
+
| `provenance` | 26,725 | Label deduced from per-row provenance metadata in the original source |
|
| 66 |
+
| `journal_provenance` | 20,000 | Label deduced from journal-name provenance (Indonesian / Malaysian academic journals) |
|
| 67 |
+
| `manual_latex` | 500 | Manually labelled `__NOT_LANGUAGE__` / LaTeX-source rows |
|
| 68 |
+
|
| 69 |
+
## Source attribution
|
| 70 |
+
|
| 71 |
+
| Source | Rows | License | Notes |
|
| 72 |
+
|---|---:|---|---|
|
| 73 |
+
| Wikipedia (raw) | 2,093,518 | CC-BY-SA 4.0 | Per-article text, sampled across language editions |
|
| 74 |
+
| Wikipedia_Gemini_verified | 93,988 | CC-BY-SA 4.0 | Targeted resample with Gemini per-row verification of contaminated classes |
|
| 75 |
+
| Wikipedia_resample_Gemini | 67,731 | CC-BY-SA 4.0 | Class-balanced resample, Gemini-verified |
|
| 76 |
+
| Wikipedia_resample | 67,624 | CC-BY-SA 4.0 | Class-balanced resample (consensus method) |
|
| 77 |
+
| Pralekha | 27,042 | CC-BY-SA 4.0 | Indic-language paragraphs |
|
| 78 |
+
| VOA Africa | 24,341 | Public Domain (US Federal) | Voice of America Africa-language broadcasts |
|
| 79 |
+
| Common Corpus 1 v3 adversarial | 17,953 | per-source (CC) | Hand-picked adversarial paragraphs from Common Corpus |
|
| 80 |
+
| Cultural Heritage | 16,381 | Public Domain / per-collection | Digitised cultural-heritage archives |
|
| 81 |
+
| Perseus PROIEL | 11,638 | CC-BY-SA 4.0 | Classical languages (Latin, Ancient Greek, Old Church Slavonic, Gothic, …) |
|
| 82 |
+
| OpenAlex (Malaysian journals) | 10,000 | per-journal (mostly CC-BY) | Indonesian/Malay disambiguation data, journal-name provenance |
|
| 83 |
+
| OpenAlex (Indonesian journals) | 10,000 | per-journal (mostly CC-BY) | Companion to the above |
|
| 84 |
+
| OpenPecha / Ambuda | 8,317 | Public Domain / CC | Tibetan, Sanskrit |
|
| 85 |
+
| Common Corpus 1 Haiku v5 | 7,497 | per-source (CC) | Haiku-validated minority-language paragraphs |
|
| 86 |
+
| OpenAlex (African academic) | 6,193 | per-journal | African academic publishing, English-heavy filtered out |
|
| 87 |
+
| WaxalNLP ASR | 5,373 | CC-BY-SA 4.0 | West African ASR transcripts (residual after extensive cleanup — see History below) |
|
| 88 |
+
| eBible (Public Domain) | 4,877 | Public Domain | Bible translations, public-domain editions only |
|
| 89 |
+
| OpenAlex English | 2,705 | per-journal | English baseline from academic publishing |
|
| 90 |
+
| Project Ben-Yehuda (Hebrew) | 2,701 | Public Domain | Hebrew literature corpus |
|
| 91 |
+
| French Research HAL | 1,575 | per-license | French academic abstracts |
|
| 92 |
+
| Sefaria Tanakh | 947 | Public Domain | Hebrew religious corpus |
|
| 93 |
+
| Krike-Krake (Barat 1977) | 744 | Public Domain | Tachelhit/Berber documentation |
|
| 94 |
+
| OpenAlex LaTeX | 500 | n/a | Manually labelled `__NOT_LANGUAGE__` (LaTeX source) |
|
| 95 |
+
| US-PD-Newspapers | 348 | Public Domain | Long-tail language samples |
|
| 96 |
+
| Common Corpus Adversarial | 243 | per-source | |
|
| 97 |
+
| Geste | 202 | Public Domain | Old French |
|
| 98 |
+
| English-PD | 108 | Public Domain | |
|
| 99 |
+
| German-PD | 8 | Public Domain | |
|
| 100 |
+
| French-PD-Newspapers | 6 | Public Domain | |
|
| 101 |
+
| French-PD-Books | 6 | Public Domain | |
|
| 102 |
+
| Italian-PD | 2 | Public Domain | |
|
| 103 |
+
|
| 104 |
+
The single largest source is Wikipedia (≈ 93 % of rows when raw + resample variants are summed). The long tail (~7 %) is what makes coverage of low-resource and ancient languages possible.
|
| 105 |
+
|
| 106 |
+
## Reproducing the model
|
| 107 |
+
|
| 108 |
+
```python
|
| 109 |
+
import pyarrow.parquet as pq
|
| 110 |
+
train = pq.read_table("train.parquet", columns=["text", "lang"])
|
| 111 |
+
val = pq.read_table("val.parquet", columns=["text", "lang"])
|
| 112 |
+
# train ByteHybrid using github.com/PleIAs/bytehybrid-lid/train_lid.py
|
| 113 |
+
```
|
| 114 |
+
|
| 115 |
+
## License & responsible use
|
| 116 |
+
|
| 117 |
+
CommonLingua-Train aggregates 30 sources whose licenses range from **public domain** (most newspaper / heritage / Bible / classical-philology corpora) to **CC-BY-SA 4.0** (Wikipedia and most aggregated corpora). Some OpenAlex rows inherit the journal's per-publication license — most are CC-BY but please consult the `license` and `open_type` columns of each row before redistributing.
|
| 118 |
+
|
| 119 |
+
If you redistribute derived versions, please keep the per-row `license`, `creator`, and `identifier` columns intact for downstream attribution.
|
| 120 |
+
|
| 121 |
+
## History
|
| 122 |
+
|
| 123 |
+
This dataset is the v7.2.1 iteration. Earlier iterations (v6.3.x) carried collection-level labels at face value, which led to mislabelled African-language data (Wax̌alNLP collections under `kik`/`mas`/`sog`/etc.). The v7 line dropped those classes outright and re-validated the rest with Gemini 2.5 Flash. The current dataset retains only ~5 k rows from the original WaxalNLP collection, after that cleanup.
|
| 124 |
+
|
| 125 |
+
## Citation
|
| 126 |
+
|
| 127 |
+
```bibtex
|
| 128 |
+
@misc{commonlingua-train,
|
| 129 |
+
author = {{PleIAs}},
|
| 130 |
+
title = {CommonLingua-Train: A multi-source open dataset for byte-level language identification},
|
| 131 |
+
year = {2026},
|
| 132 |
+
url = {https://huggingface.co/datasets/PleIAs/CommonLingua-Train}
|
| 133 |
+
}
|
| 134 |
+
```
|