| 1 | from typing import Any |
| 2 | |
| 3 | def initialize(espeak_data_dir: str = '') -> None: |
| 4 | """initialize(espeak_data_dir) -> Initialize this module. Must be called once before |
| 5 | using any other functions from this module. If espeak_data_dir is not specified or |
| 6 | is the empty string the default data location is used. |
| 7 | """ |
| 8 | pass |
| 9 | |
| 10 | def set_voice(voice_config: Any, model_path: str) -> None: |
| 11 | "set_voice(voice_config, model_path) -> Load the model in preparation for synthesis." |
| 12 | pass |
| 13 | |
| 14 | def start(text: str) -> None: |
| 15 | "start(text) -> Start synthesizing the specified text, call next() repeatedly to get the audiodata." |
| 16 | pass |
| 17 | |
| 18 | def next(as_16bit_samples: bool = True) -> tuple[bytes, int, int, bool]: |
| 19 | """next(as_16bit_samples=True) -> Return the next chunk of audio data |
| 20 | (audio_data, num_samples, sample_rate, is_last). Here audio_data is a bytes object |
| 21 | consisting of either native 16bit integer audio samples or native floats in the |
| 22 | range [-1, 1]. |
| 23 | """ |
| 24 | pass |
| 25 | |
| 26 | def set_espeak_voice_by_name(name: str) -> None: |
| 27 | "set_espeak_voice_by_name(name) -> Set the voice to be used to phonemize text" |
| 28 | pass |
| 29 | |
| 30 | def phonemize(text: str) -> list[tuple[str, str, bool]]: |
| 31 | "phonemize(text) -> Convert the specified text into espeak-ng phonemes" |
| 32 | pass |