Similar Items: Machine Learning-driven Energy-efficient Routing in Wireless Sensor Networks: Predicting Node Lifetime for Optimized Performance