Abhinandan Pandey , public record

case 02 2026 · Shipped · beta

CareAI

A lab report shouldn't require a medical degree to read.

Role

Concept, pipeline, prompt system, frontend

Stack

Gemini API · NLP pipeline · Structured output parsing · FastAPI · Vercel

Year

2026

Links

01 , The problem

In India, lab reports are usually handed straight to the patient. No clinician walkthrough, no translation layer , just a PDF full of abbreviations, reference ranges and clinical shorthand, and a person at home trying to decide whether to panic.

So people do what people do: they Google 'high MCHC meaning' at midnight and land somewhere between an ad and a horror story. The information exists; the comprehension doesn't.

CareAI's job is narrow on purpose: take a report, and return what it says in plain language , what's normal, what stands out, and what's worth asking a doctor. Zero assumed medical literacy. Zero diagnosis.

02 , Research & framing

I read real (anonymized) reports and plain-language health guidelines, and the first real insight was about risk, not features: the dangerous failure mode isn't a wrong number, it's hallucinated reassurance. A system that says 'this is fine' when it isn't is worse than no system.

That inverted the design. Instead of asking the LLM to 'explain this report', the pipeline extracts and classifies biomarkers first, deterministically where reference ranges allow it, and only then asks the model to put language around values it has actually been given.

The second insight: 'simple' is measurable. I iterated prompts against a reading-level target and a read-it-aloud test , if a sentence sounded like a doctor covering themselves legally, it went back in the loop.

03 , Architecture

Unstructured report text goes through an extraction and classification pass that pulls out biomarkers, values and reference ranges, and flags anything outside range. Only that structured data reaches the Gemini prompt , the model writes language around known values instead of free-associating over a raw document.

The output is parsed back into fixed sections: what this report is, what looks typical, what stands out and why, and questions worth taking to a doctor. Structure in, structure out , prose only in the middle.

Pipeline , structure in, structure out, prose only in the middle
Report text unstructured Extraction biomarkers + ranges Flagging out-of-range · deterministic Gemini grounded on extracted values structured data only 4 sections fixed output parse never diagnoses , enforced in generation, not disclaimed

04 , Engineering decisions

D1 , Extract first, explain second

A deterministic extraction layer feeds the LLM, instead of handing it the raw report.

Because

Grounding the model on extracted values is the strongest hallucination control I had. It can't misread a number it was explicitly given.

The trade

Extraction from messy real-world formats is its own hard problem, and unsupported formats fail early. I chose loud failure over confident nonsense.

D2 , Not a diagnostic tool , enforced, not disclaimed

The prompt system is built to explain and flag, never to diagnose or reassure; the UI repeats it.

Because

A disclaimer at the bottom of a page protects nobody. The constraint had to live in the generation itself: 'worth asking your doctor about' instead of 'you have X' or 'don't worry'.

The trade

Some users want the tool to just tell them they're fine. It refuses on purpose. That's the product working.

D3 , Fixed output sections over free-form summaries

Every report renders into the same four sections, parsed from structured output.

Because

Predictable structure is comprehension. A frightened reader shouldn't also have to navigate a new layout every time.

The trade

Occasionally a report has content that fits the sections badly. I'd still rather bend the content than the structure.

D4 , Plain language as a hard requirement

Prompts iterate against reading-level and jargon checks, not just 'be simple'.

Because

'Explain simply' produces simpler jargon. Targeting an actual literacy level , and banning specific terms unless immediately explained , produced text my non-technical family could read.

The trade

Precision occasionally suffers; 'red blood cells are slightly low' loses nuance a hematologist would keep. The target reader isn't a hematologist.

05 , What fought back

Real reports are chaos

Every lab formats differently , different units, different reference ranges, tables that aren't tables. The extraction layer went through more rewrites than any other part of the system, and taught me why 'data cleaning' is most of applied ML.

Tone is a safety feature

The same fact can be written to inform or to alarm. 'Outside the typical range' and 'abnormal result detected' carry identical information and completely different heart rates. I ended up treating tone calibration as seriously as accuracy.

Evaluating 'understandable'

Accuracy has metrics; comprehension mostly doesn't. My honest evaluation was structured but manual: readability scores, a banned-jargon list, and real humans without medical backgrounds reading outputs back to me. It worked, and it doesn't scale , which is exactly the kind of problem I want to work on next.

06 , The numbers, honestly

0

assumed medical literacy in output

2

layers: deterministic extraction + generative language

4

fixed sections in every summary

100%

of explained values grounded in extracted data

CareAI is not clinically validated and says so plainly. In a medical context, being honest about what a tool is not is part of the engineering.

07 , What it taught me

  1. 01

    In high-stakes domains, what the system refuses to say matters more than what it says.

  2. 02

    Structure beats eloquence. The fixed sections did more for comprehension than any clever prose.

  3. 03

    Constraints belong in the generation, not in the disclaimer.

08 , Where it goes next

  • OCR for scanned and photographed reports
  • Hindi and regional language output , the users who need this most don't read English lab reports
  • A clinician review mode for feedback on flagged explanations
  • Longitudinal view: the same biomarker across months of reports

Next case , /03

Review Sentiment Analyzer →