--- license: cc-by-nc-sa-4.0 language: - vai tags: - stt - asr - onnx - onnx-asr - wav2vec2 - automatic-speech-recognition base_model: - facebook/wav2vec2-xls-r-300m --- # misterkissi-w2v2-lg-xls-r-300m-vai-onnx (ONNX) ONNX export of [misterkissi/w2v2-lg-xls-r-300m-vai](https://huggingface.co/misterkissi/w2v2-lg-xls-r-300m-vai), a Vai wav2vec2-CTC ASR model fine-tuned by [Emmanuel Kissi](https://huggingface.co/misterkissi) on top of [facebook/wav2vec2-xls-r-300m](https://huggingface.co/facebook/wav2vec2-xls-r-300m), converted for use with [onnx-asr](https://github.com/istupakov/onnx-asr) (`wav2vec2-ctc` model type) and the [OVOS onnx-asr STT plugin](https://github.com/OpenVoiceOS/ovos-stt-plugin-onnx-asr). Per-utterance zero-mean/unit-variance normalization is baked into the ONNX graph, masked by `input_lengths` for correct behavior with padded/batched input, so the model works with onnx-asr's plain `identity` preprocessor (raw 16kHz waveform in). ## Usage ```py import onnx_asr model = onnx_asr.load_model("OpenVoiceOS/misterkissi-w2v2-lg-xls-r-300m-vai-onnx") print(model.recognize("test.wav")) ``` Or with the OVOS plugin: ```py from ovos_stt_plugin_onnx_asr import OnnxASRSTT stt = OnnxASRSTT(config={"model": "OpenVoiceOS/misterkissi-w2v2-lg-xls-r-300m-vai-onnx"}) ``` ## Files * `model.onnx` / `model.onnx.data` (when present; small models may be fully inline) -- fp32 ONNX graph (inputs: `input_values` (batch, samples) float32, `input_lengths` (batch,) int64; output: `logprobs` (batch, frames, vocab) float32 log-softmax). * `vocab.txt` -- CTC vocabulary in onnx-asr's `token id` format (word-delimiter -> `▁`, pad token -> ``). * `config.json` -- `{"model_type": "wav2vec2-ctc", "subsampling_factor": 320}`. ## License CC BY-NC-SA 4.0, inherited from the source model [misterkissi/w2v2-lg-xls-r-300m-vai](https://huggingface.co/misterkissi/w2v2-lg-xls-r-300m-vai).