1
2
3
4
5
6
7
9 """
10 A processing interface for assigning a probability to the next word.
11 """
12
14 '''Create a new language model.'''
15 raise NotImplementedError()
16
18 '''Train the model on the text.'''
19 raise NotImplementedError()
20
22 '''Evaluate the probability of this word in this context.'''
23 raise NotImplementedError()
24
26 '''Randomly select a word that is likely to appear in this context.'''
27 raise NotImplementedError()
28
30 '''Evaluate the total entropy of a message with respect to the model.
31 This is the sum of the log probability of each word in the message.'''
32 raise NotImplementedError()
33