A full-stack clinical knowledge graph application built on top of the BODHI ontology by Eka Care.
Stack: FastAPI Β· React (Vite + TypeScript) Β· Neo4j 5.x Β· Docker Compose
Data licensed under CC BY-NC 4.0 β non-commercial use only. Credit: Eka Care.
The BODHI ontology data is included as a git submodule (see section below). Always clone with:
git clone --recurse-submodules https://github.com/pcmedsinge/bodhi_app.gitIf you already cloned without --recurse-submodules, fetch the submodule manually:
git submodule update --init --recursivebodhi_app/
βββ backend/ # FastAPI app (Neo4j queries, REST endpoints)
β βββ main.py
β βββ db.py
β βββ Dockerfile
β βββ requirements.txt
β βββ .env.example # Copy to .env and fill in credentials
βββ frontend/ # React + Vite dashboard
β βββ src/
β βββ Dockerfile
β βββ vite.config.ts
βββ neo4j/
β βββ import/ # Cypher import scripts (bodhi_s.cypher, bodhi_m.cypher)
β βββ plugins/
βββ BODHI/ # Upstream ontology data (git submodule β eka-care/BODHI)
βββ scripts/
β βββ neo4j.sh # Helper to run cypher-shell queries
βββ docker-compose.yml
cp backend/.env.example backend/.env # set credentials if needed
docker compose up --build| Service | URL |
|---|---|
| Frontend | http://localhost:5173 |
| Backend | http://localhost:8000/docs |
| Neo4j | http://localhost:7474 |
On first run, import the ontology data into Neo4j:
docker exec neo4j-bodhi cypher-shell -u neo4j -p bodhi123 -f /import/bodhi_s.cypher
docker exec neo4j-bodhi cypher-shell -u neo4j -p bodhi123 -f /import/bodhi_m.cypherThe BODHI/ folder is the upstream ontology source from Eka Care. It is not copied into this repo β instead it is tracked as a git submodule. This means:
- Only a pointer (commit hash) to the external repo is stored here, not the actual files.
- The version of the ontology you are using is always explicit and reproducible.
- Updates from upstream are pulled deliberately, not silently.
git submodule status
# output example:
# a3f82c1 BODHI (heads/main)
# the hash is the exact upstream commit your project is pinned tocd BODHI
git pull origin main # pull latest from eka-care/BODHI
cd ..
git add BODHI
git commit -m "chore: update BODHI submodule to latest upstream"
git pushcd BODHI
git checkout v2.0.0 # or any commit hash
cd ..
git add BODHI
git commit -m "chore: pin BODHI submodule to v2.0.0"
git pushgit pull
git submodule update --recursiveCopy backend/.env.example to backend/.env:
NEO4J_URI=bolt://localhost:7687
NEO4J_USER=neo4j
NEO4J_PASSWORD=changeme
When running via Docker Compose, these are injected automatically from docker-compose.yml and point to the neo4j service name instead of localhost.
Application code: MIT
BODHI ontology data (BODHI/): CC BY-NC 4.0 β Eka Care