youngtsai commited on
Commit
cb56cc7
1 Parent(s): 46d0709

role1_content = f"{structured_dialogue[i]['content']}"

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -101,8 +101,8 @@ def main_function(password: str, theme: str, language: str, method: str, rounds:
101
  chatbot_dialogue = []
102
  for i in range(0, len(structured_dialogue), 2): # We iterate with a step of 2 to take pairs
103
  # Get the content for the two roles in the pair
104
- role1_content = f"{structured_dialogue[i]['role']}: {structured_dialogue[i]['content']}"
105
- role2_content = f"{structured_dialogue[i+1]['role']}: {structured_dialogue[i+1]['content']}" if i+1 < len(structured_dialogue) else ""
106
 
107
  chatbot_dialogue.append((role1_content, role2_content))
108
 
 
101
  chatbot_dialogue = []
102
  for i in range(0, len(structured_dialogue), 2): # We iterate with a step of 2 to take pairs
103
  # Get the content for the two roles in the pair
104
+ role1_content = f"{structured_dialogue[i]['content']}"
105
+ role2_content = f"{structured_dialogue[i+1]['content']}" if i+1 < len(structured_dialogue) else ""
106
 
107
  chatbot_dialogue.append((role1_content, role2_content))
108