alt-profanity-check
A fast, robust library to check for offensive language in strings. Dropdown replacement of "profanity-check".
Decision gist · record as of 2026-08-14
Yes, if you need fast, model-based profanity detection and can target Python 3.11+. The package is actively maintained, has no known vulnerabilities, and offers better accuracy than blacklist-based alternatives with minimal install friction. The main trade-off is the strict Python version requirement and scikit-learn version pinning; treat predictions as heuristics, not ground truth, and test on your specific use case before deploying.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.11 or newer; scikit-learn version must match the package version (e.g., alt-profanity-check 1.9.0 expects scikit-learn 1.9.0).
- Low friction: pure Python wheel with only scikit-learn and joblib as runtime dependencies.
- Actively maintained with a release 64 days ago; requires Python 3.11 or newer, which may constrain adoption on older codebases.
License · maintenance · safety
permissive license (permissive) — MIT license (permissive); you can use, modify, and distribute this package freely with minimal legal restrictions.
last release 2026-06-11 (64 days) · last repo commit 2026-06-11 · 92 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 324,852 downloads/mo, #7,591 on PyPI
Alternatives
Verify before relying
pip install alt-profanity-check
from alt-profanity-check import predict, predict_prob
predict(['fuck you'])
# [1]
predict_prob(['go to hell, you scum'])
# [0.7618861]- Whether the package's scikit-learn version pinning strategy is enforced strictly or merely recommended.
- Current accuracy metrics on modern datasets; the description cites benchmarks from December 2018.
- Whether the command-line interface is available in the current version.
What it is and what it does
Alt-profanity-check is a maintained fork providing fast offensive-language detection for Python applications. It uses a linear SVM model trained on 200k labeled text samples from hate-speech and toxic-comment datasets, combined with scikit-learn's CountVectorizer and LinearSVC to classify input strings as offensive or clean. The package returns either binary predictions (0 or 1) or probability scores, making it suitable for content moderation pipelines.
The library trades some accuracy for speed compared to more sophisticated NLP approaches, but avoids the brittleness of hard-coded word blacklists. It depends on scikit-learn and joblib, and the maintainer aligns package versions with scikit-learn releases to ensure model compatibility. The package is actively maintained and requires Python 3.11 or newer; older Python versions require pinning to specific package versions.
Use it for
- Filter user-generated comments or forum posts in real time to flag potentially offensive content for review.
- Pre-screen chat messages or social media content in moderation workflows before human review.
- Detect toxic language in customer support tickets or feedback to route sensitive cases appropriately.
- Classify text datasets for research on hate speech or offensive language patterns.
- Implement content policies in multiplayer games or collaborative platforms by scoring text submissions.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you need fast, model-based profanity detection and can target Python 3.11+.
The package is actively maintained, has no known vulnerabilities, and offers better accuracy than blacklist-based alternatives with minimal install friction. The main trade-off is the strict Python version requirement and scikit-learn version pinning; treat predictions as heuristics, not ground truth, and test on your specific use case before deploying.
Install
alt-profanity-check on PyPI
Before you install
Low friction: pure Python wheel with only scikit-learn and joblib as runtime dependencies. Actively maintained with a release 64 days ago; requires Python 3.11 or newer, which may constrain adoption on older codebases.
Requires Python 3.11 or newer; scikit-learn version must match the package version (e.g., alt-profanity-check 1.9.0 expects scikit-learn 1.9.0).
License in practice
MIT license (permissive); you can use, modify, and distribute this package freely with minimal legal restrictions.
Quickstart
pip install alt-profanity-check
from alt-profanity-check import predict, predict_prob
predict(['fuck you'])
# [1]
predict_prob(['go to hell, you scum'])
# [0.7618861]
Verify before relying
- Whether the package's scikit-learn version pinning strategy is enforced strictly or merely recommended.
- Current accuracy metrics on modern datasets; the description cites benchmarks from December 2018.
- Whether the command-line interface is available in the current version.
Package facts
| License | permissive license permissive |
| Python support | Supports the current Python release >=3.11 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 2 packagesscikit-learnjoblib |
| Maintenance | Actively maintained 64 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 324,852 / month, #7,591 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableLicense :: OSI Approved :: MIT LicenseNatural Language :: EnglishOperating System :: OS IndependentProgramming Language :: Python :: 3 |
Evidence: alt_profanity_check-1.9.0-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “offensive language classifier”
- alt-profanity-checkDetects offensive or profane language in text strings using a…
- detoxifyDetoxify classifies text comments for toxic content using pre-trained…
- langidIdentifies the language of text input across 97 languages using a…
Give your agent the search over MCP, or paste the wish link into any chat.
More Linguistic packages
Detects and normalizes text encoding from unknown or ambiguous sources, supporting all IANA character sets that Python's core library provides codecs for, with the ability to register custom codecs.
tiktoken is a fast BPE tokenizer that converts text into token sequences compatible with OpenAI models, supporting multiple encoding schemes including o200k_base and model-specific encodings.
Install it if you work with OpenAI APIs or need to understand token boundaries in GPT-family models.
Detects character encoding and language in byte sequences with high accuracy, supporting 99 encodings and returning confidence scores, language tags, and MIME types.
Install it if you need to detect character encoding or language in byte data; the rewrite makes it substantially faster and more accurate than its predecessors.
Converts Unicode text to ASCII by transliterating non-ASCII characters into their closest ASCII equivalents, with no runtime dependencies.
However, if transliteration quality or ongoing maintenance matters, consider unidecode instead despite its GPL-only license.
Lark is a parsing library that builds abstract syntax trees from context-free grammars, supporting multiple parsing algorithms (Earley, LALR(1), CYK) with automatic line and column tracking.
Python bindings to the tree-sitter parsing library, enabling incremental parsing and syntax tree analysis for source code.
See also better-profanity · detoxify · fasttext · fasttext-wheel · fasttext-numpy2 · gibberish-detector · lingua-language-detector · keyphrase-vectorizers · confusables · wordfreq