API ReferenceLocal APIs
useVAD
React hook — real-time mic voice-activity detection (Silero).
Auto-generated from JSDoc in
packages/react/src/local/useVAD.ts. Do not edit — runnpm run docs:api.
useVAD
functionfunction useVAD(opts: UseVADOptions): UseVADUseVAD
interfaceinterface UseVADstatus: VADStatus
error?: Error
start: () => Promise<void>
Request mic permission, load the model, begin listening.
stop: () => void
Stop listening (keeps the loaded model for a fast restart).
UseVADOptions
interfaceinterface UseVADOptionsonSpeechEnd?: (audio: Float32Array) => void
Called with the 16 kHz Float32 audio of each completed speech segment.
onSpeechStart?: () => void
baseAssetPath?: string
Override the CDN paths for the model + onnx wasm if self-hosting.
onnxWASMBasePath?: string
VADStatus
type aliastype VADStatus = idle | loading | listening | speaking | error