Pi — Your AI Coding Agent on Android
A personal AI coding assistant that runs locally on your Android device — powered by cloud APIs or local models via Ollama. One command to install, one command to start.
curl -fsSL https://raw.githubusercontent.com/perminder-klair/droidclaw/main/scripts/setup.sh | bashWhat is Pi?
Pi is a personal AI coding assistant powered by the pi-coding-agent npm package. It runs inside a full Ubuntu environment on your Android device via Termux and proot-distro — no root required. Connect to cloud APIs like OpenAI and Anthropic, or run models locally with Ollama for fully offline coding.
It remembers context across sessions, follows custom instructions you define, and can access your Android's file system so you can edit configs from any text editor on your phone.
Think of it as having a sharp, opinionated senior engineer in your pocket — one that actually listens and gets better over time.
How It Works
Three steps. Five minutes. No root access required.
Install Termux
Download Termux from F-Droid. The Play Store version is outdated — use F-Droid for the latest build.
Run the Setup
Paste the one-line install command into Termux. It handles everything automatically — packages, Ubuntu, Node.js, the agent, Ollama, and device skills.
Start Coding
Type start-pi and you're in. Pi is ready to help you build, debug, and ship code — right from your phone.
Features
Everything you need for a productive AI coding workflow on mobile.
One-Command Setup
A single curl command sets up Termux, Ubuntu, Node.js 22, the agent, Ollama, and device skills — everything in one go.
Hybrid AI Backend
Choose cloud APIs (OpenAI, Anthropic) or run models locally via Ollama for offline, private coding.
Full Ubuntu Environment
Runs in a real Ubuntu instance via proot-distro with Node.js 22 — no root required, no containers, no VMs.
Persistent Memory
MEMORY.md preserves context across sessions. Pi remembers what you're working on and picks up where you left off.
Custom AI Persona
Define Pi's personality and behavior in SOUL.md. Make it match your coding style and communication preferences.
Android File Access
Agent configs live in /sdcard/pi — edit them from any text editor on your phone. No terminal required for configuration.
Termux API Skills
Pi knows how to use your Android hardware — camera, SMS, sensors, location, notifications, and more via auto-discovered Termux API skills.
Run Local with Ollama
Don't want to rely on cloud APIs? Pi supports Ollama as a local backend — run models like Llama 3, CodeGemma, and DeepSeek Coder directly on your device. No API keys, no internet, no data leaving your phone.
Switching between cloud and local is a single config change. Point Pi at your Ollama instance and it auto-detects available models — no restart required.
Cloud APIs give you the most capable models. Ollama gives you full privacy and offline access. Use whichever fits the moment — or both.
Fully Offline
Run models without an internet connection. Perfect for coding on the go or in restricted networks.
Private by Default
Your code never leaves your device. No tokens sent to third-party servers, no usage tracking.
Seamless Switching
Switch between cloud APIs and local models with a single config change. No re-install, no downtime.
Android Device Skills
Pi can interact with your Android hardware through Termux API skills. Send SMS, take photos, check battery, read sensors, show notifications, record audio, and more — all through natural conversation with your agent.
Skills are auto-discovered when Pi starts. Install them with a single command and Pi immediately knows how to use every Termux API command on your device.
curl -fsSL https://raw.githubusercontent.com/perminder-klair/droidclaw/main/scripts/skills-setup.sh | bashDevice & Sensors
Battery status, brightness, torch, vibrate, volume, sensors, fingerprint, GPS location, WiFi, clipboard, notifications, dialogs, toasts, wake lock, wallpaper, and downloads.
Comms & Media
SMS send & receive, contacts, call log, camera photos, microphone recording, text-to-speech, media playback, file sharing, storage picker, and calendar access.
What Gets Installed
Here's exactly what the setup script does — no surprises.
Update Termux
Upgrades all Termux packages non-interactively
Install proot-distro & termux-api
Adds proot for Linux distros and API access
Setup Shared Storage
Creates ~/storage/shared/pi/ for config files
Create Agent Configs
Writes AGENTS.md, SOUL.md, and MEMORY.md
Install Ubuntu
Sets up Ubuntu via proot-distro
Install Node.js 22
Adds Node.js via NodeSource inside Ubuntu
Install pi-coding-agent
Installs @mariozechner/pi-coding-agent globally
Create Launcher & Symlinks
Adds start-pi command and Termux API symlinks