tensorboard safetensors xlm-roberta text-classification emotion-detection machine-learning slovak sk license:mit region:us
---
language:
- sk
license: mit
metrics:
- precision
- recall
- f1-score
- accuracy
model_name: poltextlab/xlm-roberta-large-pooled-slovak-emotions9-v2
tags:
- text-classification
- emotion-detection
- machine-learning
- slovak
extra_gated_fields:
  Name: text
  Country: country
  Institution: text
  Institution Email: text
  Please specify your academic use case: text
extra_gated_prompt: Our models are intended for academic use only. If you are not
  affiliated with an academic institution, please provide a rationale for using our
  models. Please allow us a few business days to manually review subscriptions.
---

# poltextlab/xlm-roberta-large-pooled-slovak-emotions9-v2
### Proposal 2B: German to Slovak Emotion Labeling (v2)

## Model Description

This model is designed for **emotion classification** in Slovak texts that have been translated from German.  
It was fine-tuned to recognize **nine emotion categories** and trained on a dataset with labeled examples.

## Labels and Their Meanings

| Label | Emotion      |
|--------|----------------|
| 0      | Anger        |
| 1      | Fear         |
| 2      | Disgust      |
| 3      | Sadness      |
| 4      | Joy          |
| 5      | None of them |
| 6      | Enthusiasm   |
| 7      | Hope         |
| 8      | Pride        |

## Evaluation Metrics

The model was evaluated using **precision, recall, f1-score, and accuracy**.

### Classification Report

| Label             | Precision | Recall | F1-score | Support |
|-------------------|-----------|--------|----------|---------|
| Anger (0)         | 0.52      | 0.55   | 0.54     | 777     |
| Fear (1)          | 0.84      | 0.76   | 0.80     | 776     |
| Disgust (2)       | 0.93      | 0.93   | 0.93     | 776     |
| Sadness (3)       | 0.87      | 0.83   | 0.85     | 775     |
| Joy (4)           | 0.80      | 0.73   | 0.76     | 736     |
| None of them (5)  | 0.60      | 0.61   | 0.61     | 1594    |
| Enthusiasm (6)    | 0.60      | 0.63   | 0.62     | 776     |
| Hope (7)          | 0.51      | 0.52   | 0.52     | 777     |
| Pride (8)         | 0.76      | 0.78   | 0.77     | 776     |

#### Overall Performance:

- **Accuracy**: 70%
- **Macro Avg**: Precision: 0.71, Recall: 0.71, F1-score: 0.71
- **Weighted Avg**: Precision: 0.70, Recall: 0.70, F1-score: 0.70

## How to Use

To use this model for text classification in Python:

```python
from transformers import pipeline

classifier = pipeline("text-classification", model="poltextlab/xlm-roberta-large-pooled-slovak-emotions9-v2", use_auth_token="<HF_TOKEN>")

text = "Som veľmi rada, že ste tu!" 
result = classifier(text)
print(result)
```