Downloads · 30 days
2
11% of all-time downloads
goatley/sentiment-final-model
sentiment-final-model is a text classification model from goatley. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as mit.
This model is a fine-tuned DistilBERT model for binary sentiment classification (positive/negative) of English text reviews. It was developed as part of an advanced NLP dashboard project demonstrating applied skills i…
Downloads · 30 days
2
11% of all-time downloads
All-time downloads
19
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
goatley/sentiment-final-modelThis model is a fine-tuned DistilBERT model for binary sentiment classification (positive/negative) of English text reviews.
It was developed as part of an advanced NLP dashboard project demonstrating applied skills in deep learning, NLP engineering, and full-stack app deployment.
distilbert-base-uncasedThis model was fine-tuned on Amazon reviews, which may carry biases toward product-related expressions and cultural language patterns.
Users should be cautious when applying the model outside typical e-commerce datasets.
For more robust domain generalization:
from transformers import pipeline
classifier = pipeline(
"sentiment-analysis",
model="goatley/sentiment-final-model",
tokenizer="goatley/sentiment-final-model"
)
classifier(["I love this!", "This was awful."])
Training Details
Training Data
Subset of Amazon Reviews Dataset
Balanced 50/50 split of positive and negative reviews
Approximately 5,000 examples used for fine-tuning
Training Procedure
Fine-tuned for 3 epochs
Learning rate scheduling with warmup
Optimizer: AdamW
Batch size: 16
Device: CPU-based training (GitHub Codespaces)
Training Hyperparameters
Learning Rate: 5e-5
Optimizer: AdamW
Max Sequence Length: 512
Epochs: 3
Evaluation
Testing Data
Held-out test split from the Amazon Reviews dataset
Metrics
Metric Score
Test Accuracy 85%
Evaluation was performed using basic classification metrics (accuracy, precision, recall, F1-score).
Environmental Impact
Hardware Type: CPU (GitHub Codespaces)
Hours Used: ~2 hours
Cloud Provider: GitHub (Microsoft Azure backend)
Compute Region: North America
Carbon Emitted: Negligible (very small dataset + CPU-only fine-tuning)
Technical Specifications
Model Architecture and Objective
Architecture: DistilBERT Transformer Encoder
Task Objective: Sequence classification with 2 labels (positive, negative)
Compute Infrastructure
Training performed on GitHub Codespaces virtual machines.
No GPUs were used.
Software Environment
Hugging Face transformers==4.51.3
Datasets datasets==3.5.0
PyTorch torch==2.6.0
Citation
If you use this model or find it helpful, please cite:
APA:
Goatley, K. (2025). Sentiment Analysis Fine-Tuned DistilBERT Model [Model]. Hugging Face. https://huggingface.co/goatley/sentiment-final-model
BibTeX:
@misc{goatley2025sentiment,
author = {Keith Goatley},
title = {Sentiment
Analysis Fine-Tuned DistilBERT Model},
year = {2025},
publisher = {Hugging Face},
howpublished = {\url{https://huggingface.co/goatley/sentiment-final-model}}
}
Model Card Authors
Keith Goatley
Contact
For questions or inquiries, please contact via:
GitHub: https://github.com/Keithgoatley
Hugging Face: https://huggingface.co/goatley