Skip to main content

Vision (Image Analysis)

Vision-capable models can analyze images alongside text, enabling use cases like image description, visual reasoning, document extraction, and more. Images are passed as part of the messages array using the OpenAI-compatible multimodal format.
The Morpheus Inference API is fully OpenAI-compatible — vision works exactly like OpenAI’s multimodal API. If you’ve used GPT-4 Vision before, you already know how to use this.

Supported Models

How It Works

Instead of sending a plain text string as the message content, you send an array of content parts — mixing text and images in a single message:
Images can be provided as:
  • URL — A direct link to an image (https://...)
  • Base64 — Inline image data (data:image/jpeg;base64,...)

Basic Example

Send an image URL for analysis:

Using Base64 Images

For local images or when you want to avoid external URLs, encode the image as base64:

Multiple Images

You can send multiple images in a single message for comparison or multi-image analysis:

Use Cases

Ask the model to describe what it sees in an image — useful for accessibility, content moderation, or cataloging.
Extract structured data from photos of documents, receipts, or invoices.
kimi-k2.5 excels at solving math problems from images and interpreting diagrams.
Have the model read and explain code from screenshots.

Tips

Choosing a model: Use kimi-k2.6, kimi-k2.5, or gemma-4-31b for complex visual reasoning, math, and multi-image analysis. Use gemma-4-26b-a4b or qwen35-9b for fast, efficient image tasks. Use mistral-31-24b when you need quick responses for simpler image tasks.
Supported formats: JPEG, PNG, GIF, and WebP images are supported. For base64, include the appropriate MIME type in the data URI (e.g., data:image/png;base64,...).

Next Steps

Available Models

See all models and their capabilities.

Chat Completions API

Full API reference for chat completions.

Tool Calling Guide

Let models invoke tools and external APIs.

Quickstart

Get started with your first API call.