SmolLM2 1.7B Instruct
A 1.7B-parameter English chat model from Hugging Face's SmolLM2 family, built small enough to run on-device and tuned with SFT and DPO for instruction following and function calling.
Overview
SmolLM2 1.7B Instruct is the chat-tuned version of the largest SmolLM2 model. Hugging Face built the SmolLM2 family (135M, 360M and 1.7B parameters) small enough to run on-device. The architecture is a Llama-style transformer decoder, released in bfloat16.
Pretraining used 11 trillion tokens from FineWeb-Edu, DCLM, The Stack and new math and code sets the team curated. The instruct model then got supervised fine-tuning on public and in-house data (published as SmolTalk), followed by Direct Preference Optimization on UltraFeedback. Argilla datasets such as Synth-APIGen-v0.1 added rewriting, summarization and function calling.
Hugging Face reports 56.7 on IFEval, 6.13 on MT-Bench and 48.2 on GSM8K (5-shot) for this model.
What you can build
- Message rewriting. Hugging Face's example turns a terse note about a CI build broken by someone's commit into a polite request to look into it.
- Email summaries. The card's example system prompt caps them at three sentences.
- Function calling. With the tools listed in the system prompt, the model replies with a JSON array of calls inside tool_call tags for your code to run.
- Chat assistants that keep a separate thread per user and conversation.
- Brainstorming, like the Tower of London answer in this page's sample.
Inputs
The prompt is the only required field. An optional system prompt goes in front of it; replace the general-purpose default with a task brief or tool definitions.
user_id and session_id are optional. With them, Wiro stores the chat history for that user and reads it back on later calls, and a new session_id opens a separate thread. Leave both blank for one-off requests.
Temperature defaults to 0.7 (range 0 to 5) and top_p to 0.95; top_k goes up to 100. Repetition and length penalties, token limits and semicolon-separated stop sequences are also available. The seed defaults to 123456, and unchecking do_sample makes generation deterministic. Quantization, which runs the weights at reduced precision, is on by default.
Outputs
A plain-text reply. The sample answer opens with a short intro, then lists five dated events from 1078 to 1605, each with a "Fictional Story Idea" paragraph.
Recommended settings
- Rewriting and summaries: Hugging Face's examples use temperature 0.2 and top_p 0.9.
- Function calling: the card's example runs with sampling off, so uncheck do_sample and spell out the exact call format in the system prompt.
- The released config sets an 8,192-token context, shared by stored history, your prompt and the reply. Start a new session_id when a thread gets long.
Limitations
- Hugging Face describes SmolLM2 as primarily an English model.
- Answers can contain factual errors and biases from the training data. This page's sample puts the Gunpowder Plot barrels in the Tower's cellars; they were found beneath the House of Lords.
- Hugging Face reports 19.3 on MMLU-Pro, so expect thin specialist knowledge and put the facts you need in the prompt.
- Hugging Face reports 27% on the BFCL function-calling leaderboard. Check every call against your schema before running it.
Safety & compliance
Released under the Apache 2.0 license. Hugging Face's card calls the models assistive tools and asks users to verify important information.
API quick start
Run SmolLM2-1.7B-Instruct with a single API call.
{
"prompt": "What are some interesting historical even…",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}curl -X POST "https://api.wiro.ai/v1/Run/huggingfacetb/smollm2-1-7b-instruct" \
-H "Content-Type: application/json" \
-H "x-api-key: YOUR_WIRO_API_KEY" \
--data-binary @- <<'JSON'
{
"prompt": "What are some interesting historical even…",
"user_id": "...",
"session_id": "...",
"system_prompt": "You are a helpful, respectful and honest …"
}
JSONOther models you might like
Explore similar llm & chat models.



