Lab build

Hybrid anime recommender

Blends collaborative and content-based anime recommendations from trained embeddings, deployed to GKE via Jenkins.

Role
Builder, end to end
Group
MLOps
Services
AI & LLM systems · MLOps & cloud

What it does

Anime, synopsis and rating files are pulled from a GCS bucket, users with fewer than 400 ratings are dropped, ratings are min-max scaled and IDs are encoded. A Keras RecommenderNet trains 128-dimensional user and anime embeddings, with a learning-rate schedule, checkpointing, early stopping and Comet ML tracking. Recommendations blend similar-user picks with similar-anime picks by weighted score, and Jenkins pulls DVC-tracked data, builds the image, pushes it to GCR and deploys it to GKE.

What was built

  1. 01

    Ingestion downloads anime.csv, anime_with_synopsis.csv and animelist.csv from GCS; DVC versions data and artifacts.

  2. 02

    Processing keeps users with at least 400 ratings, min-max scales ratings and encodes user and anime IDs.

  3. 03

    RecommenderNet uses 128-dim embeddings, a normalised dot product and sigmoid output trained with binary cross-entropy.

  4. 04

    Training applies a ramp-up and decay learning-rate schedule, best-weight checkpoints and early stopping, logged to Comet ML.

  5. 05

    Jenkins runs dvc pull, builds and pushes the image to GCR, then applies a two-replica LoadBalancer deployment on GKE.

The pipeline, layer by layer

Five layers, one pipeline.

  1. L1Data

    • GCS rating files
    • DVC versioning
  2. L2Processing

    • User filtering and scaling
    • ID encoding
  3. L3Training

    • Keras embedding model
    • Comet ML tracking
  4. L4Inference

    • Hybrid weighted ranking
    • Flask app
  5. L5Delivery

    • Jenkins pipeline
    • GCR to GKE

Stack

  • TensorFlow
  • Keras
  • pandas
  • Comet ML
  • DVC
  • Google Cloud Storage
  • Flask
  • Docker
  • Jenkins
  • Google Container Registry
  • GKE

Next lab build · 15 / 46

Network security phishing classifier

Classifies phishing websites from URL features with MongoDB ETL, drift checks, MLflow tracking and AWS deployment.

Previous: Hotel reservation cancellation prediction

Need a system like this in production? Tell us about it.