Skip to content

Latest commit

Β 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Senti iris logo

Senti

What Am I Looking At?
A local-first visual assistant for macOS β€” it sees the scene, names the objects, and answers your questions. On your Mac. Nothing uploaded.

MIT License Python 3.11+ macOS Apple Silicon Local-first privacy pytest

Quick start Β· How it works Β· Stack Β· Docs Β· License

Senti β€” local-first visual assistant on macOS

✨ Why Senti

Most visual assistants ship camera frames to a cloud API. Senti does not.

It is built for Apple Silicon so the fast path β€” object detection and tracking β€” stays at interactive rates, while the slow path β€” a local vision-language model via Ollama β€” only runs when the scene actually changes or you ask a question.

🎯 Live boxes & track IDs πŸ’¬ Follow-up questions πŸ” Object focus
YOLO26 labels, confidence, stable #1 #2 IDs β€œWhat’s that connector?” β€œWhat objects do you see?” Crop #2 phone before the VLM sees it
πŸ“ On-device OCR πŸ”Š Spoken answers πŸŽ™οΈ Push-to-talk
Ask read this or auto-read on READY macOS TTS (Qt or say) Local Whisper, Esc to cancel

πŸš€ Features

Capability Detail
πŸŽ₯ Live perception YOLO26 on Apple Silicon β€” PyTorch mps or yolo-mlx Metal β€” plus ByteTrack / BoT-SORT IDs
🧭 Scene intelligence Visual + object + spatial change detection, stability gating, best-frame selection
🧠 Local understanding Ollama VLM, auto-analysis when the scene settles, conversational memory
βœ‚οΈ Object focus Padded crop of the most likely target before a focused question
πŸ”€ On-device OCR EasyOCR on demand (read this) or automatically when the scene is ready
πŸ—£οΈ Speech I/O macOS TTS and local Whisper push-to-talk
πŸ” Privacy by design No cloud uploads, no disk recordings, bounded in-memory frame buffer

🧠 How it works

Two loops keep the UI live. The camera never waits on the language model.

Camera β†’ detect β†’ understand β†’ speak

flowchart LR
  Cam["πŸ“· Camera"] --> Fast
  subgraph Fast["⚑ Fast loop β€” 15–30 FPS"]
    YOLO["🎯 YOLO26 + tracking"]
    Scene["🧭 Scene change + stability"]
    YOLO --> Scene
  end
  Fast --> Slow
  subgraph Slow["πŸŒ™ Slow loop β€” on change or question"]
    Frame["πŸ–ΌοΈ Best-frame selection"]
    OCR["πŸ”€ Optional OCR"]
    VLM["🧠 Local VLM"]
    Frame --> OCR --> VLM
  end
  Slow --> UI["πŸ–₯️ Desktop UI + TTS"]
  Mic["πŸŽ™οΈ Push-to-talk"] --> UI
  UI --> Ask["πŸ’¬ Ask / Focus / Analyze"]
  Ask --> Slow
Loading
  1. ⚑ Fast loop β€” frames go to YOLO26, then tracking and scene-change detection. Target: 15–30 FPS.
  2. πŸŒ™ Slow loop β€” when the scene reaches READY, Senti picks the sharpest, most stable frame from a rolling buffer and sends it to the local VLM (and OCR, if enabled). Follow-ups reuse scene memory when they can.

State machine: WATCHING β†’ SCENE_CHANGED β†’ WAITING_FOR_STABILITY β†’ READY

Full package map and thread model: Architecture.

🧩 Stack

Every runtime dependency, with a badge that opens its official site. Click through β€” these are the projects Senti stands on.

Python macOS PySide6 Qt NumPy OpenCV Ultralytics YOLO26 PyTorch MLX yolo-mlx Ollama EasyOCR faster-whisper sounddevice python-dotenv pytest

Project Official site Role in Senti
Python python.org Runtime (3.11+)
macOS apple.com/macos Camera, TTS say, permissions
PySide6 / Qt doc.qt.io/qtforpython-6 Β· qt.io Native window, AVFoundation capture, TTS
NumPy numpy.org Frame arrays
OpenCV opencv.org Overlays, sharpness, scene diff
Ultralytics YOLO26 ultralytics.com Β· YOLO26 docs Detection + tracking
PyTorch pytorch.org Default YOLO path: MPS on Apple Silicon
🍎 MLX / yolo-mlx MLX · yolo-mlx Optional native Metal detector (YOLO_RUNTIME=mlx; pip install "yolo-mlx[tracking,convert]")
Ollama ollama.com Local vision-language model
πŸ”€ EasyOCR jaided.ai/easyocr Β· GitHub On-device text recognition
πŸŽ™οΈ faster-whisper SYSTRAN/faster-whisper Push-to-talk transcription
🎚️ sounddevice python-sounddevice.readthedocs.io Microphone capture
βš™οΈ python-dotenv GitHub .env configuration
pytest docs.pytest.org Unit tests

Pinned versions live in requirements.txt.

πŸ“‹ Requirements

  • 🍎 macOS on Apple Silicon (developed on M2 Pro)
  • 🐍 Python 3.11 or newer
  • πŸ“· Built-in or Continuity Camera
  • πŸ” Camera permission (and microphone if voice input is on)
  • πŸ¦™ Ollama with a vision model for scene descriptions

⚑ Quick start

git clone https://github.com/TeslaNeuro/Senti.git
cd Senti

python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt

cp .env.example .env

Pull a local vision model, then launch:

ollama pull gemma4
./scripts/run.sh

Or:

source .venv/bin/activate
python -m app

On first launch, macOS will ask for camera access. Grant it to Terminal (or your IDE) if you start Senti from the command line. Ultralytics downloads yolo26n.pt into models/ automatically (~6 MB) unless that file is already there.

Optional native Metal path: install yolo-mlx with pip install "yolo-mlx[tracking,convert]", then set YOLO_RUNTIME=mlx.

πŸ’‘ If the preview is black, another app (FaceTime, Zoom, Chrome, …) likely holds the camera. Quit it and relaunch.

πŸ–₯️ Using the app

Action What happens
πŸ‘€ Watch the preview Live boxes, labels, confidence, track IDs (#1, #2, …)
⏳ Wait for READY Automatic VLM description of the best buffered frame
πŸ’¬ Type in Ask Follow-up against scene memory, or a new VLM call when needed
🎯 Focus dropdown Analyze a specific tracked object (cropped when enabled)
πŸ” Analyze Force a fresh VLM pass (bypasses cooldown)
🧹 Clear Reset scene memory and the response panel
πŸ”Š Speak / say that Replay the current answer (when TTS is on)
πŸŽ™οΈ Mic / Stop Push-to-talk; Esc cancels an in-progress recording
πŸ“– read this Run OCR on the current scene

Status bar shows camera, YOLO device, VLM activity, FPS, and inference latency. Hover a pill for the full detail.

Step-by-step walkthrough: Usage.

βš™οΈ Configuration

Copy .env.example to .env. Important defaults:

Variable Default Purpose
CAMERA_WIDTH / CAMERA_HEIGHT 1280 / 720 Capture size
YOLO_MODEL yolo26n.pt Weights filename; stored in models/ (yolo26s.pt is more accurate)
YOLO_RUNTIME auto auto (Ultralytics unless YOLO_DEVICE=mlx), ultralytics (PyTorch MPS), or mlx (yolo-mlx Metal)
YOLO_DEVICE auto auto β†’ PyTorch mps on Apple Silicon; mlx for yolo-mlx
VLM_MODEL gemma4 Ollama vision model
VLM_BASE_URL http://localhost:11434 Local Ollama API
OCR_ENABLED false On-device text recognition
TTS_ENABLED false Speak answers aloud
VOICE_ENABLED false Whisper push-to-talk

Optional features (OCR, TTS, voice) are off until you turn them on. Full reference: Configuration.

πŸŽ› Optional extras
OCR_ENABLED=true
TTS_ENABLED=true
TTS_RUNTIME=auto
VOICE_ENABLED=true
VOICE_MODEL=base

TTS_RUNTIME=auto uses Qt when it exposes your voice, otherwise the macOS say command (so names like Tessa still work). First OCR or Whisper use downloads models in the background.

πŸ§ͺ Tests

source .venv/bin/activate
pytest tests/ -q

πŸ“š Documentation

Guide Contents
πŸ—οΈ Architecture Layers, threads, scene states, package map
πŸ–±οΈ Usage Window tour, questions, focus, speech, voice
βš™οΈ Configuration Every .env setting and sensible ranges
🩺 Troubleshooting Camera, Qt, Ollama, OCR, TTS, Whisper
πŸ›‘οΈ Security Privacy model and how to report issues
πŸ“œ License MIT License

πŸ” Privacy

Senti is local-first:

  • 🚫 Camera frames are never written to disk
  • 🧠 The frame buffer is bounded and in-memory only
  • πŸ’» YOLO, OCR, Whisper, and the VLM run on-device (Ollama on localhost)
  • πŸ“‘ No telemetry, no cloud uploads, no account

See SECURITY.md for the threat model and reporting.

πŸ“ Project layout

Senti/
β”œβ”€β”€ app/                 Application package
β”‚   β”œβ”€β”€ camera/          Qt / AVFoundation capture + in-memory buffer
β”‚   β”œβ”€β”€ detection/       YOLO26 worker
β”‚   β”œβ”€β”€ tracking/        ByteTrack / BoT-SORT monitor
β”‚   β”œβ”€β”€ perception/      Scene change, stability, best-frame selection
β”‚   β”œβ”€β”€ vision/          Local VLM, scheduler, object crops
β”‚   β”œβ”€β”€ scene/           Conversational scene memory
β”‚   β”œβ”€β”€ ocr/             EasyOCR worker
β”‚   β”œβ”€β”€ speech/          Qt TTS + macOS say
β”‚   β”œβ”€β”€ voice/           Push-to-talk + faster-whisper
β”‚   └── ui/              Native desktop window
β”œβ”€β”€ docs/                Architecture, usage, configuration
β”‚   └── assets/          README graphics (logo, banner, pipeline)
β”œβ”€β”€ models/              YOLO26 weights (gitignored *.pt / *.npz)
β”œβ”€β”€ scripts/run.sh       Create venv, install, launch
β”œβ”€β”€ tests/               Unit tests
└── resources/Info.plist Camera and microphone usage strings

πŸ“„ License

Senti is released under the MIT License.

Copyright (c) 2026 Arshia Keshvari.

Senti
Built on-device. Nothing leaves your Mac.

About

Local-first visual assistant for macOS. names the scene, answers the follow-up, and keeps the camera to itself.

Topics

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages