Commit 31282ac6 by Steven Bird

Merge pull request #286 from KaitainCPS/master

Fix issue 285
parents d05ea6b3 f625f7e1
......@@ -379,7 +379,7 @@ class Text(object):
if '_trigram_model' not in self.__dict__:
print "Building ngram index..."
estimator = lambda fdist, bins: LidstoneProbDist(fdist, 0.2)
self._trigram_model = NgramModel(3, self, estimator)
self._trigram_model = NgramModel(3, self, estimator=estimator)
text = self._trigram_model.generate(length)
print tokenwrap(text)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment