Spaces:
Paused
Paused
Update vid2persona/pipeline/llm.py
Browse files
vid2persona/pipeline/llm.py
CHANGED
@@ -71,7 +71,7 @@ async def chat(
|
|
71 |
try:
|
72 |
for response in local_openllm.send_message(messages, model_id, max_input_token_length, parameters):
|
73 |
yield response
|
74 |
-
except
|
75 |
gr.Warning(f"{e} ➡️ Switching to TGI remotely hosted model")
|
76 |
finally:
|
77 |
async for response in tgi_openllm.send_messages(messages, model_id, hf_token, parameters):
|
|
|
71 |
try:
|
72 |
for response in local_openllm.send_message(messages, model_id, max_input_token_length, parameters):
|
73 |
yield response
|
74 |
+
except Exception as e:
|
75 |
gr.Warning(f"{e} ➡️ Switching to TGI remotely hosted model")
|
76 |
finally:
|
77 |
async for response in tgi_openllm.send_messages(messages, model_id, hf_token, parameters):
|