jitesh/emotion-english

text classificationtransformersentransformerspytorchsafetensorsrobertatext-classificationemotionmit
180.0K

Emotion classification from 20 classes

20 Emotion labels

idlabel
0anger
1cheeky
2confuse
3curious
4disgust
5empathetic
6energetic
7fear
8grumpy
9guilty
10impatient
11joy
12love
13neutral
14sadness
15serious
16surprise
17suspicious
18think
19whiny

How to use

Here is how to use this model to get the emotion label of a given text:

from transformers import AutoModelForSequenceClassification, pipeline

model_name = 'jitesh/emotion-english'
model = AutoModelForSequenceClassification.from_pretrained(model_name)
classifier = pipeline("text-classification", model=model, tokenizer=model_name)

text = "I can't wait any longer "

prediction = classifier(text)
print(prediction[0], text)

The above code outputs the following line.

{'label': 'impatient', 'score': 0.924211859703064} I can't wait any longer 
DEPLOY IN 60 SECONDS

Run emotion-english on Runcrate

Deploy on H100, A100, or RTX GPUs. Pay only for what you use. No setup required.