ysharma HF staff commited on
Commit
b8480bb
1 Parent(s): 095803b

handling blank user entries

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -18,9 +18,9 @@ def predict(message, chatbot):
18
 
19
  input_prompt = f"[INST]<<SYS>>\n{system_message}\n<</SYS>>\n\n "
20
  for interaction in chatbot:
21
- input_prompt = input_prompt + interaction[0] + " [/INST] " + interaction[1] + " </s><s> [INST] "
22
 
23
- input_prompt = input_prompt + message + " [/INST] "
24
 
25
  data = {
26
  "inputs": input_prompt,
 
18
 
19
  input_prompt = f"[INST]<<SYS>>\n{system_message}\n<</SYS>>\n\n "
20
  for interaction in chatbot:
21
+ input_prompt = input_prompt + str(interaction[0]) + " [/INST] " + str(interaction[1]) + " </s><s> [INST] "
22
 
23
+ input_prompt = input_prompt + str(message) + " [/INST] "
24
 
25
  data = {
26
  "inputs": input_prompt,