basic markov functionality, working on making it better though