PatientVoice is an AI-powered health communication tool built for real people — not just doctors. You describe your symptoms in plain English. It maps them against the Human Phenotype Ontology (HPO), generates a clinical differential using Groq's blazingly fast LLaMA 3.1 inference, and hands you a personalised report of exactly what to tell your doctor.
Everything is secured with Supabase Auth + Row Level Security, persisted to a Postgres backend, and exportable as a clean clinical PDF — no UI chrome, no clutter.
| Feature | Description |
|---|---|
| 🧠 Symptom Analysis | HPO-grounded clinical differentials via LLaMA 3.1 |
| 🎙️ Voice-to-Text | Dictate symptoms — microphone maps directly to input |
| 💬 Follow-up AI Chat | Iterate on your diagnosis with an embedded chat interface |
| 🫀 Body Quick-Select | Tap body zones (Head, Chest, Joints, Stomach) to tag symptoms |
| 🖨️ Clean PDF Export | Custom CSS print routing — pristine clinical printout |
| 🌙 Dark Mode | Persistent toggle via localStorage, zero flash on load |
| 📧 Forward to Doctor | Set doctor name + email in Settings → one-click email forward |
| 🔐 Secure Auth + RLS | Supabase Row Level Security — your data never leaks |
User Input → HPO Embedding → Vector Retrieval → LLaMA 3.1 (Groq) → Clinical Report → Supabase
- Ingestion — Raw symptom text from the user
- Retrieval — Semantic search against Human Phenotype Ontology embeddings
- Augmentation — Retrieved HPO terms injected into the LLM context window
- Generation — Groq LLaMA 3.1 produces structured clinical differentials
- Persistence — Report saved to Supabase Postgres with RLS
| Layer | Technology |
|---|---|
| Framework | Next.js 14 (App Router) |
| Language | TypeScript (strict mode) |
| LLM Inference | Groq API — LLaMA 3.1 |
| Knowledge Base | Human Phenotype Ontology (HPO) |
| Auth + DB | Supabase (Auth, Postgres, RLS) |
| Styling | Tailwind CSS |
| Deployment | Vercel (Edge runtime) |
# 1. Clone the repository
git clone https://github.com/Coder-015/patientvoice-ai
cd patientvoice-ai
# 2. Install dependencies
npm install
# 3. Set up environment variables
cp .env.example .env.localOpen .env.local and fill in:
NEXT_PUBLIC_SUPABASE_URL=your_supabase_project_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key
GROQ_API_KEY=your_groq_api_key# 4. Run the development server
npm run devOpen http://localhost:3000 — you're live.
patientvoice-ai/
├── app/ # Next.js App Router pages
│ ├── (auth)/ # Auth routes (login, signup)
│ ├── dashboard/ # Report history dashboard
│ ├── report/ # AI report generation + chat
│ └── settings/ # Profile, doctor connect
├── components/ # Reusable UI components
├── lib/
│ ├── supabase/ # Supabase client + types
│ ├── groq/ # LLM API helpers
│ └── hpo/ # HPO ontology retrieval
└── public/ # Static assets
Coder-015 — CS undergrads obsessed with shipping things that actually matter.
PatientVoice was designed, engineered, and deployed entirely solo. The goal was simple: health tech should feel empathetic and smart — not rigid and clinical. This project is my attempt at that.
Check out my other work on GitHub →
Disclaimer: PatientVoice is an experimental project built for informational augmentation only. It does not replace professional medical advice, diagnosis, or treatment from a qualified physician. Always consult a real doctor for medical decisions.
