Educational DPO pilot trained for 50 optimizer steps on Intel/orca_dpo_pairs.
This repository contains the LoRA adapter, not the full base model. The validation preference accuracy was about 97.8%; this is a pair-ranking metric, not a measure of factual correctness. The pilot had mixed generation results and has not been thoroughly evaluated.
Load the adapter with the base model:
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
import torch
base_id = "Qwen/Qwen2.5-0.5B-Instruct"
adapter_id = "Aeroalrza/qwen25-05b-orca-dpo-pilot"
tokenizer = AutoTokenizer.from_pretrained(adapter_id)
base = AutoModelForCausalLM.from_pretrained(
base_id, dtype=torch.float16, device_map="auto"
)
model = PeftModel.from_pretrained(base, adapter_id)
checkpoint-50/optimizer.pt 35 MBcheckpoint-50/ref/adapter_model.safetensors 35 MBref/adapter_model.safetensors 35 MBadapter_model.safetensors 18 MBcheckpoint-50/adapter_model.safetensors 18 MBcheckpoint-50/rng_state.pth 14.6 kBcheckpoint-50/training_args.bin 5.8 kBtraining_args.bin 5.8 kBcheckpoint-50/scheduler.pt 1.5 kBQwen/Qwen2.5-0.5B-Instruct