# abhi-148/up-student-ai-copilot architecture

> Architecture diagram of the GitHub repository abhi-148/up-student-ai-copilot, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-06-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/abhi-148/up-student-ai-copilot
- Repository: https://github.com/abhi-148/up-student-ai-copilot

## Overview

1. This is a single-page React application built with Vite. The runtime entry points are `src/main.jsx` and `src/App.jsx`, with global styling coming from `src/index.css`, `src/App.css`, Tailwind config, and the custom `src/styles/glass.css` theme layer.

2. The app is organized primarily as a route-driven product experience. The `src/pages` directory holds the top-level screens, while `src/components` contains reusable UI and domain widgets that are composed into those screens. For an architecture diagram, treat `pages` as the boundary between navigation-level views and `components` as the presentation/service widgets underneath them.

3. The product domain is education and career guidance, not a generic dashboard. The page set shows distinct workflows for students, parents, admins, schools, coaching institutes, and district-level intelligence. That makes the application more like a multi-tenant decision-support portal than a simple consumer app.

4. The student journey appears to start at onboarding and welcome/login flows, then move into planning and decision screens such as `Dashboard`, `StudentOnboarding`, `CareerMap`, `CareerMapAfter9th`, `AIDailyTimetable`, `StudyProgress`, and `StudentPlanner`. These screens likely feed recommendation and progress-tracking components for daily and long-term guidance.

5. The parent-facing area is separate and summarized through `ParentView` and `ParentWeeklySummary`, with supporting notification and planning widgets. This suggests a secondary read-only/oversight experience layered over the student guidance data, rather than a fully independent parent workflow.

6. The admin and institution side is also explicitly modeled. Pages like `AdminDashboard`, `AdminLogin`, `InstituteSelect`, `CoachingAnalytics`, `CoachingComparison`, `SchoolLeaderboard`, and `DistrictTrustScore` indicate management and comparison flows for schools/coaching institutes, with KPI-style metrics and trust/ROI analysis.

7. A major subsystem is the “AI / decision engine” feature set in `src/components`. Components such as `CareerDecisionEngine`, `BestInstituteMatch`, `InstituteComparisonAI`, `DistrictCareerScore`, `DistrictHeatmap`, `AIInsight`, `AIRecommendation`, `AISimulation`, `SmartExamStrategy`, and `LocalAlternativeAI` indicate a recommendation/scoring layer surfaced as UI modules. The repo does not show a dedicated backend ML service, so these appear to be front-end orchestration and visualization layers around heuristic or API-driven intelligence.

8. There is a clear data boundary between static/reference content and dynamic UI. `src/data/schools.js` and `src/data/coachings.jsx` hold domain datasets that likely power comparison, scoring, and listing screens. This makes the app partially data-driven even without a visible database layer in the repository.

9. External communication is abstracted behind `src/services/api.js`. That file is the main architectural seam for backend or third-party calls, and it is the likely integration point for authentication, AI responses, or fetched analytics. No other server code is present, so the frontend is the visible system and the API layer is the outbound boundary.

10. Internationalization is built into the UI architecture. `src/context/LanguageContext.jsx` and `src/utils/i18n.js`, plus the `LanguageToggle` component, show that language selection is a shared cross-cutting concern affecting many screens. In a diagram, this should be shown as a context/provider layer feeding text and labels across the app.

11. Navigation and shell components form the app scaffold: `Navbar`, `TopNav`, `Sidebar`, `NotificationPanel`, `FocusMode`, and `StatCard` provide persistent layout and common interaction patterns. These components are reused across pages to keep the experience consistent while the main content changes by workflow.

12. Overall, the architecture is a frontend-only, modular React portal with three main layers: route pages, reusable domain widgets, and shared context/service utilities. The key data flow is: static/reference data and API responses feed the decision/recommendation components, which then render persona-specific views for students, parents, institutions, and district administrators.

Main entry points: [`src/App.jsx`](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/App.jsx) (App), [`src/components/CareerDecisionEngine.jsx`](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/CareerDecisionEngine.jsx) (Decision engine), [`src/pages/CoachingAnalytics.jsx`](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CoachingAnalytics.jsx) (Coaching analytics), [`src/pages/DistrictCareerIntelligence.jsx`](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/DistrictCareerIntelligence.jsx) (District intelligence)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Runtime shell"]
  node_src_main["main<br/>Vite entry<br/>[main.jsx]"]
  node_src_app["App<br/>Router shell<br/>[App.jsx]"]
  node_src_lang_context(("Language context<br/>i18n provider"))
  node_src_i18n_utils["i18n utils<br/>translation helpers<br/>[i18n.js]"]
end

subgraph group_pages["Route pages"]
  node_src_welcome["Welcome<br/>auth entry<br/>[Welcome.jsx]"]
  node_src_login["Login<br/>auth page<br/>[Login.jsx]"]
  node_src_student_onboarding["Student onboarding<br/>student flow"]
  node_src_dashboard["Dashboard<br/>student hub<br/>[Dashboard.jsx]"]
  node_src_career_map["Career map<br/>student planning<br/>[CareerMap.jsx]"]
  node_src_parent_view["Parent view<br/>parent oversight<br/>[ParentView.jsx]"]
  node_src_admin_dashboard["Admin dashboard<br/>admin ops<br/>[AdminDashboard.jsx]"]
  node_src_coaching_analytics["Coaching analytics<br/>institution analytics"]
  node_src_district_intel["District intelligence<br/>district analytics"]
  node_src_coaching_comparison["Coach compare<br/>institution comparison"]
  node_src_school_leaderboard["School leaderboard<br/>school ranking"]
  node_src_district_trust["District trust<br/>district score"]
end

subgraph group_components["Shared components"]
  node_src_decision_engine{{"Decision engine<br/>ai orchestration"}}
  node_src_ai_recommendation["AI recommendation<br/>guidance widget"]
  node_src_institute_compare_ai["Institute AI compare<br/>comparison widget"]
  node_src_parent_summary["Weekly summary<br/>parent widget"]
  node_src_navbar["Navbar<br/>shell nav<br/>[Navbar.jsx]"]
  node_src_sidebar["Sidebar<br/>shell nav<br/>[Sidebar.jsx]"]
  node_src_language_toggle["Language toggle<br/>ui control<br/>[LanguageToggle.jsx]"]
end

subgraph group_data["Reference data"]
  node_src_schools_data["Schools data<br/>reference dataset<br/>[schools.js]"]
  node_src_coachings_data["Coachings data<br/>reference dataset<br/>[coachings.jsx]"]
end

subgraph group_services["Integration layer"]
  node_src_api[("API service<br/>external boundary<br/>[api.js]")]
end

node_src_main -->|"bootstraps"| node_src_app
node_src_app -->|"routes"| node_src_welcome
node_src_app -->|"routes"| node_src_login
node_src_app -->|"routes"| node_src_student_onboarding
node_src_app -->|"routes"| node_src_dashboard
node_src_app -->|"routes"| node_src_career_map
node_src_app -->|"routes"| node_src_parent_view
node_src_app -->|"routes"| node_src_admin_dashboard
node_src_app -->|"routes"| node_src_coaching_analytics
node_src_app -->|"routes"| node_src_district_intel
node_src_app -->|"shell"| node_src_navbar
node_src_app -->|"shell"| node_src_sidebar
node_src_app -->|"ui control"| node_src_language_toggle
node_src_lang_context -->|"provides"| node_src_language_toggle
node_src_lang_context -->|"feeds"| node_src_app
node_src_i18n_utils -->|"supports"| node_src_lang_context
node_src_decision_engine -->|"emits"| node_src_ai_recommendation
node_src_decision_engine -->|"drives"| node_src_institute_compare_ai
node_src_schools_data -->|"supplies"| node_src_institute_compare_ai
node_src_coachings_data -->|"supplies"| node_src_institute_compare_ai
node_src_parent_view -->|"uses"| node_src_parent_summary
node_src_dashboard -->|"uses"| node_src_decision_engine
node_src_career_map -->|"uses"| node_src_decision_engine
node_src_coaching_analytics -->|"fetches"| node_src_api
node_src_district_intel -->|"fetches"| node_src_api
node_src_admin_dashboard -->|"fetches"| node_src_api
node_src_coaching_analytics -->|"references"| node_src_coachings_data
node_src_district_intel -->|"references"| node_src_schools_data

click node_src_main "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/main.jsx"
click node_src_app "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/App.jsx"
click node_src_lang_context "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/context/LanguageContext.jsx"
click node_src_i18n_utils "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/utils/i18n.js"
click node_src_welcome "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Welcome.jsx"
click node_src_login "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Login.jsx"
click node_src_student_onboarding "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/StudentOnboarding.jsx"
click node_src_dashboard "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Dashboard.jsx"
click node_src_career_map "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CareerMap.jsx"
click node_src_parent_view "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/ParentView.jsx"
click node_src_admin_dashboard "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/AdminDashboard.jsx"
click node_src_coaching_analytics "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CoachingAnalytics.jsx"
click node_src_district_intel "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/DistrictCareerIntelligence.jsx"
click node_src_coaching_comparison "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CoachingComparison.jsx"
click node_src_school_leaderboard "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/SchoolLeaderboard.jsx"
click node_src_district_trust "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/DistrictTrustScore.jsx"
click node_src_decision_engine "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/CareerDecisionEngine.jsx"
click node_src_ai_recommendation "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/AIRecommendation.jsx"
click node_src_institute_compare_ai "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/InstituteComparisonAI.jsx"
click node_src_parent_summary "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/ParentWeeklySummary.jsx"
click node_src_navbar "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/Navbar.jsx"
click node_src_sidebar "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/Sidebar.jsx"
click node_src_language_toggle "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/LanguageToggle.jsx"
click node_src_schools_data "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/data/schools.js"
click node_src_coachings_data "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/data/coachings.jsx"
click node_src_api "https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/services/api.js"

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_src_main,node_src_app,node_src_lang_context,node_src_i18n_utils toneBlue
class node_src_welcome,node_src_login,node_src_student_onboarding,node_src_dashboard,node_src_career_map,node_src_parent_view,node_src_admin_dashboard,node_src_coaching_analytics,node_src_district_intel,node_src_coaching_comparison,node_src_school_leaderboard,node_src_district_trust toneAmber
class node_src_decision_engine,node_src_ai_recommendation,node_src_institute_compare_ai,node_src_parent_summary,node_src_navbar,node_src_sidebar,node_src_language_toggle toneMint
class node_src_schools_data,node_src_coachings_data toneRose
class node_src_api toneIndigo
```

## Components

### Runtime shell

Vite entry, app bootstrap, global styling, and language context.

- [main](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/main.jsx): Vite entry · Bootstraps the React app. · `src/main.jsx`
- [App](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/App.jsx): Router shell · Top-level app composition and route orchestration. · `src/App.jsx`
- [Language context](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/context/LanguageContext.jsx): i18n provider · Shared language state for the UI. · `src/context/LanguageContext.jsx`
- [i18n utils](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/utils/i18n.js): translation helpers · Language and copy lookup utilities. · `src/utils/i18n.js`

### Route pages

Top-level screens organized by persona and workflow.

- [Welcome](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Welcome.jsx): auth entry · Landing and welcome flow. · `src/pages/Welcome.jsx`
- [Login](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Login.jsx): auth page · Sign-in flow for the portal. · `src/pages/Login.jsx`
- [Student onboarding](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/StudentOnboarding.jsx): student flow · Initial student setup and profile capture. · `src/pages/StudentOnboarding.jsx`
- [Dashboard](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/Dashboard.jsx): student hub · Primary student workspace. · `src/pages/Dashboard.jsx`
- [Career map](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CareerMap.jsx): student planning · Career exploration and guidance screen. · `src/pages/CareerMap.jsx`
- [Parent view](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/ParentView.jsx): parent oversight · Read-only parent-facing summary view. · `src/pages/ParentView.jsx`
- [Admin dashboard](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/AdminDashboard.jsx): admin ops · Administrative control and reporting surface. · `src/pages/AdminDashboard.jsx`
- [Coaching analytics](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CoachingAnalytics.jsx): institution analytics · Institution performance and KPI workflow. · `src/pages/CoachingAnalytics.jsx`
- [District intelligence](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/DistrictCareerIntelligence.jsx): district analytics · District-level decision and opportunity intelligence. · `src/pages/DistrictCareerIntelligence.jsx`
- [Coach compare](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/CoachingComparison.jsx): institution comparison · Side-by-side comparison of coaching options. · `src/pages/CoachingComparison.jsx`
- [School leaderboard](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/SchoolLeaderboard.jsx): school ranking · Relative ranking and trust/score views for schools. · `src/pages/SchoolLeaderboard.jsx`
- [District trust](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/pages/DistrictTrustScore.jsx): district score · Trust and score view for district-level evaluation. · `src/pages/DistrictTrustScore.jsx`

### Shared components

Reusable shell, widgets, and decision UI used across pages.

- [Decision engine](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/CareerDecisionEngine.jsx): ai orchestration · Core recommendation and scoring logic surfaced in the UI. · `src/components/CareerDecisionEngine.jsx`
- [AI recommendation](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/AIRecommendation.jsx): guidance widget · Recommendation output component. · `src/components/AIRecommendation.jsx`
- [Institute AI compare](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/InstituteComparisonAI.jsx): comparison widget · AI-assisted institute comparison and matching. · `src/components/InstituteComparisonAI.jsx`
- [Weekly summary](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/ParentWeeklySummary.jsx): parent widget · Parent-facing progress and notification summary. · `src/components/ParentWeeklySummary.jsx`
- [Navbar](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/Navbar.jsx): shell nav · Primary navigation shell component. · `src/components/Navbar.jsx`
- [Sidebar](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/Sidebar.jsx): shell nav · Secondary navigation and layout scaffold. · `src/components/Sidebar.jsx`
- [Language toggle](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/components/LanguageToggle.jsx): ui control · Language switching control. · `src/components/LanguageToggle.jsx`

### Reference data

Static domain datasets for schools and coaching institutes.

- [Schools data](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/data/schools.js): reference dataset · Static school reference data. · `src/data/schools.js`
- [Coachings data](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/data/coachings.jsx): reference dataset · Static coaching institute dataset. · `src/data/coachings.jsx`

### Integration layer

Frontend boundary for API and external data or AI calls.

- [API service](https://github.com/abhi-148/up-student-ai-copilot/blob/main/src/services/api.js): external boundary · Single frontend integration seam for backend or third-party calls. · `src/services/api.js`

## Connections

- main → App: bootstraps · React entry mounts the application shell.
- App → Welcome: routes · App routes to the welcome entry screen.
- App → Login: routes · App routes to authentication screens.
- App → Student onboarding: routes · App routes to student setup.
- App → Dashboard: routes · App routes to the student hub.
- App → Career map: routes · App routes to career guidance screens.
- App → Parent view: routes · App routes to parent oversight views.
- App → Admin dashboard: routes · App routes to admin operations.
- App → Coaching analytics: routes · App routes to institution analytics.
- App → District intelligence: routes · App routes to district intelligence pages.
- App → Navbar: shell · Global navigation component reused across views.
- App → Sidebar: shell · Layout scaffold used across the portal.
- App → Language toggle: ui control · Language switching is available from the app shell.
- Language context → Language toggle: provides · Toggle consumes shared language state.
- Language context → App: feeds · Context is available to routed screens and shell.
- i18n utils → Language context: supports · Translation utilities back the language provider.
- Decision engine → AI recommendation: emits · Core guidance engine drives recommendation UI.
- Decision engine → Institute AI compare: drives · Decision logic powers institute matching and comparison.
- Schools data → Institute AI compare: supplies · School reference data feeds comparison workflows.
- Coachings data → Institute AI compare: supplies · Coaching dataset feeds comparison workflows.
- Parent view → Weekly summary: uses · Parent view is summarized through weekly insights.
- Dashboard → Decision engine: uses · Student hub surfaces guidance and scoring.
- Career map → Decision engine: uses · Career exploration is powered by decision logic.
- Coaching analytics → API service: fetches · Analytics pages likely pull live or aggregated data.
- District intelligence → API service: fetches · District intelligence depends on external data or AI calls.
- Admin dashboard → API service: fetches · Admin workflows integrate with backend services.
- Coaching analytics → Coachings data: references · Analytics may combine live metrics with local coaching data.
- District intelligence → Schools data: references · District views draw from school reference data.
