Once we have a set of word tokens identified in the wikitext, we want to know if any of them are non_safe words (bad words). This will allow us to build the credibility signals related to non-safe words.
Implementation is mostly regex pattern matching.
Implementation details:
[1] This utility will live under structured-data/packages.
[2] is_non_safe_word(word_token) -> True/ False
If the word token matches against any non-safe word pattern in any language, we return true.
For this, you will need to copy/paste the list of bad_words for each language. Refer to the non_safe words for english in the link. Similarly, browse through the directory for other languages.
