Text Classification
Transformers
ONNX
Safetensors
Transformers.js
modernbert
toxicity
toxic-comment-classification
content-moderation
detoxify
multi-label-classification
mmbert
text-embeddings-inference
Instructions to use Horizon-Labs/multilingual-toxicity-base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Horizon-Labs/multilingual-toxicity-base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="Horizon-Labs/multilingual-toxicity-base")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("Horizon-Labs/multilingual-toxicity-base") model = AutoModelForSequenceClassification.from_pretrained("Horizon-Labs/multilingual-toxicity-base", device_map="auto") - Transformers.js
How to use Horizon-Labs/multilingual-toxicity-base with Transformers.js:
// npm i @huggingface/transformers import { pipeline } from '@huggingface/transformers'; // Allocate pipeline const pipe = await pipeline('text-classification', 'Horizon-Labs/multilingual-toxicity-base'); - Notebooks
- Google Colab
- Kaggle
Download eval/this_model.json from Horizon-Labs/multilingual-toxicity-base: direct link, hf CLI and curl.
- Browser
- Download file 2.16 kB
-
https://huggingface.co/Horizon-Labs/multilingual-toxicity-base/resolve/main/eval/this_model.json
- Command line
-
hf download hf://Horizon-Labs/multilingual-toxicity-base/eval/this_model.json
-
curl -L -o this_model.json https://huggingface.co/Horizon-Labs/multilingual-toxicity-base/resolve/main/eval/this_model.json
2.16 kB
| { | |
| "/fast/awuhrmann/agent-outputs/run-20260923-130458/af2b12ed-bc7f-44c8-8473-5eded3119c60/model": { | |
| "labels": [ | |
| "toxicity", | |
| "severe_toxicity", | |
| "obscene", | |
| "threat", | |
| "insult", | |
| "identity_attack", | |
| "sexual_explicit" | |
| ], | |
| "mapped": [ | |
| "toxicity", | |
| "severe_toxicity", | |
| "obscene", | |
| "threat", | |
| "insult", | |
| "identity_attack", | |
| "sexual_explicit" | |
| ], | |
| "civil_test": { | |
| "n": 20000, | |
| "auc": { | |
| "toxicity": 0.9713385430598546, | |
| "obscene": 0.9927044347644126, | |
| "threat": 0.9933599277450946, | |
| "insult": 0.9801924806827356, | |
| "identity_attack": 0.9903715411344962, | |
| "sexual_explicit": 0.9978641513217573 | |
| }, | |
| "mean_auc": 0.9876385131180586, | |
| "toxicity_auc": 0.9713385430598546 | |
| }, | |
| "tdx_am": { | |
| "n": 1000, | |
| "auc": 0.715652, | |
| "f1_05": 0.11173184357541899 | |
| }, | |
| "tdx_ar": { | |
| "n": 1000, | |
| "auc": 0.787258, | |
| "f1_05": 0.4489795918367347 | |
| }, | |
| "tdx_de": { | |
| "n": 1000, | |
| "auc": 0.858992, | |
| "f1_05": 0.3662420382165605 | |
| }, | |
| "tdx_en": { | |
| "n": 1000, | |
| "auc": 0.993412, | |
| "f1_05": 0.9470404984423676 | |
| }, | |
| "tdx_es": { | |
| "n": 1000, | |
| "auc": 0.906774, | |
| "f1_05": 0.6563307493540051 | |
| }, | |
| "tdx_fr": { | |
| "n": 1000, | |
| "auc": 0.987, | |
| "f1_05": 0.8283062645011601 | |
| }, | |
| "tdx_he": { | |
| "n": 1000, | |
| "auc": 0.788114, | |
| "f1_05": 0.42278860569715143 | |
| }, | |
| "tdx_hi": { | |
| "n": 1000, | |
| "auc": 0.910138, | |
| "f1_05": 0.2390158172231986 | |
| }, | |
| "tdx_hin": { | |
| "n": 1000, | |
| "auc": 0.764678, | |
| "f1_05": 0.15245009074410162 | |
| }, | |
| "tdx_it": { | |
| "n": 1000, | |
| "auc": 0.875268, | |
| "f1_05": 0.7331042382588774 | |
| }, | |
| "tdx_ja": { | |
| "n": 1000, | |
| "auc": 0.845672, | |
| "f1_05": 0.24253075571177504 | |
| }, | |
| "tdx_ru": { | |
| "n": 1000, | |
| "auc": 0.972622, | |
| "f1_05": 0.6265389876880985 | |
| }, | |
| "tdx_tt": { | |
| "n": 1000, | |
| "auc": 0.818246, | |
| "f1_05": 0.27101200686106347 | |
| }, | |
| "tdx_uk": { | |
| "n": 1000, | |
| "auc": 0.807558, | |
| "f1_05": 0.26440677966101694 | |
| }, | |
| "tdx_zh": { | |
| "n": 1000, | |
| "auc": 0.7745, | |
| "f1_05": 0.1889483065953654 | |
| }, | |
| "_civil_mean_auc": 0.9876385131180586, | |
| "_civil_toxicity_auc": 0.9713385430598546, | |
| "_tdx_mean_auc": 0.8537256000000001, | |
| "_tdx_mean_f1": 0.433295104957793 | |
| } | |
| } |