Downloads · 30 days
5
12% of all-time downloads
fkarnagi/bababoi_test
bababoi_test is a text generation model from fkarnagi. Use it when you need the model to write or continue text. It is set up for peft. The card lists the license as apache-2.0.
A fine-tuned version of TinyLlama/TinyLlama-1.1B-Chat-v1.0 using LoRA (Low-Rank Adaptation) on a small instruction-following dataset.
Downloads · 30 days
5
12% of all-time downloads
All-time downloads
42
Public
Repo size
50.5 MB
Likes
0
Public
Click a slice to open those files.
.safetensors50.5 MB · 93%
From the Hugging Face model README
A fine-tuned version of TinyLlama/TinyLlama-1.1B-Chat-v1.0 using LoRA (Low-Rank Adaptation) on a small instruction-following dataset.
| Property | Value |
|---|---|
| Base Model | TinyLlama/TinyLlama-1.1B-Chat-v1.0 |
| Fine-tuning Method | LoRA (Low-Rank Adaptation) |
| LoRA Rank | 16 |
| LoRA Alpha | 16 |
| Trainable Parameters | ~12.6M (1.13% of total) |
| Dataset Size | 20 instruction-following examples |
| Training Epochs | 10 |
| Learning Rate | 2e-4 |
| Hardware | Apple M4 GPU (MPS) |
This model was trained on a tiny Alpaca-format dataset covering basic factual Q&A, grammar, translation, and simple arithmetic. It is intended as a tutorial/demo for learning fine-tuning workflows rather than production use.
train.py — Python training script with LoRA + HuggingFace Trainerinference.py — Interactive inference scripttrain_cli.sh / infer_cli.sh — Shell wrappersfrom peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer
base_model = "TinyLlama/TinyLlama-1.1B-Chat-v1.0"
adapter = "fkarnagi/bababoi_test"
model = AutoModelForCausalLM.from_pretrained(base_model, torch_dtype="auto")
model = PeftModel.from_pretrained(model, adapter)
tokenizer = AutoTokenizer.from_pretrained(adapter)
prompt = "What is the capital of France?"
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=64)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))