Update model, config.yml, and README
Browse files- .gitattributes +1 -0
- README.md +12 -9
- config.yml +28 -0
- step_1000000.t7 +3 -0
.gitattributes
CHANGED
|
@@ -34,3 +34,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
model.t7 filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
model.t7 filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
step_1000000.t7 filter=lfs diff=lfs merge=lfs -text
|
README.md
CHANGED
|
@@ -23,7 +23,7 @@ metrics:
|
|
| 23 |
- [Evaluation](#evaluation)
|
| 24 |
- [Citation](#citation)
|
| 25 |
- [Additional Information](#additional-information)
|
| 26 |
-
|
| 27 |
---
|
| 28 |
|
| 29 |
## Model Description
|
|
@@ -34,7 +34,7 @@ This model is designed to support phoneme-based text-to-speech (TTS) systems, in
|
|
| 34 |
|
| 35 |
### Key Improvements & Features:
|
| 36 |
* **Native Galician Pipeline:** Unlike the original PL-BERT architecture which relied on English phonemizers, this model integrates the open-source linguistic tool **Cotovía** for native Galician grapheme-to-phoneme transcription and text normalization.
|
| 37 |
-
* **1:1 Alignment System:** Implements a strict sequential alignment between graphemes and phonemes, successfully handling Galician digraphs (e.g., `ll`, `rr`, `ch`, `nh`, `qu`), silent characters (e.g., silent `h`), and morphosyntactic contractions (e.g., `para` + `a`
|
| 38 |
* **Dual-Head Architecture:** The core encoder branches into two parallel prediction layers during training:
|
| 39 |
* **MLM Head (Masked Language Modeling):** Predicts the identity of masked phonemes.
|
| 40 |
* **P2G Head (Phoneme-to-Grapheme):** Predicts the corresponding grapheme for aligned feature extraction.
|
|
@@ -83,14 +83,18 @@ To force the model to prioritize prosodic clues over highly frequent phonemes, a
|
|
| 83 |
| Parameter | Value |
|
| 84 |
| :--- | :--- |
|
| 85 |
| **Model Type / Core Architecture** | ModernBERT (12 layers, 12 attention heads) |
|
|
|
|
| 86 |
| **Hidden Size** | 768 |
|
| 87 |
| **Intermediate Size (FFN)** | 2048 |
|
| 88 |
-
| **
|
| 89 |
-
| **
|
|
|
|
| 90 |
| **Precision** | Mixed Precision (`fp16`) |
|
| 91 |
| **Initial Learning Rate** | 1e-4 |
|
| 92 |
| **Scheduler Type** | `onecycle` (Cos annealing strategy, Warmup ratio: 0.1) |
|
| 93 |
| **Max Sequence Length** | 512 |
|
|
|
|
|
|
|
| 94 |
| **Replacement Probability** | 0.2 |
|
| 95 |
|
| 96 |
## Evaluation
|
|
@@ -121,12 +125,11 @@ If this model contributes to your research, please cite it as follows:
|
|
| 121 |
### Licensing
|
| 122 |
This model is licensed under the **Apache License 2.0**.
|
| 123 |
|
| 124 |
-
###
|
| 125 |
-
* **Project Oversight:** Proxecto Nós
|
| 126 |
* **Technical Development:** [Gradiant](https://www.gradiant.org/) (Centro Tecnolóxico de Telecomunicacións de Galicia)
|
| 127 |
|
| 128 |
-
##
|
| 129 |
This work is funded by the Ministerio para la Transformación Digital y de la Función Pública - Funded by EU – NextGenerationEU within the framework of the project Desarrollo de Modelos ALIA.
|
| 130 |
|
| 131 |
-
|
| 132 |
-
We would like to express our gratitude to the engineering and research teams at **Gradiant** for the technical development of this model.
|
|
|
|
| 23 |
- [Evaluation](#evaluation)
|
| 24 |
- [Citation](#citation)
|
| 25 |
- [Additional Information](#additional-information)
|
| 26 |
+
- [Funding and Acknowledgements](#funding-and-acknowledgements)
|
| 27 |
---
|
| 28 |
|
| 29 |
## Model Description
|
|
|
|
| 34 |
|
| 35 |
### Key Improvements & Features:
|
| 36 |
* **Native Galician Pipeline:** Unlike the original PL-BERT architecture which relied on English phonemizers, this model integrates the open-source linguistic tool **Cotovía** for native Galician grapheme-to-phoneme transcription and text normalization.
|
| 37 |
+
* **1:1 Alignment System:** Implements a strict sequential alignment between graphemes and phonemes, successfully handling Galician digraphs (e.g., `ll`, `rr`, `ch`, `nh`, `qu`), silent characters (e.g., silent `h`), and morphosyntactic contractions (e.g., `para` + `a` → `pra`).
|
| 38 |
* **Dual-Head Architecture:** The core encoder branches into two parallel prediction layers during training:
|
| 39 |
* **MLM Head (Masked Language Modeling):** Predicts the identity of masked phonemes.
|
| 40 |
* **P2G Head (Phoneme-to-Grapheme):** Predicts the corresponding grapheme for aligned feature extraction.
|
|
|
|
| 83 |
| Parameter | Value |
|
| 84 |
| :--- | :--- |
|
| 85 |
| **Model Type / Core Architecture** | ModernBERT (12 layers, 12 attention heads) |
|
| 86 |
+
| **Vocabulary Size** | 69 |
|
| 87 |
| **Hidden Size** | 768 |
|
| 88 |
| **Intermediate Size (FFN)** | 2048 |
|
| 89 |
+
| **Dropout** | 0.1 |
|
| 90 |
+
| **Batch Size** | 192 |
|
| 91 |
+
| **Total Steps** | 1,000,000 |
|
| 92 |
| **Precision** | Mixed Precision (`fp16`) |
|
| 93 |
| **Initial Learning Rate** | 1e-4 |
|
| 94 |
| **Scheduler Type** | `onecycle` (Cos annealing strategy, Warmup ratio: 0.1) |
|
| 95 |
| **Max Sequence Length** | 512 |
|
| 96 |
+
| **Base Word Mask Probability** | 0.15 |
|
| 97 |
+
| **Base Phoneme Mask Probability** | 0.1 |
|
| 98 |
| **Replacement Probability** | 0.2 |
|
| 99 |
|
| 100 |
## Evaluation
|
|
|
|
| 125 |
### Licensing
|
| 126 |
This model is licensed under the **Apache License 2.0**.
|
| 127 |
|
| 128 |
+
### Authors and Credits
|
| 129 |
+
* **Project Oversight:** [Proxecto Nós](https://nos.gal/gl/proxecto-nos)
|
| 130 |
* **Technical Development:** [Gradiant](https://www.gradiant.org/) (Centro Tecnolóxico de Telecomunicacións de Galicia)
|
| 131 |
|
| 132 |
+
## Funding and Acknowledgements
|
| 133 |
This work is funded by the Ministerio para la Transformación Digital y de la Función Pública - Funded by EU – NextGenerationEU within the framework of the project Desarrollo de Modelos ALIA.
|
| 134 |
|
| 135 |
+
We would like to express our gratitude to the engineering and research teams at **Gradiant** for the technical development of this model, as well as to the **Aholab Signal Processing Laboratory (HiTZ)** and the **Language Technologies Laboratory (BSC)** for their technical support and collaboration.
|
|
|
config.yml
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
mixed_precision: "fp16"
|
| 2 |
+
batch_size: 192
|
| 3 |
+
save_interval: 5000
|
| 4 |
+
log_interval: 10
|
| 5 |
+
num_process: 1 # number of GPUs
|
| 6 |
+
num_steps: 1000000
|
| 7 |
+
checkpoint_path: "step_1000000.t7"
|
| 8 |
+
dataset_params:
|
| 9 |
+
# tokenizer: "transfo-xl-wt103"
|
| 10 |
+
token_separator: " " # token used for phoneme separator (space)
|
| 11 |
+
token_mask: "M" # token used for phoneme mask (M)
|
| 12 |
+
# word_separator: 3039 # token used for word separator (<formula>)
|
| 13 |
+
# token_maps: "token_maps.pkl" # token map path
|
| 14 |
+
|
| 15 |
+
max_mel_length: 512 # max phoneme length
|
| 16 |
+
|
| 17 |
+
word_mask_prob: 0.15 # probability to mask the entire word
|
| 18 |
+
phoneme_mask_prob: 0.1 # probability to mask each phoneme
|
| 19 |
+
replace_prob: 0.2 # probablity to replace phonemes
|
| 20 |
+
|
| 21 |
+
model_params:
|
| 22 |
+
vocab_size: 69
|
| 23 |
+
hidden_size: 768
|
| 24 |
+
num_attention_heads: 12
|
| 25 |
+
intermediate_size: 2048
|
| 26 |
+
max_position_embeddings: 512
|
| 27 |
+
num_hidden_layers: 12
|
| 28 |
+
dropout: 0.1
|
step_1000000.t7
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ab0aa8f0f020613b70d8722c76823caf7e42e16e01804ffc350ae11a11d6e680
|
| 3 |
+
size 1021358416
|