jev-chat/jev-chat-jarvis-mac

聊天悬浮窗助手(macOS):屏幕感知 + 本地小模型判断意图与风险,按话术生成回复候选。纯只读。

What it solves

When a chat message pops up on your Mac, you often need to quickly judge what the other person really means, how risky it is to reply, and what to say. This project gives you that analysis instantly in a floating window, without touching the chat app itself or sending anything automatically.

How it works

It runs only on Apple Silicon Macs (macOS 13+). It watches the foreground chat app either by taking a screenshot of its window and using Apple's Vision OCR to read the text, or by directly reading the app's text interface (no screenshot needed, but requires Accessibility permission). The recognized message is fed to a small local model (decider-2b, ~3.8 GB download) that outputs an intent (8 classes, about 86.4% zero-shot accuracy) and a risk score from 0 to 9 with suggested actions. Then a second generation layer (either a cloud LLM like DeepSeek or a local Ollama) produces multiple candidate replies in different tones (14 built-in, e.g., high-EQ, tieba-style, passive-aggressive). All candidates are shown in a floating panel (NSPanel) that stays above other windows. You can click “填入” to paste a chosen reply into the chat input field via Accessibility, or copy it manually. The system is purely read-only: no injection, no hooking, no database decryption, no auto-sending.

Who it’s for

People who use chat apps on macOS (like WeChat, etc.) and want quick, AI-assisted help with interpreting messages and drafting replies — especially in social or work contexts where tone and risk matter. It’s also useful for developers who want to self-host with their own API keys or a local Ollama model.

Highlights

  • Read‑only and non‑invasive: uses screen capture + OCR or system text interface; never injects, hooks, or decrypts anything.
  • Intent and risk analysis: 8 intent classes with 86.4% zero‑shot accuracy (from 22 regression cases), risk 0–9 with action suggestions, all from one local forward pass.
  • Reply generation: 14 built‑in tone styles, each can produce 1–5 candidate replies (default 2), with local ranking and in‑place reordering.
  • Floating panel follows the foreground app, shows chat name, analysis status, intent, risk level, and grouped candidate replies.
  • Manual calibration mode lets you adjust the message and input regions on the screenshot if automatic detection misses areas.
  • Optional YOLO boxes (visual debug) show message ownership, reference status, and OCR confidence.
  • History and background context: optionally record up to 100 messages per conversation and add a custom “chat background” note to help the model.
  • Privacy‑friendly: all data is processed locally except when you choose a cloud model; no cloud sync of history, no telemetry beyond API calls you configure.
  • Easy install via Homebrew (no “right‑click open” needed) or direct download from Releases (requires one‑time right‑click open or clearing quarantine).

Related

  • Project
  • Project
  • Project
  • Project
  • Project