Upload README.md with huggingface_hub
Browse files
README.md
CHANGED
|
@@ -2,6 +2,7 @@
|
|
| 2 |
license: mit
|
| 3 |
language:
|
| 4 |
- en
|
|
|
|
| 5 |
tags:
|
| 6 |
- g2p
|
| 7 |
- grapheme-to-phoneme
|
|
@@ -21,13 +22,15 @@ benchmarks. These are static test fixtures, not runtime model assets.
|
|
| 21 |
| File | Language | Entries | Description |
|
| 22 |
|------|----------|---------|--------------|
|
| 23 |
| `g2p/en_us/test.tsv` | English (US) | 5000 | Held-out word-IPA pairs for CER benchmarking |
|
|
|
|
| 24 |
| `g2p/kokoro_vocab.json` | n/a | 114 | Kokoro phoneme vocabulary (char → token ID) used by the normalizer correctness benchmark |
|
| 25 |
| `g2p/en_us/kokoro_normalizer_ref.tsv` | English (US) | 71 | Raw IPA → expected (`en_us`, Kokoro) normalized IPA + phoneme IDs, for `IpaNormalizer` regression testing |
|
|
|
|
| 26 |
|
| 27 |
## Format
|
| 28 |
|
| 29 |
-
`g2p/en_us/test.tsv`: tab-separated, two columns,
|
| 30 |
-
alphabetically:
|
| 31 |
|
| 32 |
```
|
| 33 |
word<TAB>IPA
|
|
@@ -39,8 +42,8 @@ Example:
|
|
| 39 |
abandons əbˈændənz
|
| 40 |
```
|
| 41 |
|
| 42 |
-
`g2p/en_us/kokoro_normalizer_ref.tsv`
|
| 43 |
-
header row:
|
| 44 |
|
| 45 |
```
|
| 46 |
raw_ipa<TAB>expected_normalized_ipa<TAB>expected_phoneme_ids
|
|
@@ -66,6 +69,13 @@ Pronouncing Dictionary (https://github.com/cmusphinx/cmudict, BSD-style
|
|
| 66 |
license). These entries are held out and never seen by the G2P engine
|
| 67 |
during lexicon construction.
|
| 68 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 69 |
`g2p/kokoro_vocab.json` is copied verbatim from Moonshine Voice's
|
| 70 |
`core/moonshine-tts/data/kokoro/config.json` `vocab` object (114 entries;
|
| 71 |
the HuggingFace `onnx-community/Kokoro-82M-v1.0-ONNX` export used by Crane's
|
|
@@ -85,6 +95,22 @@ pairs and the vocab-filter/whitespace-collapse logic are simple enough that
|
|
| 85 |
this port only needs `str.replace`, `str.strip`, and Python's
|
| 86 |
`unicodedata.normalize("NFC", ...)`.
|
| 87 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 88 |
## License
|
| 89 |
|
| 90 |
Both upstream sources use permissive, MIT-compatible licenses:
|
|
|
|
| 2 |
license: mit
|
| 3 |
language:
|
| 4 |
- en
|
| 5 |
+
- de
|
| 6 |
tags:
|
| 7 |
- g2p
|
| 8 |
- grapheme-to-phoneme
|
|
|
|
| 22 |
| File | Language | Entries | Description |
|
| 23 |
|------|----------|---------|--------------|
|
| 24 |
| `g2p/en_us/test.tsv` | English (US) | 5000 | Held-out word-IPA pairs for CER benchmarking |
|
| 25 |
+
| `g2p/de_de/test.tsv` | German | 5000 | Held-out word-IPA pairs for CER benchmarking |
|
| 26 |
| `g2p/kokoro_vocab.json` | n/a | 114 | Kokoro phoneme vocabulary (char → token ID) used by the normalizer correctness benchmark |
|
| 27 |
| `g2p/en_us/kokoro_normalizer_ref.tsv` | English (US) | 71 | Raw IPA → expected (`en_us`, Kokoro) normalized IPA + phoneme IDs, for `IpaNormalizer` regression testing |
|
| 28 |
+
| `g2p/de_de/kokoro_normalizer_ref.tsv` | German | 32 | Raw IPA → expected (`de`, Kokoro) normalized IPA + phoneme IDs, for `IpaNormalizer` regression testing |
|
| 29 |
|
| 30 |
## Format
|
| 31 |
|
| 32 |
+
`g2p/en_us/test.tsv` and `g2p/de_de/test.tsv`: tab-separated, two columns,
|
| 33 |
+
UTF-8, no header row, sorted alphabetically:
|
| 34 |
|
| 35 |
```
|
| 36 |
word<TAB>IPA
|
|
|
|
| 42 |
abandons əbˈændənz
|
| 43 |
```
|
| 44 |
|
| 45 |
+
`g2p/en_us/kokoro_normalizer_ref.tsv` and `g2p/de_de/kokoro_normalizer_ref.tsv`:
|
| 46 |
+
tab-separated, three columns, UTF-8, no header row:
|
| 47 |
|
| 48 |
```
|
| 49 |
raw_ipa<TAB>expected_normalized_ipa<TAB>expected_phoneme_ids
|
|
|
|
| 69 |
license). These entries are held out and never seen by the G2P engine
|
| 70 |
during lexicon construction.
|
| 71 |
|
| 72 |
+
`g2p/de_de/test.tsv` is a 5000-entry random sample (seed 42, no replacement,
|
| 73 |
+
one pronunciation per word) from Moonshine Voice's German IPA lexicon
|
| 74 |
+
(MIT-licensed multilingual IPA dictionary data), deduplicated to unique
|
| 75 |
+
words before sampling since the source lexicon has multiple pronunciation
|
| 76 |
+
rows for some words. These entries are held out and never seen by the G2P
|
| 77 |
+
engine during lexicon construction.
|
| 78 |
+
|
| 79 |
`g2p/kokoro_vocab.json` is copied verbatim from Moonshine Voice's
|
| 80 |
`core/moonshine-tts/data/kokoro/config.json` `vocab` object (114 entries;
|
| 81 |
the HuggingFace `onnx-community/Kokoro-82M-v1.0-ONNX` export used by Crane's
|
|
|
|
| 95 |
this port only needs `str.replace`, `str.strip`, and Python's
|
| 96 |
`unicodedata.normalize("NFC", ...)`.
|
| 97 |
|
| 98 |
+
`g2p/de_de/kokoro_normalizer_ref.tsv` combines 6 realistic German lexicon
|
| 99 |
+
entries sampled from `g2p/de_de/test.tsv` (single words plus one 2-word
|
| 100 |
+
combination, chosen to exercise both plain lexicon passthrough and the
|
| 101 |
+
affricate/geminate/`ʏ` replacements together with dropped combining
|
| 102 |
+
diacritics) with 26 hand-crafted edge cases (each
|
| 103 |
+
`DE_EXTRA_KOKORO_REPLACEMENTS` pair in isolation, shared
|
| 104 |
+
affricate/diphthong passthrough under `"de"`, German phonemes with no
|
| 105 |
+
replacement needed, syllabic-consonant and non-syllabic-offglide diacritic
|
| 106 |
+
dropping, unknown-codepoint dropping, and whitespace handling). Expected
|
| 107 |
+
output was hand-derived by applying
|
| 108 |
+
`SHARED_KOKORO_REPLACEMENTS`/`DE_EXTRA_KOKORO_REPLACEMENTS` and the
|
| 109 |
+
vocab-filter/whitespace-collapse algorithm against `g2p/kokoro_vocab.json`
|
| 110 |
+
directly, then cross-checked by running the real `IpaNormalizer` and
|
| 111 |
+
confirming an exact match — not authored by trusting `normalize()`'s own
|
| 112 |
+
output as ground truth.
|
| 113 |
+
|
| 114 |
## License
|
| 115 |
|
| 116 |
Both upstream sources use permissive, MIT-compatible licenses:
|