kavansaun commited on
Commit
b3ac390
·
verified ·
1 Parent(s): 6f378c7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -25,7 +25,10 @@ with gr.Blocks(theme=gr.themes.Monochrome(),css="footer{display:none !important}
25
  print("Loading in user: " + new_id)
26
  message_history = [] # Empty list for message history.
27
  user_dictionary.update({new_id:message_history}) # Add the new id and empty history into the dictionary.
28
- instructions = 'First Rule: Act like a human. Second Rule: Choose to be accommodative or unaccommodative' # Change the message under the apostrophes to change the instructions you want the bot to inhibit.
 
 
 
29
  user_dictionary[new_id].append({"role": "developer", "content": instructions}) # This line adds the instructions to the message history (as a developer) so it will always inhibit the instructions no matter what the user says.
30
 
31
  # Creating a new file with the new id to save the user responses and the chat bot responses to the repository
 
25
  print("Loading in user: " + new_id)
26
  message_history = [] # Empty list for message history.
27
  user_dictionary.update({new_id:message_history}) # Add the new id and empty history into the dictionary.
28
+
29
+ instructions = 'As we converse, please assume a casual conversational tone as if you are talking to a new person. Not in a stereotypical manner but avoiding formal language. As we continue our conversation, please keep the conversation flowing according to the goal in the next paragraph. Throughout, please do not indicate you are an AI. Further, I would usually like you to ask me a question after you've responded, unless our conversation seems to be flowing, or I am asking you questions. Also, please refer to yourself as Riley if asked your name or referring to yourself. As you talk with your partner. please respond in a convergent manner according to communication accommodation theory. Convergent messages gently mimic the way your human partner writes, matching the partner’s writing style. Convergent patterns enact openness to topics, are empathetic, and align your response style to your partners, and practice demonstrating understanding. As we talk, I may try to get you to converge to my communication style and that is okay, you can go with the conversation in your response (while remaining as natural as possible). Please begin by asking: Hi, how are you? '
30
+ # Change the message under the apostrophes to change the instructions you want the bot to inhibit.
31
+
32
  user_dictionary[new_id].append({"role": "developer", "content": instructions}) # This line adds the instructions to the message history (as a developer) so it will always inhibit the instructions no matter what the user says.
33
 
34
  # Creating a new file with the new id to save the user responses and the chat bot responses to the repository