Views
No views yet
| Metric | Score |
|---|---|
| Accuracy | 0.8266 |
| F1-Score | 0.7587 |
| Precision | 0.7560 |
| Recall | 0.7617 |
1{
2 "embed_dim": 128,
3 "hidden_dim": 128,
4 "learning_rate": 0.0005,
5 "batch_size": 64,
6 "epochs": 20,
7 "max_len": 200,
8 "vocab_size": 73738,
9 "dropout_rate": 0.5,
10 "fc_sizes": [
11 64,
12 64,
13 16
14 ],
15 "subset": 1.0
16}1from pathlib import Path
2import pickle
3
4# Load the model components
5model_dir = Path("path/to/model")
6
7with open(model_dir / 'vectorizer.pkl', 'rb') as f:
8 vectorizer = pickle.load(f)
9
10with open(model_dir / 'classifier.pkl', 'rb') as f:
11 classifier = pickle.load(f)
12
13with open(model_dir / 'label_encoder.pkl', 'rb') as f:
14 label_encoder = pickle.load(f)1# Example reviews
2reviews = [
3 "This game is absolutely amazing! Best game I've played this year.",
4 "It's okay, nothing special but not terrible either.",
5 "Terrible game, waste of money and time."
6]
7
8# Transform and predict
9X = vectorizer.transform(reviews)
10predictions_encoded = classifier.predict(X)
11predictions = label_encoder.inverse_transform(predictions_encoded)
12
13print(predictions)
14# Output: ['positive', 'mixed', 'negative']
15
16# Get probabilities
17probabilities = classifier.predict_proba(X)
18print(probabilities)| Class | Precision | Recall | F1-Score | Support |
|---|---|---|---|---|
| Positive | 0.9148 | 0.8990 | 0.9068 | 45859 |
| Mixed | 0.5301 | 0.5493 | 0.5395 | 12697 |
| Negative | 0.8232 | 0.8366 | 0.8298 | 20181 |
results.json for the complete feature importance analysis.vectorizer.pkl: TF-IDF vectorizerclassifier.pkl: Trained classifierlabel_encoder.pkl: Label encoder for sentiment classesconfig.json: Model configurationresults.json: Complete training results and metrics@misc{game_review_sentiment,
author = {Game Review Sentiment Analysis Project},
title = {Sentiment Analysis Model for Game Reviews},
year = {2025},
url = {https://huggingface.co/wm-grsa-lstm-baseline}
}