HuggingFaceTB/SmolLM3-3B-Base
1. [Model Summary](#model-summary) 2. [How to use](#how-to-use) 3. [Evaluation](#evaluation) 4. [Training](#training) 5. [Limitations](#limitations) 6. [License](#license) SmolLM3 is a 3B parameter language model designed to push the boundaries of small models. It supports 6 languages, advanced reasoning and long context. SmolLM3 is a fully open model that offers strong performance at the 3B–4B scale. **SmolLM3-3B-Base** is the base model after pretraining, you can find the instruct model at [SmolLM3-3B](https://huggingface.co/HuggingFaceTB/SmolLM3-3B). The model is a decoder-only transformer using GQA and NoPE, it was pretrained on 11.2T tokens with a staged curriculum of web, code, math and reasoning data. Post-training included midtraining on 140B reasoning tokens followed by supervised fine-tuning and alignment via Anchored Preference Optimization (APO). - Instruct model optimized for **hybrid reasoning** - **Fully open model**: open weights + full training details including public data mixture and training configs - **Long context:** Trained on 64k context and suppots up to **128k tokens** using YARN extrapolation - **Multilingual**: 6 natively supported (English, French, Spanish, German, Italian, and Portuguese) For more details refer to our blog post: https://hf.co/blog/smollm3 The modeling code for SmolLM3 is available in transformers `v4.53.0`, so make sure to upgrade your transformers version. You can also load the model with the latest `vllm` which uses transformers as a backend. pip install -U transformers from transformers import AutoModelForCausalLM, AutoTokenizer checkpoint = "HuggingFaceTB/SmolLM3-3B" device = "cuda" # for GPU usage or "cpu" for CPU usage tokenizer = AutoTokenizer.from_pretrained(checkpoint) model = AutoModelForCausalLM.from_pretrained(checkpoint).to(device) inputs = tokenizer.encode("Gravity is", return_tensors="pt").to(device) outputs = model.generate(inputs) print(tokenizer.decode(outputs[0])) For local inference, you can use `llama.cpp`, `ONNX`, `MLX` and `MLC`. You can find quantized checkpoints in this collection (https://huggingface.co/collections/HuggingFaceTB/smollm3-686d33c1fdffe8e635317e23). The current `config.json` is set for context length up to 65,536 tokens. To handle longer inputs (128k or 256k), we utilize YaRN you can change the `max_position_embeddings` and rope_scaling` to: { ..., "rope_scaling": { "factor": 2.0, #2x65536=131 072 "original_max_position_embeddings": 65536, "type": "yarn" } } In this section, we report the evaluation results of SmolLM3 model. All evaluations are zero-shot unless stated otherwise, and we use [lighteval](https://github.com/huggingface/lighteval) to run them. We highlight the best score in bold and underline the second-best score. Note: All evaluations are zero-shot unless stated otherwise. For Ruler 64k evaluation, we apply YaRN to the Qwen models with 32k context to extrapolate the context length. The model has also been trained on Arabic (standard), Chinese and Russian data, but has seen fewer tokens in these languages compared to the 6 above. We report the performance on these langages for information. Evaluation results of non reasoning models and reasoning models in no thinking mode. We highlight the best and second-best scores in bold. (*): this is a tool calling finetune Evaluation results in reasoning mode for SmolLM3 and Qwen3 models: - **Architecture:** Transformer decoder - **Pretraining tokens:** 11T - **Precision:** bfloat16 - **GPUs:** 384 H100 - **Training Framework:** [nanotron](https://github.com/huggingface/nanotron/tree/main) - **Data processing framework:** [datatrove](https://github.com/huggingface/datatrove) - **Evaluation framework:** [lighteval](https://github.com/huggingface/lighteval) - **Post-training Framework:** [TRL](https://github.com/huggingface/trl) Here is an infographic with all the training details. - The datasets used for pretraining can be found in this [collection](https://huggingface.co/collections/HuggingFaceTB/smollm3-pretraining-datasets-685a7353fdc01aecde51b1d9) and those used in mid-training and post-training will be released in the following weeks - The training and evaluation configs and code can be found in the [huggingface/smollm](https://github.com/huggingface/smollm) repository. - The training intermediate checkpoints are available at [HuggingFaceTB/SmolLM3-3B-checkpoints](https://huggingface.co/HuggingFaceTB/SmolLM3-3B-checkpoints) SmolLM3 can produce text on a variety of topics, but the generated content may not always be factually accurate, logically consistent, or free from biases present in the training data. These models should be used as assistive tools rather than definitive sources of information. Users should always verify important information and critically evaluate any generated content. [Apache 2.0](https://www.apache.org/licenses/LICENSE-2.0) @misc{bakouch2025smollm3, title={{SmolLM3: smol, multilingual, long-context reasoner}}, author={Bakouch, Elie and Ben Allal, Loubna and Lozhkov, Anton and Tazi, Nouamane and Tunstall, Lewis and Patiño, Carlos Miguel and Beeching, Edward and Roucher, Aymeric and Reedi, Aksel Joonas and Gallouédec, Quentin and Rasul, Kashif and Habib, Nathan and Fourrier, Clémentine and Kydlicek, Hynek and Penedo, Guilherme and Larcher, Hugo and Morlon, Mathieu and Srivastav, Vaibhav and Lochner, Joshua and Nguyen, Xuan-Son and Raffel, Colin and von Werra, Leandro and Wolf, Thomas}, year={2025}, howpublished={\url{https://huggingface.co/blog/smollm3}} }
Open HuggingFaceTB/SmolLM3-3B-Base in AIniverse
Compare versions, read real ratings, save to your stack.
Open in App