https://github.com/dotpot/censor
Missing, high-performance censor for Python & Humans
https://github.com/dotpot/censor
Last synced: 10 months ago
JSON representation
Missing, high-performance censor for Python & Humans
- Host: GitHub
- URL: https://github.com/dotpot/censor
- Owner: dotpot
- Created: 2012-08-09T17:08:47.000Z (almost 14 years ago)
- Default Branch: master
- Last Pushed: 2014-10-08T08:00:57.000Z (over 11 years ago)
- Last Synced: 2025-01-05T22:12:10.537Z (over 1 year ago)
- Language: Python
- Size: 111 KB
- Stars: 1
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
##Censor
*Missing, high-performance **censor** for Python & Humans*
Use this component if you want to censor **any** text in a **fast & intuitive** ( **very** ) way.
It supports both **keywords** and **patterns** (regex)
###Overview
Imagine you have this text:
hello you little shit
And all you want to do is just censor it.
###You can do it now!!
all you have to do is:
```python
from censor import Censor
censor = Censor()
censor.add_keyword('shit')
print censor.censor('hello you little shit')
'hello you little ****'
```
#### Isn't that trolololowesome ?!
##### Please feel free to improve it if you like :)