File size: 1,436 Bytes
4d46349
 
 
 
 
6a2f552
 
 
 
 
 
 
 
 
4d46349
 
6a2f552
 
 
 
 
 
 
4d46349
 
 
6a2f552
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
34
35
36
37
38
39
40
41
42
43
---
license: openrail
---

# Classifier-Bias-SG Model Card

## Model Details
Classifier-Bias-SG is a proof of concept model designed to classify texts based on their bias levels. The model categorizes texts into 2 classes: "Biased", and "Non-Biased".

## Model Architecture
The model is built upon the distilbert-base-uncased architecture and has been fine-tuned on a custom dataset for the specific task of bias detection.

## Dataset
The model was trained on a BABE dataset containing news articles from various sources, annotated with one of the 2 bias levels. The dataset contains:
- **Biased**: 1810 articles
- **Non-Biased**: 1810 articles

## Training Procedure
The model was trained using the Adam optimizer for 15 epochs.

## Performance
On our validation set, the model achieved:

- **Accuracy**: 78%
- **F1 Score (Biased)**: 79%
- **F1 Score (Non-Biased)**: 77%

## How to Use
To use this model for text classification, use the following code:

```python
from transformers import pipeline
from transformers import AutoTokenizer, AutoModelForSequenceClassification
 
tokenizer = AutoTokenizer.from_pretrained("Social-Media-Fairness/Classifier-Bias-SG")
model = AutoModelForSequenceClassification.from_pretrained("Social-Media-Fairness/Classifier-Bias-SG")

classifier = pipeline("text-classification", model=model, tokenizer=tokenizer)
result = classifier("Women are bad driver.")
print(result)
```

Developed by Shardul Ghuge