MedGemma CKD — a clinical RAG assistant, three ways
I built the same chronic-kidney-disease assistant at three levels — simple, agentic, multi-agent — on 24 real clinical guideline documents, for the Kaggle MedGemma Impact Challenge. This series walks the whole thing: the data pipeline, each level, and an honest evaluation.
-
Part 1MedGemma CKD: building a clinical RAG assistant three ways
Why I built the same chronic-kidney-disease assistant at three levels — simple, agentic, multi-agent — and the shared foundation underneath. Part 1 of the MedGemma CKD series.
-
Part 2See it answer — grounded, cited, and willing to say "no"
Real questions through the CKD assistant — grounded, cited answers with their sources, and a clean refusal when the guidelines are silent. A demo from the MedGemma CKD series.
-
Part 3From 24 clinical PDFs to a vector store
The unglamorous half of RAG: OCR with Docling, section splitting, block-aware chunking, and embedding 24 clinical guideline documents into ChromaDB. Part 2 of the MedGemma CKD series.
-
Part 4Chunking clinical guidelines — where recall is won or lost
Recall was the ceiling — and recall is decided at chunk time. Docling OCR, section-first splitting, 2000-token chunks, the 512-token embedding catch, and a duplicate corpus. A MedGemma CKD deep-dive.
-
Part 5Level 1 — Simple RAG, the honest baseline
Retrieve, answer, cite — and the retriever choices (flat, tree, RAPTOR, contextual) that decide whether any of it works. Part 3 of the MedGemma CKD series.
-
Part 6The retriever zoo — three bets scored, two that didn't make it
Flat vs tree vs RAPTOR vs contextual vs hybrid — how each retriever works, a RAGAS scoreboard where RAPTOR wins, and the tree retriever that was silently broken for months. A MedGemma CKD deep-dive.
-
Part 7Where the model runs — local, hosted, or a GPU box
Local embeddings, a provider-agnostic generator endpoint, and three places to run it — a laptop, AI Studio, and a self-hosted g6/vLLM GPU box — with the honest tradeoffs of each. A MedGemma CKD deep-dive.
-
Part 8The knobs that move the numbers (and the ones that don't)
Top-k, similarity threshold, chunk size, embedding dimensions, RAPTOR and tree internals, generation settings — which parameters actually move the score, and which are set-and-forget. A MedGemma CKD deep-dive.
-
Part 9Level 2 — Agentic RAG with LangGraph
Wrapping retrieval in a LangGraph state machine: PII redaction with Presidio, intent routing, and self-scoring with RAGAS. Part 4 of the MedGemma CKD series.
-
Part 10Level 3 — A multi-agent clinical assistant
A router and four specialists — Diet, Medication, Lifestyle, Knowledge — because a diet question and a drug-interaction question are different jobs. Part 5 of the MedGemma CKD series.
-
Part 11Evaluating a clinical RAG — the honest results
RAGAS, a retriever comparison, and middling scores I'm not going to dress up. Why retrieval over dense clinical text is the hard part. Part 6 of the MedGemma CKD series.