{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "name": "surface-qa routing accuracy corpus",
  "version": "2.1.0",
  "purpose": "Routing-eval corpus for surface-qa (adia-ui-factory plugin). Each phrase declares whether surface-qa SHOULD be the routing target. Scored by the estate's TF-IDF routing-eval runner against the skill's description (heuristic token overlap).",
  "scoring_notes": "Heuristic signal, not ground truth. Treat misroutes as a prompt to tighten the skill description, never as a reason to keyword-stuff it. Real harness routing is LLM-driven.",
  "license": "internal",
  "scope": "surface-qa routing \u2014 does this phrase activate surface-qa (the consumer-app browser-QA exit gate), and does it correctly stay OUT of package-release's release pre-flight gates, which is the one known central-corpus misroute for any 'verify'-flavored phrase?",
  "phrases": [
    {
      "id": "verify-gate-01",
      "phrase": "verify this surface renders with zero console errors before we ship it",
      "expected": "surface-qa",
      "expected_shape": "browser-gate",
      "rationale": "Canonical pre-ship browser-render gate phrasing \u2014 matches the skill's own 'before shipping a surface' trigger."
    },
    {
      "id": "verify-gate-02",
      "phrase": "run the browser gate on the new settings page",
      "expected": "surface-qa",
      "expected_shape": "browser-gate",
      "rationale": "Direct 'browser gate' terminology from the skill's own name for its check."
    },
    {
      "id": "verify-gate-03",
      "phrase": "check that bounding boxes are non-zero on the dashboard before merging",
      "expected": "surface-qa",
      "expected_shape": "browser-gate",
      "rationale": "Non-zero bounding box is the gate's literal pass condition."
    },
    {
      "id": "verify-qa-01",
      "phrase": "verify/QA this page before we ship it",
      "expected": "surface-qa",
      "expected_shape": "qa-request",
      "rationale": "Verbatim 'verify/QA this page' phrase from the skill description."
    },
    {
      "id": "verify-qa-02",
      "phrase": "is this screen done? run the exit gate on it",
      "expected": "surface-qa",
      "expected_shape": "qa-request",
      "rationale": "'Is this screen done' \u2014 the exit-gate framing this skill owns."
    },
    {
      "id": "verify-qa-03",
      "phrase": "QA the checkout flow before it goes live for users",
      "expected": "surface-qa",
      "expected_shape": "qa-request",
      "rationale": "Consumer-app pre-launch QA request; deliberately avoids the word 'release' to not collide with package-release."
    },
    {
      "id": "verify-a11y-01",
      "phrase": "run an accessibility pass on the profile page",
      "expected": "surface-qa",
      "expected_shape": "a11y-check",
      "rationale": "A11y check is one of the two gate halves this skill owns."
    },
    {
      "id": "verify-a11y-02",
      "phrase": "check AA contrast and the keyboard path on the new modal",
      "expected": "surface-qa",
      "expected_shape": "a11y-check",
      "rationale": "AA contrast + keyboard path are named rubric rows."
    },
    {
      "id": "verify-a11y-03",
      "phrase": "does this overlay have a real heading role and an aria-label on its region?",
      "expected": "surface-qa",
      "expected_shape": "a11y-check",
      "rationale": "Region role + heading role are named a11y-gate items."
    },
    {
      "id": "verify-debug-01",
      "phrase": "the screen renders completely blank, help me figure out why",
      "expected": "surface-qa",
      "expected_shape": "debug-symptom",
      "rationale": "'Empty page' symptom \u2014 a named failure class only this gate catches."
    },
    {
      "id": "verify-debug-02",
      "phrase": "this element reports a 0x0 bounding box, why isn't it sized",
      "expected": "surface-qa",
      "expected_shape": "debug-symptom",
      "rationale": "0x0 host is the skill's named failure class."
    },
    {
      "id": "verify-debug-03",
      "phrase": "the page looks broken visually but the console shows no errors",
      "expected": "surface-qa",
      "expected_shape": "debug-symptom",
      "rationale": "Clean-console-but-visually-broken is the anti-pattern this gate exists to catch."
    },
    {
      "id": "verify-anti-01",
      "phrase": "our unit tests pass, but I want someone to actually look at the rendered page before we call it done",
      "expected": "surface-qa",
      "expected_shape": "anti-pattern-tests-pass",
      "rationale": "Directly invokes the skill's named anti-pattern: 'tests pass, ship it'."
    },
    {
      "id": "verify-anti-02",
      "phrase": "confirm the surface actually renders and isn't just clipped \u2014 don't take the test suite's word for it",
      "expected": "surface-qa",
      "expected_shape": "anti-pattern-tests-pass",
      "rationale": "Clipped-content-despite-passing-tests is the gate's reason to exist."
    },
    {
      "id": "verify-adv-01",
      "phrase": "run the pre-flight verification gates before we cut the v0.8 release",
      "expected": "package-release",
      "rationale": "Adversarial \u2014 the known central-corpus misroute: 'verify' language describing release pre-flight gates (F-N1, tag/publish checkpoints), not a consumer-app browser QA pass.",
      "expected_alternative_raw": "package-release (forge plugin)"
    },
    {
      "id": "verify-adv-02",
      "phrase": "run a dogfood sweep across every demo page in the framework repo",
      "expected": "demo-audit",
      "rationale": "Adversarial \u2014 framework-side demo sweep (visual probe, attr-quote typos, shell composition) is demo-audit's territory, not the consumer-app exit gate.",
      "expected_alternative_raw": "demo-audit (forge plugin)"
    },
    {
      "id": "verify-adv-03",
      "phrase": "the QA pass found the button is unstyled and misplaced \u2014 go fix the screen",
      "expected": "screen-composition",
      "rationale": "Adversarial \u2014 verify only reports the gap; fixing the composed screen routes to screen-composition (generator, not the gate).",
      "expected_alternative_raw": "screen-composition (adia-ui-factory plugin)"
    },
    {
      "id": "verify-adv-04",
      "phrase": "the gate found the data isn't hydrating on load \u2014 fix the state wiring",
      "expected": "data-wiring",
      "rationale": "Adversarial \u2014 fixing a hydration/state defect the gate surfaced belongs to data-wiring, not to re-running verify.",
      "expected_alternative_raw": "data-wiring (adia-ui-factory plugin)"
    },
    {
      "id": "verify-adv-05",
      "phrase": "run the structural lint check on the files from my last commit",
      "expected": null,
      "rationale": "Adversarial \u2014 structural smells (shadow DOM, raw color/px, native-primitive leaks) are the adia-lint hook's mechanized slice; verify only checks that hook reports clean, it doesn't run the lint itself.",
      "expected_alternative_raw": "adia-lint hook (advisory PostToolUse hook, not a skill)"
    },
    {
      "id": "verify-adv-06",
      "phrase": "write unit tests for the new date-parsing utility function",
      "expected": null,
      "rationale": "Adversarial \u2014 generic unit-test authoring with no browser-render or a11y surface; no AdiaUI skill should activate."
    }
  ],
  "minimums_per_spec": {
    "trigger_phrases": 14,
    "adversarial_phrases": 6,
    "task_shapes_covered": "browser-gate, qa-request, a11y-check, debug-symptom, anti-pattern-tests-pass",
    "adversarial_fraction": "30%"
  },
  "evaluator_notes": {
    "current_state": "20 cases (14 trigger + 6 adversarial). Each of the 5 task shapes has 2-3 trigger cases; adv-01 specifically targets the documented known misroute (verify-flavored phrase landing on package-release).",
    "promotion_criteria": "Promote to a CI gate (warn \u2192 hard-fail) when F1 \u2265 0.85 on this corpus across 3+ consecutive runs without description edits.",
    "review_cadence": "Re-run on every surface-qa description edit. Add 1-2 new cases per checkpoint reflecting newly-observed routing failure modes.",
    "known_limitations": "verify-adv-01 encodes the single highest-value adversarial for this skill: 'verify' as a bare word is release-gate-shaped in the central corpus, and the heuristic scorer may weight token overlap toward package-release's own 'pre-flight gates' language. The description's browser/a11y-specific vocabulary (bounding boxes, console.error, aria-label) is the intended disambiguator."
  }
}
