1 parent 137802a commit 981fa64Copy full SHA for 981fa64
1 file changed
text.py
@@ -105,7 +105,8 @@ def add_sequence(self, words):
105
self.add(tuple(words[i:i+n]))
106
107
def samples(self, nwords):
108
- """Build up a random sample of text n words long, using the"""
+ """Build up a random sample of text nwords words long, using
109
+ the conditional probability given the n-1 preceding words."""
110
n = self.n
111
nminus1gram = ('',) * (n-1)
112
output = []
0 commit comments