What changed
- Python
- C
vad-2.1-xxs-16khz for general speech detection, or vad-vf-2.0-s-16khz to detect the primary speaker only.
Migrate the setup
- Python
- C
Feed the VAD your original audio
If you run enhancement and VAD together, give both the same original input block. Do not chain them.- Python
- C
The two models can have different optimal block sizes and sample rates. If yours disagree, initialize both to the configuration your stream already uses, or keep separate block sizes and feed each object from your own buffer.
Retune sensitivity
This is the step most likely to change your application’s behavior.
There is no conversion formula. The old value described leftover energy after enhancement, the new one describes model confidence, and the direction is inverted.
Start from the model default and adjust against representative production audio.
raw_vad_probability() gives the model’s probability before thresholding, which is the practical way to pick a threshold from recordings.
SpeechHoldDuration and MinimumSpeechDuration keep their previous meaning and units.
Delay queries
The processor delays audio, the VAD does not, so there is no single output delay any more. The VAD’s prediction delay tells you how far behind its input the published decision is, so you can align speech decisions with the audio timeline. Fed from the same block, the two are independent.Node.js has not adopted the rename yet. Its
VadContext.getOutputDelay() returns the prediction delay, so only the name differs.Also worth knowing
- Model types are enforced. A processor takes enhancement and bypass models, a VAD takes VAD models, an analyzer takes analysis models. A mismatch fails at creation with
AIC_ERROR_CODE_MODEL_TYPE_UNSUPPORTED, orModelTypeUnsupportedErrorin Python, instead of silently doing something else. - Reset clears published values immediately. After a reset, the speech decision is false and the raw probability is
0.0, so queries no longer return stale values from the previous stream. - Sessions can be closed explicitly with
aic_vad_terminate_session, orterminate_session()in Python, without waiting for the object to be destroyed. Useful where deallocation is delayed. The object cannot process more audio afterwards.
Related migrations
Multi-channel to mono
The same release removed multi-channel processing and buffering.
Python SDK 2.5 to 3.0
Every Python-specific rename in this release.