So far we’ve extended transformers to one new modality at a time. True multimodal multimodal Describing models that combine more than one input modality, such as text with images or text with audio. defined in ch. 11 — open in glossary models combine two at once. We start with the most natural human interface after text: speech.
Speech-to-text
Talking is easier than typing for most people — and essential for accessibility — which is why assistants like Siri and Alexa keep spreading. The core task is automatic speech recognition automatic speech recognition (ASR) Converting spoken audio into text; wav2vec 2.0 is a transformer-based approach using unlabeled pretraining. defined in ch. 11 — open in glossary (ASR): turning spoken audio into text.
The wav2vec 2.0 family is a landmark. It pairs a CNN (to digest the raw waveform) with a transformer (to contextualize the audio), and — crucially — pretrains on huge amounts of unlabeled audio, so it needs only a few minutes of labeled speech to adapt to a new language:
Click a stage to see what it does. Data flows left → right; each stage transforms its input for the next.
Using it is the same familiar pipeline. Feeding it a clip from the SUPERB benchmark transcribes it perfectly:
from datasets import load_dataset
asr = pipeline("automatic-speech-recognition")
ds = load_dataset("superb", "asr", split="validation[:1]")
pred = asr(ds[0]["speech"])
# {'text': 'MISTER QUILTER IS THE APOSTLE OF THE MIDDLE CLASSES AND WE ARE
# GLAD TO WELCOME HIS GOSPEL'}
Note — dropping the labels entirely
Building a new language still needs a little labeled audio, which is scarce for low-resource languages. wav2vec-U removes even that: with clever clustering plus GAN training, it learns speech-to-text from independent unlabeled speech and unlabeled text — no aligned pairs at all — opening ASR to far more languages.Transformers can now “read” text and “hear” audio. Can they also see? Yes — the final frontier of this excerpt is vision-and-text models.
Check yourself: speech-to-text
1.What distinguishes a genuinely multimodal model from the single-modality extensions (ViT, TAPAS)?
2.What is automatic speech recognition (ASR)?
3.How is wav2vec 2.0 architected?
4.Why does wav2vec 2.0 need only a few minutes of labeled speech to adapt to a new language?
5.What does wav2vec-U achieve beyond wav2vec 2.0?