Update app.py
Browse files
app.py
CHANGED
|
@@ -15,9 +15,9 @@ def correct_words(text):
|
|
| 15 |
|
| 16 |
def generate_response(message):
|
| 17 |
global history
|
| 18 |
-
for text in llm(message):
|
| 19 |
response = ''.join(text)
|
| 20 |
-
time.sleep(
|
| 21 |
corrected_response = correct_words(response)
|
| 22 |
history.append(corrected_response)
|
| 23 |
yield ' '.join(history)
|
|
|
|
| 15 |
|
| 16 |
def generate_response(message):
|
| 17 |
global history
|
| 18 |
+
for text in llm.generate(message):
|
| 19 |
response = ''.join(text)
|
| 20 |
+
time.sleep(0.1)
|
| 21 |
corrected_response = correct_words(response)
|
| 22 |
history.append(corrected_response)
|
| 23 |
yield ' '.join(history)
|