This research explores public sentiment towards the Indonesian police using sentiment analysis and machine learning techniques. The study addresses the challenge of understanding public opinion based on social media comments related to significant police cases. The aim is to compare reported satisfaction levels with actual public sentiment. Utilizing the Indonesian RoBERTa base IndoLEM sentiment classifier, comments were analyzed and preprocessed. The classification was conducted using Random Forest (RF) and Complement Naive Bayes (CNB) models, incorporating unigram and bi-gram features. Oversampling techniques were applied to handle data imbalance. The best-performing model, Random Forest with bi-gram features, achieved high evaluation scores, including a precision of 0.91 and accuracy of 0.91. The findings reveal significant insights into public opinion, contributing to improved law enforcement strategies and public trust.
Copyrights © 2025