Stochastic and direct acceleration mechanisms in the Earth's magnetotail