Skip to main content
This example demonstrates how to use multimodal models that can process images, audio, and text inputs together.

Overview

The multimodal example shows how to:
  • Process images and audio inputs
  • Use the multimodal processor
  • Combine multiple input modalities
  • Apply chat templates for multimodal conversations
  • Stream generated responses

Complete Example

Key Features

Multimodal Processor

Create a processor to handle multiple input modalities:

Processing Images and Audio

The processor combines text, images, and audio:

Dynamic Content Construction

Construct user content based on available inputs:

Usage Examples

Model Types

The example supports different multimodal model architectures:
  • Vision models: Process images with text
  • Audio models: Process audio with text
  • Multimodal models: Process combinations of images, audio, and text

Command-Line Arguments

Next Steps