a11y

A11Y Plain Language

Plain-language coverage + cognitive load (spec §4.5).

TWO AXES, deliberately not fused into one "remaining" number:

  • COVERAGE: the plain_language override per language over the keys whose type offers the treatment (text, heading, label, caption).
  • COGNITIVE: cognitive_score (0-100, higher = harder) against the project threshold; above_threshold = eligible keys scored at or over it; pending_rewrites = those that HAVE a suggestion and no source-language plain_language override yet (the rewrite exists, nobody applied it). reading_level_flagged is a heuristic CANDIDATE count on the source value (reading_level_max_words), not a formal WCAG reading-level test.

CAN vs MUST (task 1830). eligible = the key TYPES that CAN carry a rewrite; only HARD-TO-READ keys NEED one, so eligible is never a backlog denominator. Three compartments, mutually exclusive, summing EXACTLY to eligible_keys:

  • candidates (scored >= threshold) — THE primary number, what remains;
  • scored_readable — read and judged readable: DONE, nothing to rewrite;
  • not_scored — UNKNOWN. Nothing measured these keys yet; never show it as work (unscored_reading_level_flagged is its "score these first" queue). pct_candidates (= candidates_rewritten / candidates) is the coverage number to display — NOT pct, which spans the whole eligible pool and reads as a backlog it is not. measured_candidates=False means nothing was identified as hard to read; that is NOT 100% and must not be painted green. suggestions_count is DEPRECATED: it counts keys that merely COULD carry a rewrite (a potential), not a queue — use candidates_remaining.
get/v1/projects/{project_id}/a11y/plain-language

Request

  • Base URL: https://api.sonenta.dev
  • URL: https://api.sonenta.dev/v1/projects/{project_id}/a11y/plain-language
  • Auth: none declared

Path parameters

project_idstring required

Query parameters

version_idstring nullable
reading_level_max_wordsinteger

Response

Successful Response

project_uuidstring required
version_uuidstring nullable required
languagesstring[] required
source_languagestring nullable required
eligible_keysinteger required
eligible_cellsinteger required
present_cellsinteger required
pctinteger required
measuredboolean required
formulaobject required
surfacestring required
key_typesstring[] required
suggestions_countinteger required
thresholdnumber required
above_thresholdinteger required
pending_rewritesinteger required
analyzedinteger required
unanalyzedinteger required
reading_level_max_wordsinteger required
reading_level_flaggedinteger required
not_scoredinteger
scored_readableinteger
candidatesinteger
candidates_rewritteninteger
candidates_remaininginteger
candidates_with_suggestioninteger
pct_candidatesinteger
measured_candidatesboolean
unscored_reading_level_flaggedinteger

Changes

No recorded changes to this operation across all 1 revision of this API.