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
π₯ Clinical Decision Support Agent
π― 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 | Google Colab (CPU) |
π How to Run
- Get a free Groq API key at console.groq.com
- Open
app.pyin Google Colab - Replace
your-groq-api-key-herewith your actual key - Run all cells in order
β οΈ 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.
π Project Status
β PubMed search tool complete β LangGraph agent built β Multi-turn memory working β BERTScore evaluation done β Gradio demo deployed on Hugging Face Spaces