On a class of non-Markov decision processes