Text Classification
Transformers
Safetensors
English
modernbert
financial-sentiment-analysis
sentiment-analysis
financial-news
finance
stocks
trading
finbert-alternative
sentiment
fintech
news
text-embeddings-inference
Instructions to use AnkitAI/FinSense-ModernBERT-Financial-News-Sentiment-Analysis with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use AnkitAI/FinSense-ModernBERT-Financial-News-Sentiment-Analysis with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="AnkitAI/FinSense-ModernBERT-Financial-News-Sentiment-Analysis")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("AnkitAI/FinSense-ModernBERT-Financial-News-Sentiment-Analysis") model = AutoModelForSequenceClassification.from_pretrained("AnkitAI/FinSense-ModernBERT-Financial-News-Sentiment-Analysis", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| { | |
| "base": "answerdotai/ModernBERT-base", | |
| "seed": 42, | |
| "smoke": false, | |
| "test_accuracy": 0.8674948240165632, | |
| "test_macro_f1": 0.8589082381215416, | |
| "confusion_matrix": [ | |
| [ | |
| 52, | |
| 5, | |
| 3 | |
| ], | |
| [ | |
| 6, | |
| 261, | |
| 20 | |
| ], | |
| [ | |
| 0, | |
| 30, | |
| 106 | |
| ] | |
| ], | |
| "labels": [ | |
| "negative", | |
| "neutral", | |
| "positive" | |
| ], | |
| "split": "stratified 80/10/10, split-seed 42", | |
| "corpus": "fpb-train", | |
| "dataset": "financial_phrasebank sentences_50agree" | |
| } |