How jayr1612/ai-internship-project-chatbot works
MedBot is a Streamlit medical-information chatbot. Users enter health questions, which the app screens for emergency keywords; non-emergency questions are sent with profile and conversation context to OpenRouter, and replies are shown and retained for chat-history export. The repository also contains standalone medical utilities for symptom and risk assessment, wellness calculations, medication information, reminders, and summaries. The README provides no architectural detail, and the sampled app excerpt does not show these utilities being invoked, so they are represented separately.
Main entry points: app.py Chat UI and flow · medical_utils.py Health assessments
Components 12
Chat application
- Chat UI and flow
app.py - Emergency screening
app.py - Profile context
app.py - Chat history export
app.py - Chatbot prompts
app.py
Medical utilities
- Health assessments
medical_utils.py - Drug information
medical_utils.py - Health outputs
medical_utils.py
AI integration
- OpenRouter client
app.py - OpenRouter API
- Models and guidance
config.py
Other components
- User
Connections 11
- User → Chat UI and flow: asks question
- Chat UI and flow → Emergency screening: screens message
- Emergency screening → Chat UI and flow: returns emergency reply
- Chat UI and flow → Profile context: adds profile context
- Chat UI and flow → Chatbot prompts: builds prompt
- Chat UI and flow → OpenRouter client: requests response
- OpenRouter client → OpenRouter API: sends messages
- OpenRouter API → OpenRouter client: returns completion
- Chat UI and flow → Chat history export: records and exports
- Chat UI and flow → User: shows reply
- Health assessments → Health outputs: generates assessments