# javalyhn/product-audit architecture

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

- Interactive diagram: https://gitdiagram.com/javalyhn/product-audit
- Repository: https://github.com/javalyhn/product-audit

## Overview

product-audit is a Claude Code Skill and Python tool for researching a web product and producing a structured Markdown/HTML evaluation. Its main workflow is URL and audit configuration → browser-based observation and LLM interpretation → synthesis → report generation. Separate branches cover logged-in audits and competitor comparison. The sampled sources show the audit/browser/LLM and report-generation responsibilities; some template and synthesis wiring is documented in the README but not visible in the excerpts, so those links are marked unverified.

Main entry points: [`scripts/audit.py`](https://github.com/JavaLyHn/product-audit/blob/main/scripts/audit.py) (Audit orchestrator), [`scripts/research_competitors.py`](https://github.com/JavaLyHn/product-audit/blob/main/scripts/research_competitors.py) (Competitor research), [`scripts/generate_report.py`](https://github.com/JavaLyHn/product-audit/blob/main/scripts/generate_report.py) (Report generator), [`scripts/llm.py`](https://github.com/JavaLyHn/product-audit/blob/main/scripts/llm.py) (LLM adapter)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_audit["Audit workflow"]
  node_skill["Skill instructions<br/>[SKILL.md]"]
  node_audit_runner["Audit orchestrator<br/>[audit.py]"]
  node_templates["Audit templates"]
  node_browser["Browser session<br/>[browser.py]"]
  node_findings["Audit findings"]
end

subgraph group_research["Research and synthesis"]
  node_llm["LLM adapter<br/>[llm.py]"]
  node_synthesis["Audit synthesis<br/>[audit.py]"]
  node_competitors["Competitor research"]
  node_competitor_data["Comparison data"]
end

subgraph group_session["Login auditing"]
  node_login_capture["Login capture<br/>[capture_login.py]"]
  node_session_state["Browser session state"]
end

subgraph group_delivery["Report delivery"]
  node_report_generator["Report generator<br/>[generate_report.py]"]
  node_report["Markdown and HTML report"]
end

node_user(("Product evaluator"))
node_target{{"Product website"}}
node_websearch{{"Web search"}}

node_user -->|"requests audit"| node_skill
node_skill -->|"invokes"| node_audit_runner
node_audit_runner -.->|"loads template"| node_templates
node_audit_runner -->|"drives browser"| node_browser
node_browser -->|"navigates"| node_target
node_audit_runner -->|"requests interpretation"| node_llm
node_audit_runner -->|"writes findings"| node_findings
node_audit_runner -->|"runs synthesis"| node_synthesis
node_synthesis -.->|"requests synthesis"| node_llm
node_llm -.->|"searches web"| node_websearch
node_user -->|"logs in"| node_login_capture
node_login_capture -->|"saves state"| node_session_state
node_session_state -->|"supplies session"| node_audit_runner
node_audit_runner -.->|"starts comparison"| node_competitors
node_competitors -->|"requests research"| node_llm
node_competitors -->|"captures pages"| node_browser
node_competitors -->|"writes comparison"| node_competitor_data
node_audit_runner -->|"invokes report generation"| node_report_generator
node_report_generator -->|"reads findings"| node_findings
node_report_generator -->|"renders"| node_report
node_competitor_data -.->|"feeds comparison section"| node_report_generator

click node_skill "https://github.com/JavaLyHn/product-audit/blob/main/SKILL.md"
click node_audit_runner "https://github.com/JavaLyHn/product-audit/blob/main/scripts/audit.py"
click node_templates "https://github.com/JavaLyHn/product-audit/tree/main/templates"
click node_browser "https://github.com/JavaLyHn/product-audit/blob/main/scripts/browser.py"
click node_llm "https://github.com/JavaLyHn/product-audit/blob/main/scripts/llm.py"
click node_synthesis "https://github.com/JavaLyHn/product-audit/blob/main/scripts/audit.py"
click node_competitors "https://github.com/JavaLyHn/product-audit/blob/main/scripts/research_competitors.py"
click node_login_capture "https://github.com/JavaLyHn/product-audit/blob/main/scripts/capture_login.py"
click node_report_generator "https://github.com/JavaLyHn/product-audit/blob/main/scripts/generate_report.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_skill,node_audit_runner,node_templates,node_browser,node_findings toneBlue
class node_llm,node_synthesis,node_competitors,node_competitor_data toneAmber
class node_login_capture,node_session_state toneMint
class node_report_generator,node_report toneRose
class node_user,node_target,node_websearch toneIndigo
```

## Components

### Audit workflow

- [Skill instructions](https://github.com/JavaLyHn/product-audit/blob/main/SKILL.md): `SKILL.md`
- [Audit orchestrator](https://github.com/JavaLyHn/product-audit/blob/main/scripts/audit.py): `scripts/audit.py`
- [Audit templates](https://github.com/JavaLyHn/product-audit/tree/main/templates): `templates`
- [Browser session](https://github.com/JavaLyHn/product-audit/blob/main/scripts/browser.py): `scripts/browser.py`
- **Audit findings**

### Research and synthesis

- [LLM adapter](https://github.com/JavaLyHn/product-audit/blob/main/scripts/llm.py): `scripts/llm.py`
- [Audit synthesis](https://github.com/JavaLyHn/product-audit/blob/main/scripts/audit.py): `scripts/audit.py`
- [Competitor research](https://github.com/JavaLyHn/product-audit/blob/main/scripts/research_competitors.py): `scripts/research_competitors.py`
- **Comparison data**

### Login auditing

- [Login capture](https://github.com/JavaLyHn/product-audit/blob/main/scripts/capture_login.py): `scripts/capture_login.py`
- **Browser session state**

### Report delivery

- [Report generator](https://github.com/JavaLyHn/product-audit/blob/main/scripts/generate_report.py): `scripts/generate_report.py`
- **Markdown and HTML report**

### Other components

- **Product evaluator**
- **Product website**
- **Web search**

## Connections

- Product evaluator → Skill instructions: requests audit (evidence: `README.md`)
- Skill instructions → Audit orchestrator: invokes (evidence: `README.md`)
- Audit orchestrator → Audit templates: loads template
- Audit orchestrator → Browser session: drives browser (evidence: `scripts/audit.py`)
- Browser session → Product website: navigates (evidence: `scripts/browser.py`)
- Audit orchestrator → LLM adapter: requests interpretation (evidence: `scripts/audit.py`)
- Audit orchestrator → Audit findings: writes findings (evidence: `scripts/audit.py`)
- Audit orchestrator → Audit synthesis: runs synthesis (evidence: `README.md`)
- Audit synthesis → LLM adapter: requests synthesis (evidence: `scripts/audit.py`)
- LLM adapter → Web search: searches web
- Product evaluator → Login capture: logs in (evidence: `README.md`)
- Login capture → Browser session state: saves state (evidence: `scripts/capture_login.py`)
- Browser session state → Audit orchestrator: supplies session (evidence: `README.md`)
- Audit orchestrator → Competitor research: starts comparison
- Competitor research → LLM adapter: requests research (evidence: `scripts/research_competitors.py`)
- Competitor research → Browser session: captures pages (evidence: `scripts/research_competitors.py`)
- Competitor research → Comparison data: writes comparison (evidence: `scripts/research_competitors.py`)
- Audit orchestrator → Report generator: invokes report generation (evidence: `README.md`)
- Report generator → Audit findings: reads findings (evidence: `scripts/generate_report.py`)
- Report generator → Markdown and HTML report: renders (evidence: `scripts/generate_report.py`)
- Comparison data → Report generator: feeds comparison section
