Machine learning in Erlang