Mindket

SmolLM2-135M

Newversion 1 · updated

Overview

Continues English text from a prompt with a 135M-parameter base language model small enough to run on-device. For developers who want a tiny model to test ideas on or fine-tune.

SmolLM2-135M is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page, a zip of its files. Nothing in it runs by itself.

At a glance

You need
  • Python with pip
  • The transformers library, plus accelerate if you spread the model over several GPUs
  • Room for the weights: about 269 MB in BF16, or about 67 MB at 4-bit by estimate
Runs in
  • Python scripts with the transformers library
  • A CPU, one GPU or several GPUs, as the card's examples show
  • Windows, macOS or Linux with Python
Start with
pip install transformers

Platform

WindowsOperating system
macOSOperating system
LinuxOperating system

About

What it is

SmolLM2-135M is the smallest model in the SmolLM2 family, which also has 360M and 1.7B versions. This one is the base model, so it continues the text you give it and does not follow chat instructions. It was trained on 2 trillion tokens from FineWeb-Edu, DCLM, The Stack and extra filtered data.

Who it suits

It suits developers, students and researchers who want a tiny English language model for experiments, teaching or fine-tuning on modest hardware.

IndustryWho uses itHow they use itExample
SoftwareApp developersPrototype on-device text features with a tiny modelTesting autocomplete behaviour offline
EducationTeachers and studentsLearn how language models load and generateA classroom demo of text completion
ResearchML researchersFine-tune a small base model for a narrow taskTraining it on a domain's text
ToolingPipeline buildersSmoke-test code with a model that loads fastChecking a generation pipeline end to end

Skip it if you need reliable answers or chat behaviour, since the card's own scores for maths and trivia are low.

Where to use it

  • Python scripts with the transformers library
  • A CPU, one GPU or several GPUs, as the card's examples show
  • Windows, macOS or Linux with Python
Use caseWhoWhat they get back
Text completionDevelopersA continuation of a short prompt
Fine-tuning baseResearchersA small starting point for task training
Pipeline testingEngineersA model that loads quickly on a laptop

How to set it up

You need these first.

  • Python with pip
  • The transformers library, plus accelerate if you spread the model over several GPUs
  • Room for the weights: about 269 MB in BF16, or about 67 MB at 4-bit by estimate
  1. Install the transformers library with pip.
  2. Load the model by its Hugging Face name.
  3. Encode a prompt, call generate and decode the result.
pip install transformers
pip install -U huggingface_hub
hf download HuggingFaceTB/SmolLM2-135M

How to use it

Load the tokenizer and model, move the model to your device, encode a short prompt and call generate. The card shows a full-precision script and a bfloat16 script.

# pip install transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
checkpoint = "HuggingFaceTB/SmolLM2-135M"
device = "cuda" # for GPU usage or "cpu" for CPU usage
tokenizer = AutoTokenizer.from_pretrained(checkpoint)
# for multiple GPUs install accelerate and do `model = AutoModelForCausalLM.from_pretrained(checkpoint, device_map="auto")`
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]))
# pip install accelerate
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
checkpoint = "HuggingFaceTB/SmolLM2-135M"
tokenizer = AutoTokenizer.from_pretrained(checkpoint)
# for fp16 use `torch_dtype=torch.float16` instead
model = AutoModelForCausalLM.from_pretrained(checkpoint, device_map="auto", torch_dtype=torch.bfloat16)
inputs = tokenizer.encode("Gravity is", return_tensors="pt").to("cuda")
outputs = model.generate(inputs)
print(tokenizer.decode(outputs[0]))
ToolWhat it does
AutoTokenizerTurns your prompt into token IDs and back into text
AutoModelForCausalLMLoads the model weights
model.generateContinues the prompt
device_map="auto"Places the model on your available GPUs, and needs accelerate

Example

Run the first script with the prompt "Gravity is". The model continues the sentence and the script prints the prompt plus the continuation. Expect a short, loosely correct passage, since a 135M base model is weak on facts.

For newcomers and experts

If you are new, a base model finishes sentences and does not take orders. Run the Gravity example once on CPU and read what it adds. Change the prompt to the start of a sentence of your own.

If you know the field, the card compares it with SmolLM-135M on zero-shot benchmarks run with lighteval. SmolLM2 scores slightly higher on HellaSwag, ARC and MMLU cloze, ties on PIQA and Winogrande, and trails on TriviaQA. The instruct variant adds supervised fine-tuning and DPO on top of this base.

  1. Your prompt text
  2. Tokenizer makes token IDs
  3. Model predicts the next tokens
  4. Tokens are decoded to text
  5. Continuation is printed

Good to know

  • Language: English only
  • Size: 135M parameters in Safetensors
  • Family: 360M and 1.7B siblings exist, plus an instruct version of each
  • Community: other people have made 79 quantized and 1,000 fine-tuned versions
Zero-shot scores of SmolLM2-135M from the card
HellaSwag42.1 points
ARC average43.9 points
PIQA68.4 points
MMLU cloze31.5 points
CommonsenseQA33.9 points
Winogrande51.3 points
OpenBookQA34.6 points
TriviaQA4.1 points
  • License: Apache 2.0
  • Cost to run: none named, the source lists no API key, account or paid service
  • Data it reaches: the prompts you give your own script, and the source names no web or account access
  • Not for: chat or instruction following, and maths, since the card reports 1.4 on GSM8K

README and files

README

SmolLM2-135M

Continues English text from a prompt with a 135M-parameter base language model small enough to run on-device. For developers who want a tiny model to test ideas on or fine-tune.

Made by HuggingFaceTB on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.

About

What it is: SmolLM2-135M is the smallest model in the SmolLM2 family, which also has 360M and 1.7B versions. This one is the base model, so it continues the text you give it and does not follow chat instructions. It was trained on 2 trillion tokens from FineWeb-Edu, DCLM, The Stack and extra filtered data.

Who it suits: It suits developers, students and researchers who want a tiny English language model for experiments, teaching or fine-tuning on modest hardware.

Industry | Who uses it | How they use it | Example
Software | App developers | Prototype on-device text features with a tiny model | Testing autocomplete behaviour offline
Education | Teachers and students | Learn how language models load and generate | A classroom demo of text completion
Research | ML researchers | Fine-tune a small base model for a narrow task | Training it on a domain's text
Tooling | Pipeline builders | Smoke-test code with a model that loads fast | Checking a generation pipeline end to end

Skip it if you need reliable answers or chat behaviour, since the card's own scores for maths and trivia are low.

Where to use it:

  • Python scripts with the transformers library
  • A CPU, one GPU or several GPUs, as the card's examples show
  • Windows, macOS or Linux with Python
Use case | Who | What they get back
Text completion | Developers | A continuation of a short prompt
Fine-tuning base | Researchers | A small starting point for task training
Pipeline testing | Engineers | A model that loads quickly on a laptop

How to set it up: You need these first.

  • Python with pip
  • The transformers library, plus accelerate if you spread the model over several GPUs
  • Room for the weights: about 269 MB in BF16, or about 67 MB at 4-bit by estimate
  1. Install the transformers library with pip.
  2. Load the model by its Hugging Face name.
  3. Encode a prompt, call generate and decode the result.
pip install transformers
pip install -U huggingface_hub
hf download HuggingFaceTB/SmolLM2-135M

How to use it: Load the tokenizer and model, move the model to your device, encode a short prompt and call generate. The card shows a full-precision script and a bfloat16 script.

# pip install transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
checkpoint = "HuggingFaceTB/SmolLM2-135M"
device = "cuda" # for GPU usage or "cpu" for CPU usage
tokenizer = AutoTokenizer.from_pretrained(checkpoint)
# for multiple GPUs install accelerate and do `model = AutoModelForCausalLM.from_pretrained(checkpoint, device_map="auto")`
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]))
# pip install accelerate
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
checkpoint = "HuggingFaceTB/SmolLM2-135M"
tokenizer = AutoTokenizer.from_pretrained(checkpoint)
# for fp16 use `torch_dtype=torch.float16` instead
model = AutoModelForCausalLM.from_pretrained(checkpoint, device_map="auto", torch_dtype=torch.bfloat16)
inputs = tokenizer.encode("Gravity is", return_tensors="pt").to("cuda")
outputs = model.generate(inputs)
print(tokenizer.decode(outputs[0]))
Tool | What it does
AutoTokenizer | Turns your prompt into token IDs and back into text
AutoModelForCausalLM | Loads the model weights
model.generate | Continues the prompt
device_map="auto" | Places the model on your available GPUs, and needs accelerate

Example: Run the first script with the prompt "Gravity is". The model continues the sentence and the script prints the prompt plus the continuation. Expect a short, loosely correct passage, since a 135M base model is weak on facts.

For newcomers and experts: If you are new, a base model finishes sentences and does not take orders. Run the Gravity example once on CPU and read what it adds. Change the prompt to the start of a sentence of your own.

If you know the field, the card compares it with SmolLM-135M on zero-shot benchmarks run with lighteval. SmolLM2 scores slightly higher on HellaSwag, ARC and MMLU cloze, ties on PIQA and Winogrande, and trails on TriviaQA. The instruct variant adds supervised fine-tuning and DPO on top of this base.

Your prompt text
Tokenizer makes token IDs
Model predicts the next tokens
Tokens are decoded to text
Continuation is printed

Good to know:

  • Language: English only
  • Size: 135M parameters in Safetensors
  • Family: 360M and 1.7B siblings exist, plus an instruct version of each
  • Community: other people have made 79 quantized and 1,000 fine-tuned versions
Title: Zero-shot scores of SmolLM2-135M from the card
HellaSwag: 42.1 points
ARC average: 43.9 points
PIQA: 68.4 points
MMLU cloze: 31.5 points
CommonsenseQA: 33.9 points
Winogrande: 51.3 points
OpenBookQA: 34.6 points
TriviaQA: 4.1 points
  • License: Apache 2.0
  • Cost to run: none named, the source lists no API key, account or paid service
  • Data it reaches: the prompts you give your own script, and the source names no web or account access
  • Not for: chat or instruction following, and maths, since the card reports 1.4 on GSM8K

On Hugging Face, 13 November 2026

  • Task: text generation
  • Library: transformers
  • Parameters: 135M
  • Weights: about 269 MB in BF16; about 67 MB at 4-bit (estimate)
  • Formats: Safetensors
  • Downloads in the last 30 days: 2,596,139
  • Likes: 269
  • License: apache-2.0
  • Languages: en
  • Quantized versions: 79
  • Fine-tunes: 1,002
  • Tags: transformers, safetensors, llama, text-generation

Links

Get the model

Download its files with Hugging Face's command line:

pip install -U huggingface_hub
hf download HuggingFaceTB/SmolLM2-135M

Then follow the usage in its model card. Nothing in this kit runs by itself.

Files
README.md  6 KB

1 file, 6 KB, downloaded as a zip.

What’s new

  • Version 1 · 2026-11-13

Compare with similar

Listed Hugging Face models in the same category that share the most tags with this one.

ProductDownloads, last 30 daysLikesParametersLicenseLast change
SmolLM2-135M This page2,596,139269135Mapache-2.0
MiniCPM5-2BShares llama · text-generation · transformers1,039,5181,8502.5Bapache-2.0
TinyLlama-1.1B-Chat-v1.0Shares llama · text-generation · transformers963,0571,9101.1Bapache-2.0
SmolLM2-135M-InstructShares llama · text-generation · transformers841,106474135Mapache-2.0
Hermes 3 Llama-3.1 8BShares llama · text-generation · transformers336,9535508Bllama3
Meta-Llama-3.1-8B-Instruct-AWQ-INT4Shares llama · text-generation · transformers319,739968Bllama3.1
Numbers as Mindket last read them, from 2026-11-12 to 2026-11-14.

Reviews

No ratings yet

Write a review

No reviews yet.

What people say

Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search and on Trendshift. Mindket doesn’t write or check them. Open one to read it where it was posted.

Searched

More from Mindket

See all from Mindket

Huashu Design

alchaincyf · Skill

Turns a one-line request in your AI agent into a finished design: a launch animation, a clickable app prototype, an editable slide deck, an infographic or a se…

New29.4k

Guizang PPT Skill

op7418 · Skill

Skill that makes single-file HTML slide decks, slide illustrations and platform covers in two visual styles, with a presenter mode for rehearsal. For speakers…

New29.8k

Claude Code Skills & Plugins

alirezarezvani · Skill

Adds 411 ready-made skills for Claude Code and other coding agents, grouped by role from engineering and product to marketing, finance and compliance. Installs…

New29.8k

Similar in Developer

See all in Developer

buzz

block · Kit

Self-hostable workspace where people and AI agents share the same rooms, built on a Nostr relay that logs every action as a signed event. For teams that want t…

New37.3k

plannotator

backnotprop · Kit

Opens your AI coding agent's plans, specs and code changes in a browser so you can annotate or comment on them and send the feedback straight back to the agent.

New10.5k

open-code-review

alibaba · Kit

Reviews Git changes with an AI agent that reads files and searches the codebase, then writes comments tied to exact lines. It suits developers who want automat…

New50.7k