Accurately distinguishing between impulsive and planned purchasing behavior remains a critical challenge in e-commerce analytics, given the multidimensional and dynamic nature of consumer data. Existing machine learning approaches often rely on conventional hyperparameter tuning strategies, which may limit model robustness and generalization. This study proposes a hybrid framework that integrates two bio-inspired metaheuristic algorithms—Walrus Optimization Algorithm (WaOA) and Weevil Damage Optimization Algorithm (WDOA)—with three gradient boosting classifiers (XGBoost, LightGBM, and CatBoost) to improve hyperparameter optimization and classification performance. Empirical evaluation indicates that the WaOA-optimized XGBoost model achieved strong predictive performance, reaching F1-scores of 0.9879 for impulsive purchases and 0.9798 for need-based purchases, with an overall testing accuracy of 97.3%. Although statistical tests suggest that performance differences among the evaluated models are not significant, the optimized configurations demonstrate consistently high predictive capability across evaluation metrics. Feature importance analysis identifies product rating, customer satisfaction, and loyalty program membership as key predictors of consumer decision type. The proposed framework demonstrates promising performance and interpretability, offering practical support for data-driven decision-making in digital retail environments.
Na Cui (Sat,) studied this question.