Skip to content

About

πŸ“š A Book Recommendation System built with Python, Flask, and machine learning. It suggests books based on user preferences using collaborative filtering and popularity-based models.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

πŸ“š Book Recommendation System

Book Recommendation System is a machine learning project that suggests books to users based on Popularity-Based Filtering and Content-Based Filtering.
It allows users to discover trending books and also find books similar to the ones they love β€” making reading choices smarter and more personalized.

πŸ“Š Dataset

This project uses the Books Dataset from Kaggle:
πŸ“Œ Kaggle Dataset - Book Recommendation Dataset

It includes:

  • Users (user IDs, demographics)
  • Books (title, author, publisher, etc.)
  • Ratings (explicit/implicit feedback)

πŸ“½οΈ Demo Video

Watch the demo of Book Recommendation System in action:

Book.Recommendation.System.mp4

πŸš€ Features

  • ⭐ Popularity-Based Recommendations
    β†’ Suggests top-rated and trending books based on user ratings.

  • πŸ“– Content-Based Recommendations
    β†’ Recommends books similar to a chosen one using author, genre, and metadata.

  • 🧠 Hybrid Approach
    β†’ Combines popularity and content similarity for better results.

  • 🌐 Interactive Web App
    β†’ Simple and user-friendly interface built with Flask.

🧠 How It Works

  1. Popularity-Based Filtering:

    • Aggregates ratings and calculates weighted score.
    • Displays the most popular books across the dataset.
  2. Content-Based Filtering:

    • Computes cosine similarity between book descriptions.
    • Finds books with high similarity scores to the input.
  3. Pre-processed Data:

    • Uses .pkl files (saved models) for faster predictions.

πŸ”§ Installation

1. Clone the Repository

git clone https://github.com/Arpit-Padmani/Book-Recommadation-System.git
cd book-recommendation-system

πŸ“ Required Files and Folders

  • Books.csv β†’ Contains book details.

  • Ratings.csv β†’ Contains user ratings.

  • Users.csv β†’ User details (for dataset reference).

  • app.py β†’ Flask application entry point.

  • books-recommandation-system.ipynb / news.ipynb β†’ Jupyter notebooks for model building & experimentation.

  • .pkl files β†’ Precomputed models and data:

    • books.pkl β†’ Processed books data
    • popular.pkl β†’ Popularity-based recommendations
    • pt.pkl β†’ Pivot table matrix
    • similarity_scores.pkl β†’ Precomputed similarity scores
  • templates/ (HTML templates for Flask UI):

    • index.html β†’ Home page (search or landing page)
    • recommend.html β†’ Displays recommended books

▢️ Usage

Run the Flask app:

python app.py

Then open your browser at:

http://127.0.0.1:5000/

πŸ› οΈ Technologies Used

  • Programming Language: Python
  • Data Handling: Pandas, NumPy
  • Machine Learning: Scikit-Learn, Cosine Similarity
  • Web Framework: Flask
  • Visualization: Matplotlib, Seaborn
  • Notebook Experiments: Jupyter

πŸ“Š Example Recommendations

  • If you like Harry Potter and the Sorcerer’s Stone β†’ Get recommendations like Percy Jackson or The Hobbit.
  • If you browse trending β†’ See books like The Da Vinci Code or The Alchemist.

πŸ“¦ Requirements

Dependencies are listed in requirements.txt:

Flask==2.3.2
pandas==2.0.3
numpy==1.24.3
scikit-learn==1.3.0
scipy==1.11.1
matplotlib==3.7.2
seaborn==0.12.2
joblib==1.3.1
notebook==7.0.2

Install them with:

pip install -r requirements.txt

πŸ“« Contact

Developed by Arpit Padmani πŸ’Ό LinkedIn

⭐ Star this repo if you found it useful!

About

πŸ“š A Book Recommendation System built with Python, Flask, and machine learning. It suggests books based on user preferences using collaborative filtering and popularity-based models.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages