A comprehensive health and wellness application that combines AI/ML technologies with modern mobile development to provide personalized health insights and medical assistance.
This application is an innovative health platform that leverages artificial intelligence and machine learning to provide users with:
- AI-Powered Health Chatbot: Intelligent medical assistance using BioBERT model
- Disease Prediction: Machine learning model for diabetes prediction
- Secure Authentication: User registration and login system
- Modern UI/UX: Clean, intuitive Flutter-based mobile interface
The application follows a hybrid architecture:
- Frontend: Flutter mobile application with cross-platform support
- Backend: Python Flask API with AI/ML capabilities
- Database: Supabase for user authentication and data storage
- AI Models: BioBERT for medical Q&A, Random Forest for disease prediction
- Secure user registration and login
- Password-based authentication via Supabase
- Session management and auto-logout
- BioBERT Integration: Uses the specialized biomedical BERT model (
dmis-lab/biobert-v1.1) - Real-time Medical Q&A: Provides accurate answers to health-related queries
- Context-Aware Responses: Fetches relevant medical information from web sources
- Reference Citations: Includes links to authoritative medical sources
- Diabetes Risk Assessment: ML model trained on medical parameters
- Input Parameters:
- Number of pregnancies
- Glucose levels
- Blood pressure
- Skin thickness
- Insulin levels
- BMI (Body Mass Index)
- Diabetes pedigree function
- Age
- Prediction Output: Risk assessment with probability scores
- Clean, responsive Flutter UI
- Cross-platform compatibility (Android, iOS, Web, Desktop)
- Intuitive navigation and user experience
- Material Design principles
- Flutter: Cross-platform mobile development
- Dart: Programming language for Flutter
- Material Design: UI/UX framework
- HTTP: API communication
- Python: Core backend language
- Flask: Web framework
- Flask-CORS: Cross-origin resource sharing
- Transformers: Hugging Face library for BioBERT
- Scikit-learn: Machine learning framework
- Pickle: Model serialization
- Requests: HTTP client for external APIs
- Supabase: Backend-as-a-Service platform
- PostgreSQL: Database (via Supabase)
- JWT: Token-based authentication
- BioBERT: Biomedical language model for Q&A
- Random Forest: Disease prediction model
- SerpAPI: Web search integration for medical context
lib/
βββ main.dart # App entry point and routing
βββ home_page.dart # Dashboard with navigation
βββ login_page.dart # User authentication
βββ signup_page.dart # User registration
βββ chatbot_page.dart # AI medical chatbot interface
βββ ml_model_page.dart # Disease prediction form
βββ profile_page.dart # User profile management
βββ app.py # Flask backend API
βββ BIO_GPT.ipynb # Model training notebook
βββ random_forest_model.pkl # Trained ML model
- Flutter SDK (>=3.4.3)
- Python 3.8+
- Supabase account
- SerpAPI account (for web search functionality)
-
Clone the repository
git clone <repository-url> cd health
-
Install Flutter dependencies
flutter pub get
-
Install Python dependencies
pip install -r requirements.txt
-
Environment Setup Create a
.envfile in the root directory:SUPABASE_URL=your_supabase_url SUPABASE_ANON_KEY=your_supabase_anon_key SERPAPI_KEY=your_serpapi_key
-
Run the Backend API
python app.py
-
Run the Flutter App
flutter run
- Create a new Supabase project
- Set up authentication with email/password
- Add your Supabase URL and anon key to the
.envfile
- Sign up for a SerpAPI account at https://serpapi.com
- Get your API key from the dashboard
- Add the
SERPAPI_KEYto your.envfile
- Model:
dmis-lab/biobert-v1.1 - Purpose: Medical question answering
- Features: Context-aware responses, reference citations
- Max Length: 512 tokens
- Algorithm: Random Forest Classifier
- Features: 8 medical parameters
- Output: Binary classification (diabetic/non-diabetic) with probabilities
- Accuracy: Trained on standard diabetes dataset
- Secure user authentication via Supabase
- Environment variable protection for sensitive keys
- CORS configuration for API security
- Input validation and error handling
- Session management with automatic logout
- Purpose: Medical chatbot interaction
- Input:
{"message": "user_query"} - Output: AI response with references
- Purpose: Disease prediction
- Input: Medical parameters array
- Output: Prediction result with probability
- Responsive Design: Adapts to different screen sizes
- Material Design: Follows Google's design principles
- Intuitive Navigation: Easy-to-use interface
- Loading States: Visual feedback during API calls
- Error Handling: User-friendly error messages
- Frontend Development: Flutter for cross-platform mobile app
- Backend Development: Python Flask for AI/ML APIs
- Model Training: Jupyter notebooks for ML model development
- Testing: Comprehensive testing for both frontend and backend
- Deployment: Cloud deployment with CI/CD pipeline
- Additional ML models for different diseases
- Integration with wearable devices
- Telemedicine consultation features
- Personalized health recommendations
- Health data visualization
- Multi-language support
- Offline mode capabilities
This project is part of BITS CSA (Computer Science and Applications) coursework and is intended for educational purposes.
This is an academic project. For any suggestions or improvements, please reach out to the development team.
For technical support or queries related to this project, please contact the development team through the appropriate academic channels.
This application represents the intersection of healthcare technology and artificial intelligence, demonstrating how modern mobile development can be combined with advanced AI/ML models to create meaningful health solutions.