ha-android-architecture
Skill by home-assistant
Home Assistant Android architecture guides an AI assistant through module, layer, dependency injection, storage and API decisions in the Home Assistant Android app. It is for developers contributing to that codebase.
Install ha-android-architecture
Built from the published package, never by AI.
git clone --depth 1 https://github.com/home-assistant/android /tmp/android && mkdir -p ~/.claude/skills && cp -r /tmp/android/.agents/skills/ha-android-architecture ~/.claude/skills/ha-android-architectureRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
Step-by-step: install ha-android-architecture in Claude Code
git clone --depth 1 https://github.com/home-assistant/android /tmp/android && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/android/.agents/skills/ha-android-architecture ~/.gemini/antigravity-cli/skills/ha-android-architectureAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Step-by-step: install ha-android-architecture in Antigravity CLI
Skills can run scripts on your machine. Some need an API key: check the README.
About
This agent skill is a structured guide to the Home Assistant Android app architecture. It explains which Gradle module and feature package new code belongs in, and how the layers fit together. The layers are ViewModel, Handler, Manager, UseCase and Repository, with dependencies pointing downward only.
The skill also covers Hilt injection rules, storage choices (Room, DataStore, LocalStorage and EncryptedSharedPreferences), and networking with Retrofit and OkHttp. It includes rules for gating features on the Home Assistant server version, securing PendingIntents, and handling the frontend and deep link integration points. It is intended for developers and AI assistants working on the Home Assistant Android codebase.
Written from the project's SKILL.md and checked against it.
What it can do
- Module and package placementShows which module and feature package a new piece of code should live in.
- Layer rulesExplains the ViewModel, Handler, Manager, UseCase and Repository roles and their dependency limits.
- Naming conventionsGives naming patterns for repositories, use cases, managers, handlers, ViewModels and DTOs.
- Hilt dependency injectionCovers scoping choices, custom qualifiers and avoiding manual instantiation of Android entry points.
- Storage guidanceAdvises on Room, DataStore, LocalStorage and encrypted preferences for different kinds of data.
- API networking rulesDescribes Retrofit and OkHttp usage, suspend API interfaces and handling of socket responses.
- Server version gatingShows how to keep new features from breaking users on older Home Assistant servers.
- Intent and context safetyCovers PendingIntent mutability, explicit intent matching and safe use of application context.
- Incremental migrationExplains when changes should land in small steps and when a feature flag is appropriate.
What you need
- Home Assistant Android app codebase
- Kotlin and Gradle project setup
Try asking
- Where should I put a new settings screen in the Home Assistant Android app?
- Write a repository and use case for a new Room-backed feature following HA Android rules.
- How should I store an access token securely in the Home Assistant Android app?
Good to know
- Written for the Home Assistant Android codebase, not general Android projects.
- Newer guidelines are applied as code is touched, not mass-migrated.
- The webview/ package should not be built on; it is kept only for backwards compatibility.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: .agents/skills/ha-android-architecture/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md7 KB
Alternatives to ha-android-architecture
All alternatives →Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.
Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.
Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.
Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.
Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.
Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.
Compare with openclaw-github-repo-commander, gradio or hig-components-menus
ha-android-architecture: common questions
What is the Home Assistant Android architecture skill?
It is an agent skill that documents how the Home Assistant Android app is structured, including modules, layers, dependency injection, storage and API rules.
Who should use this skill?
The source is aimed at developers adding features or contributing to the Home Assistant Android app. It helps them decide where code lives and how it should be written.
Does it cover the Home Assistant API calls?
Yes. It explains that API interfaces live in the data layer of the common module, use suspend functions, and that features should check the server version before use.
How do I install ha-android-architecture?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is ha-android-architecture free?
The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.
Is ha-android-architecture safe to use?
It scores 82 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to ha-android-architecture?
Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.
