How graytowne/caser_pytorch works
Caser-PyTorch is a sequential recommendation implementation: the command-line training workflow reads ordered user-item interactions, converts them into sequences and targets, trains a convolutional recommender with negative samples, and evaluates ranked recommendations. The graph keeps data preparation, model scoring, training, and ranking distinct, with shared utilities as an internal layer. The README documents the main training command and data format; some wiring is supported by the source index rather than a complete training excerpt.
Main entry points: train_caser.py Recommender trainer · interactions.py Interaction sequences · caser.py Caser model · evaluation.py Ranking metrics
Components 8
Interaction data
- Training interactions
datasets/ml1m/test/train.txt - Test interactions
datasets/ml1m/test/test.txt - Interaction sequences
interactions.py
Recommendation model
- Caser model
caser.py
Training workflow
- Recommender trainer
train_caser.py - Training utilities
utils.py
Ranking evaluation
- Ranking metrics
evaluation.py
Other components
- CLI user
Connections 11
- CLI user → Recommender trainer: runs
README.md - Recommender trainer → Training interactions: loads
- Recommender trainer → Test interactions: loads
- Interaction sequences → Training interactions: reads
interactions.py - Interaction sequences → Test interactions: reads
interactions.py - Recommender trainer → Interaction sequences: prepares sequences
train_caser.py - Recommender trainer → Caser model: trains and predicts
train_caser.py - Recommender trainer → Training utilities: uses helpers
train_caser.py - Caser model → Training utilities: gets activation
caser.py - Recommender trainer → Ranking metrics: evaluates
train_caser.py - Ranking metrics → Recommender trainer: requests predictions
evaluation.py