mou11's picture
Update README.md
05cbbcd verified

A newer version of the Gradio SDK is available: 6.14.0

Upgrade
metadata
title: Clinical Decision Support Agent
emoji: πŸ“ˆ
colorFrom: green
colorTo: blue
sdk: gradio
app_file: app.py
pinned: false
license: mit
pipeline_tag: text-generation
base_model: mistralai/Mistral-7B-v0.1
tags:
  - medical-ai
  - llm
  - clinical-decision-support
  - langgraph
  - pubmed
  - groq
  - llama
  - agent
  - medical
  - rag
  - nlp
  - healthcare
  - gradio
  - langchain

πŸ₯ Clinical Decision Support Agent

Python LLaMA LangGraph HuggingFace

🎯 Live Demo

πŸ‘‰ Try it on Hugging Face Spaces

πŸ” Overview

A production-grade Medical AI Agent that takes patient symptoms as natural language input, searches real PubMed medical literature automatically, and generates structured clinical recommendations with citations. Built with LangGraph for agent orchestration and Groq (LLaMA 3.3 70B) for clinical reasoning.

πŸ“Š Results

Metric Score
BERTScore Precision 0.8449
BERTScore Recall 0.8887
BERTScore F1 0.8663

πŸ§ͺ Test Cases

Case Symptoms Urgency Level
Case 1 Fever, cough, chest pain High βœ…
Case 2 Stiff neck, fever, confusion Emergency βœ…
Case 3 Chest pain radiating to left arm, diabetes Emergency βœ…

✨ Features

  • βœ… Real-time PubMed literature search via NCBI API
  • βœ… LLM-powered clinical reasoning (LLaMA 3.3 70B via Groq)
  • βœ… Structured output: conditions, tests, treatments, urgency
  • βœ… Multi-turn conversation memory
  • βœ… BERTScore quality evaluation
  • βœ… Interactive Gradio web interface

πŸ—οΈ Architecture

Patient Symptoms β†’ Extract Search Query (LLM) β†’ Search PubMed (NCBI API) β†’ Generate Recommendation (LLaMA 3.3 70B) β†’ Format Report β†’ Gradio UI

πŸ› οΈ Tech Stack

Component Tool
Agent Orchestration LangGraph
LLM Groq β€” LLaMA 3.3 70B
Medical Literature PubMed NCBI API
Evaluation BERTScore
UI Gradio
Platform Kaggle T4 GPU

πŸš€ How to Run

  1. Get a free Groq API key at console.groq.com
  2. Clone the Space and install requirements
  3. Set your Groq API key as environment variable
  4. Run python app.py

⚠️ Medical Disclaimer

This system is for educational and research purposes only. It does not provide medical advice. Always consult a qualified healthcare professional for medical decisions.

πŸ“Œ Part of Medical AI Portfolio

  1. βœ… Pneumonia Detection (ViT + Grad-CAM)
  2. βœ… Clinical Decision Support Agent (LangGraph + RAG) β€” this project
  3. βœ… Medical LLM Fine-tuning (QLoRA)
  4. βœ… Medical Report Generator (Hallucination Detection + FHIR)