mistral-medium

Mistral AI's medium-sized LLM. Supports a context window of 32k tokens and outperforms Mixtral 8x7B and Mistral-7b on almost all benchmarks.

Input

Prompt:

Press Ctrl + Enter to submit
The maximum number of tokens to generate. Shorter token lengths will provide faster performance.
A decimal number that determines the degree of randomness in the response
An alternative to sampling with temperature, where the model considers the results of the tokens with top_p probability mass.
A system prompt sets the behavior and context for an AI assistant in a conversation, such as modifying its personality.

Output

Submit a prompt for a response.

Notes

Mistral Medium Model

Mistral AI's medium-sized model. Supports a context window of 32k tokens (around 24000 words) and is stronger than Mixtral 8x7B and Mistral-7b on benchmarks across the board.

Run Mistral Medium with an API

You can run the Mistral Medium Instruct Model using Clarifai’s Python SDK.

Check out the Code Below:

Export your PAT as an environment variable. Then, import and initialize the API Client.

export CLARIFAI_PAT={your personal access token}
from clarifai.client.model import Model

prompt = "What’s the future of AI?"

inference_params = dict(temperature=0.7, max_tokens=200,
top_p= 0.95, system_prompt = "You are a helpful assistant.")

# Model Predict
model_prediction = Model("https://clarifai.com/mistralai/completion/models/mistral-medium").predict_by_bytes(prompt.encode(), "text")

You can also run Mistral Medium API using other Clarifai Client Libraries like Java, cURL, NodeJS, PHP, etc here.

Benchmarks results

The following tables gather results on a suite of commonly used benchmarks for each of the Mistal models. Check out model selection guide to explore further the performance, and speed, and discuss how to select the appropriate model for different use cases.

General knowledge, common sense and reasoning

ModelMMLUhellaswag (10-shot)winograde (5-shot)arc challenge (25-shot)TriviaQA (5-shot)TruthfulQA
Mistral 7B62.5%83.1%78.0%78.1%68.8%42.35%
Mixtral 8x7B70.6%86.7%81.2%85.8%78.38%47.5%
Mistral Small72.2%86.9%84.7%86.9%79.5%51.7%
Mistral Medium75.3%88.0%88%89.9%81.1%47%
Mistral Large81.2%89.2%86.7%94.0%82.7%50.6%

Coding

ModelHumanE pass@1MBPP pass@1
Mistral 7B26.2%50.2%
Mistral 8x7B40.2%60.7%
Mistral Small44.5%61.5%
Mistral Medium38.4%62.3%
Mistral Large45.1%73.2%

Multi-lingual

ModelFR Arc-CFR HellaSFR MMLUDE Arc-CDE HellaSDE MMLUES Arc-CES HellaSES MMLUIT Arc-CIT HellaSIT MMLU
Mistral 7B44.2%63.9%50.6%39.9%58.4%49.6%43.9%64.8%51.4%41.2%60.8%51.3%
Mistral 8x7B54.3%76.0%66.1%52.7%71.0%64.9%53.7%76.3%67.5%51.1%72.9%65.9%
Mistral Small58.8%77.4%68.4%53.0%72.9%70.1%55.9%78.2%69.7%53.7%75.1%69.5%
Mistral Medium58.2%77.4%70.9%54.3%73.0%71.5%55.4%77.6%72.5%52.8%75.1%70.9%
Mistral Large62.3%80.3%79.3%57.6%77.2%78.2%61.7%81.9%79.7%60.3%77.8%78.9%

Mistral Model Use Cases

Here is a brief overview on the types of use cases we see along with their respective Mistral model:

  1. • Simple tasks that one can do in bulk (Classification, Customer Support, or Text Generation) are powered by Mistral Small.
  2. • Intermediate tasks that require moderate reasoning (Data extraction, Summarizing a Document, Writing emails, Writing a Job Description, or Writing Product Descriptions) are powered by Mistral Medium.
  3. • Complex tasks that require large reasoning capabilities or are highly specialized (Synthetic Text Generation, Code Generation, RAG, or Agents) are powered by Mistral Large
  • ID
  • Model Type ID
    Text To Text
  • Input Type
    text
  • Output Type
    text
  • Description
    Mistral AI's medium-sized LLM. Supports a context window of 32k tokens and outperforms Mixtral 8x7B and Mistral-7b on almost all benchmarks.
  • Last Updated
    Oct 17, 2024
  • Privacy
    PUBLIC
  • Use Case
  • License
  • Share
  • Badge
    mistral-medium