File size: 1,417 Bytes
af7c479
 
 
5a52aa5
 
 
 
af7c479
 
65096ac
af7c479
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2e3a71a
af7c479
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
---
language:
- en
metrics:
- f1
- accuracy
pipeline_tag: text-classification
---
### BERTweet-large-sexism-detector
This is a fine-tuned model of BERTweet-large on the Explainable Detection of Online Sexism (EDOS) dataset. It is intended to be used as a classification model for identifying tweets (0 - not sexist; 1 - sexist). 

More information about the original pre-trained model can be found [here](https://huggingface.co/docs/transformers/model_doc/bertweet)

Classification examples:

|Prediction|Tweet|
|-----|--------|
|sexist         |Every woman wants to be a model. It's codeword for "I get everything for free and people want me" |
|not sexist     |basically I placed more value on her than I should then?|
# More Details 
For more details  about the datasets and eval results, see (we will updated the page with our paper link)
# How to use
```python
from transformers import AutoModelForSequenceClassification, AutoTokenizer,pipeline
import torch
model = AutoModelForSequenceClassification.from_pretrained('sana-ngu/BERTweet-large-sexism-detector')
tokenizer = AutoTokenizer.from_pretrained('vinai/bertweet-large') 
classifier = pipeline("text-classification", model=model, tokenizer=tokenizer)
prediction=classifier("Every woman wants to be a model. It's codeword for 'I get everything for free and people want me' ")
label_pred = 'not sexist' if prediction == 0 else 'sexist' 

print(label_pred)
```