Skip to content

Instantly share code, notes, and snippets.

@terbo
Created November 22, 2016 23:50
Show Gist options
  • Save terbo/92c93b58a855434ede479d7442097953 to your computer and use it in GitHub Desktop.
Save terbo/92c93b58a855434ede479d7442097953 to your computer and use it in GitHub Desktop.
Quick Markov chain from the command line using python/markovify
#!/usr/bin/env python
import sys,markovify
try: print markovify.Text(open(sys.argv[1]).read()).make_short_sentence(60)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment