import pyttsx3 engine = pyttsx3.init() voices = engine.getProperty('voices') for voice in voices: print voice if voice.languages[0] == u'en_US': engine.setProperty('voice', voice.id) break engine.say('Hello World') engine.runAndWait() code example
Example: how to change the rate of speech in pyttsx3
import pyttsx3
engine = pyttsx3.init()
engine.setProperty("rate", 178)
engine.say("I am the text spoken after changing the speech rate.")
engine.runAndWait()