# jagathastroved/ai_kundali_report_final architecture

> Architecture diagram of the GitHub repository jagathastroved/ai_kundali_report_final, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/jagathastroved/ai_kundali_report_final
- Repository: https://github.com/jagathastroved/ai_kundali_report_final

## Overview

This is a browser-based Kundli astrology report app. Users enter birth details and location, the form requests a report, and report state combines returned data with a tailored local fallback before routing users through a multi-section report and premium offers. The map preserves the major report-analysis sections and pricing/location capabilities. Edges follow excerpts, SOURCE INDEX references, or the routes shown; several API and page implementations were not sampled, so their internal behavior is not inferred.

Main entry points: [`src/routes/AppRoutes.tsx`](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/routes/AppRoutes.tsx) (Report routing), [`src/context/ReportContext.tsx`](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/ReportContext.tsx) (Report state), [`src/components/forms/BirthDetailsForm.tsx`](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/forms/BirthDetailsForm.tsx) (Birth details form), [`src/providers/AppProviders.tsx`](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/providers/AppProviders.tsx) (App providers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_intake["Birth Intake"]
  node_landing["Landing screen<br/>[LandingScreen.tsx]"]
  node_form["Birth details form"]
  node_location["Location lookup<br/>[locationApi.ts]"]
  node_locationutils["Location utilities"]
  node_reportapi["Report API<br/>[reportApi.ts]"]
end

subgraph group_state["App State &amp; Services"]
  node_app["App shell<br/>[App.tsx]"]
  node_routes["Report routing<br/>[AppRoutes.tsx]"]
  node_providers["App providers<br/>[AppProviders.tsx]"]
  node_reportctx["Report state<br/>[ReportContext.tsx]"]
  node_theme["Theme state<br/>[ThemeContext.tsx]"]
end

subgraph group_report["Kundli Report"]
  node_book["Report book"]
  node_welcome["Report welcome<br/>[WelcomePage.tsx]"]
  node_birthstar["Birth star analysis"]
  node_personality["Core personality"]
  node_signs["Influential signs"]
  node_elements["Element analysis"]
  node_karma["Karmic chakra<br/>[KarmicChakra.tsx]"]
  node_lagna["Lagna chart<br/>[LagnaChartPage.tsx]"]
  node_strengths["Planetary strengths"]
  node_profiles["Planetary profiles"]
  node_atmakaraka["Atmakaraka<br/>[AtmakarakaPage.tsx]"]
  node_dasha["Dasha timeline<br/>[DashaWheelPage.tsx]"]
  node_features["Report features"]
  node_pdf["PDF download"]
  node_shared["Report visual elements<br/>[SharedElements.tsx]"]
end

subgraph group_commerce["Premium &amp; Pricing"]
  node_premium["Premium deliverables"]
  node_offer["Full report offer"]
  node_pricectx["Price state<br/>[PriceContext.tsx]"]
  node_priceapi["Price API<br/>[PriceApi.ts]"]
end

node_user(("Report reader"))

node_user -->|"starts report"| node_landing
node_app -->|"wraps"| node_providers
node_app -->|"renders"| node_routes
node_providers -->|"provides"| node_reportctx
node_providers -->|"provides"| node_theme
node_providers -->|"provides"| node_pricectx
node_routes -->|"reads"| node_reportctx
node_routes -->|"routes to"| node_landing
node_routes -->|"routes to"| node_book
node_routes -->|"routes to"| node_welcome
node_routes -->|"routes to"| node_birthstar
node_routes -->|"routes to"| node_personality
node_routes -->|"routes to"| node_signs
node_routes -->|"routes to"| node_elements
node_routes -->|"routes to"| node_karma
node_routes -->|"routes to"| node_lagna
node_routes -->|"routes to"| node_strengths
node_routes -->|"routes to"| node_profiles
node_routes -->|"routes to"| node_atmakaraka
node_routes -->|"routes to"| node_dasha
node_routes -->|"routes to"| node_features
node_routes -->|"routes to"| node_premium
node_landing -->|"renders"| node_form
node_form -->|"looks up places"| node_location
node_form -->|"uses fallback"| node_locationutils
node_form -->|"requests report"| node_reportapi
node_form -->|"submits details"| node_reportctx
node_book -->|"reads report"| node_reportctx
node_book -->|"reads theme"| node_theme
node_book -->|"renders"| node_offer
node_premium -->|"reads report"| node_reportctx
node_premium -->|"uses currency info"| node_locationutils
node_premium -->|"reads prices"| node_pricectx
node_pricectx -->|"loads prices"| node_priceapi
node_offer -->|"reads prices"| node_pricectx
node_offer -->|"uses currency info"| node_locationutils
node_birthstar -->|"reads report"| node_reportctx
node_personality -->|"reads report"| node_reportctx
node_signs -->|"reads report"| node_reportctx
node_elements -->|"reads report"| node_reportctx
node_karma -->|"reads report"| node_reportctx
node_lagna -->|"reads report"| node_reportctx
node_strengths -->|"reads report"| node_reportctx
node_profiles -->|"reads report"| node_reportctx
node_atmakaraka -->|"reads report"| node_reportctx
node_dasha -->|"reads report"| node_reportctx
node_elements -->|"uses visuals"| node_shared
node_lagna -->|"uses visuals"| node_shared

click node_app "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/App.tsx"
click node_routes "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/routes/AppRoutes.tsx"
click node_providers "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/providers/AppProviders.tsx"
click node_reportctx "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/ReportContext.tsx"
click node_theme "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/ThemeContext.tsx"
click node_landing "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/LandingScreen.tsx"
click node_form "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/forms/BirthDetailsForm.tsx"
click node_location "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/locationApi.ts"
click node_locationutils "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/utils/locationCurrencyUtils.ts"
click node_reportapi "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/reportApi.ts"
click node_book "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/report/KundliReportBook.tsx"
click node_welcome "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/WelcomePage.tsx"
click node_birthstar "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/BirthStarAnalysis.tsx"
click node_personality "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/CorePersonalityPage.tsx"
click node_signs "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/InfluentialSigns.tsx"
click node_elements "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/DominantElement.tsx"
click node_karma "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/KarmicChakra.tsx"
click node_lagna "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/LagnaChartPage.tsx"
click node_strengths "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PlanetaryStrengthsPage.tsx"
click node_profiles "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PlanetaryProfilesPage.tsx"
click node_atmakaraka "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/AtmakarakaPage.tsx"
click node_dasha "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/DashaWheelPage.tsx"
click node_features "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/ReportFeaturesPage.tsx"
click node_premium "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PremiumDeliverablesPage.tsx"
click node_offer "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/FullReportOfferModal.tsx"
click node_pricectx "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/PriceContext.tsx"
click node_priceapi "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/PriceApi.ts"
click node_pdf "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/ui/DownloadPdfButton.tsx"
click node_shared "https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/ui/SharedElements.tsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_landing,node_form,node_location,node_locationutils,node_reportapi toneBlue
class node_app,node_routes,node_providers,node_reportctx,node_theme toneAmber
class node_book,node_welcome,node_birthstar,node_personality,node_signs,node_elements,node_karma,node_lagna,node_strengths,node_profiles,node_atmakaraka,node_dasha,node_features,node_pdf,node_shared toneMint
class node_premium,node_offer,node_pricectx,node_priceapi toneRose
class node_user toneIndigo
```

## Components

### Birth Intake

- [Landing screen](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/LandingScreen.tsx): `src/pages/LandingScreen.tsx`
- [Birth details form](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/forms/BirthDetailsForm.tsx): `src/components/forms/BirthDetailsForm.tsx`
- [Location lookup](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/locationApi.ts): `src/api/locationApi.ts`
- [Location utilities](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/utils/locationCurrencyUtils.ts): `src/utils/locationCurrencyUtils.ts`
- [Report API](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/reportApi.ts): `src/api/reportApi.ts`

### App State & Services

- [App shell](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/App.tsx): `src/App.tsx`
- [Report routing](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/routes/AppRoutes.tsx): `src/routes/AppRoutes.tsx`
- [App providers](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/providers/AppProviders.tsx): `src/providers/AppProviders.tsx`
- [Report state](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/ReportContext.tsx): `src/context/ReportContext.tsx`
- [Theme state](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/ThemeContext.tsx): `src/context/ThemeContext.tsx`

### Kundli Report

- [Report book](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/report/KundliReportBook.tsx): `src/components/report/KundliReportBook.tsx`
- [Report welcome](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/WelcomePage.tsx): `src/pages/WelcomePage.tsx`
- [Birth star analysis](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/BirthStarAnalysis.tsx): `src/pages/BirthStarAnalysis.tsx`
- [Core personality](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/CorePersonalityPage.tsx): `src/pages/CorePersonalityPage.tsx`
- [Influential signs](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/InfluentialSigns.tsx): `src/pages/InfluentialSigns.tsx`
- [Element analysis](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/DominantElement.tsx): `src/pages/DominantElement.tsx`
- [Karmic chakra](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/KarmicChakra.tsx): `src/pages/KarmicChakra.tsx`
- [Lagna chart](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/LagnaChartPage.tsx): `src/pages/LagnaChartPage.tsx`
- [Planetary strengths](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PlanetaryStrengthsPage.tsx): `src/pages/PlanetaryStrengthsPage.tsx`
- [Planetary profiles](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PlanetaryProfilesPage.tsx): `src/pages/PlanetaryProfilesPage.tsx`
- [Atmakaraka](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/AtmakarakaPage.tsx): `src/pages/AtmakarakaPage.tsx`
- [Dasha timeline](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/DashaWheelPage.tsx): `src/pages/DashaWheelPage.tsx`
- [Report features](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/ReportFeaturesPage.tsx): `src/pages/ReportFeaturesPage.tsx`
- [PDF download](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/ui/DownloadPdfButton.tsx): `src/components/ui/DownloadPdfButton.tsx`
- [Report visual elements](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/ui/SharedElements.tsx): `src/components/ui/SharedElements.tsx`

### Premium & Pricing

- [Premium deliverables](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/pages/PremiumDeliverablesPage.tsx): `src/pages/PremiumDeliverablesPage.tsx`
- [Full report offer](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/components/FullReportOfferModal.tsx): `src/components/FullReportOfferModal.tsx`
- [Price state](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/context/PriceContext.tsx): `src/context/PriceContext.tsx`
- [Price API](https://github.com/jagathastroved/ai_kundali_report_final/blob/main/src/api/PriceApi.ts): `src/api/PriceApi.ts`

### Other components

- **Report reader**

## Connections

- Report reader → Landing screen: starts report
- App shell → App providers: wraps (evidence: `src/App.tsx`)
- App shell → Report routing: renders (evidence: `src/App.tsx`)
- App providers → Report state: provides (evidence: `src/providers/AppProviders.tsx`)
- App providers → Theme state: provides (evidence: `src/providers/AppProviders.tsx`)
- App providers → Price state: provides (evidence: `src/providers/AppProviders.tsx`)
- Report routing → Report state: reads (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Landing screen: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Report book: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Report welcome: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Birth star analysis: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Core personality: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Influential signs: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Element analysis: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Karmic chakra: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Lagna chart: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Planetary strengths: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Planetary profiles: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Atmakaraka: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Dasha timeline: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Report features: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Report routing → Premium deliverables: routes to (evidence: `src/routes/AppRoutes.tsx`)
- Landing screen → Birth details form: renders (evidence: `src/pages/LandingScreen.tsx`)
- Birth details form → Location lookup: looks up places (evidence: `src/components/forms/BirthDetailsForm.tsx`)
- Birth details form → Location utilities: uses fallback (evidence: `src/components/forms/BirthDetailsForm.tsx`)
- Birth details form → Report API: requests report (evidence: `src/components/forms/BirthDetailsForm.tsx`)
- Birth details form → Report state: submits details (evidence: `src/components/forms/BirthDetailsForm.tsx`)
- Report book → Report state: reads report (evidence: `src/components/report/KundliReportBook.tsx`)
- Report book → Theme state: reads theme (evidence: `src/components/report/KundliReportBook.tsx`)
- Report book → Full report offer: renders (evidence: `src/components/report/KundliReportBook.tsx`)
- Premium deliverables → Report state: reads report (evidence: `src/pages/PremiumDeliverablesPage.tsx`)
- Premium deliverables → Location utilities: uses currency info (evidence: `src/pages/PremiumDeliverablesPage.tsx`)
- Premium deliverables → Price state: reads prices (evidence: `src/pages/PremiumDeliverablesPage.tsx`)
- Price state → Price API: loads prices (evidence: `src/context/PriceContext.tsx`)
- Full report offer → Price state: reads prices (evidence: `src/components/FullReportOfferModal.tsx`)
- Full report offer → Location utilities: uses currency info (evidence: `src/components/FullReportOfferModal.tsx`)
- Birth star analysis → Report state: reads report (evidence: `src/pages/BirthStarAnalysis.tsx`)
- Core personality → Report state: reads report (evidence: `src/pages/CorePersonalityPage.tsx`)
- Influential signs → Report state: reads report (evidence: `src/pages/InfluentialSigns.tsx`)
- Element analysis → Report state: reads report (evidence: `src/pages/DominantElement.tsx`)
- Karmic chakra → Report state: reads report (evidence: `src/pages/KarmicChakra.tsx`)
- Lagna chart → Report state: reads report (evidence: `src/pages/LagnaChartPage.tsx`)
- Planetary strengths → Report state: reads report (evidence: `src/pages/PlanetaryStrengthsPage.tsx`)
- Planetary profiles → Report state: reads report (evidence: `src/pages/PlanetaryProfilesPage.tsx`)
- Atmakaraka → Report state: reads report (evidence: `src/pages/AtmakarakaPage.tsx`)
- Dasha timeline → Report state: reads report (evidence: `src/pages/DashaWheelPage.tsx`)
- Element analysis → Report visual elements: uses visuals (evidence: `src/pages/DominantElement.tsx`)
- Lagna chart → Report visual elements: uses visuals (evidence: `src/pages/LagnaChartPage.tsx`)
