LanguageIdentifierOptions
Options & Configuration ยท AiDotNet.Audio.LanguageIdentification
Configuration options for language identification models.
Inheritance: ModelOptions โ LanguageIdentifierOptions
Known derived types: ECAPATDNNOptions, Wav2Vec2LidOptions
For Beginners
Language identification (LID) determines which language is being spoken in an audio recording.
Key settings:
- SampleRate: Must match your audio (16000 Hz is common for speech)
- MinConfidence: Minimum confidence to report a detection
- TopK: Number of top language predictions to return
Example:
How It Works
These options configure how language identification models process audio and return predictions.
Constructors
| Constructor | Summary |
|---|---|
LanguageIdentifierOptions() |
Initializes a new instance with default values. |
LanguageIdentifierOptions(LanguageIdentifierOptions other) |
Initializes a new instance by copying from another instance. |
Properties
| Property | Summary |
|---|---|
OnnxModelOptions OnnxOptions { get; set; } |
Gets or sets the ONNX model options. |
bool UseVoiceActivityDetection { get; set; } |
Gets or sets whether to apply voice activity detection before language identification. |
double MinConfidence { get; set; } |
Gets or sets the minimum confidence threshold for valid detection. |
double MinDurationSeconds { get; set; } |
Gets or sets the minimum audio duration in seconds required for reliable detection. |
int EmbeddingDimension { get; set; } |
Gets or sets the embedding dimension. |
int FftSize { get; set; } |
Gets or sets the FFT size for spectrogram computation. |
int HopLength { get; set; } |
Gets or sets the hop length between frames. |
int NumMels { get; set; } |
Gets or sets the number of mel filterbank channels. |
int SampleRate { get; set; } |
Gets or sets the sample rate of input audio in Hz. |
int SegmentWindowMs { get; set; } |
Gets or sets the window size in milliseconds for segmented language detection. |
int TopK { get; set; } |
Gets or sets the number of top language predictions to return. |
string ModelPath { get; set; } |
Gets or sets the path to the ONNX model file. |