← Open Source
souvikmajumder26

Multi-Agent-Medical-Assistant

βš•οΈGenAI powered multi-agentic medical diagnostics and healthcare research assistance chatbot. πŸ₯ Designed for healthcare professionals, researchers and patients.

ApplicationsWrappersPython
Open on GitHub
Momentum
+0stars in 24 hours0.0%
991
Stars
210
Forks
+6
This week
1
Contributors
Created 2025-03-10 Β· Updated 2026-10-14 Β· #12198 today
Top developers

souvikmajumder26/Multi-Agent-Medical-Assistant is ranked 12,198 with 991 stars.

Same-category comparison

souvikmajumder26/Multi-Agent-Medical-Assistant is ranked 12,198 among these 8 peers; TypingMind/typingmind is ranked 12,201.

Same-category comparison
NameRankMetrics
Ayush0Chaudhary/blurr12,178
Language:
Kotlin
Stars:
993
Forks:
159
Description:
This app can now use Android, just like a human.
srikanth235/privy12,181
Language:
TypeScript
Stars:
993
Forks:
51
Description:
An open-source alternative to GitHub copilot that runs locally.
callstackincubator/cali12,191
Language:
TypeScript
Stars:
991
Forks:
58
Description:
AI agent for building React Native apps.
dzoba/gptrpg12,193
Language:
JavaScript
Stars:
991
Forks:
106
Description:
A demo of an GPT-based agent existing in an RPG-like environment.
TypingMind/typingmind12,201
Language:
HTML
Stars:
990
Forks:
364
Description:
The most advanced Web UI for AI chat.
run-llama/chat-llamaindex12,205
Language:
TypeScript
Stars:
990
Forks:
272
MichelNivard/gptstudio12,210
Language:
R
Stars:
989
Forks:
115
Description:
GPT RStudio addins that enable GPT assisted coding, writing & analysis.
51bitquant/binance_grid_trader12,234
Language:
Python
Stars:
984
Forks:
298
Description:
Binance_grid_trader is a grid strategy bot trading with Binance Spot and Binance Futures Exchange. you can use it to trade any pair in Binance Exchange.
Key parameters and specifications
Key parameters and specifications
ParameterValue
LanguagePython
CategoryApplications
SubcategoryWrappers
KeywordsBiomedical, Medical
Stars991
Forks210
Contributors1
Created date2025-03-10
Updated date2026-10-14
Stars in 1 day0
Stars in 7 days6
Rank12,198
Previous rank6,130
Rank change-6,068
7-day stars rank5,195
Previous 7-day stars rank5,207
7-day stars rank change12
Total stars rank11,232
Previous total stars rank11,201
Total stars rank change-31
CountryIndia
README summary

**Document Processing Upgrade**: Unstructured. io has been replaced with Docling for document parsing and extraction of text, tables, and images to be embedded. **Enhanced RAG References**: Links to source documents and reference images present in reranked retrieved chunks stored in local storage are added to the bottom of the RAG responses. πŸš€ **Powered by Multi-Agent Intelligence**, this system integrates: **πŸ€– Large Language Models (LLMs)** **πŸ–ΌοΈ Computer Vision Models** for medical imaging analysis **πŸ“š Retrieval-Augmented Generation (RAG)** leveraging vector databases **🌐 Real-time Web

Search** for up-to-date medical insights **πŸ‘¨β€βš•οΈ Human-in-the-Loop Validation** to verify AI-based medical image diagnoses **What You’ll Learn from This Project** πŸ“– πŸ”Ή **πŸ‘¨β€πŸ’» Multi-Agent Orchestration** with structured graph workflows πŸ”Ή **πŸ” Advanced RAG Techniques** – hybrid retrieval, semantic chunking, and vector search πŸ”Ή **⚑ Confidence-Based Routing** & **Agent-to-Agent Handoff** πŸ”Ή **πŸ”’ Scalable, Production-Ready AI with Modularized Code & Robust Exception Handling** πŸ“‚ **For learners**: Check out for a **detailed breakdown** of the agentic workflow! :) πŸ“‚ **For an even more detailed demo video**: Check

out . βœ… **RAG-based Retrieval** – Uses Qdrant for vector search & hybrid retrieval techniques. βœ… **Medical Image Analysis** – Supports **brain tumor segmentation, chest X-ray disease detection, and skin lesion classification**. βœ… **Web Search Agent** – Fetches the latest medical research when required. βœ… **Confidence Score Check** – Ensures high accuracy with log probability-based verification. βœ… **Speech-to-Text & Text-to-Speech** – Uses **Eleven Labs API** for voice interactions. βœ… **Human-in-the-Loop Verification** – Medical professionals validate the AI’s results before final output. βœ… **Intuitive UI** – Built

for seamless user experience. Embedding markdown formatted text, tables and LLM based image summaries. LLM based semantic chunking with structural boundary awareness. LLM based query expansion with related medical domain terms. Qdrant hybrid search combining BM25 sparse keyword search along with dense embedding vector search. HuggingFace Cross-Encoder based reranking of retrieved document chunks for accurate LLM reponses. Input-output guardrails to ensure safe and relevant responses. Links to source documents and images present in reference document chunks provided with

reponse. Confidence-based agent-to-agent handoff between RAG and Web Search to prevent hallucinations. Brain Tumor Medical Computer Vision model integration. NOTE] You may use any llm and embedding model of your choice. If using Azure OpenAI, no modification required. If using direct OpenAI, modify the llm and embedding model definitions in the 'config. py' and provide appropriate env variables. If using local models, appropriate code changes might be required throughout the codebase especially in 'agents'. WARNING] Ensure the

API keys in the file are correct and have the necessary permissions. No trailing whitespaces after variable names. 3️⃣ Build the Docker Image 4️⃣ Run the Docker Container The application will be available at: 5️⃣ Ingest Data into Vector DB from Docker Container To ingest a single document: To ingest multiple documents from a directory: Managing the Container: Stop the Container Start the Container View Logs Remove the Container Troubleshooting: Container Health Check The container includes a health check that

monitors the application status. You can check the health status with: Container Not Starting If the container fails to start

Frequently asked questions

How many stars and forks are recorded?

souvikmajumder26/Multi-Agent-Medical-Assistant has 991 stars and 210 forks.

What is the repository rank?

souvikmajumder26/Multi-Agent-Medical-Assistant is ranked 12,198.

What language and category are recorded?

souvikmajumder26/Multi-Agent-Medical-Assistant has 991 stars, uses Python and belongs to Applications.

Which repository is closest in rank?

souvikmajumder26/Multi-Agent-Medical-Assistant is compared with TypingMind/typingmind, ranked 12,201 with 990 stars.

README

βš•οΈ Multi-Agent-Medical-Assistant : AI-powered multi-agentic system for medical diagnosis and assistance


[!IMPORTANT]
πŸ“‹ Version Updates from v2.0 to v2.1 and further:

  1. Document Processing Upgrade: Unstructured.io has been replaced with Docling for document parsing and extraction of text, tables, and images to be embedded.
  2. Enhanced RAG References: Links to source documents and reference images present in reranked retrieved chunks stored in local storage are added to the bottom of the RAG responses.

To use Unstructured.io based solution, refer release - v2.0.

πŸ“š Table of Contents


πŸ“Œ Overview

The Multi-Agent Medical Assistant is an AI-powered chatbot designed to assist with medical diagnosis, research, and patient interactions.

πŸš€ Powered by Multi-Agent Intelligence, this system integrates:

  • πŸ€– Large Language Models (LLMs)
  • πŸ–ΌοΈ Computer Vision Models for medical imaging analysis
  • πŸ“š Retrieval-Augmented Generation (RAG) leveraging vector databases
  • 🌐 Real-time Web Search for up-to-date medical insights
  • πŸ‘¨β€βš•οΈ Human-in-the-Loop Validation to verify AI-based medical image diagnoses

What You’ll Learn from This Project πŸ“–

πŸ”Ή πŸ‘¨β€πŸ’» Multi-Agent Orchestration with structured graph workflows
πŸ”Ή πŸ” Advanced RAG Techniques – hybrid retrieval, semantic chunking, and vector search
πŸ”Ή ⚑ Confidence-Based Routing & Agent-to-Agent Handoff
πŸ”Ή πŸ”’ Scalable, Production-Ready AI with Modularized Code & Robust Exception Handling

πŸ“‚ For learners: Check out agents/README.md for a detailed breakdown of the agentic workflow! 🎯


πŸ’« Demo

https://github.com/user-attachments/assets/d27d4a2e-1c7d-45e2-bbc5-b3d95ccd5b35

If you like what you see and would want to support the project's developer, you can ! :)

πŸ“‚ For an even more detailed demo video: Check out Multi-Agent-Medical-Assistant-v1.9. πŸ“½οΈ


πŸ›‘οΈ Technical Flow Chart


✨ Key Features

  • πŸ€– Multi-Agent Architecture : Specialized agents working in harmony to handle diagnosis, information retrieval, reasoning, and more

  • πŸ” Advanced Agentic RAG Retrieval System :

    • Docling based parsing to extract text, tables, and images from PDFs.
    • Embedding markdown formatted text, tables and LLM based image summaries.
    • LLM based semantic chunking with structural boundary awareness.
    • LLM based query expansion with related medical domain terms.
    • Qdrant hybrid search combining BM25 sparse keyword search along with dense embedding vector search.
    • HuggingFace Cross-Encoder based reranking of retrieved document chunks for accurate LLM reponses.
    • Input-output guardrails to ensure safe and relevant responses.
    • Links to source documents and images present in reference document chunks provided with reponse.
    • Confidence-based agent-to-agent handoff between RAG and Web Search to prevent hallucinations.
  • πŸ₯ Medical Imaging Analysis

    • Brain Tumor Detection (TBD)
    • Chest X-ray Disease Classification
    • Skin Lesion Segmentation
  • 🌐 Real-time Research Integration : Web search agent that retrieves the latest medical research papers and findings

  • πŸ“Š Confidence-Based Verification : Log probability analysis ensures high accuracy in medical recommendations

  • πŸŽ™οΈ Voice Interaction Capabilities : Seamless speech-to-text and text-to-speech powered by Eleven Labs API

  • πŸ‘©β€βš•οΈ Expert Oversight System : Human-in-the-loop verification by medical professionals before finalizing outputs

  • βš”οΈ Input & Output Guardrails : Ensures safe, unbiased, and reliable medical responses while filtering out harmful or misleading content

  • πŸ’» Intuitive User Interface : Designed for healthcare professionals with minimal technical expertise

[!NOTE]
Upcoming features:

  1. Brain Tumor Medical Computer Vision model integration.
  2. Open to suggestions and contributions.

πŸ› οΈ Technology Stack

Component Technologies
πŸ”Ή Backend Framework FastAPI
πŸ”Ή Agent Orchestration LangGraph
πŸ”Ή Document Parsing Docling
πŸ”Ή Knowledge Storage Qdrant Vector Database
πŸ”Ή Medical Imaging Computer Vision Models
β€’ Brain Tumor: Object Detection (PyTorch)
β€’ Chest X-ray: Image Classification (PyTorch)
β€’ Skin Lesion: Semantic Segmentation (PyTorch)
πŸ”Ή Guardrails LangChain
πŸ”Ή Speech Processing Eleven Labs API
πŸ”Ή Frontend HTML, CSS, JavaScript
πŸ”Ή Deployment Docker, GitHub Actions CI/CD

πŸš€ Installation & Setup

πŸ“Œ Option 1: Using Docker

Prerequisites:

  • Docker installed on your system
  • API keys for the required services

1️⃣ Clone the Repository

git clone https://github.com/souvikmajumder26/Multi-Agent-Medical-Assistant.git
cd Multi-Agent-Medical-Assistant

2️⃣ Create Environment File

  • Create a .env file in the root directory and add the following API keys:

[!NOTE]
You may use any llm and embedding model of your choice...

  1. If using Azure OpenAI, no modification required.
  2. If using direct OpenAI, modify the llm and embedding model definitions in the 'config.py' and provide appropriate env variables.
  3. If using local models, appropriate code changes might be required throughout the codebase especially in 'agents'.

[!WARNING]
Ensure the API keys in the .env file are correct and have the necessary permissions. No trailing whitespaces after variable names.

# LLM Configuration (Azure Open AI - gpt-4o used in development)
# If using any other LLM API key or local LLM, appropriate code modification is required
deployment_name= 
model_name=gpt-4o
azure_endpoint=
openai_api_key=
openai_api_version=

# Embedding Model Configuration (Azure Open AI - text-embedding-ada-002 used in development)
# If using any other embedding model, appropriate code modification is required
embedding_deployment_name=
embedding_model_name=text-embedding-ada-002
embedding_azure_endpoint=
embedding_openai_api_key=
embedding_openai_api_version=

# Speech API Key (Free credits available with new Eleven Labs Account)
ELEVEN_LABS_API_KEY=

# Web Search API Key (Free credits available with new Tavily Account)
TAVILY_API_KEY=

# Hugging Face Token - using reranker model "ms-marco-TinyBERT-L-6"
HUGGINGFACE_TOKEN=

# (OPTIONAL) If using Qdrant server version, local does not require API key
QDRANT_URL=
QDRANT_API_KEY=

3️⃣ Build the Docker Image

docker build -t medical-assistant .

4️⃣ Run the Docker Container

docker run -d --name medical-assistant-app -p 8000:8000 --env-file .env medical-assistant

The application will be available at: http://localhost:8000

5️⃣ Ingest Data into Vector DB from Docker Container

  • To ingest a single document:
docker exec medical-assistant-app python ingest_rag_data.py --file ./data/raw/brain_tumors_ucni.pdf
  • To ingest multiple documents from a directory:
docker exec medical-assistant-app python ingest_rag_data.py --dir ./data/raw

Managing the Container:

Stop the Container

docker stop medical-assistant-app

Start the Container

docker start medical-assistant-app

View Logs

docker logs medical-assistant-app

Remove the Container

docker rm medical-assistant-app

Troubleshooting:

Container Health Check

The container includes a health check that monitors the application status. You can check the health status with:

docker inspect --format='{{.State.Health.Status}}' medical-assistant-app

Container Not Starting

If the container fails to start, check the logs for errors:

docker logs medical-assistant-app

πŸ“Œ Option 2: Without Using Docker

1️⃣ Clone the Repository

git clone https://github.com/souvikmajumder26/Multi-Agent-Medical-Assistant.git  
cd Multi-Agent-Medical-Assistant  

2️⃣ Create & Activate Virtual Environment

  • If using conda:
conda create --name  python=3.11
conda activate 
  • If using python venv:
python -m venv 
source /bin/activate  # For Mac/Linux
\Scripts\activate     # For Windows  

3️⃣ Install Dependencies

[!IMPORTANT]
ffmpeg is required for speech service to work.

  • If using conda:
conda install -c conda-forge ffmpeg
pip install -r requirements.txt  
  • If using python venv:
wingetΒ install ffmpeg
pip install -r requirements.txt  

4️⃣ Set Up API Keys

  • Create a .env file and add the required API keys as shown in Option 1.

5️⃣ Run the Application

  • Run the following command in the activate environment.
python app.py

The application will be available at: http://localhost:8000

6️⃣ Ingest additional data into the Vector DB

Run any one of the following commands as required.

  • To ingest one document at a time:
python ingest_rag_data.py --file ./data/raw/brain_tumors_ucni.pdf
  • To ingest multiple documents from a directory:
python ingest_rag_data.py --dir ./data/raw

🧠 Usage

[!NOTE]

  1. The first run can be jittery and may get errors - be patient and check the console for ongoing downloads and installations.
  2. On the first run, many models will be downloaded - yolo for tesseract ocr, computer vision agent models, cross-encoder reranker model, etc.
  3. Once they are completed, retry. Everything should work seamlessly since all of it is thoroughly tested.
  • Upload medical images for AI-based diagnosis. Task specific Computer Vision model powered agents - upload images from 'sample_images' folder to try out.
  • Ask medical queries to leverage retrieval-augmented generation (RAG) if information in memory or web-search to retrieve latest information.
  • Use voice-based interaction (speech-to-text and text-to-speech).
  • Review AI-generated insights with human-in-the-loop verification.

🀝 Contributions

Contributions are welcome! Please check the issues tab for feature requests and improvements.


βš–οΈ License

This project is licensed under the Apache-2.0 License. See the LICENSE file for details.


πŸ“ Citing

@misc{Souvik2025,
  Author = {Souvik Majumder},
  Title = {Multi Agent Medical Assistant},
  Year = {2025},
  Publisher = {GitHub},
  Journal = {GitHub repository},
  Howpublished = {\url{https://github.com/souvikmajumder26/Multi-Agent-Medical-Assistant}}
}

πŸ“¬ Contact

For any questions or collaboration inquiries, reach out to Souvik Majumder on:

πŸ”— LinkedIn: https://www.linkedin.com/in/souvikmajumder26

πŸ”— GitHub: https://github.com/souvikmajumder26

πŸ” Return


Nearby in the ranking
Similar items