DEV Community

noneofurbusiness
noneofurbusiness

Posted on

Udhaar Khata: The Notebook Behind the Counter

Udhaar Khata: The Notebook Behind the Counter

What I Built

In almost every kirana store in India, there is a thin notebook next to the cash box. Page after page, it records entries like Ramesh ₹500, Sita ₹300, and Amit ₹1,000 baaki. This is the udhaar khata, the informal credit ledger that small businesses use to track customer debts and repayments.

Tutors maintain similar records for pending fees, while tailors, milkmen, chemists, and neighbourhood shops rely on trust and handwritten notes to manage payments. But notebooks can get lost, amounts can be disputed, and promised payment dates can be forgotten.

Digital alternatives often introduce too much friction through signups, complicated forms, and dropdowns. They may also require customers' financial information to be stored on someone else's server.

I built Udhaar Khata, a privacy-focused digital ledger that lets users record transactions in everyday language instead of filling out forms.

For example, a shopkeeper can type:

"Ramesh ne 500 udhaar liya, 200 kal dega."

The AI interprets the sentence and extracts transaction details, including the customer, amount, transaction type, promised payment, and date. The shopkeeper reviews the proposed entry, corrects it if necessary, and confirms it before saving. Payment reminders can also be opened in WhatsApp with a pre-filled message.

The goal is to preserve the two best things about the traditional notebook—speed and privacy—while making records easier to maintain.

Who would pay for it?

My target users are kirana shop owners, tutors, tailors, milkmen, chemists, and other small businesses that maintain informal credit records. The product could follow a free or low-cost model, with potential premium features such as backups, exports, and advanced summaries. Local AI inference helps keep recurring inference costs low.

Demo

Live application: https://udhaar-khata.onrender.com

Open the application in an up-to-date version of Chrome or Edge on a device that supports WebGPU. The first visit may take longer because the AI model needs to download.

Code

GitHub repository: https://github.com/yaansa/udhaar-khata

The project is built around local AI inference, natural-language transaction parsing, and a simple interface that keeps the user in control of financial records.

How I Built It

Udhaar Khata uses an open-weight language model running directly in the browser through WebLLM and WebGPU. Instead of sending every transaction to a remote AI service, the application processes the user's input locally.

The workflow is straightforward:

  1. The user enters a transaction in everyday Hindi, Hinglish, or English.
  2. The model interprets the sentence and returns structured JSON.
  3. The application validates the output and checks for missing or malformed fields.
  4. The proposed transaction is displayed for review and editing.
  5. The entry is saved only after the user confirms it.
  6. A WhatsApp deep link can open a pre-filled payment reminder.

The application uses browser-side storage for ledger records and is hosted as a static website on Render, with the source code maintained on GitHub.

A key design decision was to avoid silently trusting the model. Financial records require care, so when parsing fails or important details are missing, the application provides an editable fallback instead of guessing.

The main challenges include interpreting colloquial Hinglish, distinguishing money lent from money repaid, understanding partial payments, and handling relative dates such as "kal" and "parso." These are important areas for further testing and improvement.

Why Does Open Innovation Matter?

Open innovation matters because privacy, affordability, flexibility, and adaptability are central to this project.

1. Privacy by design

A ledger contains sensitive information about customers, outstanding balances, and payment habits. Local inference means transaction text does not need to be sent to a third-party AI API. This reduces unnecessary data sharing and gives users greater control over their records.

2. Affordable AI for small businesses

A shopkeeper may record dozens of transactions every day. Per-request API charges could make a free or affordable product difficult to sustain. Running inference on the user's device avoids per-request AI costs, although hosting, device compatibility, and the initial model download remain practical considerations.

3. Flexibility without provider lock-in

Using open-weight models provides the flexibility to evaluate and potentially replace the model as better alternatives become available, without depending entirely on a single hosted AI provider.

4. Opportunities for domain-specific improvements

Everyday expressions such as "baaki hai," "wapas diye," and "parso dega" can be difficult for general-purpose models to interpret consistently. Open weights create opportunities to investigate domain-specific evaluation and fine-tuning using carefully prepared, privacy-conscious examples.

5. AI that supports rather than replaces human judgment

The model proposes a transaction, but the shopkeeper makes the final decision. This human-in-the-loop approach is particularly important when AI is handling financial information.

For me, open innovation is not just about using a model whose weights are available. It is about making useful AI more adaptable, affordable, and accessible to people who may not otherwise benefit from it.

My Agent Session

Udhaar Khata's main contribution is the working application and its browser-based AI workflow. I do not have a DevRelay agent-session link to share in this submission, so I am leaving this optional section out.

Prize Categories

Open-Source AI / Open-Weight Models: Udhaar Khata uses an open-weight language model through browser-based inference with WebLLM and WebGPU.

Side Hustle: The project addresses a practical problem faced by small businesses and explores a free or low-cost product model built around local AI inference.

What's Next?

I would like to improve Udhaar Khata with Hindi voice input, better handling of colloquial Hinglish, domain-specific model evaluation, reliable export and backup, and a summary view showing outstanding balances.

Local-first storage also introduces an important limitation: records may be lost if the device is lost or browser data is cleared. A reliable backup feature will be essential for making the application more practical for everyday use.

The broader idea behind this project is simple: some of the most useful tools are built around habits people already trust. The traditional udhaar notebook works because it is immediate and personal. Digitising it should not require complicated workflows or unnecessary data sharing.

With Udhaar Khata, I wanted to explore how a small open-weight model can make an everyday task easier without taking control away from the person using it.

Top comments (0)