← 返回 Skills 市场
crazytigerman

agent-android

作者 CrazyTigerMan · GitHub ↗ · v0.1.6 · MIT-0
cross-platform ✓ 安全检测通过
94
总下载
0
收藏
0
当前安装
6
版本数
在 OpenClaw 中安装
/install agent-android
功能描述
Control Android over LAN without USB, ADB, or root.
使用说明 (SKILL.md)

\r

Android REPL\r

\r Use this skill to drive an Android device through the public agent-android beta surface published in the aivanelabs/ai-rpa repo.

Runtime prerequisites:

  • agent-android is available on PATH
  • if it is missing, install the CLI with uv tool install aivane-agent-android; then run uv tool update-shell if the command is still not found
  • the user has provided a trusted device URL such as http://\x3Cdevice-ip>:8080 \r The public path is local-first:\r \r
  • the phone hosts the lightweight HTTP service locally\r
  • the desktop connects directly to http://\x3Cdevice-ip>:8080\r
  • UI reads, taps, inputs, and screenshots stay on the phone and controlling machine\r
  • the current tradeoff is LAN-only control; an optional server-side or relay path may arrive later\r \r If an agent-android command suddenly stops working, first check whether the AIVane app or its local API service has exited on the phone.

Safety Boundaries

  • Connect only to a device URL explicitly provided by the user.
  • Do not scan local networks or guess device IP addresses.
  • Treat UI trees and screenshots as sensitive because they may contain private app content.
  • Save screenshots or raw UI dumps only when the user explicitly asks for a file output.
  • Ask for confirmation before operating sensitive apps, private content, account settings, or irreversible actions.
  • Do not expose the phone-side service on a public network.

Core Workflow

\r Every Android control task should follow the same short loop:\r \r

  1. Confirm connectivity with /health\r
  2. Discover the target app with apps if needed\r
  3. Launch one app\r
  4. Inspect the current UI tree\r
  5. Perform one action\r
  6. Inspect again\r \r Keep the loop short. Prefer inspect -> act -> inspect over long speculative command chains.\r \r

Quick Start\r

\r Start the REPL with the user-provided device URL:

  • agent-android --repl --url http://\x3Cdevice-ip>:8080

Built-in help:

  • agent-android --help
  • In the REPL: h \r

Essential CLI Commands\r

\r Use the one-off CLI when you already know the exact action you want.\r \r Connectivity:

  • agent-android --health --url http://\x3Cdevice-ip>:8080

Discovery:

  • agent-android --apps --url http://\x3Cdevice-ip>:8080
  • agent-android --list --url http://\x3Cdevice-ip>:8080
  • agent-android --id com.example:id/search --url http://\x3Cdevice-ip>:8080
  • agent-android --text Search --url http://\x3Cdevice-ip>:8080
  • agent-android --inputs --url http://\x3Cdevice-ip>:8080
  • agent-android --refId 7 --url http://\x3Cdevice-ip>:8080
  • agent-android --xpath 7 --url http://\x3Cdevice-ip>:8080
  • agent-android --get-attr 7 text --url http://\x3Cdevice-ip>:8080

Actions:

  • agent-android --launch com.xingin.xhs --url http://\x3Cdevice-ip>:8080
  • agent-android --tap 7 --url http://\x3Cdevice-ip>:8080
  • agent-android --input 7 "hello world" --url http://\x3Cdevice-ip>:8080
  • agent-android --swipe up --url http://\x3Cdevice-ip>:8080
  • agent-android --back --url http://\x3Cdevice-ip>:8080
  • agent-android --press home --url http://\x3Cdevice-ip>:8080
  • agent-android --screenshot --url http://\x3Cdevice-ip>:8080

Waiting and output:

  • agent-android --wait-for Search --timeout 30 --url http://\x3Cdevice-ip>:8080
  • agent-android --list --raw --url http://\x3Cdevice-ip>:8080 \r

REPL Command Reference\r

\r Use the REPL for exploratory tasks and smoke runs. Short aliases and long names both work.\r \r

Browse\r

\r

  • health or hl\r Check /health.\r
  • l [n] or list [n]\r List the first n elements, or all cached elements when n is omitted.\r
  • ss or snapshot\r Force-refresh the UI tree and print it again.\r
  • f \x3Ctext> or find \x3Ctext>\r Filter by text or content description.\r
  • id \x3CresourceId>\r Filter by Android resource ID.\r
  • ref \x3CrefId>\r Show the full element detail for one refId.\r
  • x \x3CrefId> or xpath \x3CrefId>\r Generate XPath candidates and validate their runtime match counts.\r
  • xx \x3CrefId>\r Tap by the best unique generated XPath candidate. Refuses ambiguous matches.\r
  • vx \x3Cxpath> [idx] or validatex \x3Cxpath> [idx]\r Validate one XPath against the runtime. Optionally inspect one match by zero-based index.\r \r

Interact\r

\r

  • t \x3CrefId> or tap \x3CrefId>\r Tap the element center point from the current tree.\r
  • tx \x3Cxpath> or tapx \x3Cxpath>\r Tap one runtime-resolved XPath target.\r
  • i \x3CrefId> \x3Ctext> or input \x3CrefId> \x3Ctext>\r Input text into a refId target.\r Use --clear or "" to clear instead of typing.\r
  • ix \x3Cxpath> \x3Ctext> or inputx \x3Cxpath> \x3Ctext>\r Input text into one XPath target.\r Use ix \x3Cxpath> -- or --clear to clear the field.\r
  • sw \x3Cd|u|l|r> [--dur N] [--dist N] or swipe ...\r Swipe down/up/left/right with optional duration and distance.\r
  • p \x3Cback|home|recents> or press ... Press a system key.
  • b or back\r Press Back.\r
  • la \x3Cpackage> or launch \x3Cpackage>\r Launch an app by package name.\r
  • s [path] or screenshot [path]\r Capture a screenshot to an auto-generated or explicit path.\r \r

Wait And Inspect\r

\r

  • wf \x3Ctext> [--t N] or waitfor ...\r Wait for an element to appear.\r
  • g \x3CrefId> \x3Cattr> or get \x3CrefId> \x3Cattr>\r Read an attribute such as text, class, bounds, x, y, or xpath.\r
  • apps\r List launcher apps from /apps.\r \r

Session\r

\r

  • raw\r Toggle raw JSON mode.\r
  • vars Show current URL, timeout, raw mode, and tree cache state.
  • set timeout 30 Set the default wait timeout in seconds.
  • h or help\r Show the built-in help text.\r
  • q or quit\r Exit the REPL.\r \r

Common Patterns\r

\r

First smoke flow\r

\r

  1. Start the REPL with agent-android --repl --url http://\x3Cdevice-ip>:8080.
  2. health
  3. apps
  4. la \x3Cpackage>
  5. l
  6. t \x3CrefId>
  7. i \x3CrefId> hello
  8. b
  9. s \r

Find the right package before launch

  • apps
  • la com.example.app
  • l \r

Inspect an element before using XPath

  • l
  • ref 12
  • x 12
  • vx //EditText[@text='Search'] \r

Clear and refill an input

  • i 7 --clear
  • i 7 hello world
  • ix //EditText[@text='Search'] --
  • ix //EditText[@text='Search'] -- hello world \r

Troubleshooting\r

\r

  • If an agent-android command fails, first check whether the AIVane app or phone-side API service has exited.
  • If agent-android is not found, run uv tool update-shell, reopen the terminal, and retry.
  • Re-open the app or restart the phone-side service, then retry curl http://\x3Cdevice-ip>:8080/health.
  • If health works but UI commands fail, run ss to force-refresh the tree before tapping or inputting.\r
  • If tx or ix fails, run vx \x3Cxpath> and make sure the XPath resolves to exactly one runtime match.\r
  • If screenshots fail the first time, confirm the on-device MediaProjection permission prompt was accepted.\r
  • If everything suddenly stops responding, confirm the phone IP did not change and that the desktop is still on the same LAN.\r \r

When To Stop\r

\r Stop and ask for user help when:\r \r

  • the device is unreachable on LAN\r
  • the app is not running and cannot be restarted from the current path\r
  • required Android permissions are missing\r
  • launcher discovery returns nothing useful\r
  • the runtime UI no longer matches the expected screen after repeated refreshes\r \r

References\r

\r

安全使用建议
This skill appears coherent for controlling an Android device over LAN. Before installing: (1) verify the aivane-agent-android/agent-android binary provenance (check the GitHub repo, release artifacts, and package contents) because the 'uv' install mechanism is less familiar; (2) only give the skill explicit, trusted device URLs on your LAN — do not let it discover or scan your network; (3) treat UI trees and screenshots as sensitive and avoid saving or exposing them unless you explicitly request a file; (4) consider running the CLI in an isolated environment or inspecting its binary/script contents after install; (5) ensure the user confirms any actions that affect private apps, accounts, or irreversible operations. If you want higher assurance, request the package source code or a signed release artifact before installing.
能力评估
Purpose & Capability
Name/description, declared required binary (agent-android), and the commands in SKILL.md all align with a LAN Android control CLI. No unrelated credentials, binaries, or config paths are requested.
Instruction Scope
SKILL.md limits actions to interacting with a user-provided device URL and outlines specific commands (health, apps, tap, input, screenshot, etc.). It explicitly warns not to scan networks and to treat UI trees/screenshots as sensitive — instructions do not reference unrelated files, env vars, or external endpoints.
Install Mechanism
The install spec uses 'uv' to install package 'aivane-agent-android' which creates the agent-android binary. 'uv' is not a widely-known global package host like official GitHub releases/homebrew; installing a third-party CLI writes a binary to disk and should be verified. This is not necessarily malicious but is a provenance/trust risk to check.
Credentials
The skill requests no environment variables or credentials. The only sensitive I/O is UI trees and screenshots returned by the device API (expected for this purpose); SKILL.md instructs to save such data only on explicit user request.
Persistence & Privilege
always:false and default autonomous invocation are set; the skill does not request permanent inclusion or modify other skills. Installation creates a single CLI binary which is expected for this use-case.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install agent-android
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /agent-android 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v0.1.6
Shorten the ClawHub summary to highlight LAN Android control without USB, ADB, or root.
v0.1.5
Clarify how to install the agent-android CLI when it is missing.
v0.1.4
Replace fenced code blocks with inline command lists for ClawHub readability.
v0.1.3
Declare OpenClaw runtime metadata and reduce install/persistence warning signals.
v0.1.2
Remove platform-specific skill install instructions and add runtime safety boundaries.
v0.1.1
Initial public OpenClaw skill for AIVane Android REPL.
元数据
Slug agent-android
版本 0.1.6
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 6
常见问题

agent-android 是什么?

Control Android over LAN without USB, ADB, or root. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 94 次。

如何安装 agent-android?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install agent-android」即可一键安装,无需额外配置。

agent-android 是免费的吗?

是的,agent-android 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

agent-android 支持哪些平台?

agent-android 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 agent-android?

由 CrazyTigerMan(@crazytigerman)开发并维护,当前版本 v0.1.6。

💬 留言讨论