Sentiment Analysis of Public Opinion on the Pertalite Fuel Issue in YouTube Comments Using the Naïve Bayes Method - Frevita, Ernika; Ahmad, Fandi; Al Rosyid, Harun (Journal of Artificial Intelligence and Engineering Applications (JAIEA), 2026)
The issue of Pertalite fuel (BBM Pertalite) has generated widespread public reactions on social media, particularly on the YouTube platform, where users actively express opinions through comment sections. This study aims to analyze public sentiment toward the Pertalite fuel issue based on YouTube comments using a text mining approach and the Naïve Bayes classification algorithm. The dataset consists of approximately 3,000 YouTube comments collected via the YouTube Data API and processed through several text preprocessing stages, including cleaning, normalization, tokenization, stopword removal, and stemming. Sentiment labeling was performed using a lexicon-based approach, followed by feature extraction using Term Frequency–Inverse Document Frequency (TF-IDF). The data were divided into training and testing sets with an 80:20 ratio. Experimental results indicate that the Naïve Bayes model achieved an accuracy of 69.67%, with negative sentiment dominating public discourse both in terms of comment frequency and user engagement measured by likes. These findings suggest a prevailing public dissatisfaction with the Pertalite fuel issue and highlight the usefulness of social media–based sentiment analysis as a data-driven instrument for understanding public perception. The results of this study provide valuable insights that can support the evaluation of energy policies and demonstrate the potential of sentiment analysis in policy-related public opinion studies.