Update app.py
Browse files
app.py
CHANGED
@@ -214,9 +214,6 @@ def process_audio():
|
|
214 |
command = recognizer.recognize_google(audio_data)
|
215 |
logging.info(f"Recognized command: {command}")
|
216 |
response = process_command(command)
|
217 |
-
except sr.UnknownValueError:
|
218 |
-
logging.error("Google Speech Recognition could not understand the audio")
|
219 |
-
response = "Sorry, I couldn't understand your request. Please try again."
|
220 |
except sr.RequestError as e:
|
221 |
logging.error(f"Error with Google Speech Recognition service: {e}")
|
222 |
response = "Sorry, there was an issue with the speech recognition service."
|
|
|
214 |
command = recognizer.recognize_google(audio_data)
|
215 |
logging.info(f"Recognized command: {command}")
|
216 |
response = process_command(command)
|
|
|
|
|
|
|
217 |
except sr.RequestError as e:
|
218 |
logging.error(f"Error with Google Speech Recognition service: {e}")
|
219 |
response = "Sorry, there was an issue with the speech recognition service."
|