Healthcare Document Intelligence MCP Server

Healthcare Document Intelligence MCP Server

Enables document search, grounded question answering, summarization, patient timeline extraction, and PHI redaction for healthcare documents using retrieval-augmented generation.

Category
Visit Server

README

Healthcare Document Intelligence RAG + MCP

Production-ready starter project for healthcare document intelligence using retrieval-augmented generation, medical document pipelines, PHI-aware preprocessing, a FastAPI service, and an MCP server for agent extensibility.

Highlights

  • Healthcare-focused ingestion for clinical notes, discharge summaries, lab reports, and policy documents
  • PHI redaction layer before indexing and prompt construction
  • Hybrid retrieval with deterministic local embeddings by default and optional OpenAI embeddings
  • Citation-grounded answers with document, section, and page metadata
  • FastAPI REST API with OpenAPI docs at /docs
  • MCP server exposing document search, patient timeline extraction, summarization, and evidence QA tools
  • Docker, Compose, tests, linting, and GitHub Actions CI
  • Offline sample dataset so reviewers can run the project without vendor keys

Architecture

documents
  -> parser
  -> PHI redactor
  -> medical chunker
  -> embedding model
  -> vector index
  -> retriever
  -> grounded response
        |-> FastAPI
        |-> MCP tools

Quick Start

cd healthcare-document-intelligence-rag-mcp
python -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
cp .env.example .env
make seed
make test
make api

Open:

http://127.0.0.1:8000/docs

Ask a grounded question:

curl -X POST http://127.0.0.1:8000/query \
  -H "Content-Type: application/json" \
  -d '{"question":"What follow-up is recommended after discharge?","top_k":4}'

MCP Server

Run the MCP server locally:

make mcp

The server exposes:

  • search_documents
  • answer_question
  • summarize_document
  • extract_patient_timeline
  • redact_phi

Example Claude Desktop style configuration:

{
  "mcpServers": {
    "healthcare-document-intelligence": {
      "command": "python",
      "args": ["-m", "meddoc_intel.mcp.server"],
      "cwd": "/absolute/path/to/healthcare-document-intelligence-rag-mcp"
    }
  }
}

API

Core endpoints:

  • GET /health
  • POST /documents
  • POST /query
  • POST /summaries
  • POST /redact
  • GET /documents

See docs/API.md for examples.

Evaluation

Seed the sample index and run the retrieval smoke evaluation:

make seed
python scripts/evaluate_retrieval.py

The evaluation uses expected-document recall for simple, reviewable regression checks. See docs/ML_PIPELINE.md.

Configuration

The default setup uses deterministic local embeddings, which are ideal for demos, CI, and reproducible tests.

Optional OpenAI support:

EMBEDDING_PROVIDER=openai
OPENAI_API_KEY=sk-...
OPENAI_EMBEDDING_MODEL=text-embedding-3-small

This project is a developer portfolio and prototyping system. It is not medical advice, not a diagnostic device, and not a substitute for professional clinical judgment.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured