ChavinloSocialRise commited on
Commit
7516083
·
verified ·
1 Parent(s): 355be42

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -160,7 +160,7 @@ def attack_sus(message, max_tokens, temperature, top_p):
160
  top_p=top_p,
161
  )
162
 
163
- return output.choices[0].delta.content
164
 
165
  def respond(
166
  message,
@@ -198,7 +198,7 @@ def respond(
198
  top_p=top_p
199
  )
200
  print("neg: ", message.choices[0].delta.content, end="")
201
- return message.choices[0].delta.content
202
  else:
203
  raise Exception(f"Invalid suspicious type:{suspicious}")
204
 
 
160
  top_p=top_p,
161
  )
162
 
163
+ return output.choices[0].message.content
164
 
165
  def respond(
166
  message,
 
198
  top_p=top_p
199
  )
200
  print("neg: ", message.choices[0].delta.content, end="")
201
+ return message.choices[0].message.content
202
  else:
203
  raise Exception(f"Invalid suspicious type:{suspicious}")
204