Skip to main content

Live Demo — Caduceus HIS

Caduceus is a hospital information system demo that uses every published @fhir-dsl/* package end-to-end. It's the surface-freeze smoke test for v1.x — and the most concrete way to see what the toolchain looks like in a real React app.

Live demo  ·  Source on GitHub

What's in the demo

PillarWhat it showsPackages exercised
Patient list / detailTyped search with where / include / sort, profile-narrowing toggle (US Core), FHIRPath-driven write-back via JSON Patch, optimistic update + rollback on FhirRequestError@fhir-dsl/core, @fhir-dsl/runtime, @fhir-dsl/fhirpath, @fhir-dsl/tanstack-query
SMART-on-FHIR launchFull v2 flow through the SMART Health IT sandbox: discovery → PKCE → code exchange → token persistence@fhir-dsl/smart
FHIRPath playgroundLive compile + evaluate against sample resources, UCUM-aware Quantity demo, terminology hooks demo@fhir-dsl/fhirpath
Claude chatbot (full version only)LLM tool-use loop wired to an in-process MCP server, with audit timeline@fhir-dsl/mcp, @anthropic-ai/sdk

Two deployment flavors

The demo is a TanStack Start app with both client and server routes. We ship two builds:

  • GitHub Pages (this site, /demo/) — a static SPA build. Patient list/detail, FHIRPath playground, and the SMART login flow all work because they're client-only. The chatbot is disabled because it requires server-side calls to the Anthropic SDK and the in-process MCP dispatcher.
  • Full self-host — build from the source repo and run with pnpm demo for the complete experience including the chatbot. Requires ANTHROPIC_API_KEY in your environment.

Run the full version locally

git clone https://github.com/awbx/fhir-dsl.git
cd fhir-dsl
pnpm install
pnpm demo:gen # generates R4 FHIR types into apps/his-demo/src/fhir/r4
pnpm demo # runs the dev server with chatbot + MCP enabled

Open http://localhost:3000 and click "Login with SMART" to start the patient-launch dance. Drop your ANTHROPIC_API_KEY in apps/his-demo/.env.local first if you want the chatbot.

Architecture

The demo is structured as a TanStack Start app with file-based routing and shadcn/ui. The interesting bits to read: