Downloads · 30 days
0
umaico/qwen3-gsm8k-lora
qwen3-gsm8k-lora is a machine learning model from umaico. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This is a Qwen3-0.6B model fine-tuned on GSM8K math problems using LoRA (Low-Rank Adaptation).
Downloads · 30 days
0
Access
Public
Updated Sep 4, 2025
Repo size
643 MB
Likes
0
Public
Click a slice to open those files.
.safetensors643 MB · 100%
From the Hugging Face model README
This is a Qwen3-0.6B model fine-tuned on GSM8K math problems using LoRA (Low-Rank Adaptation).
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import PeftModel
# Load base model and tokenizer
tokenizer = AutoTokenizer.from_pretrained("Qwen/Qwen3-0.6B")
base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3-0.6B")
# Load LoRA adapter
model = PeftModel.from_pretrained(base_model, "your-username/qwen3-gsm8k-lora")
# Generate response
question = "Tom has 12 apples. He ate 5. How many are left?"
messages = [{"role": "user", "content": question}]
text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer([text], return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=200)
response = tokenizer.decode(outputs[0][len(inputs.input_ids[0]):], skip_special_tokens=True)
print(response)
The model shows step-by-step reasoning for basic math problems, though improvements over the base model are limited due to the base model's existing mathematical capabilities.