SpLexicon
The SpLexicon automation object provides access to lexicons. Lexicons contain information about words that can be recognized or spoken.
SAPI defines two types of lexicons. The first is the application lexicon. Application lexicons are the words that all applications can use. They are installed by speech-enabled applications and are read-only. As a result, the application lexicons may vary slightly among computers. The second type is the user lexicon. User lexicons store words specific to a speech user.
An SpLexicon object includes the user lexicon and all application lexicons available on the computer. Calls to SpLexicon methods may return data from several different lexicons.
The SpUnCompressedLexicon object represents a single application lexicon.
Automation Interface Elements
The SpLexicon automation object contains the following elements:
Properties | Description |
---|---|
GenerationId Property | Gets the generation ID of the current application lexicon. |
Methods | Description |
---|---|
AddPronunciation Method | Adds a pronunciation, specified in phone symbols, to the current user lexicon. |
AddPronunciationByPhoneIds Method | Adds a pronunciation, specified in phone IDs, to the current user lexicon. |
GetGenerationChange Method | Gets a list of words in the current user lexicon that have changed since the specified generation. |
GetPronunciations Method | Gets the pronunciations and parts of speech for a word from the user and application lexicons. |
GetWords Method | Gets a list of all words in the current user and application lexicons. |
RemovePronunciation Method | Removes a word and/or its pronunciations, specified in phone symbols, from the user lexicon. |
RemovePronunciationByPhoneIds Method | Removes a word and/or its pronunciations, specified in phone IDs, from the user lexicon. |