Downloads · 30 days
20
51% of all-time downloads
Riddhi2952/financial-sentiment-distilbert
financial-sentiment-distilbert is a text classification model from Riddhi2952. Use it when you need a label for a piece of text. The card lists the license as apache-2.0.
Fine-tuned DistilBERT model for financial news sentiment classification.
Downloads · 30 days
20
51% of all-time downloads
All-time downloads
39
Public
Parameters
67M
268 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors268 MB · 100%
From the Hugging Face model README
Fine-tuned DistilBERT model for financial news sentiment classification.
This model classifies financial news headlines into three sentiment categories:
| Metric | Score |
|---|---|
| Accuracy | 84.43% |
| Macro F1 | 0.80 |
| Bearish F1 | 0.74 |
| Bullish F1 | 0.77 |
| Neutral F1 | 0.90 |
from transformers import pipeline
classifier = pipeline(
"text-classification",
model="Riddhi2952/financial-sentiment-distilbert"
)
result = classifier("$AAPL beats earnings estimates revenue up 12%")
print(result)
# [{'label': 'Bullish', 'score': 0.99}]