This is a LoRA adapter fine-tuned on a dental instruction-following task using the ADA Dental Code dataset. It helps Qwen2.5-1.5B better explain dental procedure codes in plain English.
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-1.5B", trust_remote_code=True)
tokenizer = AutoTokenizer.from_pretrained("Qwen/Qwen2.5-1.5B", trust_remote_code=True)
model = PeftModel.from_pretrained(base, "BirdieByte1024/Qwen2.5-1.5B-LoRA-dental")
prompt = """### Instruction:
Explain the following dental code.
### Code:
D7140 - Extraction, erupted tooth
### Response:"""
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=100)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Qwen/Qwen2.5-1.5B to functionSame license as the base model: Apache 2.0
4 commits
This is a LoRA adapter fine-tuned on a dental instruction-following task using the ADA Dental Code dataset. It helps Qwen2.5-1.5B better explain dental procedure codes in plain English.
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
base = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-1.5B", trust_remote_code=True)
tokenizer = AutoTokenizer.from_pretrained("Qwen/Qwen2.5-1.5B", trust_remote_code=True)
model = PeftModel.from_pretrained(base, "BirdieByte1024/Qwen2.5-1.5B-LoRA-dental")
prompt = """### Instruction:
Explain the following dental code.
### Code:
D7140 - Extraction, erupted tooth
### Response:"""
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=100)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Qwen/Qwen2.5-1.5B to functionSame license as the base model: Apache 2.0
4 commits