Model reference · open weights
qwen3-gsm8k-sft is an open-weight language model from Hugging Face. qwen3-1.7b-gsm8k-sft (BF16) weighs 3.4 GB; the smallest configuration that runs it is RTX 3060 12 GB.
Summary of the HuggingFaceTB/qwen3-1.7b-gsm8k-sft model card, 2026-10-01
What it is
| Released by | Hugging Face |
|---|---|
| Released | 2026-03-25 |
| Parameters | 1.7B |
| VRAM | 3.4 GB for the weights |
What it runs on
| Card | Requests at once | Context max | Memory | |
|---|---|---|---|---|
| 8K each | 32K each | |||
| RTX 3060 12 GB | 7 | 1 | all 40K | 11.6 GB |
| RTX 4060 Ti 16 GB | 12 | 3 | all 40K | 15.4 GB |
| RTX 3090 24 GB | 20 | 5 | all 40K | 23.4 GB |
| RTX 4090 24 GB | 20 | 5 | all 40K | 23.4 GB |
| RTX 5090 32 GB | 28 | 7 | all 40K | 31.0 GB |
| L40S 48 GB | 42 | 10 | all 40K | 44.0 GB |
| A100 80 GB | 78 | 19 | all 40K | 78.2 GB |
| H100 80 GB | 78 | 19 | all 40K | 78.1 GB |
| RTX PRO 6000 Blackwell 96 GB | 95 | 23 | all 40K | 93.8 GB |
| DGX Spark (GB10) 128 GB unified | 109 | 27 | all 40K | 107 GB |
| H200 141 GB | 142 | 35 | all 40K | 138 GB |
| B200 180 GB | 183 | 45 | all 40K | 176 GB |
| 2× RTX 3060 12 GB split by layers (llama.cpp) | 19 | 4 | all 40K | 11.6 GB a card |
| Requests at once | 8K tokens each | 32K tokens each |
|---|---|---|
| 1 | 5.0 GB | 7.9 GB |
| 5 | 8.8 GB | 22.9 GB |
| 8 | 11.6 GB | 34.2 GB |
| 16 | 19.1 GB | 64.2 GB |
| 32 | 34.2 GB | 124 GB |
| 64 | 64.2 GB | 245 GB |
One card, with vLLM's small-card settings.
From the model card
This model is a fine-tuned version of Qwen/Qwen3-1.7B optimized for mathematical reasoning on the GSM8K benchmark.
| Benchmark | Accuracy | Notes |
|---|---|---|
| GSM8K | 77.2% | Grade school math (1,319 test problems) |
| MATH-500 | 55.2% | Competition math (500 test problems) |
| Baseline GSM8K | 20% | Original Qwen3-1.7B |
| Level | Accuracy |
|---|---|
| Level 1 (Easiest) | 86.0% |
| Level 2 | 68.9% |
| Level 3 | 64.8% |
| Level 4 | 54.7% |
| Level 5 (Hardest) | 29.1% |
| Subject | Accuracy |
|---|---|
| Algebra | 71.8% |
| Prealgebra | 68.3% |
| Number Theory | 61.3% |
| Counting & Probability | 55.3% |
| Geometry | 43.9% |
| Precalculus | 41.1% |
| Intermediate Algebra | 32.0% |
| Model | GSM8K | MATH-500 | Notes |
|---|---|---|---|
| This model (SFT) | 77.2% | 55.2% | Optimized for GSM8K |
| Qwen3-1.7B (base) | ~20% | 62.0% | Pre-training only |
Note: The fine-tuned model shows significant improvement on GSM8K (+57pp) but slightly lower performance on MATH-500 compared to the base model. This is expected as the training focused on GSM8K-style problems.
For deployment with llama.cpp, Ollama, or other GGUF-compatible runtimes:
| File | Size | Description |
|---|---|---|
| qwen3-1.7b-gsm8k-q8_0.gguf | 1.8 GB | 8-bit quantized (recommended) |
| qwen3-1.7b-gsm8k-f16.gguf | 3.3 GB | Full FP16 precision |
# Download and run
ollama run hf.co/HuggingFaceTB/qwen3-1.7b-gsm8k-sft:q8_0
# Download the GGUF file
huggingface-cli download HuggingFaceTB/qwen3-1.7b-gsm8k-sft qwen3-1.7b-gsm8k-q8_0.gguf
# Run inference
./llama-cli -m qwen3-1.7b-gsm8k-q8_0.gguf -p "Solve: If a train travels 120 miles in 2 hours, what is its average speed?"
... chain-of-thought reasoningSFTConfig(
num_train_epochs=2, # Stage 1
per_device_train_batch_size=8,
gradient_accumulation_steps=4,
learning_rate=2e-5, # 5e-6 for Stage 2
lr_scheduler_type="cosine",
warmup_ratio=0.03,
weight_decay=0.01,
max_length=1024,
packing=True,
bf16=True,
gradient_checkpointing=True,
)
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model = AutoModelForCausalLM.from_pretrained(
"HuggingFaceTB/qwen3-1.7b-gsm8k-sft",
torch_dtype=torch.bfloat16,
device_map="auto"
)
tokenizer = AutoTokenizer.from_pretrained("HuggingFaceTB/qwen3-1.7b-gsm8k-sft")
# For math problems, the model uses chain-of-thought reasoning
messages = [
{"role": "user", "content": "Natalia sold clips to 48 of her friends in April, and then she sold half as many clips in May. How many clips did Natalia sell altogether in April and May?"}
]
text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(text, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=1024, do_sample=False)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
... tags... reasoning format significantly improves math performanceTraining scripts are available in the scripts/ directory:
train_improved.py - Main training script (Stage 1)train_continued.py - Continued training script (Stage 2)evaluate.py - GSM8K evaluation scriptevaluate_math500.py - MATH-500 evaluation scriptprepare_combined_data.py - Data preparation scriptIf you use this model, please cite:
@misc{qwen3-gsm8k-sft,
title={Qwen3-1.7B Fine-tuned for GSM8K},
author={HuggingFaceTB},
year={2026},
publisher={Hugging Face},
url={https://huggingface.co/HuggingFaceTB/qwen3-1.7b-gsm8k-sft}
}
This model inherits the license from the base model Qwen/Qwen3-1.7B (Apache 2.0).
Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.
Benchmarks
As published on the model card: the maker's own numbers, not measured by AxForge.
| Task | Dataset | Metric | Score |
|---|---|---|---|
| Math Reasoning | GSM8K | Accuracy | 77.200 |
| Math Reasoning | MATH-500 | Accuracy | 55.200 |