Views
No views yet
| Feature | Description |
|---|---|
| Transformer Encoder Backbone | Built using a custom multi-head self-attention encoder with AddNorm, FeedForward, and dropout. |
| Emotion-Aware Output | Classifies text into six universal emotions: joy, sadness, anger, fear, surprise, and disgust. |
| LLM-Optimized Representations | Mean pooling generates compact, interpretable vectors ideal for prompt engineering and fine-tuning. |
| Fully Configurable | Easily adjust depth, embedding dimensions, number of heads, FFN size, and vocab size via config. |
| Hugging Face Compatibility | Integrated with AutoModel and AutoTokenizer for frictionless usage in production pipelines. |
transformers library.pip install transformers torch1from transformers import AutoTokenizer, AutoModelForSequenceClassification
2import torch
3
4model_name = "sanjithrj/FeelWiseEmotion"
5tokenizer = AutoTokenizer.from_pretrained(model_name)
6model = AutoModelForSequenceClassification.from_pretrained(model_name)
7
8text = "I'm feeling really overwhelmed and anxious today."
9inputs = tokenizer(text, return_tensors="pt")
10logits = model(**inputs).logits
11pred = torch.argmax(logits).item()
12print(f"Predicted Emotion: {model.config.id2label[pred]}")1logits = model(**inputs).logits
2# Output: tensor([[-0.18, 2.73, 0.41, 1.12, 0.09, -0.45]])
3# → Predicted class index: 1 → Emotion: "Sadness"1{
2 "model_type": "FeelWiseEmotion",
3 "n_layers": 1,
4 "d_model": 256,
5 "n_head": 8,
6 "d_ff": 1024,
7 "max_len": 500,
8 "input_vocab_size": 50000,
9 "dropout": 0.1,
10 "num_classes": 6
11}A popular benchmark for emotion classification covering multiple real-world expressions.
transformers, datasets, or model cards added as well?