android_use
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
First call aua_setup(status), start if absent, then aua_ready. The host agent owns task understanding, planning, exact text composition, recovery and final business verification. Use aua_execute_goal for a short local UI subgoal: Jev, when enabled, decides the next candidate; otherwise you decide each step with aua_goal_decide. Android Use alone executes actions. Known paths should still use batch. Optimize end-to-end completion time and success rate, reducing host-model round trips. Do not route based on Jev token cost. With Jev, delegate a coherent local decision loop rather than asking the host to approve every low-level choice. Reuse a safe returned observation when planning the next step instead of immediately reading it again. On handoff inspect steps and current state, then continue with existing tools; do not repeat the original goal blindly. Jev does not replace the host agent. Use trees first, screenshots for visual content/failures; aua_locate or tap visual only when no tree target exists and the user opted in to sending screenshots. Actions accept wait_for={selector,state:visible|gone,timeout_seconds}; use scroll_until for bounded list search. An unmet condition never replays the action. Execute actions once; do not replay uncertain mutations. Password/PIN/OTP authentication belongs to the user: pause, ask, await confirmation, resume and observe. Verify final business outcomes from actual device state.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| aua_read_fieldsA | Read-only Jev field judgments on current app text. source=auto uses the tree when text/expected_labels and money candidates suffice; otherwise captures a device ROI and runs local macOS Vision OCR (requires Xcode Command Line Tools). source=tree disables OCR; screen_ocr forces it. OCR pixels are checked again after inference. No visual clicks. Extract code-owned money/text spans or classify supplied options, all fields in one request. Requires Jev enabled. evidence_text optionally supplies Agent OCR text, explicitly marked caller_provided_text, not verified as a phone read. Missing/ambiguous values return NONE. Decimal parsing is local. region limits evidence in display pixels; ocr_masks exclude non-evidence from OCR and hashing. min_ocr_confidence is optional uncalibrated provider telemetry, not accuracy. Declare currency for ambiguous symbols. Optional sum_check validates same-currency Decimal sums in code; no device actions. verified=false always requires Agent business verification. |
| aua_locateA | Read-only Jev Box location for elements the accessibility tree lacks (canvas, games, WebView images, icons without labels); small text such as prices or tags is unreliable, so select text with selectors. Sends one masked screenshot of region (default full display) to TypeSafe, so it needs Jev plus the separate images opt-in (允许发送截图(视觉定位) in screen settings, or ANDROID_USE_JEV_IMAGES=1); otherwise jev_images_disabled. Refuses password/OTP screens and paused devices. One request asks presence, match count and a box; status is located, not_found, ambiguous, low_confidence or masked; a box spanning several tree labels is ambiguous with reason and tree_candidates. box=[x,y,width,height] and tap=[x,y] are display pixels; tap is set only when located. masks blank sensitive areas before upload. Prefer trees/selectors when they work; a located box is a model judgment, not verification. |
| aua_execute_goalA | Agent plans, a decision policy selects candidate IDs, Android Use executes. decider=auto uses Jev when enabled (TypeSafe key in screen settings, or ANDROID_USE_JEV_ENABLED=1 / TYPESAFE_API_KEY; sends visible app UI text to TypeSafe), otherwise host: no key, nothing sent externally. Host mode returns status=decision_required with compact state, option IDs and a one-time token; choose with aua_goal_decide. Caller supplies goal, foreground package, exact input texts and optional completion selector. Compact semantic state and parallel operation/target questions share one Jev request per step. Each Jev request also judges goal completion; without a completion selector a confident ACHIEVED stops before another action (stop_reason=model_goal_achieved, unverified: check it). input_macros=true can combine stable-field focus and exact input with native readback; max_steps counts candidate selections, with at most two native writes per input macro. Bounded candidate-only actions; no automatic replay. status=handoff is not success. effect_timeout_seconds bounds observation after acknowledged mutations; unresolved effects hand off without another mutation. Geometry-only changes do not prove an effect. Keep existing tools for planning, unsupported controls and recovery. Password screens hand off. |
| aua_goal_decideA | Host-decider step of aua_execute_goal: send one option ID from the latest decision_required result with its one-time token. Android Use reads the UI again; if it changed, the choice is discarded and a fresh decision is returned (previous_choice_stale=true). Otherwise it executes that candidate once, checks its effect and returns the next decision, completion or handoff. An unknown option ID keeps the token; any other outcome consumes it. Tokens expire after 5 idle minutes and need the same MCP server process. timeout_seconds counts device time only, not host thinking time. |
| aua_tapA | Tap once by selector OR x/y display pixels OR visual (aua_locate args: Jev Box with the images opt-in). visual taps the box center only when located, after rechecking the pixels around the box, never in batch. Ambiguity returns candidates and a screenshot. Optional wait_for waits for visible/gone selector after action; timeout never replays it. Optional observation_id checks same runtime/app/display context. No automatic replay. |
| aua_long_pressB | Long press once by selector OR x/y display pixels for duration seconds (0.5..3). Supports wait_for and observe. Inspect uncertain results; no replay. |
| aua_double_tapA | Perform one intentional pair at selector OR x/y display pixels. interval is seconds between clicks, excluding RPC latency. Supports wait_for and observe. A failed pair may have executed its first click; never replay automatically. |
| aua_dragB | Drag once from start {x,y} to end {x,y}, in Android display pixels. Supports duration, observation_id, wait_for and observe. No automatic replay. |
| aua_scroll_untilA | Find a visible selector, swiping only if absent. Bounded by max_swipes and timeout_seconds; stops after two unchanged regional snapshots, or app/display change. Does not click the result. no_progress does not prove list end. Use region for nested lists. |
| aua_type_textA | Set Unicode text on a focused, editable, non-password field. Focus it with tap first. Default replace=true, no submit. verify checks exact readback. App must support setText. Newlines need allow_newlines=true. Never blindly retry uncertain input. |
| aua_swipeC | Perform one swipe. Direction is finger motion: up usually reveals later rows. Use display-pixel region if needed, observe for next-step context. No automatic retries. |
| aua_press_buttonC | Press home/back/recent/enter/volume once. Enter may submit; user must authorize it. |
| aua_launch_appB | Launch an installed package's launcher activity once; no force-stop or data reset. |
| aua_observeC | Read a current accessibility tree and/or screenshot. Coordinates are Android display pixels; image pixels multiplied by pixel_to_device give action coordinates. |
| aua_waitA | Wait at most 20 seconds for a selector to be visible or gone. condition_met reports the requested condition; found reports current visible matches. |
| aua_findC | Find exact text/description/resource_id/class_name/package or substring text/description. Multiple targets require an explicit 0-based index; bounds don't prove unobstructed access. |
| aua_doctorA | Read local ADB device inventory and configuration. Does not start a phone service. |
| aua_setupA | First use: status/discover, start once if needed, then ready. configure selects a serial. start pushes a pinned JAR and reuses/starts UiAutomator without root or keyboard APK. |
| aua_readyB | Verify unlocked screen, UiAutomator, foreground, display and a nonempty tree. Does not start/restart services. Reuse the returned observation. |
| aua_appsA | List installed third-party package IDs; query matches package ID, not human app name. |
| aua_pauseA | Pause Android Use reads/actions for user authentication takeover across CLI/MCP processes. |
| aua_resumeA | Resume only after user confirms authentication is finished; then get a fresh observation. |
| aua_screenA | Open/reuse the Android live screen sidebar. Uses an independent H.264 video stream, not screenshot/tree polling. Requires ffmpeg. READY also links the same panel. |
| aua_screen_frameB | App-only cached video frame. Does not query UI trees or capture screenshots. |
| aua_screen_actionC | App-only preview controls and local Jev settings. Phone actions are blocked during authentication takeover. Settings never return credentials; save tests a fixed synthetic Choice before enabling. Users enter their own key in the screen UI. |
| aua_batchA | Execute up to 20 known steps, using each operation's normal args. Entire plan is validated before actions. Stops on error, unmet condition, scroll miss, Enter submission or 25s budget (in-flight RPCs may overrun). Resume from stopped_at; never replay completed/uncertain steps. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| Android 手机屏幕 |
TDQS
Scored across 26 tools
Most tools are cleanly separated by gesture or resource (tap vs long_press vs double_tap vs drag vs swipe), and the observe/find/wait trio has clear boundaries (read tree, locate selector, block for condition). The fuzziest pairs are aua_swipe vs aua_scroll_until (both motion-based, though one targets a selector) and aua_screen/aua_screen_frame/aua_screen_action, which require reading descriptions carefully. aua_execute_goal vs aua_goal_decide is well explained as an auto/host decider pair.
All 26 tools share the aua_ snake_case prefix with mostly verb-based names (aua_tap, aua_launch_app, aua_read_fields, aua_execute_goal). A few outliers are nouns/adjectives rather than verbs (aua_screen, aua_apps, aua_doctor, aua_ready), a minor deviation. The convention remains predictable despite the large set.
26 tools is at the heavy end — the rubric's 'borderline/heavy' band. Android UI automation is genuinely broad (gestures, observation, vision, goal-driving, setup, diagnostics), so most tools map to real capabilities, but a few niche ones (aua_screen_frame, aua_screen_action, aua_pause/aua_resume) inflate the surface and add selection cost.
Coverage is strong for device automation: gesture input, observation, find/wait, app launching, batching, setup/diagnostics, and a goal-driven loop. Gaps are smaller: no app install/uninstall or force-stop, no file/ADB shell passthrough, and key input limited to home/back/recent/enter/volume. These are workable around but leave a few dead ends.