AI Models

IMDB Movie Reviews Sentiment Analysis

🔬 Research Focus:

Leveraging GPT-2 transformer architecture for sentiment classification on the IMDB movie review dataset. This model brings the power of Large Language Models to binary sentiment analysis tasks.

📊 Performance Metrics:

Dataset: 50,000 movie reviews from IMDB.

Model: GPT-2 based classification head.

Accuracy: High accuracy sentiment classification.

Input Size: Tokenized text with max length 512.

Optimization: Cross-entropy loss with Adam optimizer.

🧠 Technical Advantages:

Transformer Architecture: Self-attention mechanism for understanding contextual relationships in text.

Pre-trained Weights: GPT-2 base model fine-tuned on movie domain.

Bidirectional Context: Understanding review context from both directions.

Transfer Learning: Leveraging pre-trained language model representations.

📁 Model Files:

Notebook: `01-imdb-movie-reviews-sentiment.ipynb`

Dataset: Kaggle IMDB Dataset of 50k Movie Reviews

Framework: PyTorch, Transformers

Technical Stack

PythonPyTorchGPT-2TransformersNLPDeep Learning

Sample Reviews & Predictions

IMDB Movie Reviews Sentiment Analysis — Sample Reviews & Predictions

Example predictions from the model on test reviews. The model correctly identifies sentiment in reviews with varying complexity, from simple positive/negative statements to nuanced opinions requiring contextual understanding.

Training & Validation Curves

IMDB Movie Reviews Sentiment Analysis — Training & Validation Curves

The training curves show the model's learning progression over epochs. The loss decreases steadily while accuracy increases, reaching stable convergence. The validation metrics track closely with training, indicating good generalization without overfitting.

Classification Performance Matrix

IMDB Movie Reviews Sentiment Analysis — Classification Performance Matrix

The confusion matrix demonstrates the model's effectiveness in sentiment classification. It correctly identifies positive and negative reviews with high precision, making it reliable for real-world sentiment analysis applications. The model achieves balanced performance across both classes.