# kanglesoham11-code/hirepath architecture

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

- Interactive diagram: https://gitdiagram.com/kanglesoham11-code/hirepath
- Repository: https://github.com/kanglesoham11-code/hirepath

## Overview

HirePath is a consent-first recruiting platform: recruiters manage roles in a React dashboard, source live candidates, screen their public evidence, conduct consent-gated outreach, coordinate interviews, and monitor pipeline and compliance activity. FastAPI exposes the workflow and SSE updates; shared database, evidence, privacy, and LLM utilities support it. The README documents several integrations and capabilities whose implementation was not sampled, so those links are shown as documented rather than inferred from unsampled code.

Main entry points: [`backend/database.py`](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/database.py) (Recruiting and audit data), [`backend/agents/scout.py`](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/scout.py) (Live sourcing), [`backend/main.py`](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/main.py) (REST and SSE API), [`backend/orchestrator.py`](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/orchestrator.py) (Pipeline orchestrator)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_dashboard["Recruiter dashboard"]
  node_dashboard_app["Dashboard app<br/>[App.tsx]"]
  node_app_state["Dashboard state<br/>[AppContext.tsx]"]
  node_role_workspace["Role workspace"]
  node_activity_compliance["Activity and compliance<br/>[ComplianceView.tsx]"]
  node_api_client["API client<br/>[api.ts]"]
end

subgraph group_backend["API and orchestration"]
  node_fastapi["REST and SSE API<br/>[main.py]"]
  node_orchestrator["Pipeline orchestrator<br/>[orchestrator.py]"]
end

subgraph group_workflow["Recruiting workflow"]
  node_sourcing["Live sourcing<br/>[scout.py]"]
  node_screening["Candidate screening<br/>[screen.py]"]
  node_outreach["Consent-first outreach<br/>[engage.py]"]
  node_interviews["Interview coordination<br/>[coord.py]"]
  node_pipeline_analytics["Pipeline analytics<br/>[track.py]"]
  node_privacy_controls["Privacy controls<br/>[privacy.py]"]
end

subgraph group_shared["Shared services"]
  node_database[("Recruiting and audit data<br/>[database.py]")]
  node_evidence["Evidence validation<br/>[evidence.py]"]
  node_location["Location resolver"]
  node_llm["LLM client<br/>[llm.py]"]
end

node_recruiter(("Recruiter"))
node_github{{"GitHub APIs"}}
node_stackoverflow{{"StackExchange API"}}
node_groq{{"Groq API"}}
node_smtp{{"Gmail SMTP"}}
node_calendar{{"Google Calendar"}}
node_slack{{"Slack webhook"}}

node_recruiter -->|"uses"| node_dashboard_app
node_dashboard_app -->|"provides state"| node_app_state
node_dashboard_app -->|"renders"| node_role_workspace
node_dashboard_app -->|"renders"| node_activity_compliance
node_app_state -->|"calls"| node_api_client
node_api_client -.->|"sends requests"| node_fastapi
node_fastapi -.->|"dispatches workflow"| node_orchestrator
node_fastapi -->|"runs sourcing"| node_sourcing
node_orchestrator -->|"dispatches"| node_sourcing
node_orchestrator -->|"dispatches"| node_screening
node_orchestrator -->|"dispatches"| node_outreach
node_orchestrator -->|"dispatches"| node_pipeline_analytics
node_sourcing -->|"queries profiles"| node_github
node_sourcing -->|"queries profiles"| node_stackoverflow
node_sourcing -->|"resolves locations"| node_location
node_sourcing -->|"persists candidates"| node_database
node_screening -->|"reads and updates"| node_database
node_screening -->|"validates sources"| node_evidence
node_screening -->|"requests evaluation"| node_llm
node_llm -->|"sends inference"| node_groq
node_outreach -->|"reads and updates"| node_database
node_outreach -->|"validates sources"| node_evidence
node_outreach -->|"signs privacy links"| node_privacy_controls
node_outreach -->|"sends email"| node_smtp
node_interviews -.->|"records interviews"| node_database
node_interviews -->|"books meetings"| node_calendar
node_pipeline_analytics -->|"reads pipeline"| node_database
node_privacy_controls -.->|"supports privacy actions"| node_database
node_fastapi -->|"serves data"| node_database
node_fastapi -.->|"streams activity"| node_app_state
node_pipeline_analytics -.->|"sends alerts"| node_slack

click node_dashboard_app "https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/App.tsx"
click node_app_state "https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/context/AppContext.tsx"
click node_role_workspace "https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/components/RoleWorkspaceView.tsx"
click node_activity_compliance "https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/components/ComplianceView.tsx"
click node_api_client "https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/services/api.ts"
click node_fastapi "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/main.py"
click node_orchestrator "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/orchestrator.py"
click node_sourcing "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/scout.py"
click node_screening "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/screen.py"
click node_outreach "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/engage.py"
click node_interviews "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/coord.py"
click node_pipeline_analytics "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/track.py"
click node_privacy_controls "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/privacy.py"
click node_database "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/database.py"
click node_evidence "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/evidence.py"
click node_location "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/location_resolver.py"
click node_llm "https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/llm.py"

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_dashboard_app,node_app_state,node_role_workspace,node_activity_compliance,node_api_client toneBlue
class node_fastapi,node_orchestrator toneAmber
class node_sourcing,node_screening,node_outreach,node_interviews,node_pipeline_analytics,node_privacy_controls,node_github,node_stackoverflow,node_groq,node_slack toneMint
class node_database,node_evidence,node_location,node_llm toneRose
class node_recruiter,node_smtp,node_calendar toneIndigo
```

## Components

### Recruiter dashboard

- [Dashboard app](https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/App.tsx): `frontend_src/src/App.tsx`
- [Dashboard state](https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/context/AppContext.tsx): `frontend_src/src/context/AppContext.tsx`
- [Role workspace](https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/components/RoleWorkspaceView.tsx): `frontend_src/src/components/RoleWorkspaceView.tsx`
- [Activity and compliance](https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/components/ComplianceView.tsx): `frontend_src/src/components/ComplianceView.tsx`
- [API client](https://github.com/kanglesoham11-code/hirepath/blob/main/frontend_src/src/services/api.ts): `frontend_src/src/services/api.ts`

### API and orchestration

- [REST and SSE API](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/main.py): `backend/main.py`
- [Pipeline orchestrator](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/orchestrator.py): `backend/orchestrator.py`

### Recruiting workflow

- [Live sourcing](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/scout.py): `backend/agents/scout.py`
- [Candidate screening](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/screen.py): `backend/agents/screen.py`
- [Consent-first outreach](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/engage.py): `backend/agents/engage.py`
- [Interview coordination](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/coord.py): `backend/agents/coord.py`
- [Pipeline analytics](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/agents/track.py): `backend/agents/track.py`
- [Privacy controls](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/privacy.py): `backend/utils/privacy.py`

### Shared services

- [Recruiting and audit data](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/database.py): `backend/database.py`
- [Evidence validation](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/evidence.py): `backend/utils/evidence.py`
- [Location resolver](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/location_resolver.py): `backend/utils/location_resolver.py`
- [LLM client](https://github.com/kanglesoham11-code/hirepath/blob/main/backend/utils/llm.py): `backend/utils/llm.py`

### Other components

- **Recruiter**
- **GitHub APIs**
- **StackExchange API**
- **Groq API**
- **Gmail SMTP**
- **Google Calendar**
- **Slack webhook**

## Connections

- Recruiter → Dashboard app: uses
- Dashboard app → Dashboard state: provides state (evidence: `frontend_src/src/App.tsx`)
- Dashboard app → Role workspace: renders (evidence: `frontend_src/src/App.tsx`)
- Dashboard app → Activity and compliance: renders (evidence: `frontend_src/src/App.tsx`)
- Dashboard state → API client: calls (evidence: `frontend_src/src/context/AppContext.tsx`)
- API client → REST and SSE API: sends requests
- REST and SSE API → Pipeline orchestrator: dispatches workflow (evidence: `backend/main.py`)
- REST and SSE API → Live sourcing: runs sourcing (evidence: `backend/main.py`)
- Pipeline orchestrator → Live sourcing: dispatches (evidence: `backend/orchestrator.py`)
- Pipeline orchestrator → Candidate screening: dispatches (evidence: `backend/orchestrator.py`)
- Pipeline orchestrator → Consent-first outreach: dispatches (evidence: `backend/orchestrator.py`)
- Pipeline orchestrator → Pipeline analytics: dispatches (evidence: `backend/orchestrator.py`)
- Live sourcing → GitHub APIs: queries profiles
- Live sourcing → StackExchange API: queries profiles
- Live sourcing → Location resolver: resolves locations (evidence: `backend/agents/scout.py`)
- Live sourcing → Recruiting and audit data: persists candidates (evidence: `backend/agents/scout.py`)
- Candidate screening → Recruiting and audit data: reads and updates (evidence: `backend/agents/screen.py`)
- Candidate screening → Evidence validation: validates sources (evidence: `backend/agents/screen.py`)
- Candidate screening → LLM client: requests evaluation (evidence: `backend/agents/screen.py`)
- LLM client → Groq API: sends inference (evidence: `backend/utils/llm.py`)
- Consent-first outreach → Recruiting and audit data: reads and updates (evidence: `backend/agents/engage.py`)
- Consent-first outreach → Evidence validation: validates sources (evidence: `backend/agents/engage.py`)
- Consent-first outreach → Privacy controls: signs privacy links (evidence: `backend/agents/engage.py`)
- Consent-first outreach → Gmail SMTP: sends email
- Interview coordination → Recruiting and audit data: records interviews (evidence: `backend/agents/coord.py`)
- Interview coordination → Google Calendar: books meetings
- Pipeline analytics → Recruiting and audit data: reads pipeline (evidence: `backend/agents/track.py`)
- Privacy controls → Recruiting and audit data: supports privacy actions
- REST and SSE API → Recruiting and audit data: serves data (evidence: `backend/main.py`)
- REST and SSE API → Dashboard state: streams activity
- Pipeline analytics → Slack webhook: sends alerts
