Downloads · 30 days
5
5% of all-time downloads
RegFo/Matsuo2025-Main-Qwen3-4B-DPO-v1
Matsuo2025-Main-Qwen3-4B-DPO-v1 is a text generation model from RegFo. Use it when you need the model to write or continue text. The card lists the license as apache-2.0.
This model is a fine-tuned version of Matsuo2025-Main-Qwen3-4B-SFT-v1 using Direct Preference Optimization (DPO). The LoRA weights have been merged into the base model (16-bit).
Downloads · 30 days
5
5% of all-time downloads
All-time downloads
108
Public
Parameters
4.1B
3.6 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors3.5 GB · 100%
How the weights are stored.
U83.1B · 76%
From the Hugging Face model README
This model is a fine-tuned version of Matsuo2025-Main-Qwen3-4B-SFT-v1 using Direct Preference Optimization (DPO). The LoRA weights have been merged into the base model (16-bit).
from transformers import AutoModelForCausalLM, AutoTokenizer
import torch
model_id = "RegFo/Matsuo2025-Main-Qwen3-4B-DPO-v1"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.float16, device_map="auto")
# Test inference
prompt = "Your question here"
inputs = tokenizer.apply_chat_template([{"role": "user", "content": prompt}], tokenize=True, add_generation_prompt=True, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=512)
print(tokenizer.decode(outputs[0]))