# Fix: Update comment moderation logic Inspired by #38450 to help fix/complete the moderation script, this updates the moderation script to: - Add language detection for non-English comments - Implement profanity filtering - Check for off-topic content - Improve forbidden link detection - Add owner exemption logic - Enhance error handling and logging - Add a message indicating why the comment was deleted. *To configure the moderation lists:* - Go to repository Settings > Secrets > Actions - Add `MODERATION_PROFANITY` secret containing a JSON array of terms - Add `MODERATION_OFFTOPIC` secret containing a JSON array of phrases - Example format for each: `["term1","term2","term3"]` Resources for priming the PROFANITY and OFFTOPIC lists: - https://www.cs.cmu.edu/~biglou/resources/ (first link) - https://github.com/OOPSpam/spam-words/blob/main/spam-words-EN.txt Co-authored-by: Laurent Destailleur <eldy@destailleur.fr> |
||
|---|---|---|
| .. | ||
| ISSUE_TEMPLATE | ||
| scripts | ||
| tmp | ||
| workflows | ||
| CODE_OF_CONDUCT.md | ||
| CODEOWNERS | ||
| CONTRIBUTING.md | ||
| dependabot.yml | ||
| FUNDING.yml | ||
| PULL_REQUEST_TEMPLATE.md | ||