A whisper stt plugin for OVOS
Project description
Description
OpenVoiceOS STT plugin for Whisper-LM-transformers, KenLM and Large language model integration with Whisper ASR models implemented in Hugging Face library.
Install
pip install ovos-stt-plugin-whisper-lm
⚠️ only python <=3.11 supported by some of the dependencies
Models
Pretrained ngram models are provided by HiTZ
Each lm_model is built using the KenLM toolkit and is based on n-gram statistics extracted from large, domain-specific corpora. The models available are:
- Basque (eu):
5gram-eu.bin(11G) - Galician (gl):
5gram-gl.bin(8.4G) - Catalan (ca):
5gram-ca.bin(20G) - Spanish (es):
5gram-es.bin(13G)
Finetuned whisper models are also available from Xabier Zuazo for those languages
Instead of a ngram model it is also possible to use a LLM such as latxa
Configuration
In the example below, we use HiTZ Basque KenLM model. Optimize the lm_alpha, lm_beta, etc., for best results with your own models.
"stt": {
"module": "ovos-stt-plugin-whisper-lm",
"ovos-stt-plugin-whisper-lm": {
"model": "zuazo/whisper-medium-eu",
"lm_repo": "HiTZ/whisper-lm-ngrams",
"lm_model": "5gram-eu.bin",
"lm_alpha": 0.33582369,
"lm_beta": 0.68825565,
"use_cuda": true
}
}
💡
lm_repoonly needs to be set if you want to specify a specific filename inlm_model
To use an LLM instead of a ngram model
"stt": {
"module": "ovos-stt-plugin-whisper-lm",
"ovos-stt-plugin-whisper-lm": {
"model": "zuazo/whisper-medium-eu",
"lm_model": "HiTZ/latxa-7b-v1.2",
"lm_alpha": 2.73329396,
"lm_beta": 0.00178595,
"use_cuda": true
}
}
⚠️ Running large LMs side-by-side with Whisper requires sufficient GPU memory.
Credits
This plugin was developed by TigreGotico for OpenVoiceOS under the ILENIA project.
This plugin was funded by the Ministerio para la Transformación Digital y de la Función Pública and Plan de Recuperación, Transformación y Resiliencia - Funded by EU – NextGenerationEU within the framework of the project ILENIA with reference 2022/TL22/00215337
The pretrained Ngram models are available under the Creative Commons Attribution 4.0 International License (CC BY 4.0). You are free to use, modify, and distribute this model as long as you credit the original creators.
@misc{dezuazo2025whisperlmimprovingasrmodels,
title={Whisper-LM: Improving ASR Models with Language Models for Low-Resource Languages},
author={Xabier de Zuazo and Eva Navas and Ibon Saratxaga and Inma Hernáez Rioja},
year={2025},
eprint={2503.23542},
archivePrefix={arXiv},
primaryClass={cs.CL},
url={https://arxiv.org/abs/2503.23542},
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ovos_stt_plugin_whisper_lm-0.0.6a9.tar.gz.
File metadata
- Download URL: ovos_stt_plugin_whisper_lm-0.0.6a9.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e5a0849eac0541a562f97d4e8c787a5421f0d8a9194db43ae4792b0ca09768a8
|
|
| MD5 |
6dae13fb6d83c868c00bd16e882a7d0a
|
|
| BLAKE2b-256 |
ae47d669114c44ea56f31c5ebc22b4e13cd7bb43f275c3e86fa2dfc6cb2764de
|
File details
Details for the file ovos_stt_plugin_whisper_lm-0.0.6a9-py3-none-any.whl.
File metadata
- Download URL: ovos_stt_plugin_whisper_lm-0.0.6a9-py3-none-any.whl
- Upload date:
- Size: 9.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5c15e3e7e3089d871ecef9748862a383cfa87e6bc2677d71c4fd667daa694da7
|
|
| MD5 |
1c8e43f5fa94b5ff0eb2119abb0ae45e
|
|
| BLAKE2b-256 |
b0871edaf226b81ff3a6bec2f2a105c23b9dbda70e36481ae05523456f91ff26
|