Vision, Audio, and Generative Media
Modalities require different representations
Text uses tokenization. Vision systems may divide an image into patches and encode them as vectors. Audio systems may process waveforms or time-frequency features such as spectrograms. A multimodal model connects representations across two or more forms of data.
An image-text system can learn to align captions with images, allowing text-based image retrieval. A vision-language assistant may process image representations alongside text instructions. Architecture and training vary; do not assume every model simply converts every image into a hidden caption first.
flowchart TD A[Image or audio input] --> B[Preprocess and encode] C[Text request] --> D[Text representation] B --> E[Multimodal processing] D --> E E --> F[Text, labels, or generated media] F --> G[Task-specific validation]
Vision example: read a receipt
A receipt application may need text recognition, item grouping, amounts, currency, and a total. A system can read an amount correctly yet attach it to the wrong item. Validate arithmetic with code and preserve the original evidence region. Blurry images, unusual layouts, small text, and handwritten notes need explicit tests.
Do not use a vision model's apparent confidence as proof of identity or reliable measurement. Tasks such as counting many small objects or reading exact coordinates can require specialized pipelines and calibrated validation.
Audio and speech
Automatic speech recognition transcribes speech; text-to-speech produces audio. Diarization estimates which speaker spoke when. These are different tasks. Word error rate compares substitutions, deletions, and insertions against a reference, but a single misheard account number can be more consequential than several harmless word errors.
Streaming speech systems need to manage partial transcripts that may later be revised. Accents, noise, overlapping speech, and language switching deserve evaluation.
Image generation and diffusion
Diffusion models commonly learn to reverse a noising process; generation starts from noise and iteratively refines it, often under text conditioning. Latent diffusion performs much of this process in a compressed representation. Autoregressive and other generative approaches also exist. “Generative AI” is therefore broader than next-token text generation.
Checkpoint with answers
Does an OCR result prove the total is correct? No. Check layout interpretation and arithmetic as well as recognized characters.
Why can text inside an image be a security concern? It can contain malicious instructions that become part of the model's interpreted input, creating another prompt-injection surface.
Exercise: A speech transcript changes “15” to “50.” What should protect a payment workflow? Answer: verify the structured amount with the user before the consequential action, rather than silently trusting transcription.