Wanda  Huel

Wanda Huel


Content-based Movie Recommender System


Content-Based Movie Recommender System built using the cosine similarity scores

Table of Content

1. Executive Summary

2. Introduction

3. Algorithm

3.1. Content-Based filtering

3.2. Cosine Similarity

4. Objective

5. Methodology

5.1. Sample Database schema

5.2. Python-Oracle Database connection

5.3. Preparing the sample dataset

5.4. Identifying the highest rated movies and getting the best movie details

5.5. Merging key features and building a cosine similarity matrix

5.6. Generating Recommendations

5.7. Results

6. Conclusion

7. Project Repository

8. References

1. Executive Summary

Whenever we visit a digital platform, we no longer need to worry about what to watch next as we are served with a bunch of recommendations to choose from. But how exactly the platform decides what to recommend to a specific user, and if the user is going to like that.

In this project, we attempt to build a specific kind of recommendation system by extending the RELMDB oracle database. We attempt to build a recommender system that identifies the best movie, based on the number of IMDb votes and the average IMDb rating, and suggest movies with similar content to the user. We start by importing and munging data from the oracle database to create our base dataset. We, then, identify the best movie and use the cosine similarity algorithm to recommend the top 10 similar movies to the user.

#recommendation-system #machine-learning-python #data-science #python

What is GEEK

Buddha Community

Content-based Movie Recommender System
Justice  Reilly

Justice Reilly


Content-Based Recommendation System Implementation

A content-based recommendation system revolves around a user’s profiles. It is based on the user’s ratings including the number of times a…

#pandas #movie-recommendation #content-based-filtering #python #recommendation-system #programming

Create Your Own Movie Recommendation System Using Python

Do you wonder how Netflix suggests movies that align your interests so much? Or maybe you want to build a system that can make such suggestions to its users too?

If your answer was yes, then you’ve come to the right place as this article will teach you how to build a movie recommendation system by using Python.

However, before we start discussing the ‘How’ we must be familiar with the ‘What.’

Recommendation System: What is It?

Types of Recommendation Systems

Building a Basic Movie Recommendation System

**Learn More About a Movie Recommendation System **

Final Thoughts

#data science #movie recommendation system #movie recommendation system using python #python

Math Behind Content Based Recommendation System.

Concept Behind Content based Recommendation system:

Firstly I would like to give the intuition regarding the content based recommendation system, Like how it Works, in real practices and later We’ll jump into the mathematical part behind it!

Assuming, we have User 1, who had saw movie 1(Action) rated it 5/5, movie 2(Romance) rated it 4/5, and movie 3(Action) rated it 5/5 respectively.

Now, If User 2, watches the Movie 6 (Action) rates it 5/5, and Movie 7(Romance) rates it 5/5, So, the Content based recommendation system will most probably recommend the Action Movie 1 or Action Movie 3 for User 2, based on the ratings and the type of movie, with which both the Users are Related.

In-short, these algorithms try to recommend items that are similar to those that a user liked in the past, or is examining in the present.

Well, this is how Content Based Recommendation system works in a Nutshell, but It is also very important to understand the math behind every Algorithm, so lets Dive into the Math behind this algorithm.

Math behind the Algorithm:

So, lets start with a simple example, assuming the following data,

Image for post

So the question is, How can we Recommend the Unknown rating of the Users!?

Based the above data, we can see that. Movie 1, Movie 2 and Movie 3 tend to be more Action based Movies, while Movie 4 and Movie 5, tend to be Romantic ones, Also we can conclude that, User 1 and User 2 prefer Action movies over Romantic ones!, and Vice-Versa for the User 3, and User 4 respectively.


N(U)=No. of Users=4,

N(M)=No. of Movies=5, and

N(Features)=2 i.e.(Action and Romance)

So let’s Consider, Movie 1, Assuming the X-intercept value as X(0)=1,and Considering Feature Values, We can write, Feature Vector for Movie 1, as Vector of Matrix(3,1) as [1 0.9 0], Similarly we’ll have Feature Vectors for Movie 2,3,4 and 5.

Now, For Each user “j”, learns a parameter Theta(j)==Real Number^(3) i.e.(Feature(2)+1), So by using

(Theta^(j))^(T)*x^(i), we can find the Rating of Movie(i), using The Parameter Vector Theta(i) for each User, where (i), is no. of user.

#recommender-systems #data-science #math #recommendation-system #machine-learning #deep learning

How to Build A Flexible Movie Recommender Chatbot In Python

Follow our steps to discover what it takes to create a web-app that recommends movies based on open-ended user inputs!

Our working final product can be tested here.

Have you ever wondered what a chatbot is and how to build one?

In this three-part series, we will teach you everything you need to build and deploy your Chatbot. By “we” here, I mean my team members (Ahmed, Dennis, Pedro, and Steven), four data science students at the Minerva Schools at KGI. The series will cover the following topics:

We use a Jupyter Python 3 notebook as a collaborative coding environment for this project, and other bits of code for the web app development and deployment. All the code for this series is available in this GitHub repository.


Businesses integrate chatbots into many processes and applications. You might need to interact with one while buying an item from Sephora, booking a flight from British Airways, or even customizing your cup of coffee from Starbucks. Developers build chatbots to understand customers’ needs and assist them without needing human help, making chatbots very useful for many customer-facing businesses. So how does a chatbot work?

Generally, there are three types of chatbots:

  1. Rule-based Chatbots: these bots can answer customers’ requests based on pre-defined rules that we created. These bots are suitable to handle simple, repetitive, and predicted tasks but might fail to address complex ones.
  2. **Retrieval-based Chatbots: **these bots utilize advanced algorithms to select the most suitable response from a pool of diverse answers to accommodate customer’s needs. The retrieval approach is more intelligent than the rule-based fixed algorithm as it considers the message and the context of the conversation in answering customer’s requests.
  3. **Generative Chatbots: **these bots use Machine Learning algorithms to simulate how humans understand and respond to customers’ requests. Like humans, they can generate new and different responses based on the context and wording of customer’s questions. Although Generative bots are the most intelligent type of chatbots, it is challenging to build and train them.

The chatbot we settled on creating is retrieval-based. Our bot can take a diverse set of responses, which are only slightly structured and output tailored recommendations. We had two main challenges to making this work: first, to build a flexible recommendation system in Python capable of taking in written requests by users and outputting decent recommendations. Second, implementing that algorithm in a web-app that is user-friendly and easy to use.

#movie-recommendation #towards-data-science #recommendation-system #chatbots #how to build a flexible movie recommender chatbot in python #chatbot in python

Ruth  Nabimanya

Ruth Nabimanya


System Databases in SQL Server


In SSMS, we many of may noticed System Databases under the Database Folder. But how many of us knows its purpose?. In this article lets discuss about the System Databases in SQL Server.

System Database

Fig. 1 System Databases

There are five system databases, these databases are created while installing SQL Server.

  • Master
  • Model
  • MSDB
  • Tempdb
  • Resource
  • This database contains all the System level Information in SQL Server. The Information in form of Meta data.
  • Because of this master database, we are able to access the SQL Server (On premise SQL Server)
  • This database is used as a template for new databases.
  • Whenever a new database is created, initially a copy of model database is what created as new database.
  • This database is where a service called SQL Server Agent stores its data.
  • SQL server Agent is in charge of automation, which includes entities such as jobs, schedules, and alerts.
  • The Tempdb is where SQL Server stores temporary data such as work tables, sort space, row versioning information and etc.
  • User can create their own version of temporary tables and those are stored in Tempdb.
  • But this database is destroyed and recreated every time when we restart the instance of SQL Server.
  • The resource database is a hidden, read only database that holds the definitions of all system objects.
  • When we query system object in a database, they appear to reside in the sys schema of the local database, but in actually their definitions reside in the resource db.

#sql server #master system database #model system database #msdb system database #sql server system databases #ssms #system database #system databases in sql server #tempdb system database