Page MenuHomePhabricator

Create Utility For Non-Safe Words Check
Closed, ResolvedPublic8 Estimated Story Points

Description

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.

Screen Shot 2022-01-19 at 3.30.28 PM.png (1,073×667 px, 114 KB)

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.

Event Timeline

Anribolon changed the task status from Open to In Progress.Mar 21 2022, 11:47 AM
• Lena.Milenko changed the task status from In Progress to Open.Mar 21 2022, 2:50 PM
• Lena.Milenko changed the task status from Open to In Progress.Mar 22 2022, 10:58 PM
• Lena.Milenko changed the task status from In Progress to Open.Apr 13 2022, 9:28 PM