Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: support usage of multiple voices #7

Open
H-Dorina opened this issue Feb 29, 2024 · 4 comments
Open

Request: support usage of multiple voices #7

H-Dorina opened this issue Feb 29, 2024 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@H-Dorina
Copy link

I use pied on ubuntu 22.04 with orca screenreader. I would like to use multiple Piper voices, e.g. Lessac in the web browser and Ryan in the terminal.
Please help me on how to achieve this with pied

@Elleo
Copy link
Owner

Elleo commented Mar 4, 2024

Hi @H-Dorina,

This isn't currently possible, but I've been giving it some thought over the weekend and have an idea for how we can support this sort of use case in future versions. The plan would be to support multiple speech dispatcher voice configurations (e.g. MALE1, FEMALE1, MALE2, FEMALE2, etc.), so that the voice can be changed dynamically at run time without needing to change configuration.

However, I'm not clear on what support Orca has for dynamically setting voices based on applications, I haven't been able to find any information about this sort of functionality. Is it something that already exists in Orca? And if so, what are the steps to activate it so that I can test this behaviour?

Thanks,
Mike

@Elleo Elleo self-assigned this Mar 4, 2024
@H-Dorina
Copy link
Author

H-Dorina commented Mar 4, 2024

Unfortunately I can't find any concrete information about orca's dynamic voice change capabilities at runtime.
However, on gnome's orca mailing list there is a topic about dynamic language switching: https://mail.gnome.org/archives/orca-list/2010-February/msg00134.html
Based on the referred webpage, I think if your app could support multiple speech dispatcher voice configurations, it might be possible that orca can change voice dynamically, since orca is using speech dispatcher.
I can help you implementing and testing this approach.

@Jopp-gh
Copy link

Jopp-gh commented Apr 11, 2024

I think a dynamic voice switch based on the active process wouldn't be too hard, example:

wmctrl -lx -p | grep Gnome-terminal

Additionally, Pied would need some more user preferences to know what voice presets to use for what process. Although I like this request too, it's a fairly custom feature request, not an essential feature , imo.

@takov751
Copy link

takov751 commented Apr 17, 2024

As far as i understand all downloaded models should be added to piper.conf with Addvoice line and then instead of ${MODEL_PATH} simply use ${MODEL_BASE_PATH}/${VOICE} .

Similarly to this manual solution i wrote earlier for myself in this discussion rhasspy/piper#328

 echo \'$DATA\' | /home/username/.var/app/com.mikeasoft.pied/data/pied/piper/piper \
--model /home/username/.var/app/com.mikeasoft.pied/data/pied/models/${VOICE} --output_raw | $PROCESS | $OUTPUT;"


AddVoice "en-us" "MALE1" "en_US-ryan-high.onnx"
AddVoice "de-DE" "MALE1" "de_DE-karlsson-low.onnx"

With this addition DeafaultVoice needs to be set and voicedetection function need some work to detect all installed voice models and detect defaultVoice as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants