Interface: SpeechAudioOptions
@kortexya/reasoninglayer / SpeechAudioOptions
Interface: SpeechAudioOptions
Section titled “Interface: SpeechAudioOptions”Defined in: src/speech-audio.ts:13
Properties
Section titled “Properties”beforeCapture?
Section titled “beforeCapture?”
optionalbeforeCapture?:Promise<unknown>
Defined in: src/speech-audio.ts:26
Authenticate/negotiate before requesting microphone access. Context activation still begins synchronously from the caller’s user gesture.
capture?
Section titled “capture?”
optionalcapture?:boolean
Defined in: src/speech-audio.ts:23
Playback-only use never requests or opens a microphone.
deviceId?
Section titled “deviceId?”
optionaldeviceId?:string
Defined in: src/speech-audio.ts:21
onBargeIn
Section titled “onBargeIn”onBargeIn: () =>
void
Defined in: src/speech-audio.ts:16
Returns
Section titled “Returns”void
onCapture
Section titled “onCapture”onCapture: (
samples) =>void
Defined in: src/speech-audio.ts:14
Parameters
Section titled “Parameters”samples
Section titled “samples”Int16Array
Returns
Section titled “Returns”void
onError
Section titled “onError”onError: (
error) =>void
Defined in: src/speech-audio.ts:18
Parameters
Section titled “Parameters”Error
Returns
Section titled “Returns”void
onPlayed
Section titled “onPlayed”onPlayed: (
acknowledgment) =>void
Defined in: src/speech-audio.ts:15
Parameters
Section titled “Parameters”acknowledgment
Section titled “acknowledgment”Returns
Section titled “Returns”void
onState?
Section titled “onState?”
optionalonState?: (state) =>void
Defined in: src/speech-audio.ts:17
Parameters
Section titled “Parameters”"playing" | "drained" | "underrun" | "suspended"
Returns
Section titled “Returns”void
signal?
Section titled “signal?”
optionalsignal?:AbortSignal
Defined in: src/speech-audio.ts:19
workletUrl?
Section titled “workletUrl?”
optionalworkletUrl?:string
Defined in: src/speech-audio.ts:20