Skip to content

Commit

Permalink
Merge pull request #320 from C-Pro/backdoor
Browse files Browse the repository at this point in the history
backdoor plus logs
  • Loading branch information
C-Pro authored Sep 8, 2024
2 parents 1c2fd95 + 8af2055 commit c41ec13
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions bot/skills/towel_mode.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,11 @@ def catch_reply(update: Update, context: CallbackContext):

def is_worthy(text: str) -> bool:
"""check if reply is a valid bio as requested"""

# backdoor for testing
if text.lower().find("i love vldc") != -1:
return True

if len(text) < 15:
return False

Expand All @@ -220,6 +225,8 @@ def is_worthy(text: str) -> bool:
presence_penalty=0.6,
)

logger.info("text: %s is %s", text, response.choices[0].message.content)

return response.choices[0].message.content == "worthy"


Expand Down

0 comments on commit c41ec13

Please sign in to comment.