Downloads · 30 days
10
28% of all-time downloads
AsifZaman1912/ChatgaiyyaLM-0.5B
ChatgaiyyaLM-0.5B is a text generation model from AsifZaman1912. 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.
[!IMPORTANT] Superseded. Use ChatgaiyyaLM-0.5B-B2subsetctgsylbn instead — 65.64 chrF on Chittagonian→Bangla against this adapter's 35.66, trained jointly with Sylheti and standard Bangla and uploaded without the lossy…
Downloads · 30 days
10
28% of all-time downloads
All-time downloads
36
Public
Repo size
1.7 GB
Likes
0
Public
Click a slice to open those files.
.safetensors1.7 GB · 99%
From the Hugging Face model README
[!IMPORTANT] Superseded. Use ChatgaiyyaLM-0.5B-B2_subset_ctg_syl_bn instead — 65.64 chrF on Chittagonian→Bangla against this adapter's 35.66, trained jointly with Sylheti and standard Bangla and uploaded without the lossy repackaging step described below.
LoRA adapter adapting Qwen/Qwen2.5-0.5B to Chittagonian (চাটগাঁইয়া), a Bangla dialect
spoken by tens of millions of people with almost no NLP resources.
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel
REPO = "AsifZaman1912/ChatgaiyyaLM-0.5B"
tok = AutoTokenizer.from_pretrained(REPO)
model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen2.5-0.5B", dtype=torch.float16)
model.resize_token_embeddings(len(tok)) # REQUIRED: adapter adds 3,914 tokens
model = PeftModel.from_pretrained(model, REPO).eval()
prompt = "চাটগাঁইয়া থেকে প্রমিত বাংলায় অনুবাদ করো:\nঅ্যাঁই ভাত ন হাইয়্যুম\nঅনুবাদ:"
ids = tok(prompt, return_tensors="pt")
out = model.generate(**ids, max_new_tokens=64, do_sample=False)
print(tok.decode(out[0][ids["input_ids"].shape[1]:], skip_special_tokens=True))
Load the tokenizer from this repo. Token ids were assigned in insertion order, so a tokenizer rebuilt from elsewhere silently misaligns every added token.
chrF on the gold translation track of ChatgaiyyaBench, 120 fixed-seed items per direction.
| System | ctg → bn | bn → ctg |
|---|---|---|
| base Qwen2.5-0.5B, no adaptation | 20.54 | 19.77 |
| copy the input unchanged | 29.51 | 28.79 |
| this adapter (independently re-measured) | 35.66 | 24.10 |
| rule transducer, no GPU | — | 57.94 |
| the same arm, as measured on the training run | 58.46 | 52.63 |
The last two rows are the honest part.
The adapter still clears both meaningful baselines — the unadapted model (20.54) and copying the input (29.51) — so it is a working dialect adapter, just not as strong as the training run suggested. A re-trained release without the lossy repackaging step is in progress.
| Adaptation | vocabulary augmentation + subset-selected continued pretraining + instruction tuning |
| CPT tokens | 7,189,504 |
| CPT loss | 2.7438 |
| SFT loss | 1.3713 |
| Wall time | 95 min on 2× Tesla T4 |
| Added vocabulary | 3,914 Chittagonian subword tokens |
| Precision | fp16+GradScaler (Tesla T4, sm_75 has no hardware bf16) |
Vocabulary augmentation cuts Chittagonian fertility from 5.722 to 2.254 tokens/word. Across five tokenizers, the more Bangla-specialised the tokenizer, the larger its dialect penalty — banglat5 has the best absolute Bangla fertility (1.054) and the worst dialect tax (+72.6%).
silver (auto-derived labels or transduced text),
awaiting native-speaker validation.@software{chatgaiyyalm,
title = {ChatgaiyyaLM: Language Adaptation and Benchmarking for Chittagonian},
author = {Asifuzzaman, A. K. M.},
year = {2026},
url = {https://github.com/A-K-M-Asifuzzaman/Chatgaiya-AI}
}