유대선
프로젝트로
·스냅샷·2

Architecture overview — ScreenBridge (jarvis-pc) as of 2026-05-31

Swift 6.3 macOS native app that captures the cursor monitor, fuses Vision OCR with AXUIElement, dispatches to a vision LLM (Gemini/Claude with a local Qwen2.5-VL path under construction), and overlays a red box plus bubble on the same monitor.

System shape

[HotKey ⌥Space / NSStatusItem]
        │ records trigger cursor monitor

[TriggerPanel] ── user pastes instruction ──┐

                              [AnalyzeCoordinator]

        ┌───────────────────────────────────┼───────────────────────────────────┐
        ▼                                   ▼                                   ▼
[ScreenCaptureService]              [OCRService]                        [AXService]
 (ScreenCaptureKit)                 (Vision framework)                  (AXUIElement)
        │                                   │                                   │
        └────────────► [ElementMatcher: OCR + AX spatial fusion] ◄───────────────┘


                          [LLMDispatcher] → Gemini / Claude / (Qwen local, in progress)
                            FallbackDispatcher on 429


                          [HUDController → HUDOverlayWindow / HUDOverlayView]
                          red box + bubble on the cursor monitor


                          [SessionAuditLog] JSON per session
                          [SecretMasker] regex mask before LLM

Key libs / modules

Why these choices

Boundaries

State of completion

Phases 1–7.3 are landed: capture, OCR+AX fusion, multi-target overlay, continuation hotkey, completion pill, session audit, secret masking, and Claude/Gemini dispatch with 429 fallback are all in Sources/ScreenBridge/. Phase 9.0 (local Qwen2.5-VL via MLX) is at Week 1 skeleton only — QwenLocalDispatcher.swift exists, the mlx-swift-examples dep is pinned, but the local path is not yet wired into AnalyzeCoordinator. No production .app bundle yet; dev loop is swift run.