agentleFS
BuddhiliveBuddhilive/buddhi-cli/.agents/skills/a11y/SKILL.md

a11y

Skill1 starsChanged 15 days agoMITView on GitHub

Persistent Context System for Accessibility: 19-Rule AI Behavioral Contract, Compliance Profiles (Standard AA, Shield AAA, Launchpad A), WAI-ARIA APG component references, static verification gate, and release evidence.

11 other projects use a version of this.

Adopted by

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. 0 are common, 5 are distinctive, and 9 are very specific to this project.

  • 0

    Common

    Most of the 9 edited versions we read keep these.

  • 5

    Distinctive

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If a user cannot complete a task due to an accessibility barrier, the feature is considered technically broken.

    line 21
  2. Distinctive:

    Default profile: Standard (AA).

    line 26
  3. Distinctive:

    No Inference: Never infer accessibility without direct evidence in the code or specification.

    line 51
  4. Distinctive:

    Protocol for Ambiguity: Follow the Complex Component Protocol when a component lacks an established APG pattern.

    line 54
  5. Very specific:

    Conflicting Access Needs: When needs collide (e.g. motion vs vestibular), implement user preferences (prefers-reduced-motion) or document …

    line 62
  6. Very specific:

    Component Reuse: Check existing components via buddhi_search or project design systems before creating new ones.

    line 63
  7. Very specific:

    Release Evidence: Ensure REPORT.md exists and is newer than the last interface change before any delivery to an end user.

    line 66
  8. Very specific:

    Static Gate: Run buddhi scripts verify-a11y via terminal-runner (or MCP tool verify_a11y) before delivery and record findings in REPORT.md.

    line 67
  9. Very specific:

    ARIA Soup: No redundant roles (e.g. role="button" on <button>), no hardcoded static aria-expanded that script never toggles.

    line 131
  10. Very specific:

    Nullified Alt: Never combine aria-hidden="true" or role="presentation" with a non-empty alt.

    line 133
  11. Distinctive:

    Overlays: Never propose third-party accessibility toolbar scripts as a fix.

    line 134
  12. Very specific:

    Outline None: Never set outline: none without a visible high-contrast replacement.

    line 136
  13. Very specific:

    Redundant Alert: Never combine role="alert" with aria-live.

    line 137
  14. Very specific:

    Run static gate and contrast verification through terminal-runner or MCP tools:

    line 144

“Common” is measured: kept by at least 6 in 10 of the 9 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

a11y

Adapted from Project A11Y.md (MIT License, Copyright (c) 2026 Felipe A. Carriço). Version: 2.5.0 | Target Standard: WCAG 2.2 AA (Shield AAA, Launchpad A)

This skill establishes the persistent context required so that software can be certified under WCAG 2.2 AA, ISO 9241-171, ADA, EAA, and ABNT NBR 17225, depending on rigorous implementation and mandatory human validation.

Most agent context teaches a capability — how to do something, loaded when the task calls for it. This skill defines a constraint: what may never be done, whatever you are building. It belongs in context before generating any UI code.


0. Principle Zero: Accessibility as Pre-condition

  • Accessibility is not a feature or an incremental improvement; it is a pre-condition for use.
  • If a user cannot complete a task due to an accessibility barrier, the feature is considered technically broken.
  • Task Completion success is the primary quality metric.

0.1. Compliance Profiles

Default profile: Standard (AA). When generating or reviewing interface code, confirm the profile with the user if not specified:

ProfileTargetContrast (text / UI)Min Font†Min TargetUse Case
🛡️ Shield (AAA)WCAG AAA7:1 / 3:1 (SC 1.4.6, 1.4.11)14px†44×44px (SC 2.5.5) · 48×48px† advisedRegulated industries, healthcare, gov
⚖️ Standard (AA)WCAG AA4.5:1 / 3:1 (SC 1.4.3, 1.4.11)12px†24×24px (SC 2.5.8) · 44×44px† advisedDefault. Production apps, public web
🚀 Launchpad (A)WCAG A3:1† (house floor)10px†24×24px†MVPs, internal tools, prototypes

† = A11Y.md rule (ergonomic baseline beyond WCAG minimums). Skipping a WCAG SC at your target level MUST be logged in EXCEPTIONS.md; relaxing an A11Y.md rule is a product decision recorded in A11Y-DECISIONS.md.

⚠️ The Launchpad (A) profile does NOT relax CRITICAL rules. Keyboard operability, focus management, and semantic HTML remain mandatory at ALL levels.


1. Severity & Impact Model

  • 🔴 CRITICAL: Operation failures blocking task completion (broken keyboard nav, click on div/span, modal without focus management). MUST FIX.
  • 🟠 HIGH: Perception and readability failures (insufficient contrast, font < 12px in critical text, missing dynamic feedback). MUST FIX.
  • 🟡 MEDIUM: Reduces efficiency and satisfaction (missing keyboard shortcuts, lack of redundant labels). SHOULD FIX.
  • 🔵 LOW: Cosmetic or polish impact (micro-interactions without aria-labels, focus indicators needing contrast polish). MAY FIX.

2. 19-Rule AI Behavioral Contract

  1. No Inference: Never infer accessibility without direct evidence in the code or specification.
  2. Lazy Context Loading: Reference files in references/ MUST NOT be preloaded — consult only the row of each component the interface contains per §2.1.
  3. Reference APG: Prioritize patterns from the WAI-ARIA Authoring Practices Guide (APG).
  4. Protocol for Ambiguity: Follow the Complex Component Protocol when a component lacks an established APG pattern.
  5. Explain Trade-offs: Explicitly state impacts on Accessibility vs UX vs Business when proposing changes.
  6. UI Component Interrogation: Propose replacing click-handled non-semantic elements with native buttons or full APG patterns.
  7. Image Evidence: Resolve text alternatives with the developer before images enter code. Fabricating alt from filenames or defaulting to alt="" without confirmation is forbidden.
  8. Media Evidence: Resolve captions, transcripts, and audio control before media enters code. Autoplay without pause or volume controls is 🔴 CRITICAL.
  9. Framework Adaptation: Transpose patterns to the project's active framework (React, Vue, Svelte, HTML) while preserving semantic equivalence.
  10. Platform Awareness: Identify target platform before loading references (web ARIA intent translates to native accessibility APIs on iOS, Android, Flutter).
  11. Cognitive Load: Multi-step flows, auth, or time limits must enforce: nothing remembered across screens (SC 3.3.8), nothing re-typed (SC 3.3.7), consistent help location (SC 3.2.6). Never block paste on password fields.
  12. Conflicting Access Needs: When needs collide (e.g. motion vs vestibular), implement user preferences (prefers-reduced-motion) or document trade-offs in A11Y-DECISIONS.md.
  13. Component Reuse: Check existing components via buddhi_search or project design systems before creating new ones.
  14. Decision Memory: Record choices between equally conformant alternatives in A11Y-DECISIONS.md indexed by pattern.
  15. Exception Memory: Record knowingly accepted WCAG deviations in EXCEPTIONS.md with owner, approver, issue link, and expiry.
  16. Release Evidence: Ensure REPORT.md exists and is newer than the last interface change before any delivery to an end user.
  17. Static Gate: Run buddhi scripts verify-a11y via terminal-runner (or MCP tool verify_a11y) before delivery and record findings in REPORT.md.
  18. Independent Verification: Reproduce Section 7 automated checkpoints with a verifier that did not generate the code (dispatch an unprimed subagent via invoke_subagent to achieve fresh-context verification).
  19. Mode Awareness: Apply rules proactively when generating new code; prioritize targeted fixes by severity when reviewing existing code.

2.1. Lazy Loading Map (Component → Guide)

Load only the guide matching the component you are currently building or reviewing:

Component TypeReference Guide
button, CTA, clickable action, icon buttonreferences/guide-buttons.md
form, field, validation, error messagereferences/guide-forms.md
checkbox, radio group, switch, toggle, slider, selectreferences/guide-form-controls.md
login, signup, multi-step flow, wizard, checkoutreferences/guide-cognitive.md
modal, dialog, drawer, confirmationreferences/guide-modals.md
cookie banner, consent notice, privacy overlayreferences/guide-consent-banners.md
menu, header, skip link, landmark, SPA routingreferences/guide-navigation.md
table, data gridreferences/guide-tables.md
tabs, accordion, disclosure, collapsible panelreferences/guide-tabs-accordion.md
tooltip, popover, hover cardreferences/guide-tooltips-popovers.md
toast, snackbar, alert, status messagereferences/guide-toasts-notifications.md
skeleton, spinner, loading state, aria-busyreferences/guide-loading-skeleton.md
autocomplete, combobox, searchable selectreferences/guide-autocomplete.md
carousel, slider, rotating bannerreferences/guide-carousels-sliders.md
drag and drop, list reordering, kanbanreferences/guide-drag-drop.md
infinite scroll, feed, paginationreferences/guide-infinite-scroll.md
image, icon, SVG, avatar, illustrationreferences/guide-images.md
video, audio, player, background videoreferences/guide-media.md
chart, graph, dashboard, data visualizationreferences/guide-charts.md
date picker, calendar, date rangereferences/guide-datepicker.md
tree view, file explorer, nested pickerreferences/guide-treeview.md
chat, streaming AI assistant, generative UIreferences/guide-generative-ui.md
map, store locator, route displayreferences/guide-maps.md
design tokens, color palette, theme configreferences/guide-visual-perception.md
responsive layout, breakpoint, touch targetreferences/guide-responsive-mobile.md
iOS, Android, React Native, Flutterreferences/guide-platform-native.md
non-React web frameworks (Vue, Svelte, Angular)references/guide-framework-mapping.md
AI agents navigating product, llms.txtreferences/guide-agentic-web.md
audit, VPAT, accessibility statement, CI gatereferences/guide-governance.md

Lifecycle Templates (Loaded by Event):

  • Delivery / QA: templates/REPORT.md
  • Accepted WCAG deviation: templates/EXCEPTIONS.md
  • Pattern choice: templates/A11Y-DECISIONS.md
  • Public statement (GitHub Accessibility tab): templates/ACCESSIBILITY.md

3. Technical Standards (POUR Summary)

  • Perceivable: Text contrast >= 4.5:1 (3:1 large, 3:1 UI components). Compute with buddhi scripts contrast or MCP check_contrast. Every <img> has alt (empty alt="" only for confirmed decorative images). Prerecorded media has captions. Sound > 3s has pause/mute controls.
  • Operable: 100% keyboard operable (Tab, Enter, Space, Escape). Focus indicator visible (>= 2px, 3:1 contrast against background). Touch target >= 24x24px (AA), 44x44px recommended. Moving content > 5s has pause mechanism. Flashing <= 3 times/sec.
  • Understandable: Language declared on <html lang="...">. Inputs have explicit <label for="...">. Error feedback uses Color + Icon + Text with aria-live or role alerts.
  • Robust: Valid semantic HTML5 elements before custom ARIA.

4. Anti-patterns to Prevent (Section 6)

  1. Clickable Divs: No div or span with click handlers without native <button> or complete keyboard replication (role, tabindex="0", Enter/Space).
  2. Leaked Focus Traps: Modals must trap focus, close on Escape, and restore focus to trigger.
  3. Placeholder as Only Label: <input> must have a visible <label>.
  4. ARIA Soup: No redundant roles (e.g. role="button" on <button>), no hardcoded static aria-expanded that script never toggles.
  5. Half-Climbed ARIA: role="tablist" without role="tab" is strictly forbidden.
  6. Nullified Alt: Never combine aria-hidden="true" or role="presentation" with a non-empty alt.
  7. Overlays: Never propose third-party accessibility toolbar scripts as a fix.
  8. Positive Tabindex: tabindex > 0 is forbidden.
  9. Outline None: Never set outline: none without a visible high-contrast replacement.
  10. Redundant Alert: Never combine role="alert" with aria-live.
  11. Media Autoplay: Unmuted autoplaying audio/video is forbidden.

5. Verification Commands

Run static gate and contrast verification through terminal-runner or MCP tools:

# Static gate check against project source and artifacts
buddhi scripts verify-a11y [project_dir] [--src subdir] [--warn-only]

# Contrast verification
buddhi scripts contrast <hex1> <hex2>
buddhi scripts contrast --bg "#ffffff" --fg "#1c1b19" "#767676" --profile standard
buddhi scripts contrast --css styles.css --page-bg "#ffffff"

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.