--- language: - eu license: cc-by-sa-4.0 task_categories: - text-to-speech tags: - basque - phonemization - IPA - wikipedia pretty_name: Basque Wikipedia Phonemized Corpus (Text + IPA phonemes) size_categories: - 1M`, ``, etc.) - Replaces `` blocks with `formula_N` placeholders - Outputs plain paragraphs, one per line ### Step 2 — Cleaning The extracted text was further cleaned with the following filters and transformations: **Sentence-level filters (removal):** - Sentences shorter than **100 characters** - Sentences containing **double quotes** (`"`) - Sentences containing **chess notation** (`e4`, `c4`) - Sentences containing **HTML-like symbols** (`<`, `>`) - Sentences containing the string **`formula kimikoa`** (Basque for "chemical formula") - Sentences containing **`formula_N`** placeholders (Wikipedia math markup artifacts) - Sentences containing **`|`** (MediaWiki pipe/table syntax artifacts) - Sentences consisting **only of digits and punctuation** **Text normalization transformations:** - `"K. a."` → `"K.a."` and `"K. o."` → `"K.o."` (Basque grammatical abbreviations) - Dots after single uppercase initials removed (e.g. `A.` → `A`) - Content inside parentheses/brackets removed - All bracket characters `[]<>{}()` removed - Hyphens between words removed (e.g. `behaketa-saioa` → `behaketa saioa`), preserving numeric ranges - Quotes and apostrophes (`"`, `'`, `"`, `"`, `'`, `'`) removed - URLs and email addresses removed - Non-printable characters removed - Whitespace normalized (multiple spaces → single space) - Consecutive or redundant punctuation cleaned up (e.g. `,,` → `,`, `..` → `.`) - Trailing punctuation normalized to a single `.` ### Step 3 — Normalization + Phonemization Each cleaned sentence was first **normalized** and then **phonemized** using **[ahoNT](https://github.com/hitz-zentroa/ahoNT)**, a Basque text processing and phonemization tool developed at HiTZ Zentroa / AhoLab. **Normalization** handles: - Number expansion (e.g. `42` → spoken Basque word form) - Abbreviation resolution - Other text-to-speech pre-processing rules specific to Basque **Phonemization** then: - Converts each normalized word to its phoneme sequence - Outputs IPA symbols with stress markers and multicharacter affricates preserved - Attaches punctuation marks to the preceding word --- ## Usage ```python from datasets import load_dataset ds = load_dataset("HiTZ/wikipedia_basque_ipa", split="train") for example in ds.select(range(5)): print(example["text"]) print(example["phonemes"]) print() ``` **Split phonemes into individual word tokens:** ```python for example in ds.select(range(5)): tokens = example["phonemes"].split() print(tokens) # e.g. ["'istoɾiako", "le'enenɡo", "ʂi'entʂia", "iʂ'an", "da", "astr'onomia.", ...] ``` **Use as a G2P training corpus:** ```python for example in ds.select(range(5)): words = example["text"].split() phonemes = example["phonemes"].split() # Note: words and phoneme tokens are aligned one-to-one # (punctuation is attached to the preceding phoneme token) ``` --- ## License The dataset is derived from Basque Wikipedia, which is released under the [Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)](https://creativecommons.org/licenses/by-sa/4.0/) license. --- ## Citation If you use this dataset, please cite the Basque Wikipedia and acknowledge the phonemization pipeline developed at AhoLab (University of the Basque Country). ## Related Resources - **[ahoNT](https://github.com/hitz-zentroa/ahoNT)** — Basque text normalization and phonemization tool - **[WikiExtractor](https://github.com/attardi/wikiextractor)** - Python script that extracts and cleans text from a Wikipedia database backup dump