AI-powered coding assistant for Even Realities G2 smart glasses. Voice-driven conversations with Claude Code, displayed on the G2's monochrome display.
Talk to your codebase hands-free -- speak through the G2 glasses, get responses from Claude Code, scroll through results, answer interactive questions, all without touching a keyboard.
[G2 Glasses] <--BLE--> [iPhone Even App] <--HTTPS--> [Backend Server (Mac/Pi)]
(WebView app) (Express + Claude Agent SDK)
- You speak into the G2 glasses
- Audio is sent to the backend server over HTTPS (via Cloudflare tunnel)
- Server transcribes speech locally with whisper.cpp (zero API cost)
- Transcribed text goes to a Claude Code agent session via the Agent SDK
- Responses stream back to the glasses display
- Each conversation runs in an isolated git worktree
packages/
server/ # CLI + Express backend (SQLite, BullMQ, Claude Agent SDK, Whisper)
glasses-app/ # G2 web app (Vite, Even Hub SDK)
shared/ # Types and constants shared between server and app
- Node.js >= 20
- pnpm (package manager)
- Redis (job queue backend)
- Claude Code CLI installed and authenticated (
~/.claude/.credentials.json) - cloudflared (optional, for public tunnel access)
- Git (worktree management)
| Platform | Whisper Model | Notes |
|---|---|---|
| macOS | base.en |
Recommended for development |
| Raspberry Pi 5 | tiny.en |
~11s transcription for short clips |
git clone https://github.com/your-org/EvenCode.git
cd EvenCode
pnpm install
pnpm buildpnpm build:cli
npm install -g ./packages/serverThis makes the evencode command available globally.
Run the interactive setup to check prerequisites and download the Whisper model:
evencode setupOr use the shell script for a full automated setup (installs Redis, cloudflared, etc.):
bash scripts/setup.shCopy the example env file and edit it:
cp .env.example .env| Variable | Default | Description |
|---|---|---|
PORT |
3456 |
Server port |
HOST |
0.0.0.0 |
Bind address |
REPO_PATH |
Current directory | Git repo for Claude to work on |
WORKTREE_BASE |
~/.evencode/worktrees |
Where git worktrees are created |
DB_PATH |
~/.evencode/data.db |
SQLite database path |
REDIS_URL |
redis://127.0.0.1:6379 |
Redis connection URL |
AUTH_TOKEN |
Auto-generated | Bearer token for API auth |
WHISPER_MODEL |
base.en |
Whisper model (tiny.en for Pi) |
MAX_CONCURRENT_JOBS |
2 |
Parallel job queue workers |
AUDIO_TMP_DIR |
/tmp/glasses-audio |
Temp directory for audio files |
CLAUDE_MODEL |
Claude default | Override Claude model (see below) |
evencode start --workspace /path/to/your/repoThe server will:
- Initialize the database and connect to Redis
- Prune orphaned git worktrees from previous runs
- Prompt to start a Cloudflare tunnel (if cloudflared is installed)
- Display a QR code to connect your glasses
evencode start [options]
-w, --workspace <path> Override working directory (git repo)
-m, --model <model> Claude model to use
evencode setup Check prerequisites and download Whisper model
evencode status Show active conversationsOverride the default Claude model with --model:
# Use Sonnet for faster, cheaper responses
evencode start -w /path/to/repo --model claude-sonnet-4-6
# Use Opus for maximum capability
evencode start -w /path/to/repo --model claude-opus-4-6
# Use Haiku for speed on constrained hardware
evencode start -w /path/to/repo --model claude-haiku-4-5-20251001You can also set this via the CLAUDE_MODEL environment variable in .env.
Run the server and glasses app in dev mode (two terminals):
# Terminal 1: Backend server
pnpm dev:server -- start --workspace /path/to/repo
# Terminal 2: Glasses app (Vite dev server)
pnpm dev:appTest the glasses app in the Even Realities simulator:
npx @evenrealities/evenhub-simulator@latest http://127.0.0.1:5173All endpoints require Authorization: Bearer <token> (except /health).
| Method | Endpoint | Description |
|---|---|---|
GET |
/health |
Health check |
GET |
/auth/verify |
Verify auth token |
GET |
/system/qr |
Connection QR code |
POST |
/conversations |
Create new conversation (+ git worktree) |
GET |
/conversations |
List conversations |
GET |
/conversations/:id |
Get conversation details |
DELETE |
/conversations/:id |
Archive and remove worktree |
GET |
/conversations/:id/messages?since= |
Poll for messages |
POST |
/conversations/:id/messages |
Send text message |
POST |
/conversations/:id/audio |
Send audio (base64 PCM) |
GET |
/jobs/:id |
Job status |
POST |
/jobs/:id/retry |
Retry failed job |
- Fork the repo and create a feature branch
- Install dependencies:
pnpm install - Run in dev mode (see Development section above)
- Test against the Even Realities simulator before real hardware
- Submit a pull request
- Monorepo managed with pnpm workspaces
- TypeScript strict mode across all packages
- Shared types live in
packages/shared-- import from@evencode/shared - The glasses app is vanilla TypeScript (no framework) due to the constrained G2 display SDK
- The server bundles the built glasses app into
glasses-app-dist/for production serving
- Job queue: All audio transcription and Claude queries run through BullMQ for reliability and retry
- Git worktrees: Each conversation gets an isolated branch (
glasses/<id>) so Claude can make changes without conflicts - Render lock: The glasses display SDK requires serialized calls -- the renderer enforces this
- Polling: The glasses app polls the server (3s active, 5s home) since the G2 WebView doesn't support WebSockets
- cc-g2 -- Event handling patterns, bridge initialization, display pagination, and SDK quirk workarounds in the glasses app were ported from this project
- whisper.cpp by Georgi Gerganov -- Local speech-to-text engine
- whisper-node -- Node.js bindings for whisper.cpp
- Claude Code Agent SDK by Anthropic -- Powers the AI coding sessions
- Even Realities -- G2 glasses and Even Hub SDK
- Cloudflare -- Quick tunnel for exposing the local server
Proprietary. All rights reserved.
