Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -37,13 +37,15 @@ def respond(
|
|
| 37 |
top_p=top_p,
|
| 38 |
):
|
| 39 |
token = message.choices[0].delta.content
|
|
|
|
| 40 |
print(token)
|
| 41 |
|
| 42 |
response += token
|
|
|
|
| 43 |
|
| 44 |
yield response.json()
|
| 45 |
except Exception as e:
|
| 46 |
-
|
| 47 |
"""
|
| 48 |
For information on how to customize the ChatInterface, peruse the gradio docs: https://www.gradio.app/docs/chatinterface
|
| 49 |
"""
|
|
|
|
| 37 |
top_p=top_p,
|
| 38 |
):
|
| 39 |
token = message.choices[0].delta.content
|
| 40 |
+
print('token start')
|
| 41 |
print(token)
|
| 42 |
|
| 43 |
response += token
|
| 44 |
+
print('token end')
|
| 45 |
|
| 46 |
yield response.json()
|
| 47 |
except Exception as e:
|
| 48 |
+
print (f"Error: {e}")
|
| 49 |
"""
|
| 50 |
For information on how to customize the ChatInterface, peruse the gradio docs: https://www.gradio.app/docs/chatinterface
|
| 51 |
"""
|