facebook / mms-lid-256

huggingface.co
Total runs: 41.0K
24-hour runs: 0
7-day runs: 20.0K
30-day runs: 5.3K
Model's Last Updated: June 13 2023
audio-classification

Introduction of mms-lid-256

Model Details of mms-lid-256

Massively Multilingual Speech (MMS) - Finetuned LID

This checkpoint is a model fine-tuned for speech language identification (LID) and part of Facebook's Massive Multilingual Speech project . This checkpoint is based on the Wav2Vec2 architecture and classifies raw audio input to a probability distribution over 256 output classes (each class representing a language). The checkpoint consists of 1 billion parameters and has been fine-tuned from facebook/mms-1b on 256 languages.

Table Of Content
Example

This MMS checkpoint can be used with Transformers to identify the spoken language of an audio. It can recognize the following 256 languages .

Let's look at a simple example.

First, we install transformers and some other libraries

pip install torch accelerate torchaudio datasets
pip install --upgrade transformers

Note : In order to use MMS you need to have at least transformers >= 4.30 installed. If the 4.30 version is not yet available on PyPI make sure to install transformers from source:

pip install git+https://github.com/huggingface/transformers.git

Next, we load a couple of audio samples via datasets . Make sure that the audio data is sampled to 16000 kHz.

from datasets import load_dataset, Audio

# English
stream_data = load_dataset("mozilla-foundation/common_voice_13_0", "en", split="test", streaming=True)
stream_data = stream_data.cast_column("audio", Audio(sampling_rate=16000))
en_sample = next(iter(stream_data))["audio"]["array"]

# Arabic
stream_data = load_dataset("mozilla-foundation/common_voice_13_0", "ar", split="test", streaming=True)
stream_data = stream_data.cast_column("audio", Audio(sampling_rate=16000))
ar_sample = next(iter(stream_data))["audio"]["array"]

Next, we load the model and processor

from transformers import Wav2Vec2ForSequenceClassification, AutoFeatureExtractor
import torch

model_id = "facebook/mms-lid-256"

processor = AutoFeatureExtractor.from_pretrained(model_id)
model = Wav2Vec2ForSequenceClassification.from_pretrained(model_id)

Now we process the audio data, pass the processed audio data to the model to classify it into a language, just like we usually do for Wav2Vec2 audio classification models such as ehcalabres/wav2vec2-lg-xlsr-en-speech-emotion-recognition

# English
inputs = processor(en_sample, sampling_rate=16_000, return_tensors="pt")

with torch.no_grad():
    outputs = model(**inputs).logits

lang_id = torch.argmax(outputs, dim=-1)[0].item()
detected_lang = model.config.id2label[lang_id]
# 'eng'

# Arabic
inputs = processor(ar_sample, sampling_rate=16_000, return_tensors="pt")

with torch.no_grad():
    outputs = model(**inputs).logits

lang_id = torch.argmax(outputs, dim=-1)[0].item()
detected_lang = model.config.id2label[lang_id]
# 'ara'

To see all the supported languages of a checkpoint, you can print out the language ids as follows:

processor.id2label.values()

For more details, about the architecture please have a look at the official docs .

Supported Languages

This model supports 256 languages. Unclick the following to toogle all supported languages of this checkpoint in ISO 639-3 code . You can find more details about the languages and their ISO 649-3 codes in the MMS Language Coverage Overview .

Click to toggle
  • ara
  • cmn
  • eng
  • spa
  • fra
  • mlg
  • swe
  • por
  • vie
  • ful
  • sun
  • asm
  • ben
  • zlm
  • kor
  • ind
  • hin
  • tuk
  • urd
  • aze
  • slv
  • mon
  • hau
  • tel
  • swh
  • bod
  • rus
  • tur
  • heb
  • mar
  • som
  • tgl
  • tat
  • tha
  • cat
  • ron
  • mal
  • bel
  • pol
  • yor
  • nld
  • bul
  • hat
  • afr
  • isl
  • amh
  • tam
  • hun
  • hrv
  • lit
  • cym
  • fas
  • mkd
  • ell
  • bos
  • deu
  • sqi
  • jav
  • kmr
  • nob
  • uzb
  • snd
  • lat
  • nya
  • grn
  • mya
  • orm
  • lin
  • hye
  • yue
  • pan
  • jpn
  • kaz
  • npi
  • kik
  • kat
  • guj
  • kan
  • tgk
  • ukr
  • ces
  • lav
  • bak
  • khm
  • fao
  • glg
  • ltz
  • xog
  • lao
  • mlt
  • sin
  • aka
  • sna
  • ita
  • srp
  • mri
  • nno
  • pus
  • eus
  • ory
  • lug
  • bre
  • luo
  • slk
  • ewe
  • fin
  • rif
  • dan
  • yid
  • yao
  • mos
  • hne
  • est
  • dyu
  • bam
  • uig
  • sck
  • tso
  • mup
  • ctg
  • ceb
  • war
  • bbc
  • vmw
  • sid
  • tpi
  • mag
  • san
  • kri
  • lon
  • kir
  • run
  • ubl
  • kin
  • rkt
  • xmm
  • tir
  • mai
  • nan
  • nyn
  • bcc
  • hak
  • suk
  • bem
  • rmy
  • awa
  • pcm
  • bgc
  • shn
  • oci
  • wol
  • bci
  • kab
  • ilo
  • bcl
  • haw
  • mad
  • nod
  • sag
  • sas
  • jam
  • mey
  • shi
  • hil
  • ace
  • kam
  • min
  • umb
  • hno
  • ban
  • syl
  • bxg
  • xho
  • mww
  • epo
  • tzm
  • zul
  • ibo
  • abk
  • guz
  • ckb
  • knc
  • nso
  • bho
  • dje
  • tiv
  • gle
  • lua
  • skr
  • bto
  • kea
  • glk
  • ast
  • sat
  • ktu
  • bhb
  • emk
  • kng
  • kmb
  • tsn
  • gom
  • ven
  • sco
  • glv
  • sot
  • sou
  • gno
  • nde
  • bjn
  • ina
  • fmu
  • esg
  • wes
  • pnb
  • phr
  • mui
  • bug
  • mrr
  • kas
  • lir
  • vah
  • ssw
  • rwr
  • pcc
  • hms
  • wbr
  • swv
  • mtr
  • haz
  • aii
  • bns
  • msi
  • wuu
  • hsn
  • bgp
  • tts
  • lmn
  • dcc
  • bew
  • bjj
  • ibb
  • tji
  • hoj
  • cpx
  • cdo
  • daq
  • mut
  • nap
  • czh
  • gdx
  • sdh
  • scn
  • mnp
  • bar
  • mzn
  • gsw
Model details
  • Developed by: Vineel Pratap et al.

  • Model type: Multi-Lingual Automatic Speech Recognition model

  • Language(s): 256 languages, see supported languages

  • License: CC-BY-NC 4.0 license

  • Num parameters : 1 billion

  • Audio sampling rate : 16,000 kHz

  • Cite as:

    @article{pratap2023mms,
      title={Scaling Speech Technology to 1,000+ Languages},
      author={Vineel Pratap and Andros Tjandra and Bowen Shi and Paden Tomasello and Arun Babu and Sayani Kundu and Ali Elkahky and Zhaoheng Ni and Apoorv Vyas and Maryam Fazel-Zarandi and Alexei Baevski and Yossi Adi and Xiaohui Zhang and Wei-Ning Hsu and Alexis Conneau and Michael Auli},
    journal={arXiv},
    year={2023}
    }
    
Additional Links

Runs of facebook mms-lid-256 on huggingface.co

41.0K
Total runs
0
24-hour runs
8.5K
3-day runs
20.0K
7-day runs
5.3K
30-day runs

More Information About mms-lid-256 huggingface.co Model

More mms-lid-256 license Visit here:

https://choosealicense.com/licenses/cc-by-nc-4.0

mms-lid-256 huggingface.co

mms-lid-256 huggingface.co is an AI model on huggingface.co that provides mms-lid-256's model effect (), which can be used instantly with this facebook mms-lid-256 model. huggingface.co supports a free trial of the mms-lid-256 model, and also provides paid use of the mms-lid-256. Support call mms-lid-256 model through api, including Node.js, Python, http.

mms-lid-256 huggingface.co Url

https://huggingface.co/facebook/mms-lid-256

facebook mms-lid-256 online free

mms-lid-256 huggingface.co is an online trial and call api platform, which integrates mms-lid-256's modeling effects, including api services, and provides a free online trial of mms-lid-256, you can try mms-lid-256 online for free by clicking the link below.

facebook mms-lid-256 online free url in huggingface.co:

https://huggingface.co/facebook/mms-lid-256

mms-lid-256 install

mms-lid-256 is an open source model from GitHub that offers a free installation service, and any user can find mms-lid-256 on GitHub to install. At the same time, huggingface.co provides the effect of mms-lid-256 install, users can directly use mms-lid-256 installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

mms-lid-256 install url in huggingface.co:

https://huggingface.co/facebook/mms-lid-256

Url of mms-lid-256

mms-lid-256 huggingface.co Url

Provider of mms-lid-256 huggingface.co

facebook
ORGANIZATIONS

Other API from facebook

huggingface.co

Total runs: 8.2M
Run Growth: 98.1K
Growth Rate: 1.20%
Updated:January 20 2022
huggingface.co

Total runs: 5.9M
Run Growth: -1.2M
Growth Rate: -20.72%
Updated:September 15 2023
huggingface.co

Total runs: 3.1M
Run Growth: 6.1K
Growth Rate: 0.19%
Updated:January 17 2024
huggingface.co

Total runs: 2.8M
Run Growth: -328.9K
Growth Rate: -11.88%
Updated:September 06 2023
huggingface.co

Total runs: 2.1M
Run Growth: -459.4K
Growth Rate: -22.27%
Updated:December 28 2021
huggingface.co

Total runs: 1.9M
Run Growth: -140.5K
Growth Rate: -7.22%
Updated:November 21 2025
huggingface.co

Total runs: 1.5M
Run Growth: -626.6K
Growth Rate: -41.05%
Updated:March 23 2023
huggingface.co

Total runs: 1.1M
Run Growth: -1.1M
Growth Rate: -96.11%
Updated:January 25 2024
huggingface.co

Total runs: 886.6K
Run Growth: 29.8K
Growth Rate: 3.35%
Updated:September 06 2023
huggingface.co

Total runs: 533.6K
Run Growth: 75.1K
Growth Rate: 14.03%
Updated:May 22 2023
huggingface.co

Total runs: 528.0K
Run Growth: 98.0K
Growth Rate: 18.56%
Updated:March 17 2025
huggingface.co

Total runs: 365.2K
Run Growth: 246.8K
Growth Rate: 66.28%
Updated:June 13 2023
huggingface.co

Total runs: 352.3K
Run Growth: -111.0K
Growth Rate: -30.74%
Updated:February 29 2024
huggingface.co

Total runs: 343.7K
Run Growth: -4.0K
Growth Rate: -1.14%
Updated:January 12 2024
huggingface.co

Total runs: 284.1K
Run Growth: -702
Growth Rate: -0.25%
Updated:June 15 2023
huggingface.co

Total runs: 272.1K
Run Growth: -2.5K
Growth Rate: -0.92%
Updated:January 12 2024
huggingface.co

Total runs: 249.0K
Run Growth: -31.7K
Growth Rate: -12.79%
Updated:November 17 2022
huggingface.co

Total runs: 239.3K
Run Growth: 49.7K
Growth Rate: 21.70%
Updated:February 12 2023
huggingface.co

Total runs: 236.9K
Run Growth: 14.3K
Growth Rate: 6.02%
Updated:July 23 2024
huggingface.co

Total runs: 188.0K
Run Growth: -132.9K
Growth Rate: -70.64%
Updated:September 06 2023
huggingface.co

Total runs: 179.4K
Run Growth: -132.5K
Growth Rate: -75.65%
Updated:September 15 2023
huggingface.co

Total runs: 147.0K
Run Growth: 29.2K
Growth Rate: 19.59%
Updated:June 03 2022
huggingface.co

Total runs: 122.7K
Run Growth: -17.5K
Growth Rate: -14.33%
Updated:November 16 2023
huggingface.co

Total runs: 111.1K
Run Growth: -61.7K
Growth Rate: -55.92%
Updated:May 22 2023
huggingface.co

Total runs: 99.3K
Run Growth: 51.1K
Growth Rate: 51.43%
Updated:March 28 2026
huggingface.co

Total runs: 95.0K
Run Growth: 52.0K
Growth Rate: 54.68%
Updated:December 09 2025
huggingface.co

Total runs: 82.1K
Run Growth: -113.2K
Growth Rate: -137.39%
Updated:July 25 2023
huggingface.co

Total runs: 67.2K
Run Growth: -32.0K
Growth Rate: -47.55%
Updated:September 15 2023
huggingface.co

Total runs: 57.7K
Run Growth: 48.2K
Growth Rate: 83.55%
Updated:March 27 2026
huggingface.co

Total runs: 53.3K
Run Growth: -127.3K
Growth Rate: -234.75%
Updated:September 06 2023
huggingface.co

Total runs: 51.5K
Run Growth: -106.7K
Growth Rate: -188.31%
Updated:September 01 2023
huggingface.co

Total runs: 47.7K
Run Growth: -44.5K
Growth Rate: -92.47%
Updated:February 12 2023
huggingface.co

Total runs: 42.0K
Run Growth: 27.2K
Growth Rate: 65.31%
Updated:October 16 2024
huggingface.co

Total runs: 40.1K
Run Growth: -3.1K
Growth Rate: -7.79%
Updated:September 05 2023
huggingface.co

Total runs: 38.2K
Run Growth: -23.9K
Growth Rate: -70.38%
Updated:January 25 2023
huggingface.co

Total runs: 37.7K
Run Growth: -8.7K
Growth Rate: -23.19%
Updated:January 21 2026
huggingface.co

Total runs: 37.0K
Run Growth: -8.2K
Growth Rate: -21.83%
Updated:March 13 2024