Comparison of TF-IDF and Sentence-Transformer NLP Methods for a Perfume Recommendation System Based on User Descriptions with Streamlit Visualization
DOI:
https://doi.org/10.32664/fn1g4768Keywords:
Content-Based Filtering, Natural Language Processing, Perfume Recommendation, Sentence-Transformer, TF-IDFAbstract
The global perfume industry has grown considerably in recent years, yet helping consumers identify products that genuinely align with their personal taste remains a non-trivial problem, especially when preferences are communicated through unstructured, free-form natural language rather than standardized scent terminology. This study addresses that gap by evaluating and comparing two Natural Language Processing (NLP) text-representation methods, Term Frequency-Inverse Document Frequency (TF-IDF) and Sentence-Transformer, within a cross-lingual content-based filtering perfume recommendation system. The novelty lies in the cross-lingual setup, where unstructured Indonesian-language queries are matched directly against an English fragrance dataset of 42,115 records without any external translation module. A Streamlit web interface was deployed to collect data from 30 respondents, who submitted 180 graded relevance judgments for Top-3 recommendations evaluated through Precision@3 and Normalized Discounted Cumulative Gain (nDCG@3). System stability was assessed by partitioning the corpus into a training set of 33,692 records and a test set of 8,423 records. Sentence-Transformer, using the pre-trained paraphrase-multilingual-MiniLM-L12-v2 model, outperformed TF-IDF on all metrics, achieving a mean Precision@3 of 0.867 against 0.833 and a mean nDCG@3 of 0.912 against 0.850, with substantially lower score degradation across data partitions. These findings confirm that semantic embedding methods provide superior ranking quality and cross-lingual robustness, offering a scalable and translation-free solution applicable to multilingual product recommendation systems in commercial settings.





