# jatingarg850/resume architecture

> Architecture diagram of the GitHub repository jatingarg850/resume, 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/jatingarg850/resume
- Repository: https://github.com/jatingarg850/resume

## Overview

TalentLens is a local AI-assisted resume-screening application for recruiters, hiring managers, candidates, and guest applicants. Its main workflow takes job descriptions and incoming resumes through criteria extraction, resume parsing and structured profiling, deterministic explainable scoring, recruiter review and decisions, and candidate-facing status and feedback. The map also includes search, comparison, Q&A, analytics, administration, retention, and optional Ollama-backed extraction and embeddings. Relationships are limited to those shown in excerpts, the SOURCE INDEX, or README; unsampled subsystem internals are not inferred.

Main entry points: [`app/api/jobs.py`](https://github.com/jatingarg850/resume/blob/main/app/api/jobs.py) (Jobs and review API), [`app/ai/extraction.py`](https://github.com/jatingarg850/resume/blob/main/app/ai/extraction.py) (Profile and criteria extraction), [`static/js/main.js`](https://github.com/jatingarg850/resume/blob/main/static/js/main.js) (Recruiter app), [`app/services/worker.py`](https://github.com/jatingarg850/resume/blob/main/app/services/worker.py) (Background resume worker)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["User interfaces"]
  node_recruiter_ui["Recruiter app<br/>[main.js]"]
  node_candidate_ui["Candidate portal<br/>[portal.js]"]
  node_guest_ui["Guest apply<br/>[apply.js]"]
  node_ui_core["UI core<br/>[core.js]"]
end

subgraph group_api["Application API"]
  node_auth_api["Staff authentication<br/>[auth.py]"]
  node_jobs_api["Jobs and review API<br/>[jobs.py]"]
  node_candidate_api["Candidate review API<br/>[candidates.py]"]
  node_portal_api["Candidate portal API<br/>[portal.py]"]
  node_public_api["Public apply API<br/>[public.py]"]
  node_admin_api["Admin API<br/>[admin.py]"]
end

subgraph group_processing["Resume processing"]
  node_resume_parser["Resume text parser<br/>[parser.py]"]
  node_profile_extract["Profile and criteria extraction<br/>[extraction.py]"]
  node_rule_extract["Rule-based extraction<br/>[rules.py]"]
  node_worker["Background resume worker<br/>[worker.py]"]
  node_ollama["Ollama client<br/>[ollama_client.py]"]
  node_embeddings["Embedding service<br/>[embeddings.py]"]
end

subgraph group_matching["Matching and review"]
  node_ranking["Ranking and analytics<br/>[ranking.py]"]
  node_scoring["Deterministic scoring<br/>[scoring.py]"]
  node_skills["Skill matching<br/>[skills.py]"]
  node_review_tools["Explain, search, compare, Q&amp;A"]
end

subgraph group_platform["Identity and data"]
  node_security["Sessions and roles<br/>[security.py]"]
  node_audit["Audit logging<br/>[audit.py]"]
  node_retention["Data retention<br/>[retention.py]"]
  node_db[("Application database<br/>[db.py]")]
  node_storage[("Encrypted resume files<br/>[storage.py]")]
  node_vectors[("Embedding vectors<br/>[vectors.py]")]
end

node_recruiter(("Recruiter / HR"))
node_candidate(("Candidate / guest"))
node_ollama_service(("Ollama service<br/>external service"))

node_recruiter -->|"uses"| node_recruiter_ui
node_candidate -->|"uses"| node_candidate_ui
node_candidate -->|"applies through"| node_guest_ui
node_recruiter_ui -->|"uses"| node_ui_core
node_recruiter_ui -->|"requests"| node_auth_api
node_recruiter_ui -->|"requests"| node_jobs_api
node_candidate_ui -->|"requests"| node_portal_api
node_guest_ui -->|"submits to"| node_public_api
node_auth_api -->|"authenticates with"| node_security
node_jobs_api -->|"extracts criteria"| node_profile_extract
node_jobs_api -->|"queues resumes"| node_worker
node_jobs_api -->|"requests ranking"| node_ranking
node_jobs_api -->|"uses review tools"| node_review_tools
node_candidate_api -->|"parses resume"| node_resume_parser
node_candidate_api -->|"provides Q&amp;A"| node_review_tools
node_portal_api -->|"extracts application"| node_profile_extract
node_public_api -->|"extracts application"| node_profile_extract
node_worker -->|"structures profile"| node_profile_extract
node_worker -->|"reads and updates"| node_db
node_profile_extract -->|"uses rules"| node_rule_extract
node_profile_extract -->|"requests AI extraction"| node_ollama
node_worker -->|"ensures embeddings"| node_embeddings
node_ranking -->|"scores candidates"| node_scoring
node_scoring -->|"matches skills"| node_skills
node_ranking -->|"builds explanations"| node_review_tools
node_embeddings -->|"requests vectors"| node_ollama
node_embeddings -->|"reads and writes"| node_vectors
node_admin_api -->|"configures retention"| node_retention
node_admin_api -->|"checks models"| node_ollama
node_jobs_api -->|"records decisions"| node_audit
node_portal_api -->|"audits changes"| node_audit
node_security -->|"stores sessions"| node_db
node_audit -->|"writes audit log"| node_db
node_retention -->|"purges records"| node_db
node_retention -->|"purges files"| node_storage
node_ollama -.->|"calls optionally"| node_ollama_service

click node_recruiter_ui "https://github.com/jatingarg850/resume/blob/main/static/js/main.js"
click node_candidate_ui "https://github.com/jatingarg850/resume/blob/main/static/js/views/portal.js"
click node_guest_ui "https://github.com/jatingarg850/resume/blob/main/static/js/views/apply.js"
click node_ui_core "https://github.com/jatingarg850/resume/blob/main/static/js/core.js"
click node_auth_api "https://github.com/jatingarg850/resume/blob/main/app/api/auth.py"
click node_jobs_api "https://github.com/jatingarg850/resume/blob/main/app/api/jobs.py"
click node_candidate_api "https://github.com/jatingarg850/resume/blob/main/app/api/candidates.py"
click node_portal_api "https://github.com/jatingarg850/resume/blob/main/app/api/portal.py"
click node_public_api "https://github.com/jatingarg850/resume/blob/main/app/api/public.py"
click node_admin_api "https://github.com/jatingarg850/resume/blob/main/app/api/admin.py"
click node_resume_parser "https://github.com/jatingarg850/resume/blob/main/app/ai/parser.py"
click node_profile_extract "https://github.com/jatingarg850/resume/blob/main/app/ai/extraction.py"
click node_rule_extract "https://github.com/jatingarg850/resume/blob/main/app/ai/rules.py"
click node_worker "https://github.com/jatingarg850/resume/blob/main/app/services/worker.py"
click node_ollama "https://github.com/jatingarg850/resume/blob/main/app/ai/ollama_client.py"
click node_ranking "https://github.com/jatingarg850/resume/blob/main/app/services/ranking.py"
click node_scoring "https://github.com/jatingarg850/resume/blob/main/app/matching/scoring.py"
click node_skills "https://github.com/jatingarg850/resume/blob/main/app/matching/skills.py"
click node_review_tools "https://github.com/jatingarg850/resume/tree/main/app/matching"
click node_security "https://github.com/jatingarg850/resume/blob/main/app/core/security.py"
click node_audit "https://github.com/jatingarg850/resume/blob/main/app/core/audit.py"
click node_retention "https://github.com/jatingarg850/resume/blob/main/app/services/retention.py"
click node_db "https://github.com/jatingarg850/resume/blob/main/app/data/db.py"
click node_storage "https://github.com/jatingarg850/resume/blob/main/app/data/storage.py"
click node_vectors "https://github.com/jatingarg850/resume/blob/main/app/data/vectors.py"
click node_embeddings "https://github.com/jatingarg850/resume/blob/main/app/ai/embeddings.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_recruiter_ui,node_candidate_ui,node_guest_ui,node_ui_core toneBlue
class node_auth_api,node_jobs_api,node_candidate_api,node_portal_api,node_public_api,node_admin_api toneAmber
class node_resume_parser,node_profile_extract,node_rule_extract,node_worker,node_ollama,node_embeddings toneMint
class node_ranking,node_scoring,node_skills,node_review_tools toneRose
class node_security,node_audit,node_retention,node_db,node_storage,node_vectors,node_recruiter,node_candidate,node_ollama_service toneIndigo
```

## Components

### User interfaces

- [Recruiter app](https://github.com/jatingarg850/resume/blob/main/static/js/main.js): `static/js/main.js`
- [Candidate portal](https://github.com/jatingarg850/resume/blob/main/static/js/views/portal.js): `static/js/views/portal.js`
- [Guest apply](https://github.com/jatingarg850/resume/blob/main/static/js/views/apply.js): `static/js/views/apply.js`
- [UI core](https://github.com/jatingarg850/resume/blob/main/static/js/core.js): `static/js/core.js`

### Application API

- [Staff authentication](https://github.com/jatingarg850/resume/blob/main/app/api/auth.py): `app/api/auth.py`
- [Jobs and review API](https://github.com/jatingarg850/resume/blob/main/app/api/jobs.py): `app/api/jobs.py`
- [Candidate review API](https://github.com/jatingarg850/resume/blob/main/app/api/candidates.py): `app/api/candidates.py`
- [Candidate portal API](https://github.com/jatingarg850/resume/blob/main/app/api/portal.py): `app/api/portal.py`
- [Public apply API](https://github.com/jatingarg850/resume/blob/main/app/api/public.py): `app/api/public.py`
- [Admin API](https://github.com/jatingarg850/resume/blob/main/app/api/admin.py): `app/api/admin.py`

### Resume processing

- [Resume text parser](https://github.com/jatingarg850/resume/blob/main/app/ai/parser.py): `app/ai/parser.py`
- [Profile and criteria extraction](https://github.com/jatingarg850/resume/blob/main/app/ai/extraction.py): `app/ai/extraction.py`
- [Rule-based extraction](https://github.com/jatingarg850/resume/blob/main/app/ai/rules.py): `app/ai/rules.py`
- [Background resume worker](https://github.com/jatingarg850/resume/blob/main/app/services/worker.py): `app/services/worker.py`
- [Ollama client](https://github.com/jatingarg850/resume/blob/main/app/ai/ollama_client.py): `app/ai/ollama_client.py`
- [Embedding service](https://github.com/jatingarg850/resume/blob/main/app/ai/embeddings.py): `app/ai/embeddings.py`

### Matching and review

- [Ranking and analytics](https://github.com/jatingarg850/resume/blob/main/app/services/ranking.py): `app/services/ranking.py`
- [Deterministic scoring](https://github.com/jatingarg850/resume/blob/main/app/matching/scoring.py): `app/matching/scoring.py`
- [Skill matching](https://github.com/jatingarg850/resume/blob/main/app/matching/skills.py): `app/matching/skills.py`
- [Explain, search, compare, Q&A](https://github.com/jatingarg850/resume/tree/main/app/matching): `app/matching`

### Identity and data

- [Sessions and roles](https://github.com/jatingarg850/resume/blob/main/app/core/security.py): `app/core/security.py`
- [Audit logging](https://github.com/jatingarg850/resume/blob/main/app/core/audit.py): `app/core/audit.py`
- [Data retention](https://github.com/jatingarg850/resume/blob/main/app/services/retention.py): `app/services/retention.py`
- [Application database](https://github.com/jatingarg850/resume/blob/main/app/data/db.py): `app/data/db.py`
- [Encrypted resume files](https://github.com/jatingarg850/resume/blob/main/app/data/storage.py): `app/data/storage.py`
- [Embedding vectors](https://github.com/jatingarg850/resume/blob/main/app/data/vectors.py): `app/data/vectors.py`

### Other components

- **Recruiter / HR**
- **Candidate / guest**
- **Ollama service**: external service

## Connections

- Recruiter / HR → Recruiter app: uses
- Candidate / guest → Candidate portal: uses
- Candidate / guest → Guest apply: applies through
- Recruiter app → UI core: uses (evidence: `static/js/main.js`)
- Recruiter app → Staff authentication: requests
- Recruiter app → Jobs and review API: requests
- Candidate portal → Candidate portal API: requests
- Guest apply → Public apply API: submits to
- Staff authentication → Sessions and roles: authenticates with (evidence: `app/api/auth.py`)
- Jobs and review API → Profile and criteria extraction: extracts criteria (evidence: `app/api/jobs.py`)
- Jobs and review API → Background resume worker: queues resumes (evidence: `app/api/jobs.py`)
- Jobs and review API → Ranking and analytics: requests ranking (evidence: `app/api/jobs.py`)
- Jobs and review API → Explain, search, compare, Q&A: uses review tools (evidence: `app/api/jobs.py`)
- Candidate review API → Resume text parser: parses resume (evidence: `app/api/candidates.py`)
- Candidate review API → Explain, search, compare, Q&A: provides Q&A (evidence: `app/api/candidates.py`)
- Candidate portal API → Profile and criteria extraction: extracts application (evidence: `app/api/portal.py`)
- Public apply API → Profile and criteria extraction: extracts application (evidence: `app/api/public.py`)
- Background resume worker → Profile and criteria extraction: structures profile (evidence: `app/services/worker.py`)
- Background resume worker → Application database: reads and updates (evidence: `app/services/worker.py`)
- Profile and criteria extraction → Rule-based extraction: uses rules (evidence: `app/ai/extraction.py`)
- Profile and criteria extraction → Ollama client: requests AI extraction (evidence: `app/ai/extraction.py`)
- Background resume worker → Embedding service: ensures embeddings (evidence: `app/services/worker.py`)
- Ranking and analytics → Deterministic scoring: scores candidates (evidence: `app/services/ranking.py`)
- Deterministic scoring → Skill matching: matches skills (evidence: `app/matching/scoring.py`)
- Ranking and analytics → Explain, search, compare, Q&A: builds explanations (evidence: `app/services/ranking.py`)
- Embedding service → Ollama client: requests vectors (evidence: `app/ai/embeddings.py`)
- Embedding service → Embedding vectors: reads and writes (evidence: `app/ai/embeddings.py`)
- Admin API → Data retention: configures retention (evidence: `app/api/admin.py`)
- Admin API → Ollama client: checks models (evidence: `app/api/admin.py`)
- Jobs and review API → Audit logging: records decisions (evidence: `app/api/jobs.py`)
- Candidate portal API → Audit logging: audits changes (evidence: `app/api/portal.py`)
- Sessions and roles → Application database: stores sessions (evidence: `app/core/security.py`)
- Audit logging → Application database: writes audit log (evidence: `app/core/audit.py`)
- Data retention → Application database: purges records (evidence: `app/services/retention.py`)
- Data retention → Encrypted resume files: purges files (evidence: `app/services/retention.py`)
- Ollama client → Ollama service: calls optionally
