Downloads · 30 days
0
vishnuamarapu/Full-Fine-Tuning-Qwen-2.5-0.5B-tuned-prompts
Full-Fine-Tuning-Qwen-2.5-0.5B-tuned-prompts is a machine learning model from vishnuamarapu. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This repository contains a Prompt Tuning (PEFT) adapter trained on top of my Supervised Fine-Tuned (SFT) personalized Qwen model.
Downloads · 30 days
0
Access
Public
Updated Jun 26, 2026
Repo size
11.5 MB
Likes
0
Public
Click a slice to open those files.
.json11.4 MB · 99%
From the Hugging Face model README
This repository contains a Prompt Tuning (PEFT) adapter trained on top of my Supervised Fine-Tuned (SFT) personalized Qwen model.
The adapter learns a set of virtual prompt embeddings while keeping the underlying language model completely frozen. It is designed to personalize the model for answering questions about Vishnu Amarapu.
Note: This repository does not contain the full model weights. It only contains the learned prompt embeddings and must be loaded together with the corresponding SFT model.
This adapter was trained on the following SFT model:
BASE_MODEL = "vishnuamarapu/Full-Fine-Tuning-Qwen-2.5-0.5B-instruct-sft"
Do not use the original Qwen/Qwen2.5-0.5B-Instruct model, as the prompt embeddings were optimized specifically for the fine-tuned SFT model.
pip install -U transformers peft accelerate torch
import torch
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import PeftModel
BASE_MODEL = "vishnuamarapu/Full-Fine-Tuning-Qwen-2.5-0.5B-instruct-sft"
PROMPT_ADAPTER = "vishnuamarapu/Full-Fine-Tuning-Qwen-2.5-0.5B-tuned-prompts"
tokenizer = AutoTokenizer.from_pretrained(BASE_MODEL)
model = AutoModelForCausalLM.from_pretrained(
BASE_MODEL,
device_map="auto",
torch_dtype="auto"
)
model = PeftModel.from_pretrained(
model,
PROMPT_ADAPTER
)
messages = [
{
"role": "system",
"content": (
"You are Vishnu's personal AI assistant. "
"Answer questions about Vishnu."
)
},
{
"role": "user",
"content": "What is your name?"
}
]
text = tokenizer.apply_chat_template(
messages,
tokenize=False,
add_generation_prompt=True
)
inputs = tokenizer(
text,
return_tensors="pt"
).to(model.device)
outputs = model.generate(
**inputs,
max_new_tokens=80,
do_sample=False
)
response = tokenizer.decode(
outputs[0],
skip_special_tokens=True
)
print(response)
adapter_config.json
adapter_model.safetensors
tokenizer.json
tokenizer_config.json
chat_template.jinja
training_args.bin
The repository stores only the prompt tuning adapter, making it lightweight and efficient to distribute.
This adapter is intended for:
Please refer to the license of the underlying Qwen model and ensure compliance with its terms when using this adapter.