Overview
Vision models can analyze images, screenshots, diagrams, and more.
Supported models
Vision works on any model whose input_modalities include image. Filter
GET /v1/models to find them.
Basic Usage
response = client.chat.completions.create(
model="qwen/qwen3-vl-30b-a3b-instruct",
messages=[{
"role": "user",
"content": [
{
"type": "text",
"text": "What's in this image?"
},
{
"type": "image_url",
"image_url": {
"url": "https://example.com/image.jpg"
}
}
]
}]
)
Base64 Images
import base64
def encode_image(image_path):
with open(image_path, "rb") as image_file:
return base64.b64encode(image_file.read()).decode('utf-8')
base64_image = encode_image("photo.jpg")
response = client.chat.completions.create(
model="qwen/qwen3-vl-30b-a3b-instruct",
messages=[{
"role": "user",
"content": [
{"type": "text", "text": "Describe this image"},
{
"type": "image_url",
"image_url": {
"url": f"data:image/jpeg;base64,{base64_image}"
}
}
]
}]
)
Multiple Images
response = client.chat.completions.create(
model="qwen/qwen3-vl-30b-a3b-instruct",
messages=[{
"role": "user",
"content": [
{"type": "text", "text": "Compare these images"},
{"type": "image_url", "image_url": {"url": "https://example.com/1.jpg"}},
{"type": "image_url", "image_url": {"url": "https://example.com/2.jpg"}}
]
}]
)
Use Cases
- Medical image analysis
- Document OCR
- Chart interpretation
- Product inspection
- Satellite imagery
qwen/qwen3-vl-30b-a3b-instruct can be served by a verified upstream provider for confidential image
processing. Confirm a confidential response per request from the receipt.