How mnahtygal/thor-city works
THOR CITY collects live process and host telemetry from the local THOR machine and an optional Mac Mini, then streams it to a browser that renders an interactive, GPU-instanced city. The principal path is telemetry collection → host aggregation → WebSocket updates → city visualization and inspection. The README also documents search, pause, overview, FPS, process picking, and the performance-oriented tower design. Most browser behavior is in one sampled file; the HTML and CSS are present in the tree but were not sampled, so their wiring is not inferred.
Main entry points: city.js 3D Scene · main.py Fleet Snapshot · index.html City Page · collector.py Mac Collector
Components 16
Telemetry Collection
- Local Telemetry
app/main.py - Mac Collector
collector.py
Aggregation Service
- Fleet Snapshot
app/main.py - Snapshot API
app/main.py - WebSocket Stream
app/main.py
City Visualization
- City Page
app/static/index.html - 3D Scene
app/static/city.js - City Districts
app/static/city.js - Process Towers
app/static/city.js - Data Traffic
app/static/city.js - Page Styling
app/static/style.css
Browser Interaction
- Camera Controls
app/static/city.js - Process Search
app/static/city.js - Process Inspector
app/static/city.js - Telemetry Status
app/static/city.js
Other components
- Operator
Connections 16
- Local Telemetry → Fleet Snapshot: collects locally
app/main.py - Fleet Snapshot → Mac Collector: fetches snapshot
app/main.py - Mac Collector → Fleet Snapshot: returns telemetry
- Snapshot API → Fleet Snapshot: returns snapshot
app/main.py - WebSocket Stream → Fleet Snapshot: requests updates
app/main.py - Operator → City Page: opens
- City Page → 3D Scene: hosts scene
- 3D Scene → WebSocket Stream: receives updates
app/static/city.js - 3D Scene → City Districts: builds districts
app/static/city.js - 3D Scene → Process Towers: renders processes
app/static/city.js - 3D Scene → Data Traffic: animates traffic
app/static/city.js - 3D Scene → Camera Controls: updates camera
app/static/city.js - Process Search → Process Towers: filters processes
app/static/city.js - Process Towers → Process Inspector: selects process
app/static/city.js - 3D Scene → Telemetry Status: updates metrics
app/static/city.js - City Page → Page Styling: uses styles