Pythonity Blog Pythonity Blog

Ivona, Speak Dammit!

I don't know if you're familiar with Amazon's IVONA, but if you're not, let me just say that it's considered one of the best text-to-speech tools out there. Anyway, my boss needed an on-the-fly text to speech generator that makes use of IVONA's API for some project, and he tried to find a command-line script, but to his surprise, there wasn't anything that he liked. So he wrote one himself - in Go, for reasons unknown to me to this day.

But the fact that there wasn't anything like that made in Python didn't sit right with me. And who really uses Go for command-line tools anyway? Long story short - I made one as well. It's written (obviously) in Python and it's quite nice, if I do say so myself - for instance, it doesn't require you to explicitly provide all the attributes of the selected voice, while my bosses' version does. So there.

All you need to do to use it is to install it via $ pip3 install ivona_speak and then do something similar to like this:

$ ivona-speak --access-key 'ACCESS_KEY' --secret-key 'SECRET_KEY' / 
    -o good_news.mp3 'Good news everyone!'

Who needs mouths, am I right? They're so overrated anyway.

We (and by we, I mean my boss) also decided to factor out the part responsible for connecting to IVONA Speech Cloud into another library (as well as a GitHub repository). So, you can use python-ivona-api if you want to connect to IVONA from within your Python project, as we do in ivona-speak. How awesome is that?

ivona-speak: https://github.com/Pythonity/ivona-speak
ivona-api: https://github.com/Pythonity/python-ivona-api

Comments