Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

plasmate-a11y

Accessibility auditing powered by Plasmate's Semantic Object Model.

The insight: SOM is what screen readers always wanted — structured content with clear hierarchy and meaningful labels. By analyzing the SOM, we can instantly identify what a screen reader would "see" vs what's actually on the page.

Install

pip install plasmate plasmate-a11y

Quick Start

from plasmate_a11y import audit_url

result = audit_url("https://example.com")
print(f"Score: {result['summary']['score']}/100")
print(f"Errors: {result['summary']['errors']}")
print(f"Warnings: {result['summary']['warnings']}")

for issue in result['issues']:
    print(f"  [{issue['severity']}] {issue['message']}")

CLI

python -m plasmate_a11y https://example.com

Exit code is 1 if any errors are found — useful in CI pipelines.

What It Checks

Rule Severity Description
no-title Error Page missing title element
no-lang Error Page missing language attribute
heading-skip Warning Heading levels skip (e.g. h2 → h4)
no-h1 Error Page doesn't start with h1
img-no-alt Error Images without alt text
empty-link-text Error Links with no text
vague-link-text Warning Links with "click here" etc.
input-no-label Error Form inputs without labels
no-nav-landmark Warning Missing navigation region
no-main-landmark Warning Missing main content region

Programmatic Use

from plasmate_a11y import audit_url, audit_urls, format_report, format_markdown

# Single URL
result = audit_url("https://example.com")
print(format_report(result))          # terminal output with color
print(format_markdown(result))        # markdown table

# Multiple URLs
results = audit_urls(["https://a.com", "https://b.com"])
for r in results:
    print(format_report(r))

Why Plasmate for Accessibility?

Traditional accessibility auditors use Chrome + axe-core, which requires rendering the full page. Plasmate skips rendering and goes straight to semantic analysis:

  • 10× faster — no rendering overhead
  • Structured by default — SOM already represents what matters for a11y
  • Token-efficient — results are compact and machine-readable

Development

git clone https://github.com/plasmate-labs/plasmate-a11y.git
cd plasmate-a11y
pip install -e ".[dev]"
pytest

License

Apache 2.0 — see LICENSE.

Links


Part of the Plasmate Ecosystem

Engine plasmate - The browser engine for agents
MCP plasmate-mcp - Claude Code, Cursor, Windsurf
Extension plasmate-extension - Chrome cookie export
SDKs Python / Node.js / Go / Rust
Frameworks LangChain / CrewAI / AutoGen / Smolagents
Tools Scrapy / Audit / A11y / GitHub Action
Resources Awesome Plasmate / Notebooks / Benchmarks
Docs docs.plasmate.app
W3C Web Content Browser for AI Agents

About

Accessibility auditing via Plasmate's Semantic Object Model. 7 WCAG rules, CLI + Python API.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages