Inspiration
In many rural or disaster-hit areas, access to reliable healthcare is scarce, and internet connectivity is unreliable. What if we could give community health workers and families a "doctor in a box", an AI assistant that works entirely offline, guiding basic triage and care decisions, while always reminding users: this is not a substitute for professional care. That vision inspired Village Doctor.
What it does
Village Doctor in a Box is an offline AI health assistant. It retrieves guidance from a curated first-aid knowledge base, runs a rule-based triage engine, and answers questions in local languages, all powered by open-source models that run without internet access.
How we built it
Village Doctor is an offline medical assistant powered by open-source language models. It combines: Q&A retrieval from a curated knowledge base of first-aid and WHO/MSF guidelines.
- Rule-based triage engine for common conditions like fever, dehydration, or cough.
- Mobile app UI (Expo React Native) so health workers can quickly ask in local languages.
- Offline inference via gpt-oss models (served by Ollama / llama.cpp), so it runs without internet access.
The project demonstrates how AI can be localized, offline, and life-saving, even in places far from hospitals.
Challenges we ran into
- Model size vs. latency: larger models (20B) gave higher quality but were too slow on CPU-only devices. We balanced with quantized 7B/8B models.
- Deployment portability: building Docker + Compose to run both the model server and the API reliably.
- Mobile networking: ensuring Expo apps could talk to the backend via LAN IPs (not localhost).
- Safety: keeping the AI's tone cautious, adding disclaimers, and restricting knowledge base content to vetted first-aid sources.
Accomplishments that we're proud of
- Built a full end-to-end system: FastAPI backend, Expo mobile app, FAISS retrieval, and Ollama-served LLMs.
- Made the assistant work completely offline, even after disconnecting Wi-Fi during demos.
- Integrated safety features: mandatory disclaimers, escalation rules, and restricted knowledge base to reduce misuse.
- Achieved a working triage prototype in just a hackathon timeframe, showing practical impact.
What we learned
- How to integrate open-weight models (GGUF / gpt-oss) with a FastAPI backend and mobile frontend.
- How to design AI assistants with safety disclaimers, retrieval grounding, and rule-based escalation.
- That offline deployment is both challenging and rewarding, performance tuning, quantization, and context management matter a lot.
What's next for Village Doctor in a Box
- Expand the knowledge base with multilingual content (WHO, MSF, UNICEF) and local translation.
- Improve triage coverage with more symptoms and validated decision trees.
- Add voice I/O (speech-to-text and text-to-speech) for low-literacy users.
- Package as a Dockerized "box" or Android APK so NGOs and rural clinics can deploy instantly.
- Explore lightweight quantized models for smoother performance on low-power devices.
Built With
- curl
- expo.io
- faiss
- faiss-index
- github-actions-for-testing
- gpt-oss:20b
- httpx-ai-models:-gpt-oss:20b-(via-ollama)-+-quantized-gguf-instruct-models-(mistral
- javascript/typescript-frameworks-&-libraries:-fastapi
- llama-3.1)-infrastructure-&-tools:-backend:-fastapi
- ollama
- phi-3
- python
- python-rules-engine-frontend:-expo-react-native-mobile-app-model-serving:-ollama-/-llama.cpp-server-containerization:-docker-&-docker-compose-for-full-stack-other:-markdown-kb-documents
- react-native
- react-native-(expo)
- sentencetransformers

Log in or sign up for Devpost to join the conversation.