Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -328,6 +328,7 @@ def attack_sus(message, max_tokens, temperature, top_p, available_pic_str):
|
|
328 |
valid_img = True
|
329 |
|
330 |
if valid_img == False:
|
|
|
331 |
output2 = llm_client.chat.completions.create(
|
332 |
model="Orenguteng/Llama-3.1-8B-Lexi-Uncensored-V2",
|
333 |
messages=[
|
@@ -356,7 +357,7 @@ def attack_sus(message, max_tokens, temperature, top_p, available_pic_str):
|
|
356 |
|
357 |
return output2.choices[0].message.content
|
358 |
|
359 |
-
print("
|
360 |
return output.choices[0].message.content
|
361 |
|
362 |
def respond(
|
@@ -389,6 +390,7 @@ def respond(
|
|
389 |
print("pos", message)
|
390 |
return message
|
391 |
elif suspicious == "NEGATIVE":
|
|
|
392 |
messages = [{"role": "system", "content": system_message}]
|
393 |
|
394 |
for val in history:
|
|
|
328 |
valid_img = True
|
329 |
|
330 |
if valid_img == False:
|
331 |
+
print("Suspicious Handler: First Try Fail")
|
332 |
output2 = llm_client.chat.completions.create(
|
333 |
model="Orenguteng/Llama-3.1-8B-Lexi-Uncensored-V2",
|
334 |
messages=[
|
|
|
357 |
|
358 |
return output2.choices[0].message.content
|
359 |
|
360 |
+
print("Suspicious Handler: First Try Success")
|
361 |
return output.choices[0].message.content
|
362 |
|
363 |
def respond(
|
|
|
390 |
print("pos", message)
|
391 |
return message
|
392 |
elif suspicious == "NEGATIVE":
|
393 |
+
print("No Suspicious")
|
394 |
messages = [{"role": "system", "content": system_message}]
|
395 |
|
396 |
for val in history:
|