Downloads · 30 days
88
40% of all-time downloads
wesjos/GRPO-SFT-Qwen3-4B-Base-math
GRPO-SFT-Qwen3-4B-Base-math is a text generation model from wesjos. Use it when you need the model to write or continue text. It is set up for transformers.
- this model was first SFT on openmath-mini dataset from Qwen3-4B-Base - then GRPO on the same openmath-mini dataset again - arc: 0.91 - ifeval: 0.86 - race: 0.91 - amc: 0.70 - competitionmath: 0.92 - gsm8k: 0.90 - ma…
Downloads · 30 days
88
40% of all-time downloads
All-time downloads
222
Public
Parameters
4B
2.7 GB on disk
Likes
1
Trending 1
Click a slice to open those files.
.safetensors2.7 GB · 99%
How the weights are stored.
U83.6B · 90%
From the Hugging Face model README
from transformers import AutoModelForCausalLM, AutoTokenizer,TextStreamer
model_name='wesjos/GRPO-SFT-Qwen3-4B-Base-math'
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(
model_name,
device_map="auto",
)
system_prompt="你是一个友善并且擅长解决问题的助手,请根据我的提问,给出专业的回答。"
prompt='帮我写一个python的强化学习玩2048的代码'
messages = [
{'role':'system',"content":system_prompt},
{"role": "user", "content": prompt}
]
streamer= TextStreamer(tokenizer)
text = tokenizer.apply_chat_template(
messages,
tokenize=False,
add_generation_prompt=True,
)
model_inputs = tokenizer([text], return_tensors="pt",add_special_tokens=True,
).to(model.device)
outputs = model.generate(
**model_inputs,
max_new_tokens=4096,
streamer=streamer,
)