Downloads · 30 days
8
0% of all-time downloads
dougtrajano/toxicity-target-classification
toxicity-target-classification is a text classification model from dougtrajano. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as apache-2.0.
should probably proofread and complete it, then remove this comment. --
Downloads · 30 days
8
0% of all-time downloads
All-time downloads
1.9K
Public
Repo size
5.7 GB
Likes
0
Public
Click a slice to open those files.
.bin436 MB · 100%
From the Hugging Face model README
Toxicity Target Classification is a model that classifies if a given text is targeted or not.
This BERT model is a fine-tuned version of neuralmind/bert-base-portuguese-cased on the OLID-BR dataset.
Input: Text in Brazilian Portuguese
Output: Binary classification (targeted or untargeted)
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("dougtrajano/toxicity-target-classification")
model = AutoModelForSequenceClassification.from_pretrained("dougtrajano/toxicity-target-classification")
The following factors may degrade the model’s performance.
Text Language: The model was trained on Brazilian Portuguese texts, so it may not work well with Portuguese dialects.
Text Origin: The model was trained on texts from social media and a few texts from other sources, so it may not work well on other types of texts.
Sometimes models exhibit performance issues under particular circumstances. In this section, we'll discuss situations in which you might discover that the model performs less than optimally, and should plan accordingly.
Text Length: The model was fine-tuned on texts with a word count between 1 and 178 words (average of 18 words). It may give poor results on texts with a word count outside this range.
The model was evaluated on the test set of the OLID-BR dataset.
Accuracy: 0.6864
Precision: 0.6882
Recall: 0.6864
F1-Score: 0.6872
| Class | Precision | Recall | F1-Score | Support |
|---|---|---|---|---|
UNTARGETED | 0.4912 | 0.5011 | 0.4961 | 443 |
TARGETED INSULT | 0.7759 | 0.7688 | 0.7723 | 995 |
The following hyperparameters were used during training:
If you have any feedback on this model, please open an issue on GitHub.