DEV Community

benthecoder
benthecoder

Posted on

Search for any comments in the Rick Roll music video

Overview of My Submission

The main idea of the app is a filter feature for YouTube video comments. I sometimes do CMD + F and look for particular comments and I thought it would be fun to make an app that filters out only comments I'm interested in.

In my app, any user can search for comments in the popular rick roll video – Rick Astley's Never Gonna Give You Up. There was restrictions in getting all the comment data however, due to the API quota restrictions. There's also the fact that there are new comments to the video every single day (2,047,723 comments as of the day this article is published)

Nonetheless, I was only able to get ~1 million comments, which I believe is more than enough for this little side project.

To build the web app, I used streamlit because it's easy to use and is great out-of-the-box. It has well designed components and I don't have to worry about web dev.

To build the search functionality, I used MongoDB Atlas Search, which was great and simple to set up. I loved the fact that I could test my search index before writing any code.

You can try out the app in the link below

https://share.streamlit.io/benthecoder/yt-comments-mongodb-search/main/yt_comments/app.py

Submission Category:

Choose Your Own Adventure

Link to Code

Github Repo

Additional Resources / Info

App result for the query - "rickrolled"
rickrolled query result

data frame output of result

data frame output

App result for query - "music"
music query result

Top comments (0)