Markov Chain for Text
An implementation of second-order Markov Chains for text generation.
For usage, see example file, markov-example.py which shows the two ways to train the Markov Chain:
- with a single string as the training set
- or a list of filenames
Example text files are also included.
- lyrics.txt includes the lyrics to most Muse songs (from AZ Lyrics)
- standup.txt includes the text from a Robin Williams stand-up routine
Happy text generating!