def requested_donna_audio():
response_donna = "Hello Kevin, sure give me a moment!"
tts = gTTS(text= response_donna, lang='en')
# Google text to speech requires MP3 file
tts.save('response_donna.mp3')
# We are using Alsa as output to play the MP3
os.system('mpg321 -o alsa response_donna.mp3')
os.remove('response_donna.mp3')
评论列表
文章目录