Downloads · 30 days
17
25% of all-time downloads
krishnamishra8848/movie_sentiment_analysis
movie_sentiment_analysis is a text classification model from krishnamishra8848. Use it when you need a label for a piece of text. The card lists the license as apache-2.0.
Downloads · 30 days
17
25% of all-time downloads
All-time downloads
68
Public
Parameters
67M
515 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors268 MB · 100%
From the Hugging Face model README
Movie Sentiment Analysis Model
Want to try out the model? Click here!
<span style="color:red">This model can detect movie sentiment analysis from all languages. However, since it uses RapidAPI for language detection and translation, the free tier only allows 500 requests per month. If the model is not making predictions, it means the monthly limit of 500 requests has been reached. Please try again later. You can also download our model and run it on your local system for unlimited use free of cost, or fine-tune it as needed—no problem!</span>
Overview
This model is a fine-tuned version of distilbert-base-uncased for sentiment analysis on IMDB movie reviews. It has been trained on 20,000 labeled reviews, with an equal distribution of positive (10,000) and negative (10,000) examples. The model achieves 93% F1 score, precision, and recall, making it a state-of-the-art solution for movie sentiment analysis.
Model Details
Base Model: DistilBERT (distilbert-base-uncased)
Dataset: IMDB Movie Reviews (20,000 samples: 10k positive, 10k negative)
Performance:
F1 Score: 93%
Precision: 93%
Recall: 93%
Use Case: Analyze the sentiment of movie reviews as either positive or negative.
How to Use
# How To use model
from transformers import pipeline
# Load the pipeline
classifier = pipeline('sentiment-analysis', model='krishnamishra8848/movie_sentiment_analysis')
# Analyze sentiment
review = "I really enjoyed this movie from start to finish!"
result = classifier(review)
# Human-readable output
label_mapping = {"LABEL_0": "negative", "LABEL_1": "positive"}
human_readable_result = {
"sentiment": label_mapping[result[0]['label']],
"confidence": result[0]['score']
}
print(human_readable_result)