public class AILocalWakeupIncrementIntent extends BaseIntent
needCopyFeedData, needCopyResultData, useCustomFeed
Constructor and Description |
---|
AILocalWakeupIncrementIntent() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getBlackWords()
获取黑名单
|
java.util.Map<java.lang.String,java.lang.Double> |
getCustomThreshold()
获取自定义的词表
|
double |
getEnglishThreshold() |
double |
getFillerPenaltyScore() |
boolean |
getIsIgnoreThreshold() |
int |
getMaxSpeechTime()
获取单词允许最大录音时长,单位 s
|
int |
getNoSpeechTime()
获取NoSpeechTime
|
java.lang.String |
getSaveAudioPath()
获取音频保存路径
|
double |
getThreshold()
获取热词置信度阈值
|
java.lang.String |
getWords()
获取词表
|
boolean |
isUseContinuousRecognition()
是否支持连续识别,默认打开
|
boolean |
isUseFiller() |
void |
setBlackWords(java.lang.String[] blackWords)
设置热词黑名单
|
void |
setCustomThreshold(java.lang.String[] words,
java.lang.Double[] threshold)
自定义单词置信度阈值
|
void |
setEnglishThreshold(double englishThreshold) |
void |
setFillerPenaltyScore(double fillerPenaltyScore)
根据误唤醒集合设置的值
|
void |
setIsIgnoreThreshold(boolean isIgnoreThreshold)
设置是否忽略阈值,不管kernel返回的结果是大于还是小于阈值,都将结果返回给上层
|
void |
setMaxSpeechTime(int maxSpeechTime)
设置音频最大录音时长,达到该值将取消语音引擎并抛出异常
允许的最大录音时长 单位秒 0 表示无最大录音时长限制 默认大小为10S 须在start之前设置才生效 |
void |
setNoSpeechTime(int noSpeechTime)
设置启动识别后无人声输入最大录音时常,到达该值后将跑出异常
默认 0 s ,热词引擎不开启此配置
|
void |
setSaveAudioPath(java.lang.String path)
设置音频文件存储路径,release 版本建议关闭
|
void |
setThreshold(double threshold)
设置置信度阈值
|
void |
setUseContinuousRecognition(boolean useContinuousRecognition)
设置是否开启连续识别,默认 true
start之前设置有效
|
void |
setUseFiller(boolean useFiller)
设置是否使用解码网络里增加的filler路径
|
void |
setWords(java.lang.String words)
直接按照内核既定格式设置词表如: \"打开副屏,打开今日头条\"
|
void |
setWords(java.lang.String[] words)
设置词表
|
isNeedCopyFeedData, isNeedCopyResultData, isUseCustomFeed, setNeedCopyFeedData, setNeedCopyResultData, setUseCustomFeed
public void setIsIgnoreThreshold(boolean isIgnoreThreshold)
public boolean getIsIgnoreThreshold()
public void setUseContinuousRecognition(boolean useContinuousRecognition)
useContinuousRecognition
- useContinuousRecognitionpublic void setMaxSpeechTime(int maxSpeechTime)
maxSpeechTime
- 最大人声时长public void setNoSpeechTime(int noSpeechTime)
noSpeechTime
- 无人声时常public void setSaveAudioPath(java.lang.String path)
path
- 文件路径public void setWords(java.lang.String[] words)
words
- 词表public void setWords(java.lang.String words)
words
- 内核词表public void setBlackWords(java.lang.String[] blackWords)
blackWords
- 黑名单词表public void setThreshold(double threshold)
threshold
- 阈值public void setEnglishThreshold(double englishThreshold)
public void setCustomThreshold(java.lang.String[] words, java.lang.Double[] threshold)
words
- 词表threshold
- 阈值public int getNoSpeechTime()
public double getThreshold()
public double getEnglishThreshold()
public int getMaxSpeechTime()
public java.lang.String getWords()
public java.lang.String getSaveAudioPath()
public boolean isUseContinuousRecognition()
public java.lang.String getBlackWords()
public java.util.Map<java.lang.String,java.lang.Double> getCustomThreshold()
Map
public boolean isUseFiller()
public void setUseFiller(boolean useFiller)
useFiller
- 默认不开启public double getFillerPenaltyScore()
public void setFillerPenaltyScore(double fillerPenaltyScore)
fillerPenaltyScore
- 默认 1.5,可根据实际情况再调整