POLRAMBORA commited on
Commit
e2f573b
·
verified ·
1 Parent(s): 11e76a2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -117,8 +117,8 @@ def respond(message, api_key, max_tokens, top_p, temperature):
117
  chunk_message = chunk.get("chunk", {}).get("content", "")
118
  assistant_reply += chunk_message
119
 
120
- partial_history = history + [(message, assistant_reply, "You", "P-ALPLE", session["avatar"], ASSISTANT_PIC_PATH)]
121
- sessions[api_key]["history"] = partial_history
122
 
123
  yield assistant_reply
124
  except json.JSONDecodeError as e:
 
117
  chunk_message = chunk.get("chunk", {}).get("content", "")
118
  assistant_reply += chunk_message
119
 
120
+ sessions[api_key]["history"].append((message, assistant_reply, "You", "P-ALPLE", session["avatar"], ASSISTANT_PIC_PATH))
121
+
122
 
123
  yield assistant_reply
124
  except json.JSONDecodeError as e: