Your intelligent, AI-powered companion for smarter, faster, and safer healthcare.
▲ Click to watch the full demo
Important Notice: This repository contains the original 2022 academic prototype of the NearestDoctor Healthcare platform.
Thank you to everyone who supported this project with stars, forks, and feedback. The V1 codebase (React/Express/Node) available here remains open-source under the Apache 2.0 license for educational purposes.
However, the project's vision has been taken forward exclusively by Ahlem Laajili and evolved into a proprietary, commercial startup.
The entire platform has been rewritten from scratch by Ahlem Laajili using a modern tech stack (Next.js, FastAPI, advanced LLMs, and cloud-native infrastructure). It is now closed-source to protect the new Intellectual Property (IP) owned solely by her. The V2 code (including the FastAPI and Next.js upgrades) will not be pushed to this repository.
If you are interested in the future of NearestDoctor, enterprise solutions, or participating in our upcoming beta, please reach out to Ahlem Laajili directly or stay tuned!
- About The Project
- Key Features
- Tech Stack
- Architecture
- Getting Started
- How It Works
- Screenshots
- Roadmap
- Achievements
- Contributing
- Team
- Acknowledgments
NearestDoctor is a full-stack, AI-powered healthcare web application that bridges the gap between patients and medical professionals. It combines machine learning, blockchain, facial recognition, and natural language processing into a seamless platform that covers the entire patient journey from first symptom to secured medical record.
💡 "Every patient deserves professional medical guidance, instantly and securely — no matter where they are."
Despite advances in digital health, patients still face three core challenges:
- 🔍 Finding the right doctor: it's hard to know which specialist fits your symptoms.
- 📆 Getting an appointment: scheduling is manual, slow, and rarely location-aware.
- 🔐 Securing medical records: records are fragmented, inaccessible, and vulnerable to breaches.
NearestDoctor was designed from the ground up to solve all three.
| Feature | Description |
|---|---|
| 🤖 AI Symptom Detection & Chatbot | Patients chat with a Dialogflow-powered bot, describe symptoms, and receive an illness prediction with the right specialist recommendation. |
| 📍 Location-Based Doctor Search | Find the nearest doctor or first available appointment in real time. |
| 📅 Smart Appointment Scheduling | Book with the nearest doctor or earliest available slot directly through the chatbot flow. |
| 🔗 Blockchain Medical Records | Patient data is stored on Ethereum using smart contracts. Every update creates a verifiable, immutable transaction block. |
| 🫁 X-Ray Lung Diagnosis | Doctors upload chest X-rays; a TensorFlow pre-trained model predicts COVID-19, tuberculosis, or pneumonia in seconds. |
| 🧠 Mental Health Test | Patients take a guided quiz to assess their mental wellbeing, then receive a result and curated article suggestions. |
| 🪪 Doctor Identity Verification | Doctors verify their real identity using a national card ID processed through the Nanonets AI OCR API before they can register. |
| 🤳 Multi-Mode Authentication | Three login options: LinkedIn OAuth, username/password, or Face ID (TensorFlow deep learning model). |
| 📰 Blogs & Web Scraping Search | Doctors publish articles; an integrated web scraping engine lets users search for external medical content by keyword. |
| 🛒 Paramedical E-Shop | ML-based patient behavioral analysis drives personalized product recommendations. |
| 🎙️ AI Voice Assistant | ALAN SDK integration lets users navigate the platform entirely by voice commands. |
| 💳 Integrated Payments | Stripe API handles doctor subscription plans and patient service payments. |
| Layer | Technology | Version |
|---|---|---|
| Frontend | React.js | v18 |
| Backend API | Node.js + Express.js | Node v16.13.1 / Express v4.17.1 |
| AI/ML Microservices | Python + Flask | Flask v2.1 |
| Database | MongoDB | v5.9.1 |
| Blockchain | Ethereum Smart Contracts | — |
| Face Recognition | TensorFlow (pre-trained deep learning model) | — |
| ID Card OCR | Nanonets AI API | — |
| Chatbot (Symptoms + Appointments) | Dialogflow | — |
| X-Ray Diagnosis | TensorFlow (pre-trained model) | — |
| Maps & Location | Google Maps API | — |
| Voice Assistant | ALAN SDK | — |
| Payments | Stripe API | — |
| OAuth | LinkedIn OAuth | — |
| Languages | JavaScript, Python, HTML5, CSS | — |
The platform follows a microservices-inspired MERN architecture:
- The React.js frontend communicates with the Node/Express REST API for core operations.
- AI features run as independent Flask microservices (symptom detection, face recognition, X-ray diagnosis, OCR, behavioral analysis).
- MongoDB stores application data users, appointments, blogs, shop inventory.
- Ethereum smart contracts handle patient medical records with immutability and permission-based access control.
- Node.js v16+ and
npmoryarn - MongoDB running locally or via a cloud URI (v5.9.1+)
- Python 3.8+ for AI/ML microservices
- Git
-
Clone the repository
git clone https://github.com/ahlem-phantom/AI-HealthCare-Assistant.git cd AI-HealthCare-Assistant -
Install Node.js dependencies
npm install # or yarn install -
Install Python dependencies (for AI services)
pip install -r requirements.txt
-
Configure environment variables
Create a
.envfile in the root directory:MONGO_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret PORT=5000 STRIPE_SECRET_KEY=your_stripe_key GOOGLE_MAPS_API_KEY=your_maps_key DIALOGFLOW_PROJECT_ID=your_dialogflow_project_id NANONETS_API_KEY=your_nanonets_key
-
Start the main development server
npm run development
-
Start Flask AI microservices (in a separate terminal)
cd py-side flask run -
Open the app at
http://localhost:3000🎉
- Select Role — choose "Patient" at the landing screen.
- Register & Log In — via username/password or LinkedIn OAuth.
- Describe Symptoms — chat with the Dialogflow AI bot; receive a specialist recommendation.
- Mental Health Check — take the guided quiz and get personalized article suggestions.
- Book an Appointment — schedule with the nearest or first-available doctor via the chatbot and Google Maps.
- Medical Records — your records are securely stored on the blockchain; grant selective access to your chosen doctors.
- Verify Identity — upload your national card ID; Nanonets OCR confirms authenticity in real time.
- Register Face ID — enroll your face using the TensorFlow model for future biometric logins.
- Choose a Plan & Pay — select a subscription tier and complete payment via Stripe.
- Log In — use LinkedIn OAuth, username/password, or a live Face ID camera scan.
- Use the Dashboard — manage appointments, write blogs, run X-ray lung diagnoses (COVID / TB / pneumonia), and access patient records via blockchain with granted permission.
-
Phase 1 — Study & Prototyping
- Problem definition, state of the art & competitive analysis
- Feasibility study, wireframes
-
Phase 2 — Design & Initial Build
- Data model & physical/logical architecture design
- Static frontend + first Node.js components
-
Phase 3.1 — Feature Implementation (V1)
- Full backend REST API
- Frontend integration with all services
- Core AI modules: symptom detection, face ID, OCR verification
-
Phase 3.2 — Finalization & Deployment (V1.5)
- X-ray diagnosis, mental health test, blockchain records
- Final integration, system testing & deployment
🎖️ NearestDoctor was selected among dozens of projects to participate in the 9th Edition Ceremony of Best Engineering Projects of 2022 at Esprit School of Engineering, Tunisia.
Contributions are welcome! Here's how to get started:
- Fork the project
- Create your feature branch
git checkout -b feature/AmazingFeature
- Commit your changes
git commit -m "Add AmazingFeature" - Push to the branch
git push origin feature/AmazingFeature
- Open a Pull Request
See open issues for ideas and known bugs. Don't forget to ⭐ star the project if you find it useful!
Built with 💕 by AlphaCoders 5 engineering students from Esprit School of Engineering, Tunisia.
Project Mentor: ameni.rommene@esprit.tn
Important: This project prototype was built in 2022 and several of its core libraries and dependencies are now outdated or deprecated. The codebase across
react-app/,server/,py side/, andblockchain/may require dependency updates or patches before it can be safely run in a modern environment.Known areas built with legacy 2022 configurations:
- React: Uses older setups without Vite.
- Node.js / Express: Some deprecated dependencies;
npm auditis recommended.- Python / Flask: AI service modules need careful version-pinning.
While we do not officially support updates to this legacy public V1 anymore (as development has moved to the V2 startup), educational forks are welcome to tweak and learn from the code!

















