Version: 4.1 | Architecture: World-Class Modular Monolith Status: β Production-Ready | Audit: A (93/100) - December 2025
AI-powered healthcare intelligence platform with multi-tenant architecture, visual workflow designer, and enterprise-grade security.
| Layer | Active Files | Test Files | Archive | Total |
|---|---|---|---|---|
| Backend (Python) | 425 | 47 | 96 | 568 |
| Frontend (TypeScript) | 1,394 | 18 | 0 | 1,412 |
| Packages (TypeScript) | 223 | 0 | 0 | 223 |
| Grand Total | 2,042 | 65 | 96 | 2,203 |
Canonical Audit Report: .claude/docs/services/ask-expert/ASK_EXPERT_UNIFIED_AUDIT.md
DO NOT create files in project root or random locations!
| File Type | β Correct Location | β Wrong Location |
|---|---|---|
| Internal Docs | /.claude/docs/ |
/, /docs/ |
| Public Docs | /docs/guides/ |
/, /.claude/docs/ |
| Python Code | /services/ai-engine/src/ |
/, /scripts/ |
| SQL Files | /database/migrations/ |
/, /docs/ |
See STRUCTURE.md or .claude.md for complete rules.
# Install dependencies
pnpm install
# Start development
make dev
# Or use Docker
make docker-upπ Documentation: See docs/ for public docs or .claude/docs/ for internal documentation.
vital-platform/
βββ apps/ # Frontend (Next.js 14)
β βββ vital-system/ # Main application
β βββ src/
β βββ app/ # Next.js App Router
β βββ features/ # Feature modules
β βββ components/ # Shared components
β βββ lib/ # Utilities (consolidated)
β βββ middleware/ # Next.js middleware
β βββ types/ # TypeScript types
β βββ contexts/ # React contexts
β βββ hooks/ # React hooks
β βββ stores/ # State stores
β
βββ packages/ # Shared packages
β βββ protocol/ # Type definitions (Zod schemas)
β
βββ services/ # Backend services
β βββ ai-engine/ # Python FastAPI + LangGraph
β βββ src/
β β βββ api/ # Routes & middleware
β β βββ modules/ # Business logic
β β β βββ translator/ # React Flow β LangGraph
β β β βββ execution/ # Workflow runner
β β β βββ expert/ # Ask Expert service
β β β βββ panels/ # Panel discussions
β β βββ workers/ # Celery async tasks
β β βββ domain/ # Entities & services
β β βββ infrastructure/ # LLM, DB, cache
β βββ tests/
β
βββ database/ # SQL migrations & policies
β βββ migrations/ # Schema migrations
β βββ policies/ # RLS policies
β
βββ infrastructure/ # Deployment configs
β βββ docker/ # Docker Compose + Dockerfiles
β βββ terraform/ # AWS infrastructure
β
βββ tests/ # E2E & performance tests
β βββ e2e/ # Playwright tests
β βββ performance/ # k6 load tests
β
βββ docs/ # Public documentation
βββ architecture/ # System design
βββ api/ # OpenAPI spec
βββ guides/ # Getting started
| Feature | Description |
|---|---|
| Ask Expert | 4-mode AI assistant (quick, smart, deep, panel) |
| Workflow Designer | Visual builder with React Flow β LangGraph |
| Multi-tenant | Row-Level Security with organization_id |
| Type-Safe | Zod (TS) β Pydantic (Python) sync |
| Async Processing | Celery workers for long tasks |
| Token Budgeting | Cost control per organization |
# Development
make dev # Start all services
make dev-api # Backend only
make dev-web # Frontend only
# Docker
make docker-up # Start containers
make docker-down # Stop containers
make docker-logs # View logs
# Testing
make test # All tests
make test-api # Backend tests
# Build
make build # Build all
make sync-types # Generate Pydantic from Zod| Document | Location |
|---|---|
| Architecture | .claude/docs/architecture/VITAL_WORLD_CLASS_STRUCTURE_FINAL.md |
| API Reference | docs/api/openapi.yaml |
| Getting Started | docs/guides/getting-started.md |
| Development | docs/guides/development.md |
| Deployment | docs/guides/deployment.md |
| Internal Docs | .claude/docs/ |
Frontend: Next.js 14, React Flow, TanStack Query, Tailwind CSS Backend: FastAPI, LangGraph, Celery, Pydantic Database: Supabase (PostgreSQL + RLS), Pinecone (vectors) Infrastructure: Docker, Terraform, AWS EKS
| Directory | Files | Purpose |
|---|---|---|
services/ai-engine/src/agents/ |
66 | L1-L5 agent hierarchy |
services/ai-engine/src/api/ |
66 | FastAPI routes & schemas |
services/ai-engine/src/langgraph_workflows/ |
40 | Mode 1-4 workflows |
services/ai-engine/src/services/ |
71 | Business logic |
apps/vital-system/src/app/ |
281 | Next.js pages & API |
apps/vital-system/src/features/ |
344 | Feature modules |
apps/vital-system/src/components/ |
385 | UI components |
packages/vital-ai-ui/ |
141 | VITAL AI UI library |
| Directory | Files | Reason |
|---|---|---|
services/ai-engine/src/_backup_phase1/ |
27 | Phase 1 refactoring backups |
services/ai-engine/src/_legacy_archive/ |
69 | Deprecated implementations |
Proprietary - All Rights Reserved
Last Updated: December 12, 2025