Giter Site home page Giter Site logo

prashant-smart / recommendation-system Goto Github PK

View Code? Open in Web Editor NEW
11.0 1.0 1.0 4.55 MB

Recommendation System Using three different approaches Simple Recommendation Using Content based( TF-IDF & Bag of words ), Using KNN and Collaborative Filtering (Item-Item). Explanation:https://www.youtube.com/watch?v=lapsqCrSwCo

Home Page: https://share.streamlit.io/prashant-smart/recommendation-system/main.py

CSS 5.88% Python 94.12%
collaborative-filtering content-filtering machine-learning-algorithms machine-learning-projects mahcine-learning python-project recommendation-engine recommendation-system streamlit-webapp

recommendation-system's Introduction

PMBD.COM

PMBD is the project based on Machine Learning in whcih i have devloped a web application to demonstrate how various Machine Learning algorithms use for recommendation

Website link: https://share.streamlit.io/prashant-smart/recommendation-system/main.py

Demonstrate the use of Recommendation System :

  1. Helps to Improve the on-site experience by creating dynamic recommendations for different kinds of audiences like Netflix does.
  2. Helps to categories the product based on their features. Eg: Material, Season, etc.
  • Acknowledgement points:-
    1. This Project is part of Microsoft Engage Program.
    2. The data fetched is 95% accurate and fetched from the pre available websites such as kaggle.com , movielens.org etc.
    3. There is no plagirism issue as per design and code, i am sole contributor

TECH STACK USED

  • Python
  • Streamlit

First of all you need to SIGN UP in the page using ( You can use any username and password for login ):-

Data Preprocessing Code : Data Preprocessing

Three Recommendation Type:

  • Section A: Movie based
  • Section B: Person based(cast Member)
  • Section C: genres based

Section A: Movie based

In this, a user can select the number of recommendations they want related to a specific movie selected by the movie name.

Result with poster

Result without poster

Four Algorithm Type:

  • Section A.1: Content Based (TF-IDF)
  • Section A.2: Content Based (Bag Of Words)
  • Section A.3: Item-Item Collaborative Based
  • Section A.4: K Nearest Neighbor (Item Based)

Section A.1: Content Based (TF-IDF)

This algorithm uses TfidfVectorizer for vector conversion and Cosine Similarity for calculating the angle between two vectors. On the basis of the movie name selected by the user, this algorithm retruns a list of movies sorted in descending order with respect to similarity, which is taken from the similarity matrix (which contains similarity score for each movie).

Code: Content Based Filtering.ipynb

Section A.2: Content Based (Bag Of Words)

Bag of Words uses the same technique as TF-IDF, but the score is calculated based on the frequency of the most repetitive words in the movie's content, and the similarity score is calculated in the same way as in TF-IDF.

Code: Content Based Filtering.ipynb

Section A.3: Item-Item Collaborative Based

In this algorithm, a user rating for a specific movie is calculated on the basis of how other user rate same movie, and by taking some real time rartings, we can show recommendations to users.

Code: Collaborative Item To Ttem Filtering.ipynb

Section A.4: K Nearest Neighbor (Item Based)

User ratings are predicted here same as in Item-Item Collaborative filtering, but for calculating distance it uses euclidean and manhattan distance between two vectors, and according to that, forms a similarity matrix, then shows recommendations to the user with respect to a specific movie which is selected by the user.

Code: Kth Nearest Neighbor.ipynb

Section B: Person based(cast Member)

Users can also get recommendations on the basis of a person who has appeared in movies as a lead actor or director.

First, all movies in which that person is cast as an actor or director are sorted in reverse order according to the average rating and if the number of recommendations is greater than that person's movies, then the user gets recommendation on the basis of the first movie which is going to be recommended first to the user.

Code: Cast Based Search.ipynb

Section C: genres based

This recommendation is based on those movies which have the same genres as selected by the user and then sorted in reverse order according to average ratings of each movie.

Code: Generes Based Search.ipynb

Installation

Make a folder in your system and clone the project using git bash then open the project in Visual Studio Code or any IDE you prefer.

Clone the project
git clone https://github.com/prashant-smart/Recommendation-system.git

after cloning the project get into main directory

cd .\Recommendation-system\

⚠️ Make sure pip is already installed otherwise check out https://pip.pypa.io/en/stable/installation/

⚠️ Python version sholud be 3.9.12 or higher ( if you want to download then check out https://www.python.org/downloads/ )

now install all library

pip install -r requirements.txt

Set Up

To open webapp on your local machine

streamlit run main.py


Hope You Like the Project ❤️❤️❤️

For better understanding the flow of the website please see Flowchart and Vedio demo.

Peace to everyone 🙏🏻

recommendation-system's People

Contributors

prashant-smart avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

lingangu

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.