OpenVoiceOS / ovos-tts-plugin-piper

Apache License 2.0
13 stars 9 forks source link

Download models on load rather than on first play #26

Open PureTryOut opened 1 month ago

PureTryOut commented 1 month ago

I switched to a new voice and instead of OVOS just giving me the answer immediately it first had to download that new voice. Which, being 115MB, was anything but instant.

It would be nice if it loaded voices on load and on config file changes so you don't have to wait when it's trying to give you the first answer.

JarbasAl commented 1 month ago

you can request a different voice per request, we cant download ALL models, so every time you request a model you dont have, it is downloaded on demand

i'm open to suggestions, maybe something like a cli command to download them?

the plugin also needs to be updated for latest piper that i believe handles their own download, so this might just be an upstream bug depending how we look at it

JarbasAl commented 1 month ago

also note, you can set your config to preload models already

preload_voices = self.config.get("preload_voices") or []
preload_langs = self.config.get("preload_langs") or [self.lang]
PureTryOut commented 1 month ago

Oh interesting, why would you ever preload some voices but not others?