Views
No views yet
1from transformers import pipeline
2text= "I’m tired of being sick.. it’s been four days dawg"
3
4pipe = pipeline('text-classification', model="cardiffnlp/twitter-roberta-base-emoji-latest", return_all_scores=True))
5predictions = pipe(text)[0]
6predictions = sorted(predictions, key=lambda d: d['score'], reverse=True)
7predictions[:5]
8>> [{'label': '😒', 'score': 0.14303581416606903},
9 {'label': '😩', 'score': 0.07775110006332397},
10 {'label': '😤', 'score': 0.0710175409913063},
11 {'label': '😑', 'score': 0.06665993481874466},
12 {'label': '😫', 'score': 0.0662984848022461}]1@inproceedings{antypas2023supertweeteval,
2 title={SuperTweetEval: A Challenging, Unified and Heterogeneous Benchmark for Social Media NLP Research},
3 author={Dimosthenis Antypas and Asahi Ushio and Francesco Barbieri and Leonardo Neves and Kiamehr Rezaee and Luis Espinosa-Anke and Jiaxin Pei and Jose Camacho-Collados},
4 booktitle={Findings of the Association for Computational Linguistics: EMNLP 2023},
5 year={2023}
6}