Fixed the Backend and added Voice recognition API
This commit is contained in:
parent
3588a4b703
commit
de4a6145af
3 changed files with 27 additions and 11 deletions
|
@ -7,5 +7,7 @@ class VoiceRecognition:
|
|||
r = sr.Recognizer()
|
||||
if option == "online":
|
||||
return r.recognize_google_cloud(audio)
|
||||
if option == "offline":
|
||||
elif option == "offline":
|
||||
return r.recognize_sphinx(audio)
|
||||
|
||||
return False
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue