Logo vun Android Ui Automation

Android Ui Automation

Organisatioun
OpenMinis
android-ui-automation

Automate Android apps that have no public API or web version by driving the UI layer through the Accessibility Service. Handles: deep-link launch (open an app into a specific screen), intelligent node location (find a button or text by fuzzy match, not exact text), tap-and-verify (confirm an action had its effect), and human-like swipes. Use this whenever the user wants to control a phone-only app on Android — e.g. "open Spotify and play X", "tap the like button", "swipe through my feed", "play 连名带姓", anything involving `spotify://`, `weixin://`, or apps with no web/API surface. Also use when the user asks why an automation didn't work (permissions, missing app, hidden view trees). Android-only; requires the Minis Accessibility Service enabled.

Iwwersiicht

EditeurOpenMinis
RepositoryMinisSkills
Skill-Nummandroid-ui-automation
Stären
543
Forks
86
Matgeliwwert Fichieren
6
LizenzMIT
Linken
  • Instruktiounen am Markdown-Format

    Eng SKILL.md-Datei, déi de Modell bei Bedarf luet, soudatt nëmmen Token ufalen, wann eng Ufro tatsächlech dozou passt.

  • Funktionéiert mat all LLM

    KI-Skills si reng Markdown, keen ubidderspezifesche Code. Dofir funktionéiert dëse Skill mat GPT, Claude, Gemini, Grok oder engem lokale Modell.

  • 6 matgeliwwert Dateien

    Skripten, Virlagen a Referenzen, déi de Modell beim Schaffe liese kann. D'Dateie kënnen nëmme gelies ginn a ginn ni ausgeféiert.

  • Open Source

    Vum OpenMinis op GitHub verëffentlecht. Liest de Quelltext, ier Dir de Skill installéiert.

Installatioun

Installéiert de KI-Skill Android Ui Automation an TypingMind, fir e mat all LLM ze benotzen, oder füügt en an en anere KI-Agent an, deen SKILL.md liest.

1

An TypingMind installéieren

TypingMind installéiert e Skill direkt aus sengem GitHub-Dossier — dobäi gëtt SKILL.md gelies, d'Ressourcedateie gi gebëndelt an d'Resultat gëtt lokal gespäichert.

  1. Maacht d'App op a gitt op Plugins → Skills.
  2. Wielt „Vun GitHub installéieren“.
  3. Pecht d'URL vum Skill-Dossier hei drënner an a bestätegt.
    https://github.com/OpenMinis/MinisSkills/tree/main/android-ui-automation
  4. Aktivéiert de Skill an all Chat, an deem Dir e benotze wëllt.
Plugins → Skills → Skill afügen → Vu GitHub-URL, pecht dann d'URL vum Dossier an a klickt op Weider.
2

An engem anere KI-Agent installéieren

All KI-Agent, deen d'Format Agent Skills liest, kann dëse Skill benotzen — kopéiert den Dossier an de Skill-Verzeechnes vun deem KI-Agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/OpenMinis/MinisSkills.git /tmp/MinisSkills
mkdir -p .claude/skills
cp -r /tmp/MinisSkills/android-ui-automation .claude/skills/android-ui-automation
Start Claude Code nom Kopéieren nei, fir datt den neie Skill erkannt gëtt.

An TypingMind benotzen

Aktivéiert Android Ui Automation an engem Chat vun TypingMind, an de Modell iwwerhëlt de Rescht. Den Numm an d'Beschreiwung stinn am System-Prompt. Soubal eng Ufro dozou passt, luet de Modell déi komplett Instruktioune selwer — Dir musst de Skill ni manuell opruffen, an et fale keng Token un, bis en tatsächlech benotzt gëtt.

De Modell luet Android Ui Automation automatesch, soubal eng Ufro dozou passt.

Funktionéiert mat all KI-Modell

KI-Skills si reng Markdown-Instruktiounen amplaz vun ubidderspezifeschem Code. Dofir ass Android Ui Automation net un de Modell gebonnen, fir deen de Skill geschriwwe gouf. Installéiert en eemol an TypingMind a benotzt e mat GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama oder engem lokale Modell, deen Dir selwer bedreift — alles mat Ären eegenen API-Keys.

  • Gëtt nëmme gelueden, wann et néideg ass

    De System-Prompt enthält nëmmen den Numm an d'Beschreiwung. D'Instruktioune gi bei der éischter passender Ufro gelueden, soudatt en onbenotzte Skill näischt kascht.

  • De Modell am lafende Chat wiesselen

    Well de Skill aus Instruktiounen amplaz vu Code besteet, funktionéiert en och no engem Modellwiessel — den nächste Modell liest déi selwecht SKILL.md-Datei.

Skill-Instruktiounen

Dëst ass den Inhalt vu SKILL.md, deen de Modell luet. Liest e virun der Installatioun — e Skill besteet aus Instruktiounen, déi Äre Modell befollegt.

Android UI Automation

Drive Android apps through their UI layer when they have no public API or web version. This is the fallback that makes "phone-only" apps automatable.

Environment & dependencies (read first)

This skill drives the user's Android phone. It relies on two CLI tools that ship with the Minis app for Android (installed at /usr/local/bin/ inside the Minis runtime):

CLIRole
android-a11y-cliAccessibility-Service bridge: ui dump, tap node, gesture swipe, wait, extract, ...
android-openLaunch any URL/scheme via the system handler (spotify://..., weixin://..., tel:, ...)

Prerequisites on the device:

  1. Minis app installed (Android). These CLIs do not exist on other hosts (macOS/Windows/other Linux) — verify with which android-a11y-cli first, and if missing, tell the user this skill only runs inside Minis on Android.
  2. Minis Accessibility Service enabled: Settings → Accessibility → Minis. Check with android-a11y-cli service ping; if it reports not running, ask the user to re-enable it before anything else.
  3. The target app installed on the same device.

These are device-side capabilities, not network APIs — no API keys, no OAuth, no server. If a step returns permission_denied from the a11y service, it means the service was revoked; recover via Settings → Accessibility.

When to use

  • The target app has no API / no web page (WeChat Moments, many CN apps).
  • Offload fine-grained clicking to reliable scripts instead of brittle commands.
  • The user asks to play/search/open/tap/swipe inside an installed Android app.

Do not use this for apps that already have a proper skill (e.g. bilibili-hub, spotify-hub) — prefer the API path when one exists.

Core workflow

Follow this order. Each step has a reason; don't skip verification.

  1. Resolve the target Confirm the app is installed. If unsure, ask the user or try the deep link and check the foreground package (see step 2).

  2. Launch via deep link — scripts/open_deep_link.py

    python3 scripts/open_deep_link.py "spotify://search/circles%20post%20malone" --pkg com.spotify.music
    • It constructs/opens the link and verifies the app reached the foreground.
    • Percent-encode query values (CJK and &/? break raw links).
    • If it returns ok:false, don't proceed — the app is missing, the scheme is unhandled, or something redirected. Surface the error.
    • ⚠️ Some apps (Spotify) land on a suggestion page, not results — tap a suggestion row first (see references/app-deep-links.md), then locate the result.
  3. Locate the node — scripts/find_node.py

    python3 scripts/find_node.py "Circles" --clickable-only --top 5
    • Uses fuzzy scoring (exact > substring > node-fragment), prefers clickable.
    • Read the nodeId and center from the top result.
  4. Tap and verify — scripts/tap_and_verify.py

    python3 scripts/tap_and_verify.py --query "Circles – Post Malone" --marker "暂停"
    • The marker is the proof it worked (e.g. after tapping play, a pause button must appear). Never report success without a marker.
    • Retries a few times with relocation in case the tree changed.
  5. Human-like swipes (when the tree is unavailable) — use gestures:

    android-a11y-cli gesture swipe X1 Y1 X2 Y2

    Vary distance/pause randomly to look natural. This is the ONLY fallback when an app (like WeChat Moments) hides its view tree.

Why the verify step matters

A raw tap is fire-and-forget: the UI may be mid-animation or the node may have drifted. Verifying a success marker (pause button, title, toast) converts "I clicked something" into "I know it worked". If the marker never appears, say so honestly instead of claiming success.

Known limitations

  • Apps can hide their view tree from the Accessibility Service (WeChat Moments is a known case). When ui dump returns no app nodes, do NOT blind-tap guessed coordinates — either use swipes (scroll-only) or ask the user to tap precisely.
  • The Accessibility Service can be revoked (e.g. after a force-stop). Check android-a11y-cli service status; if not running, ask the user to re-enable it in Settings → Accessibility.
  • Deep-link support varies by app/build. Read references/app-deep-links.md for the tested set and always confirm foreground.

Examples

Play a song on Spotify (no API key, no Premium):

python3 scripts/open_deep_link.py "spotify://search/circles%20post%20malone"
python3 scripts/find_node.py "添加建议"          # suggestion page → tap to get results
python3 scripts/tap_and_verify.py --query "添加建议“circles post malone”" --marker "Circles"
python3 scripts/find_node.py "Circles – Post Malone" --clickable-only
python3 scripts/tap_and_verify.py --query "Circles – Post Malone" --marker "暂停"

Human-like feed scroll (WeChat Moments):

android-a11y-cli ui info            # confirm weixin:// foreground
android-a11y-cli gesture swipe 540 1600 540 800   # repeat with varied distance/pause

Decline gracefully when the app can't be reached: Report ok:false from open_deep_link.py rather than proceeding blind.

Output format

Always report the confirmed state, e.g.:

[Result]

  • Opened: spotify://search/... via deep link, foreground=com.spotify.music
  • Tapped: node ("Circles – Post Malone")
  • Verified: playback bar shows pause button → playing

Matgeliwwert Fichieren

De Modell liest dës Dateie bei Bedarf, wärend de Skill gelueden ass. Si ginn als liesbar Dateie bereetgestallt a ginn ni ausgeféiert.

Heefeg gestallte Froen

Wat mécht de KI-Skill Android Ui Automation?

Automate Android apps that have no public API or web version by driving the UI layer through the Accessibility Service. Handles: deep-link launch (open an app into a specific screen), intelligent node location (find a button or text by fuzzy match, not exact text), tap-and-verify (confirm an action had its effect), and human-like swipes. Use this whenever the user wants to control a phone-only app on Android — e.g. "open Spotify and play X", "tap the like button", "swipe through my feed", "play 连名带姓", anything involving `spotify://`, `weixin://`, or apps with no web/API surface. Also use wh...

Firwat Android Ui Automation op TypingMind benotzen?

Well Dir en eemol installéiert a mat all Modell benotze kënnt. Android Ui Automation besteet aus einfachem Markdown amplaz vun ubidderspezifeschem Code. Dee selwechte Skill funktionéiert also mat GPT-5, Claude, Gemini, Grok oder engem lokale Modell – an Dir kënnt de Modell matzen am Chat wiesselen, ouni datt de Skill ophält ze funktionéieren. TypingMind benotzt Är eegen API-Schlësselen, sou datt Dir d'Ubidder direkt bezuelt amplaz vun engem Abonnement pro Benotzerplaz. Är Skills a Chats bleiwen an Ärem eegene Späicher.

Wéi installéieren ech Android Ui Automation an TypingMind?

Maacht an TypingMind Plugins → Skills → Vu GitHub installéieren op a setzt https://github.com/OpenMinis/MinisSkills/tree/main/android-ui-automation an. TypingMind liest d'Datei SKILL.md, bündelt déi zougehéiereg Dateien an installéiert dat Ganzt als Skill, deen Dir pro Chat aktivéiere kënnt.

Wéi eng KI-Modeller kënnen Android Ui Automation benotzen?

All Modell, deen Dir an TypingMind verbënnt. KI-Skills sinn einfach Markdown-Instruktiounen an net ubidderspezifesche Code. Dofir kënne GPT, Claude, Gemini, Grok a lokal Modeller dëse Skill lueden, wann eng Ufro dozou passt.

Wéi vill KI-Modeller kann ech mat Android Ui Automation benotzen?

Esou vill Dir wëllt. Soulaang e Modell Skills ënnerstëtzt, kënnt Dir Android Ui Automation domat benotzen – GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama a méi – alles op TypingMind mat Ären eegenen API-Schlësselen.

Ass de KI-Skill Android Ui Automation gratis?

Jo. De Skill gëtt vum OpenMinis ënner der Lizenz MIT op GitHub publizéiert. Dir bezuelt nëmmen Ären eegene KI-Ubidder fir d'Token, déi Dir benotzt.

Wat si KI-Skills?

E KI-Skill ass e weiderverwendbaart Pak vun Instruktiounen, dat engem KI-Modell bäibréngt, wéi en eng bestëmmt Aufgab erfëllt. E follegt dem oppenen Agent Skills-Format: eng Datei SKILL.md mat engem Numm an enger Beschreiwung, plus all Scripten, Virlagen oder Referenzdateien, déi de Modell eventuell brauch. De Modell liest d'Instruktiounen eréischt, wann Är Ufro zum Skill passt. En installéierte Skill kascht also näischt, bis e benotzt gëtt.

Wéi ënnerscheede sech KI-Skills vu Plugins oder MCP-Serveren?

E Plugin oder MCP-Server gëtt engem Modell nei Tools, déi en opruffe kann – Code, deen iergendwou leeft an e Resultat zeréckgëtt. E KI-Skill gëtt dem Modell dogéint Wëssen an eng Virgoensweis: wéi en eng Aufgab ugeet, wéi eng Schrëtt en nokënnt a wéi eng gutt Ausgab ausgesäit. Skills bestinn aus einfachem Markdown, brauche kee Server, keen API-Schlëssel a keng Lafzäitëmfeld a funktionéiere mat all Modell.

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇