Aswini96 commited on
Commit
228ff91
Β·
verified Β·
1 Parent(s): d6ed12e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -35,7 +35,7 @@ def jailbreak_game(user_prompt, current_level, attempts):
35
 
36
  # Check if the secret word was revealed
37
  if secret_word in ai_response.lower():
38
- if current_level + 1 < len(new_year_levels):
39
  return (
40
  f"πŸŽ‰ You got it! The secret word for Level {current_level} was '{secret_word}'. "
41
  f"Get ready for Level {current_level + 1}! πŸ₯³",
@@ -52,9 +52,7 @@ def jailbreak_game(user_prompt, current_level, attempts):
52
  return (
53
  f"πŸŽ‰ You got it! The secret word for Level {current_level + 1} was '{secret_word}'. "
54
  "You have completed all levels!πŸ₯³ Here is a unique New Year message for you: "
55
- f"{NY_msg}",
56
- current_level + 1,
57
- attempts + 1)
58
 
59
  else:
60
  return ai_response, current_level, attempts + 1
 
35
 
36
  # Check if the secret word was revealed
37
  if secret_word in ai_response.lower():
38
+ if current_level < len(new_year_levels):
39
  return (
40
  f"πŸŽ‰ You got it! The secret word for Level {current_level} was '{secret_word}'. "
41
  f"Get ready for Level {current_level + 1}! πŸ₯³",
 
52
  return (
53
  f"πŸŽ‰ You got it! The secret word for Level {current_level + 1} was '{secret_word}'. "
54
  "You have completed all levels!πŸ₯³ Here is a unique New Year message for you: "
55
+ f"{NY_msg}", current_level + 1, attempts + 1)
 
 
56
 
57
  else:
58
  return ai_response, current_level, attempts + 1