Commit 8f15b60d authored by Thathsarani R.P.H.S.R's avatar Thathsarani R.P.H.S.R

Modified text_to_speech.py

parent bc1061b7
import pyttsx3
from flask import jsonify
def text_to_speech(text):
print("Dev -->", text)
engine = pyttsx3.init()
engine.say(text)
engine.runAndWait()
# Send the conversation data to the front-end using jsonify (Flask)
jsonify({'message': text})
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment