jgram

jgram is a simple markov-chain library suitable for building rudimentary n-gram representations of sequences of any Java objects. It has an extensible scoring mechanism and a generator for traversing a random path through n-gram states based on transition score. (Source: http://freecode.com/)