Skip to content

Commit ca81706

Browse files
committed
docs: replace ASCII diagrams with GitHub-native Mermaid diagrams
- System architecture: color-coded subgraphs (Frontend/Backend/Data/Infra) - Match analysis flow: 8-step pipeline with category breakdown - Both render as live visual diagrams on GitHub, no image files needed - Keep Excalidraw interactive links as fallback
1 parent ecc86b1 commit ca81706

2 files changed

Lines changed: 123 additions & 45 deletions

File tree

README.md

Lines changed: 86 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -31,33 +31,95 @@ DocuQuery gives you a **structured, AI-powered match analysis in under 30 second
3131

3232
## Architecture
3333

34-
> [View System Architecture on Excalidraw](https://excalidraw.com/#json=BSZhDGDr5Qm3eDInxF8E8,EFSiUD4_xVdstYVDt2oipA) | [View Match Analysis Flow](https://excalidraw.com/#json=Nuok9iHjYoT326RfiCf-B,9D9-jQvlv29quAIuccmsOw)
35-
34+
### System Architecture
35+
36+
```mermaid
37+
graph TB
38+
subgraph Frontend["Frontend — Vercel"]
39+
direction TB
40+
NJ["Next.js 16 + TypeScript"]
41+
AR["App Router"] --- SC["shadcn/ui"]
42+
HK["Custom Hooks"] --- TW["Tailwind CSS"]
43+
DM["Dark Mode"]
44+
end
45+
46+
subgraph Backend["Backend — Railway"]
47+
direction TB
48+
FA["FastAPI + Python 3.12"]
49+
AUTH["Auth · JWT"] --- DOCS["Documents API"]
50+
PARSE["Doc Parser<br/>PDF / DOCX / TXT"] --- ANALYZE["Match Analyzer<br/>LLM + JSON mode"]
51+
TIPS["Tips Engine"] --- STORE["File Storage"]
52+
ALB["Alembic Migrations"]
53+
end
54+
55+
subgraph Data["Data & External"]
56+
direction TB
57+
PG[("PostgreSQL 16<br/>Supabase")]
58+
OAI["OpenAI GPT-4o-mini<br/>JSON mode · temp=0.2"]
59+
FS[("File Storage")]
60+
end
61+
62+
subgraph Infra["Infrastructure"]
63+
direction LR
64+
VCL["Vercel"] --- RWY["Railway"]
65+
DCK["Docker Compose"] --- GHA["GitHub Actions CI"]
66+
PT["59 Tests"] --- E2E["10 E2E Tests"]
67+
end
68+
69+
Frontend -->|"REST API"| Backend
70+
Frontend -.->|"Auth"| PG
71+
Backend -->|"SQLAlchemy async"| PG
72+
Backend -->|"Structured prompts"| OAI
73+
Backend --> FS
74+
75+
style Frontend fill:#dbe4ff,stroke:#4a9eed,color:#1e1e1e
76+
style Backend fill:#e5dbff,stroke:#8b5cf6,color:#1e1e1e
77+
style Data fill:#d3f9d8,stroke:#22c55e,color:#1e1e1e
78+
style Infra fill:#f3e8ff,stroke:#8b5cf6,color:#1e1e1e
3679
```
37-
┌─────────────────────────────────────────────┐
38-
│ Frontend (Vercel) │
39-
│ Next.js 16 · TypeScript · Tailwind · shadcn│
40-
└──────────────────┬──────────────────────────┘
41-
│ REST API
42-
┌──────────────────▼──────────────────────────┐
43-
│ Backend (Railway) │
44-
│ FastAPI · Python 3.12 · SQLAlchemy · JWT │
45-
│ │
46-
│ ┌──────────┐ ┌────────────┐ ┌───────────┐ │
47-
│ │Doc Parser│ │Match Analyz.│ │Tips Engine│ │
48-
│ │PDF/DOCX/ │ │ LLM + JSON │ │ Prioritize│ │
49-
│ │TXT │ │ mode │ │ & rank │ │
50-
│ └──────────┘ └──────┬─────┘ └───────────┘ │
51-
└──────────┬───────────┼──────────────────────┘
52-
│ │
53-
┌──────────▼──┐ ┌─────▼──────────┐
54-
│ PostgreSQL │ │ OpenAI │
55-
│ (Supabase) │ │ GPT-4o-mini │
56-
│ │ │ JSON mode │
57-
└─────────────┘ │ temp=0.2 │
58-
└────────────────┘
80+
81+
### Match Analysis Flow
82+
83+
```mermaid
84+
graph LR
85+
A["Upload Resume<br/>+ Job Description<br/><i>PDF / DOCX / TXT</i>"] -->|1| B["Extract Text<br/><i>PyMuPDF · python-docx</i>"]
86+
B -->|2| C["Validate & Store<br/><i>Magic bytes + DB</i>"]
87+
C -->|3| D["Select Resume + JD<br/>for Analysis"]
88+
D -->|4| E["Build LLM Prompt<br/><i>8K resume / 4K JD</i>"]
89+
E -->|5| F["Call GPT-4o-mini<br/><i>JSON mode · temp=0.2</i><br/><i>1 retry on timeout</i>"]
90+
F -->|6| G["Parse + Validate<br/><i>Pydantic schemas</i>"]
91+
G -->|7| H["Store Analysis<br/>+ Return Response"]
92+
93+
H -->|8| I["Score Gauge<br/><b>78 / 100</b>"]
94+
H --> J["Category Breakdown"]
95+
H --> K["Keyword Gaps"]
96+
H --> L["Actionable Tips"]
97+
98+
J --> J1["Skills 85%"]
99+
J --> J2["Experience 70%"]
100+
J --> J3["Education 90%"]
101+
J --> J4["Keywords 65%"]
102+
103+
style A fill:#a5d8ff,stroke:#4a9eed,color:#1e1e1e
104+
style B fill:#ffd8a8,stroke:#f59e0b,color:#1e1e1e
105+
style C fill:#d0bfff,stroke:#8b5cf6,color:#1e1e1e
106+
style D fill:#c3fae8,stroke:#22c55e,color:#1e1e1e
107+
style E fill:#fff3bf,stroke:#f59e0b,color:#1e1e1e
108+
style F fill:#ffc9c9,stroke:#ef4444,color:#1e1e1e
109+
style G fill:#d0bfff,stroke:#8b5cf6,color:#1e1e1e
110+
style H fill:#c3fae8,stroke:#22c55e,color:#1e1e1e
111+
style I fill:#b2f2bb,stroke:#22c55e,color:#1e1e1e
112+
style J fill:#dbe4ff,stroke:#4a9eed,color:#1e1e1e
113+
style K fill:#fff3bf,stroke:#f59e0b,color:#1e1e1e
114+
style L fill:#e5dbff,stroke:#8b5cf6,color:#1e1e1e
115+
style J1 fill:#a5d8ff,stroke:#4a9eed,color:#1e1e1e
116+
style J2 fill:#ffd8a8,stroke:#f59e0b,color:#1e1e1e
117+
style J3 fill:#b2f2bb,stroke:#22c55e,color:#1e1e1e
118+
style J4 fill:#ffc9c9,stroke:#ef4444,color:#1e1e1e
59119
```
60120

121+
> Interactive versions: [System Architecture](https://excalidraw.com/#json=BSZhDGDr5Qm3eDInxF8E8,EFSiUD4_xVdstYVDt2oipA) | [Analysis Flow](https://excalidraw.com/#json=Nuok9iHjYoT326RfiCf-B,9D9-jQvlv29quAIuccmsOw)
122+
61123
### Tech Stack
62124

63125
| Layer | Technology | Why |

docs/ARCHITECTURE.md

Lines changed: 37 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -14,27 +14,43 @@ DocuQuery is a **resume-job match analysis platform** built as a decoupled fulls
1414

1515
## Architecture Diagram
1616

17-
> **[View interactive System Architecture on Excalidraw](https://excalidraw.com/#json=BSZhDGDr5Qm3eDInxF8E8,EFSiUD4_xVdstYVDt2oipA)** | **[View Match Analysis Flow](https://excalidraw.com/#json=Nuok9iHjYoT326RfiCf-B,9D9-jQvlv29quAIuccmsOw)**
18-
19-
```
20-
┌─────────────────────────────────────────────┐
21-
│ Frontend (Vercel) │
22-
│ Next.js 16 · TypeScript · Tailwind · shadcn│
23-
└──────────────────┬──────────────────────────┘
24-
│ REST API
25-
┌──────────────────▼──────────────────────────┐
26-
│ Backend (Railway) │
27-
│ FastAPI · Python 3.12 · SQLAlchemy · JWT │
28-
│ │
29-
│ ┌──────────┐ ┌────────────┐ ┌───────────┐ │
30-
│ │Doc Parser│ │Match Analyz.│ │Tips Engine│ │
31-
│ └──────────┘ └──────┬─────┘ └───────────┘ │
32-
└──────────┬───────────┼──────────────────────┘
33-
│ │
34-
┌──────────▼──┐ ┌─────▼──────────┐
35-
│ PostgreSQL │ │ OpenAI │
36-
│ (Supabase) │ │ GPT-4o-mini │
37-
└─────────────┘ └────────────────┘
17+
> Interactive versions: [System Architecture on Excalidraw](https://excalidraw.com/#json=BSZhDGDr5Qm3eDInxF8E8,EFSiUD4_xVdstYVDt2oipA) | [Match Analysis Flow](https://excalidraw.com/#json=Nuok9iHjYoT326RfiCf-B,9D9-jQvlv29quAIuccmsOw)
18+
19+
```mermaid
20+
graph TB
21+
subgraph Frontend["Frontend — Vercel"]
22+
direction TB
23+
NJ["Next.js 16 + TypeScript"]
24+
AR["App Router"] --- SC["shadcn/ui"]
25+
HK["Custom Hooks"] --- TW["Tailwind CSS"]
26+
DM["Dark Mode"]
27+
end
28+
29+
subgraph Backend["Backend — Railway"]
30+
direction TB
31+
FA["FastAPI + Python 3.12"]
32+
AUTH["Auth · JWT"] --- DOCS["Documents API"]
33+
PARSE["Doc Parser<br/>PDF / DOCX / TXT"] --- ANALYZE["Match Analyzer<br/>LLM + JSON mode"]
34+
TIPS["Tips Engine"] --- STORE["File Storage"]
35+
ALB["Alembic Migrations"]
36+
end
37+
38+
subgraph Data["Data & External"]
39+
direction TB
40+
PG[("PostgreSQL 16<br/>Supabase")]
41+
OAI["OpenAI GPT-4o-mini<br/>JSON mode · temp=0.2"]
42+
FS[("File Storage")]
43+
end
44+
45+
Frontend -->|"REST API"| Backend
46+
Frontend -.->|"Auth"| PG
47+
Backend -->|"SQLAlchemy async"| PG
48+
Backend -->|"Structured prompts"| OAI
49+
Backend --> FS
50+
51+
style Frontend fill:#dbe4ff,stroke:#4a9eed,color:#1e1e1e
52+
style Backend fill:#e5dbff,stroke:#8b5cf6,color:#1e1e1e
53+
style Data fill:#d3f9d8,stroke:#22c55e,color:#1e1e1e
3854
```
3955

4056
## Data Model

0 commit comments

Comments
 (0)