CoolFace
Apppublic

mou11/clinical-decision-support-agent

sourceHugging Facemitupdated 4mo agoView on Hugging Face
2likes
App README

๐Ÿฅ 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

MetricScore
BERTScore Precision0.8449
BERTScore Recall0.8887
BERTScore F10.8663

๐Ÿงช Test Cases

CaseSymptomsUrgency Level
Case 1Fever, cough, chest painHigh โœ…
Case 2Stiff neck, fever, confusionEmergency โœ…
Case 3Chest pain radiating to left arm, diabetesEmergency โœ…

โœจ 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

ComponentTool
Agent OrchestrationLangGraph
LLMGroq โ€” LLaMA 3.3 70B
Medical LiteraturePubMed NCBI API
EvaluationBERTScore
UIGradio
PlatformKaggle T4 GPU

๐Ÿš€ How to Run

  1. 1.Get a free Groq API key at console.groq.com
  2. 2.Clone the Space and install requirements
  3. 3.Set your Groq API key as environment variable
  4. 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. 1.โœ… Pneumonia Detection (ViT + Grad-CAM)
  2. 2.โœ… Clinical Decision Support Agent (LangGraph + RAG) โ€” this project
  3. 3.โœ… Medical LLM Fine-tuning (QLoRA)
  4. 4.โœ… Medical Report Generator (Hallucination Detection + FHIR)