SPPHRASERULE

Microsoft Speech SDK

The Microsoft.com Speech website Microsoft Speech SDK SAPI 5.1

SPPHRASERULE

SPPHRASERULE contains the information for a rule in a grammar result. SAPI uses the pFirstChild and pNextSibling pointers to represent the parse tree. SPPHRASE.Rule is the root node of the parse tree.

struct tagSPPHRASERULE
{
    const   WCHAR          *pszName;
    ULONG                   ulId;
    ULONG                   ulFirstElement;
    ULONG                   ulCountOfElements;
    const   SPPHRASERULE   *pNextSibling;
    const   SPPHRASERULE   *pFirstChild;
    float                   SREngineConfidence;
    signed char             Confidence;
 };

Members

pszName
Name of this rule (in Speech Text Grammar Format set using <RULE NAME="MyName">).
ulId
ID of this rule (set using <RULE ID="123">).
ulFirstElement
The index of the first spoken element (word) of this rule.
ulCountOfElements
Number of spoken elements (words) spanned by this rule.
pNextSibling
Pointer to the next sibling in the parse tree.
pFirstChild
Pointer to the first child node in the parse tree.
SREngineConfidence
Confidence for this rule computed by the SR engine. The value is engine dependent and not standardized across multiple SR engines. See Confidence Scoring and Rejection in SAPI Speech Recognition Engine Guide for additional details.
Confidence
Confidence for this rule computed by SAPI. The value is either SP_LOW_CONFIDENCE, SP_NORMAL_CONFIDENCE, or SP_HIGH_CONFIDENCE. See Confidence Scoring and Rejection in SAPI Speech Recognition Engine Guide for additional details.