Appearance
Mistral Small 4 119B A6B ​
Overview ​
Mistral Small 4 is a powerful hybrid model that unifies the capabilities of three different model families—Instruct, Reasoning (Magistral), and Devstral—into a single, unified model. It features a sparse mixture-of-experts architecture with 119B total parameters and 6.5B activated parameters per token, designed for general-purpose tasks including coding, agentic workflows, reasoning, and multimodal understanding. The model supports a native context length of up to 256,144 tokens.
Supported languages: multilingual, including English, French, Spanish, German, Italian, Portuguese, Dutch, Chinese, Japanese, Korean, and Arabic.
Input: multilingual text, image
Output: multilingual text, code, tool calls
Note
- Mistral Small 4 supports configurable reasoning effort per request via the
reasoning_effortparameter. - Set
reasoning_effort="none"for fast, lightweight responses for everyday tasks. - Set
reasoning_effort="high"for deep, step-by-step reasoning for complex problems. - This page documents the features currently exposed on Swisscom Inference Endpoints.
Use Cases: Applications that require multimodal reasoning, visual question answering, coding assistance, tool calling, structured workflows, long-context analysis, and general chat assistance.
Model Card: Mistral-Small-4-119B-2603
Key Features ​
- Reasoning Mode: Toggle between fast instant reply mode (
reasoning_effort="none") and reasoning mode (reasoning_effort="high"), boosting performance with test-time compute when requested. - Vision: Analyzes images and provides insights based on visual content, in addition to text.
- Multilingual: Supports dozens of languages, including English, French, Spanish, German, Italian, Portuguese, Dutch, Chinese, Japanese, Korean, and Arabic.
- System Prompt: Strong adherence and support for system prompts.
- Agentic: Best-in-class agentic capabilities with native function calling and JSON output.
- Speed-Optimized: Delivers best-in-class performance and speed with 40% reduction in end-to-end completion time in latency-optimized setup.
- Large Context Window: Supports a 256k context window.
- Apache 2.0 License: Open-source license for both commercial and non-commercial use.
Recommended Settings ​
- Reasoning Effort:
'none'→ Do not use reasoning (fast, lightweight responses)'high'→ Use reasoning (recommended for complex prompts)
- Temperature:
0.7forreasoning_effort="high"0.0to0.7forreasoning_effort="none"depending on task
Multimodal Reasoning ​
Mistral Small 4 can process image and text input in the same request. This makes the model suitable for tasks such as:
- describing scenes and visual content
- extracting information from screenshots, charts, and documents
- solving reasoning tasks that combine image and text context
- generating grounded answers based on visual evidence
Tool Calling ​
Mistral Small 4 is suitable for agentic workflows where the model needs to call external functions. By supplying a tools definition and setting tool_choice, applications can let the model decide when a tool should be invoked and then continue the conversation with tool results.
Best Practices ​
- For
reasoning_effort="high", a temperature of0.7is recommended. - For
reasoning_effort="none", use temperature between0.0and0.7depending on the task. - When image input is used, place the image before the task instruction inside the message content.
- In multi-turn applications, it is usually preferable to keep only the final answer in the stored conversation history instead of the full reasoning trace.
- For complex reasoning and coding workloads, a larger
max_completion_tokensbudget improves answer quality.
Endpoints ​
1. Create Chat Completion ​
POST /v1/chat/completions
Description ​
Generates a chat completion for text-only, multimodal, or tool-calling requests.
Request Body ​
json
{
"model": "mistralai/mistral-small-4-119b-2603",
"messages": [
{
"role": "user",
"content": "Summarize the main differences between retrieval and fine-tuning."
}
],
"temperature": 0.7,
"reasoning_effort": "none",
"max_completion_tokens": 2048,
"stream": false
}| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | ID of the model to use. Only mistralai/mistral-small-4-119b-2603 is available. |
messages | array | Yes | List of messages in the conversation. Message content can be plain text or multimodal content blocks. |
temperature | number | No | Sampling temperature. Use 0.7 for reasoning_effort="high", 0.0-0.7 for reasoning_effort="none". |
reasoning_effort | string | No | Controls reasoning depth. Values: "none" (fast) or "high" (deep reasoning). |
tools | array | No | Tool definitions for function calling. |
tool_choice | string or object | No | Controls whether and how the model selects a tool. |
max_completion_tokens | integer | No | Maximum number of tokens to generate. |
stream | boolean | No | If true, the response is streamed in chunks. Default: false. |
Response (When stream is false) ​
json
{
"id": "chat-abcdefg1234567",
"object": "chat.completion",
"created": 1770000000,
"model": "mistralai/mistral-small-4-119b-2603",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Retrieval augments a model with external knowledge at runtime, while fine-tuning changes model behavior through additional training."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 26,
"completion_tokens": 58,
"total_tokens": 84
}
}2. List Models ​
GET /v1/models
Description ​
Lists all available models and their metadata.
Response ​
json
{
"object": "list",
"data": [
{
"id": "mistralai/mistral-small-4-119b-2603",
"object": "model",
"created": 1770000000,
"owned_by": "SwissAI"
}
]
}Example Code Snippets ​
Note:
The production URL for this API is available in the corresponding plan for this model in the Digital Marketplace. To retrieve the URL:
- Navigate to the Digital Marketplace.
- Go to the Documentation section.
- Select the plan associated with the
Mistral Small 4 119B A6Bmodel.- Locate the production URL provided in the plan details.
- Set up the environment variable
API_URLto the production URL retrieved.
1. Text-only instruction following with curl ​
bash
curl -X POST $API_URL/v1/chat/completions \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "mistralai/mistral-small-4-119b-2603",
"messages": [
{
"role": "user",
"content": "Write me a sentence where every word starts with the next letter in the alphabet - start with 'a' and end with 'z'."
}
],
"temperature": 0.15,
"reasoning_effort": "none",
"max_completion_tokens": 1024
}'2. Image input with Python ​
python
import base64
import os
import openai
def image_to_base64(image_path: str) -> str:
with open(image_path, "rb") as img:
return base64.b64encode(img.read()).decode("utf-8")
client = openai.OpenAI(
api_key=os.getenv("YOUR_API_KEY"),
base_url=os.getenv("API_URL") + "/v1",
)
base64_image = image_to_base64("your_image.jpg")
response = client.chat.completions.create(
model="mistralai/mistral-small-4-119b-2603",
messages=[
{
"role": "user",
"content": [
{
"type": "image_url",
"image_url": {
"url": f"data:image/jpeg;base64,{base64_image}"
}
},
{
"type": "text",
"text": "Extract the key information from this screenshot."
}
]
}
],
temperature=0.15,
reasoning_effort="none",
max_completion_tokens=2048,
)
print(response.choices[0].message.content)3. Tool calling with Python ​
python
import json
import os
import openai
client = openai.OpenAI(
api_key=os.getenv("YOUR_API_KEY"),
base_url=os.getenv("API_URL") + "/v1",
)
def get_weather(location: str) -> str:
return f"The current weather in {location} is 12°C and cloudy."
tools = [
{
"type": "function",
"function": {
"name": "get_weather",
"description": "Return the current weather for a location.",
"parameters": {
"type": "object",
"properties": {
"location": {
"type": "string",
"description": "City and country"
}
},
"required": ["location"]
}
}
}
]
messages = [
{
"role": "system",
"content": "Use available tools when external information is required."
},
{
"role": "user",
"content": "What is the weather in Bern today?"
}
]
response = client.chat.completions.create(
model="mistralai/mistral-small-4-119b-2603",
messages=messages,
tools=tools,
tool_choice="auto",
temperature=0.15,
reasoning_effort="none",
)
tool_calls = response.choices[0].message.tool_calls
messages.append({"role": "assistant", "tool_calls": tool_calls})
for tool_call in tool_calls:
if tool_call.function.name == "get_weather":
arguments = json.loads(tool_call.function.arguments)
result = get_weather(arguments["location"])
messages.append(
{
"role": "tool",
"tool_call_id": tool_call.id,
"name": tool_call.function.name,
"content": result,
}
)
final_response = client.chat.completions.create(
model="mistralai/mistral-small-4-119b-2603",
messages=messages,
temperature=0.15,
reasoning_effort="none",
)
print(final_response.choices[0].message.content)4. Vision reasoning with reasoning_effort="high" ​
python
import os
import openai
client = openai.OpenAI(
api_key=os.getenv("YOUR_API_KEY"),
base_url=os.getenv("API_URL") + "/v1",
)
image_url = "https://example.com/image.jpg"
messages = [
{
"role": "user",
"content": [
{
"type": "text",
"text": "What action do you think I should take in this situation? List all the possible actions and explain why you think they are good or bad.",
},
{"type": "image_url", "image_url": {"url": image_url}},
],
},
]
response = client.chat.completions.create(
model="mistralai/mistral-small-4-119b-2603",
messages=messages,
temperature=0.7,
reasoning_effort="high",
max_completion_tokens=4096,
)
print(response.choices[0].message.content)5. Non-reasoning mode for fast responses ​
python
import os
import openai
client = openai.OpenAI(
api_key=os.getenv("YOUR_API_KEY"),
base_url=os.getenv("API_URL") + "/v1",
)
response = client.chat.completions.create(
model="mistralai/mistral-small-4-119b-2603",
messages=[
{
"role": "user",
"content": "Provide a one-sentence summary of retrieval-augmented generation."
}
],
temperature=0.3,
reasoning_effort="none",
max_completion_tokens=512,
)
print(response.choices[0].message.content)Replace YOUR_API_KEY with the actual API key. The authentication flow is described in Inference Endpoints Overview.

