Package com.keenresearch.keenasr
Class KASRPhone
java.lang.Object
com.keenresearch.keenasr.KASRPhone
KASRPhone represents a phone (speech segment that possesses distinct physical or perceptual
properties and serves as the basic unit of phonetic speech analysis). ASR Bundle used to
initialize the recognizer will contain a list of phones that were used to train the models.
In the context of KeenASR SDK, each recognized word is represented via KASRWord object, which
will contain an array of KASRPhone object that correspond to the most likely phonetic
transcription of the given word.
-
Method Summary
Modifier and TypeMethodDescriptionfloat
Duration, in seconds, for this phone.float
Pronunciation score in the range 0 to 1.float
Start time, in seconds, for this phone relative to when the recognizer started to listen.getText()
Text of the phonetoString()
String representation of this object.
-
Method Details
-
getText
Text of the phone- Returns:
- text of the phone
-
getStartTime
public float getStartTime()Start time, in seconds, for this phone relative to when the recognizer started to listen.- Returns:
- phone start time in seconds
-
getDuration
public float getDuration()Duration, in seconds, for this phone.- Returns:
- phone duration in seconds
-
getPronunciationScore
public float getPronunciationScore()Pronunciation score in the range 0 to 1. Higher value corresponds to better native-like pronunciation. Scores are computed in reference to the recognizer word and its corresponding phonetic representation.- Returns:
- pronunciations score for the phone
-
toString
String representation of this object. Useful for debugging and logging purposes.
-