Screen-Aware MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Screen-Aware MCP ServerLook at the screen and tell me what's under my cursor, then suggest a fix."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Screen-Aware MCP Server & Antigravity Skill
An open-source Model Context Protocol (MCP) server and Antigravity Skill that provides AI coding assistants with high-fidelity, privacy-first computer screen context, cursor position awareness, active window metadata, and visual verification.
π Overview
When building and debugging graphical interfaces or web applications, verbal references like:
"Make this button blue and increase padding." (while pointing cursor at the button)
require the AI agent to know:
What the screen looks like.
Exactly where the user is pointing.
Which application window and UI component is focused.
Screen-Aware MCP solves this by providing structured, synchronized screen context directly to multimodal AI coding agents (such as Google Antigravity) without relying on permanent disk writes, third-party cloud uploads, or invasive screen-recording daemons.
Related MCP server: Screen Agent
ποΈ Core Architecture
flowchart TD
User([User + Screen + Mouse])
User -->|Voice / Text Prompt| Agent[Antigravity Agent]
Agent -->|Skill Guidance| Skill[Antigravity Skill]
Skill -->|Tool Invocations| MCP[Screen-Aware MCP Server]
MCP -->|Win32 / OS APIs| OS[Local OS / Screen / Cursor / Window]
OS -->|Raw Frames & Coordinates| MCP
MCP -->|ImageContent + JSON Metadata| Model[Multimodal AI Model]
Model -->|Visual UI Identification| Agent
Agent -->|Code Changes & Verification| Codebase[(Source Code)]Separation of Responsibilities
Antigravity Skill: Guides the agent on behavior (when to capture screen context, how to correlate cursor coordinates with visual UI elements, how to locate source components, and verify results).
MCP Server: Provides capabilities (capturing screen frames, measuring cursor coordinates, detecting foreground window, packaging multimodal content).
OS Platform Layer: Interfaces directly with native OS APIs (
GetCursorPos,GetForegroundWindow,mssframe buffer) with full DPI awareness.Multimodal Model: Performs visual reasoning over the synchronized screenshot and cursor coordinates.
π Features (Milestone 1 β Read-Only Foundation)
πΈ High-Speed Screen Capture: Native in-memory screen capture via
mss& Pillow.π― Sub-Pixel Cursor Tracking: Exact cursor coordinates + normalized
[0, 1]positions matching hardware pixels (DPI-aware).πͺ Active Window Detection: Detects focused window title, PID, process executable name, and bounding box.
β‘ Synchronized Screen Context: Captures cursor, window, and screen snapshot in a single sub-millisecond call to eliminate coordinate drift.
π Privacy-First: Zero disk persistence by default, local execution, no background surveillance.
π¦ Project Structure
screen-aware-mcp/
βββ server/
β βββ __init__.py
β βββ server.py # MCP Server definition & tool registration
β βββ config.py # Server configuration & environment variables
β βββ tools/
β β βββ __init__.py
β β βββ screen.py # capture_screen implementation
β β βββ cursor.py # get_cursor_position implementation
β β βββ window.py # get_active_window implementation
β β βββ context.py # capture_screen_context synchronized tool
β βββ platform/
β βββ __init__.py # Platform provider selector
β βββ base.py # Abstract OS platform interface
β βββ windows.py # Windows Win32 / ctypes implementation
βββ skill/
β βββ SKILL.md # Antigravity Skill specification
βββ voice/
β βββ README.md # Voice architecture & roadmap
βββ tests/
β βββ test_cursor.py # Cursor tracking tests
β βββ test_screen.py # Screen capture tests
β βββ test_window.py # Window detection tests
β βββ test_context.py # Context synchronization tests
β βββ test_server.py # End-to-end MCP tool tests
βββ docs/
β βββ architecture.md # Detailed architectural design
β βββ installation.md # Setup and integration guide
β βββ antigravity.md # Antigravity IDE & CLI configuration
β βββ privacy.md # Privacy policies & data handling
β βββ security.md # Security model & tool permissions
βββ examples/
β βββ client_example.py # Example MCP client script
βββ .env.example # Sample environment configuration
βββ .gitignore
βββ LICENSE # MIT License
βββ pyproject.toml
βββ requirements.txtπ οΈ Installation & Setup
Prerequisites
Python 3.10 or higher
Windows 10/11 (macOS / Linux support on roadmap)
1. Install Dependencies
cd screen-aware-mcp
pip install -r requirements.txt2. Configure Environment (Optional)
cp .env.example .env3. Run MCP Server
python -m server.serverπ§ͺ Running Tests
Run the full automated test suite:
pytest tests/ -vπΊοΈ Roadmap & Milestones
Milestone 1 β MCP Foundation: Read-only MCP tools (
capture_screen,get_cursor_position,get_active_window,capture_screen_context), DPI-aware Win32 integration, comprehensive test suite.Milestone 2 β Antigravity Skill: Integrate with Antigravity agent workflows for prompt-driven UI element identification.
Milestone 3 β Visual UI Targeting: Windows UI Automation (UIA) & accessibility tree integration.
Milestone 4 β Voice Input: Audio / microphone input bridge.
Milestone 5 β Controlled UI Interaction: Permission-controlled click, drag, scroll, keyboard input.
Milestone 6 β Screen Watching: Intelligent frame-diff change detection.
π License
This project is licensed under the MIT License.
This server cannot be deployed
Maintenance
Related MCP Connectors
Give AI coding agents access to your Vynix visual feedback, bug reports, and AI diagnosis.
Cross-device AI memory with encrypted activity capture and context handoff between AI tools
Local-first, governed memory and session continuity for AI coding agents. No cloud, no telemetry.
Eyes and hands on real Windows PCs β observe, click, type via Glasswarp API.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to capture and analyze screen content across multi-monitor setups with smart image optimization. Provides screenshot capabilities and detailed monitor information for visual debugging, UI analysis, and desktop assistance.-
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to capture screenshots and control desktop input (mouse, keyboard) to see and interact with your screen. Features user-first safety controls including automatic pause on user activity and app allowlists to restrict interactions to approved applications only.1MIT
- FlicenseNot gradedqualityCmaintenanceGives AI coding assistants live, structured access to running apps' state and UI elements, enabling real-time verification and interaction across web, mobile, and desktop.36-
- AlicenseNot gradedqualityDmaintenanceGives AI coding assistants real-time screen capture capabilities with multi-monitor support, PDF text extraction, and answer logging.MIT