Views
No views yet
original model checkpoint for offline use.toxic_original-c1212f89.ckpt1from detoxify import Detoxify
2
3model = Detoxify('original')
4result = model.predict("Your text here")
5print(result)toxic_original-c1212f89.ckpt from this repo~/.cache/torch/hub/checkpoints/1from detoxify import Detoxify
2
3# Works offline if checkpoint is in cache
4model = Detoxify('original', device='cpu')
5result = model.predict("Your text here")toxicity - Overall toxicitysevere_toxicity - Severe toxic contentobscene - Obscene languagethreat - Threatening languageinsult - Insultsidentity_attack - Attacks on identity1@misc{detoxify,
2 title={Detoxify},
3 author={Hanu, Laura and Unitary team},
4 howpublished={Github. https://github.com/unitaryai/detoxify},
5 year={2020}
6}