Update README.md
Browse files
README.md
CHANGED
@@ -33,7 +33,24 @@ HateBERTimbau is a transformer-based encoder model for identifying hate speech i
|
|
33 |
|
34 |
# Uses
|
35 |
|
36 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
37 |
|
38 |
# Training
|
39 |
|
|
|
33 |
|
34 |
# Uses
|
35 |
|
36 |
+
You can use this model directly with a pipeline for hate speech classification:
|
37 |
+
|
38 |
+
```python
|
39 |
+
from transformers import pipeline
|
40 |
+
pipe = pipeline("text-classification", model="knowhate/HateBERTimbau")
|
41 |
+
|
42 |
+
result = pipe("As pessoas tem que perceber que ser 'panasca' não é deixar de ser homem, é deixar de ser humano 😂😂")
|
43 |
+
|
44 |
+
[{'label': 'Hate Speech', 'score': 0.5513273477554321}]
|
45 |
+
|
46 |
+
```
|
47 |
+
|
48 |
+
Or this model can be used by fine-tuning it for a specific task/dataset:
|
49 |
+
|
50 |
+
```python
|
51 |
+
|
52 |
+
|
53 |
+
```
|
54 |
|
55 |
# Training
|
56 |
|