[ WORK ]  /  AgentDroid - Android AI Agent & Automation Framework

AgentDroid - Android AI Agent & Automation Framework

An open-source Android AI agent framework for autonomous UI/UX automation, vision-based screen reasoning, self-healing test execution, and automated Appium code generation.

Open SourceKotlin · Android · AI Agents · LLM Vision · Appium · UI Automator · Accessibility Service

AgentDroid: Android AI Agent & Automation Framework

Project Type: Open-Source Android AI & Developer Tooling
Repository: github.com/dcdhameliya/AgentDroid
Tech Stack: Kotlin, Android Accessibility / UI Automator, Multimodal LLM Vision, Appium Codegen


The Problem

Traditional mobile UI testing and automation frameworks (Espresso, UI Automator, Appium) rely on brittle, hardcoded view selectors (resource-id, XPath, or content descriptions). Whenever a product team refactors a screen, migrates from XML Views to Jetpack Compose, or experiments with Server-Driven UI layouts, existing selector-based test suites break - costing engineering teams hours of manual test maintenance on every release.


What AgentDroid Does

AgentDroid replaces brittle selector scripts with goal-driven, multimodal AI agents that understand and interact with Android screens the way a human user does.

1. Multimodal Screen Perception (Accessibility Tree + Vision)

Instead of relying solely on raw pixels or solely on XML view hierarchies, AgentDroid fuses two complementary signals on every step:

  • Semantic UI Hierarchy Extraction: Parses the live Android Accessibility / UI Automator node tree, filtering out non-interactive noise and assigning deterministic bounding-box indices to actionable elements.
  • Vision-Based Grounding: Overlays indexed visual markers onto a compressed frame capture so multimodal LLMs can reason accurately about custom canvas views, Jetpack Compose nodes, icons without accessibility labels, and visual layout state.

2. Autonomous Goal Execution & Self-Healing Tests

Given a natural-language objective (for example, "Complete the guest checkout flow and verify the order summary total"), AgentDroid runs a structured Observe -> Reason -> Act -> Verify loop:

  • Executes taps, text entry, directional scrolls, and system navigation actions deterministically.
  • Detects unexpected dialogs, permission prompts, or layout shifts at runtime and self-heals by re-evaluating the semantic screen state rather than failing on a missing view ID.

3. Automated Appium & UI Test Code Generation

To bridge autonomous exploration with fast CI/CD execution, AgentDroid records validated agent trajectories and compiles them into clean, reproducible Appium / UI test scripts with resilient locator fallbacks - letting teams author end-to-end mobile regression suites in minutes instead of days.