Instructions to use GroNLP/bert_dutch_base_offensive_language with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use GroNLP/bert_dutch_base_offensive_language with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="GroNLP/bert_dutch_base_offensive_language")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("GroNLP/bert_dutch_base_offensive_language") model = AutoModelForSequenceClassification.from_pretrained("GroNLP/bert_dutch_base_offensive_language", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| license: apache-2.0 | |
| language: | |
| - nl | |
| pipeline_tag: text-classification | |
| Fine-tuned model for detecting instances of offensive language in Dutch tweets. The model has been trained with [DALC v2.0 ](https://github.com/tommasoc80/DALC). | |
| Offensive language definition is inherited from SemEval 2019 OffensEval: "Posts containing any form of non-acceptable language (profanity) or a targeted offence, | |
| which can be veiled or direct. This includes insults, threats, and posts containing profane language or swear words." ([Zampieri et al., 2019](https://aclanthology.org/N19-1144/)) | |
| The model achieves the following results on multiple test data: | |
| - DALC held-out test set: macro F1: 79.93; F1 Offensive: 70.34 | |
| - HateCheck-NL (functional benchmark for hate speech): Accuracy: 61.40; Accuracy non-hateful tests: 47.61 ; Accuracy hateful tests: 68.86 | |
| - OP-NL (dynamic benchmark for offensive language): macro F1: 73.56 | |
| More details on the training settings and pre-processing are available [here](https://github.com/tommasoc80/DALC) | |