Table of Contents

Property EnableVoiceActivityDetection

Namespace
LMKit.Speech
Assembly
LM-Kit.NET.dll

EnableVoiceActivityDetection

Gets or sets whether voice activity detection is enabled. When true, only the detected speech portions of the audio are processed, which can reduce processing time and improve speed. All VAD-specific behavior is governed by VadSettings. Defaults to true.

public bool EnableVoiceActivityDetection { get; set; }

Property Value

bool

Examples

using LMKit.Model;
using LMKit.Speech;
using LMKit.Media.Audio;
using System;

// Load a Whisper model
LM model = LM.LoadFromModelID("whisper-large-turbo3");

// Create the speech-to-text engine
var engine = new SpeechToText(model);

// Disable VAD to process all audio including silence
engine.EnableVoiceActivityDetection = false;

// Transcribe
var result = engine.Transcribe(new WaveFile("audio.wav"));
foreach (var segment in result.Segments)
{
    Console.WriteLine(segment.Text);
}