Sentiment Analysis of YouTube Comments Using XLM-RoBERTa to Support the Understanding of Multilingual Public Opinion

Authors

  • Kevin R. K. Meliala Department of Computer Science, Bina Nusantara University, Indonesia , Binus University image/svg+xml
  • Dhafin W. Wicaksono Department of Computer Science, Bina Nusantara University, Indonesia , Binus University image/svg+xml
  • Jonathan E. Siregar Department of Computer Science, Bina Nusantara University, Indonesia , Binus University image/svg+xml
  • Naufal D. Prakintara Department of Computer Science, Bina Nusantara University, Indonesia , Binus University image/svg+xml
  • Raafi A. Ramadhan Department of Computer Science, Bina Nusantara University, Indonesia , Binus University image/svg+xml

Abstract

YouTube is one of the largest social media platforms, generating millions of user comments every day. These comments contain various opinions, responses, and perceptions that can be utilized to understand public reactions toward content, products, and services. However, the massive volume of comments makes manual analysis inefficient and time-consuming. This study aims to develop a YouTube comment sentiment analysis system based on Natural Language Processing (NLP) using the XLM-RoBERTa model to automatically classify sentiment in a multilingual environment. The system is developed using FastAPI as the backend, React as the frontend, and the YouTube Data API v3 as the source for retrieving comment data. The analysis process includes comment retrieval, preprocessing, spam and noise filtering, model inference, heuristic post-processing, and result visualization through an interactive dashboard. The results demonstrate that the system is capable of classifying comments into positive and negative sentiment categories with strong performance. The dashboard also provides various analytical features, including sentiment distribution, word cloud visualization, comment search, and top comments ranked by confidence score. The novelty of this research lies in the integration of the multilingual XLM-RoBERTa model with a heuristic post-processing mechanism to improve the classification quality of Indonesian and code-mixed language comments. The developed system is expected to assist users, researchers, and organizations in understanding public opinion more quickly, accurately, and efficiently.

Keywords:

Sentiment Analysis, YouTube, XLM-RoBERTa, Natural Language Processing, Multilingual

Downloads

Published

2026-08-31