FieldMedic is an AI-powered clinical decision support system designed to assist frontline healthcare workers by providing evidence-backed patient triage recommendations.
The system combines Retrieval-Augmented Generation (RAG), semantic search, clinical safety rules, and a Large Language Model to produce structured triage decisions.
- AI-powered patient triage
- Retrieval-Augmented Generation (RAG)
- Semantic search using Sentence Transformers
- PostgreSQL + pgvector vector database
- FastAPI backend
- Streamlit frontend
- Rule-based clinical safety layer
- Structured JSON outputs
- Knowledge ingestion pipeline
- Evaluation harness for testing
Streamlit UI
│
▼
FastAPI Backend
│
┌─────────────┴─────────────┐
▼ ▼
Retrieval Pipeline Safety Rules
│ │
└─────────────┬─────────────┘
▼
Gemini LLM Reasoner
│
▼
Structured Triage Output
▲
│
PostgreSQL + pgvector Knowledge Base
- Python
- FastAPI
- Streamlit
- PostgreSQL
- pgvector
- Docker
- Sentence Transformers
- Google Gemini API
FieldMedic/
│
├── src/
│ ├── agents/
│ ├── prompts/
│ ├── infra/
│ ├── eval/
│ └── app.py
│
├── ui/
│ └── Home.py
│
├── init/
│
├── Dockerfile
├── compose.yaml
├── requirements.txt
└── README.md
Clone the repository
git clone https://github.com/SandeepKr24/FieldMedic.git
cd FieldMedicCreate a virtual environment
python -m venv .venvInstall dependencies
pip install -r requirements.txtCreate a .env file using .env.example.
docker compose up --buildFastAPI
http://localhost:3000/docs
Streamlit
http://localhost:8501
Accepts patient symptoms and vitals and returns a structured triage recommendation.
Adds medical knowledge to the vector database.
Health check endpoint.
{
"triage": "Urgent",
"care_plan": "Immediate physician assessment and hydration.",
"icd10": [
"J18.9"
],
"summary": "Patient presents with fever and productive cough. Evidence suggests possible community-acquired pneumonia.",
"confidence": 0.92
}- Images knowledge ingestion
- Multi-provider LLM support
- Authentication
- Explainable AI citations
- Clinical audit logs
- Deployment on cloud infrastructure
MIT License


