Add algorithms, training and tests