# harishpullagurla/codecred_ai architecture

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

- Interactive diagram: https://gitdiagram.com/harishpullagurla/codecred_ai
- Repository: https://github.com/harishpullagurla/codecred_ai

## Overview

CodeCred AI is a Flask web application for comparing skills claimed in a resume with evidence from a candidate’s GitHub repositories. A user submits a GitHub username and PDF resume; the Flask route extracts resume text, fetches and scans repositories for languages and technologies, then asks Gemini to generate an HTML verification report. The report is returned to the frontend. The sampled backend shows these calls; the frontend source was not sampled, so its submission and result-display connections are unverified.

Main entry points: [`app.py`](https://github.com/harishpullagurla/codecred_ai/blob/main/app.py) (Flask routes), [`templates/index.html`](https://github.com/harishpullagurla/codecred_ai/blob/main/templates/index.html) (Web interface), [`services/pdf_service.py`](https://github.com/harishpullagurla/codecred_ai/blob/main/services/pdf_service.py) (Resume extraction), [`services/github_service.py`](https://github.com/harishpullagurla/codecred_ai/blob/main/services/github_service.py) (GitHub repository scan)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web application"]
  node_frontend["Web interface<br/>[index.html]"]
  node_app["Flask routes<br/>[app.py]"]
end

subgraph group_evidence["Evidence collection"]
  node_pdf["Resume extraction<br/>[pdf_service.py]"]
  node_github["GitHub repository scan<br/>[github_service.py]"]
end

subgraph group_analysis["Verification analysis"]
  node_ai["Skill verification report<br/>[ai_service.py]"]
end

node_user(("Candidate or reviewer"))
node_github_api["GitHub REST API"]
node_pypdf["PDF reader library"]
node_gemini["Google Gemini API"]

node_app -->|"renders page"| node_frontend
node_user -.->|"uses"| node_frontend
node_frontend -.->|"submits analysis"| node_app
node_app -->|"extracts resume"| node_pdf
node_pdf -->|"reads PDF"| node_pypdf
node_app -->|"fetches evidence"| node_github
node_github -->|"requests repository data"| node_github_api
node_app -->|"requests report"| node_ai
node_ai -->|"generates report"| node_gemini

click node_frontend "https://github.com/harishpullagurla/codecred_ai/blob/main/templates/index.html"
click node_app "https://github.com/harishpullagurla/codecred_ai/blob/main/app.py"
click node_pdf "https://github.com/harishpullagurla/codecred_ai/blob/main/services/pdf_service.py"
click node_github "https://github.com/harishpullagurla/codecred_ai/blob/main/services/github_service.py"
click node_ai "https://github.com/harishpullagurla/codecred_ai/blob/main/services/ai_service.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_frontend,node_app,node_user toneBlue
class node_pdf,node_github toneAmber
class node_ai,node_github_api,node_gemini toneMint
class node_pypdf toneIndigo
```

## Components

### Web application

- [Web interface](https://github.com/harishpullagurla/codecred_ai/blob/main/templates/index.html): `templates/index.html`
- [Flask routes](https://github.com/harishpullagurla/codecred_ai/blob/main/app.py): `app.py`

### Evidence collection

- [Resume extraction](https://github.com/harishpullagurla/codecred_ai/blob/main/services/pdf_service.py): `services/pdf_service.py`
- [GitHub repository scan](https://github.com/harishpullagurla/codecred_ai/blob/main/services/github_service.py): `services/github_service.py`

### Verification analysis

- [Skill verification report](https://github.com/harishpullagurla/codecred_ai/blob/main/services/ai_service.py): `services/ai_service.py`

### Other components

- **Candidate or reviewer**
- **GitHub REST API**
- **PDF reader library**
- **Google Gemini API**

## Connections

- Flask routes → Web interface: renders page (evidence: `app.py`)
- Candidate or reviewer → Web interface: uses
- Web interface → Flask routes: submits analysis
- Flask routes → Resume extraction: extracts resume (evidence: `app.py`)
- Resume extraction → PDF reader library: reads PDF (evidence: `services/pdf_service.py`)
- Flask routes → GitHub repository scan: fetches evidence (evidence: `app.py`)
- GitHub repository scan → GitHub REST API: requests repository data (evidence: `services/github_service.py`)
- Flask routes → Skill verification report: requests report (evidence: `app.py`)
- Skill verification report → Google Gemini API: generates report (evidence: `services/ai_service.py`)
