diff --git a/content.py b/content.py index 57ccefdc9..42c3c5df7 100644 --- a/content.py +++ b/content.py @@ -1023,7 +1023,7 @@ def _get_simplified_content(content: str) -> str: def detect_dogwhistles(content: str, dogwhistles: {}) -> {}: """Returns a dict containing any detected dogwhistle words """ - content = remove_html(content) + content = remove_html(content).lower() result = {} words = _get_simplified_content(content).split(' ') for whistle, category in dogwhistles.items(): @@ -1031,8 +1031,9 @@ def detect_dogwhistles(content: str, dogwhistles: {}) -> {}: continue ending = False starting = False + whistle = whistle.lower() - if whistle.lower().startswith('x-'): + if whistle.startswith('x-'): whistle = whistle[2:] ending = True elif (whistle.startswith('*') or diff --git a/default_dogwhistles.txt b/default_dogwhistles.txt index 89f5bf851..4860e5081 100644 --- a/default_dogwhistles.txt +++ b/default_dogwhistles.txt @@ -1,9 +1,15 @@ X-pilled, alt-right terminology +soy boy, alt-right terminology +soyboy, alt-right terminology +soyboi, alt-right terminology +kek, alt-right terminology +groyper, alt-right meme chad, alt-right meme globalist*, antisemitism globalism, antisemitism fren, alt-right terminology cuck*, alt-right terminology *1488, nazism +nazbol, nazism *1290, antisemitism