Skip to content

twopranav/MedAI-Assistant-Langflow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MedAI - Chronic Disease Predicting Assistant 🩺

MedAI is a personal health assistant powered by Langflow and Streamlit. It uses an advanced AI agent hosted on DataStax Astra DB to analyze user symptoms and health data, providing preliminary insights and predictions regarding chronic conditions.

The application features a modern, medical-themed UI with a dynamic "Hero-to-Chat" interface that adapts as you interact with it, ensuring a professional and reassuring user experience.


🚀 Features

  • Intelligent Analysis: Powered by a custom Langflow agent running on DataStax Astra DB.
  • Dynamic UI: Starts as a search-engine style "Hero" interface and seamlessly transitions to a scrollable chat interface upon interaction.
  • Medical Aesthetics: Clean, reassuring design with glassmorphism effects, medical color palettes (Teal/Blue/White), and professional typography.
  • Secure: Uses Streamlit Secrets management to protect sensitive API keys.
  • Real-time Interaction: Instant responses to health queries and symptom descriptions.

🛠️ Installation & Setup

Follow these steps to run MedAI locally on your machine.

1. Clone the Repository

Open your terminal and run:

git clone [https://github.com/YOUR_USERNAME/medai-assistant.git](https://github.com/YOUR_USERNAME/medai-assistant.git)
cd medai-assistant

2. Create a Virtual Environment (Recommended)

It is best practice to run Python apps in a virtual environment to avoid conflicts.

# Windows
python -m venv venv
venv\Scripts\activate

# Mac/Linux
python3 -m venv venv
source venv/bin/activate

3. Install Dependencies

Install the required Python packages listed in requirements.txt:

pip install -r requirements.txt

4. Set Up API Secrets 🔐

Important: This app requires a Langflow API Token to function. For security, this token is not stored in the code. You must set it up locally.

  1. Create a folder named .streamlit in the root directory of the project.
  2. Inside that folder, create a file named secrets.toml.
  3. Add your token inside the file:
# .streamlit/secrets.toml
LANGFLOW_TOKEN = "Your_AstraCS_Token_Here"

(Note: If you are deploying to Streamlit Cloud, add this secret in the "Advanced Settings" of your dashboard).

5. Run the App

Launch the application:

streamlit run app.py

The app will open automatically in your default browser at http://localhost:8501.


📂 Project Structure

medai-assistant/
├── app.py                 # The main Streamlit application logic and UI
├── requirements.txt       # List of Python dependencies
├── .gitignore             # Config to keep secrets and system files out of GitHub
├── .streamlit/            # Streamlit configuration folder
│   ├── config.toml        # UI Theme configuration (Light mode force)
│   └── secrets.toml       # API Keys (Local only - DO NOT COMMIT)
└── README.md              # Project documentation


🔧 Technologies Used


⚠️ Disclaimer

MedAI is an AI prototype designed for educational and informational purposes only.

It is not a substitute for professional medical advice, diagnosis, or treatment. Always seek the advice of your physician or other qualified health provider with any questions you may have regarding a medical condition. Never disregard professional medical advice or delay in seeking it because of something you have read on this application.


About

AI-powered chronic disease predictor built with Langflow & Streamlit.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages