Views
No views yet
distilbert-base-uncased model from Hugging Face Transformers, further fine-tuned for sentiment classification. The base model is a lighter, faster version of BERT, suitable for various NLP tasks.distilbert-base-uncasedfp16=True was used to speed up training.pipeline:1from transformers import pipeline
2
3classifier = pipeline("sentiment-analysis", model="jackenmail/sentiment-analysis")
4
5text = "I absolutely loved this movie, it was fantastic!"
6result = classifier(text)
7print(result)
8# Output: {'label': 'POSITIVE', 'score': 0.99...}
9
10text = "This was a terrible experience, completely ruined my day."
11result = classifier(text)
12print(result)
13# Output: {'label': 'NEGATIVE', 'score': 0.99...}