Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement validate_profanity feature via external api #38

Merged
merged 13 commits into from
Dec 21, 2023

Conversation

SeeknnDestroy
Copy link
Contributor

No description provided.

@fcakyon
Copy link
Contributor

fcakyon commented Dec 20, 2023

@SeeknnDestroy bu implementasyonun nasil kullanilacagini tam anlamadim, bir text uzerinde safetext tespiti yapip ayni zamanda moderatecontent api ile dogrulmaasini yapmak istiyorum, bunu ornek bir kod uzerinden yorumlayarak gosterebilir misin bu yoruma cevap olarak?

@SeeknnDestroy
Copy link
Contributor Author

@SeeknnDestroy bu implementasyonun nasil kullanilacagini tam anlamadim, bir text uzerinde safetext tespiti yapip ayni zamanda moderatecontent api ile dogrulmaasini yapmak istiyorum, bunu ornek bir kod uzerinden yorumlayarak gosterebilir misin bu yoruma cevap olarak?

st = SafeText(validate_profanity=True, api_key=api_key)
words = st.check_profanity(test_text)
# Check logs for comparison results
print(words)

INFO:root:Possible missing bad words: {'am', 'moron'}
[{'word': 'fuckin', 'index': 2, 'start': 4, 'end': 10}]

@SeeknnDestroy SeeknnDestroy changed the title implement moderate content api class implement validate_profanity feature for detected bad words, from external api Dec 21, 2023
@SeeknnDestroy SeeknnDestroy changed the title implement validate_profanity feature for detected bad words, from external api implement validate_profanity feature via external api Dec 21, 2023
@SeeknnDestroy SeeknnDestroy merged commit e35f105 into main Dec 21, 2023
@SeeknnDestroy SeeknnDestroy deleted the moderate-content-api branch December 21, 2023 08:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants