Africa's gig economy telemedicine platform
# Doctors on Wheels - South Africa's Healthcare Platform
Doctors on Wheels is a hybrid Web2/Web3 healthcare platform designed for the South African market. It features real-time telehealth consultations, a "gig economy" model for healthcare providers, and autonomous agents integrated with the **Somnia Agentic L1** blockchain.
## 🚀 Key Features
- **Gig Economy for Doctors**: Doctors can toggle "Gig Mode," set custom pricing, and manage their availability.
- **On-Chain Escrow**: Patient payments are held in a Somnia smart contract and released only upon successful consultation.
- **Autonomous Agents**:
- **Appointment Matcher**: Automatically connects patients in the waiting room with available doctors.
- **Prescription Reviewer**: Uses AI (Somnia LLM Inference) to audit prescriptions for safety.
- **Follow-Up Scheduler**: Generates personalized AI follow-ups post-consultation.
- **Escrow Agent**: Manages the automated release or refund of funds on the blockchain.
- **Telehealth Suite**: Integrated video calling (Socket.io), medical records, and digital prescriptions.
- **Hybrid Storage**: Uses Supabase for structured data and Filebase (S3) for medical records/avatars.
## 🛠️ Tech Stack
- **Backend**: FastAPI (Python 3.10+)
- **Database**: SQLite (Local) / Supabase Postgres (Production)
- **Blockchain**: Somnia Agentic L1 (Testnet)
- **Real-time**: Socket.io / WebSockets
- **Frontend**: Vanilla HTML5, CSS3, and JavaScript
## 📋 Prerequisites
- Python 3.10+
- Somnia Testnet Wallet with STT tokens.
- Supabase account (optional for local SQLite dev).
## ⚙️ Setup & Installation
1. **Clone the repository**:
```bash
git clone
cd Doctors on Wheels
```
2. **Install dependencies**:
```bash
pip install -r requirements.txt
```
3. **Configure Environment**:
Create a `.env` file based on `.env.example`.
```bash
cp .env.example .env
```
Ensure you fill in the following:
- `SOMNIA_PRIVATE_KEY`: Your wallet's private key.
- `SOMNIA_ESCROW_CONTRACT`: Leave blank initially (wi …