Instructions to use Nakul24/Spanbert-emotion-extraction with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Nakul24/Spanbert-emotion-extraction with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "question-answering" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("question-answering", model="Nakul24/Spanbert-emotion-extraction")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForQuestionAnswering tokenizer = AutoTokenizer.from_pretrained("Nakul24/Spanbert-emotion-extraction") model = AutoModelForQuestionAnswering.from_pretrained("Nakul24/Spanbert-emotion-extraction", device_map="auto") - Notebooks
- Google Colab
- Kaggle
YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
Enter the Name of Emotion in the Question Field
Enter The Text from which emotion has to be extracted
Example 1- Question - Guilty
Context - I shouted to my mom
Example 2 -
Question - Sad
Context - I felt betrayed when my girlfriend kissed another guy even though she was drunk
Note: Model is still under development stage so results might be a little strange
- Downloads last month
- 35