Upload README.md with huggingface_hub

#2
by Mwau - opened
Files changed (1) hide show
  1. README.md +71 -0
README.md ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - sw
4
+ license: cc-by-nc-4.0
5
+ base_model: facebook/mms-tts-swh
6
+ tags:
7
+ - text-to-speech
8
+ - tts
9
+ - vits
10
+ - swahili
11
+ - mms
12
+ datasets:
13
+ - google/WaxalNLP
14
+ pipeline_tag: text-to-speech
15
+ ---
16
+
17
+ # TTSModel — Swahili TTS
18
+
19
+ A Swahili text-to-speech model, finetuned from Meta's [MMS-TTS Swahili](https://huggingface.co/facebook/mms-tts-swh) checkpoint on the `swa_tts` split of [google/WaxalNLP](https://huggingface.co/datasets/google/WaxalNLP), using the [VITS finetuning recipe](https://github.com/ylacombe/finetune-hf-vits) from `ylacombe/finetune-hf-vits`. Developed by the [Maseno Centre for Applied AI (MCAAI)](https://mcaai.maseno.ac.ke/).
20
+
21
+ ## Model details
22
+
23
+ - **Base model:** `facebook/mms-tts-swh` (Meta's Massively Multilingual Speech TTS, Swahili)
24
+ - **Architecture:** VITS (single-speaker)
25
+ - **Training data:** [google/WaxalNLP](https://huggingface.co/datasets/google/WaxalNLP), `swa_tts` config — 1,387 train utterances (805 after duration/length filtering), single Swahili speaker, 16kHz audio, sourced via the Loud & Clear initiative.
26
+ - **Training checkpoint:** step 4,500 / 20,200 planned steps (~22 epochs of ~805 examples)
27
+ - **Sample rate:** 16,000 Hz
28
+ - **Language:** Swahili (`swh` / ISO 639-3)
29
+
30
+ ## Training configuration
31
+
32
+ | Setting | Value |
33
+ |---|---|
34
+ | Learning rate | 2e-5 |
35
+ | Batch size | 8 |
36
+ | Precision | fp16 |
37
+ | Max clip duration | 20s |
38
+ | Min clip duration | 0.5s |
39
+ | Loss weights | mel=35, kl=1.5, disc=3, gen/fmaps/duration=1 |
40
+
41
+ Training used the `finetune-hf-vits` recipe with `transformers==4.35.1`, `datasets==2.14.7`, `accelerate==0.24.1`, `numpy<2.0`.
42
+
43
+ ## Usage
44
+
45
+ ```python
46
+ import numpy as np
47
+ from transformers import pipeline
48
+ import scipy.io.wavfile
49
+
50
+ synthesiser = pipeline("text-to-speech", model="MCAA1-MSU/TTSModel")
51
+ speech = synthesiser("Habari yako, karibu Kenya.")
52
+
53
+ audio = np.squeeze(speech["audio"])
54
+ scipy.io.wavfile.write("output.wav", rate=speech["sampling_rate"], data=audio)
55
+ ```
56
+
57
+ Verified loading cleanly with `transformers` `pipeline("text-to-speech", ...)` — no missing/unexpected weight warnings on load.
58
+
59
+ ## Intended use
60
+
61
+ Research and experimentation with Swahili TTS. Not yet suitable for production or user-facing applications given the early training stage.
62
+
63
+ ## License
64
+
65
+ Derived from `facebook/mms-tts-swh` (**CC-BY-NC-4.0**, non-commercial). This finetuned model inherits that license. `swa_tts` training data is CC-BY-SA-4.0.
66
+
67
+ ## Acknowledgements
68
+
69
+ - [Meta MMS](https://huggingface.co/facebook/mms-tts-swh) for the base checkpoint
70
+ - [WAXAL / google/WaxalNLP](https://huggingface.co/datasets/google/WaxalNLP) for the training data
71
+ - [ylacombe/finetune-hf-vits](https://github.com/ylacombe/finetune-hf-vits) for the finetuning recipe