RadiX is a Next.js clinical imaging workstation for AI-assisted radiology review. It supports scan upload, AI analysis, doctor review state, consultation chat, surgical comparison, voice assistance, signed private scan storage, and Supabase-backed clinical records.
This repository is the cleaned production scaffold rebuilt from the hackathon prototype. It intentionally excludes local scan files, real environment files, demo archives, and generated build artifacts.
- Next.js 16 App Router with TypeScript
- React 18
- Tailwind CSS
- Supabase Auth, Postgres, Row Level Security, and private Storage
- Claude, Gemini, and local MedGemma provider paths
- ElevenLabs text-to-speech
- Jest and Playwright
- GitHub Actions CI
- Supabase project with the migrations in
supabase/migrationsapplied - Anthropic and/or Gemini API key for production AI inference
- Optional local MedGemma service exposed through
MEDGEMMA_API_URL - Optional ElevenLabs API key for speech generation
Create .env.local from .env.example and fill only local values. Never commit .env*.
Required for production runtime:
NEXT_PUBLIC_SUPABASE_URLNEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEYorNEXT_PUBLIC_SUPABASE_ANON_KEYSUPABASE_SERVICE_ROLE_KEY
At least one AI path should be configured:
ANTHROPIC_API_KEYGEMINI_API_KEYMEDGEMMA_API_URL
Optional:
ELEVENLABS_API_KEYAI_PROVIDERCLAUDE_MODELNEXT_PUBLIC_SITE_URL
npm install
npm run devOpen http://localhost:3000.
Run the full non-browser gate:
npm run ci:verifyRun Playwright smoke tests:
npm run test:e2eThe authenticated E2E flow is skipped unless demo credentials are supplied through environment variables.
GET /api/health returns deployment readiness without exposing secret values.
200means required Supabase runtime configuration is present.503means required runtime configuration is missing or still uses placeholder values.
Migrations live in supabase/migrations.
Important production properties:
- clinical tables use authenticated ownership RLS
audit_logis append-only at the database levelscan-imagesis a private storage bucket- storage policies restrict reads/writes to the authenticated user's folder prefix