Fine-tune on MYUniDialectSentiment840 (840 samples, 14 dialects). Test acc=0.9796, F1_macro=0.9753.
Browse files- README.md +42 -234
- config.json +14 -12
- model.safetensors +2 -2
- tokenizer.json +2 -2
- training_args.bin +3 -0
- training_metrics.json +40 -0
README.md
CHANGED
|
@@ -1,253 +1,61 @@
|
|
| 1 |
---
|
| 2 |
language:
|
| 3 |
-
- en
|
| 4 |
- ms
|
| 5 |
-
|
| 6 |
tags:
|
| 7 |
-
- emotion-classification
|
| 8 |
-
- multilingual
|
| 9 |
-
- xlm-roberta
|
| 10 |
- text-classification
|
| 11 |
-
-
|
| 12 |
-
-
|
| 13 |
-
-
|
| 14 |
-
-
|
| 15 |
-
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
- custom-multilingual-emotion-dataset
|
| 19 |
-
metrics:
|
| 20 |
-
- accuracy
|
| 21 |
-
- f1
|
| 22 |
-
- precision
|
| 23 |
-
- recall
|
| 24 |
---
|
| 25 |
|
| 26 |
-
#
|
| 27 |
-
|
| 28 |
-
## 🚀 **TRY THE INTERACTIVE APP NOW!**
|
| 29 |
-
|
| 30 |
-
**🎮 [Launch Interactive Demo](https://huggingface.co/spaces/rmtariq/multilingual-emotion-classifier-demo)** ← Click to test the model in your browser!
|
| 31 |
-
|
| 32 |
-
A state-of-the-art multilingual emotion classification model with **85.0% accuracy**, **comprehensive Malay language support**, and **interactive web interface**.
|
| 33 |
-
|
| 34 |
-
## 🎭 **INTERACTIVE FEATURES**
|
| 35 |
-
|
| 36 |
-
### **🎯 Single Text Analysis**
|
| 37 |
-
- Real-time emotion classification
|
| 38 |
-
- Confidence scoring with visual gauges
|
| 39 |
-
- Support for English and Malay
|
| 40 |
-
- Interactive charts and visualizations
|
| 41 |
-
|
| 42 |
-
### **📊 Batch Processing**
|
| 43 |
-
- Analyze multiple texts simultaneously
|
| 44 |
-
- Emotion distribution charts
|
| 45 |
-
- Detailed results tables
|
| 46 |
-
- Export capabilities
|
| 47 |
-
|
| 48 |
-
### **🧪 Model Testing**
|
| 49 |
-
- Run predefined test cases
|
| 50 |
-
- Validate model performance
|
| 51 |
-
- Check accuracy across languages
|
| 52 |
-
- Verify all fixes are working
|
| 53 |
-
|
| 54 |
-
### **📱 User-Friendly Interface**
|
| 55 |
-
- Beautiful, responsive design
|
| 56 |
-
- No coding required
|
| 57 |
-
- Instant results
|
| 58 |
-
- Mobile-friendly
|
| 59 |
-
|
| 60 |
-
## 🚀 **Quick Start**
|
| 61 |
-
|
| 62 |
-
### **Option 1: Interactive Web App (Recommended)**
|
| 63 |
-
🎮 **[Try the Interactive Demo](https://huggingface.co/spaces/rmtariq/multilingual-emotion-classifier-demo)**
|
| 64 |
-
|
| 65 |
-
No installation required! Test the model directly in your browser.
|
| 66 |
-
|
| 67 |
-
### **Option 2: Python Code**
|
| 68 |
-
```python
|
| 69 |
-
from transformers import pipeline
|
| 70 |
-
|
| 71 |
-
classifier = pipeline(
|
| 72 |
-
"text-classification",
|
| 73 |
-
model="rmtariq/multilingual-emotion-classifier"
|
| 74 |
-
)
|
| 75 |
-
|
| 76 |
-
# English examples
|
| 77 |
-
result = classifier("I am so happy today!")
|
| 78 |
-
print(result) # [{'label': 'happy', 'score': 0.999}]
|
| 79 |
-
|
| 80 |
-
# Malay examples (now working perfectly!)
|
| 81 |
-
result = classifier("Ini adalah hari jadi terbaik!")
|
| 82 |
-
print(result) # [{'label': 'happy', 'score': 0.999}] ✅
|
| 83 |
-
|
| 84 |
-
result = classifier("Terbaik!")
|
| 85 |
-
print(result) # [{'label': 'happy', 'score': 0.999}] ✅
|
| 86 |
-
```
|
| 87 |
-
|
| 88 |
-
## 📊 **Performance Highlights**
|
| 89 |
-
- ✅ **Overall Accuracy**: 85.0%
|
| 90 |
-
- ✅ **F1 Macro Score**: 85.5%
|
| 91 |
-
- ✅ **English Performance**: 100.0% accuracy
|
| 92 |
-
- ✅ **Malay Performance**: 100% (all issues fixed)
|
| 93 |
-
- ✅ **Speed**: 20+ predictions/second
|
| 94 |
-
- ✅ **Interactive Demo**: Available for instant testing
|
| 95 |
-
|
| 96 |
-
## 🎯 **Supported Emotions**
|
| 97 |
-
|
| 98 |
-
| Emotion | Emoji | English Example | Malay Example | Demo Result |
|
| 99 |
-
|---------|-------|-----------------|---------------|-------------|
|
| 100 |
-
| **anger** | 😠 | "I'm so angry!" | "Marah betul!" | Try in demo! |
|
| 101 |
-
| **fear** | 😨 | "I'm scared!" | "Takut sangat!" | Try in demo! |
|
| 102 |
-
| **happy** | 😊 | "I'm so happy!" | "Gembira sangat!" | Try in demo! |
|
| 103 |
-
| **love** | ❤️ | "I love you!" | "Sayang kamu!" | Try in demo! |
|
| 104 |
-
| **sadness** | 😢 | "I'm so sad" | "Sedih betul" | Try in demo! |
|
| 105 |
-
| **surprise** | 😲 | "What a surprise!" | "Terkejut betul!" | Try in demo! |
|
| 106 |
|
| 107 |
-
|
|
|
|
|
|
|
| 108 |
|
| 109 |
-
##
|
| 110 |
-
``
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
``
|
|
|
|
| 116 |
|
| 117 |
-
|
| 118 |
|
| 119 |
-
|
|
|
|
|
|
|
|
|
|
| 120 |
|
| 121 |
-
##
|
| 122 |
-
🎮 **[Launch Interactive Demo](https://huggingface.co/spaces/rmtariq/multilingual-emotion-classifier-demo)**
|
| 123 |
-
- Web-based testing interface
|
| 124 |
-
- Real-time results
|
| 125 |
-
- Visual confidence charts
|
| 126 |
-
- Batch processing capabilities
|
| 127 |
|
| 128 |
-
|
| 129 |
-
|
| 130 |
-
|
| 131 |
-
pip install torch transformers numpy pandas scikit-learn
|
| 132 |
|
| 133 |
-
#
|
| 134 |
-
python test_model.py --test-type quick
|
| 135 |
|
| 136 |
-
|
| 137 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 138 |
|
| 139 |
-
#
|
| 140 |
-
python test_model.py --test-type interactive
|
| 141 |
-
```
|
| 142 |
|
| 143 |
-
|
| 144 |
-
|
| 145 |
-
# Run automated validation
|
| 146 |
-
python validate_model.py
|
| 147 |
-
|
| 148 |
-
# Generate validation report
|
| 149 |
-
python validate_model.py --output validation_report.json
|
| 150 |
-
```
|
| 151 |
-
|
| 152 |
-
## 🏭 **Production Use Cases**
|
| 153 |
-
|
| 154 |
-
### **✅ Social Media Monitoring**
|
| 155 |
-
```python
|
| 156 |
-
# Real-time emotion analysis
|
| 157 |
-
social_posts = [
|
| 158 |
-
"Love the new update! 😍",
|
| 159 |
-
"Suka sangat dengan produk ni!",
|
| 160 |
-
"This is frustrating...",
|
| 161 |
-
"Kecewa dengan service"
|
| 162 |
-
]
|
| 163 |
-
|
| 164 |
-
emotions = classifier(social_posts)
|
| 165 |
-
# Or test in the interactive demo!
|
| 166 |
-
```
|
| 167 |
-
|
| 168 |
-
### **✅ Customer Service Automation**
|
| 169 |
-
```python
|
| 170 |
-
# Automated ticket routing
|
| 171 |
-
support_messages = [
|
| 172 |
-
"I'm really upset about this issue",
|
| 173 |
-
"Marah betul dengan masalah ni",
|
| 174 |
-
"Thank you for the great service!",
|
| 175 |
-
"Terima kasih, service terbaik!"
|
| 176 |
-
]
|
| 177 |
-
|
| 178 |
-
# Route high-emotion tickets to human agents
|
| 179 |
-
# Test these examples in the interactive demo!
|
| 180 |
-
```
|
| 181 |
-
|
| 182 |
-
## 📈 **Performance Evolution**
|
| 183 |
-
|
| 184 |
-
| Phase | Accuracy | F1 Macro | Interactive Demo |
|
| 185 |
-
|-------|----------|----------|------------------|
|
| 186 |
-
| **Initial Baseline** | 17.5% | 8.7% | ❌ Not available |
|
| 187 |
-
| **Phase 1 Optimization** | 68.7% | 34.0% | ❌ Not available |
|
| 188 |
-
| **Phase 2 Optimized** | **85.0%** | **85.5%** | ❌ Not available |
|
| 189 |
-
| **Phase 3 + Interactive** | **85.0%** | **85.5%** | ✅ **Available!** |
|
| 190 |
-
|
| 191 |
-
**Total Improvement**: **4.9x performance gain** + **interactive web interface**
|
| 192 |
-
|
| 193 |
-
## 🎮 **How to Use the Interactive Demo**
|
| 194 |
-
|
| 195 |
-
1. **🔗 [Click here to open the demo](https://huggingface.co/spaces/rmtariq/multilingual-emotion-classifier-demo)**
|
| 196 |
-
2. **Choose a tab**: Single Text, Batch Analysis, or Model Testing
|
| 197 |
-
3. **Enter your text**: Type in English or Malay
|
| 198 |
-
4. **Get instant results**: See emotions, confidence, and visualizations
|
| 199 |
-
5. **Explore features**: Try batch processing and predefined tests
|
| 200 |
-
|
| 201 |
-
## 🧪 **Demo Features**
|
| 202 |
-
|
| 203 |
-
### **🎯 Single Text Analysis**
|
| 204 |
-
- Enter any text in English or Malay
|
| 205 |
-
- Get instant emotion classification
|
| 206 |
-
- See confidence scores with visual gauges
|
| 207 |
-
- Try the provided examples
|
| 208 |
-
|
| 209 |
-
### **📊 Batch Analysis**
|
| 210 |
-
- Process multiple texts at once
|
| 211 |
-
- See emotion distribution charts
|
| 212 |
-
- Get detailed results tables
|
| 213 |
-
- Perfect for analyzing conversations or reviews
|
| 214 |
-
|
| 215 |
-
### **🧪 Model Testing**
|
| 216 |
-
- Run 13 predefined test cases
|
| 217 |
-
- Validate model performance
|
| 218 |
-
- Check that all fixes are working
|
| 219 |
-
- See accuracy metrics
|
| 220 |
-
|
| 221 |
-
## 📞 **Contact & Resources**
|
| 222 |
-
|
| 223 |
-
- **🎮 Interactive Demo**: [Launch App](https://huggingface.co/spaces/rmtariq/multilingual-emotion-classifier-demo)
|
| 224 |
-
- **📖 Testing Guide**: See `TESTING_GUIDE.md` for comprehensive testing
|
| 225 |
-
- **🤖 Model Repository**: [rmtariq/multilingual-emotion-classifier](https://huggingface.co/rmtariq/multilingual-emotion-classifier)
|
| 226 |
-
- **👨💻 Author**: rmtariq
|
| 227 |
-
|
| 228 |
-
## 📚 **Citation**
|
| 229 |
-
|
| 230 |
-
```bibtex
|
| 231 |
-
@misc{rmtariq2024multilingual_interactive,
|
| 232 |
-
title={Interactive Multilingual Emotion Classification with Web Demo},
|
| 233 |
-
author={rmtariq},
|
| 234 |
-
year={2024},
|
| 235 |
-
publisher={Hugging Face},
|
| 236 |
-
url={https://huggingface.co/rmtariq/multilingual-emotion-classifier},
|
| 237 |
-
note={Version 2.1 with interactive Gradio demo}
|
| 238 |
-
}
|
| 239 |
-
```
|
| 240 |
-
|
| 241 |
-
## 📄 **License**
|
| 242 |
-
|
| 243 |
-
This model is released under the Apache 2.0 License.
|
| 244 |
-
|
| 245 |
-
---
|
| 246 |
|
| 247 |
-
|
| 248 |
-
**🚀 Performance**: 85.0% Accuracy, 85.5% F1 Macro
|
| 249 |
-
**🌍 Languages**: English, Malay (Fully Fixed)
|
| 250 |
-
**🎮 Demo**: Interactive Web Interface Available
|
| 251 |
-
**📅 Last Updated**: June 2024 (Version 2.1)
|
| 252 |
|
| 253 |
-
|
|
|
|
|
|
| 1 |
---
|
| 2 |
language:
|
|
|
|
| 3 |
- ms
|
| 4 |
+
- en
|
| 5 |
tags:
|
|
|
|
|
|
|
|
|
|
| 6 |
- text-classification
|
| 7 |
+
- emotion
|
| 8 |
+
- malaysian
|
| 9 |
+
- bahasa-malaysia
|
| 10 |
+
- code-switching
|
| 11 |
+
- educational
|
| 12 |
+
license: apache-2.0
|
| 13 |
+
pipeline_tag: text-classification
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
---
|
| 15 |
|
| 16 |
+
# rmtariq/multilingual-emotion-classifier
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17 |
|
| 18 |
+
Fine-tuned emotion classifier (7-class) for Malaysian higher-education
|
| 19 |
+
feedback. Trained on **MYUniDialectSentiment840 (840 samples, 14 dialects, 20 topics, 15 learning contexts)**, a hand-curated balanced corpus covering
|
| 20 |
+
Standard Malay, 13 regional dialects, and Manglish code-switching.
|
| 21 |
|
| 22 |
+
## Labels
|
| 23 |
+
- `happy`
|
| 24 |
+
- `love`
|
| 25 |
+
- `surprise`
|
| 26 |
+
- `no_clear_emotion`
|
| 27 |
+
- `sadness`
|
| 28 |
+
- `anger`
|
| 29 |
+
- `fear`
|
| 30 |
|
| 31 |
+
## Held-out test metrics (n=147, stratified)
|
| 32 |
|
| 33 |
+
| split | accuracy | f1_macro |
|
| 34 |
+
|---|---:|---:|
|
| 35 |
+
| validation (n=105) | 0.9524 | 0.9440 |
|
| 36 |
+
| test (n=147) | 0.9796 | 0.9753 |
|
| 37 |
|
| 38 |
+
## Intended use
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 39 |
|
| 40 |
+
Sentiment / emotion monitoring of student feedback for Malaysian
|
| 41 |
+
higher-education institutions. Designed to handle code-switched,
|
| 42 |
+
dialect-heavy and informal academic discourse.
|
|
|
|
| 43 |
|
| 44 |
+
## Training details
|
|
|
|
| 45 |
|
| 46 |
+
- Base: previous revision of `rmtariq/multilingual-emotion-classifier`
|
| 47 |
+
- Optimizer: AdamW (lr=2e-5, weight_decay=0.01, warmup_ratio=0.1)
|
| 48 |
+
- Epochs: 5 with early stopping on validation macro-F1
|
| 49 |
+
- Batch size: 16 (train) / 32 (eval), max_length=128
|
| 50 |
+
- Hardware: Apple Silicon MPS
|
| 51 |
+
- Class-weighted cross-entropy (for emotion only)
|
| 52 |
|
| 53 |
+
## Dataset
|
|
|
|
|
|
|
| 54 |
|
| 55 |
+
`MYUniDialectSentiment840` — 840 samples, balanced on sentiment, stratified
|
| 56 |
+
70/12.5/17.5 train/val/test by sentiment-x-dialect.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 57 |
|
| 58 |
+
## Citation / authors
|
|
|
|
|
|
|
|
|
|
|
|
|
| 59 |
|
| 60 |
+
- Raja Mohd Tariqi B. Raja Lope Ahmad — Ts., Fiscal Digest Sdn. Bhd.
|
| 61 |
+
- Raja Qatrun Nada Bin Raja Mohd Tariqi — Master of Education, UKM
|
config.json
CHANGED
|
@@ -5,27 +5,30 @@
|
|
| 5 |
"attention_probs_dropout_prob": 0.1,
|
| 6 |
"bos_token_id": 0,
|
| 7 |
"classifier_dropout": null,
|
|
|
|
| 8 |
"eos_token_id": 2,
|
| 9 |
"hidden_act": "gelu",
|
| 10 |
"hidden_dropout_prob": 0.1,
|
| 11 |
"hidden_size": 768,
|
| 12 |
"id2label": {
|
| 13 |
-
"0": "
|
| 14 |
-
"1": "
|
| 15 |
-
"2": "
|
| 16 |
-
"3": "
|
| 17 |
"4": "sadness",
|
| 18 |
-
"5": "
|
|
|
|
| 19 |
},
|
| 20 |
"initializer_range": 0.02,
|
| 21 |
"intermediate_size": 3072,
|
| 22 |
"label2id": {
|
| 23 |
-
"anger":
|
| 24 |
-
"fear":
|
| 25 |
-
"happy":
|
| 26 |
-
"love":
|
|
|
|
| 27 |
"sadness": 4,
|
| 28 |
-
"surprise":
|
| 29 |
},
|
| 30 |
"layer_norm_eps": 1e-05,
|
| 31 |
"max_position_embeddings": 514,
|
|
@@ -36,8 +39,7 @@
|
|
| 36 |
"pad_token_id": 1,
|
| 37 |
"position_embedding_type": "absolute",
|
| 38 |
"problem_type": "single_label_classification",
|
| 39 |
-
"
|
| 40 |
-
"transformers_version": "4.52.4",
|
| 41 |
"type_vocab_size": 1,
|
| 42 |
"use_cache": true,
|
| 43 |
"vocab_size": 250002
|
|
|
|
| 5 |
"attention_probs_dropout_prob": 0.1,
|
| 6 |
"bos_token_id": 0,
|
| 7 |
"classifier_dropout": null,
|
| 8 |
+
"dtype": "float32",
|
| 9 |
"eos_token_id": 2,
|
| 10 |
"hidden_act": "gelu",
|
| 11 |
"hidden_dropout_prob": 0.1,
|
| 12 |
"hidden_size": 768,
|
| 13 |
"id2label": {
|
| 14 |
+
"0": "happy",
|
| 15 |
+
"1": "love",
|
| 16 |
+
"2": "surprise",
|
| 17 |
+
"3": "no_clear_emotion",
|
| 18 |
"4": "sadness",
|
| 19 |
+
"5": "anger",
|
| 20 |
+
"6": "fear"
|
| 21 |
},
|
| 22 |
"initializer_range": 0.02,
|
| 23 |
"intermediate_size": 3072,
|
| 24 |
"label2id": {
|
| 25 |
+
"anger": 5,
|
| 26 |
+
"fear": 6,
|
| 27 |
+
"happy": 0,
|
| 28 |
+
"love": 1,
|
| 29 |
+
"no_clear_emotion": 3,
|
| 30 |
"sadness": 4,
|
| 31 |
+
"surprise": 2
|
| 32 |
},
|
| 33 |
"layer_norm_eps": 1e-05,
|
| 34 |
"max_position_embeddings": 514,
|
|
|
|
| 39 |
"pad_token_id": 1,
|
| 40 |
"position_embedding_type": "absolute",
|
| 41 |
"problem_type": "single_label_classification",
|
| 42 |
+
"transformers_version": "4.57.6",
|
|
|
|
| 43 |
"type_vocab_size": 1,
|
| 44 |
"use_cache": true,
|
| 45 |
"vocab_size": 250002
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:1d60839eba81934d24fdd0de8df4607b215e71954fe0133eefe2c876011c2c81
|
| 3 |
+
size 1112220388
|
tokenizer.json
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e63c7a5faf7f3257542d756311f64572a52913c2845c4a3849529e1ef87f8eef
|
| 3 |
+
size 17082832
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f43ab5a58a6bdafe9a63f3a5ba9437d45634e88fdd715a699af80782bef28593
|
| 3 |
+
size 5905
|
training_metrics.json
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"validation": {
|
| 3 |
+
"eval_loss": 0.2610369622707367,
|
| 4 |
+
"eval_accuracy": 0.9523809523809523,
|
| 5 |
+
"eval_f1_macro": 0.9440484327702372,
|
| 6 |
+
"eval_f1_weighted": 0.9526608729616249,
|
| 7 |
+
"eval_runtime": 0.1854,
|
| 8 |
+
"eval_samples_per_second": 566.462,
|
| 9 |
+
"eval_steps_per_second": 21.58,
|
| 10 |
+
"epoch": 5.0
|
| 11 |
+
},
|
| 12 |
+
"test": {
|
| 13 |
+
"test_loss": 0.16173337399959564,
|
| 14 |
+
"test_accuracy": 0.9795918367346939,
|
| 15 |
+
"test_f1_macro": 0.9753212396069539,
|
| 16 |
+
"test_f1_weighted": 0.9800003599323326,
|
| 17 |
+
"test_runtime": 0.3085,
|
| 18 |
+
"test_samples_per_second": 476.463,
|
| 19 |
+
"test_steps_per_second": 16.206,
|
| 20 |
+
"epoch": 5.0
|
| 21 |
+
},
|
| 22 |
+
"class_weights": [
|
| 23 |
+
0.8235294117647058,
|
| 24 |
+
1.2352941176470589,
|
| 25 |
+
2.1,
|
| 26 |
+
0.46153846153846156,
|
| 27 |
+
1.1506849315068493,
|
| 28 |
+
1.2173913043478262,
|
| 29 |
+
1.5555555555555556
|
| 30 |
+
],
|
| 31 |
+
"label2id": {
|
| 32 |
+
"happy": 0,
|
| 33 |
+
"love": 1,
|
| 34 |
+
"surprise": 2,
|
| 35 |
+
"no_clear_emotion": 3,
|
| 36 |
+
"sadness": 4,
|
| 37 |
+
"anger": 5,
|
| 38 |
+
"fear": 6
|
| 39 |
+
}
|
| 40 |
+
}
|