pure-flow-ai ๐ซโจ
Efficient profanity filter for JavaScript/TypeScript applications with flexible configuration and simple API ๐ก๏ธ
Table of Contents
๐ Description
pure-flow-ai
is a powerful and flexible profanity filter for JavaScript and TypeScript applications. It provides a simple yet comprehensive API for detecting, masking, and cleaning text from inappropriate language. Perfect for chat applications, comment systems, or any text-processing functionality requiring content moderation.
โก Features
- ๐ Smart Detection: Efficiently identifies profane words in text
- ๐ญ Flexible Masking: Customizable placeholder characters for censoring
- ๐งน Text Cleaning: Complete removal of inappropriate content
- ๐ Customizable Lists: Add your own words to block or allow
- ๐ช TypeScript Support: Full type definitions included
- ๐ Case Insensitive: Works regardless of letter casing
- ๐ฏ Zero Dependencies: Lightweight and efficient
- ๐ Unicode Support: Works with special characters and different alphabets
๐ป Installation
Using npm:
npm install pure-flow-ai
Using yarn:
yarn install pure-flow-ai
Using pnpm:
pnpm install pure-flow-ai
Advanced Example
import BadWordFilter from 'pure-flow-ai';
const { hasProfaneWords, maskProfanity, cleanString } = BadWordFilter({
additionalBlockWords: ['bad', 'word,'],
excludedWords: ['trash'],
placeholder: '*',
overrideBlockWords: true
});
const hasBadWords = hasProfaneWords('your text here');
const masked = maskProfanity('your text here');
const clean = cleanString('your text here');
๐ค Contributing
We'd love for you to contribute to pure-flow-ai
! Whether it's reporting bugs, suggesting features, or submitting pull requests, your help is always appreciated.
How to contribute:
- Fork the repository.
- Create a new branch (
git checkout -b feature/your-feature
).
- Make your changes.
- Commit your changes (
git commit -am 'Add new feature'
).
- Push to the branch (
git push origin feature/your-feature
).
- Open a pull request.
๐ Code of Conduct
Please follow our Code of Conduct when participating in this project to ensure a welcoming and productive atmosphere.
๐ Security Policy
Security is our priority. If you encounter any issues, please read our full Security Policy to report vulnerabilities safely and responsibly.
๐ฅ Team
These folks keep the project moving and are resources for help.
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.
๐ก๏ธ Make your application safer with pure-flow-ai!
Support
If you found this project useful, please consider giving it a โญ๏ธ on Github and sharing it with your friends!