ARTEMIS: Next-Gen AI Mobile Test Automation & Autonomous Assistant Platform
Autonomous Real-time Testing, Exploration & Mobile Interaction System
β‘ Test Real Devices from Antigravity & Claude Code β’ Cross-App Automation β’ Zero-Maintenance Testing β’ Bug Repro & Logcat Diagnostics
English β’ δΈζζζ‘£ β’ Workflow Showcase β’ Quick Start β’ MCP for IDEs β’ Benchmarks β’ Discord Community
Live Demo: Setup driving routes and calculate total durations in Google Maps, then open YouTube to play a Coldplay song.
- π€ Cross-App Automation & Autonomous AI Assistant: Operates not just as a robust testing framework, but as an autonomous agent capable of handling complex cross-app workflows and daily tasks via natural language;
- π§ͺ Zero-Maintenance Test Automation: Built upon a "Dynamic-First, Coordinate-Fallback" multimodal locating engine, eliminating fragile XPath/ID selector maintenance and remaining resilient to UI redesigns, system updates, and resolution drift;
- π One-Click Bug Repro & Logcat Diagnostics in IDE: Native Model Context Protocol (MCP) integration allows Antigravity, Claude Code, and Windsurf to drive physical test devices via natural language, automatically capturing crash stacks from Logcat and keyframe screenshots;
- β‘ Ultra-Fast Execution (3β5s per Step): Pioneered an Optimistic Asynchronous Pipeline that completely decouples UI interaction from heavy LLM reasoning, achieving rapid regression throughput in Flash mode;
- π‘οΈ Popup Self-Healing & 10+ Hour Exploration: Proprietary Safety Net double-checks targets before action execution to intercept and clear interfering system popups; Pro mode supports 10+ hours of continuous exploratory & monkey-plus stability testing;
- π Industry-Leading SOTA: Achieved 99%+ task completion on Google Research's AndroidWorld benchmark (100+ complex multi-step tasks).
Experience seamless collaboration between Antigravity and ARTEMIS via native MCP integration β taking you from a natural language requirement to a production-grade diagnostic report in four automated steps:
Ensure an Android device (with USB Debugging enabled) or emulator is connected. The one-click startup script will automatically:
- π οΈ Install System Toolchains: Detect and auto-install ADB, scrcpy, FFmpeg, and Python (
uv) dependencies. - π Mount Global MCP Server & AI Agent Rules: Prompt to automatically install global MCP configurations and the Artemis Mobile Testing Mindset (
rules.md) into your AI IDEs (Antigravity, Cursor, Claude Code, Codex, Windsurf, VS Code, Cline/Roo, OpenClaw).
# 1. Clone repo & navigate to directory
git clone https://github.com/google/artemis.git && cd artemis
# 2. One-click launch
./start.sh# 1. Clone repo & navigate to directory
git clone https://github.com/google/artemis.git
cd artemis
# 2. One-click launch
.\start.batPowerShell does not search the current directory for executable scripts by default, so use
.\start.batwithout a trailing\. In Command Prompt (CMD), usestart.batinstead.
π‘ Tip: Opens
http://localhost:8000in your default browser with a device connection wizard, live screen mirroring, prompt sandbox, and execution replays. You can also run directly from CLI:uv run artemis run "Open Settings, find Battery and tell me current level" --profile flash.
π MCP Setup for Codex / Antigravity / Claude Code / Windsurf (Click to expand)
ARTEMIS includes a native Model Context Protocol (MCP) server. Connect your real phone directly into AI IDEs:
Running ./start.sh (macOS/Linux) or .\start.bat (Windows PowerShell) will prompt you to configure global MCP and testing rules for detected IDEs (or you can install/update anytime later manually using the commands below):
# Auto-install MCP server & global rules for Antigravity / Jetski:
uv run artemis mcp --install antigravity
# Or install for all supported AI IDEs (including Codex):
uv run artemis mcp --install allπ‘ Tip: You can also configure MCP interactively during first-time setup via
uv run artemis init. Pro Tip: If you want to use theartemiscommand globally withoutuv runin any directory, runuv tool install -e .once in the project root.
If you prefer to configure manually, run uv run artemis mcp --generate-config <client> (for example, codex or antigravity) to output the appropriate TOML or JSON snippet. Replace /path/to/artemis with your actual repo path and point command to your .venv Python executable:
- Codex (
~/.codex/config.toml):
[mcp_servers.artemis]
command = "/path/to/artemis/.venv/bin/python"
args = ["-m", "mcp_server"]
cwd = "/path/to/artemis"
[mcp_servers.artemis.env]
PYTHONUNBUFFERED = "1"
PYTHONPATH = "/path/to/artemis"- Antigravity (
~/.gemini/jetski/mcp_config.json):
{
"mcpServers": {
"artemis": {
"command": "/path/to/artemis/.venv/bin/python",
"args": ["-m", "mcp_server"],
"cwd": "/path/to/artemis",
"env": {
"PYTHONUNBUFFERED": "1"
},
"tools": {
"mobile_run_task": { "eager": true },
"mobile_manage_task": { "eager": true },
"mobile_get_device_state": { "eager": true },
"mobile_inspect_trace": { "eager": true }
}
}
}
}- Claude Desktop (
claude_desktop_config.json):
{
"mcpServers": {
"artemis": {
"command": "/path/to/artemis/.venv/bin/python",
"args": ["-m", "mcp_server"],
"cwd": "/path/to/artemis"
}
}
}To ensure your AI coding assistant acts with the rigor of a senior mobile test engineer and never hallucinates UI interactions, we provide a dedicated testing mindset rules file at mcp_server/rules.md (covering Active Exploration before coding, Flash vs. Pro routing strategy, Latency & Timing compensation, and the "Dynamic-First, Coordinate-Fallback" locator pattern).
You can mount or copy mcp_server/rules.md into your AI IDE's rule configuration:
- Antigravity: Add the contents of
rules.mdto your Workspace Rules, Global Rules settings, or agent instructions. - Claude Code: Copy or include the contents of
rules.mdin your project'sCLAUDE.mdfile. - Cursor: Copy the contents into
.cursorrulesor create a rule file at.cursor/rules/artemis.mdc. - Codex: Add the contents to
~/.codex/AGENTS.md(or the activeAGENTS.override.md). - Windsurf / OpenClaw: Add the rules to your workspace rules or global system prompts.
π‘ For more details on the testing mindset and MCP architecture, see the MCP Server README.
In Codex, Antigravity, or Claude Code, simply prompt:
π¬ "Build the latest changes into an APK, install it on the connected device, open the login screen with a test account, verify if there are any unexpected popups after login, and return screenshots of the final page."
π Python SDK Integration (Click to expand)
Embed the mobile automation engine into your Python workflows in just a few lines:
import asyncio
from artemis.interfaces.sdk import ArtemisClient
async def main():
# Initialize client (choose "flash" for fast UI checks or "pro" for deep reasoning & self-healing)
client = ArtemisClient(default_profile="flash")
# Execute natural language end-to-end test case
result = await client.run(
"Open System Settings, go to 'Battery', verify battery percentage is displayed, and check for any crash dialogs."
)
# Structured assertions & execution tracing
assert result.status == "SUCCESS", f"Test failed: {result.failure_reason}"
print(f"β
Test Passed! Turns: {result.turns} | Trace ID: {result.trace_id}")
if __name__ == "__main__":
asyncio.run(main())
π‘ Console Overview: β View Switcher (Home / Workspace) Β· β‘ Model & Replay (Flash/Pro status & video replay) Β· β’ Live Agent Stream (Action perception, target coordinates & structured results) Β· β£ Prompt Dock (Natural language dispatch) Β· β€ Task Queue & Dashboard (Lifecycle & history)
- π₯οΈ Web Visual Test Console (
uv run artemis ui): Real-time screen projection and interactive panel, supporting natural language test dispatch, live reasoning telemetry, action trajectories, and execution replay; - π Native MCP Protocol (IDE Collaboration): Operates as a standard MCP server seamlessly integrating with Antigravity, Claude Code, Windsurf, etc., directly driving real devices inside the IDE to verify bugs and run test cases;
- π» Developer CLI (
uv run artemis run): Direct terminal execution for automated test cases, exploratory stability inspection, or AndroidWorld benchmarks with high-fidelity structured terminal output; - π Python SDK: Integrates as a standard Python library into existing automated testing frameworks (e.g., pytest) or CI/CD pipelines with strongly typed Pydantic structured outputs and assertion support.
| Evaluation Dimension | Traditional Test Automation (Appium / Maestro) | Generic Mobile VLM Agents | ARTEMIS β (Next-Gen AI Testing) |
|---|---|---|---|
| Test Case Maintenance | β Fragile XPath/ID dependencies; UI changes cause test failures | π§ͺ Zero Maintenance: Natural language test cases resilient to UI drift & redesigns | |
| Execution Latency & Throughput | β‘ Fast script execution, but extreme setup and locator debugging costs | β Sluggish 20β30s per step; too slow for regression testing | β‘ High Throughput: Optimistic Async Pipeline runs at 3β5s per step |
| Popup Resilience & Self-Healing | β System popups or permissions immediately crash the script | β Easily gets stuck or loops endlessly on unexpected dialogs | π‘οΈ Pre-Execution Safety Net: Automatically intercepts and clears interfering popups |
| Diagnostics & Multimedia | β Blind static waits (sleep); cannot assert dynamic video/animations | β Static screenshots only; no system logs or underlying state | π Deep Diagnostics: Live video stream analysis & Logcat crash stack capture |
| Dev Environment Integration | β Standalone runner; requires manual log collection upon failure | β Isolated web demos; difficult to embed into dev pipelines | π Native MCP & SDK: Drive physical test devices and debug directly inside Antigravity / Claude Code |
Evaluated on AndroidWorld β Google Research's gold-standard benchmark spanning 20+ real apps and 100+ complex multi-step tasks: Artemis demonstrated exceptional robustness across the entire benchmark suite, achieving a 99%+ completion rate.
- β‘ Optimistic Asynchronous Pipeline: The front-facing loop responds in milliseconds, while memory pruning and assertion verification run concurrently in the background without blocking execution;
- π‘οΈ Safety Net Pre-Execution Gate: Dual-layer pre-check validates target availability milliseconds before action dispatch, instantly intercepting unexpected popups to eliminate blind clicks;
- β±οΈ Time-Sensitive Speculative Chaining: Overcomes LLM inference latency for transient UI elements (e.g. video fullscreen) by predicting target coordinates and executing rapid chained taps.
π Click to expand: Architecture Deep Dive & Pipeline Diagram
- Status Quo & Pain Points: Conventional mobile agents rely on a fully synchronous blocking model β every single action must wait sequentially for the LLM to prune historical context, check milestone assertions, and audit long-term plans. This inflates per-step latency to 20β40 seconds, creating a sluggish user experience.
- Artemis's Architectural Solution: Inspired by Optimistic Concurrency Control (OCC) and Snapshot Isolation in database systems, Artemis completely decouples the main execution loop from heavy auxiliary computation:
- High-Throughput Main Loop: The front-facing execution path is strictly narrowed to a high-speed "Perception β Decision β Safety Gate β Execution" pipeline;
- Background Concurrent Tasks: Context token pruning, milestone checkers (
Checker), and planner validations (Planner) run dynamically in parallel without halting device interaction; - Snapshot Isolation & Rollback: The agent optimistically charges forward. If background verification detects a deviation, Artemis instantly rolls back via state snapshots (Rollback) and injects self-healing feedback.
- Status Quo & The Transient UI Dilemma:
- Mobile applications feature numerous time-sensitive transient UI controls (e.g. video fullscreen: tapping the screen wakes up the floating overlay, followed immediately by tapping the fullscreen icon).
- Traditional agents tap the screen to reveal controls, take a new screenshot, and wait 3β15 seconds for LLM reasoning. By the time the click is dispatched, the player controls have already auto-faded away β causing the click to strike the underlying video, triggering an endless loop of accidental pausing and waking.
- Artemis's Architectural Solution:
- Speculative Chained Actions: Upon recognizing time-sensitive dependencies, the agent dispatches compound chained actions (Wakeup β Millisecond Chained Tap) to hit the target within its transient visibility window;
- Two Pillars Ensuring Reliable Chaining:
- Historical UI Prior Prediction: Predicts the target control's wake-up coordinates based on prior interaction history and app layout heuristics;
- Safety Net Pre-Execution Gate: Milliseconds before the chained action lands, the Safety Net instantly verifies that the target control was successfully revealed at the expected coordinates. If the wakeup failed or an unexpected popup intercepted it, execution is immediately blocked to prevent blind clicks.
| Feature / Dimension | β‘ ARTEMIS Flash (--profile flash) |
π§ ARTEMIS Pro (--profile pro) |
|---|---|---|
| Design Purpose | Lightweight & Fast: Direct deterministic UI actions | Deep Reasoning: Multi-step planning & complex self-healing |
| Step Latency | 3β5 seconds / step | 15β30 seconds / turn (includes planning & verification) |
| Task Duration | Minute-level short tasks (typically β€35 steps) | Runs stably for 10+ hours; monitoring tasks support 24/7 execution |
| Best Suited For | Well-defined standard UI tasks | Complex cross-app workflows, failure self-healing, continuous monitoring |
| Self-Healing | Local step retries | Safety Net Gate + dialog suppression + crash recovery + snapshot rollback |
| Media Analysis | Basic visual perception + High-Speed OCR | Full scrcpy/ffmpeg video stream analysis + Logcat logs |
- Optimistic Asynchronous Pipeline: Ultra-lean main loop + background context compression & milestone checks.
- Pre-Execution Safety Net: Millisecond pre-check gate & speculative chained actions.
- Time-Sensitive Media Tasks: Fullscreen video and audio stream analysis with
scrcpy&ffmpeg. - Native MCP Server: Seamless integration with tools like Antigravity and Claude Desktop.
- Web Visual Console: Live screen projection, interactive playground, and trajectory review.
- AndroidWorld SOTA: Achieved 99%+ task completion rate.
- Cross-Platform Extensions: Exploring iOS and desktop Web perception and execution.
- On-Device Lightweight VLMs: Zero-cloud local execution with lightweight edge vision models.
- Real-time Duplex Voice Mode: Natural voice input with real-time interruption (barge-in) control.
Contributions are warmly welcomed!
- β Star the repo to follow updates and releases
- π¬ Join the Discord Community for technical discussions
- π Open an Issue or submit a Pull Request
This project is licensed under the Apache License 2.0.






