Temporarily remove Whisper functionality
Browse files
app.py
CHANGED
|
@@ -263,17 +263,15 @@ def run_chain(chain, inp, capture_hidden_text):
|
|
| 263 |
try:
|
| 264 |
output = chain.run(input=inp)
|
| 265 |
except AuthenticationError as ae:
|
| 266 |
-
|
| 267 |
-
|
|
|
|
| 268 |
except ValueError as ve:
|
| 269 |
-
|
| 270 |
-
print("\nValueError: ", ve)
|
| 271 |
except InvalidRequestError as ire:
|
| 272 |
-
|
| 273 |
-
print("\nInvalidRequestError: ", ire)
|
| 274 |
except Exception as e:
|
| 275 |
-
|
| 276 |
-
print("\nException: ", e)
|
| 277 |
|
| 278 |
return output, hidden_text
|
| 279 |
|
|
|
|
| 263 |
try:
|
| 264 |
output = chain.run(input=inp)
|
| 265 |
except AuthenticationError as ae:
|
| 266 |
+
error_msg = AUTH_ERR_MSG
|
| 267 |
+
except RateLimitError as rle:
|
| 268 |
+
error_msg = "\n\nRateLimitError."
|
| 269 |
except ValueError as ve:
|
| 270 |
+
error_msg = "\n\nValueError."
|
|
|
|
| 271 |
except InvalidRequestError as ire:
|
| 272 |
+
error_msg = "\n\nInvalidRequestError."
|
|
|
|
| 273 |
except Exception as e:
|
| 274 |
+
error_msg = "\n\nException."
|
|
|
|
| 275 |
|
| 276 |
return output, hidden_text
|
| 277 |
|