The Product Failure of Static Code Scanners
Traditional web accessibility (WCAG) tools are fundamentally broken for non-technical small business owners. Standard rule-based checkers function merely as noisy scanners. They dump a massive list of unverified violations onto a user, fail to evaluate whether an image's alt-text is actually contextually descriptive, and provide zero contextual validation. This leaves small businesses highly vulnerable to predatory ADA lawsuits because a raw, unverified report does not resolve the underlying code vulnerability.
To bridge this gap, I took a prototype I built for the Google All Things Agentic Hackathon and engineered it into a fully production-ready, open-source public utility: MAD Platform (Multi-Agent Defense), hosted live at mad-platform.org.
Instead of generating a static report, it deploys a deterministic, self-correcting multi-agent orchestration pattern that crawls, visualizes, verifies via RAG, and outputs production-ready fixes. Here is the technical architecture behind how I built it.
The Core Architecture: Analyst vs. Editor Verification Loop
In a high-stakes regulatory compliance environment, relying on a single LLM call is a product non-starter. Models hallucinate, leading to false negatives that leave businesses legally exposed, or false positives that waste developer time. To achieve production-grade accuracy, MAD Platform splits cognitive labor into specialized agents that cross-examine each other's execution paths.
[Web Crawler / Playwright]
│
▼
┌─────────────────────────────────┐
│ 1. ANALYST AGENT │ ◄── Discovers violations via parallel visual & code checks
└────────────────┬────────────────┘
│ (Flags Finding)
▼
┌─────────────────────────────────┐
│ 2. EDITOR AGENT & RAG │ ◄── Cross-checks findings against live screenshot & official WCAG
└────────────────┬────────────────┘
│
┌───────┴───────┐
▼ ▼
[Dismissed] [Confirmed] ──► [Reporter Agent] ──► Jira CSV / HTML
1. The Analyst Agent (Multi-Modal Discovery)
The pipeline begins using Playwright for headless rendering, screenshot capture, and computed-style extraction. The Analyst Agent (powered by gemini-3.5-flash-lite for high-volume cost efficiency) runs three parallel checks per page:
- Deterministic: Traditional code-rule parsing (e.g., raw contrast ratios, missing form labels).
- Semantic: Evaluating structural layout hierarchy and ARIA roles.
- Multimodal Visual: Reasoning over the actual rendered screenshot to detect elements hidden by bad styling.
2. The Editor Agent & WCAG RAG (The Quality Gate)
Any violation flagged by the Analyst is treated as unverified. It is passed to the Editor Agent (utilizing gemini-3.7-flash for high-judgment reasoning).
To completely bypass the "hallucination barrier," the system does not rely on fragile LLM memory. Instead, I engineered a highly precise Retrieval-Augmented Generation (RAG) architecture. The system queries a localized, curated vector knowledge base (gemini-embedding-001) containing the exact, unadulterated Web Content Accessibility Guidelines (WCAG) success criteria. This strict regulatory text is injected directly into the prompt context.
The Editor independently cross-examines the Analyst’s finding against the raw visual screenshot using the absolute ground truth of the retrieved WCAG standards. If the evidence matches the strict statutory text, the finding is confirmed; if it doesn't, it is dismissed with an audited, documented reason.
3. Closed-Loop Product Improvement (Persistent Memory)
To ensure the platform scales without manual code changes, a weekly background Cloud Run Job (pattern-miner) runs a batch task. It analyzes human dismissal logs from edge-case escalations, identifies recurring false-alarm patterns, and codifies them into permanent system grounding. The product literally self-heals its own knowledge base over time.
Infrastructure Optimization: Scale-to-Zero Sustainability
To keep this utility permanently free for small businesses, I engineered the entire tech stack on a serverless, scale-to-zero model using Google Cloud Run and Firestore to reduce operational costs to nearly zero. I am funding the base infrastructure entirely out of my own pocket.
Because public utilities require total transparency, the code is 100% open-source under an AGPL-3.0 license. Note that we require a verified email address strictly at the moment of scan submission as an anti-abuse measure to protect our API thresholds from bot exploitation—no account registration or signup required.
- Live Tool: mad-platform.org
- Open Source Code: Github
As AI transitions from simple chat interfaces to autonomous workflows, the biggest hurdle isn't the underlying model—it's the system architecture and verification loops we build around them. How are you handling error-correction loops in your own autonomous LLM workflows? Let's discuss below.
Top comments (1)
Hey everyone, built this to solve a real-world accessibility compliance headache using the new Gemini stack.
Let me know if you run a scan and what edge cases your sites turn up!