How ayuressence146-boop/ayuressence-hpl works
AyurEssence is a role-based Ayurvedic Prakriti assessment platform: doctors and students manage patients and assessments, patients can access their own assessment information, and finalized assessments provide scored results and related reports. The graph shows the web app, FastAPI modular monolith, domain services, and persistence. The README documents the main assessment sequence; sampled source confirms selected service calls and database access. Several frontend-to-API and unsampled subsystem links are not visible in the excerpts, so they are left unverified or omitted.
Main entry points: main.py FastAPI application · models.py SQLAlchemy records · assessments/service.py Assessment workflow · auth/service.py Authentication
Components 22
Web experience
- Role-based web app
frontend/src/App.tsx - Role workflows
frontend/src/pages - API client
frontend/src/services/api.ts - Frontend data store
frontend/src/services/dataStore.ts
API and access
- FastAPI application
app/main.py - Authentication
app/auth/service.py - Token security
app/core/security.py - Access control
app/core/dependencies.py - Configuration
app/core/config.py - API error handling
app/core/exceptions.py
Clinical workflow
- Patient management
app/patients/service.py - Questionnaires
app/questionnaires/service.py - Assessment workflow
app/assessments/service.py - Clinical observations
app/observations/schemas.py - Prakriti scoring
app/calculation/engine.py
Results and support
- Educational content
app/educational/service.py - Recommendations
app/recommendations/service.py - Reports and sharing
app/reports/service.py - Reminders
app/reminders/service.py
Persistence
- SQLAlchemy records
app/database/models.py - Database connection
app/database/connection.py
Other components
- Clinical users
Connections 30
- Clinical users → Role-based web app: use
frontend/src/App.tsx - Role-based web app → Role workflows: routes to
frontend/src/App.tsx - Role workflows → API client: request data
- API client → FastAPI application: call API
- Frontend data store → API client: uses
frontend/src/services/dataStore.ts - FastAPI application → Authentication: registers router
app/main.py - FastAPI application → Patient management: registers router
app/main.py - FastAPI application → Questionnaires: registers router
app/main.py - FastAPI application → Assessment workflow: registers router
app/main.py - FastAPI application → Recommendations: registers router
app/main.py - FastAPI application → Reports and sharing: registers router
app/main.py - FastAPI application → Reminders: registers router
app/main.py - FastAPI application → Educational content: registers router
app/main.py - Authentication → Token security: uses tokens
app/auth/service.py - FastAPI application → Database connection: initializes
app/main.py - Database connection → Configuration: reads settings
app/database/connection.py - Database connection → SQLAlchemy records: creates schema
app/database/connection.py - Authentication → SQLAlchemy records: reads and writes
app/auth/service.py - Patient management → SQLAlchemy records: reads and writes
app/patients/service.py - Questionnaires → SQLAlchemy records: queries
app/questionnaires/service.py - Assessment workflow → SQLAlchemy records: reads and writes
app/assessments/service.py - Assessment workflow → Prakriti scoring: calculates with
app/assessments/service.py - Assessment workflow → Clinical observations: handles
app/assessments/router.py - Educational content → SQLAlchemy records: reads
app/educational/service.py - Recommendations → SQLAlchemy records: reads and writes
app/recommendations/service.py - Reports and sharing → SQLAlchemy records: reads and writes
app/reports/service.py - Reminders → SQLAlchemy records: reads and writes
app/reminders/service.py - Access control → Token security: decodes token
app/core/dependencies.py - Access control → SQLAlchemy records: loads profile
app/core/dependencies.py - FastAPI application → API error handling: registers handlers
app/main.py