Based on the current project files, help me generate technical documentation:
【Project Information】
Name: {Project Name}
Problem: {Core Problem}
Technology: {Tech Stack}
【Document Structure - 4 Parts】
1️⃣ Problem and Solution (300 words)
- What is the problem
- Why it needs to be solved
- How to solve it
- Why this solution was chosen
2️⃣ Technical Implementation (300 words)
- What technologies were used
- Role of each technology
- Explanation of key technical points
- Key parameters or configurations
3️⃣ System Architecture (simple flowchart)
- Complete data flow
- Relationships between parts
- Execution process
4️⃣ Achievements and Benefits (200 words)
- What was solved
- What benefits were brought
- Reusable aspects
1️⃣ Problem and Solution
The heatmap on the CoinGlass website cannot be obtained via API and is dynamically rendered by React.
Solution: Use Playwright browser automation for screenshots.
Why this solution was chosen:
2️⃣ Technical Implementation
Key technical points:
[class*="treemap"] to locate the heatmap container.3️⃣ System Architecture
Crontab scheduled task (hourly)
↓
Python script starts
↓
Playwright launches browser
↓
Visit website → Wait (5s) → Click coin → Wait (7s)
↓
Screenshot (840×384px)
↓
PIL cropping (Left -1, Right -1, Top -1, Bottom -1)
↓
Final Heatmap (838×382px)
↓
Save to local directory
4️⃣ Achievements and Benefits
Achievements:
Benefits:
Reusable experience:
Version: v1.0 (Essential Edition) Update: 2025-10-19