The problem

An Indian OPD sees hundreds of patients a day, and the queue is first-come-first-served. A patient with chest pain waits behind a patient with a cold, because the desk sorts by arrival, not urgency. General AI chatbots answer symptom questions fluently and can hallucinate — a wrong urgency call is worse than no call.

What it does

Type symptoms in Hinglish or English. A deterministic rule engine — no model, no API, no guessing — assigns one of four colours (RED emergency now · AMBER urgent same-day · GREEN routine next slot · BLUE self-care), advises which OPD slot to take based on how crowded the OPD is, and produces a structured doctor handoff summary (symptoms verbatim, colour, matched rule, red flags, vitals, slot advice) the patient can copy, download or print. The full rule book is published on the page — every rule, keyword and advice is inspectable. Symptoms outside the corpus get an honest refusal ('cannot triage — see a clinician'), never a guessed colour.

How it works

34 written rules (English + Hinglish keywords) plus 4 combination rules (e.g. chest pain + breathlessness is an emergency even though chest pain alone is not), with explicit modifiers: duration (fever 3+ days escalates), age group (child with fever escalates), and vitals (SpO2 < 92% raises the floor). Voice input via the browser's built-in speech service; typing is the primary path. Static site, no backend, no patient data leaves the device.

Evaluation

Accuracy on our own 45-case labelled test set: 45/45 = 100% (RED 10/10, AMBER 15/15, GREEN 10/10, BLUE 5/5, UNKNOWN/refusal 5/5). The labelled set is published in the repo (corpus.js) and re-runnable with node tests/test.js. Unit tests 39/39 pass (23 triage + 16 Prevent); headless end-to-end checks 33/33 pass against the live build (desktop + mobile, zero console errors). Honest framing: this measures agreement between the engine and our own labels — a correctness check on the rule book, not a claim about real patients. The labelled set was built by us, not from real patient data. Baseline comparison: first-come-first-served queueing (the status quo this replaces) performs no urgency sorting at all; a general-purpose LLM chatbot baseline was rejected for this task because its urgency answers are non-deterministic and unauditable.

The Prevent mode shown in the demo video was evaluated with three standard personas across its metabolic, cardiovascular and sleep-stress signals: Low scores 0/0/0, Medium 53/42/28, and Red-flag 100/100/64, with the scheduler producing a dated screening plan for each.

Safety and limits

Not a diagnosis. OPD Triage Lens triages urgency for OPD flow only; it never diagnoses and never prescribes. In an emergency, call 108. The corpus covers common OPD presentations only; anything outside it is refused, not guessed. Vitals are patient-entered and unverified, and are shown as entered in the handoff.

Built by M S Abhishek, solo.

Built With

Share this project:

Updates

Submission history