@mcptoolshop/accessibility-suite 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (241) hide show
  1. package/.github/workflows/ci.yml +63 -0
  2. package/LICENSE +21 -0
  3. package/README.md +37 -0
  4. package/docs/prov-spec/.github/workflows/ci.yml +68 -0
  5. package/docs/prov-spec/CHANGELOG.md +69 -0
  6. package/docs/prov-spec/CODE_OF_CONDUCT.md +129 -0
  7. package/docs/prov-spec/CONFORMANCE_LEVELS.md +223 -0
  8. package/docs/prov-spec/CONTRIBUTING.md +145 -0
  9. package/docs/prov-spec/IMPLEMENTER_CHECKLIST.md +137 -0
  10. package/docs/prov-spec/LICENSE +21 -0
  11. package/docs/prov-spec/PRESS_RELEASE.md +74 -0
  12. package/docs/prov-spec/README.md +182 -0
  13. package/docs/prov-spec/SETUP.md +135 -0
  14. package/docs/prov-spec/WHY.md +86 -0
  15. package/docs/prov-spec/examples/artifact.example.json +14 -0
  16. package/docs/prov-spec/examples/artifact.ref.example.json +9 -0
  17. package/docs/prov-spec/examples/evidence.example.json +6 -0
  18. package/docs/prov-spec/examples/mcp.envelope.example.json +97 -0
  19. package/docs/prov-spec/examples/mcp.request.example.json +28 -0
  20. package/docs/prov-spec/examples/prov.record.example.json +35 -0
  21. package/docs/prov-spec/interop/PROOF_NODE_ENGINE.md +114 -0
  22. package/docs/prov-spec/spec/MCP_COMPATIBILITY.md +241 -0
  23. package/docs/prov-spec/spec/PROV_METHODS_CATALOG.md +142 -0
  24. package/docs/prov-spec/spec/PROV_METHODS_SPEC.md +397 -0
  25. package/docs/prov-spec/spec/methods.json +213 -0
  26. package/docs/prov-spec/spec/schemas/artifact.ref.schema.v0.1.json +58 -0
  27. package/docs/prov-spec/spec/schemas/artifact.schema.v0.1.json +61 -0
  28. package/docs/prov-spec/spec/schemas/assist.request.schema.v0.1.json +52 -0
  29. package/docs/prov-spec/spec/schemas/assist.response.schema.v0.1.json +70 -0
  30. package/docs/prov-spec/spec/schemas/cli.error.schema.v0.1.json +78 -0
  31. package/docs/prov-spec/spec/schemas/evidence.schema.v0.1.json +37 -0
  32. package/docs/prov-spec/spec/schemas/mcp.envelope.schema.v0.1.json +141 -0
  33. package/docs/prov-spec/spec/schemas/mcp.request.schema.v0.1.json +79 -0
  34. package/docs/prov-spec/spec/schemas/methods.schema.json +93 -0
  35. package/docs/prov-spec/spec/schemas/prov-capabilities.schema.json +122 -0
  36. package/docs/prov-spec/spec/schemas/prov.record.schema.v0.1.json +133 -0
  37. package/docs/prov-spec/spec/vectors/adapter.wrap.envelope_v0_1/expected.json +4 -0
  38. package/docs/prov-spec/spec/vectors/adapter.wrap.envelope_v0_1/input.json +1 -0
  39. package/docs/prov-spec/spec/vectors/adapter.wrap.envelope_v0_1/negative/double_wrapped.json +14 -0
  40. package/docs/prov-spec/spec/vectors/adapter.wrap.envelope_v0_1/negative/wrong_schema_version.json +11 -0
  41. package/docs/prov-spec/spec/vectors/engine.extract.evidence.json_pointer/expected.json +24 -0
  42. package/docs/prov-spec/spec/vectors/engine.extract.evidence.json_pointer/input.json +8 -0
  43. package/docs/prov-spec/spec/vectors/integrity.digest.sha256/expected.json +7 -0
  44. package/docs/prov-spec/spec/vectors/integrity.digest.sha256/input.json +1 -0
  45. package/docs/prov-spec/spec/vectors/integrity.digest.sha256/negative/non_hex_chars.json +16 -0
  46. package/docs/prov-spec/spec/vectors/integrity.digest.sha256/negative/uppercase_hex.json +16 -0
  47. package/docs/prov-spec/spec/vectors/integrity.digest.sha256/negative/wrong_length.json +16 -0
  48. package/docs/prov-spec/spec/vectors/method_id_syntax/negative/hyphen_separator.json +8 -0
  49. package/docs/prov-spec/spec/vectors/method_id_syntax/negative/reserved_namespace.json +8 -0
  50. package/docs/prov-spec/spec/vectors/method_id_syntax/negative/starts_with_digit.json +8 -0
  51. package/docs/prov-spec/spec/vectors/method_id_syntax/negative/uppercase.json +8 -0
  52. package/docs/prov-spec/spec/vectors/method_id_syntax/positive/valid_ids.json +18 -0
  53. package/docs/prov-spec/tools/python/prov_validator.py +428 -0
  54. package/examples/a11y-demo-site/.github/workflows/a11y-artifacts.yml +81 -0
  55. package/examples/a11y-demo-site/.github/workflows/a11y.yml +34 -0
  56. package/examples/a11y-demo-site/CODE_OF_CONDUCT.md +129 -0
  57. package/examples/a11y-demo-site/CONTRIBUTING.md +83 -0
  58. package/examples/a11y-demo-site/LICENSE +21 -0
  59. package/examples/a11y-demo-site/README.md +155 -0
  60. package/examples/a11y-demo-site/html/contact.html +15 -0
  61. package/examples/a11y-demo-site/html/index.html +20 -0
  62. package/examples/a11y-demo-site/scripts/a11y.sh +20 -0
  63. package/package.json +26 -0
  64. package/src/a11y-assist/.github/workflows/publish.yml +52 -0
  65. package/src/a11y-assist/.github/workflows/test.yml +30 -0
  66. package/src/a11y-assist/A11Y_ASSIST_TEST_COVERAGE_REQUIREMENTS.md +104 -0
  67. package/src/a11y-assist/CODE_OF_CONDUCT.md +129 -0
  68. package/src/a11y-assist/CONTRIBUTING.md +98 -0
  69. package/src/a11y-assist/ENGINE.md +363 -0
  70. package/src/a11y-assist/LICENSE +21 -0
  71. package/src/a11y-assist/PRESS_RELEASE.md +71 -0
  72. package/src/a11y-assist/QUICKSTART.md +101 -0
  73. package/src/a11y-assist/README.md +192 -0
  74. package/src/a11y-assist/RELEASE_NOTES.md +319 -0
  75. package/src/a11y-assist/a11y_assist/__init__.py +3 -0
  76. package/src/a11y-assist/a11y_assist/cli.py +599 -0
  77. package/src/a11y-assist/a11y_assist/from_cli_error.py +149 -0
  78. package/src/a11y-assist/a11y_assist/guard.py +444 -0
  79. package/src/a11y-assist/a11y_assist/ingest.py +407 -0
  80. package/src/a11y-assist/a11y_assist/methods.py +137 -0
  81. package/src/a11y-assist/a11y_assist/parse_raw.py +71 -0
  82. package/src/a11y-assist/a11y_assist/profiles/__init__.py +29 -0
  83. package/src/a11y-assist/a11y_assist/profiles/cognitive_load.py +245 -0
  84. package/src/a11y-assist/a11y_assist/profiles/cognitive_load_render.py +86 -0
  85. package/src/a11y-assist/a11y_assist/profiles/dyslexia.py +144 -0
  86. package/src/a11y-assist/a11y_assist/profiles/dyslexia_render.py +77 -0
  87. package/src/a11y-assist/a11y_assist/profiles/plain_language.py +119 -0
  88. package/src/a11y-assist/a11y_assist/profiles/plain_language_render.py +66 -0
  89. package/src/a11y-assist/a11y_assist/profiles/screen_reader.py +348 -0
  90. package/src/a11y-assist/a11y_assist/profiles/screen_reader_render.py +89 -0
  91. package/src/a11y-assist/a11y_assist/render.py +95 -0
  92. package/src/a11y-assist/a11y_assist/schemas/assist.request.schema.v0.1.json +52 -0
  93. package/src/a11y-assist/a11y_assist/schemas/assist.response.schema.v0.1.json +70 -0
  94. package/src/a11y-assist/a11y_assist/schemas/cli.error.schema.v0.1.json +78 -0
  95. package/src/a11y-assist/a11y_assist/storage.py +31 -0
  96. package/src/a11y-assist/pyproject.toml +60 -0
  97. package/src/a11y-assist/tests/__init__.py +1 -0
  98. package/src/a11y-assist/tests/fixtures/base_inputs/cli_error_high.json +18 -0
  99. package/src/a11y-assist/tests/fixtures/base_inputs/cli_error_medium.json +16 -0
  100. package/src/a11y-assist/tests/fixtures/base_inputs/raw_text_low.txt +3 -0
  101. package/src/a11y-assist/tests/fixtures/cli_error_good.json +9 -0
  102. package/src/a11y-assist/tests/fixtures/cli_error_missing_id.json +7 -0
  103. package/src/a11y-assist/tests/fixtures/cli_error_string_format.json +7 -0
  104. package/src/a11y-assist/tests/fixtures/expected/cognitive_load_high.txt +20 -0
  105. package/src/a11y-assist/tests/fixtures/expected/dyslexia_high.txt +20 -0
  106. package/src/a11y-assist/tests/fixtures/expected/lowvision_high.txt +18 -0
  107. package/src/a11y-assist/tests/fixtures/expected/plain_language_high.txt +14 -0
  108. package/src/a11y-assist/tests/fixtures/expected/screen_reader_high.txt +19 -0
  109. package/src/a11y-assist/tests/fixtures/golden_screen_reader_cli_error.txt +16 -0
  110. package/src/a11y-assist/tests/fixtures/golden_screen_reader_raw_no_id.txt +14 -0
  111. package/src/a11y-assist/tests/fixtures/golden_screen_reader_raw_with_id.txt +14 -0
  112. package/src/a11y-assist/tests/fixtures/raw_good.txt +11 -0
  113. package/src/a11y-assist/tests/fixtures/raw_no_id.txt +2 -0
  114. package/src/a11y-assist/tests/test_cognitive_load.py +469 -0
  115. package/src/a11y-assist/tests/test_dyslexia.py +337 -0
  116. package/src/a11y-assist/tests/test_explain.py +74 -0
  117. package/src/a11y-assist/tests/test_golden.py +127 -0
  118. package/src/a11y-assist/tests/test_guard.py +819 -0
  119. package/src/a11y-assist/tests/test_guard_integration.py +457 -0
  120. package/src/a11y-assist/tests/test_ingest.py +311 -0
  121. package/src/a11y-assist/tests/test_methods_metadata.py +236 -0
  122. package/src/a11y-assist/tests/test_plain_language.py +348 -0
  123. package/src/a11y-assist/tests/test_render.py +117 -0
  124. package/src/a11y-assist/tests/test_screen_reader.py +703 -0
  125. package/src/a11y-assist/tests/test_storage_last.py +61 -0
  126. package/src/a11y-assist/tests/test_triage.py +86 -0
  127. package/src/a11y-ci/.github/workflows/ci.yml +43 -0
  128. package/src/a11y-ci/.github/workflows/test.yml +30 -0
  129. package/src/a11y-ci/A11Y_CI_TEST_COVERAGE_REQUIREMENTS.md +94 -0
  130. package/src/a11y-ci/CODE_OF_CONDUCT.md +129 -0
  131. package/src/a11y-ci/CONTRIBUTING.md +142 -0
  132. package/src/a11y-ci/LICENSE +21 -0
  133. package/src/a11y-ci/README.md +105 -0
  134. package/src/a11y-ci/a11y_ci/__init__.py +3 -0
  135. package/src/a11y-ci/a11y_ci/allowlist.py +83 -0
  136. package/src/a11y-ci/a11y_ci/cli.py +145 -0
  137. package/src/a11y-ci/a11y_ci/gate.py +131 -0
  138. package/src/a11y-ci/a11y_ci/render.py +48 -0
  139. package/src/a11y-ci/a11y_ci/schemas/allowlist.schema.json +24 -0
  140. package/src/a11y-ci/a11y_ci/scorecard.py +99 -0
  141. package/src/a11y-ci/npm/package.json +35 -0
  142. package/src/a11y-ci/pyproject.toml +64 -0
  143. package/src/a11y-ci/tests/__init__.py +1 -0
  144. package/src/a11y-ci/tests/fixtures/allowlist_expired.json +10 -0
  145. package/src/a11y-ci/tests/fixtures/allowlist_ok.json +10 -0
  146. package/src/a11y-ci/tests/fixtures/baseline_ok.json +7 -0
  147. package/src/a11y-ci/tests/fixtures/current_fail.json +6 -0
  148. package/src/a11y-ci/tests/fixtures/current_ok.json +6 -0
  149. package/src/a11y-ci/tests/fixtures/current_regresses.json +7 -0
  150. package/src/a11y-ci/tests/test_gate.py +134 -0
  151. package/src/a11y-evidence-engine/.github/workflows/ci.yml +53 -0
  152. package/src/a11y-evidence-engine/CODE_OF_CONDUCT.md +129 -0
  153. package/src/a11y-evidence-engine/CONTRIBUTING.md +128 -0
  154. package/src/a11y-evidence-engine/LICENSE +21 -0
  155. package/src/a11y-evidence-engine/README.md +71 -0
  156. package/src/a11y-evidence-engine/bin/a11y-engine.js +11 -0
  157. package/src/a11y-evidence-engine/fixtures/bad/button-no-name.html +30 -0
  158. package/src/a11y-evidence-engine/fixtures/bad/img-missing-alt.html +19 -0
  159. package/src/a11y-evidence-engine/fixtures/bad/input-missing-label.html +26 -0
  160. package/src/a11y-evidence-engine/fixtures/bad/missing-lang.html +11 -0
  161. package/src/a11y-evidence-engine/fixtures/good/index.html +29 -0
  162. package/src/a11y-evidence-engine/package-lock.json +109 -0
  163. package/src/a11y-evidence-engine/package.json +45 -0
  164. package/src/a11y-evidence-engine/src/cli.js +74 -0
  165. package/src/a11y-evidence-engine/src/evidence/canonicalize.js +52 -0
  166. package/src/a11y-evidence-engine/src/evidence/json_pointer.js +34 -0
  167. package/src/a11y-evidence-engine/src/evidence/prov_emit.js +153 -0
  168. package/src/a11y-evidence-engine/src/fswalk.js +56 -0
  169. package/src/a11y-evidence-engine/src/html_parse.js +117 -0
  170. package/src/a11y-evidence-engine/src/ids.js +53 -0
  171. package/src/a11y-evidence-engine/src/rules/document_missing_lang.js +50 -0
  172. package/src/a11y-evidence-engine/src/rules/form_control_missing_label.js +105 -0
  173. package/src/a11y-evidence-engine/src/rules/img_missing_alt.js +77 -0
  174. package/src/a11y-evidence-engine/src/rules/index.js +37 -0
  175. package/src/a11y-evidence-engine/src/rules/interactive_missing_name.js +129 -0
  176. package/src/a11y-evidence-engine/src/scan.js +128 -0
  177. package/src/a11y-evidence-engine/test/scan.test.js +149 -0
  178. package/src/a11y-evidence-engine/test/vectors.test.js +200 -0
  179. package/src/a11y-lint/.github/workflows/ci.yml +46 -0
  180. package/src/a11y-lint/.github/workflows/test.yml +34 -0
  181. package/src/a11y-lint/CODE_OF_CONDUCT.md +129 -0
  182. package/src/a11y-lint/CONTRIBUTING.md +70 -0
  183. package/src/a11y-lint/GOVERNANCE.md +57 -0
  184. package/src/a11y-lint/LICENSE +21 -0
  185. package/src/a11y-lint/PRESS_RELEASE.md +50 -0
  186. package/src/a11y-lint/README.md +276 -0
  187. package/src/a11y-lint/RELEASE_NOTES.md +57 -0
  188. package/src/a11y-lint/RELEASING.md +57 -0
  189. package/src/a11y-lint/a11y_lint/__init__.py +64 -0
  190. package/src/a11y-lint/a11y_lint/cli.py +319 -0
  191. package/src/a11y-lint/a11y_lint/errors.py +252 -0
  192. package/src/a11y-lint/a11y_lint/render.py +293 -0
  193. package/src/a11y-lint/a11y_lint/report_md.py +289 -0
  194. package/src/a11y-lint/a11y_lint/scan_cli_text.py +434 -0
  195. package/src/a11y-lint/a11y_lint/schemas/cli.error.schema.v0.1.json +83 -0
  196. package/src/a11y-lint/a11y_lint/scorecard.py +244 -0
  197. package/src/a11y-lint/a11y_lint/validate.py +225 -0
  198. package/src/a11y-lint/pyproject.toml +75 -0
  199. package/src/a11y-lint/tests/__init__.py +1 -0
  200. package/src/a11y-lint/tests/test_cli.py +200 -0
  201. package/src/a11y-lint/tests/test_errors.py +188 -0
  202. package/src/a11y-lint/tests/test_render.py +202 -0
  203. package/src/a11y-lint/tests/test_report_md.py +188 -0
  204. package/src/a11y-lint/tests/test_scan_cli_text.py +290 -0
  205. package/src/a11y-lint/tests/test_scorecard.py +195 -0
  206. package/src/a11y-lint/tests/test_validate.py +257 -0
  207. package/src/a11y-mcp-tools/.github/workflows/ci.yml +53 -0
  208. package/src/a11y-mcp-tools/CODE_OF_CONDUCT.md +129 -0
  209. package/src/a11y-mcp-tools/CONTRIBUTING.md +136 -0
  210. package/src/a11y-mcp-tools/LICENSE +21 -0
  211. package/src/a11y-mcp-tools/PROV_METHODS_CATALOG.md +104 -0
  212. package/src/a11y-mcp-tools/README.md +168 -0
  213. package/src/a11y-mcp-tools/bin/cli.js +452 -0
  214. package/src/a11y-mcp-tools/bin/server.js +244 -0
  215. package/src/a11y-mcp-tools/fixtures/requests/a11y.diagnose.ok.json +27 -0
  216. package/src/a11y-mcp-tools/fixtures/requests/a11y.evidence.ok.json +25 -0
  217. package/src/a11y-mcp-tools/fixtures/responses/a11y.diagnose.ok.json +139 -0
  218. package/src/a11y-mcp-tools/fixtures/responses/a11y.diagnose.provenance_fail.json +13 -0
  219. package/src/a11y-mcp-tools/fixtures/responses/a11y.evidence.ok.json +88 -0
  220. package/src/a11y-mcp-tools/package-lock.json +189 -0
  221. package/src/a11y-mcp-tools/package.json +49 -0
  222. package/src/a11y-mcp-tools/src/envelope.js +197 -0
  223. package/src/a11y-mcp-tools/src/index.js +9 -0
  224. package/src/a11y-mcp-tools/src/schemas/artifact.js +85 -0
  225. package/src/a11y-mcp-tools/src/schemas/diagnosis.schema.v0.1.json +137 -0
  226. package/src/a11y-mcp-tools/src/schemas/envelope.schema.v0.1.json +108 -0
  227. package/src/a11y-mcp-tools/src/schemas/evidence.bundle.schema.v0.1.json +129 -0
  228. package/src/a11y-mcp-tools/src/schemas/evidence.js +97 -0
  229. package/src/a11y-mcp-tools/src/schemas/index.js +11 -0
  230. package/src/a11y-mcp-tools/src/schemas/provenance.js +140 -0
  231. package/src/a11y-mcp-tools/src/schemas/tools/a11y.diagnose.request.schema.v0.1.json +77 -0
  232. package/src/a11y-mcp-tools/src/schemas/tools/a11y.diagnose.response.schema.v0.1.json +50 -0
  233. package/src/a11y-mcp-tools/src/schemas/tools/a11y.evidence.request.schema.v0.1.json +120 -0
  234. package/src/a11y-mcp-tools/src/schemas/tools/a11y.evidence.response.schema.v0.1.json +50 -0
  235. package/src/a11y-mcp-tools/src/tools/diagnose.js +597 -0
  236. package/src/a11y-mcp-tools/src/tools/evidence.js +481 -0
  237. package/src/a11y-mcp-tools/src/tools/index.js +10 -0
  238. package/src/a11y-mcp-tools/test/contract.test.mjs +154 -0
  239. package/src/a11y-mcp-tools/test/diagnose.test.js +485 -0
  240. package/src/a11y-mcp-tools/test/evidence.test.js +183 -0
  241. package/src/a11y-mcp-tools/test/schema.test.js +327 -0
@@ -0,0 +1,101 @@
1
+ # Quickstart (60 seconds): a11y-evidence-engine + a11y-assist
2
+
3
+ This flow gives you:
4
+ 1. **Deterministic accessibility findings**
5
+ 2. **Verifiable provenance** for each finding
6
+ 3. **Fix-oriented advisories**
7
+
8
+ ---
9
+
10
+ ## 1) Install
11
+
12
+ ```bash
13
+ npm install -g a11y-evidence-engine
14
+ pip install a11y-assist
15
+ ```
16
+
17
+ ---
18
+
19
+ ## 2) Scan your HTML and emit provenance
20
+
21
+ ```bash
22
+ a11y-engine scan ./html-dir --out ./results
23
+ ```
24
+
25
+ You now have:
26
+ - `results/findings.json`
27
+ - `results/provenance/finding-0001/{record.json,digest.json,envelope.json}`
28
+
29
+ ---
30
+
31
+ ## 3) Ingest findings into a11y-assist
32
+
33
+ ```bash
34
+ a11y-assist ingest ./results/findings.json --out ./results/a11y-assist --format text
35
+ ```
36
+
37
+ Optional strict mode (fails if provenance is missing or invalid):
38
+
39
+ ```bash
40
+ a11y-assist ingest ./results/findings.json --verify-provenance --strict
41
+ ```
42
+
43
+ ---
44
+
45
+ ## 4) What you get
46
+
47
+ - A readable summary in your terminal
48
+ - `results/a11y-assist/ingest-summary.json`
49
+ - `results/a11y-assist/advisories.json` (fix-oriented tasks with evidence links)
50
+
51
+ ---
52
+
53
+ ## Example output
54
+
55
+ ```
56
+ Source: a11y-evidence-engine v0.1.0
57
+ Target: ./html-dir
58
+
59
+ Files scanned: 12 Errors: 4 Warnings: 1 Info: 0
60
+
61
+ By rule:
62
+ html.img.missing_alt: 2 (error)
63
+ html.form_control.missing_label: 2 (error)
64
+
65
+ Top files:
66
+ index.html: 2 errors, 0 warnings
67
+
68
+ Provenance: VERIFIED
69
+
70
+ Output: ./results/a11y-assist
71
+ ```
72
+
73
+ ---
74
+
75
+ ## CLI reference
76
+
77
+ ```
78
+ a11y-assist ingest <findings.json> [options]
79
+
80
+ Options:
81
+ --out <dir> Output directory (default: alongside findings.json)
82
+ --format text|json Output format for stdout (default: text)
83
+ --min-severity Filter: info|warning|error (default: info)
84
+ --strict Fail on missing/invalid provenance
85
+ --verify-provenance Validate provenance bundles
86
+ --fail-on Exit nonzero on: error|warning|never (default: error)
87
+ ```
88
+
89
+ ---
90
+
91
+ ## Exit codes
92
+
93
+ | Code | Meaning |
94
+ |------|---------|
95
+ | 0 | Success, no findings at/above `--fail-on` |
96
+ | 2 | Success, but findings exist at/above `--fail-on` |
97
+ | 3 | Ingest/validation failure |
98
+
99
+ ---
100
+
101
+ **That's it.** You can now build fixes with evidence you can verify.
@@ -0,0 +1,192 @@
1
+ # a11y-assist
2
+
3
+ ![assist](https://img.shields.io/badge/assist-low--vision--first-blue)
4
+ ![safe](https://img.shields.io/badge/commands-SAFE--only-green)
5
+ ![license](https://img.shields.io/badge/license-MIT-black)
6
+
7
+ Low-vision-first assistant for CLI failures.
8
+
9
+ **v0.3 is non-interactive and deterministic.**
10
+ It never rewrites tool output. It only adds an `ASSIST` block.
11
+
12
+ ## Install
13
+
14
+ ```bash
15
+ pip install a11y-assist
16
+ ```
17
+
18
+ ## Usage
19
+
20
+ ### Explain from structured ground truth (best)
21
+
22
+ ```bash
23
+ a11y-assist explain --json message.json
24
+ ```
25
+
26
+ ### Triage raw CLI output (fallback)
27
+
28
+ ```bash
29
+ some-tool do-thing 2>&1 | a11y-assist triage --stdin
30
+ ```
31
+
32
+ ### Wrapper mode (best UX without tool changes)
33
+
34
+ ```bash
35
+ assist-run some-tool do-thing
36
+ # if it fails, run:
37
+ a11y-assist last
38
+ ```
39
+
40
+ ### Accessibility profiles
41
+
42
+ Use `--profile` to select output format:
43
+
44
+ ```bash
45
+ # Default: low-vision profile (numbered steps, max 5)
46
+ a11y-assist explain --json message.json --profile lowvision
47
+
48
+ # Cognitive-load profile (reduced, max 3 steps, First/Next/Last labels)
49
+ a11y-assist explain --json message.json --profile cognitive-load
50
+
51
+ # Screen-reader profile (TTS-optimized, expanded abbreviations)
52
+ a11y-assist explain --json message.json --profile screen-reader
53
+
54
+ # Dyslexia profile (reduced reading friction, explicit labels)
55
+ a11y-assist explain --json message.json --profile dyslexia
56
+
57
+ # Plain-language profile (maximum clarity, one clause per sentence)
58
+ a11y-assist explain --json message.json --profile plain-language
59
+ ```
60
+
61
+ Available profiles:
62
+ - **lowvision** (default): Clear labels, numbered steps, SAFE commands
63
+ - **cognitive-load**: Reduced cognitive load for ADHD, autism, anxiety, or stress
64
+ - **screen-reader**: TTS-optimized for screen readers, braille displays, listen-first workflows
65
+ - **dyslexia**: Reduced reading friction, explicit labels, no symbolic emphasis
66
+ - **plain-language**: Maximum clarity, one clause per sentence, simplified structure
67
+
68
+ ## Output Format
69
+
70
+ ### Low Vision Profile (default)
71
+
72
+ ```
73
+ ASSIST (Low Vision):
74
+ - Anchored to: PAY.EXPORT.SFTP.AUTH
75
+ - Confidence: High
76
+
77
+ Safest next step:
78
+ Start by confirming the cause described under 'Why', then apply the first Fix step.
79
+
80
+ Plan:
81
+ 1) Verify credentials.
82
+ 2) Re-run: payroll export --batch 2026-01-26 --dry-run
83
+
84
+ Next (SAFE):
85
+ payroll export --batch 2026-01-26 --dry-run
86
+
87
+ Notes:
88
+ - Original title: Payment export failed
89
+ - This assist block is additive; it does not replace the tool's output.
90
+ ```
91
+
92
+ ### Cognitive Load Profile
93
+
94
+ Designed for users who benefit from reduced cognitive load (ADHD, autism, anxiety, stress):
95
+
96
+ ```
97
+ ASSIST (Cognitive Load):
98
+ - Anchored to: PAY.EXPORT.SFTP.AUTH
99
+ - Confidence: High
100
+
101
+ Goal: Get back to a known-good state.
102
+
103
+ Safest next step:
104
+ Verify credentials.
105
+
106
+ Plan:
107
+ First: Verify credentials.
108
+ Next: Re-run with dry-run flag.
109
+ Last: Check output for success.
110
+
111
+ Next (SAFE):
112
+ payroll export --batch 2026-01-26 --dry-run
113
+ ```
114
+
115
+ Key differences:
116
+ - Fixed "Goal" line for orientation
117
+ - Max 3 plan steps (vs 5)
118
+ - First/Next/Last labels (vs numbers)
119
+ - One SAFE command max (vs 3)
120
+ - Shorter, simpler sentences
121
+ - No parentheticals or verbose explanations
122
+
123
+ ### Screen Reader Profile
124
+
125
+ Designed for users consuming output via screen readers, TTS, or braille displays:
126
+
127
+ ```
128
+ ASSIST. Profile: Screen reader.
129
+ Anchored I D: PAY.EXPORT.SFTP.AUTH.
130
+ Confidence: High.
131
+
132
+ Summary: Payment export failed.
133
+
134
+ Safest next step: Confirm the credential method used for S F T P.
135
+
136
+ Steps:
137
+ Step 1: Verify the username and password or the S S H key.
138
+ Step 2: Run the dry run export.
139
+ Step 3: Retry the upload.
140
+
141
+ Next safe command:
142
+ payroll export --batch 2026-01-26 --dry-run
143
+ ```
144
+
145
+ Key differences:
146
+ - Spoken-friendly headers (periods instead of colons)
147
+ - "Step N:" labels for predictable listening
148
+ - Abbreviations expanded (CLI → command line, ID → I D, JSON → J S O N)
149
+ - No visual navigation references (above, below, arrow)
150
+ - No parentheticals (screen readers read them awkwardly)
151
+ - Low confidence reduces to 3 steps (less listening time)
152
+
153
+ ## Confidence Levels
154
+
155
+ | Level | Meaning |
156
+ |-------|---------|
157
+ | High | Validated `cli.error.v0.1` JSON with ID |
158
+ | Medium | Raw text with detectable `(ID: ...)` |
159
+ | Low | Best-effort parse, no ID found |
160
+
161
+ ## Safety
162
+
163
+ - **SAFE-only** suggested commands in v0.1
164
+ - Never invents error IDs
165
+ - Confidence is disclosed (High/Medium/Low)
166
+ - No network calls
167
+ - Never rewrites original output
168
+
169
+ ## Commands
170
+
171
+ | Command | Description |
172
+ |---------|-------------|
173
+ | `a11y-assist explain --json <path>` | High-confidence assist from cli.error.v0.1 |
174
+ | `a11y-assist triage --stdin` | Best-effort assist from raw text |
175
+ | `a11y-assist last` | Assist from `~/.a11y-assist/last.log` |
176
+ | `assist-run <cmd> [args...]` | Wrapper that captures output for `last` |
177
+
178
+ ## Integration with a11y-lint
179
+
180
+ Tools that emit `cli.error.v0.1` JSON get high-confidence assistance:
181
+
182
+ ```bash
183
+ # Tool emits structured error
184
+ my-tool --json 2> error.json
185
+
186
+ # Get high-confidence assist
187
+ a11y-assist explain --json error.json
188
+ ```
189
+
190
+ ## License
191
+
192
+ MIT
@@ -0,0 +1,319 @@
1
+ # a11y-assist v0.3.1
2
+
3
+ Sixth stable release of **a11y-assist**, adding audit metadata support for traceability.
4
+
5
+ ## Added
6
+
7
+ ### Methods metadata (audit-only)
8
+ Optional metadata fields in `assist.response.v0.1` for auditing and traceability:
9
+
10
+ - `methods_applied`: List of stable method identifiers (e.g., `engine.normalize.from_cli_error_v0_1`, `profile.screen_reader.apply`, `guard.validate_profile_transform`)
11
+ - `evidence`: Source anchors mapping output fields back to input (e.g., `plan[0]` → `cli.error.fix[0]`)
12
+
13
+ Rules:
14
+ - Metadata does not affect rendering output (golden tests unchanged)
15
+ - Method IDs are append-only and stable once published
16
+ - Evidence anchors are deterministic and lightweight
17
+
18
+ ### New module: `a11y_assist.methods`
19
+ Helper functions for adding methods and evidence:
20
+ - `with_method()`, `with_methods()` - add method IDs
21
+ - `with_evidence()` - add evidence anchors
22
+ - `evidence_for_plan()` - generate plan step evidence
23
+
24
+ ### Governance artifacts
25
+ - `CONTRIBUTING.md` - contributor guidelines and core principles
26
+ - Golden fixtures (`tests/fixtures/`) - frozen expected outputs for all 5 profiles
27
+ - `tests/test_golden.py` - exact string match tests against fixtures
28
+ - `tests/test_methods_metadata.py` - 16 tests for metadata correctness
29
+
30
+ ## Changed
31
+
32
+ - Version bump to 0.3.1
33
+ - ENGINE.md updated to v0.3.1 with §14 Methods metadata
34
+ - Response schema updated with optional `methods_applied` and `evidence` properties
35
+ - 253 tests total (16 new metadata tests + 7 golden tests)
36
+
37
+ ## Unchanged from v0.3.0
38
+
39
+ All v0.3.0 features remain stable:
40
+ - Dyslexia and plain-language profiles
41
+ - All existing profiles (lowvision, cognitive-load, screen-reader)
42
+ - Profile Guard runtime safety
43
+ - Core commands: explain, triage, last, assist-run
44
+ - Safety guarantees: no invented IDs, SAFE-only, deterministic
45
+
46
+ ---
47
+
48
+ # a11y-assist v0.3.0
49
+
50
+ Fifth stable release of **a11y-assist**, completing the inclusive profile set with dyslexia and plain-language profiles.
51
+
52
+ ## Added
53
+
54
+ ### Dyslexia profile (`--profile dyslexia`)
55
+ Reduces reading friction without reducing information:
56
+
57
+ - Extra vertical spacing between sections
58
+ - One idea per line
59
+ - Explicit labels (never implied by formatting)
60
+ - "Step N:" prefix for predictable structure
61
+ - No parentheticals
62
+ - No symbolic emphasis (*, _, →)
63
+ - No visual navigation references
64
+ - Abbreviations expanded (CLI → command line, ID → I D)
65
+ - Max 5 steps, max 2 notes
66
+
67
+ ### Plain-language profile (`--profile plain-language`)
68
+ Maximizes understandability through simplicity:
69
+
70
+ - Active voice, present tense
71
+ - One clause per sentence
72
+ - Subordinate clauses removed
73
+ - Conjunctions split (keeps first clause)
74
+ - No parentheticals
75
+ - Simple numeric step labels
76
+ - Max 4 steps, max 1 command
77
+ - Notes omitted for clarity
78
+
79
+ ### Complete inclusive profile set
80
+ Ally now supports five principled profiles:
81
+
82
+ | Profile | Primary benefit |
83
+ |---------|-----------------|
84
+ | lowvision | Visual clarity |
85
+ | cognitive-load | Reduced mental steps |
86
+ | screen-reader | Audio-first |
87
+ | dyslexia | Reduced reading friction |
88
+ | plain-language | Maximum clarity |
89
+
90
+ ## Changed
91
+
92
+ - Version bump to 0.3.0
93
+ - 50 new tests for dyslexia and plain-language (230 total)
94
+ - Guard updated to enforce dyslexia and plain-language constraints
95
+
96
+ ## Unchanged from v0.2.2
97
+
98
+ All v0.2.2 features remain stable:
99
+ - Profile Guard runtime safety
100
+ - Screen-reader, cognitive-load, lowvision profiles
101
+ - Core commands: explain, triage, last, assist-run
102
+ - Safety guarantees: no invented IDs, SAFE-only, deterministic
103
+
104
+ ---
105
+
106
+ # a11y-assist v0.2.2
107
+
108
+ Fourth stable release of **a11y-assist**, adding the Profile Guard runtime safety system.
109
+
110
+ ## Added
111
+
112
+ ### Profile Guard (`guard.py`)
113
+ Centralized runtime invariant checker that runs after every profile transform:
114
+
115
+ - **ID Invariant**: Anchored ID cannot be invented or changed
116
+ - **Confidence Invariant**: Confidence cannot increase (only same or decrease)
117
+ - **Commands Invariant**: SAFE-only commands - no invented commands, no commands on Low confidence
118
+ - **Step Count Invariant**: Enforces max steps per profile (lowvision: 5, cognitive-load: 3, screen-reader: 3-5)
119
+ - **Content Support Invariant**: Profile must not add new factual content (WARN only)
120
+ - **Profile-Specific Constraints**: Screen-reader forbids parentheticals and visual references
121
+
122
+ ### Guard API
123
+ - `GuardIssue`: Frozen dataclass for guard violations
124
+ - `GuardViolation`: Exception raised when invariants are violated
125
+ - `GuardContext`: Frozen dataclass with profile rules and constraints
126
+ - `validate_profile_transform()`: Main validation function
127
+ - `get_guard_context()`: Factory function for profile-specific contexts
128
+
129
+ ### Guard Error Output
130
+ Guard failures produce structured error messages:
131
+ ```
132
+ [ERROR] A11Y.ASSIST.ENGINE.GUARD.FAIL
133
+
134
+ What:
135
+ A profile produced output that violates engine safety rules.
136
+
137
+ Why:
138
+ This indicates a bug in a profile transform or renderer.
139
+
140
+ Fix:
141
+ Run tests; open an issue; include profile name and guard codes.
142
+
143
+ Guard codes:
144
+ - A11Y.ASSIST.GUARD.COMMANDS.INVENTED: Profile included a command not in the allowed set
145
+ ```
146
+
147
+ ## Changed
148
+
149
+ - Version bump to 0.2.2
150
+ - 48 new tests for guard (180 total)
151
+ - All profile transforms now run through guard validation
152
+
153
+ ## Unchanged from v0.2.1
154
+
155
+ All v0.2.1 features remain stable:
156
+ - Screen-reader profile
157
+ - Cognitive-load profile
158
+ - Low-vision profile (default)
159
+ - Core commands: explain, triage, last, assist-run
160
+ - Safety guarantees: no invented IDs, SAFE-only, deterministic
161
+
162
+ ---
163
+
164
+ # a11y-assist v0.2.1
165
+
166
+ Third stable release of **a11y-assist**, adding the screen-reader accessibility profile.
167
+
168
+ ## Added
169
+
170
+ ### Screen-reader profile (`--profile screen-reader`)
171
+ Designed for users consuming output via:
172
+ - Screen readers / TTS
173
+ - Braille displays
174
+ - Listen-first workflows (hands busy, eyes fatigued)
175
+
176
+ Features:
177
+ - Spoken-friendly headers (periods instead of colons)
178
+ - "Step N:" labels for predictable listening
179
+ - Abbreviations expanded (CLI → command line, ID → I D, JSON → J S O N, SFTP → S F T P)
180
+ - No visual navigation references (above, below, left, right, arrow)
181
+ - No parentheticals (screen readers read them awkwardly)
182
+ - Low confidence reduces to 3 steps (less listening time)
183
+ - Summary line for quick context
184
+
185
+ ### Profile selection now includes screen-reader
186
+ All commands support `--profile lowvision|cognitive-load|screen-reader`:
187
+ - `a11y-assist explain --json <path> --profile screen-reader`
188
+ - `a11y-assist triage --stdin --profile screen-reader`
189
+ - `a11y-assist last --profile screen-reader`
190
+
191
+ ### Screen-reader invariants (in addition to base invariants)
192
+ - No meaning in punctuation/formatting alone
193
+ - No "visual navigation" references
194
+ - Avoid parentheticals as meaning carriers
195
+ - Abbreviations expanded for TTS clarity
196
+
197
+ ## Changed
198
+
199
+ - Version bump to 0.2.1
200
+ - 56 new tests for screen-reader profile (132 total)
201
+
202
+ ## Unchanged from v0.2.0
203
+
204
+ All v0.2.0 features remain stable:
205
+ - Cognitive-load profile (`--profile cognitive-load`)
206
+ - Low-vision profile (`--profile lowvision`, default)
207
+ - Core commands: explain, triage, last, assist-run
208
+ - Safety guarantees: no invented IDs, SAFE-only, deterministic
209
+
210
+ ## Stability guarantees
211
+
212
+ - v0.2.x output format is considered stable for all three profiles
213
+ - No breaking changes without a major version bump
214
+ - Interactive or AI-assisted features will not be added to v0.x
215
+
216
+ ## What's next (v0.3.0)
217
+
218
+ - Optional interactive mode
219
+ - Pluggable AI backends (opt-in)
220
+ - Deeper integration with a11y-ci workflows
221
+
222
+ ---
223
+
224
+ # a11y-assist v0.2.0
225
+
226
+ Second stable release of **a11y-assist**, adding the cognitive-load accessibility profile.
227
+
228
+ ## Added
229
+
230
+ ### Cognitive-load profile (`--profile cognitive-load`)
231
+ Designed for users who benefit from reduced cognitive load:
232
+ - ADHD / executive dysfunction
233
+ - Autism / sensory overload
234
+ - Anxiety under incident conditions
235
+ - Novices under stress
236
+
237
+ Features:
238
+ - Fixed "Goal" line for orientation
239
+ - Max 3 plan steps (vs 5 in low-vision)
240
+ - First/Next/Last labels instead of numbers
241
+ - One SAFE command max (vs 3)
242
+ - Shorter, simpler sentences
243
+ - No parentheticals or verbose explanations
244
+
245
+ ### Profile selection via `--profile` flag
246
+ All commands now support `--profile lowvision|cognitive-load`:
247
+ - `a11y-assist explain --json <path> --profile cognitive-load`
248
+ - `a11y-assist triage --stdin --profile cognitive-load`
249
+ - `a11y-assist last --profile cognitive-load`
250
+
251
+ ### Invariants (non-negotiable)
252
+ The cognitive-load profile enforces strict invariants:
253
+ 1. **No invented facts** - only rephrases existing content
254
+ 2. **No invented commands** - SAFE commands are verbatim from input
255
+ 3. **SAFE-only** remains absolute
256
+ 4. **Additive** - doesn't rewrite original output
257
+ 5. **Deterministic** - no randomness, no network calls
258
+
259
+ ## Changed
260
+
261
+ - Default profile is `lowvision` (backward compatible)
262
+ - Version bump to 0.2.0
263
+
264
+ ---
265
+
266
+ # a11y-assist v0.1.0
267
+
268
+ Initial stable release of **a11y-assist**, a low-vision-first assistant for CLI failures.
269
+
270
+ ## Added
271
+
272
+ ### Core commands
273
+ - `a11y-assist explain --json <path>`
274
+ Deterministic assistance from validated `cli.error.v0.1` JSON
275
+
276
+ - `a11y-assist triage --stdin`
277
+ Best-effort parsing of raw CLI output with explicit confidence labeling
278
+
279
+ - `a11y-assist last`
280
+ Assist from the most recent captured command output
281
+
282
+ - `assist-run <command>`
283
+ Wrapper that captures stdout/stderr and suggests help on failure
284
+
285
+ ### Rendering
286
+ - Clear **ASSIST (Low Vision)** output block
287
+ - Explicit confidence levels: High / Medium / Low
288
+ - Structured sections:
289
+ - Safest next step
290
+ - Numbered plan (max 5)
291
+ - SAFE next commands (when applicable)
292
+ - Notes
293
+
294
+ ### Safety guarantees
295
+ - Original CLI output is never modified
296
+ - No invented error IDs
297
+ - SAFE-only command suggestions in v0.1
298
+ - No network calls or background services
299
+
300
+ ### Compatibility
301
+ - Anchors to `cli.error.v0.1` when present
302
+ - Gracefully degrades on raw text
303
+ - Works alongside existing tools without modification
304
+
305
+ ## Stability guarantees
306
+
307
+ - v0.1 output format is considered stable
308
+ - No breaking changes without a major version bump
309
+ - Interactive or AI-assisted features will not be added to v0.x
310
+
311
+ ## Known limitations
312
+
313
+ - Raw text triage is heuristic and lower confidence
314
+ - Assistance quality depends on the structure of input
315
+ - Interactive mode is intentionally not included
316
+
317
+ ---
318
+
319
+ Thank you for helping make developer tools more humane.
@@ -0,0 +1,3 @@
1
+ """a11y-assist: Low-vision-first assistant for CLI failures."""
2
+
3
+ __version__ = "0.3.1"