We can't find the internet
Attempting to reconnect
Something went wrong!
Hang in there while we get back on track
Text-to-speech
npm install @wfloat/wfloat-web
import { loadTextToSpeech } from '@wfloat/wfloat-web';
const model = await loadTextToSpeech('rhasspy/piper-en_US-amy-medium');
const generation = model.generate('Hello, how are you?');
const result = await generation.result();
console.log(result.audio.samples, result.audio.sampleRate);
generation.dispose();
await model.unload();
npm install @wfloat/react-native-wfloat
cd ios && pod install
Rebuild the app after installation. Native setup.
import { loadTextToSpeech } from '@wfloat/react-native-wfloat';
const model = await loadTextToSpeech('rhasspy/piper-en_US-amy-medium');
const generation = model.generate('Hello, how are you?');
const result = await generation.result();
console.log(result.audio.samples, result.audio.sampleRate);
generation.dispose();
await model.unload();
pip install wfloat
from wfloat import load_text_to_speech
with load_text_to_speech("rhasspy/piper-en_US-amy-medium") as model:
result = model.generate("Hello, how are you?")
result.audio.save("speech.wav")