How thinkwatchproject/thinkwatch-lite works
ThinkWatch Lite is a cross-platform desktop app that embeds a local AI gateway. Users connect supported AI clients once, configure upstream providers and routing in the app, then send requests through the gateway; request traces and security findings are available in the interface. The README documents additional capabilities, including client restoration, remote-core operation, MCP and configuration scanning, and request replay. The graph combines those documented workflows with sampled UI/control code; several backend subsystem links are documented rather than verified from excerpts.
Main entry points: gateway.rs Request gateway · App.tsx App shell · useRequests.ts Request history · control.ts Control bridge
Components 20
Desktop app
- App shell
src/App.tsx - Control bridge
src/control.ts - Desktop backend
src-tauri/src/lib.rs
Gateway operation
- Request gateway
src-tauri/src/gateway.rs - Request routing
src/requestRouting.ts - Request protection
src/security
Client and provider setup
- Client setup
src/clients/ClientsPage.tsx - Client adoption
src-tauri/crates/tw-adopt/src/clients.rs - Provider setup
src/upstreams/UpstreamsPage.tsx - Routing setup
src/routing/RoutingPage.tsx
Monitoring and protection
- Request history
src/useRequests.ts - Traffic explorer
src/traffic/TrafficPage.tsx - Usage overview
src/overview/useLive.ts - Security findings
src/security/SecurityPage.tsx - MCP and config scan
src-tauri/crates/tw-scan/src/lib.rs - MCP interface
src/mcp/McpPage.tsx
Other components
- User
- AI client
- AI upstream
- Remote core
Connections 20
- User → App shell: configures
README.md - App shell → Control bridge: calls
src/App.tsx - Control bridge → Desktop backend: invokes
src/control.ts - App shell → Remote core: connects remotely
README.md - User → Client setup: selects clients
README.md - Client setup → Client adoption: requests adoption
- Client adoption → AI client: updates config
README.md - User → Provider setup: configures providers
README.md - User → Routing setup: defines rules
README.md - AI client → Request gateway: sends requests
README.md - Request gateway → Request protection: checks requests
README.md - Request gateway → Request routing: selects route
README.md - Request routing → AI upstream: forwards requests
README.md - Request gateway → Request history: records requests
README.md - Request history → Traffic explorer: feeds traces
- Request history → Usage overview: feeds metrics
- Request protection → Security findings: reports findings
README.md - MCP and config scan → MCP interface: presents scan
- User → MCP interface: reviews clients
README.md - User → Traffic explorer: searches and replays
README.md