Views
No views yet
unsloth/Qwen2.5-1.5B-Instruct (4-bit Unsloth bundle: unsloth/qwen2.5-1.5b-instruct-unsloth-bnb-4bit)peft), saved from training/sft_warmup.py1import torch
2from transformers import AutoModelForCausalLM, AutoTokenizer
3from peft import PeftModel
4
5base_model_id = "unsloth/Qwen2.5-1.5B-Instruct"
6adapter_id = "HardikJha/extractor-aea"
7
8tokenizer = AutoTokenizer.from_pretrained(adapter_id, trust_remote_code=True)
9
10base = AutoModelForCausalLM.from_pretrained(
11 base_model_id,
12 torch_dtype=torch.float16,
13 device_map="auto",
14 trust_remote_code=True,
15)
16model = PeftModel.from_pretrained(base, adapter_id)training/prompts.py)training/sft_warmup.py)1@misc{vonwerra2022trl,
2 title = {{TRL: Transformer Reinforcement Learning}},
3 author = {Leandro von Werra and Younes Belkada and Lewis Tunstall and Edward Beeching and Tristan Thrush and Nathan Lambert and Shengyi Huang and Kashif Rasul and Quentin Gallou{\'e}dec},
4 year = 2020,
5 journal = {GitHub repository},
6 publisher = {GitHub},
7 howpublished = {\url{https://github.com/huggingface/trl}}
8}