polly-converse
A simple python script that creates an audio conversation from a script using Amazon Polly.
Create a script
- Create a plain text file for your conversation
- Use curly braces to designate voices (Voice names are case sensitive)
- Use
--s--
,--m--
,--l--
flags in your script to quickly add short, medium, or long pauses. - You can use your own SSML tags in the script for more controls.
Example Script
{Matthew}
Hey there. Hello.
{Joanna}
Hello!
{Matthew}
How's life?
{Joanna}
It's ok!
{Matthew}
Great to hear.
{Joanna}
Running
- Install the boto3 python library:
pip install boto3 --user
-
Enable the Polly service from your AWS console
-
Write your script and run
python polly.py your-script.txt
The script outputs an mp3 file with the same name as your script.