The lmtool
module queries the language model. It can be used to retrieve the language model vocabulary list, to check whether a specific word is in the language model vocabulary, and to calculate the language model perplexity over a sample text file.
Mode | Input | Output | Description |
---|---|---|---|
WORD
|
Does not accept any input streams or produce any output streams. Reports whether a word is present in the language model and, if it is present, its ranking (where 1 is the most common word, 2 is the second most common, and so on). | ||
TEXT
|
Does not accept any input streams or produce any output streams. Calculates the perplexity of a language model and out-of-vocabulary, given a sample text file. | ||
VOCAB
|
Does not accept any input streams or produce any output streams. Lists the most common words in the language model. |
Examples:
output ← lmtool(WORD,input)
output ← lmtool(TEXT,input)
output ← lmtool(VOCAB,input)
Some of these parameters do not have an internal default value. You must either set the configuration parameter to a suitable value, or set the value in the corresponding action parameter.
|