edu.cmu.sphinx.result
Interface WordResult

All Known Implementing Classes:
SimpleWordResult

public interface WordResult

Represents a word in a recognition result. This is designed specifically for obtaining confidence scores. All scores are maintained in LogMath log base.


Method Summary
 double getConfidence()
          Returns a log confidence score for this WordResult.
 Data[] getDataFrames()
          Gets the feature frames associated with this word
 int getEndFrame()
          Gets the ending frame number for the word
 LogMath getLogMath()
          Returns the log math of the scores.
 Pronunciation getPronunciation()
          Gets the pronunciation for this word.
 double getScore()
          Gets the total score for this word.
 int getStartFrame()
          Gets the starting frame number for the word
 boolean isFiller()
          Does this word result represent a filler token?
 java.lang.String toString()
          Returns a string representation of this object
 

Method Detail

getScore

double getScore()
Gets the total score for this word.

Returns:
the score for the word (in LogMath log base)

getConfidence

double getConfidence()
Returns a log confidence score for this WordResult. Use the getLogMath().logToLinear() method to convert the log confidence score to linear. The linear value should be between 0.0 and 1.0 (inclusive) for this word.

Returns:
a log confidence score which linear value is between 0.0 and 1.0 (inclusive)

getLogMath

LogMath getLogMath()
Returns the log math of the scores.

Returns:
the log math of the scores

getPronunciation

Pronunciation getPronunciation()
Gets the pronunciation for this word.

Returns:
the pronunciation for the word

getStartFrame

int getStartFrame()
Gets the starting frame number for the word

Returns:
the starting frame number for the word

getEndFrame

int getEndFrame()
Gets the ending frame number for the word

Returns:
the ending frame number for the word

getDataFrames

Data[] getDataFrames()
Gets the feature frames associated with this word

Returns:
the set of feature frames associated with this word, or null if the frames are not available.

toString

java.lang.String toString()
Returns a string representation of this object

Overrides:
toString in class java.lang.Object

isFiller

boolean isFiller()
Does this word result represent a filler token?

Returns:
true if this is a filler