cd /news/large-language-models/how-i-engineered-the-world-s-first-k… · home topics large-language-models article
[ARTICLE · art-125681] src=dev.to ↗ pub= topic=large-language-models verified=true sentiment=↑ positive

How I Engineered the World's First Khattak Pashto LLM (Qwen2 + LoRA)

Software engineer Muhammad Zubair built Khatta-ka-LLM, which he describes as the first AI language model fine-tuned specifically for the Khattak Pashto dialect spoken in Pakistan's Karak, Nowshera, and Kohat regions. Using Qwen2 with LoRA and the Unsloth framework, he curated a custom dataset of more than 2,000 English-to-Khattak pairs and engineered dialect-specific grammatical rules into the model's training weights. The project aims to bridge modern AI infrastructure with regional linguistic heritage for low-resource languages.

by read2 min views1 publishedSep 10, 2026

Standard Large Language Models (LLMs) are incredible, but they have a massive blind spot: rural and regional dialects.

While standard Pashto is supported by some models, they completely fail to capture the rich, localized grammar of the Khattak dialect spoken in Karak, Nowshera, and Kohat (Pakistan). To solve this, I built Khatta-ka-LLM—the world's first AI language model fine-tuned specifically for the Khattak (Khatak) dialect.

(Note: You can read the original architectural breakdown on my Software Engineering Portfolio or test the model live below). Watch the Live Testing Video:

As a Software Engineer specializing in AI Infrastructure, my focus was on creating a clean, scalable, and reproducible pipeline for low-resource languages. Here is how I built it:

Because no dataset existed for this dialect, I curated a custom dataset of 2,000+ English-to-Khattak pairs. This represents the first digitized collection of Khattak linguistic markers, focusing heavily on the unique grammar used in the Karak and Kohat regions.

To achieve high performance on consumer-grade hardware, I utilized the following stack:

To ensure the AI didn't just speak "standard Pashto with a Khattak accent," I had to engineer specific linguistic rules into the model's training weights.

Here are a few of the core rules the model learned:

In the Khattak dialect, first-person verbs end in a nasal Noon Ghunna (ں) rather than the standard "M".

The model successfully converts standard "A" sounds to the deep Khattak "O":

By focusing on high-quality, localized data, Khatta-ka-LLM successfully translates English into pure Khattak Pashto. As a Software Engineer from Pakistan, my goal is to bridge the gap between modern AI infrastructure and regional linguistic heritage. We shouldn't have to lose our dialects to use modern technology.

I would love to hear your thoughts on fine-tuning models for low-resource languages! Have you worked with Unsloth or LoRA recently? Let me know in the comments. 👇

I am Muhammad Zubair, a Software, DevOps, and Platform Engineer from Pakistan. I specialize in architecting scalable AI infrastructure, cloud platforms (AWS/Kubernetes), and full-stack systems.

My passion lies in solving real-world problems through code, whether that's building real-time mobility radars for the visually impaired or preserving regional languages through AI.

🔗 Let's Connect:

── more in #large-language-models 4 stories · sorted by recency
── more on @muhammad zubair 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/how-i-engineered-the…] indexed:0 read:2min 2026-09-10 ·