Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -152,7 +152,7 @@ def chat_with_openai(message: str, history: list, temperature: float, max_new_to
|
|
152 |
response = None
|
153 |
|
154 |
while attempt < 5:
|
155 |
-
if attempt == 4:
|
156 |
del conversation[-1]
|
157 |
attempt += 1
|
158 |
response = client.chat.completions.create(
|
|
|
152 |
response = None
|
153 |
|
154 |
while attempt < 5:
|
155 |
+
if attempt == 4 and not fast_mode:
|
156 |
del conversation[-1]
|
157 |
attempt += 1
|
158 |
response = client.chat.completions.create(
|