Downloads · 30 days
8
5% of all-time downloads
Nikhila15/Gita-Qwen-2B
Gita-Qwen-2B is a machine learning model from Nikhila15. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as cc-by-nc-4.0.
A LoRA fine-tune of Qwen2.5-1.5B-Instruct that responds to modern-life questions in the voice and philosophy of the Bhagavad Gita.
Downloads · 30 days
8
5% of all-time downloads
All-time downloads
157
Public
Parameters
1.5B
6.2 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors3.1 GB · 100%
From the Hugging Face model README
A LoRA fine-tune of Qwen2.5-1.5B-Instruct that responds to modern-life questions in the voice and philosophy of the Bhagavad Gita.
🤗 Model on Hugging Face: Nikhila15/Gita-Qwen-2B 🚀 Live Demo: here
This project fine-tunes a small instruction-tuned LLM so that it answers everyday questions (stress, relationships, purpose, motivation, etc.) the way the Bhagavad Gita frames them — first-person, aphoristic, rooted in concepts like detachment from outcomes, duty, and the eternal Self — instead of giving a generic AI-assistant answer.
unsloth/Qwen2.5-1.5B-Instruct, loaded in 4-bitBhagavad Gita Q&A Dataset for Modern Life Problems (Kaggle)
tokenizer.apply_chat_template() (ChatML format, matching how the base model was originally trained)SFTTrainer)r=16, lora_alpha=16, target modules = all attention + MLP projections2e-4, assistant_only_loss=True (loss computed only on the assistant's turns, not the prompt)After training, the LoRA adapter was merged into the base model (merge_and_unload / save_pretrained_merged, 16-bit) and pushed to the Hugging Face Hub as a single standalone model.
🚀 Gita-LLM Space — no setup required.
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
tokenizer = AutoTokenizer.from_pretrained("Nikhila15/Gita-Qwen-2B")
model = AutoModelForCausalLM.from_pretrained(
"Nikhila15/Gita-Qwen-2B", torch_dtype=torch.bfloat16
).to("cuda")
messages = [{"role": "user", "content": "<question>"}]
inputs = tokenizer.apply_chat_template(
messages, tokenize=True, add_generation_prompt=True,
return_tensors="pt", return_dict=True
).to("cuda")
outputs = model.generate(**inputs)
print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:], skip_special_tokens=True))
| File | Description |
|---|---|
FineTuning_Experimentation.ipynb | Full training notebook — data loading, LoRA setup, training, merging, evaluation, and HF upload |
This is a personal/educational fine-tuning experiment, not an authoritative source, and not licensed or intended for commercial use. I take no responsibility for any answers generated by this model, how they are interpreted, or any actions taken based on them.