
## [PhoBert](https://huggingface.co/vinai/phobert-base/tree/main) finetuned version for hate speech detection

## Dataset
- [**VLSP2019**](https://github.com/sonlam1102/vihsd): Hate Speech Detection on Social Networks Dataset
- [**ViHSD**](https://vlsp.org.vn/vlsp2019/eval/hsd): Vietnamese Hate Speech Detection dataset

## Class name
- LABEL_0 : **Normal**
- LABEL_1 : **OFFENSIVE**
- LABEL_2 : **HATE**


## Usage example with **TextClassificationPipeline**
```python
from transformers import AutoModelForSequenceClassification, AutoTokenizer, TextClassificationPipeline


model = AutoModelForSequenceClassification.from_pretrained("tsdocode/phobert-finetune-hatespeech", num_labels=3)
tokenizer = AutoTokenizer.from_pretrained("tsdocode/phobert-finetune-hatespeech")


pipe = TextClassificationPipeline(model=model, tokenizer=tokenizer, return_all_scores=True)
# outputs a list of dicts like [[{'label': 'NEGATIVE', 'score': 0.0001223755971295759},  {'label': 'POSITIVE', 'score': 0.9998776316642761}]]
pipe("đồ ngu")

```
{"language": ["vi"], "tags": ["classification"], "widget": [{"text": "X\u1ea5u vcl", "example_title": "C\u00f4ng k\u00edch"}, {"text": "\u0110\u1ed3 ngu", "example_title": "Th\u00f9 gh\u00e9t"}, {"text": "Xin ch\u00e0o ch\u00fac m\u1ed9t ng\u00e0y t\u1ed1t l\u00e0nh", "example_title": "Normal"}]}
transformers pytorch roberta text-classification classification vi autotrain_compatible endpoints_compatible region:us
TAGS
#transformers #pytorch #roberta #text-classification #classification #vi #autotrain_compatible #endpoints_compatible #region-us 


## PhoBert finetuned version for hate speech detection

## Dataset
- VLSP2019: Hate Speech Detection on Social Networks Dataset
- ViHSD: Vietnamese Hate Speech Detection dataset

## Class name
- LABEL_0 : Normal
- LABEL_1 : OFFENSIVE
- LABEL_2 : HATE


## Usage example with TextClassificationPipeline

## PhoBert finetuned version for hate speech detection ## Dataset
- VLSP2019: Hate Speech Detection on Social Networks Dataset
- ViHSD: Vietnamese Hate Speech Detection dataset ## Class name
- LABEL_0 : Normal
- LABEL_1 : OFFENSIVE
- LABEL_2 : HATE ## Usage example with TextClassificationPipeline
TAGS
#transformers #pytorch #roberta #text-classification #classification #vi #autotrain_compatible #endpoints_compatible #region-us 
 ## PhoBert finetuned version for hate speech detection ## Dataset
- VLSP2019: Hate Speech Detection on Social Networks Dataset
- ViHSD: Vietnamese Hate Speech Detection dataset ## Class name
- LABEL_0 : Normal
- LABEL_1 : OFFENSIVE
- LABEL_2 : HATE ## Usage example with TextClassificationPipeline
passage: TAGS
#transformers #pytorch #roberta #text-classification #classification #vi #autotrain_compatible #endpoints_compatible #region-us 
## PhoBert finetuned version for hate speech detection## Dataset
- VLSP2019: Hate Speech Detection on Social Networks Dataset
- ViHSD: Vietnamese Hate Speech Detection dataset## Class name
- LABEL_0 : Normal
- LABEL_1 : OFFENSIVE
- LABEL_2 : HATE## Usage example with TextClassificationPipeline