cd /news/ai-agents/bypassing-adb-0-32ms-android-ui-tree… · home › topics › ai-agents › article
[ARTICLE · art-174241] src=github.com ↗ pub= topic=ai-agents verified=true sentiment=↑ positive

Bypassing ADB: 0.32ms Android UI trees and A* routing for AI agents (Rust/Kotlin

A benchmark suite published by the DroidPath project measured its Shadow DOM plus A* spatial-graph router at 0.32 ms steady-state latency for retrieving a 54-node Android UI tree on an unlocked Google Pixel 10a, versus 2,423.9 ms and 29,357 bytes (~7,340 tokens) for an `adb exec-out uiautomator dump` XML loop and 658.1 ms for a raw PNG screencap. DroidPath streams incremental NDJSON accessibility diffs over a persistent loopback TCP socket and executes learned multi-hop paths locally in Rust via A*, reaching 100% success (3/3) on live Settings navigation tasks at an average 603 ms cold-start and 561 ms warm. The project claims the approach is 7,575× faster than uiautomator in steady state and cuts text tokens 2.7× versus the XML hierarchy, with opt-in hybrid vision returning a 38,581-byte JPEG (q45) in 452.33 ms.

recommendation

Replace per-step ADB uiautomator dumps with a persistent accessibility-diff stream and local A* path execution to avoid intermediate LLM turns, and keep vision capture opt-in only for canvas or icon disambiguation.

more in playbook: Designing agent systems
read3 min views1 publishedNov 22, 2026
Bypassing ADB: 0.32ms Android UI trees and A* routing for AI agents (Rust/Kotlin
Image: Michielbdejong (auto-discovered)

You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert

This benchmark suite compares DroidPath (Shadow DOM + Layer 3 A Spatial Graph Router)* against the two dominant Android automation paradigms used by autonomous AI agents:

Pure Vision (Screenshot + VLM loop) — captures a full-resolution PNG screenshot on every step and sends it to a Vision-Language Model to predict (x, y) coordinates.

Appium / uiautomator dump XML loop — runs uiautomator dump over ADB on every step and feeds the raw XML hierarchy (~25–35 KB) to an LLM.

DroidPath (Shadow DOM + Layer 3 A)* — streams incremental NDJSON accessibility diffs over a persistent loopback TCP socket (android-daemon) and executes learned multi-hop paths locally in Rust via A* without intermediate LLM turns.

Transparency Note: Hardware primitive latencies and End-to-End (E2E) Settings navigation timings below were measured live over USB ADB on an unlocked Google Pixel 10a (61061JEA307110, Android com.android.settings root screen, 54 live UI nodes) using node scripts/benchmark_agentic.mjs --mode live --json against compiled target/release/droidpath-mcp. Multi-step Pure Vision and Appium/XML comparisons in the replay table run real droidpath-mcp stdio JSON-RPC calls against a 60-node loopback Shadow DOM daemon paired with explicit token and cost formulas documented under Methodology & Token Model.

  1. Live Hardware Probe (Unlocked Google Pixel 10a · com.android.settings, 54 Nodes)

Primitive / Method

Status

Measured Latency

Payload Size

Notes

DroidPath android_get_ui_tree (steady-state) ok

0.32 ms

10,742 bytes (~2,686 tok) 54 live UI nodes from local Shadow DOM stream (7,575× faster than uiautomator)

DroidPath android_get_ui_tree (cold connect)

ok

41.89 ms

10,742 bytes (~2,686 tok) First TCP connect + live snapshot (58× faster than uiautomator)

DroidPath Hybrid Vision (include_vision: true) ok

452.33 ms

38,581 bytes JPEG (540×1212) 54 live UI nodes + compressed JPEG (q45, 6.1× smaller than raw PNG)

adb exec-out screencap -p (raw PNG) ok

658.1 ms

235,258 bytes PNG

Visual capture only — no structured UI tree

adb exec-out uiautomator dump /dev/tty (XML) ok

2,423.9 ms

29,357 bytes (~7,340 tok) Requires stopping UiAutomation daemon; 2.7× more text tokens than Shadow DOM

  1. Live End-to-End Hardware Navigation (Google Pixel 10a · Real Seed Hydration → Warm A*)
Task (Settings → Target)

Cold-Start (Seed Hydration)

Cold Status

Warm A* Graph

Warm Status

Live Success Rate

Settings → Display

378.6 ms

arrived

296.2 ms(1 step) arrived

100%

Settings → Battery

655.9 ms

arrived

642.8 ms(1 step) arrived

100%

Settings → About phone(scroll required) 775.7 ms

arrived

744.1 ms(1 step) arrived

100%

Average across live suite

603 ms

100% (3/3) 561 ms

100% (3/3) 100%

  1. Local MCP Runtime Micro-Benchmarks (Measured) Metric

Measured Value

tools/list JSON-RPC latency (9 tools) 0.25 ms

android_graph_stats JSON-RPC latency

0.42 ms

Pre-hydrated Seed Graph loaded at boot

20 vertices / 19 edges

Compact Shadow DOM tree (60-node mock Settings screen)

Text tokens:ceil(utf8_bytes / 4) (standard BPE approximation for JSON/XML).

Cost / 1,000 tasks: Computed transparently at $3.00 / 1M input tokens (standard Claude Sonnet-class API pricing): (avg_tokens_per_task * 1,000 / 1,000,000) * $3.00.

Vision image tokens: Anthropic's published (W × H) / 750 formula for a 1080×2400 Android screenshot scaled to 1568px long edge (706 × 1568 / 750 = 1,477 image tokens + ~350 prompt/tool tokens = 1,827 tokens/step).

Opt-in Hybrid Vision (include_vision: true): Downscaled 540px-wide JPEG (quality: 45, measured 38.6 KB on unlocked Pixel 10a Settings vs 235.3 KB raw PNG) is strictly opt-in and only used when an agent explicitly needs visual disambiguation (e.g., canvas/icons), remaining strictly blocked on FLAG_SECURE screens.

── more in #ai-agents 4 stories · sorted by recency
── more on @droidpath 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/bypassing-adb-0-32ms…] indexed:0 read:3min 2026-11-22 · —