Instructions to use IMSyPP/hate_speech_slo with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use IMSyPP/hate_speech_slo with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="IMSyPP/hate_speech_slo")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("IMSyPP/hate_speech_slo") model = AutoModelForSequenceClassification.from_pretrained("IMSyPP/hate_speech_slo", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update config.json
Browse files- config.json +6 -0
config.json
CHANGED
|
@@ -2,6 +2,12 @@
|
|
| 2 |
"architectures": [
|
| 3 |
"BertForSequenceClassification"
|
| 4 |
],
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 5 |
"attention_probs_dropout_prob": 0.1,
|
| 6 |
"directionality": "bidi",
|
| 7 |
"finetuning_task": null,
|
|
|
|
| 2 |
"architectures": [
|
| 3 |
"BertForSequenceClassification"
|
| 4 |
],
|
| 5 |
+
"label2id": {
|
| 6 |
+
"acceptable": 0,
|
| 7 |
+
"innapropriate": 1,
|
| 8 |
+
"offensive": 2,
|
| 9 |
+
"violent": 3
|
| 10 |
+
},
|
| 11 |
"attention_probs_dropout_prob": 0.1,
|
| 12 |
"directionality": "bidi",
|
| 13 |
"finetuning_task": null,
|