Text Classification
Transformers
Safetensors
Bengali
English
xlm-roberta
safeage
safety-classification
bangla
banglish
text-embeddings-inference
Instructions to use mehedi4/SafeAge-XLM-R-Base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use mehedi4/SafeAge-XLM-R-Base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="mehedi4/SafeAge-XLM-R-Base")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("mehedi4/SafeAge-XLM-R-Base") model = AutoModelForSequenceClassification.from_pretrained("mehedi4/SafeAge-XLM-R-Base", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download evaluation/test_metrics.json from mehedi4/SafeAge-XLM-R-Base: direct link, hf CLI and curl.
- Browser
- Download file 1.45 kB
-
https://huggingface.co/mehedi4/SafeAge-XLM-R-Base/resolve/main/evaluation/test_metrics.json
- Command line
-
hf download hf://mehedi4/SafeAge-XLM-R-Base/evaluation/test_metrics.json
-
curl -L -o test_metrics.json https://huggingface.co/mehedi4/SafeAge-XLM-R-Base/resolve/main/evaluation/test_metrics.json
1.45 kB
| { | |
| "default_0_5": { | |
| "rows": 1204, | |
| "benign_rows": 756, | |
| "attack_rows": 448, | |
| "threshold": 0.5, | |
| "accuracy": 0.9127906976744186, | |
| "balanced_accuracy": 0.9000909391534392, | |
| "macro_f1": 0.9053775802797357, | |
| "attack_precision": 0.9093078758949881, | |
| "attack_recall": 0.8504464285714286, | |
| "attack_f1": 0.8788927335640139, | |
| "benign_specificity": 0.9497354497354498, | |
| "benign_false_positive_rate": 0.05026455026455026, | |
| "attack_false_negative_rate": 0.14955357142857142, | |
| "roc_auc": 0.970037320483749, | |
| "average_precision": 0.9595743795979578, | |
| "brier_score": 0.08266975804310862, | |
| "log_loss": 0.5941776420834323, | |
| "tn": 718, | |
| "fp": 38, | |
| "fn": 67, | |
| "tp": 381 | |
| }, | |
| "validation_selected": { | |
| "rows": 1204, | |
| "benign_rows": 756, | |
| "attack_rows": 448, | |
| "threshold": 0.99, | |
| "accuracy": 0.9102990033222591, | |
| "balanced_accuracy": 0.8917410714285714, | |
| "macro_f1": 0.9013842247522319, | |
| "attack_precision": 0.9314720812182741, | |
| "attack_recall": 0.8191964285714286, | |
| "attack_f1": 0.8717339667458432, | |
| "benign_specificity": 0.9642857142857143, | |
| "benign_false_positive_rate": 0.03571428571428571, | |
| "attack_false_negative_rate": 0.18080357142857142, | |
| "roc_auc": 0.970037320483749, | |
| "average_precision": 0.9595743795979578, | |
| "brier_score": 0.08266975804310862, | |
| "log_loss": 0.5941776420834323, | |
| "tn": 729, | |
| "fp": 27, | |
| "fn": 81, | |
| "tp": 367 | |
| } | |
| } | |