update
This commit is contained in:
@@ -15,14 +15,10 @@ class Assistant(
|
|||||||
private val model = Model(path)
|
private val model = Model(path)
|
||||||
private val buffer = ByteArray(4096)
|
private val buffer = ByteArray(4096)
|
||||||
private val microphone = line(format)
|
private val microphone = line(format)
|
||||||
private val actions = listOf<Action>(
|
val actions = listOf<Action>(Light(home))
|
||||||
Light(home)
|
|
||||||
)
|
|
||||||
|
|
||||||
private val recognizer = Recognizer(
|
private val recognizer = Recognizer(
|
||||||
model, format.sampleRate, Gson().toJson(
|
model, format.sampleRate, Gson()
|
||||||
listOf(name) + dict.words
|
.toJson(listOf(name) + dict.words)
|
||||||
)
|
|
||||||
)
|
)
|
||||||
|
|
||||||
private fun line(format: AudioFormat) = run {
|
private fun line(format: AudioFormat) = run {
|
||||||
|
|||||||
Reference in New Issue
Block a user