tiny-voca-ja
日本語要約: tiny-voca-ja は、英語 TTS モデル tiny-voca(n4ze3m)を日本語で ゼロから学習し直した派生モデルです。パラメータ 4.5M、声は F2(女性)と M2(男性)の 2 声、出力は 24 kHz モノラル。学習データは Qwen3-TTS で生成した合成音声 16,321 クリップ(16.6 時間)で、実在の話者の録音は含まれません。CPU で実時間より速く 動きます。未学習16文の正式評価では CER 平均 6.6%(数字・単位の表記を読みにそろえた正規化後は 1.6%)でした。日付・数字の読み誤りの主因はモデルではなく、読み処理(フロントエンド)側にありました。
tiny-voca-ja is a Japanese text-to-speech model with two voices, F2 (female) and M2 (male). It is a from-scratch retrain of tiny-voca — the same architecture and recipe by Muhammed Nazeem — on Japanese data. It is not a fine-tune of the English weights: no pretrained weights are part of the model. The complete model, including the waveform generator, has 4.5M parameters and was trained on about 16.6 hours of synthetic speech. It runs faster than real time on CPU.
- Code (Japanese recipe): https://github.com/gachimoto-code/tiny-voca-ja
- Original project: https://github.com/n4ze3m/tiny-voca
- Dataset: https://huggingface.co/datasets/gachimoto/tiny-voca-ja
| Parameters | 4,538,827 |
| Voices | F2, M2 (Japanese) |
| Output | 24 kHz mono |
| Input | Japanese text, converted to phonemes with eSpeak NG (ja voice); kanji readings resolved with pykakasi |
| Pretrained weights in the model | None |
| License | Apache-2.0 |
The parameter count is 1,536 higher than the English model (4,537,291) because the phoneme inventory grew from 76 to 84 symbols (8 Japanese additions).
Files
| File | Size | Contents |
|---|---|---|
tiny-voca-ja.pt |
18.2 MB | PyTorch weights, float32 (inference checkpoint, format 4) |
onnx/model.onnx |
21.4 MB | ONNX export, float32, opset 17 |
config.json |
Model settings, phoneme vocabulary, voices, front-end identity | |
samples/ |
The audio samples on this page, synthesized by this model | |
metrics.jsonl |
11.0 MB | Full training log of the final run |
SHA256:
tiny-voca-ja.pt:34e6c68cd6d627207a09378deb8642f8cfb346d9826eea7145ef8d06472725d4onnx/model.onnx:3037732cc4b5428773aa96aff55977cec4d1cbad711a4ce16a5655ce9f30e95e
The ONNX export was verified against the PyTorch model on a Japanese sentence for both voices: identical durations, and a waveform difference of at most 0.16% of the peak amplitude (the noise signal is drawn by each runtime, as in the English model).
Samples
Synthesized on a CPU-only Linux machine (no GPU). CER is the character error rate of a Whisper small (multilingual) transcription against the input text, computed in a kana-normalized space so that kanji spelling variants are not counted as errors. See Evaluation for the caveats — this is four sentences, not a benchmark.
| # | Voice | Text | CER |
|---|---|---|---|
| 1 | F2 | こんにちは、これは日本語の音声合成のテストです。 | 0.0% |
| 2 | F2 | はじめまして。私は日本語で話す、小さな音声合成モデルです。 | 0.0% |
| 3 | M2 | 今日は十一月十九日、木曜日です。東京の天気は、晴れのち曇りでしょう。 | 0.0% |
| 4 | F2 | 人工知能が、日本語の文章を読み上げます。声の大きさも、速さも、自由に変えられます。 | 0.0% |
Sample 3 was scored 29.2% in the original spot check; that figure later turned out to be mostly a scoring artifact, and the same audio scores 0.0% once numeral notation is normalized on both sides — see the correction in Evaluation.
Usage
The Japanese front end uses eSpeak NG with the ja voice, so the checkpoint
only speaks Japanese text. You need the espeak-ng system package and the
code from the Japanese recipe repository.
sudo apt install espeak-ng # or your platform's equivalent
pip install git+https://github.com/gachimoto-code/tiny-voca-ja
hf download gachimoto/tiny-voca-ja --local-dir tiny-voca-ja
tiny-voca-speak \
--checkpoint tiny-voca-ja/tiny-voca-ja.pt \
--voice F2 \
--text "こんにちは、これは日本語の音声合成のテストです。" \
--output hello.wav
(python -m tiny_voca.infer with the same arguments works too.)
| Option | Default | Meaning |
|---|---|---|
--text-file |
Read the text from a file instead of --text. |
|
--voice |
F2 |
F2 or M2 |
--speed |
1.0 | Speaking rate |
--pitch-shift |
0 | Added to log F0. 0.058 is about one semitone. |
--pitch-range |
1.0 | Scales pitch movement around the utterance mean. |
Text of any length works. The command reads it one sentence at a time and
joins the audio. The checkpoint records the front end it was trained with;
inference refuses to run with a mismatched front end unless
--allow-frontend-mismatch is given.
Synthesis measured on a small shared CPU-only VM: 2.8–6.3 seconds per sentence including model load, for 4.4–8.1 seconds of audio — faster than real time, but this VM is far from a benchmark machine.
ONNX
The graph takes phoneme ids and stress values and returns the waveform.
Text is converted to ids outside the graph with the Japanese front end
(eSpeak NG ja + pykakasi); the ids are the positions in vocab in
config.json. Inputs and outputs are the same as the English model:
inputs tokens, stress, voice (0 = F2, 1 = M2), speed, pitch_shift,
pitch_range; outputs audio (24 kHz float32) and durations. The model
reads one utterance per call, up to 512 tokens and 32 seconds. The audio can
peak a little above 1.0, so scale it down before saving 16-bit samples.
Model
Text is converted to phonemes with a stress value for each. A transformer encoder (4 blocks) reads the phonemes, a duration predictor gives each one a length in frames, and two frame-level transformers (2 and 5 blocks) predict pitch, voicing and energy and then the parameters of the waveform generator. All blocks use 192 channels, 4 heads and rotary position embeddings.
The waveform is produced by a source-filter synthesizer instead of a neural vocoder. A band-limited pulse train at the predicted pitch and a noise signal are each shaped by a time-varying filter, whose cepstrum the network predicts once per frame (256 samples, 10.7 ms). This part has 25,862 parameters.
The Japanese model uses the same components as the English one; only the phoneme embedding grows with the 84-symbol inventory.
Training
| Data | gachimoto/tiny-voca-ja: 16,321 clips, 16.6 hours, two voices; 11,561 clips (11.5 hours) passed annotation and were used for training (10,884 train / 332 validation / 345 test) |
| Steps | 104,000 |
| Hardware | One RTX 4090 (rented, RunPod), about 5.3 hours |
| Final loss | 10.717 (base loss 6.494) at step 104,000 |
| Losses | Multi-resolution spectral losses; adversarial loss with multi-period and multi-resolution discriminators after step 8,000 (gan-ratio 0.7) |
The training audio is synthetic. Both voices were created from text descriptions with Qwen3-TTS VoiceDesign, and the recordings were generated with Qwen3-TTS 1.7B Base. No recording of a real speaker is involved.
Phoneme durations come from forced alignment with
prj-beatrice/japanese-hubert-base-phoneme-ctc-v2, with labels from
pyopenjtalk-plus. This differs from the English recipe on purpose: the
eSpeak-based aligner used there (facebook/wav2vec2-lv-60-espeak-cv-ft)
accepted 0 of 150 Japanese smoke-test clips — it has not learned Japanese
acoustics — so a Japanese phoneme CTC model was used instead. 11,561 of the
16,321 clips (70.8%) passed the alignment checks.
Evaluation
Character error rate of synthesized speech, compared in a kana-normalized space so that kanji spelling variants are not counted as errors. Two checks have been run, both synthesized locally on CPU: a 4-sentence sanity check transcribed with Whisper small (multilingual), and a formal evaluation of 16 unseen sentences transcribed with Whisper large-v3:
| Sentences | Clips | CER |
|---|---|---|
| New sentences, not in the dataset | 4 | 7.3% mean (0.0 / 0.0 / 29.2 / 0.0) with the original kana-only scoring; 0.0% mean after numeral normalization |
| Formal evaluation, 16 unseen sentences (Whisper large-v3) | 16 | 6.6% mean raw, 1.6% after numeral/unit normalization |
The 4-sentence row is a sanity check, not a benchmark. The formal evaluation has since been run (2026-11-19): 16 unseen sentences covering dates in both numeral styles, times, money, counters, place and personal names, a phone number, decimals, homophones and one long sentence, transcribed with Whisper large-v3. The stock front end scored 6.6% mean CER raw and 1.6% after normalizing numeral and unit notation on both sides; 13 of the 16 sentences scored 0.0% normalized. No listening test has been run.
Correction (2026-11-19). Sample 3's 29.2% was mostly a measurement artifact: the ASR writes dates as digits ("11月19日") while the reference is read as kanji numerals, and the kana scorer drops digits, so matching sounds were counted as errors on one side only. Normalized, that sentence scores 0.0% — the audio was correct. The genuine reading errors were in Arabic-numeral date sentences (「今日は」 read as the greeting 「こんにちは」, a wrong weekday); an experiment in the GitHub repository (experiments/frontend-swap) shows they come from the front end, not the model: with pyopenjtalk-plus readings the same checkpoint scores 0.0% on that sentence, and 1.6% mean normalized CER over the 16-sentence set.
Limitations
- Japanese only, two fixed voices, no voice cloning.
- Numbers and dates depend on the front end. The stock front end misreads some Arabic-numeral date sentences (「今日は」 read as the greeting 「こんにちは」, weekday mix-ups). An earlier version of this card also described the kanji-numeral date sample as a reading failure (CER 29.2%); that was a scoring artifact, corrected in Evaluation above. Writing numbers out in kana before synthesis avoids most of the genuine cases.
- Pitch accent is not modeled explicitly; the model only sees what the eSpeak front end provides, so accent can sound flat or foreign.
- The voice is clear but can sound slightly synthetic.
- The same text is always read the same way. There is no sampling of prosody.
- Foreign names and unusual kanji readings depend on the front end and are often misread.
- No streaming.
- The training data is itself synthetic, so the model cannot be more natural than the model that generated it.
Cost
About $20 of rented GPU time in total (estimated from pod hours × the $0.89/h rate; not reconciled against the RunPod billing screen). Roughly: $9.18 for dataset generation, $4.69 for the final training run, the rest for voice design, environment setup and the failed annotation attempts. The English original cost $9.56; the Japanese version cost about twice that, mainly because of the aligner replacement and the higher per-hour rate of the GPU that was actually available.
License
The weights and code are released under Apache-2.0.
tiny-voca-ja is a derivative work of tiny-voca by Muhammed Nazeem, used under Apache-2.0. The architecture, training recipe and code base are his; the Japanese front end, corpus, annotation pipeline and training run are this project's. If you use this model, please credit both.
Citation
@software{fujimoto2026tinyvocaja,
author = {Fujimoto, Satoshi},
title = {tiny-voca-ja: a 4.5M-parameter two-voice Japanese text-to-speech model},
year = {2026},
url = {https://huggingface.co/gachimoto/tiny-voca-ja}
}
Original model:
@software{nazeem2026tinyvoca,
author = {Nazeem, Muhammed},
title = {tiny-voca: a 4.5M-parameter two-voice English text-to-speech model},
year = {2026},
url = {https://huggingface.co/n4ze3m/tiny-voca}
}
Author: gachimoto (Satoshi Fujimoto).
Acknowledgements
The design builds on FastSpeech 2 (explicit duration and prosody prediction), DDSP and the neural homomorphic vocoder (source-filter synthesis with predicted filters), and HiFi-GAN and UnivNet (discriminators). No code or weights from these projects are used. The Japanese alignment uses prj-beatrice/japanese-hubert-base-phoneme-ctc (Apache-2.0) and pyopenjtalk-plus.
- Downloads last month
- 18
Model tree for gachimoto/tiny-voca-ja
Base model
n4ze3m/tiny-voca