International Journal Of Computer, Network Security and Information System (IJCONSIST)
Vol 8 No 1 (2026): September

Sentiment Analysis of Google Gemini Reviews Using K-Nearest Neighbor and Particle Swarm Optimization

Siraj Fatwa Sidqy (Universitas Pembangunan Jaya)
Yunus Widjaya (Universitas Pembangunan Jaya)



Article Info

Publish Date
01 Sep 2026

Abstract

Google Gemini, Google's generative AI assistant, receives a large volume of user reviews on the Google Play Store daily, making manual reading of user opinions impractical. This study analyzes the sentiment of Indonesian-language Google Gemini reviews using K-Nearest Neighbor (KNN) as the baseline classifier, then optimizes the k parameter through Particle Swarm Optimization (PSO) to examine its effect on classification performance. A total of 5,000 reviews were collected via web scraping using the Google Play Scraper library between 1 June and 1 September 2026, followed by preprocessing (duplicate removal, cleaning, case folding, normalization, tokenization, and stopword removal), leaving 2,858 labeled reviews, of which 2,000 were used for modeling. Negative, Neutral, and Positive labels were assigned automatically from each reviewer's star rating. Text was represented using CountVectorizer, producing 2,282 features, split into 1,600 training and 400 testing samples via stratified sampling. The baseline KNN model with k=5 achieved 79.50% accuracy, while PSO selected k=4 with a best cost of 0.188125, yielding a KNN-PSO accuracy of 80.75%, a 1.25 percentage-point increase. This improvement was accompanied by a rise in macro F1-score from 0.441 to 0.458 and weighted F1-score from 0.765 to 0.780, mainly driven by the Negative and Positive classes, while the Neutral class remained undetected by both models (F1=0). These findings indicate that PSO optimization yields a consistent but limited improvement, and does not resolve the underlying difficulty of identifying

Copyrights © 2026






Journal Info

Abbrev

ijconsist

Publisher

Subject

Computer Science & IT

Description

Focus and Scope The Journal covers the whole spectrum of intelligent informatics, which includes, but is not limited to : • Artificial Immune Systems, Ant Colonies, and Swarm Intelligence • Autonomous Agents and Multi-Agent Systems • Bayesian Networks and Probabilistic Reasoning • ...