# meteor060606111-pixel/resourcelens architecture

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

- Interactive diagram: https://gitdiagram.com/meteor060606111-pixel/resourcelens
- Repository: https://github.com/meteor060606111-pixel/resourcelens

## Overview

拾流 ResourceLens is a Windows resource-capture and media-download application. Its main workflow is to capture media requests through a local HTTPS proxy or accept links, resolve platform metadata and quality, then queue, transfer, process, validate, and save media for preview. The README also documents distinct Douyin, WeChat Channels, generic video, maintenance, and update capabilities. Edges are limited to relationships visible in excerpts or stated in the README; several subsystem internals were not sampled.

Main entry points: [`app/wechat.go`](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat.go) (WeChat Channels capture), [`app/engine.go`](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/engine.go) (Local API engine), [`frontend/src/App.vue`](https://github.com/meteor060606111-pixel/resourcelens/blob/main/frontend/src/App.vue) (ResourceLens UI), [`app/proxy.go`](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/proxy.go) (HTTPS capture proxy)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["User interface"]
  node_vue["ResourceLens UI<br/>[App.vue]"]
  node_appentry["Desktop entry<br/>[main.go]"]
  node_engine["Local API engine<br/>[engine.go]"]
  node_webassets["Embedded UI assets<br/>[assets.go]"]
end

subgraph group_capture["Capture and platforms"]
  node_proxy["HTTPS capture proxy<br/>[proxy.go]"]
  node_certificate["Local certificate<br/>[certificate.go]"]
  node_platforms["Platform adapters<br/>[platforms.go]"]
  node_douyin["Douyin resolver<br/>[douyin.go]"]
  node_browser["Private browser resolver<br/>[douyin-browser.mjs]"]
  node_wechat["WeChat Channels capture<br/>[wechat.go]"]
  node_wechatbridge["WeChat page bridge<br/>[wechat-bridge.js]"]
  node_quality["WeChat quality probe<br/>[wechat_quality.go]"]
  node_status["WeChat connection status"]
end

subgraph group_media["Media processing"]
  node_resources["Resource metadata<br/>[media.go]"]
  node_jobs["Download tasks<br/>[download.go]"]
  node_transfer["Segmented transfer<br/>[transfer.go]"]
  node_video["Video resolution<br/>[video.go]"]
  node_videotransfer["Video transfer and validation<br/>[video_transfer.go]"]
  node_isaac["WeChat media decode<br/>[wechat_isaac.go]"]
end

subgraph group_operations["App operations"]
  node_session[("Session persistence<br/>[session.go]")]
  node_maintenance["Settings and maintenance<br/>[maintenance.go]"]
  node_system["Windows proxy control<br/>[system_windows.go]"]
  node_update["Update and rollback<br/>[update.go]"]
end

node_user(("User"))
node_external(("Media sites and WeChat"))
node_enginebin["FFmpeg and yt-dlp"]

node_user -->|"submits links"| node_vue
node_appentry -->|"starts"| node_engine
node_appentry -->|"loads assets"| node_webassets
node_vue -->|"requests API"| node_engine
node_engine -->|"restores state"| node_session
node_engine -.->|"persists state"| node_session
node_engine -.->|"controls capture"| node_proxy
node_proxy -.->|"uses certificate"| node_certificate
node_proxy -.->|"records requests"| node_resources
node_user -->|"plays media"| node_proxy
node_resources -.->|"resolves links"| node_platforms
node_platforms -.->|"resolves Douyin"| node_douyin
node_douyin -.->|"fallback parses"| node_browser
node_browser -->|"reads public page"| node_external
node_wechatbridge -->|"posts metadata"| node_wechat
node_external -->|"serves page data"| node_wechatbridge
node_wechat -.->|"updates resources"| node_resources
node_wechat -.->|"probes variants"| node_quality
node_wechat -.->|"checks connection"| node_status
node_resources -.->|"queues downloads"| node_jobs
node_jobs -.->|"transfers files"| node_transfer
node_jobs -.->|"resolves video"| node_video
node_video -.->|"downloads and validates"| node_videotransfer
node_videotransfer -.->|"uses media tools"| node_enginebin
node_wechat -.->|"decodes media"| node_isaac
node_vue -.->|"manages settings"| node_maintenance
node_maintenance -.->|"controls system proxy"| node_system
node_vue -.->|"manages updates"| node_update

click node_vue "https://github.com/meteor060606111-pixel/resourcelens/blob/main/frontend/src/App.vue"
click node_appentry "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/main.go"
click node_engine "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/engine.go"
click node_webassets "https://github.com/meteor060606111-pixel/resourcelens/blob/main/frontend/assets.go"
click node_session "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/session.go"
click node_proxy "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/proxy.go"
click node_certificate "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/certificate.go"
click node_platforms "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/platforms.go"
click node_douyin "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/douyin.go"
click node_browser "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/helpers/douyin-browser.mjs"
click node_wechat "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat.go"
click node_wechatbridge "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/helpers/wechat-bridge.js"
click node_quality "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_quality.go"
click node_status "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_status_windows.go"
click node_resources "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/media.go"
click node_jobs "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/download.go"
click node_transfer "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/transfer.go"
click node_video "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/video.go"
click node_videotransfer "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/video_transfer.go"
click node_isaac "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_isaac.go"
click node_maintenance "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/maintenance.go"
click node_system "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/system_windows.go"
click node_update "https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/update.go"
click node_enginebin "https://github.com/meteor060606111-pixel/resourcelens/tree/main/video-engine"

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_vue,node_appentry,node_engine,node_webassets,node_user toneBlue
class node_proxy,node_certificate,node_platforms,node_douyin,node_browser,node_wechat,node_wechatbridge,node_quality,node_status toneAmber
class node_resources,node_jobs,node_transfer,node_video,node_videotransfer,node_isaac toneMint
class node_session,node_maintenance,node_system,node_update toneRose
class node_external toneIndigo
class node_enginebin toneTeal
```

## Components

### User interface

- [ResourceLens UI](https://github.com/meteor060606111-pixel/resourcelens/blob/main/frontend/src/App.vue): `frontend/src/App.vue`
- [Desktop entry](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/main.go): `app/main.go`
- [Local API engine](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/engine.go): `app/engine.go`
- [Embedded UI assets](https://github.com/meteor060606111-pixel/resourcelens/blob/main/frontend/assets.go): `frontend/assets.go`

### Capture and platforms

- [HTTPS capture proxy](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/proxy.go): `app/proxy.go`
- [Local certificate](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/certificate.go): `app/certificate.go`
- [Platform adapters](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/platforms.go): `app/platforms.go`
- [Douyin resolver](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/douyin.go): `app/douyin.go`
- [Private browser resolver](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/helpers/douyin-browser.mjs): `app/helpers/douyin-browser.mjs`
- [WeChat Channels capture](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat.go): `app/wechat.go`
- [WeChat page bridge](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/helpers/wechat-bridge.js): `app/helpers/wechat-bridge.js`
- [WeChat quality probe](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_quality.go): `app/wechat_quality.go`
- [WeChat connection status](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_status_windows.go): `app/wechat_status_windows.go`

### Media processing

- [Resource metadata](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/media.go): `app/media.go`
- [Download tasks](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/download.go): `app/download.go`
- [Segmented transfer](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/transfer.go): `app/transfer.go`
- [Video resolution](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/video.go): `app/video.go`
- [Video transfer and validation](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/video_transfer.go): `app/video_transfer.go`
- [WeChat media decode](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/wechat_isaac.go): `app/wechat_isaac.go`

### App operations

- [Session persistence](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/session.go): `app/session.go`
- [Settings and maintenance](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/maintenance.go): `app/maintenance.go`
- [Windows proxy control](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/system_windows.go): `app/system_windows.go`
- [Update and rollback](https://github.com/meteor060606111-pixel/resourcelens/blob/main/app/update.go): `app/update.go`

### Other components

- **User**
- **Media sites and WeChat**
- [FFmpeg and yt-dlp](https://github.com/meteor060606111-pixel/resourcelens/tree/main/video-engine): `video-engine`

## Connections

- User → ResourceLens UI: submits links (evidence: `README.md`)
- Desktop entry → Local API engine: starts (evidence: `app/main.go`)
- Desktop entry → Embedded UI assets: loads assets (evidence: `app/main.go`)
- ResourceLens UI → Local API engine: requests API (evidence: `frontend/src/App.vue`)
- Local API engine → Session persistence: restores state (evidence: `app/engine.go`)
- Local API engine → Session persistence: persists state
- Local API engine → HTTPS capture proxy: controls capture
- HTTPS capture proxy → Local certificate: uses certificate
- HTTPS capture proxy → Resource metadata: records requests
- User → HTTPS capture proxy: plays media (evidence: `README.md`)
- Resource metadata → Platform adapters: resolves links
- Platform adapters → Douyin resolver: resolves Douyin
- Douyin resolver → Private browser resolver: fallback parses
- Private browser resolver → Media sites and WeChat: reads public page (evidence: `app/helpers/douyin-browser.mjs`)
- WeChat page bridge → WeChat Channels capture: posts metadata (evidence: `app/helpers/wechat-bridge.js`)
- Media sites and WeChat → WeChat page bridge: serves page data (evidence: `README.md`)
- WeChat Channels capture → Resource metadata: updates resources
- WeChat Channels capture → WeChat quality probe: probes variants
- WeChat Channels capture → WeChat connection status: checks connection
- Resource metadata → Download tasks: queues downloads
- Download tasks → Segmented transfer: transfers files
- Download tasks → Video resolution: resolves video
- Video resolution → Video transfer and validation: downloads and validates
- Video transfer and validation → FFmpeg and yt-dlp: uses media tools
- WeChat Channels capture → WeChat media decode: decodes media
- ResourceLens UI → Settings and maintenance: manages settings
- Settings and maintenance → Windows proxy control: controls system proxy
- ResourceLens UI → Update and rollback: manages updates
