Machine learning (ML) may provide a new methodology to directly learn from raw data to develop constitutive models for soils by using pure mathematic skills, and it has presented success and versatility in cases of simple stress paths due to its strong non-linear mapping capacity without limitations of constitutive formulations. However, current studies on the ML based constitutive modeling of soils is still very limited. This study comprehensively reviews the application of ML algorithms in the development of constitutive models of soils and compares the performance of different ML algorithms. First, the basic principles of typical ML algorithms used in describing soil behaviors are briefly elaborated. The main characteristics and the limitations of such ML algorithms are summarized and compared. Then, the methodology of developing a ML-based soil model is reviewed from six aspects, such as adopted ML algorithms, data source, framework of the ML based model, training strategy, generalization ability and application scope. Finally, five new ML based models are developed using five typical ML algorithms (i.e. BPNN, RBF, LSTM, GRU and BiLSTM that can predict multi outputs together) based on same set of experimental results of sand, and compare each other in terms of the predictive accuracy and generalization ability. Results show the long short-term memory (LSTM) neural network and its variants are most suitable for developing constitutive models. Moreover, some useful suggestions for developing ML-based soil models are also provided for the community.