Turns a medical textbook into a graph so an AI's answer can be traced node by node instead of trusted as a black box.
Built in 36-ish hours at The Future of Data (Cincinnati, November 2024). 1st place.
WhiteBox takes Davidson's Principles and Practice of Medicine and breaks it into a Neo4j graph of about 60,000 nodes and 130,000 relationships. Ask it a medical question and instead of a model generating an answer from nowhere, it walks a path through that graph and shows you the path.
The bet behind it: in a field like medicine, "trust me" isn't good enough. If a model tells you a symptom points to a diagnosis and a diagnosis points to a treatment, you should be able to see the specific nodes and edges it walked to get there, not just the final sentence.
- A question comes in through the
/getNodesendpoint (server/Graph_RAG.py). - Each word in the question gets embedded with
all-MiniLM-L6-v2(sentence-transformers) and scored against the whole question by cosine similarity, so filler words drop out and only terms above a 0.25 threshold survive. - Those terms drive a Cypher query against Neo4j, pulling candidate
Documentnodes that touch them. - Candidates get re-ranked by cosine similarity between the question and each document's title + text, and the top 3 are kept.
- Their graph neighborhoods get pulled and handed to
microsoft/Phi-3-mini-4k-instruct, which generates the answer from that neighborhood instead of from general knowledge. - The same subgraph is returned as nodes and edges and rendered in the browser with vis.js, so the answer and the path it came from sit side by side.
- Model selection and fine-tuning, including a LLaMA 3.1 8B fine-tune for summarization and classification, was Arya's part of the build, feeding the graph and the retrieval step above.
- The graph dump is in
Neo4j/neo4j.dump;Neo4j/load-data.shcontains the database restore command.scripts/DB_labels_fix.pymerges near-duplicate labels after import.
The UI and graph API are separate Flask processes. Set NEO4J_URI, NEO4J_USERNAME,
and NEO4J_PASSWORD in the environment for the graph API, and point them at a Neo4j
database restored from the included dump. For a local Neo4j instance, the URI is
commonly bolt://localhost:7687. From the repository root, install each service's
listed Python requirements and start the processes in separate terminals:
python3 -m pip install -r server/requirements.txt
python3 server/Graph_RAG.pypython3 -m pip install -r frontend/requirements.txt
python3 frontend/app.pyOpen http://localhost:8080/. The UI sends graph questions to the API on port 8000.
The server loads all-MiniLM-L6-v2 at startup and downloads Phi-3 when generating an
answer; model weights and a populated Neo4j database are not bundled. server/main.py
is a separate early /chat echo stub, not the graph endpoint used by this UI.
This is a hackathon research demo, not a clinically validated diagnostic or treatment tool. Its answers and retrieved paths require expert review.
The real pipeline needs Neo4j loaded with the full graph and two models resident in memory, not something you casually clone and run. prototype/graph_qa_demo.py is a toy stand-in: a 25-node dict graph of symptoms, conditions, and treatments, walked with plain BFS instead of a model call. The point survives the downgrade: the answer is the path, and the path is the whole explanation.
No hackathon metrics were logged, so there are no charts of results here — just two explanatory diagrams. python prototype/graph_qa_demo.py regenerates both locally (numpy + matplotlib, nothing else).
The first is a real BFS walk on the toy graph, asking "what treats shortness of breath?" and tracing the shortest path to a treatment (the rest of the toy graph shown as hairlines for context):
The second is a concept sketch of the real architecture as built at the hackathon: textbook to graph at build time, question to answer-with-path at query time.
- Arya Garg — open-source model selection and fine-tuning. github.com/Aryagarg23
- Kaaustaaub Shankar — RAG. github.com/KaaustaaubShankar
- Raihan Rafeek — database and API.
Originally hacked together in KaaustaaubShankar/WhiteBox.
- Gyrus — agentic browser that supports curiosity instead of replacing it (WeaveHacks 2025)
- G-Code-Assembler — G-code assembly + STL visualization (MakeUC 2024, Kinetic Vision winner)
- Terminally-Addicted — Spotify, GitHub, GPT and YouTube without leaving the terminal (HackOHI/O 2024)
- Memento — digital memory journal for Alzheimer's patients and caregivers (RevolutionUC 2024, 3rd overall)
- Buycott — barcode scan -> parent company -> NLP stance on social issues (MakeUC 2023, 1st overall)
- SignLink — video calls with real-time ASL fingerspelling to text (BoilerMake X 2023)
- Kuka Arm Viz — interactive 7-DOF robot arm in WebGL with inverse kinematics (RevolutionUC 2023)
- Hi-Five — anonymous friend-matching on OCEAN personality vectors (SASEhack 2024)
- Friction — speculative OS + hardware that protects flow state with physical friction (Fig Build 2026)

