File size: 2,374 Bytes
73cc8d2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | from __future__ import annotations
from mteb.abstasks.TaskMetadata import TaskMetadata
from ....abstasks import AbsTaskClassification
class GermanPoliticiansTwitterSentimentClassification(AbsTaskClassification):
metadata = TaskMetadata(
name="GermanPoliticiansTwitterSentimentClassification",
description="GermanPoliticiansTwitterSentiment is a dataset of German tweets categorized with their sentiment (3 classes).",
reference="https://aclanthology.org/2022.konvens-1.9",
dataset={
"path": "Alienmaster/german_politicians_twitter_sentiment",
"revision": "65343b17f5a76227ab2e15b9424dfab6466ffcb1",
},
type="Classification",
category="s2s",
eval_splits=["test"],
eval_langs=["deu-Latn"],
main_score="accuracy",
date=("2021-01-01", "2021-12-31"),
form=["written"],
domains=["Social", "Government"],
task_subtypes=["Sentiment/Hate speech"],
license="Not specified",
socioeconomic_status="high",
annotations_creators="human-annotated",
dialect=[],
text_creation="found",
bibtex_citation="""
@inproceedings{schmidt-etal-2022-sentiment,
title = "Sentiment Analysis on {T}witter for the Major {G}erman Parties during the 2021 {G}erman Federal Election",
author = "Schmidt, Thomas and
Fehle, Jakob and
Weissenbacher, Maximilian and
Richter, Jonathan and
Gottschalk, Philipp and
Wolff, Christian",
editor = "Schaefer, Robin and
Bai, Xiaoyu and
Stede, Manfred and
Zesch, Torsten",
booktitle = "Proceedings of the 18th Conference on Natural Language Processing (KONVENS 2022)",
month = "12--15 " # sep,
year = "2022",
address = "Potsdam, Germany",
publisher = "KONVENS 2022 Organizers",
url = "https://aclanthology.org/2022.konvens-1.9",
pages = "74--87",
}
""",
n_samples={"test": 357},
avg_character_length={"test": 302.48},
)
def dataset_transform(self):
self.dataset = self.dataset.rename_column("majority_sentiment", "label")
|