Datasets:
Tasks:
Text Classification
Modalities:
Text
Formats:
parquet
Languages:
Swahili (macrolanguage)
Size:
1M - 10M
License:
Add dataset README
Browse files
README.md
CHANGED
@@ -1,22 +1,88 @@
|
|
1 |
---
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
configs:
|
15 |
-
- config_name: default
|
16 |
-
data_files:
|
17 |
-
- split: train
|
18 |
-
path: data/train-*
|
19 |
---
|
20 |
-
# Dataset Card for "swahili-emotions-corpus"
|
21 |
|
22 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
license: mit
|
3 |
+
task_categories:
|
4 |
+
- text-classification
|
5 |
+
language:
|
6 |
+
- swa
|
7 |
+
tags:
|
8 |
+
- emotion
|
9 |
+
- african-languages
|
10 |
+
- nlp
|
11 |
+
- text-classification
|
12 |
+
size_categories:
|
13 |
+
- 1M<n<10M
|
|
|
|
|
|
|
|
|
|
|
14 |
---
|
|
|
15 |
|
16 |
+
# Swahili Emotion Analysis Corpus
|
17 |
+
|
18 |
+
## Dataset Description
|
19 |
+
|
20 |
+
This dataset contains emotion-labeled text data in Swahili for emotion classification (joy, sadness, anger, fear, surprise, disgust, neutral). Emotions were extracted and processed from the English meanings of the sentences using the model `j-hartmann/emotion-english-distilroberta-base`. The dataset is part of a larger collection of African language emotion analysis resources.
|
21 |
+
|
22 |
+
## Dataset Statistics
|
23 |
+
|
24 |
+
- **Total samples**: 2,000,000
|
25 |
+
- **Joy**: 147146 (7.4%)
|
26 |
+
- **Sadness**: 114445 (5.7%)
|
27 |
+
- **Anger**: 125076 (6.3%)
|
28 |
+
- **Fear**: 89559 (4.5%)
|
29 |
+
- **Surprise**: 105550 (5.3%)
|
30 |
+
- **Disgust**: 162737 (8.1%)
|
31 |
+
- **Neutral**: 1255487 (62.8%)
|
32 |
+
|
33 |
+
## Dataset Structure
|
34 |
+
|
35 |
+
### Data Fields
|
36 |
+
|
37 |
+
- **Text Column**: Contains the original text in Swahili
|
38 |
+
- **emotion**: Emotion label (joy, sadness, anger, fear, surprise, disgust, neutral)
|
39 |
+
|
40 |
+
### Data Splits
|
41 |
+
|
42 |
+
This dataset contains a single split with all the processed data.
|
43 |
+
|
44 |
+
## Data Processing
|
45 |
+
|
46 |
+
The emotion labels were generated using:
|
47 |
+
- Model: `j-hartmann/emotion-english-distilroberta-base`
|
48 |
+
- Processing: Batch processing with optimization for efficiency
|
49 |
+
- Deduplication: Duplicate entries were removed based on text content
|
50 |
+
|
51 |
+
## Usage
|
52 |
+
|
53 |
+
```python
|
54 |
+
from datasets import load_dataset
|
55 |
+
|
56 |
+
# Load the dataset
|
57 |
+
dataset = load_dataset("michsethowusu/swahili-emotions-corpus")
|
58 |
+
|
59 |
+
# Access the data
|
60 |
+
print(dataset['train'][0])
|
61 |
+
```
|
62 |
+
|
63 |
+
## Citation
|
64 |
+
|
65 |
+
If you use this dataset in your research, please cite:
|
66 |
+
|
67 |
+
```bibtex
|
68 |
+
@dataset{swahili_emotions_corpus,
|
69 |
+
title={Swahili Emotions Corpus},
|
70 |
+
author={Mich-Seth Owusu},
|
71 |
+
year={2025},
|
72 |
+
url={https://huggingface.co/datasets/michsethowusu/swahili-emotions-corpus}
|
73 |
+
}
|
74 |
+
```
|
75 |
+
|
76 |
+
## License
|
77 |
+
|
78 |
+
This dataset is released under the MIT License.
|
79 |
+
|
80 |
+
## Contact
|
81 |
+
|
82 |
+
For questions or issues regarding this dataset, please open an issue on the dataset repository.
|
83 |
+
|
84 |
+
## Dataset Creation
|
85 |
+
|
86 |
+
**Date**: 2025-07-04
|
87 |
+
**Processing Pipeline**: Automated emotion analysis using HuggingFace Transformers
|
88 |
+
**Quality Control**: Deduplication and batch processing optimizations applied
|