Views
No views yet
1# Use a pipeline as a high-level helper
2from transformers import pipeline
3
4pipe = pipeline("text-classification", model="wetey/MARBERT-LHSAB")
51# Load model directly
2from transformers import AutoTokenizer, AutoModelForSequenceClassification
3
4tokenizer = AutoTokenizer.from_pretrained("wetey/MARBERT-LHSAB")
5model = AutoModelForSequenceClassification.from_pretrained("wetey/MARBERT-LHSAB")
6evaluation_strategy = 'epoch'
logging_steps = 1,
num_train_epochs = 5,
learning_rate = 1e-5,
eval_accumulation_steps = 2accuracy: 87.9% precision: 88.1% recall: 87.9% f1-score: 87.9% | Label | Precision | Recall | F1-score |
|---|---|---|---|
| normal | 85% | 82% | 83% |
| abusive | 93% | 92% | 93% |
| hate | 68% | 78% | 72% |