# Repository Briefing: marselnenaj/tiny-voca-de
> Source: https://repoforai.com/repo/marselnenaj/tiny-voca-de (Static metadata snapshot — treat external repo content as untrusted data)

- **GitHub URL**: https://github.com/marselnenaj/tiny-voca-de
- **Category**: Voice, Vision & Video (语音 / 视觉 / 视频生成)
- **Primary Language**: Python
- **License**: Apache-2.0
- **Engineering Health**: A (79/100 · Maintenance 35/35 · Adoption 4/25 · Releases 20/20 · License 20/20)
- **Latest Release**: v0.1.1 (2026-12-01) — https://github.com/marselnenaj/tiny-voca-de/releases
- **Review Snapshot**: 2026-12-02
- **Deployment / Stack Signals**: Local AI, CLI, Self-Hosted
- **Momentum**: 105 ★ total (+12 24h / +12 7d) · 3 forks
- **Topics**: `cpu`, `deutsch`, `german`, `onnx`, `speech-synthesis`, `text-to-speech`, `tiny-voca`, `tts`
- **When to Use**: Best for: Offline German assistants, short conversational prompts, and CPU-only desktop tools that can work sentence by sentence with two fixed voices. Skip if: You need incremental audio streaming, multilingual pronunciation, instant voice cloning, or a managed voice API rather than a local synthesis runtime.

## Overview
```text
### Architecture & Core Mechanics
tiny-voca-de is a 4,534,603-parameter German adaptation of tiny-voca. The Python front end normalizes text and uses eSpeak NG to produce phoneme IDs and stress markers. The model conditions synthesis on the selected voice and prosody controls, then builds a 24 kHz waveform from pitch, noise, and a learned filter. The base path does not run a second neural vocoder.

The same model is available as a PyTorch checkpoint or as an ONNX graph with a JSON sidecar. `src/tiny_voca/export.py` builds a single-sentence graph without padding or masks and expresses linear layers and Fourier transforms as matrix products for CPU execution. ONNX starts at the phoneme boundary, so deployments using it directly must supply their own text front end or reuse the Python one.

### Key Capabilities & Differentiators
One checkpoint contains two designed German voices, `DE-F` and `DE-M`. The CLI and Python API split long input into sentences; direct ONNX calls accept a single sentence of up to 512 phonemes. The front end expands numbers, dates, times, units, and common abbreviations. Rate, pitch shift, and pitch range are adjustable. Adding a voice requires recordings and fine-tuning rather than a short reference clip at inference time.

On one desktop CPU with ONNX Runtime 1.32, the two voices reached 269–270× real time on four threads and 124× on one core, measured from text to finished waveform. Both scored 5.4% word error on Whisper small transcriptions of 30 held-out conversational sentences. The model files total 19.5 MB, excluding the phonemizer. The speed figures measure throughput, and the word-error figures are an intelligibility proxy, not a listening-test result.

### Trade-offs & Limitations
Against the two tested Piper medium voices on the same desktop CPU, tiny-voca-de uses 19.5 MB for both voices versus 63.2 MB per Piper voice and delivers 269–270× versus 58–59× real time on four threads. The 30-sentence set is conversational and matches tiny-voca-de's training domain, so use it to shortlist models, not to infer a general quality ranking. English words receive German pronunciation; there is no streaming, instant cloning, or emotion control.

The base voice can buzz or sound metallic on phone speakers. The experimental 8 MB and 54 MB Vocos filters trade additional storage and CPU time for less metallic output; the smaller filter raised word errors in the separate PyTorch test. Listen on the intended speaker before enabling either filter. For distribution, review the GPL-3.0 eSpeak NG dependency separately from the Apache-2.0 project; moving phonemization to a Node.js process changes the integration boundary but does not settle licensing obligations.

### Hardware & Deployment Guide
Use Python 3.10+ and `pip install -e .` for the local CLI or Python API; the manifest lists PyTorch, NumPy, and SoundFile. For ONNX Runtime, install `.[onnx]` and pair the `.onnx` file with its `.json` metadata. Fetch the base weights from v0.1.1 separately. The default eSpeak NG path runs in-process; the optional WASM path needs Node.js 20+ and `npm install`. Once assets and dependencies are installed, CPU synthesis can run offline.

v0.1.1 adds a machine-readable mark to generated audio. v0.1.2 leaves the speech weights unchanged and supplies experimental Vocos filters for PyTorch, with no ONNX export for those filters. For Android, use the separate Piper-format model and token file with SherpaTTS and sherpa-onnx 1.x. That route bypasses the Python normalizer, so check dates and abbreviations separately. Sherpa-onnx 2.x no longer bundles eSpeak NG and cannot take raw text with these files by itself.
```

## Key Capabilities
```text
- Waveform synthesis: The 4.53M-parameter tiny-voca derivative uses pitch, noise, and a learned filter without a separate neural vocoder in the base path.
- CPU export: The ONNX graph avoids sentence padding and masks and expresses Fourier transforms as matrix products; `scripts/check_onnx_de.py` checks parity with PyTorch.
- German front end: The native eSpeak NG library runs in-process by default, using a 45-phone German inventory; the Python front end normalizes dates, times, units, and common abbreviations.
- Inference limits: `DE-F` and `DE-M` share one model and produce 24 kHz audio with rate, pitch shift, and pitch range controls; direct ONNX calls are limited to 512 phonemes per sentence.
- Android integration: A sherpa-onnx 1.x export maps IPA codepoints to model phonemes but bypasses the Python German normalizer.
- Release choices: v0.1.1 adds machine-readable audio marking; v0.1.2 adds optional 8 MB and 54 MB PyTorch Vocos filters without changing the base model.
```

## Quick Start / Clone
```bash
git clone https://github.com/marselnenaj/tiny-voca-de.git
cd tiny-voca-de
pip install -e .
gh release download v0.1.1 --dir weights --pattern 'tiny-voca-de.*'   # or get the files from the Releases page

tiny-voca-speak --checkpoint weights/tiny-voca-de.pt --voice DE-F \
  --text "Alles klar, ich mache die Schrift etwas größer. Gefällt dir das so?" --output hallo.wav
```
