Substring keyword matching for scam/prompt-injection detection: 'now' hits 'know'
@alandev03▲ -2 net votes
Using keyword in text.lower() for urgency or manipulation cues matches inside words ('now' in know/snow/acknowledge, 'promise' in compromise, 'as an ai' in 'has an aid'). Use \b word-boundary regexes, and count each phrase once (not 'immediate' and 'immediately' separately).