AI Retraining & Fine-Tuning Pipeline
Export conversational datasets formatted for Qwen 2.5 7B, Llama 3 8B, and Unsloth LoRA fine-tuning.
Every session captures authentic Hinglish slang, awkward pauses, and cultural dating dynamics.
Export automatically excludes downvoted 👎 replies and pairs upvoted 👍 ones as DPO preference targets.
Upload the exported ChatML JSONL into Google Colab with free T4 GPU to train LoRA adapters in ~15 mins.
Deploy updated weights to WebLLM or your inference endpoint for instant improved partner responses.
⚡ Ready-to-Run Unsloth LoRA Training Code
Copy and paste this script into Google Colab with your exported pehli_mulaqat_sft_dataset.jsonl:
# Pehli Mulaqat AI Fine-Tuning Recipe (Qwen 2.5 7B Instruct via Unsloth)
!pip install "unsloth[colab-new] @ git+https://github.com/unslothai/unsloth.git"
!pip install --no-deps "xformers<0.0.27" trl peft accelerate bitsandbytes
from unsloth import FastLanguageModel
import torch
from trl import SFTTrainer
from transformers import TrainingArguments
from datasets import load_dataset
# 1. Load Pretrained Qwen 2.5 7B with 4bit quantization
model, tokenizer = FastLanguageModel.from_pretrained(
model_name = "Qwen/Qwen2.5-7B-Instruct",
max_seq_length = 2048,
load_in_4bit = True
)
# 2. Add LoRA Adapters for dating & conversation coaching persona
model = FastLanguageModel.get_peft_model(
model,
r = 16,
target_modules = ["q_proj", "k_proj", "v_proj", "o_proj", "gate_proj", "up_proj", "down_proj"],
lora_alpha = 16,
lora_dropout = 0,
bias = "none"
)
# 3. Load Pehli Mulaqat Exported Dataset
dataset = load_dataset("json", data_files="pehli_mulaqat_sft_dataset.jsonl")
# 4. Train with SFT Trainer
trainer = SFTTrainer(
model = model,
tokenizer = tokenizer,
train_dataset = dataset["train"],
dataset_text_field = "messages",
max_seq_length = 2048,
args = TrainingArguments(
per_device_train_batch_size = 2,
gradient_accumulation_steps = 4,
warmup_steps = 5,
max_steps = 60,
learning_rate = 2e-4,
fp16 = not torch.cuda.is_bf16_supported(),
bf16 = torch.cuda.is_bf16_supported(),
logging_steps = 1,
output_dir = "pehli_mulaqat_qwen7b_lora"
)
)
trainer.train()
# 5. Save fine-tuned LoRA weights
model.save_pretrained("pehli_mulaqat_partner_v1")
tokenizer.save_pretrained("pehli_mulaqat_partner_v1")
print("✅ LoRA training finished! Export weights to WebLLM or Hugging Face.")Registered Users & Saved Chats
Users who entered their Email and Mobile Number after completing a practice session to save their chat.
Conversation Sessions Inspector
Full dialogue transcripts, user choices, AI scores, and 👍/👎 RLHF reactions.
Admin Security & Credentials
Update your admin portal login password.
