Skip to main content
Glama
Swih

Mistral MCP — Document Extraction

by Swih

Mistral multimodal chat (vision)

mistral_vision
Read-only

Send text and images to a vision-capable Mistral model for chat completion. Use it to analyze images or extract details from visual content.

Instructions

Chat completion with multimodal input: text + image_url parts.

Requires a vision-capable model. Accepted:

  • pixtral-large-latest

  • pixtral-12b-latest

  • mistral-large-latest

  • mistral-medium-latest

  • mistral-small-latest

Each message's content is either a plain string (pure text) or an array of parts { type: 'text', text } / { type: 'image_url', imageUrl }. The image URL can be an https URL or a data: URI base64 payload.

Returns the assistant text + token usage. For non-visual requests, prefer mistral_chat.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
seedNoRandom seed for deterministic sampling. Maps to Mistral's `random_seed`.
modelNoVision-capable Mistral model. Default: pixtral-large-latest.
top_pNoNucleus sampling probability mass: 0.1 considers tokens in the top 10% of probability mass. Prefer adjusting this or temperature, not both.
messagesYesChat messages. Pure-text requests are accepted, but this tool is intended primarily for multimodal prompts containing image parts.
max_tokensNoMaximum number of tokens to generate. Input tokens plus this limit must fit within the model's context length.
temperatureNoSampling temperature: higher values make output more random; lower values make it more focused. Prefer adjusting this or top_p, not both.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYes
modelYes
usageNo
finish_reasonNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed16 schema fields changedv0.8.3
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / max_tokens / description
      Added value: +"Maximum number of tokens to generate. Input tokens plus this limit must fit within the model's context length."
    • addedInput schema / properties / max_tokens / maximum
      Added value: +9007199254740991
    • removedInput schema / properties / messages / items / additionalProperties
      Removed value: -false
    • changedInput schema / properties / messages / items / properties / content / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "items": {
      -      "anyOf": [
      -        {
      -          "additionalProperties": false,
      -          "properties": {
      -            "text": {
      -              "type": "string"
      -            },
      -            "type": {
      -              "const": "text",
      -              "type": "string"
      -            }
      -          },
      -          "required": [
      -            "type",
      -            "text"
      -          ],
      -          "type": "object"
      -        },
      -        {
      -          "additionalProperties": false,
      -          "properties": {
      -            "imageUrl": {
      -              "anyOf": [
      -                {
      -                  "description": "https URL or data:image/...;base64,... payload",
      -                  "type": "string"
      -                },
      -                {
      -                  "additionalProperties": false,
      -                  "properties": {
      -                    "detail": {
      -                      "enum": [
      -                        "auto",
      -                        "low",
      -                        "high"
      -                      ],
      -                      "type": "string"
      -                    },
      -                    "url": {
      -                      "type": "string"
      -                    }
      -                  },
      -                  "required": [
      -                    "url"
      -                  ],
      -                  "type": "object"
      -                }
      -              ]
      -            },
      -            "type": {
      -              "const": "image_url",
      -              "type": "string"
      -            }
      -          },
      -          "required": [
      -            "type",
      -            "imageUrl"
      -          ],
      -          "type": "object"
      -        },
      -        {
      -          "additionalProperties": false,
      -          "properties": {
      -            "documentName": {
      -              "type": "string"
      -            },
      -            "documentUrl": {
      -              "type": "string"
      -            },
      -            "type": {
      -              "const": "document_url",
      -              "type": "string"
      -            }
      -          },
      -          "required": [
      -            "type",
      -            "documentUrl"
      -          ],
      -          "type": "object"
      -        }
      -      ]
      -    },
      -    "minItems": 1,
      -    "type": "array"
      -  }
      -]New value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "items": {
      +      "anyOf": [
      +        {
      +          "properties": {
      +            "text": {
      +              "description": "Text to include in the message.",
      +              "type": "string"
      +            },
      +            "type": {
      +              "const": "text",
      +              "description": "Identifies a text content part.",
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "type",
      +            "text"
      +          ],
      +          "type": "object"
      +        },
      +        {
      +          "properties": {
      +            "imageUrl": {
      +              "anyOf": [
      +                {
      +                  "description": "https URL or data:image/...;base64,... payload",
      +                  "type": "string"
      +                },
      +                {
      +                  "properties": {
      +                    "detail": {
      +                      "description": "Image detail hint: automatic, low, or high.",
      +                      "enum": [
      +                        "auto",
      +                        "low",
      +                        "high"
      +                      ],
      +                      "type": "string"
      +                    },
      +                    "url": {
      +                      "description": "HTTPS URL or data:image/...;base64,... payload.",
      +                      "type": "string"
      +                    }
      +                  },
      +                  "required": [
      +                    "url"
      +                  ],
      +                  "type": "object"
      +                }
      +              ],
      +              "description": "Image source as a URL or base64 data URI, optionally with a detail hint."
      +            },
      +            "type": {
      +              "const": "image_url",
      +              "description": "Identifies an image content part.",
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "type",
      +            "imageUrl"
      +          ],
      +          "type": "object"
      +        },
      +        {
      +          "properties": {
      +            "documentName": {
      +              "description": "Filename of the referenced document.",
      +              "type": "string"
      +            },
      +            "documentUrl": {
      +              "description": "URL of the PDF or document to include in the message.",
      +              "type": "string"
      +            },
      +            "type": {
      +              "const": "document_url",
      +              "description": "Identifies a document content part.",
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "type",
      +            "documentUrl"
      +          ],
      +          "type": "object"
      +        }
      +      ]
      +    },
      +    "minItems": 1,
      +    "type": "array"
      +  }
      +]
    • addedInput schema / properties / messages / items / properties / content / description
      Added value: +"Message text or an ordered list of text, image, and document content parts."
    • addedInput schema / properties / messages / items / properties / role / description
      Added value: +"Message author: system for instructions, user for requests, or assistant for prior replies."
    • removedInput schema / properties / model / enum
      Removed value: -[
      -  "pixtral-large-latest",
      -  "pixtral-12b-latest",
      -  "mistral-large-latest",
      -  "mistral-medium-latest",
      -  "mistral-small-latest"
      -]
    • addedInput schema / properties / model / maxLength
      Added value: +200
    • addedInput schema / properties / model / minLength
      Added value: +1
    • addedInput schema / properties / seed / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / seed / minimum
      Added value: +-9007199254740991
    • addedInput schema / properties / temperature / description
      Added value: +"Sampling temperature: higher values make output more random; lower values make it more focused. Prefer adjusting this or top_p, not both."
    • addedInput schema / properties / top_p / description
      Added value: +"Nucleus sampling probability mass: 0.1 considers tokens in the top 10% of probability mass. Prefer adjusting this or temperature, not both."
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed1 schema field changedv0.7.0
    • addedInput schema / properties / seed
      Added value: +{
      +  "description": "Random seed for deterministic sampling. Maps to Mistral's `random_seed`.",
      +  "type": "integer"
      +}
  3. First observedv0.4.0

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true and destructiveHint=false, so safety is covered. The description adds useful non-structural context: the vision-model requirement, accepted model IDs, and that it returns assistant text plus token usage. It does not cover cost/latency or image size limits, so not a full 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core purpose, then model list, then payload format, then routing guidance. The model enumeration is slightly verbose but each line is actionable and the structure is scannable.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Output schema exists so return values needn't be explained, and the description still notes the assistant-text + token-usage return. Model constraints, payload shapes, and sibling routing are all present; nothing needed to call this correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3, but the description goes beyond by enumerating the accepted vision model IDs (the schema only says 'Vision-capable Mistral model') and clarifying the content part shapes and image URL formats.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Chat completion with multimodal input: text + image_url parts') and explicitly differentiates from the sibling mistral_chat for non-visual requests. An agent can distinguish this from mistral_ocr and mistral_chat without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes usage: 'Requires a vision-capable model' with an enumerated accepted-model list, and states 'For non-visual requests, prefer mistral_chat.' This names both the condition to use it and the alternative to use otherwise.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.