Text Classification
Transformers
Safetensors
PyTorch
English
distilbert
sentiment-analysis
ecommerce
text-embeddings-inference
Instructions to use EBSQ/amazon-sentiment-distilbert with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use EBSQ/amazon-sentiment-distilbert with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="EBSQ/amazon-sentiment-distilbert")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("EBSQ/amazon-sentiment-distilbert") model = AutoModelForSequenceClassification.from_pretrained("EBSQ/amazon-sentiment-distilbert", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 1,698 Bytes
5a75096 a9a1578 5a75096 a52dd9e 5a75096 a9a1578 a52dd9e a9a1578 a52dd9e 5a75096 a9a1578 a52dd9e 5a75096 a9a1578 a52dd9e 5a75096 a9a1578 5a75096 a9a1578 5a75096 a52dd9e | 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 | ---
library_name: transformers
license: apache-2.0
datasets:
- amazon-sales-dataset
language:
- en
metrics:
- accuracy
- f1
tags:
- text-classification
- sentiment-analysis
- ecommerce
- pytorch
- distilbert
---
# Model Card for Model ID
<!-- Provide a quick summary of what the model is/does. -->
## Model Details
### Model Description
This model is a fine-tuned version of distilbert-base-uncased on an Amazon product reviews dataset. It classifies customer reviews into two sentiment categories:
Negative (label 0): rating < 3.5
Positive (label 1): rating ≥ 3.5
The model is designed to support automated customer service systems by providing real-time sentiment analysis.
- **Developed by:** Estella
- **Model type:** Text Classification
- **Language(s) (NLP):** English
- **License:** apache-2.0
- **Number of Classes:** 2
- 0: Negative
- 1: Positive
## Intended Uses & Limitations
**Intended Use:**
- Sentiment analysis for e-commerce customer reviews
- Pre-processing step for automated reply generation or customer feedback dashboard
**Limitations:**
- The model was trained on product reviews from Amazon (electronics, cables, TVs, etc.). Performance on other domains (e.g., clothing, books) may vary.
- It does not detect neutral sentiment; reviews with rating 3.5 are considered positive by the chosen threshold.
## How to Use the Model
You can use this model directly with the Transformers pipeline for text classification.
```python
from transformers import pipeline
classifier = pipeline("text-classification", model="your_username/amazon-sentiment-distilbert")
result = classifier("This product is amazing!")
print(result) # [{'label': 'POSITIVE', 'score': 0.99}] |