Getting started
Install Twig on Android. Build from source. Bring your own keys.
Twig is a Bun + Turborepo monorepo. The product surface is Expo React Native on Android only. For downloads, package id, and legal terms see the distribution page.
You need
- Bun 1.3+
- Android device or the browser emulator (Docker + noVNC)
- Dev build of the app (Expo Go is dead here — see below)
adbon your PATH (brew install --cask android-platform-toolson macOS)
Install
bun installBrowser emulator (optional)
Pop an Android phone into your browser, then adb it from the host or from a coding agent:
bun run emu:doctor
bun run emu:up # Linux + KVM; on Mac use a remote host — see emulator docs
bun run emu:wait && bun run emu:adb
bun run emu:open # http://localhost:6080Details, Apple Silicon notes, and companion pairing: Browser Android emulator.
Run Android app
bun run dev:nativeTwig needs expo-sqlite with sqlite-vec. That is a build-time flag. Expo Go cannot
do it. You make a real development build:
cd apps/native
bunx expo prebuild --platform android
bunx expo run:androidSkip this and you get pain.
Run docs site
bun run dev:web
# → http://localhost:4000Laptop companion
Companion TUI in apps/cli. Lends compute over USB / adb reverse. Does not steal agent homes:
bun run companionWith the Docker emulator, start it first (emu:adb), then the companion — same reverse tunnel as a
real cable. See Laptop companion.
Scripts
| Script | What |
|---|---|
bun run dev | Everything |
bun run dev:native | Expo only |
bun run dev:web | Docs on port 4000 |
bun run companion | Laptop companion TUI |
bun run emu:up | Start Docker Android + noVNC |
bun run emu:adb | adb connect the emulator |
bun run emu:open | Open noVNC in the browser |
bun run build | Build all |
bun run check-types | Typecheck |
bun run test | Tests |
API keys
Twig does not ship models. Put key in app. OpenRouter = default easy path. Also OpenAI, Anthropic, Google. Keys live in secure storage on device. No key still means you can open files and reindex. Key only needed when you want the model to talk.