I'm quite a beginner when it comes to programming so sorry if I get any of the terminology wrong.
I am trying to get text to speech to work for my AI programmed in python. At the moment I have got to a point where in python I have a text output, chosen from the user input. I have a sound output from CMD too which says what the user enters. However I want a way to connect the two... so I want to pass on the python text output to CMD where it will convert it to a sound output.
cmd:
aws polly synthesize-speech ^
--text-type text ^
--text "**Hello World**" ^
--output-format mp3 ^
--voice-id Joey ^
speech.mp3
python:
output = "Hello World"
essentially I want to pass that block of code from python to CMD, the output will change depending on the function run and user input.