# thayaa21/linkedin architecture

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

- Interactive diagram: https://gitdiagram.com/thayaa21/linkedin
- Repository: https://github.com/thayaa21/linkedin

## Overview

The product automates referral outreach: it polls new LinkedIn connections, identifies their employers, matches them to recent applications, queues eligible people, finds company resumes, and sends personalized DMs while maintaining sheet statuses. The scheduler/orchestrator owns these actions; Sheets, Drive, LinkedIn, and optional OpenAI are external services. Dashboard monitoring and resume sync are documented companion capabilities. Unsampled subsystems are represented only where README or indexed references support them.

Main entry points: [`main.py`](https://github.com/thayaa21/linkedin/blob/main/main.py) (Poll and send jobs), [`sheets.py`](https://github.com/thayaa21/linkedin/blob/main/sheets.py) (Applications and date window), [`dashboard.py`](https://github.com/thayaa21/linkedin/blob/main/dashboard.py) (Monitoring dashboard), [`matcher.py`](https://github.com/thayaa21/linkedin/blob/main/matcher.py) (Headline extraction and matching)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_workflow["Outreach workflow"]
  node_orchestrator["Poll and send jobs<br/>[main.py]"]
  node_company_extract["Headline extraction and matching<br/>[matcher.py]"]
end

subgraph group_integrations["External integrations"]
  node_linkedin["Connection scraping and DMs<br/>[linkedin.py]"]
  node_tracker[("Applications and date window<br/>[sheets.py]")]
  node_sent_queue[("Pending and sent records<br/>[sheets.py]")]
  node_snapshot[("Connection snapshot<br/>[sheets.py]")]
  node_resume_lookup["Resume lookup<br/>[drive.py]"]
  node_drive_service[("Google Drive")]
  node_linkedin_service["LinkedIn"]
  node_sheets_service[("Google Sheets")]
  node_openai["OpenAI extraction"]
end

subgraph group_operations["Monitoring and utilities"]
  node_dashboard["Monitoring dashboard<br/>[dashboard.py]"]
  node_resume_sync["Resume sync<br/>[sync_resumes.py]"]
  node_github_actions["Scheduled workflows"]
end

subgraph group_settings["Configuration"]
  node_config["Runtime settings<br/>[config.py]"]
end

node_applicant(("Applicant"))

node_github_actions -->|"triggers"| node_orchestrator
node_applicant -->|"records applications"| node_tracker
node_orchestrator -->|"reads jobs"| node_tracker
node_orchestrator -->|"reads and queues"| node_sent_queue
node_orchestrator -->|"loads and saves"| node_snapshot
node_orchestrator -->|"polls and sends"| node_linkedin
node_linkedin -.->|"scrapes and messages"| node_linkedin_service
node_orchestrator -->|"extracts and matches"| node_company_extract
node_company_extract -.->|"optionally extracts"| node_openai
node_company_extract -->|"reads thresholds"| node_config
node_orchestrator -->|"fetches resume link"| node_resume_lookup
node_resume_lookup -->|"searches resumes"| node_drive_service
node_tracker -.->|"reads and updates"| node_sheets_service
node_sent_queue -.->|"reads and updates"| node_sheets_service
node_snapshot -.->|"persists snapshot"| node_sheets_service
node_dashboard -->|"displays applications"| node_tracker
node_dashboard -->|"displays outreach status"| node_sent_queue
node_dashboard -->|"dispatches workflows"| node_github_actions
node_resume_sync -.->|"syncs resume links"| node_tracker
node_orchestrator -->|"uses settings"| node_config

click node_orchestrator "https://github.com/thayaa21/linkedin/blob/main/main.py"
click node_linkedin "https://github.com/thayaa21/linkedin/blob/main/linkedin.py"
click node_company_extract "https://github.com/thayaa21/linkedin/blob/main/matcher.py"
click node_tracker "https://github.com/thayaa21/linkedin/blob/main/sheets.py"
click node_sent_queue "https://github.com/thayaa21/linkedin/blob/main/sheets.py"
click node_snapshot "https://github.com/thayaa21/linkedin/blob/main/sheets.py"
click node_resume_lookup "https://github.com/thayaa21/linkedin/blob/main/drive.py"
click node_config "https://github.com/thayaa21/linkedin/blob/main/config.py"
click node_dashboard "https://github.com/thayaa21/linkedin/blob/main/dashboard.py"
click node_resume_sync "https://github.com/thayaa21/linkedin/blob/main/sync_resumes.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_orchestrator,node_company_extract toneBlue
class node_linkedin,node_tracker,node_sent_queue,node_snapshot,node_resume_lookup,node_drive_service,node_linkedin_service,node_sheets_service,node_openai toneAmber
class node_dashboard,node_resume_sync,node_github_actions toneMint
class node_config toneRose
class node_applicant toneIndigo
```

## Components

### Outreach workflow

- [Poll and send jobs](https://github.com/thayaa21/linkedin/blob/main/main.py): `main.py`
- [Headline extraction and matching](https://github.com/thayaa21/linkedin/blob/main/matcher.py): `matcher.py`

### External integrations

- [Connection scraping and DMs](https://github.com/thayaa21/linkedin/blob/main/linkedin.py): `linkedin.py`
- [Applications and date window](https://github.com/thayaa21/linkedin/blob/main/sheets.py): `sheets.py`
- [Pending and sent records](https://github.com/thayaa21/linkedin/blob/main/sheets.py): `sheets.py`
- [Connection snapshot](https://github.com/thayaa21/linkedin/blob/main/sheets.py): `sheets.py`
- [Resume lookup](https://github.com/thayaa21/linkedin/blob/main/drive.py): `drive.py`
- **Google Drive**
- **LinkedIn**
- **Google Sheets**
- **OpenAI extraction**

### Monitoring and utilities

- [Monitoring dashboard](https://github.com/thayaa21/linkedin/blob/main/dashboard.py): `dashboard.py`
- [Resume sync](https://github.com/thayaa21/linkedin/blob/main/sync_resumes.py): `sync_resumes.py`
- **Scheduled workflows**

### Configuration

- [Runtime settings](https://github.com/thayaa21/linkedin/blob/main/config.py): `config.py`

### Other components

- **Applicant**

## Connections

- Scheduled workflows → Poll and send jobs: triggers (evidence: `README.md`)
- Applicant → Applications and date window: records applications (evidence: `README.md`)
- Poll and send jobs → Applications and date window: reads jobs (evidence: `main.py`)
- Poll and send jobs → Pending and sent records: reads and queues (evidence: `main.py`)
- Poll and send jobs → Connection snapshot: loads and saves (evidence: `main.py`)
- Poll and send jobs → Connection scraping and DMs: polls and sends (evidence: `main.py`)
- Connection scraping and DMs → LinkedIn: scrapes and messages
- Poll and send jobs → Headline extraction and matching: extracts and matches (evidence: `main.py`)
- Headline extraction and matching → OpenAI extraction: optionally extracts (evidence: `matcher.py`)
- Headline extraction and matching → Runtime settings: reads thresholds (evidence: `matcher.py`)
- Poll and send jobs → Resume lookup: fetches resume link (evidence: `main.py`)
- Resume lookup → Google Drive: searches resumes (evidence: `drive.py`)
- Applications and date window → Google Sheets: reads and updates
- Pending and sent records → Google Sheets: reads and updates
- Connection snapshot → Google Sheets: persists snapshot
- Monitoring dashboard → Applications and date window: displays applications (evidence: `dashboard.py`)
- Monitoring dashboard → Pending and sent records: displays outreach status (evidence: `dashboard.py`)
- Monitoring dashboard → Scheduled workflows: dispatches workflows (evidence: `dashboard.py`)
- Resume sync → Applications and date window: syncs resume links
- Poll and send jobs → Runtime settings: uses settings (evidence: `main.py`)
