public class AIWakeupConfig extends BaseConfig
Modifier and Type | Class and Description |
---|---|
static class |
AIWakeupConfig.Builder |
tagSuffix
Constructor and Description |
---|
AIWakeupConfig() |
Modifier and Type | Method and Description |
---|---|
Languages |
getLanguages() |
int |
getOneShotCacheTime() |
AIOneshotConfig |
getOneshotConfig() |
java.lang.String |
getWakeupResource() |
boolean |
isPreWakeupOn() |
void |
setOneShotCacheTime(int oneShotCacheTime)
设置oneshot功能下需要缓存的音频时长,根据具体的硬件性能和唤醒词长度调节。
|
void |
setWakeupResource(java.lang.String wakeupResource)
设置唤醒资源
|
java.lang.String |
toString() |
getTagSuffix, setTagSuffix
public void setWakeupResource(java.lang.String wakeupResource)
1. 如在 sd 里设置为绝对路径 如/sdcard/speech/***.bin
2. 如在 assets 里设置为名称
wakeupResource
- 唤醒资源public void setOneShotCacheTime(int oneShotCacheTime)
oneShotCacheTime
- 单位毫秒, 默认为1200mspublic java.lang.String getWakeupResource()
public int getOneShotCacheTime()
public AIOneshotConfig getOneshotConfig()
public boolean isPreWakeupOn()
public Languages getLanguages()
public java.lang.String toString()
toString
in class java.lang.Object