File size: 1,969 Bytes
ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 ca1254d 1467aa6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | ---
language: en
license: apache-2.0
tags:
- text-classification
- financial-nlp
- sentiment-analysis
- distilroberta
- finstream
datasets:
- financial_phrasebank
metrics:
- accuracy
- f1
---
# hitenvk22/finstream-sentiment
**FinStream** financial sentiment classifier fine-tuned on Financial PhraseBank.
Part of the [FinStream Active Learning Pipeline](https://github.com/hitenvk22/finstream).
## Model Description
| Property | Value |
|---|---|
| Base model | `distilroberta-base` |
| Task | 3-class financial sentiment classification |
| Dataset | Financial PhraseBank (~4,845 sentences) |
| Labels | `negative` (Bearish) · `neutral` · `positive` (Bullish) |
| Accuracy | 0.8443298969072165 |
| F1 macro | 0.8457725376192002 |
| Precision | 0.8510783764659424 |
| Recall | 0.8443298969072165 |
| Training hardware | Kaggle T4 GPU · FP16 · 5 epochs |
## Quick Start
```python
from transformers import pipeline
classifier = pipeline(
"text-classification",
model="hitenvk22/finstream-sentiment",
tokenizer="hitenvk22/finstream-sentiment",
)
result = classifier("The company reported record earnings, beating all analyst estimates.")
print(result)
# [{'label': 'positive', 'score': 0.96}]
```
## Label Mapping
| Integer | Label | Financial meaning |
|---|---|---|
| 0 | negative | Bearish — price likely to fall |
| 1 | neutral | No directional signal |
| 2 | positive | Bullish — price likely to rise |
## Intended Use
- Real-time financial news sentiment scoring
- Portfolio risk alerts
- Market signal generation
- Active learning pipeline retraining target
## Limitations
- Trained on English-only text
- Short sentences (< 128 tokens); may underperform on long documents
- Not fine-tuned on post-2020 financial language
## Training Details
- Optimiser: AdamW · LR 2e-5 · warmup 10 % · weight decay 0.01
- Early stopping patience: 2 epochs
- Dynamic padding via `DataCollatorWithPadding`
|