What Is Multimodal AI?
Multimodal AI processes or generates information in more than one form, such as text, images, audio or video. A model might combine a photo with a written question to produce a text answer, or use a written description to generate an image or video. The modalities it accepts as input and the modalities it can produce as output depend on its architecture and the interface you use.
A modality is a form in which information is represented. A repair ticket is a sequence of text tokens; a photograph of the faulty component is a grid of pixels; a spoken report is a waveform; and a video clip is a time-ordered sequence of frames that may include an audio track. These sources can carry complementary evidence. A photo may show that an indicator is amber, while an audio recording captures the technician saying the colour changed after startup.
In practice, one product might pass images and words to a shared model, while another routes speech through a transcription model, sends the transcript to a large language model, and reads the answer back using text-to-speech. Both products offer a multimodal experience. Their capabilities differ: the transcript-based system cannot hear the background fan unless an audio component analyses the sound and passes that information along. The useful engineering question is: What evidence reaches the component making the decision?
What Can Multimodal AI Take In and Generate?
Read a model specification in two directions. A model that accepts an image and returns a caption supports image understanding with text output. An image generator maps a prompt to pixels, but that capability alone does not make it a visual question-answering system. “Understand” here describes observable performance on tasks such as captioning, locating objects or answering questions about evidence. It does not imply that every answer is grounded in the input.

| Modality | Typical input or understanding tasks | Typical generation tasks | Representative models or products |
|---|---|---|---|
| Text | Extract fields, answer questions, summarise documents | Write an explanation of quantum computing for a first-year student | GPT-4, Llama, Gemini and Claude families |
| Image | Caption a photo, read a label, locate an object when the model supports spatial grounding | Generate an image of a mountain range or edit a specified region of a photo | Vision-capable Gemini and Claude models for understanding; DALL-E, Stable Diffusion and Midjourney for generation |
| Audio | Transcribe speech or identify sounds with a suitable audio model | Generate spoken narration or a short music clip | Whisper for transcription; ElevenLabs products for speech generation; MusicGen for music |
| Video | Caption a clip, describe an event sequence or answer a question about selected frames | Generate a clip from text or an image, or edit a clip with a supported video tool | Video-capable Gemini models for understanding; Sora, Runway and Pika as examples of generation systems |
Models in the GPT-4o and Gemini families illustrate why you should verify capabilities at the endpoint level: a family name alone does not tell you whether a specific API accepts a video file, receives its audio, or can return spoken output. Also check the granularity of the response. A caption names what appears in an image; an object detector returns localised predictions, typically with coordinates. If a downstream application needs bounding boxes, evaluate those coordinates directly.
How Do Multimodal Models Combine Text, Images and Audio?
A model first converts each input into representations it can compute on. A text tokenizer maps a string to token IDs, and a lookup table turns those IDs into vectors. A vision encoder commonly divides an image into patches and maps those patches into contextualised vectors. An audio encoder might start from a log-mel spectrogram, a time-by-frequency representation of signal energy. A video encoder may work with sampled frames or short groups of frames and include temporal position information. These embeddings are numerical features; they do not need to correspond to human-readable words.

In one common vision-language design, a learned projector maps the vision encoder's features into the language model's hidden dimension. The projected features occupy dedicated positions in a sequence alongside text embeddings. When generating an answer, the decoder can attend to both the question and the preceding visual positions. Another design keeps the visual features in a separate memory and uses cross-attention, with decoder states as queries and visual features as keys and values. Read the chapter on the attention mechanism for the query, key and value mechanics.
Matching dimensions alone does not align the modalities. Training on paired examples teaches the system what the features mean for a task. In caption training, for example, the decoder predicts each next caption token conditioned on the image and earlier caption tokens. Minimising -sum_t log p(y_t | y_<t, image) sends a learning signal to the trainable components, which may include the projector, the decoder or the vision encoder. Later instruction training can teach the model to answer questions rather than always produce captions. Contrastive training serves a different purpose: it can bring matching image and text embeddings closer for retrieval without training a caption generator.
Fusion can also happen after separate models make predictions. A lecture search system might retrieve transcript passages and slide images independently, then combine ranked results by timestamp. That pipeline is easier to inspect than a single model taking the entire recording. Its failure mode is equally concrete: if transcription drops a symbol and slide retrieval misses the matching frame, the final model never receives the evidence needed to recover it.
How Does AI Generate Text, Images, Audio and Video?
Text: predict the next token
An autoregressive language model produces logits over a vocabulary at each step. A decoding rule either selects a token directly or transforms the logits into probabilities and samples. The selected token becomes part of the next step's input. Even if a photo conditions the answer, this decoder still emits text token IDs rather than pixels. The tokenization chapter explains why token count differs from word count.
Images: generate pixels through a learned representation
Modern image generators can use diffusion, related flow-based methods or autoregressive image token generation. In a latent diffusion system, a text encoder represents the prompt, and a denoising network repeatedly updates a noisy spatial latent conditioned on that representation. A learned image decoder converts the final latent into pixels. For editing, a system can also condition on a source image and a mask indicating the intended region. Exact preservation of unmasked pixels may require an explicit compositing step, depending on the pipeline. The diffusion models chapter explains the relationship between training with noise and sampling from it.
Audio: model timing, pitch and waveform detail
Speech generation and speech recognition solve different problems. A text-to-speech model can predict acoustic features from text and pass them to a vocoder that synthesises the waveform. Another design predicts discrete audio codec tokens that a codec decoder converts into sound. Text controls what is said, but it normally leaves timing, pitch and speaker characteristics underspecified. Music generation has different requirements, including rhythm and longer-range structure. Whisper, by contrast, predicts text from audio and is not a synthesiser.
Video: preserve appearance and motion over time
Video generation can operate on spatiotemporal latents, which represent content across both space and time. A generator can condition on a text prompt, a reference image or an existing clip, depending on its design. Generating each frame independently often produces flicker or changes an object's appearance. Joint temporal modelling allows features at different times to interact, although it can still produce inconsistent motion or object identity. A generated video need not include sound, and a video understanding endpoint may inspect frames without processing the soundtrack.
Worked Example: How Many Tokens Does a Video Add?
Suppose you want to ask, “Did the machine's indicator change from green to amber?” Assume a vision-language model takes frames resized to 336 x 336 pixels. It uses non-overlapping 14 x 14 patches and merges each 2 x 2 group of patch features into one visual position before fusion. These are illustrative design choices rather than a specification for a named model.
- Patch grid:
336 / 14 = 24patches per side, giving24 x 24 = 576patches per frame. - After merging:
12 x 12 = 144visual positions per frame. - One frame: with 80 text positions, including instructions and the question, the simplified input length is
144 + 80 = 224. - Eight frames: the same question now gives
8 x 144 + 80 = 1,232positions, before adding any frame separators or other model-specific tokens.
In a decoder that performs dense self-attention over the combined sequence, attention work during the initial prompt pass scales approximately with the square of its length. Holding the model dimensions fixed, the attention-work ratio here is about (1,232 / 224)^2 = 30.25. That is a ratio for the attention term, not a prediction of end-to-end latency, API charges or memory. Image encoding, projection, attention kernels, caching and output length also affect the measured cost.
Sampling decisions matter as much as token counts. If the amber light stays on for 200 milliseconds and you sample at one frame per second, the frames could all miss it. In that case, a better prompt cannot recover the event. Increase sampling around the relevant interval, retain frame timestamps, and allow the system to say that the available frames do not establish a change.
How Do You Run a Vision-Language Model in Python?
This exercise sends a synthetic indicator panel and a question to an open-weight vision-language model. Install a recent version of transformers, plus torch and pillow, in a virtual environment. The first run downloads the model files. Use a GPU if available; CPU inference is possible with sufficient RAM but can be slow. The chat template inserts the image placeholder, and the processor converts the image and text into the tensors expected by this model.
from PIL import Image, ImageDraw
import torch
from transformers import AutoProcessor, Qwen2_5_VLForConditionalGeneration
model_id = "Qwen/Qwen2.5-VL-3B-Instruct"
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
if device.type == "cuda":
dtype = torch.bfloat16 if torch.cuda.is_bf16_supported() else torch.float16
else:
dtype = torch.float32
processor = AutoProcessor.from_pretrained(model_id)
model = Qwen2_5_VLForConditionalGeneration.from_pretrained(
model_id, dtype=dtype
).to(device).eval()
question = (
"What colour is the circular indicator in the image? "
"Answer with one colour word."
)
messages = [{
"role": "user",
"content": [{"type": "image"}, {"type": "text", "text": question}],
}]
prompt = processor.apply_chat_template(
messages, tokenize=False, add_generation_prompt=True
)
for expected, rgb in [("green", (0, 220, 70)), ("orange", (255, 140, 0))]:
panel = Image.new("RGB", (336, 336), (35, 35, 35))
ImageDraw.Draw(panel).ellipse((84, 84, 252, 252), fill=rgb)
batch = processor(
text=[prompt], images=[panel], return_tensors="pt"
).to(device)
with torch.inference_mode():
generated = model.generate(**batch, max_new_tokens=12, do_sample=False)
# Decoder-only generation returns the input prefix plus new tokens.
prefix_length = batch["input_ids"].shape[1]
new_ids = generated[:, prefix_length:]
answer = processor.batch_decode(new_ids, skip_special_tokens=True)[0].strip()
print(f"Expected: {expected}; model answer: {answer}")
The expected labels come from the image construction code, not from a model run. Inspect the responses: “amber” for the orange panel could be acceptable in a maintenance tool and a failure in an application that expects an exact enum. Define the label contract before scoring. Disabling sampling removes random token selection, but it does not validate the answer. The model here accepts an image and emits text; it does not generate the panel. Pillow creates it so that you can change visual evidence while holding the question constant.
How Do You Evaluate Multimodal AI?
Start with a task whose answer can be checked independently. For a lecture assistant, annotate a question, the supporting slide or audio interval, and the expected answer. Score answer correctness separately from grounding: a correct answer with the wrong timestamp is a failure if learners need to jump to the source. Use paired test cases like the colour exercise, where changing one visual feature should change the answer. Add blurry slides, quiet audio and clips with missing evidence, and check whether the model expresses uncertainty instead of inventing details.
Pick metrics that match the output. For transcription, word error rate is (S + D + I) / N, where S, D and I are word substitutions, deletions and insertions, and N is the number of reference words. If a 20-word reference has two substitutions and one deletion, the word error rate is 15 percent. Document how you normalise punctuation, numerals and mixed-language speech. For image or video generation, assess prompt adherence and visual quality separately. For video, also inspect temporal consistency: a plausible paused frame can hide flicker or an object that disappears mid-shot.
Measure latency on inputs that resemble real requests, recording media duration, sampled frame count and output length. Report results by condition, such as clean versus noisy recordings, because an overall average can hide a systematic failure. Before sending recordings or screenshots to a service, check what sensitive material they contain, whether you have permission to process it, and how the service retains inputs. The chapter on LLM hallucination, evaluation and safety extends this testing approach to the reliability of generated answers.
Key Takeaways
- Check input modalities and output modalities separately for every model and endpoint.
- Encoders convert different kinds of media into features. Projectors and attention layers can make those features available to a shared decoder.
- Text, image, audio and video generation use output representations suited to their medium.
- Image resolution and frame sampling affect both compute and what evidence the model sees.
- A modular pipeline can be easier to debug, but a text-only intermediate representation can discard useful audio or visual information.
- Evaluate correctness, grounding and operational cost separately on representative media.
Frequently Asked Questions
Does multimodal AI always produce more than one type of output?
No. A vision-language model can accept an image and a text question while producing only text. A text-to-image system accepts words and produces an image. Either system crosses modalities. To decide whether it fits your application, check the supported input types and the output formats exposed by the specific endpoint.
Can a multimodal AI model watch and listen to a video at the same time?
Some systems process both frames and the audio track. Others discard the track, or transcribe it and use only the resulting text. Check the interface documentation and test with a clip where the spoken content contradicts the on-screen caption. The answer should show which source the model is using.
Is OCR the same as multimodal AI?
Optical character recognition is the specific task of converting written or printed characters in an image into machine-readable text. A multimodal assistant may perform that task and also answer questions about layout, images or charts. If you need exact fields from a document, compare both approaches against labelled examples before choosing.
What is the difference between a multimodal AI model and a multimodal pipeline?
A multimodal model can learn to combine representations from different modalities inside its architecture. A pipeline coordinates separate components, such as a speech recogniser, a language model and a speech synthesiser. A product may use both designs. Trace the intermediate representations to see which information survives each stage and where errors enter.
Why does multimodal AI sometimes miss obvious details?
Preprocessing can remove evidence by resizing an image, merging patches, sampling too few frames or reducing audio to a transcript. Even when the evidence survives, the decoder may favour a common answer it learned during training. Test small input changes with known answers to distinguish missing evidence from errors in interpreting it.