Spaces:
Running
Running
oceansweep
commited on
Commit
•
0911ebb
1
Parent(s):
fe1ae68
Update app.py
Browse files
app.py
CHANGED
@@ -1488,7 +1488,7 @@ def main(input_path, api_name=None, api_key=None, num_speakers=2, whisper_model=
|
|
1488 |
requests.status_code = "Connection: "
|
1489 |
elif api_name.lower() == "huggingface":
|
1490 |
huggingface_api_key = os.environ.get(HF_TOKEN)
|
1491 |
-
if huggingface_api_key is
|
1492 |
huggingface_api_key = api_key if api_key else config.get('API', 'huggingface_api_key', fallback=None)
|
1493 |
try:
|
1494 |
logging.debug(f"MAIN: Trying to summarize with huggingface")
|
|
|
1488 |
requests.status_code = "Connection: "
|
1489 |
elif api_name.lower() == "huggingface":
|
1490 |
huggingface_api_key = os.environ.get(HF_TOKEN)
|
1491 |
+
if (huggingface_api_key is None):
|
1492 |
huggingface_api_key = api_key if api_key else config.get('API', 'huggingface_api_key', fallback=None)
|
1493 |
try:
|
1494 |
logging.debug(f"MAIN: Trying to summarize with huggingface")
|