Hate Speech Detection
Collection
6 items
•
Updated
Fine‑tuned from uitnlp/visobert
on the VN‑HSD unified Vietnamese hate‐speech dataset, combining ViHSD, ViCTSD, and ViHOS.
uitnlp/visobert
32
3e-5
100
256
<INSERT_ACCURACY>
<INSERT_F1_SCORE>
from transformers import AutoTokenizer, AutoModelForSequenceClassification
tokenizer = AutoTokenizer.from_pretrained("visolex/visobert-hsd")
model = AutoModelForSequenceClassification.from_pretrained("visolex/visobert-hsd")
text = "Hắn ta thật kinh tởm!"
inputs = tokenizer(text, return_tensors="pt", truncation=True, max_length=256)
logits = model(**inputs).logits
pred = logits.argmax(dim=-1).item()
label_map = {0: "CLEAN", 1: "OFFENSIVE", 2: "HATE"}
print(f"Predicted label: {label_map[pred]}")
Base model
uitnlp/visobert