Problem
Small shops and wholesalers in Pakistan often track stock purchases, stock arrivals, and customer credit in notebooks or informal notes. These notes may mix English, Urdu, and Roman Urdu, so entering them into a POS system by hand takes time and can leave records inconsistent. ShopNote parses a note into POS-style JSON fields such as product, quantity, unit, price, counterparty, and credit status. It is a text-to-JSON prototype; it does not itself update a live inventory ledger, and generated records need review.
Model
A QLoRA fine-tuned LoRA adapter for English, Urdu-script, and Roman Urdu notes about inventory and khata (credit) transactions.
Adapter only
This repository contains adapter weights, not the full base model. Load it on top of Qwen/Qwen3-1.7B. The adapter config points to this public base model.
Training
- Base model: Qwen/Qwen3-1.7B
- Method: 4-bit NF4 QLoRA
- Rank: 16; alpha: 32; dropout: 0.05
- Training: 3 epochs on a Google Colab Tesla T4
- Data: synthetic English, Urdu, and Roman Urdu shop notes; no real business records
- Split after duplicate-prompt removal: 819 train, 99 validation, 101 evaluation examples
Reported evaluation
On a 101-example synthetic held-out evaluation set, the notebook reported valid JSON for 101/101 and exact JSON matches for 97/101. In a separate same-15-example comparison, the base model returned valid JSON for 0/15; the fine-tuned model returned valid JSON for 15/15 and exact matches for 12/15. These small synthetic evaluations are not production reliability claims. Manual checks found errors, including invented counterparties and transaction-type mistakes. Review every record before posting it to a ledger.
Usage
Load Qwen/Qwen3-1.7B, then attach this adapter with PEFT. Local offline use requires downloading the base model and adapter files in advance. See the training notebook for training and offline-inference details:
https://www.kaggle.com/code/harisabid200/qwen-pakistan-pos-transaction-finetuning