Driisa/finbert-finetuned-github
FinBERT Fine-Tuned on Financial Sentiment (Financial PhraseBank + GitHub Dataset)
๐ Model Description
This model is a fine-tuned version of FinBERT (ProsusAI/finbert) trained for financial sentiment classification. It can classify financial text into three categories:
- Negative (0)
- Neutral (1)
- Positive (2)
๐ Dataset Used
This model was trained on: โ Financial PhraseBank - A widely used financial sentiment dataset. โ GitHub Generated Sentiment Dataset - An additional dataset to test the model.
โ๏ธ Training Parameters
๐ Model Performance
๐ Intended Use
This model is designed for: โ Financial Analysts & Investors to assess sentiment of financial sentences in ex. reports, news, and stock discussions. โ Financial Institutions for NLP-based sentiment analysis in automated trading. โ AI Researchers exploring financial NLP models.
โ ๏ธ Limitations
โ ๏ธ May not generalize well to datasets with very different financial language. โ ๏ธ Might require fine-tuning for specific financial domains (crypto, banking, startups).
๐ฅ Usage Example
You can use the model via Hugging Face Transformers:
from transformers import AutoModelForSequenceClassification, AutoTokenizer
model_name = "Driisa/finbert-finetuned-github"
# Load model and tokenizer
model = AutoModelForSequenceClassification.from_pretrained(model_name)
tokenizer = AutoTokenizer.from_pretrained(model_name)
# Example input
text = "The company's stock has seen significant growth this quarter."
# Tokenize and predict
inputs = tokenizer(text, return_tensors="pt", padding=True, truncation=True, max_length=128)
outputs = model(**inputs)
# Get predicted class
predicted_class = outputs.logits.argmax().item()
print(f"Predicted Sentiment: {['Negative', 'Neutral', 'Positive'][predicted_class]}")
