Omar Elshaer · Portfolio

Doctorly

AI Healthcare Platform · 2025

Arabic-first healthcare portal that combines AI symptom triage, provider discovery, appointment booking, and role-based care coordination in one place.

Built with Python, Flask, SQLAlchemy, Groq API, SQLite/MySQL, Vanilla JavaScript

Project Overview

Doctorly is a web platform for symptom intake, doctor discovery, appointment booking, and consultation messaging. It serves patients, doctors, and admins through a Flask REST API with static HTML pages.

The system reduces the friction of finding care by keeping chat history, profile data, provider search, bookings, and medical uploads in one workflow. That gives users a faster path from first symptoms to a usable doctor match or scheduled visit.

Core Features

  • Email/password registration and login with role-based redirects.
  • Arabic AI medical chat with streamed answers, saved conversation history, and an archive of prior chats.
  • Quick symptom chips and a nearby-doctor shortcut inside the chat screen.
  • Doctor search by name, specialty, and location, with geolocation radius filtering, distance sorting, ratings, and map links.
  • Start a consultation from a doctor card and continue a two-way consultation thread with messaging.
  • Book appointments with optional notes and review upcoming visits.
  • Edit the patient health profile, upload an avatar image, and manage PDF medical reports.
  • Doctor views for appointments and consultations, plus admin tools for creating doctors, editing users, and removing ratings.

Technical Highlights

  • JWT bearer authentication with role-aware access control on patient, doctor, and admin endpoints.
  • Conversation memory is persisted in chat messages and extracted into structured symptom slots for follow-up questioning.
  • The assistant supports both streaming and non-streaming Groq responses with a fallback path when streaming is unavailable.
  • Provider ranking can factor in distance using Haversine calculations and optional radius limits.
  • SQLAlchemy models link users, profiles, doctors, appointments, consultations, ratings, reports, and consultation messages with unique constraints where needed.
  • Avatar and report uploads are handled per user with secure filenames and server-side file storage.