/ Модель

Характеристики

Контекст
32 768 токенов
Параметры
7,5 млрд
Размер весов
16 ГБ
Лицензия
Своя лицензия
Архитектура
mistral · dense
Библиотека
vllm
Опубликована
15 окт 2024

Ministral-8B-Instruct-2410

Генерация текстаТекст → текст15 профессий

Многоязычная инструкция-дообученная языковая модель Mistral AI с 8 млрд параметров для локального чата, генерации текста, кода и вызова функций.

122 тыс.скачиваний за 30 дней596лайковвеса обновлены31 июл 2025

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Тесты пользователейпока нет

Никто ещё не опубликовал тест этой модели. Соберите бенчмарк из своих задач — результат появится здесь.

  1. Добавьте модель в бенчмарк

    Вместе с другими моделями категории «Текст» — сравнение идёт внутри одной категории.

  2. Опишите свои задачи

    Напишите запросы, при необходимости приложите файлы и эталонные ответы.

  3. Запустите и опубликуйте

    Модели ответят на каждую задачу, судья оценит ответы. Опубликованный результат появится на этой странице.

Публичные оценки8

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

  • BBH

    BBH Raw · выше — лучше

    Результат

    0,4762

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

  • IFEval

    IFEval Raw · выше — лучше

    Результат

    0,5896

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

  • MMLU-PRO

    MMLU-PRO Raw · выше — лучше

    Результат

    0,3291

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

  • LEXam-Benchmark/LEXam

    score · выше — лучше

    Результат

    26,27

    mcq_4_choices 26,27open_question 14,88
    Hugging Face Leaderboards

    Публичная таблицаревизия не подтверждена

  • TIGER-Lab/MMLU-Pro

    score · выше — лучше

    Результат

    37,93

    mmlu_pro 37,93
    Hugging Face Leaderboards

    Публичная таблицаревизия не подтверждена

  • MUSR

    MUSR Raw · выше — лучше

    Результат

    0,4138

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

  • MATH Lvl 5

    MATH Lvl 5 Raw · выше — лучше

    Результат

    0,1956

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

  • GPQA

    GPQA Raw · выше — лучше

    Результат

    0,2844

    Open LLM v2 · архив

    Публичная таблицадругая ревизия

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Ministral-8B-Instruct-2410 — инструкция-дообученная плотная трансформерная языковая модель компании Mistral AI с примерно 8 млрд параметров. Она предназначена для локального и периферийного запуска, диалогов и выполнения инструкций; также поддерживает вызов функций и задачи с кодом и математическими рассуждениями. Модель обучена на многоязычных данных и данных по программированию. В карточке заявлено контекстное окно до 128 тыс. токенов с чередующимся скользящим вниманием; в vLLM контекст ограничен 32 тыс. токенов. Метаданные указывают 32 768 токенов как native context.

Модель рассчитана на генерацию текста и чат на нескольких языках, включая русский, английский, французский, немецкий, испанский, итальянский, португальский, китайский, японский и корейский. Для запуска на одном GPU требуется около 24 ГБ видеопамяти; для длинного контекста требования могут быть выше. Модель выпущена по Mistral Research License; для коммерческого использования README предлагает обратиться к Mistral AI за коммерческой лицензией.

Сценарии применения

  • диалоговый помощник с локальным запуском
  • ответы на запросы и следование инструкциям
  • генерация и объяснение программного кода
  • решение математических задач
  • вызов функций в приложениях с LLM
  • генерация текста на нескольких языках

Ограничения

В vLLM контекст ограничен 32 тыс. токенов, хотя README заявляет обучение с окном до 128 тыс.; для одного GPU требуется около 24 ГБ видеопамяти. Коммерческое использование требует отдельной лицензии от Mistral AI.

Для каких профессий подходит15

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Также подходит для

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

Model Card for Ministral-8B-Instruct-2410

We introduce two new state-of-the-art models for local intelligence, on-device computing, and at-the-edge use cases. We call them les Ministraux: Ministral 3B and Ministral 8B.

The Ministral-8B-Instruct-2410 Language Model is an instruct fine-tuned model significantly outperforming existing models of similar size, released under the Mistral Research License.

If you are interested in using Ministral-3B or Ministral-8B commercially, outperforming Mistral-7B, reach out to us.

For more details about les Ministraux please refer to our release blog post.

Ministral 8B Key features

  • Released under the Mistral Research License, reach out to us for a commercial license
  • Trained with a 128k context window with interleaved sliding-window attention
  • Trained on a large proportion of multilingual and code data
  • Supports function calling
  • Vocabulary size of 131k, using the V3-Tekken tokenizer

Basic Instruct Template (V3-Tekken)

<s>[INST]user message[/INST]assistant response</s>[INST]new user message[/INST]

For more information about the tokenizer please refer to mistral-common

Ministral 8B Architecture

FeatureValue
ArchitectureDense Transformer
Parameters8,019,808,256
Layers36
Heads32
Dim4096
KV Heads (GQA)8
Hidden Dim12288
Head Dim128
Vocab Size131,072
Context Length128k
Attention PatternRagged (128k,32k,32k,32k)

Benchmarks

Base Models

Knowledge & Commonsense

ModelMMLUAGIEvalWinograndeArc-cTriviaQA
Mistral 7B Base62.542.574.267.962.5
Llama 3.1 8B Base64.744.474.646.060.2
Ministral 8B Base65.048.375.371.965.5
Gemma 2 2B Base52.433.868.742.647.8
Llama 3.2 3B Base56.237.459.643.150.7
Ministral 3B Base60.942.172.764.256.7

Code & Math

ModelHumanEval pass@1GSM8K maj@8
Mistral 7B Base26.832.0
Llama 3.1 8B Base37.842.2
Ministral 8B Base34.864.5
Gemma 2 2B20.135.5
Llama 3.2 3B14.633.5
Ministral 3B34.250.9

Multilingual

ModelFrench MMLUGerman MMLUSpanish MMLU
Mistral 7B Base50.649.651.4
Llama 3.1 8B Base50.852.854.6
Ministral 8B Base57.557.459.6
Gemma 2 2B Base41.040.141.7
Llama 3.2 3B Base42.342.243.1
Ministral 3B Base49.148.349.5

Instruct Models

Chat/Arena (gpt-4o judge)

ModelMTBenchArena HardWild bench
Mistral 7B Instruct v0.36.744.333.1
Llama 3.1 8B Instruct7.562.437.0
Gemma 2 9B Instruct7.668.743.8
Ministral 8B Instruct8.370.941.3
Gemma 2 2B Instruct7.551.732.5
Llama 3.2 3B Instruct7.246.027.2
Ministral 3B Instruct8.164.336.3

Code & Math

ModelMBPP pass@1HumanEval pass@1Math maj@1
Mistral 7B Instruct v0.350.238.413.2
Gemma 2 9B Instruct68.567.747.4
Llama 3.1 8B Instruct69.767.149.3
Ministral 8B Instruct70.076.854.5
Gemma 2 2B Instruct54.542.722.8
Llama 3.2 3B Instruct64.661.038.4
Ministral 3B Instruct67.777.451.7

Function calling

ModelInternal bench
Mistral 7B Instruct v0.36.9
Llama 3.1 8B InstructN/A
Gemma 2 9B InstructN/A
Ministral 8B Instruct31.6
Gemma 2 2B InstructN/A
Llama 3.2 3B InstructN/A
Ministral 3B Instruct28.4

Usage Examples

vLLM (recommended)

We recommend using this model with the vLLM library to implement production-ready inference pipelines.

[!IMPORTANT] Currently vLLM is capped at 32k context size because interleaved attention kernels for paged attention are not yet implemented in vLLM. Attention kernels for paged attention are being worked on and as soon as it is fully supported in vLLM, this model card will be updated. To take advantage of the full 128k context size we recommend Mistral Inference

Installation

Make sure you install vLLM >= v0.6.4:

pip install --upgrade vllm

Also make sure you have mistral_common >= 1.4.4 installed:

pip install --upgrade mistral_common

You can also make use of a ready-to-go docker image.

Offline

from vllm import LLM
from vllm.sampling_params import SamplingParams

model_name = "mistralai/Ministral-8B-Instruct-2410"

sampling_params = SamplingParams(max_tokens=8192)

# note that running Ministral 8B on a single GPU requires 24 GB of GPU RAM
# If you want to divide the GPU requirement over multiple devices, please add *e.g.* `tensor_parallel=2`
llm = LLM(model=model_name, tokenizer_mode="mistral", config_format="mistral", load_format="mistral")

prompt = "Do we need to think for 10 seconds to find the answer of 1 + 1?"

messages = [
    {
        "role": "user",
        "content": prompt
    },
]

outputs = llm.chat(messages, sampling_params=sampling_params)

print(outputs[0].outputs[0].text)
# You don't need to think for 10 seconds to find the answer to 1 + 1. The answer is 2,
# and you can easily add these two numbers in your mind very quickly without any delay.

Server

You can also use Ministral-8B in a server/client setting.

  1. Spin up a server:
vllm serve mistralai/Ministral-8B-Instruct-2410 --tokenizer_mode mistral --config_format mistral --load_format mistral

Note: Running Ministral-8B on a single GPU requires 24 GB of GPU RAM.

If you want to divide the GPU requirement over multiple devices, please add e.g. --tensor_parallel=2

  1. And ping the client:
curl --location 'http://<your-node-url>:8000/v1/chat/completions' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer token' \
--data '{
    "model": "mistralai/Ministral-8B-Instruct-2410",
    "messages": [
      {
        "role": "user",
        "content": "Do we need to think for 10 seconds to find the answer of 1 + 1?"
      }
    ]
}'

Mistral-inference

We recommend using mistral-inference to quickly try out / "vibe-check" the model.

Install

Make sure to have mistral_inference >= 1.5.0 installed.

pip install mistral_inference --upgrade

Download

from huggingface_hub import snapshot_download
from pathlib import Path

mistral_models_path = Path.home().joinpath('mistral_models', '8B-Instruct')
mistral_models_path.mkdir(parents=True, exist_ok=True)

snapshot_download(repo_id="mistralai/Ministral-8B-Instruct-2410", allow_patterns=["params.json", "consolidated.safetensors", "tekken.json"], local_dir=mistral_models_path)

Chat

After installing mistral_inference, a mistral-chat CLI command should be available in your environment. You can chat with the model using

mistral-chat $HOME/mistral_models/8B-Instruct --instruct --max_tokens 256

Passkey detection

[!IMPORTANT] In this example the passkey message has over >100k tokens and mistral-inference does not have a chunked pre-fill mechanism. Therefore you will need a lot of GPU memory in order to run the below example (80 GB). For a more memory-efficient solution we recommend using vLLM.

from mistral_inference.transformer import Transformer
from pathlib import Path
import json
from mistral_inference.generate import generate
from huggingface_hub import hf_hub_download

from mistral_common.tokens.tokenizers.mistral import MistralTokenizer
from mistral_common.protocol.instruct.messages import UserMessage
from mistral_common.protocol.instruct.request import ChatCompletionRequest

def load_passkey_request() -> ChatCompletionRequest:
    passkey_file = hf_hub_download(repo_id="mistralai/Ministral-8B-Instruct-2410", filename="passkey_example.json")

    with open(passkey_file, "r") as f:
        data = json.load(f)

    message_content = data["messages"][0]["content"]
    return ChatCompletionRequest(messages=[UserMessage(content=message_content)])

tokenizer = MistralTokenizer.from_file(f"{mistral_models_path}/tekken.json")
model = Transformer.from_folder(mistral_models_path, softmax_fp32=False)

completion_request = load_passkey_request()

tokens = tokenizer.encode_chat_completion(completion_request).tokens

out_tokens, _ = generate([tokens], model, max_tokens=64, temperature=0.0, eos_id=tokenizer.instruct_tokenizer.tokenizer.eos_id)
result = tokenizer.instruct_tokenizer.tokenizer.decode(out_tokens[0])

print(result)  # The pass key is 13005.

Instruct following

from mistral_inference.transformer import Transformer
from mistral_inference.generate import generate

from mistral_common.tokens.tokenizers.mistral import MistralTokenizer
from mistral_common.protocol.instruct.messages import UserMessage
from mistral_common.protocol.instruct.request import ChatCompletionRequest


tokenizer = MistralTokenizer.from_file(f"{mistral_models_path}/tekken.json")
model = Transformer.from_folder(mistral_models_path)

completion_request = ChatCompletionRequest(messages=[UserMessage(content="How often does the letter r occur in Mistral?")])

tokens = tokenizer.encode_chat_completion(completion_request).tokens

out_tokens, _ = generate([tokens], model, max_tokens=64, temperature=0.0, eos_id=tokenizer.instruct_tokenizer.tokenizer.eos_id)
result = tokenizer.instruct_tokenizer.tokenizer.decode(out_tokens[0])

print(result)

Function calling

from mistral_common.protocol.instruct.tool_calls import Function, Tool
from mistral_inference.transformer import Transformer
from mistral_inference.generate import generate

from mistral_common.tokens.tokenizers.mistral import MistralTokenizer
from mistral_common.protocol.instruct.messages import UserMessage
from mistral_common.protocol.instruct.request import ChatCompletionRequest
from mistral_common.tokens.tokenizers.tekken import SpecialTokenPolicy


tokenizer = MistralTokenizer.from_file(f"{mistral_models_path}/tekken.json")
tekken = tokenizer.instruct_tokenizer.tokenizer
tekken.special_token_policy = SpecialTokenPolicy.IGNORE

model = Transformer.from_folder(mistral_models_path)

completion_request = ChatCompletionRequest(
    tools=[
        Tool(
            function=Function(
                name="get_current_weather",
                description="Get the current weather",
                parameters={
                    "type": "object",
                    "properties": {
                        "location": {
                            "type": "string",
                            "description": "The city and state, e.g. San Francisco, CA",
                        },
                        "format": {
                            "type": "string",
                            "enum": ["celsius", "fahrenheit"],
                            "description": "The temperature unit to use. Infer this from the users location.",
                        },
                    },
                    "required": ["location", "format"],
                },
            )
        )
    ],
    messages=[
        UserMessage(content="What's the weather like today in Paris?"),
        ],
)

tokens = tokenizer.encode_chat_completion(completion_request).tokens

out_tokens, _ = generate([tokens], model, max_tokens=64, temperature=0.0, eos_id=tokenizer.instruct_tokenizer.tokenizer.eos_id)
result = tokenizer.instruct_tokenizer.tokenizer.decode(out_tokens[0])

print(result)

The Mistral AI Team

Albert Jiang, Alexandre Abou Chahine, Alexandre Sablayrolles, Alexis Tacnet, Alodie Boissonnet, Alok Kothari, Amélie Héliou, Andy Lo, Anna Peronnin, Antoine Meunier, Antoine Roux, Antonin Faure, Aritra Paul, Arthur Darcet, Arthur Mensch, Audrey Herblin-Stoop, Augustin Garreau, Austin Birky, Avinash Sooriyarachchi, Baptiste Rozière, Barry Conklin, Bastien Bouillon, Blanche Savary de Beauregard, Carole Rambaud, Caroline Feldman, Charles de Freminville, Charline Mauro, Chih-Kuan Yeh, Chris Bamford, Clement Auguy, Corentin Heintz, Cyriaque Dubois, Devendra Singh Chaplot, Diego Las Casas, Diogo Costa, Eléonore Arcelin, Emma Bou Hanna, Etienne Metzger, Fanny Olivier Autran, Francois Lesage, Garance Gourdel, Gaspard Blanchet, Gaspard Donada Vidal, Gianna Maria Lengyel, Guillaume Bour, Guillaume Lample, Gustave Denis, Harizo Rajaona, Himanshu Jaju, Ian Mack, Ian Mathew, Jean-Malo Delignon, Jeremy Facchetti, Jessica Chudnovsky, Joachim Studnia, Justus Murke, Kartik Khandelwal, Kenneth Chiu, Kevin Riera, Leonard Blier, Leonard Suslian, Leonardo Deschaseaux, Louis Martin, Louis Ternon, Lucile Saulnier, Lélio Renard Lavaud, Sophia Yang, Margaret Jennings, Marie Pellat, Marie Torelli, Marjorie Janiewicz, Mathis Felardos, Maxime Darrin, Michael Hoff, Mickaël Seznec, Misha Jessel Kenyon, Nayef Derwiche, Nicolas Carmont Zaragoza, Nicolas Faurie, Nicolas Moreau, Nicolas Schuhl, Nikhil Raghuraman, Niklas Muhs, Olivier de Garrigues, Patricia Rozé, Patricia Wang, Patrick von Platen, Paul Jacob, Pauline Buche, Pavankumar Reddy Muddireddy, Perry Savas, Pierre Stock, Pravesh Agrawal, Renaud de Peretti, Romain Sauvestre, Romain Sinthe, Roman Soletskyi, Sagar Vaze, Sandeep Subramanian, Saurabh Garg, Soham Ghosh, Sylvain Regnier, Szymon Antoniak, Teven Le Scao, Theophile Gervet, Thibault Schueller, Thibaut Lavril, Thomas Wang, Timothée Lacroix, Valeriia Nemychnikova, Wendy Shang, William El Sayed, William Marshall

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · vllm

Можно запустить

Подбираем GPU…

Класс архитектуры
MistralForCausalLM
Ревизия весов
2f494a1

0 моделей