Commit
·
ac94b5c
1
Parent(s):
b788296
Update app.py
Browse files
app.py
CHANGED
@@ -44,12 +44,13 @@ class ChatWrapper:
|
|
44 |
# Run chain and append input.
|
45 |
output = chain({"question": inp, "chat_history": history})["answer"]
|
46 |
history.append((inp, output))
|
|
|
47 |
except Exception as e:
|
48 |
raise e
|
49 |
finally:
|
50 |
self.lock.release()
|
51 |
-
return history,
|
52 |
-
|
53 |
|
54 |
|
55 |
chat = ChatWrapper()
|
|
|
44 |
# Run chain and append input.
|
45 |
output = chain({"question": inp, "chat_history": history})["answer"]
|
46 |
history.append((inp, output))
|
47 |
+
chatResult = (inp, output)
|
48 |
except Exception as e:
|
49 |
raise e
|
50 |
finally:
|
51 |
self.lock.release()
|
52 |
+
#return history,history
|
53 |
+
return chatResult
|
54 |
|
55 |
|
56 |
chat = ChatWrapper()
|