Component 2: Android Skills and the SKILL.md Format
Android Skills solve a distinct problem from the CLI. Even with a clean, agent-friendly command interface, an agent still needs to know what steps to take and in what order when performing complex tasks that span multiple files, dependencies, and build configurations. Skills provide that knowledge in a structured, reusable format.
An Android Skill is a modular, Markdown-based instruction file — named SKILL.md by convention — that gives an AI agent a documented, step-by-step procedure for a specific Android development task. The format pairs a YAML front matter block for metadata with a Markdown body that contains the instructions, prerequisites, validation steps, and rollback procedures:
---
name: xml-to-compose-migration
description: Migrate an Android project from XML layouts to Jetpack Compose
triggers:
- "migrate to compose"
- "convert xml to compose"
- "xml layout migration"
---
## Prerequisites
- minSdk must be 21 or higher
- Project must use AGP 8.0 or higher
- Kotlin version 1.9 or higher required
## Steps
1. Add Compose BOM to dependencies in build.gradle.kts
2. Enable compose = true in the buildFeatures block
3. Migrate View-based layouts to composable functions
4. Update activity and fragment entry points
5. Run validation build to confirm no regressions
The triggers field enables automatic skill activation: when a developer’s prompt contains one of the listed trigger phrases, the agent automatically loads and applies the relevant skill without requiring the developer to attach documentation manually. You type “migrate to Compose” and the agent applies the full documented procedure — prerequisites verification, ordered step sequence, validation commands — rather than attempting to reconstruct the migration from general training knowledge that may be incomplete or dated.
The initial release ships four skills covering the most common migration and configuration challenges:
- Navigation 3 setup: Migrating from legacy NavController-based navigation to the Navigation 3 API, including deeplink handling updates and back stack adjustments
- Android Gradle Plugin 9 migration: Updating build configuration to handle AGP 9.0 breaking changes in the dependency resolution model
- XML-to-Compose migration: Converting View-based layouts to Jetpack Compose, covering the BOM dependency, buildFeatures setup, and layout conversion
- R8 configuration analysis: Diagnosing and correcting ProGuard/R8 rule issues including keep rule gaps and missing reflection annotations
Google has committed to expanding the Skills library over time. The SKILL.md format is explicitly designed for community contribution: developers can author skills for internal frameworks, library-specific workflows, or common patterns their team repeats, and share them with the broader community. Skills can include optional scripts/ subdirectories for executable code and references/ subdirectories for extended technical documentation that agents can retrieve when the task requires deeper context.
Component 3: The Android Knowledge Base
The third component addresses a fundamental limitation that has made AI agents less reliable for active Android development: training data cutoffs. A model trained through 2024 has learned the Android APIs that existed then. For newer APIs and components — features introduced in Android 15, the updated Privacy Sandbox APIs, changes in API level 36 — its knowledge is either absent or based on in-progress previews that changed before final release.
The Android Knowledge Base is a real-time documentation repository that agents query during development sessions to retrieve authoritative, current documentation. It is accessible via the android docs command in the CLI and is integrated directly into the latest version of Android Studio. When an agent needs to verify the current signature of a recently added API or confirm the migration path for a changed component, it queries the Knowledge Base rather than relying on memorized training data that may be months stale.
This matters most for teams working at the leading edge of Android development. A project targeting API 36 with features from Android 16 gets accurate implementation guidance even from a model with a 2024 training cutoff, because the agent retrieves current documentation on demand. The Knowledge Base directly addresses the “confident but wrong” failure mode that has made agents untrustworthy for new API adoption — when an agent asserts incorrect API usage confidently, a developer has to investigate and correct every instance, which negates much of the productivity gain from using an agent at all.
Practical Workflow: Using All Three Components Together
Here is how Android CLI, Skills, and the Knowledge Base combine in a typical session. The example uses Claude Code, but the same workflow applies with Gemini Code Assist in Android Studio or OpenAI Codex.
Install the CLI for your platform. On Apple Silicon:
curl -L https://dl.google.com/android/tools/agents/android-cli-macos-arm64 -o android
chmod +x android
mv android /usr/local/bin/
Set up the project environment. The CLI handles SDK installation and project scaffolding in two clean commands:
android sdk install --platform 36
android project create --template compose-starter --name MyApp --package com.example.myapp
Attach the Skills repository to your agent. With Claude Code, place or reference the official Android Skills repository in your project context. The agent will activate relevant skills automatically when trigger phrases appear in your prompts. With Gemini Code Assist in Android Studio, the Skills library is already integrated — no configuration needed.
Develop with natural language instructions. Instead of writing detailed prompts explaining migration procedures, you write the high-level instruction and the relevant skill handles the rest. “Set up Navigation 3 for this project” triggers the Navigation 3 skill; the agent checks prerequisites, applies the required Gradle changes, updates the navigation implementation, and validates the result following the exact sequence documented in the skill file. Compared to a standard coding agent session where you might spend several iterations correcting API usage, the skills-guided approach completes the same task in one pass.
Test on a virtual device. Device management through the CLI stays clean and predictable throughout the session:
android device create --name test-pixel --api 36 --device pixel_9
android device start --avd test-pixel
android project deploy --device test-pixel
For developers already exploring AI-assisted coding with tools like Claude Code, Cursor, and GitHub Copilot, the Android CLI provides the missing layer that makes those tools reliable for production mobile development rather than limited to well-traveled code paths.
What the 70% Token Reduction Actually Means
The 70% reduction in LLM token consumption reflects two improvements working together. First, the CLI’s consolidated interface eliminates the overhead of tool discovery and command formatting — the tokens that agents previously spent figuring out which of four tools handles a given operation and how to construct valid syntax for each. Second, structured output and deterministic errors eliminate retry loops: when an agent issues a correctly structured CLI command and receives clean output, it proceeds immediately rather than entering a diagnostic cycle to recover from an ambiguous error message.
The 3x speed improvement compounds this efficiency. Fewer tokens means faster inference responses from the model. Fewer retry cycles means less total elapsed time per task. And skills-guided task execution means that complex multi-step procedures — migrations, configuration changes, dependency updates — complete on the first attempt rather than converging through successive corrections.
For teams doing serious Android development with AI agents at scale, this translates directly to economics and developer experience. Agent API costs scale with token consumption, so a 70% reduction cuts the per-task inference cost by roughly the same proportion. More importantly, an agent that completes Android development tasks reliably on the first attempt is one that developers trust to handle real work — which determines whether AI-assisted mobile development becomes a genuine productivity multiplier or remains a demonstration technology.
What This Signals About the Future of Mobile Development
The Android CLI is the clearest signal yet from a major platform holder that AI agents are being treated as primary consumers of developer tooling, not occasional add-ons. The explicit design goals — 70% fewer tokens, deterministic output, structured errors, trigger-based skill activation, real-time documentation access — represent a fundamentally different design brief than tools built for human developers who interpret manuals and reason about heuristic errors.
This shift has significant implications for how mobile development teams will work. Teams that build fluency with agent-optimized workflows now — using the Android CLI, Skills, and Knowledge Base as the foundation for AI-assisted development — will compound those capabilities as the Skills library grows and more of the mobile development workflow becomes expressible in agent-friendly terms. The gap between teams using agent-optimized tooling and teams using agents on top of legacy human-oriented tools will widen over the next twelve to eighteen months.
The Android CLI preview is available today at developer.android.com/tools/agents. Start with the initial four Skills, get familiar with the CLI command surface, and evaluate how the workflow changes when your agent has precise procedural knowledge for the migrations your project needs. The developers building these workflows in May 2026 are ahead of where most of the industry will be by the end of the year.
Comments · 0
No comments yet. Be the first to share your thoughts.