Name: Towards AI Legal Name: Towards AI, Inc. Description: Towards AI is the world's leading artificial intelligence (AI) and technology publication. Read by thought-leaders and decision-makers around the world. Phone Number: +1-650-246-9381 Email: [email protected]
228 Park Avenue South New York, NY 10003 United States
Website: Publisher: https://towardsai.net/#publisher Diversity Policy: https://towardsai.net/about Ethics Policy: https://towardsai.net/about Masthead: https://towardsai.net/about
Name: Towards AI Legal Name: Towards AI, Inc. Description: Towards AI is the world's leading artificial intelligence (AI) and technology publication. Founders: Roberto Iriondo, , Job Title: Co-founder and Advisor Works for: Towards AI, Inc. Follow Roberto: X, LinkedIn, GitHub, Google Scholar, Towards AI Profile, Medium, ML@CMU, FreeCodeCamp, Crunchbase, Bloomberg, Roberto Iriondo, Generative AI Lab, Generative AI Lab Denis Piffaretti, Job Title: Co-founder Works for: Towards AI, Inc. Louie Peters, Job Title: Co-founder Works for: Towards AI, Inc. Louis-François Bouchard, Job Title: Co-founder Works for: Towards AI, Inc. Cover:
Towards AI Cover
Logo:
Towards AI Logo
Areas Served: Worldwide Alternate Name: Towards AI, Inc. Alternate Name: Towards AI Co. Alternate Name: towards ai Alternate Name: towardsai Alternate Name: towards.ai Alternate Name: tai Alternate Name: toward ai Alternate Name: toward.ai Alternate Name: Towards AI, Inc. Alternate Name: towardsai.net Alternate Name: pub.towardsai.net
5 stars – based on 497 reviews

Frequently Used, Contextual References

TODO: Remember to copy unique IDs whenever it needs used. i.e., URL: 304b2e42315e

Resources

Take our 85+ lesson From Beginner to Advanced LLM Developer Certification: From choosing a project to deploying a working product this is the most comprehensive and practical LLM course out there!

Publication

How is YouTube using AI to recommend videos?
Latest

How is YouTube using AI to recommend videos?

Last Updated on May 28, 2021 by Editorial Team

Author(s): Daksh Trehan

Machine Learning

Who’s the boss? The algorithm orΒ users?

From nerdschalk via Pinterest

With a high user base comes a mighty recommendation system.

You know me guys, I love to decode interesting algorithms. You can check out my articles on TikTok, Tinder, GPT-3, GoogleΒ Hum!

Table ofΒ Content:

  • What is YouTube? How popular isΒ it?
  • Decoding elements ofΒ YouTube

β–Ή Homepageβ€Šβ€”β€ŠGive suggestions without any query/navigation.

β–Ή Watch Nextβ€Šβ€”β€ŠDrive higher engagement to similarΒ content.

β–Ή Search Tabβ€Šβ€”β€ŠShow content matching theΒ query

β–Ή Trendingβ€Šβ€”β€ŠThe most controversial section ofΒ YouTube

β–Ή A Creator’s way toΒ Success!

β–Ή Collaborative Filtering

β–Ή Matrix Factorization

β–Ή Deep NeuralΒ Networks

β–Ή Work Flow in theΒ nutshell

What is YouTube? How popular isΒ it?

YouTube is a video-sharing website launched back in 2007 by three PayPal employees: Chad Hurley, Steve Chen, and JawedΒ Karim.

Once started above the small restaurant at California City, YouTube has detonated the market with its simplicity and a wide range of audiences. YouTube has something for everyone. Be it gaming channels, beauty tutorials, life hacks, product reviews, or hours of Live Newsβ€Šβ€”β€ŠYouTube got it all. Creators upload 500 hours of content every minute, and with this sort of high content-to-user ratio, I am pretty sure, something would be there to strike your choice everyΒ minute.

YouTube is now the world’s second-largest search engine and second most visited website after Google with a daily watch time of 1 Billion hours, which is greater than Netflix and Facebook combined. Once logged in, it can hook the user for 40 freakingΒ minutes.

I bet we all have been at this place, where we enter the YouTube world to gain some knowledge or insights and end up watching music videos for hours. This is the magic of the YouTube recommender system.

The YouTube algorithm is an integral part of its success, it decides 70% of the time what users have to watch, and about 80% of people in the USA follow the suggestion.

Decoding elements ofΒ YouTube

The ultimate goal of YouTube’s recommendation systemΒ are:

  1. Help viewers find the videos they’re interested in.
  2. Hook users to keep watching the videos thus increasing the popularity of the app and attract more creators.

The recommendation system in YouTube takes various things into account. It analyzes user’s history, their activities, geographical attributes, for videos, they analyze its genre, thumbnails, content, description, aiming audience, subscribers, satisfaction count(likes, comments, shares), user surveys,Β etc.

There are several different recommendation systems on YouTube that are employed in segregated sections.

Homepageβ€Šβ€”β€ŠGive suggestions without any query/navigation.

YouTube Homepage

It acts as a one-stop destination for the users, no queries searched, not peeking into other tabs like subscriptions/explore and you got your match right after opening the app. This helps to hook the user withΒ ease.

Which videos are shown on your homepage?

  • Recent videos from your subscribed channels.
  • Videos that have been watched by users matching yourΒ taste.
  • Few videos from channels that you’ve never watched enabling your discovery of new content and channelΒ growth.
  • Content from an unsubscribed channel that is familiar to the content youΒ watch.

Watch Next(Suggested Videos)β€Šβ€”β€ŠDrive higher engagement to similarΒ content.

Suggested VideosΒ section

It tries to show content similar to the video you’re watching. It can be from the same creator or a different one but having the same genre/matching context.

In the visual above, I am watching β€œChoker” by Twenty One Pilots that are from their latest album which is scheduled to release on 21st May. The recommendation system is asking me to watch another song β€œShy Away” from the same album, a video explaining β€œChokers”(Twenty One Pilot songs are hard to decode), and a song named β€œSave your Tears” which share the same genre as β€œChoker”.

Unlike at homepage, where videos suggested are personalized and content revolves around your taste, the videos suggested here are to increase your engagement on the platform and get familiar with the content of the same creator or relatedΒ content.

In easy words, the content shown hereΒ is:

related stuff to viewing videos + relevant videos forΒ you

Search Tabβ€Šβ€”β€ŠShow content matching theΒ query

Search Tab

The recommendation system employed here serves the purpose of providing relevant stuff. YouTube has a lot of greater advantage here because you’re providing some raw input in form ofΒ queries.

The search recommendation system tries to find a video with the same query as mentioned in the search box. It checks for the title of the video, tags in it, description of videos. That doesn’t necessarily mean that if I search for β€œData Science” it will show me a video titled β€œData Science” with tags and descriptions as β€œData Science” but no relevantΒ content.

YouTube also looks for the β€œFeedback Loop” i.e. it doesn’t only look for the metadata but rather also looks at the performance of the video, how much satisfaction rate(Views, Likes, Comments, Shares) it have, what people searching the same query tend to watch, the taste of audience of the contentΒ creator.

The output generated here is dependent on:

Relevance + FeedbackΒ Loop

Trendingβ€Šβ€”β€ŠThe most controversial section ofΒ YouTube

β€œTrending” Section

This is the most controversial and confusing section of YouTube, often the least expected creator and content are here with not so manyΒ views.

As mentioned by Tom[2], β€œTrending is like watercooler of YouTube.”

It is the section that takes into account most of the factors, the goal is to promote videos that are widely appreciated by the audience of various tastes. It tends to feature broadly appealing videos and the videos people are conversing about even out of YouTube. They check the velocity and increase in views and the appeal of the video. All it focuses upon is the Ranking and geography of users. Different regions have different trending videos based on the taste of people residingΒ there.

In addition, there is a β€œCreator on the rise” option that features various rising channels and promotes them free of cost. This is done by YouTube to promote small creators and provide them with free publicity to grow based on the performance of their videos and the content they areΒ making.

A Creator’s way toΒ Success!

Photo by Jungwoo Hong onΒ Unsplash

To grow as a creator, some points are needed to be taken careΒ of.

YouTube is a creator-friendly platform, but if you create sensible content and are loyal toΒ YouTube.

Creating a video on β€œHow to tie laces?” won’t work as YouTube already has 1000s of such videos. Try to create a video that is relevant and sensible that can help someone. I’m 21 years old and have been tying lace similarly as I did when I was 10 years old, so that technique doesn’tΒ change.

Try to stand out in the competition and once you’ve achieved popularity you can use the same concept to expand and boost yourΒ channel.

Always remember: if it works, don’t touchΒ it!

Make sure to try something new, but don’t go out of the league by trying new concepts and loosing the audience.

YouTube also looks at your channel’s performance. It analyzes how much time you took to hit 100k subscribers and 100k hours of watch time. So, try to accelerate your statistics as early as possible, make correct use of your popularity at rightΒ time.

Some statistics measure forΒ success:

  • 50% of Watch Time[4]: at least 50% of your viewers watch your content with high watchΒ time.
  • 5% of click rate[4]: at least 5% of viewers click and watch your video when suggested.
  • Check stats for your video at least for the first 24 hours as it is the time when your content can get maximum attention.
  • Check the geography of your users and create content accordingly.

Deep Learning Architecture for YouTube’s Recommender System

The recommender system is one of the most powerful use cases of ML that is encountered by every one of us many times aΒ day.

There are multiple ways to build a recommendation system:

Collaborative Filtering: This is a type where we tend to build collaborations between various users and items(videos).

  • User-User Collaborative Filteringβ€Šβ€”β€ŠHere, we try to match the taste of different users. It tends to check if β€œparticular user will like the particular video?”

e.g. Let’s take a recommendation system with just 10 users and 10 videos, we try to match the interests of different users and try to create a correlation betweenΒ them.

But this technique doesn’t scale well and can’t be used for such a large corpus ofΒ data.

  • Item-Item Collaborative Filteringβ€Šβ€”β€ŠThe technique is the same as above but we try to correlate different items i.e. videos. It tends to suggest β€œsimilar videos based on the videos users liked”. This performs better as we can segregate videos better as compared to segregating humans on their interests because they can have multiple interests. This way is computationally expensive and thus not employed.

Matrix Factorization: It tries to dissolve both user and item vectors together thus decomposing them and providing us with better comparison metrics. Unlike Item-Item collaborative filtering it isn’t computationally expensive but it lacks interpretability, it lacks the answer to β€œwhy we are recommending this video?” thus leading to low accuracies.

Deep Learning Architecture: In 2016, Google publicized Deep Learning architecture for YouTube recommendation and became one of the first companies to deploy production-level deep neural networks for recommender systems.

According to the paper, there are two stages to get personalized yet relevantΒ output:

Architecture for YouTube recommendation system,Β Source
  • Candidate Generation: It takes every information it could, the information is fed in form of embeddings and the output expected is the probability of any particular user watching aΒ video.
Architecture for Candidate Generation phase,Β Source

Pondering over YouTube statistics, the traditional architecture could provide us the probability for at least 1–2 billion videos every instant and that’s not what we expect. To ease the computation, we sample around 100–200 videos that are relevant to theΒ user.

  • Ranking: This serves the purpose of ranking videos based on the user’s relevance. A higher relevance score denotes video is broadly appealing and hence more push to the video. The relevance score changes very frequently and closely depend on the user’s activity.
Ranking phase architecture, Source

The relevance scores are closely equivalent to the expected watch time for videos. Videos of higher duration will have higher watch time and that’s why they are often able to fool algorithm and get high ranking/relevance score.

Feature denoting User’s context and Content attributes are merged and inputted to Logistic Weighted Regression where it spits out the relevance score for eachΒ video.

Recommendation workflow in aΒ Nutshell

YouTube algorithm workflow, Designed by Daksh Trehan, All RightsΒ Reserved

At YouTube, there are millions of content uploaded by users daily. The recommendation system tends to classify videos first based on the user’s characteristics and then based on the video’s metadata.

The algorithm analyzes the user’s attributes like Watch History, Search History, User’s taste, Age, Location, Time and then samples out few videos and sends them for the nextΒ phase.

The next phase typically includes filtering the sampled videos based on Video metadata, it includes Satisfaction rate for video, Genre, Thumbnail, Description, Tags, Total Views, Last watched,Β etc.

Concatenating the results of both the Candidate Generation and Ranking of Videos phase we get the probability of user watching sampled videos. The higher probability means the user is more interested in that kind of kinds ofΒ stuff.

This loop continues and the algorithm monitors the user’s interaction with each kind of video and dynamically keeps altering the ranking of videos thus delivering personalized and yet sufficient videos.

If you like this article, please consider subscribing to my newsletter: Daksh Trehan’s Weekly Newsletter.

Conclusion

Hopefully, this article has given you an insight into the YouTube recommendation system.

But, the information portrayed in this article is solely based on some theories that are experienced by users or publicized by YouTube developers. There can be a lot more to the algorithm that we’re missing out and I will try to add it in my future articles.

References:

[1] Deep Neural Networks for YouTube Recommendations

[2] YouTube Search & Discovery: Tips forΒ Success

[3] How does YouTube recommend videos?β€Šβ€”β€ŠAI EXPLAINED!

[4] How the YouTube Algorithm Works inΒ 2021

[5] YouTube’s Recommendation Engine: Explained

[6] How YouTube is Recommending Your Next Videoβ€Šβ€”β€ŠKDnuggets

[7] YouTube Usage Statistics

Feel free toΒ connect:

Portfolio ~ https://www.dakshtrehan.com

LinkedIn ~ https://www.linkedin.com/in/dakshtrehan

Follow for further Machine Learning/ Deep LearningΒ blogs.

Medium ~ https://medium.com/@dakshtrehan

Want to learnΒ more?

Detecting COVID-19 Using Deep Learning
The Inescapable AI Algorithm: TikTok
GPT-3 Explained to a 5-year old.
Tinder+AI: A perfect Matchmaking?
An insider’s guide to Cartoonization using Machine Learning
Reinforcing the Science Behind Reinforcement Learning
Decoding science behind Generative Adversarial Networks
Understanding LSTM’s and GRU’s
Recurrent Neural Network for Dummies
Convolution Neural Network forΒ Dummies

Cheers


How is YouTube using AI to recommend videos? was originally published in Towards AI on Medium, where people are continuing the conversation by highlighting and responding to this story.

Published via Towards AI

Feedback ↓