Triply Periodic Minimal Surface (TPMS) lattice structures are utilized in diverse fields such as engineering, material design, and biomedical. The use of appropriate TPMS lattice structures in 3D printing can obtain benefits in terms of production efficiency and material reduction towards a greener 3D printing process. However, there is a lack of an automated solution to suggest the appropriate TPMS lattice structure parameters, such that unnecessary material wastage cannot be neglected in the existing practices. To address the above challenges, this study proposes a machine learning-based recommendation framework for generating the TPMS lattice structures based on the engineering requirements. First, we compiled a dataset by producing 144 samples via the material extrusion (ME) technique and conducted compression tests on four TPMS lattice structures (Diamond, Gyroid, Schwarz, and split-P), each with varying parameters, fabricated using Polylactic acid (PLA) material. Second, we train four machine learning algorithms (K-Nearest Neighbors, Decision Tree, Random Forest, and Bayesian Regression) on this dataset to predict TPMS lattice structure (unit cell type, unit cell size, and wall thickness). Extensive experiments assess algorithm performance using R-squared values and Root Mean Square Error (RMSE) as evaluation measures. Our results indicate that the Random Forest and Decision Tree algorithms perform best, achieving R-squared scores of 0.9694 and 0.9689, along with RMSE values of 0.1180 and 0.0795, respectively. This work not only advances the field's understanding of automated selection for TPMS lattice structures but also holds noteworthy implications for eco-design and eco-innovation, particularly in the realm of sustainable and efficient green 3D printing applications.