Home / Companies / Stream / Blog / Post Details
Content Deep Dive

Filtering Profanity in Chat with React Native

Blog post from Stream

Post Details
Company
Date Published
Author
Wern A.
Word Count
3,026
Language
English
Hacker News Points
-
Summary

The tutorial provides a comprehensive guide on implementing automatic profanity filtering and moderation in a chat application using React Native and Stream Chat, with the help of the Translator Text API from Microsoft Cognitive Services. It explains how to integrate a machine learning solution to analyze text and mask profanities using asterisks, and outlines a system to warn users upon initial offenses and ban them from sending messages after repeated infractions. By utilizing webhooks, the tutorial ensures real-time updates and moderation, and it details the necessary setup for services such as Stream Chat, ngrok, and Microsoft Azure. The process involves setting up a server with Express, configuring the Translator Text API for detecting profanity, and updating user warnings or banning them based on their behavior. The guide assumes prior knowledge of React, React Native, Node.js, and Stream Chat, and provides code snippets and instructions for testing and running the app.