Model Card for Model ID

Model Details

Model Description

This model fine-tunes vinai/bertweet-base for binary sentiment classification on cryptocurrency-related tweets, focusing on Bitcoin-specific discourse. It uses the BERTweet tokenizer with normalization enabled and standard Transformer fine-tuning hyperparameters, producing logits over two labels: 0 (Negative), 1 (Positive).

  • Model type: Transformer encoder (BERTweet) for sequence classification
  • Language(s) (NLP): English social media text
  • Finetuned from model : vinai/bertweet-base

Model Sources

Uses

Direct Use

Binary sentiment classification of Bitcoin/crypto tweets or short-form social text.

Exploratory analysis, dashboards, alerting on sentiment shifts.

Downstream Use

Pipeline component in trading sentiment systems, research on crypto discourse, market microstructure studies, and social analytics.

Further fine-tuning on domain-specific labeled tweets (e.g., exchange-specific, regulation-related).

How to Get Started with the Model

Use the code below to get started with the model.

from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
import torch.nn.functional as F

repo_id = "rohan10juli/bertweet-finetuned-bitcoin"

tokenizer = AutoTokenizer.from_pretrained(repo_id)
model = AutoModelForSequenceClassification.from_pretrained(repo_id)
model.eval()

texts = [
    "Terrible day for Bitcoin investors πŸ˜“πŸ”₯",
    "Just bought my first sats today! πŸ₯³ Excited to be part of the Bitcoin revolution! πŸ”₯",
    "Bitcoin prices are crashing hard! πŸ˜žπŸ“‰ #BTC",
]

inputs = tokenizer(texts, padding=True, truncation=True, max_length=64, return_tensors="pt")

with torch.no_grad():
    outputs = model(**inputs)
    logits = outputs.logits

probs = torch.nn.functional.softmax(logits, dim=1)
confidences, predicted_classes = torch.max(probs, dim=1)

for i, text in enumerate(texts):
    print(f"Input Text: {text}")
    print(f"Predicted Class: {predicted_classes[i].item()}")

Training Hyperparameters

  • Training regime:

Optimizer: AdamW (Transformers default)

Learning rate: 2e-5

Weight decay: 0.01

Batch size: per_device_train_batch_size=32, per_device_eval_batch_size=64

Epochs: 3

Evaluation/Checkpointing: epoch-based

Evaluation

Metrics

Accuracy, F1 (macro), Precision/Recall by class; consider AUROC/PR for threshold tuning.

Results

Accuracy: 0.9947

F1 (macro): 0.9944

Precision/Recall (Positive): 0.995 / 0.994

Precision/Recall (Negative): 0.994 / 0.995

Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for rohan10juli/bertweet-finetuned-bitcoin

Finetuned
(252)
this model