/ Модель

Характеристики

Параметры
403 млн
Лицензия
Apache 2.0
Архитектура
wav2vec2-bert · dense
Базовая модель
w2v-bert-2.0
Опубликована
28 июл 2026

w2v-bert-2.0-lang-id-lug-sna-lin-best

Классификация текстаТекст → label

Дообученная модель классифицирует короткие аудиофрагменты как речь на лугандийском, шона или лингала для маршрутизации в подходящую систему распознавания речи.

11скачиваний за 30 дней0лайковвеса обновлены10 авг 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Модель keystats/w2v-bert-2.0-lang-id-lug-sna-lin-best распознаёт, на каком из трёх языков — лугандийском, шона или лингала — говорят в коротком аудиофрагменте. Это дообученная для классификации речи версия facebook/w2v-bert-2.0 с классификационной головой; размер модели — 402,7 млн параметров.

Модель предназначена для предварительной маршрутизации аудио к подходящей языковой системе распознавания речи. Она обучена на данных Google WaxalNLP и дополнительных аудиоданных из сообществ, призванных расширить охват условий записи и говорящих. В тестах на разбиениях WAXAL указана точность около 99,9%; эти результаты не гарантируют такую же точность на других данных.

Классификатор всегда выбирает один из трёх поддерживаемых языков: он не расшифровывает речь, не распознаёт другие языки и не выделяет неречевые или неизвестные аудио как отдельный класс. Модель распространяется по лицензии Apache-2.0.

Сценарии применения

  • Определение лугандийского, шона или лингала в короткой аудиозаписи
  • Маршрутизация аудио к языковой модели распознавания речи
  • Автоматическая сортировка голосовых записей по трём поддерживаемым языкам

Ограничения

Модель всегда относит аудио к одному из трёх языков, даже если там звучит другой язык или неречь; отдельного класса для неизвестного языка нет. Она не транскрибирует речь, а точность на данных вне распределения WAXAL не гарантируется.

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

w2v-bert-2.0-lang-id-lug-sna-lin-best

A spoken language identification (LID) model that classifies short audio clips into one of three languages — Luganda, Shona, or Lingala — fine-tuned from facebook/w2v-bert-2.0 with a sequence classification head. This is an improved variant of keystats/w2v-bert-2.0-lang-id-lug-sna-lin — see Difference from the base LID model below.

Model description

facebook/w2v-bert-2.0 — a large-scale, multilingual self-supervised speech encoder pretrained with a BERT-style masked prediction objective — is used as the backbone, with a from-scratch audio classification head fine-tuned to predict which of the three languages a given audio clip is spoken in. Like the base LID model, this model does not transcribe speech — it only outputs a language label.

Difference from the base LID model

The base w2v-bert-2.0-lang-id-lug-sna-lin model was trained on WAXAL data only. This -best variant adds additional community-sourced audio datasets for each language on top of the WAXAL training pool, specifically to push the model beyond WAXAL's own acoustic conditions — the goal being a classifier that generalizes to audio drawn from outside the WAXAL distribution, not just data that looks like WAXAL.

Training data

SourceRole
google/WaxalNLP — Luganda, Shona, Lingala configstrain splits from all three language configs pooled into training (each clip labeled with its language); validation splits pooled together and held out for monitoring
Additional community-sourced audio datasets (per language)Pooled into training alongside WAXAL, to broaden acoustic/speaker coverage beyond WAXAL alone

Only WAXAL's own validation/test splits were used for evaluation — the added community data was used for training only.

Training procedure

  • Base model: facebook/w2v-bert-2.0
  • Architecture: Wav2Vec2BertForSequenceClassification (audio classification head over the pretrained encoder), 3 output classes (Luganda, Shona, Lingala)
  • Sample rate: 16 kHz mono
  • Hardware: single RTX PRO 6000

Evaluation results

This model scored ~99.9% accuracy on both the WAXAL validation and test splits — effectively perfect, with only 1–2 misclassified clips out of the full evaluation sets (the exact count varied by a couple of clips between validation and test).

Note: this is marginally lower than the base LID model's 100% on WAXAL's own splits, which is expected — training on a broader mix of data (beyond WAXAL alone) trades a hair of in-domain accuracy for better generalization to audio outside WAXAL's specific recording conditions. As always, treat these in-domain WAXAL numbers as an upper bound rather than a guarantee of out-of-domain performance, though the added training data here is specifically meant to narrow that gap.

How to use

import torch
import librosa
from transformers import Wav2Vec2BertForSequenceClassification, Wav2Vec2BertProcessor

MODEL_ID = "keystats/w2v-bert-2.0-lang-id-lug-sna-lin-best"
DEVICE = "cuda" if torch.cuda.is_available() else "cpu"

processor = Wav2Vec2BertProcessor.from_pretrained(MODEL_ID)
model = Wav2Vec2BertForSequenceClassification.from_pretrained(MODEL_ID).to(DEVICE).eval()

audio_array, sr = librosa.load("path/to/audio.wav", sr=16000, mono=True)
inputs = processor(audio_array, sampling_rate=16000, return_tensors="pt")
with torch.no_grad():
    logits = model(input_features=inputs.input_features.to(DEVICE)).logits

predicted_id = torch.argmax(logits, dim=-1).item()
predicted_label = model.config.id2label[predicted_id]

print(predicted_label)  # "luganda", "shona", or "lingala"

Intended uses & limitations

  • Intended for identifying which of Luganda, Shona, or Lingala is being spoken in a given audio clip — useful as a pre-processing step to route audio to the correct language-specific ASR model (e.g. the Luganda -main-best checkpoints in this collection).
  • Trained with additional data beyond WAXAL specifically to generalize better to new, out-of-domain audio than the WAXAL-only base LID model — a better default choice if your audio doesn't closely match WAXAL's own recording conditions.
  • This is a closed-set 3-way classifier: it will always output one of the three trained languages, even for audio in a different language or non-speech audio. It has no "none of the above" / out-of-domain detection.
  • Not a general-purpose language ID model — it only distinguishes between these three specific languages, not the full range of African languages or languages generally.

Citation

If you use this model, please cite the training/fine-tuning work and the underlying dataset:

@misc{keystats_wav2vec2bert_langid_lug_sna_lin_best,
  title={w2v-bert-2.0-lang-id-lug-sna-lin-best: A Luganda/Shona/Lingala spoken language identification model fine-tuned from facebook/w2v-bert-2.0 with additional data for generalization},
  author={keystats},
  year={2026},
  howpublished={\url{https://huggingface.co/keystats/w2v-bert-2.0-lang-id-lug-sna-lin-best}}
}

@misc{waxal,
  title={WAXAL: A Multilingual African Speech Dataset},
  author={Google},
  howpublished={\url{https://huggingface.co/datasets/google/WaxalNLP}}
}

@inproceedings{w2vbert2,
  title={Seamless: Multilingual Expressive and Streaming Speech Translation},
  author={Seamless Communication and others},
  year={2023},
  howpublished={\url{https://huggingface.co/facebook/w2v-bert-2.0}}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · text-classification

Нельзя запустить

Для архитектуры wav2vec2-bert нет загрузчика под задачу text-classification.

Класс архитектуры
Wav2Vec2BertForSequenceClassification
Ревизия весов
cc01ec4

0 моделей