Skip to content

MCP server that watches web animations like a human tester - detects jank, stuttering, visual artifacts using AI vision

License

Notifications You must be signed in to change notification settings

rishitank/animawatch

Repository files navigation

🎬 AnimaWatch

MCP server that watches web animations like a human tester β€” detects jank, stuttering, visual artifacts using AI vision.

Built with FastMCP leveraging the latest MCP spec (2025-11-25) features.

✨ What It Does

YOU: "Watch the modal animation on this page"
     ↓
ANIMAWATCH:
  1. Records browser interaction as video (Playwright)
  2. Sends video to Vision AI (Gemini FREE or Ollama local)
  3. AI watches the recording like a human would
     ↓
RESULT: "Jank detected at 1.2s - fade-in stutters for 180ms"

πŸš€ Features

Feature Description
πŸŽ₯ Video Recording Records browser interactions using Playwright
πŸ‘οΈ AI Vision Analysis Uses Gemini 2.0 Flash (FREE) or Ollama (local)
πŸ” Animation Diagnosis Detects jank, stuttering, timing issues, visual artifacts
πŸ“Έ Screenshot Analysis Fast static analysis for non-animated issues
β™Ώ Accessibility Checks Visual accessibility analysis (contrast, readability)
πŸ’Ύ Resources Access recordings and analyses via MCP resources
πŸ“ Prompts Pre-defined prompt templates for different analysis types
πŸ†“ 100% FREE Uses Gemini's free tier or runs locally with Ollama

πŸ› οΈ MCP Capabilities

Tools

Tool Description
watch 🎬 Record and analyze animations (main tool)
screenshot πŸ“Έ Fast static page analysis with image return
analyze_video πŸŽ₯ Analyze an existing video file
record ⏺️ Just record without analysis
check_accessibility β™Ώ Visual accessibility analysis

Resources

URI Description
animawatch://recordings/{id} Access stored video recordings
animawatch://analyses/{id} Access stored analysis results
animawatch://config Current server configuration

Prompts

Prompt Description
animation_diagnosis Comprehensive animation analysis template
page_analysis Static page visual analysis template
accessibility_check Accessibility-focused analysis template

πŸš€ Quick Start

1. Install

cd ~/github/animawatch
uv sync
uv run playwright install chromium

2. Get FREE Gemini API Key

  1. Go to Google AI Studio
  2. Click "Get API Key" β†’ Create API key
  3. Copy your key

3. Configure

cp .env.example .env
# Edit .env and add your GEMINI_API_KEY

4. Add to Your MCP Client

Claude Desktop (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "animawatch": {
      "command": "uv",
      "args": ["--directory", "/Users/YOUR_USER/github/animawatch", "run", "animawatch"],
      "env": {
        "GEMINI_API_KEY": "your-api-key-here"
      }
    }
  }
}

Augment Code (settings):

{
  "mcpServers": {
    "animawatch": {
      "command": "uv",
      "args": ["--directory", "/Users/YOUR_USER/github/animawatch", "run", "animawatch"],
      "env": {
        "GEMINI_API_KEY": "your-api-key-here"
      }
    }
  }
}

πŸ“– Usage Examples

Watch Animation Issues

"Watch the modal animation on https://example.com for any jank"

Perform Actions Then Watch

"Click the hamburger menu on https://example.com and watch the slide-in animation"

Focus on Specific Area

"Watch https://example.com with focus on scroll behavior"

Accessibility Check

"Check accessibility on https://example.com"

Access Previous Results

"Show me the analysis from animawatch://analyses/abc123"

πŸ”§ Configuration

Environment Variable Default Description
GEMINI_API_KEY - Google Gemini API key (FREE)
VISION_PROVIDER gemini gemini or ollama
VISION_MODEL gemini-2.0-flash Vision model to use
BROWSER_HEADLESS true Run browser headless
VIDEO_WIDTH 1280 Recording width
VIDEO_HEIGHT 720 Recording height
MAX_RECORDING_DURATION 30 Max recording seconds

🏠 100% Local with Ollama

To run entirely locally (no API calls):

# Install Ollama
brew install ollama
ollama serve

# Pull a vision model
ollama pull qwen2.5-vl:7b

# Configure
export VISION_PROVIDER=ollama
export OLLAMA_MODEL=qwen2.5-vl:7b

Note: Ollama doesn't support direct video analysis, so it will analyze screenshots/frames instead.

πŸ’° Cost

Provider Cost
Gemini (AI Studio) FREE (15 req/min, 1M tokens/day)
Ollama FREE (runs locally)

πŸ—οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                       AnimaWatch                            β”‚
β”‚                    (FastMCP Server)                         β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚  Lifespan Context (AppContext)                              β”‚
β”‚  β”œβ”€β”€ BrowserRecorder (Playwright)                           β”‚
β”‚  β”œβ”€β”€ VisionProvider (Gemini/Ollama)                         β”‚
β”‚  β”œβ”€β”€ recordings: dict[id, Path]                             β”‚
β”‚  └── analyses: dict[id, str]                                β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚  Tools       β”‚  Resources              β”‚  Prompts           β”‚
β”‚  ─────────   β”‚  ─────────────────────  β”‚  ──────────────    β”‚
β”‚  watch       β”‚  animawatch://recordingsβ”‚  animation_diagnosisβ”‚
β”‚  screenshot  β”‚  animawatch://analyses  β”‚  page_analysis     β”‚
β”‚  record      β”‚  animawatch://config    β”‚  accessibility_checkβ”‚
β”‚  analyze_videoβ”‚                        β”‚                    β”‚
β”‚  check_accessβ”‚                         β”‚                    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸ“„ License

MIT

About

MCP server that watches web animations like a human tester - detects jank, stuttering, visual artifacts using AI vision

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages