Commit Graph

6 Commits

Author SHA1 Message Date
Brian S. Stephan 7c05f60ffd Markov: implement a min_size, which tries to make a chain of at least min_size words.
note that this isn't guaranteed, if the chain is such that the
current tuple has nowhere to go but to the end of the line, then
it will follow it --- it doesn't try to go back and rebuilt a different
chain or anything.
2011-01-19 18:44:07 -06:00
Brian S. Stephan ac0429569e Markov: size -> max_size, since I'm going to try adding a min_size soon 2011-01-19 18:35:01 -06:00
Brian S. Stephan 176ca25c68 Markov: increase the default max length from 25 words to 100 words.
it's expected that, usually, the chain will have hit an end before this.
2011-01-19 18:32:15 -06:00
Brian S. Stephan d592d3f3bb Markov: regexes should only match start of line --- add ^ 2011-01-19 10:20:20 -06:00
Brian S. Stephan 3283fac1ff Markov: remove some debugging i forgot to clean out before the initial commit 2011-01-18 22:51:40 -06:00
Brian S. Stephan 8dd223f778 Markov: a module to implement a chatterbot via markov chains.
yeah, we have MegaHAL, but i can't find a good implementation in
python that actually works and is stable, so we'll implement a
simple thing ourselves. works pretty much like MegaHAL does, but
without the string corruption.

original code provided by ape, care of mike bloy
2011-01-18 22:30:59 -06:00