Model reference · open weights
nb-wav2vec2-nynorsk is an open-weight audio or speech model from NbAiLab, listed in the AxForge catalogue. AxForge can bring it up on EU-owned hardware for you on request — with the licence handled where one is required.
About
Norwegian Wav2Vec2 Model - 1B Nynorsk This model is finetuned on top of feature extractor XLS-R from Facebook/Meta. The finetuned model achieves the following results on the test set with a 5-gram KenLM. The numbers in parentheses are the results without the language model: - WER: 0.1132 (0.1364) - CER: 0.0402 (---) Model description This is one of several Wav2Vec-models our team created during the 🤗 hosted Robust Speech Event. This is the complete list of our models and their final scores: Dataset In parallel with the event, the team also converted the Norwegian Parliamentary Speech Corpus (NPSC) to the NbAiLab/NPSC in 🤗 Dataset format and used that as the main source for training. Code We have released all the code developed during the event so that the Norwegian NLP community can build upon it when developing even better Norwegian ASR models. The finetuning of these models is not very computationally demanding. After following the instructions here, you should be able to train your own automatic speech recognition system in less than a day with an average GPU. Team The following people contributed to building this model: Rolv-Arild Braaten, Javier de la Rosa, and Freddy Wetjen. Training procedure To reproduce these results, we strongly recommend that you follow the instructions from 🤗 to train a simple Swedish model. When you have verified that you are able to do this, create a fresh new repo. You can then start by copying the files run.sh and runspeechrecognitionctc.py from our repo. Running these will create all the other necessary files, and should let you reproduce our results. With some tweaks to the hyperparameters, you might even be able to build an even better ASR. Good luck! Language Model As the scores indicate, adding even a simple 5-gram language will improve the results. 🤗 has provided another very nice blog explaining how to add a 5-gram language model to improve the ASR model. You can build this from your own corpus, for instance by extracting some suitable text from the Norwegian Colossal Corpus. You can also skip some of the steps in the guide, and copy the 5-gram model from this repo. Parameters The final model was run using these parameters
Summarised from the published model card. Read the full card on the HuggingFace links below.
Specifications
| Maker | NbAiLab |
|---|---|
| Type | Audio & music |
| Parameters (lead) | 963M |
| Variants | 1 |
| Runs with | transformers |
| Released | 2022-06-09 |
| Popularity | 970k downloads / month |
| Licence | Open weights |
How it works
Variants
Open weights ship in several sizes and precisions. One page, all the variants — pick the one that fits your GPU. VRAM figures are estimates from model size.
| Variant | Params | Precision | VRAM | Fits 16 GB | Weights |
|---|---|---|---|---|---|
| nb-wav2vec2-1b-nynorsk | 963M | BF16 | ~2.2 GB | ✓ | Weights ↗ |
Benchmarks
As published on the model card — the maker's own numbers, not measured by AxForge.
| Task | Dataset | Metric | Score |
|---|---|---|---|
| Automatic Speech Recognition | NPSC | Test (Nynorsk) WER | 0.113 |
| Automatic Speech Recognition | NPSC | Test (Nynorsk) CER | 0.04 |
Using it via the API
Once AxForge deploys nb-wav2vec2-nynorsk for you, it answers on the OpenAI-compatible API — the same base URL and keys as every other model. (nb-wav2vec2-nynorsk below is illustrative; you get the exact model name on deployment.)
$ curl -sS https://api.axforge.ai/v1/audio/transcriptions \ -H "Authorization: Bearer $AXFORGE_API_KEY" \ -F model="nb-wav2vec2-nynorsk" -F file=@audio.mp3
Licence
Open weights under apache-2.0 — commercial use is permitted. Deploy it on AxForge EU hardware on request. Read the licence ↗