How we built it Inspiration

Homeopaths rely on memory to match symptoms across 3,000+ remedies. We built a system that reasons over the entire knowledge graph — detecting contradictions, quantifying uncertainty, and surfacing rare patterns no single practitioner could — without the AI ever inventing anything.

What it does

HomeoAID takes a patient's complaint and returns ranked homeopathic remedies grounded entirely in a Neo4j knowledge graph. Four intelligence layers operate on top: contradiction detection, bootstrap uncertainty quantification (confidence intervals per remedy), temporal case evolution tracking (suppression detection), and rare pattern mining (Apriori across case histories). LLMs only structure input and explain results — they never decide.

How we built it

Neo4j knowledge graph with a data pipeline scraping Boericke's Materia Medica (1927, public domain) Python/FastAPI backend with four independent, purely algorithmic reasoning layers Next.js/TypeScript frontend for consultations and remedy exploration Gemini 2.0 Flash restricted to symptom extraction and explanation only Docker Compose for infrastructure, pytest for full test coverage

Challenges we ran into

Designing the pipeline so LLMs can never hallucinate remedies or override graph-derived rankings Modeling temporal snapshots, contradictions, and outcome correlations in a single coherent graph schema Parsing inconsistently formatted century-old materia medica texts into structured data Keeping 200-iteration bootstrap uncertainty estimation fast enough for interactive use Accomplishments that we're proud of Zero hallucination by design — every recommendation traces to graph edges, never LLM invention Four reasoning layers that answer questions no single practitioner can: contradiction detection, confidence intervals, suppression tracking, and rare pattern discovery End-to-end pipeline from scraping 1927 texts to a live, queryable knowledge graph with a web UI What we learned Graph-RAG vastly outperforms vanilla RAG for clinical reasoning — structured relationships carry more signal than vector similarity Constraining LLMs is a feature, not a limitation — the most trustworthy system is one where AI explains but doesn't decide Bootstrap perturbation is surprisingly effective for ranking uncertainty without probabilistic models

Built With

  • 2.0
  • backend:-python-(fastapi
  • cypher)
  • database:
  • docker
  • flash
  • gemini
  • google
  • infra:
  • llm:
  • neo4j
  • neo4j-driver
  • numpy/scipy
  • pydantic)-frontend:-typescript-(next.js
  • react)
Share this project:

Updates