[](LICENSE)
@@ -277,9 +277,9 @@ Synchronous feature flow, async issue-to-PR automation, and product backlog.
### 🎨 [aidd-ui](plugins/aidd-ui/README.md) 🚧
-`1 skill` · **alpha**
+`5 skills` · **alpha**
-UI / UX design — smoke-test only, not ready for use.
+Versioned UI system contracts, feature experience decisions, specialist verdicts, and evidence-pinned review.
diff --git a/docs/ARCHITECTURE.md b/docs/ARCHITECTURE.md
index 56508cc01..3e8377222 100644
--- a/docs/ARCHITECTURE.md
+++ b/docs/ARCHITECTURE.md
@@ -55,10 +55,11 @@ Every capability lives in exactly one plugin, chosen by **concern**. This taxono
| `aidd-orchestrator` | Orchestration | Coordination |
| `aidd-ui` 🚧 | UI/UX design | Execution |
-`aidd-ui` is alpha: smoke-test only, off the curated install path.
+`aidd-ui` is alpha: it owns interface experience decisions and remains off the curated install path.
- **Knowledge vs execution is a firewall.** Knowledge plugins produce artifacts you *read* and never write or run application source. `aidd-context`'s bootstrap deliberately creates no `package.json`. Real code belongs to `aidd-dev` or an orchestrator's own setup actions.
- **Concern decides placement, not existence.** A missing capability goes in the plugin whose concern owns it, then the caller delegates. Never reimplement it in the calling plugin because the right home lacks it today.
+- **The UI seam is an experience contract, not application code.** Product intent and durable project knowledge feed UI decisions; code transformation consumes those decisions for implementation. Current code wins when project memory drifts, and only the knowledge concern updates memory.
- **Orchestration = sequencing across concerns** with little domain logic. Delegating a sub-step once does not make a skill an orchestrator. The orchestrator owns only glue and hands off through a seam artifact, for example an `INSTALL.md` one plugin produces and another consumes.
- `aidd-orchestrator:02-backlog` owns the cross-artifact flow. Each artifact's contract stays in its `aidd-pm` skill, so a direct PM call follows the same rules as an orchestrated one.
diff --git a/docs/CATALOG.md b/docs/CATALOG.md
index d08bf4696..41f4de9f5 100644
--- a/docs/CATALOG.md
+++ b/docs/CATALOG.md
@@ -8,7 +8,7 @@ The exhaustive list of AIDD plugins, skills, and actions. Skills are invoked thr
- [aidd-refine](#-aidd-refine) - meta-cognition
- [aidd-vcs](#-aidd-vcs) - version control workflows
- [aidd-orchestrator](#-aidd-orchestrator) - async orchestration (optional)
-- [aidd-ui](#-aidd-ui) - UI / UX (🚧 alpha, not ready)
+- [aidd-ui](#-aidd-ui) - UI / UX decisions (🚧 alpha)
---
@@ -38,10 +38,10 @@ Code transformation: plan, implement, assert, audit, review, test, refactor, deb
| Skill | Role | Actions |
| --------------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |
-| `01-plan` | Turn a request, ticket, or file into a phased implementation plan: gather, explore, wireframe, plan | `01-gather`, `02-explore`, `03-wireframe`, `04-plan` |
+| `01-plan` | Turn a request, ticket, or file into a phased implementation plan and resolve ready UI decisions | `01-gather`, `02-explore`, `03-experience`, `04-plan` |
| `02-implement` | Execute a plan phase by phase until 100% complete | `01-implement` |
| `03-assert` | Assert features work - general, architecture, frontend UI | `01-assert`, `02-assert-architecture`, `03-assert-frontend` |
-| `04-audit` | Read-only codebase audit across quality pillars | `01-code-quality`, `02-architecture`, `03-security`, `04-dependencies`, `05-performance`, `06-tests`, `07-ui` |
+| `04-audit` | Read-only codebase audit; UI experience is delegated to its owning concern | `01-code-quality`, `02-architecture`, `03-security`, `04-dependencies`, `05-performance`, `06-tests`, `07-ui` |
| `05-review` | Read-only review of a diff - code quality and feature behavior | `01-review-code`, `02-review-functional` |
| `06-test` | Write and iterate tests, validate user journeys in the browser | `01-test`, `02-test-journey` |
| `07-refactor` | Improve code without changing behavior across four axes | `01-performance`, `02-security`, `03-cleanup`, `04-architecture` |
@@ -102,8 +102,12 @@ Runs synchronous feature delivery, optional async issue automation, and the prod
## 🎨 aidd-ui
-🚧 **Alpha — not ready for use.** UI / UX: design, review, and improve frontend interfaces. Currently a smoke-test only.
+🚧 **Alpha.** Shared UI systems and feature experience decisions. Off the curated install path.
-| Skill | Role | Actions |
-| ---------- | ----------------------------------------- | ---------- |
-| `01-hello` | Smoke-test that confirms the plugin loads | `01-greet` |
+| Skill | Role | Actions |
+| --- | --- | --- |
+| `01-system` | Manage shared UI system contracts and deltas | `inspect`, `map`, `specialize`, `adopt`, `establish`, `extend`, `retire`, `reconcile`, `promote` |
+| `02-design` | Create or revise a feature UI contract | `frame`, `inspect`, `specialize`, `structure`, `compose`, `write`, `verify` |
+| `03-review` | Diagnose and prioritize experience defects | `inspect`, `specialize`, `assess`, `write` |
+| `04-accessibility` | Own accessibility requirements and verdicts | `inspect`, `specify`, `evaluate` |
+| `05-adapt` | Own space, input, and platform transformations | `inspect`, `specify`, `evaluate` |
diff --git a/plugins/aidd-context/skills/02-project-memory/assets/templates/memory/ui/design.md b/plugins/aidd-context/skills/02-project-memory/assets/templates/memory/ui/design.md
index 9c18e9dd9..009a59f1a 100644
--- a/plugins/aidd-context/skills/02-project-memory/assets/templates/memory/ui/design.md
+++ b/plugins/aidd-context/skills/02-project-memory/assets/templates/memory/ui/design.md
@@ -1,25 +1,23 @@
# Design
-The visual language: the design system, tokens, and UI conventions. What it looks like, not how it is coded.
+Compact pointers to stable UI knowledge. Current code remains implementation truth; an active UI system contract remains decision authority.
-## System
+## UI System Authority
--
--
+-
-## Tokens
+## Current Implementation
--
+-
+-
-## Components
+## Stable Context
--
-
-## Accessibility
-
--
+-
+-
diff --git a/plugins/aidd-context/skills/02-project-memory/references/reading-sources.md b/plugins/aidd-context/skills/02-project-memory/references/reading-sources.md
index dbc39a760..bd3256ca5 100644
--- a/plugins/aidd-context/skills/02-project-memory/references/reading-sources.md
+++ b/plugins/aidd-context/skills/02-project-memory/references/reading-sources.md
@@ -10,6 +10,7 @@ opening it again.
| -------------------------------------------- | -------------------------------------------- |
| the manifest, and a lockfile beside it | the stack, the workspaces, the published name |
| the root README, then any `docs/` | what it does, for whom, its domain words |
+| current contracts under `aidd_docs/ui/systems/` | accepted shared UI authority, ids, and scopes |
| the top-level directories | the shape, and which areas own what |
| the entry points the manifest declares | where execution starts |
| every file under the VCS platform's own directory | how it ships, and what runs on its own schedule |
@@ -38,6 +39,8 @@ wrote stays whatever the verdicts below say.
| a work item, a live value, a technical id | drop |
| a plan, a wish, a thing not shipped | drop |
+For a current UI system contract, keep only its path, immutable id, and normalized scope. The path resolves the current revision; do not copy its decisions or retain the revision number in memory.
+
## Depth
- Every workspace of a monorepo, never the root manifest alone.
diff --git a/plugins/aidd-dev/CATALOG.md b/plugins/aidd-dev/CATALOG.md
index 671f54194..b1cc57ac2 100644
--- a/plugins/aidd-dev/CATALOG.md
+++ b/plugins/aidd-dev/CATALOG.md
@@ -44,7 +44,7 @@ Auto-generated index of skills, agents, references and assets shipped by the `ai
|-------|------|---|
| `actions` | [01-gather.md](skills/01-plan/actions/01-gather.md) | - |
| `actions` | [02-explore.md](skills/01-plan/actions/02-explore.md) | - |
-| `actions` | [03-wireframe.md](skills/01-plan/actions/03-wireframe.md) | - |
+| `actions` | [03-experience.md](skills/01-plan/actions/03-experience.md) | - |
| `actions` | [04-plan.md](skills/01-plan/actions/04-plan.md) | - |
| `assets` | [phase-template.md](skills/01-plan/assets/phase-template.md) | - |
| `assets` | [plan-template.md](skills/01-plan/assets/plan-template.md) | - |
@@ -84,7 +84,7 @@ Auto-generated index of skills, agents, references and assets shipped by the `ai
| `actions` | [06-tests.md](skills/04-audit/actions/06-tests.md) | - |
| `actions` | [07-ui.md](skills/04-audit/actions/07-ui.md) | - |
| `assets` | [audit-template.md](skills/04-audit/assets/audit-template.md) | `Codebase audit report template` |
-| `-` | [SKILL.md](skills/04-audit/SKILL.md) | `Audit a codebase read-only across seven quality pillars into one ranked report. Use when the user wants to assess, health-check, or audit a codebase or one pillar. Not for fixing findings, reviewing a change, or checking a feature works.` |
+| `-` | [SKILL.md](skills/04-audit/SKILL.md) | `Audit a codebase read-only across six engineering pillars plus delegated UI experience review. Use when the user wants to assess, health-check, or audit a codebase or one pillar. Not for fixing findings, reviewing a change, or checking a feature works.` |
#### `skills/05-review`
diff --git a/plugins/aidd-dev/README.md b/plugins/aidd-dev/README.md
index a23bc830b..e7632a00e 100644
--- a/plugins/aidd-dev/README.md
+++ b/plugins/aidd-dev/README.md
@@ -14,7 +14,7 @@ Covers code transformation: planning, implementation, assertions, audits, code r
| Bracket ID | Skill | Description |
|---|---|---|
-| [2.1] | [plan](skills/01-plan/SKILL.md) | Turn a request, ticket, or file into a phased implementation plan, gathering the source first and optionally wireframing a screen before planning. |
+| [2.1] | [plan](skills/01-plan/SKILL.md) | Turn a request, ticket, or file into a phased implementation plan, resolving a ready UI contract for frontend work with a bounded compatibility fallback while the UI provider is optional. |
| [2.2] | [implement](skills/02-implement/SKILL.md) | Execute an implementation plan phase by phase, recipe-style, iterating until 100% completeness. |
| [2.3] | [assert](skills/03-assert/SKILL.md) | Assert features work as intended - general assertions, architecture conformance, and frontend UI validation. |
| [2.4] | [audit](skills/04-audit/SKILL.md) | Perform deep codebase analysis to identify technical debt, dead code, and improvement opportunities. |
diff --git a/plugins/aidd-dev/skills/01-plan/SKILL.md b/plugins/aidd-dev/skills/01-plan/SKILL.md
index e8649e4a6..972982a1e 100644
--- a/plugins/aidd-dev/skills/01-plan/SKILL.md
+++ b/plugins/aidd-dev/skills/01-plan/SKILL.md
@@ -10,19 +10,19 @@ Turn a gathered source into an implementation plan and its phase files. Never wr
## Actions
-| # | Action | Role | Input |
-| --- | ----------- | ---------------------------------------------------- | -------------------------- |
-| 01 | `gather` | Collect and restate the source | user request |
-| 02 | `explore` | Read the codebase for projection, rules, feasibility | gathered source |
-| 03 | `wireframe` | Sketch a screen at low fidelity, frontend only | source + explore context |
-| 04 | `plan` | Break into phases, write the plan and phase files | explore output + wireframe |
+| # | Action | Role | Input |
+| --- | ------------ | ---------------------------------------------------- | ---------------------------- |
+| 01 | `gather` | Collect and restate the source | user request |
+| 02 | `explore` | Read the codebase for projection, rules, feasibility | gathered source |
+| 03 | `experience` | Resolve UI decisions, frontend only | source + explore context |
+| 04 | `plan` | Break into phases, write the plan and phase files | explore output + UI contract |
Run them in order, `01 → 04`. The plan is the culmination. Skip `03` when there is no UI.
Before running an action, read its file in `actions/`, not only the table or assets.
## References
-- `references/wireframe-conventions.md`: how to draw the ASCII wireframe a screen needs.
+- `references/wireframe-conventions.md`: bounded compatibility fallback while the UI provider remains optional.
- `references/plan-status.md`: the plan lifecycle `status` values and who writes each.
## Assets
diff --git a/plugins/aidd-dev/skills/01-plan/actions/03-experience.md b/plugins/aidd-dev/skills/01-plan/actions/03-experience.md
new file mode 100644
index 000000000..6e84ec429
--- /dev/null
+++ b/plugins/aidd-dev/skills/01-plan/actions/03-experience.md
@@ -0,0 +1,29 @@
+# 03 - Experience
+
+Resolve implementation-ready UI decisions for frontend work. Skip when the feature has no interface.
+
+## Input
+
+The gathered source, explore context, and optional feature `ui.md`.
+
+## Output
+
+Prefer one verified current `ui.md` reference with revision, pinned systems, and required deltas. When the alpha UI provider is unavailable, return a compatibility-only low-fidelity wireframe.
+
+## Process
+
+1. **Find.** Inspect the feature's current `ui.md` and reject it while `.ui.lock` exists.
+2. **Discover.** Resolve a provider from runtime capability metadata without naming a sibling.
+3. **Resolve.** Invoke `create` or `revise` when available, then accept only a current ready contract whose systems and approved or verified deltas resolve at their current bases.
+ - Route satisfied approved deltas to system reconciliation and promoted deltas to UI revision.
+4. **Fallback.** Draw a structure-only wireframe from [wireframe-conventions.md](../references/wireframe-conventions.md) only when no contract and no provider exist.
+ - Stop with `UI revision needed` when a contract exists but no provider can revise it.
+5. **Return.** Reference a resolved contract and dependencies without copying decisions, or return the bounded fallback wireframe.
+
+## Test
+
+- Non-UI work skips this action.
+- UI work yields one current ready contract with resolvable dependencies.
+- A draft, stale, or promoted graph routes to its owning UI operation.
+- Provider absence preserves only the compatibility wireframe and creates no UI artifact.
+- Provider absence never bypasses an existing draft or stale contract.
diff --git a/plugins/aidd-dev/skills/01-plan/actions/03-wireframe.md b/plugins/aidd-dev/skills/01-plan/actions/03-wireframe.md
deleted file mode 100644
index 928b9cb95..000000000
--- a/plugins/aidd-dev/skills/01-plan/actions/03-wireframe.md
+++ /dev/null
@@ -1,20 +0,0 @@
-# 03 - Wireframe
-
-Sketch a low-fidelity ASCII wireframe of a screen, to fix its layout before the plan. Frontend only, skip it when the feature has no UI.
-
-## Input
-
-The screens to sketch, from the gathered source and the `02-explore` context (the existing screens and components).
-
-## Output
-
-A low-fidelity ASCII wireframe of each screen, its regions and key elements in place, with a numbered note per region. Structure only, no behavior, no styling, no final copy.
-
-## Process
-
-1. **Pick.** List the screens the feature needs. Skip the action entirely when there is no UI.
-2. **Draw.** Sketch each screen per [wireframe-conventions.md](../references/wireframe-conventions.md). The wireframe feeds the plan.
-
-## Test
-
-- The output is a box-drawing wireframe of each screen with numbered regions and a one-line note each, carrying no behavior, styling, or final copy.
diff --git a/plugins/aidd-dev/skills/01-plan/actions/04-plan.md b/plugins/aidd-dev/skills/01-plan/actions/04-plan.md
index e6f0677ce..685c1526c 100644
--- a/plugins/aidd-dev/skills/01-plan/actions/04-plan.md
+++ b/plugins/aidd-dev/skills/01-plan/actions/04-plan.md
@@ -4,7 +4,7 @@ Turn the explored source into a plan and its phases, save them, then review the
## Input
-The explore output from `02-explore` (projection, rules, feasibility, risks), plus any confirmed wireframe from `03-wireframe`.
+The explore output from `02-explore` (projection, rules, feasibility, risks), plus the verified UI contract reference or compatibility wireframe from `03-experience` for frontend work.
## Output
@@ -14,9 +14,13 @@ A feature folder, always at `aidd_docs/tasks//_/_ {baseline restored}: 5: {channel}
```
-## Wireframe
+## UI Contract
+- Contract: `{project-relative ui.md path}@{revision}`
+- Systems: {system ids and revisions}
+- Implement deltas: {approved delta paths owned by this phase or none}
+- Consume deltas: {verified delta paths and approved delta paths owned by an earlier phase, or none}
+- Depends on phases: {owners of consumed approved deltas or none}
+
+## Wireframe
+
+
+
```txt
-{the confirmed wireframe}
+{structure-only wireframe}
```
## Tasks to do
diff --git a/plugins/aidd-dev/skills/01-plan/references/wireframe-conventions.md b/plugins/aidd-dev/skills/01-plan/references/wireframe-conventions.md
index 1dfb23947..14a9c4331 100644
--- a/plugins/aidd-dev/skills/01-plan/references/wireframe-conventions.md
+++ b/plugins/aidd-dev/skills/01-plan/references/wireframe-conventions.md
@@ -1,28 +1,8 @@
# Wireframe conventions
-A wireframe is a low-fidelity ASCII sketch of a screen. Structure only: no behavior, no styling, no final copy.
+Compatibility fallback used only when no UI decision provider is installed.
-## Drawing
-
-- One box per screen, drawn with `┌ ─ ┐ │ └ ┘`.
-- Place the regions (header, nav, main, aside, footer) and the key elements (lists, forms, cards, buttons, inputs) where they sit.
-- Number each region.
-- Under the sketch, one line per number on what it holds and why.
-
-## Example
-
-```
-┌─────────────────────────────────────┐
-│ (1) Header: logo · search · account │
-├──────────┬──────────────────────────┤
-│ (2) Nav │ (3) Results list │
-│ filters │ ┌──────────────────────┐ │
-│ by type │ │ (4) Result card │ │
-│ │ └──────────────────────┘ │
-└──────────┴──────────────────────────┘
-```
-
-1. Header: brand, global search, account menu.
-2. Nav: filters that narrow the list.
-3. Results: the matched items, paginated.
-4. Card: one result, title and summary.
+- Draw one ASCII box per screen with numbered regions.
+- Show regions and key elements in place.
+- Add one line per number explaining its structural role.
+- Include no behavior, state, styling, final copy, accessibility verdict, adaptation rule, or shared-system decision.
diff --git a/plugins/aidd-dev/skills/02-implement/actions/01-prepare.md b/plugins/aidd-dev/skills/02-implement/actions/01-prepare.md
index 7e99042de..63c209fe5 100644
--- a/plugins/aidd-dev/skills/02-implement/actions/01-prepare.md
+++ b/plugins/aidd-dev/skills/02-implement/actions/01-prepare.md
@@ -13,11 +13,25 @@ The resolved plan on a feature branch with its frontmatter `status: in-progress`
## Process
1. **Resolve.** Resolve the plan from the arguments. A path must exist and be readable. With neither a readable file nor inline content, stop with `plan not found at `. Never fabricate a plan.
-2. **Branch.** On the default branch, create a feature branch and announce it. On a non-default branch, keep it.
-3. **Mark.** Set the plan frontmatter `status: in-progress` as a runtime marker. No separate commit: it rides into the first phase commit, or into the `implemented` commit if there is no phase to code.
+2. **Revalidate UI.** Validate every referenced UI contract, system revision, and delta before mutation.
+ - Stop when the UI contract's feature folder contains `.ui.lock`.
+ - Require a current ready contract and current active system revisions.
+ - Permit a no-base establishment only without a current matching id or equal or unorderable active scope overlap.
+ - Permit `systems: []` when the contract proves no shared system decision applies.
+ - Require each approved delta in one `Implement deltas` owner phase.
+ - Require verified deltas only under `Consume deltas`.
+ - Permit an already-satisfied approved delta only when its owner phase is done in this plan.
+ - Stop with `replan needed` for any stale, invalid, changed, competing, or misowned reference.
+3. **Branch.** On the default branch, create a feature branch and announce it. On a non-default branch, keep it.
+4. **Mark.** Set the plan frontmatter `status: in-progress` as a runtime marker. No separate commit: it rides into the first phase commit, or into the `implemented` commit if there is no phase to code.
## Test
- A missing or unreadable plan with no inline content stops with `plan not found at `, and no plan is fabricated.
+- Stale UI references stop with `replan needed` before branch or status mutation.
+- Delta ownership is complete and unique before branch or status mutation.
+- A no-base establishment delta fails when a current matching id or equal or unorderable active scope overlap appears.
+- An in-flight UI contract fails while `.ui.lock` exists.
+- A contract without a shared system passes only when no shared system decision applies.
- The current branch is not the default branch.
- The plan frontmatter reads `status: in-progress`.
diff --git a/plugins/aidd-dev/skills/02-implement/actions/02-execute.md b/plugins/aidd-dev/skills/02-implement/actions/02-execute.md
index 2c531ffb4..019f01387 100644
--- a/plugins/aidd-dev/skills/02-implement/actions/02-execute.md
+++ b/plugins/aidd-dev/skills/02-implement/actions/02-execute.md
@@ -12,10 +12,11 @@ Every phase coded, asserted, and its frontmatter marked `status: done`, with the
## Process
-1. **Open.** Walk the phases in order. In a feature folder each is a `phase-.md` next to `plan.md`. Set its `status: in-progress` as a runtime marker; no commit yet.
-2. **Code.** Build the phase scope against its acceptance criteria.
-3. **Assert.** Assert the phase against its acceptance criteria. On failure, repair and repeat. The gate is the assertion passing, not a self-report. Once it passes, set `status: done` and commit the phase as one unit, its code and its status together.
-4. **Guard.** Stop the loop on either condition:
+1. **Open.** Walk the phases in order. In a feature folder each is a `phase-.md` next to `plan.md`. Open every referenced UI contract, exact system revision, and required delta before setting the phase `status: in-progress`.
+2. **Revalidate.** Apply the prepare gate again immediately before each phase, including absence of a competing active contract for establishment. Any changed status, base, revision, body, scope ownership, or missing dependency returns `replan needed` without editing the phase.
+3. **Code.** Build the phase scope against its acceptance criteria and the complete referenced UI contract. Implement only approved deltas listed under `Implement deltas`; each must be owned by exactly this phase. Treat verified deltas and approved deltas owned by completed phases as read-only dependencies. Missing or duplicate ownership returns `replan needed`.
+4. **Assert.** Assert the phase against its acceptance criteria, UI contract behaviors, and delta verification conditions. On failure, repair and repeat. The gate is the assertion passing, not a self-report. Once it passes, set `status: done` and commit the phase as one unit, its code and its status together. Delta verification remains an explicit `01-system reconcile` operation; do not edit delta status locally.
+5. **Guard.** Stop the loop on either condition:
- **Blocked** (see [blocked.md](../references/blocked.md)): set the plan `status: blocked`, commit, stop.
- **Drift**: any mismatch with the plan, trivial or substantive, stop and report `replan needed: `. Never rewrite the plan; replanning is the caller's job.
@@ -24,3 +25,5 @@ Every phase coded, asserted, and its frontmatter marked `status: done`, with the
- A phase reaches `status: done` only after assert passes against its acceptance criteria, in one commit with its code (`git status --short` shows no dangling phase edits).
- The branch holds one commit per phase; there are no separate `in-progress` status commits.
- A blocker leaves the plan `status: blocked` with no later phase run.
+- UI contracts and deltas are opened and asserted, not treated as metadata only.
+- An approved delta is implemented by one phase; a verified delta is never reimplemented.
diff --git a/plugins/aidd-dev/skills/02-implement/actions/03-finalize.md b/plugins/aidd-dev/skills/02-implement/actions/03-finalize.md
index 2943bc426..80b62ef04 100644
--- a/plugins/aidd-dev/skills/02-implement/actions/03-finalize.md
+++ b/plugins/aidd-dev/skills/02-implement/actions/03-finalize.md
@@ -12,10 +12,12 @@ The feature validated green with the plan frontmatter `status: implemented`.
## Process
-1. **Verify.** Run the plan's validation commands and tests. Never format code, never run dev mode.
-2. **Mark.** Every phase done and validation green, set the plan `status: implemented` and commit it.
+1. **Revalidate UI.** Apply the prepare UI graph gate once more, including no competing active contract for an establishment delta. Drift returns `replan needed` before final status mutation.
+2. **Verify.** Run the plan's validation commands and tests. Never format code, never run dev mode.
+3. **Mark.** Every phase done and validation green, set the plan `status: implemented` and commit it.
## Test
- The validation commands exit zero.
- The plan reads `status: implemented`, committed (`git status --short` shows it clean).
+- An implemented establishment remains an approved delta until explicit system reconciliation verifies it.
diff --git a/plugins/aidd-dev/skills/04-audit/SKILL.md b/plugins/aidd-dev/skills/04-audit/SKILL.md
index 768ba5ec8..0e6d9d81a 100644
--- a/plugins/aidd-dev/skills/04-audit/SKILL.md
+++ b/plugins/aidd-dev/skills/04-audit/SKILL.md
@@ -1,6 +1,6 @@
---
name: 04-audit
-description: Audit a codebase read-only across seven quality pillars into one ranked report. Use when the user wants to assess, health-check, or audit a codebase or one pillar. Not for fixing findings, reviewing a change, or checking a feature works.
+description: Audit a codebase read-only across six engineering pillars plus delegated UI experience review. Use when the user wants to assess, health-check, or audit a codebase or one pillar. Not for fixing findings, reviewing a change, or checking a feature works.
argument-hint: scope | pillar
model: opus
---
@@ -19,7 +19,7 @@ Diagnose a codebase against quality pillars and emit one ranked findings report.
| 04 | `dependencies` | dependencies | CVEs, licenses, outdated and unused deps, supply chain |
| 05 | `performance` | performance | N+1 queries, hot paths, bundle size, heavy operations |
| 06 | `tests` | tests | Critical-path coverage, flakiness, test pyramid balance |
-| 07 | `ui` | ui | Loading/error/empty states, visual hierarchy, design-system drift, responsive, a11y |
+| 07 | `ui` | ui | Delegate experience diagnosis to a discovered UI review capability |
Run the one pillar named, or offer all seven when the request is unscoped.
Before running an action, read its file in `actions/`, not only the table or assets.
@@ -28,9 +28,9 @@ Before running an action, read its file in `actions/`, not only the table or ass
- Read-only: diagnose and rank, never edit code.
- Scope: run the one named pillar, or for an unscoped request ask once "all seven pillars, or one?" before running. Never silently default to one pillar, never blind-run all without offering the choice.
-- One folder per run, `aidd_docs/tasks//_audit/`, like a feature folder. Every pillar that runs always writes its own `.md` there, alone or in a full run. A full run additionally writes a merged `report.md`: one Findings table (category = pillar, severity-first), one Top-actions list, and one Coverage section over all seven pillars.
+- One folder per run, `aidd_docs/tasks//_audit/`, like a feature folder. Every engineering pillar that runs writes its own `.md`; delegated UI review keeps its provider-owned report. A full run additionally writes `report.md`: one merged engineering Findings table, one Top-actions list, Coverage over all seven pillars, and a reference to the separate UI report when available.
- Unscannable pillar: skip it, record it under `Coverage > Skipped` with the reason, and never invent findings for it.
-- Every finding row carries a severity, its pillar, a concrete `file:line`, the issue, a suggested fix, and an effort.
+- Every engineering finding row carries a severity, its pillar, a concrete `file:line`, the issue, a suggested fix, and an effort. Delegated UI findings retain the UI provider schema and are never converted into engineering rows.
## Assets
diff --git a/plugins/aidd-dev/skills/04-audit/actions/07-ui.md b/plugins/aidd-dev/skills/04-audit/actions/07-ui.md
index fa3cdb447..da8e31215 100644
--- a/plugins/aidd-dev/skills/04-audit/actions/07-ui.md
+++ b/plugins/aidd-dev/skills/04-audit/actions/07-ui.md
@@ -1,31 +1,26 @@
# 07 - UI audit
-Read-only audit of the `ui` pillar, missing states, design-system drift, responsive gaps, and accessibility. Reports findings, never edits code.
+Compatibility shim that delegates UI experience diagnosis to its owning concern. Contains no UI review logic.
## Input
-An optional scope, a directory or file glob, defaulting to the entire codebase. An optional running-frontend URL enables a runtime axe accessibility pass.
+An optional interface scope, requirement source, and runtime evidence.
## Output
-The `ui` findings, written to `ui.md` in the run's audit folder.
+The non-normative UI review report returned by a discovered provider, or explicit skipped coverage when none is installed.
## Process
-1. **Scope.** Default to the full codebase when no scope is given. Otherwise restrict scanning to the provided glob or directory. When a URL is given, also run a browser-based accessibility pass against the live frontend.
-2. **Scan.** Use static component and markup analysis, plus a runtime axe-style accessibility pass when a URL is given. Stay in this pillar: redesign and implementation fixes are a separate concern.
- - **Missing loading, error, and empty states**: flag UI surfaces (lists, forms, async data areas) with no visible feedback for in-progress loading, failed fetches, or zero-result datasets.
- - **Visual hierarchy**: flag layouts where primary actions are visually subordinate, or where typographic hierarchy (heading levels, heading-to-body contrast) is broken.
- - **Design-token drift**: identify hardcoded colour, spacing, or typography values that deviate from the project's design tokens or component library.
- - **Responsive breakpoint gaps**: flag components or layouts that break or overflow at standard breakpoints (mobile, tablet, desktop), detectable from markup or media queries.
- - **Accessibility (WCAG)**: contrast-ratio failures, missing keyboard navigation, incorrect or absent aria roles and labels, missing `alt` text. Run axe or equivalent against the URL when given, otherwise inspect markup statically.
- - When no URL is given, record "no url provided, runtime a11y pass skipped, static inspection only" in `Coverage > Skipped`. Do not invent runtime findings from static analysis.
-3. **Rate.** Give each finding a severity and an effort per the [audit-template.md](../assets/audit-template.md) legend, with a concrete `file:line`. The category is always `ui`.
-4. **Write.** Fill [audit-template.md](../assets/audit-template.md) into the pillar file: the Findings table (one row per issue, severity-first), the ranked Top actions, and the Coverage section. In a full run, also add the rows to the merged `report.md` in the same folder. Emit the report and stop.
+1. **Discover.** Resolve a capability described as diagnosing and prioritizing experience defects. Never hardcode a sibling provider.
+2. **Delegate.** Supply scope and evidence without adding hierarchy, system, accessibility, or adaptation checks locally.
+3. **Integrate.** Reference the provider report under `Delegated reports` and mark UI scanned in Coverage. Never merge or translate its findings into the engineering Findings table.
+4. **Skip.** When no provider is installed, record `UI review provider unavailable` under Coverage and emit no UI finding.
## Test
-- The output file exists at the reported path.
-- It has the `## Findings`, `## Top actions`, and `## Coverage` sections.
-- Every Findings row carries a severity, category `ui`, a concrete `file:line`, and an effort.
-- Coverage lists `ui` as scanned, and no code was changed.
+- The action contains no independent UI heuristic or verdict.
+- Provider findings and provenance remain unchanged.
+- The merged audit references, rather than rewrites, the provider report.
+- Provider absence is skipped coverage, not a clean UI result.
+- No application source or normative UI artifact changes.
diff --git a/plugins/aidd-dev/skills/04-audit/assets/audit-template.md b/plugins/aidd-dev/skills/04-audit/assets/audit-template.md
index 6566f8ccc..46c82c6d8 100644
--- a/plugins/aidd-dev/skills/04-audit/assets/audit-template.md
+++ b/plugins/aidd-dev/skills/04-audit/assets/audit-template.md
@@ -25,7 +25,7 @@ Severity (shared rubric across every audit pillar, so a full audit ranks consist
- 🟢 minor - nit or cleanup. Fix when convenient.
Effort: `S` (under 1h), `M` (under 1d), `L` (over 1d).
-Category (the audit pillar, one of): `code-quality`, `architecture`, `security`, `dependencies`, `performance`, `tests`, `ui`.
+Category (the engineering pillar, one of): `code-quality`, `architecture`, `security`, `dependencies`, `performance`, `tests`. UI experience findings remain in their delegated report because they use a different evidence and priority contract.
| Sev | Category | Location | Issue | Suggested fix | Effort |
| --- | ------------ | ------------------------- | -------------------------------------- | ------------------------------------ | ------ |
@@ -35,12 +35,16 @@ Category (the audit pillar, one of): `code-quality`, `architecture`, `security`,
## Top actions
-Highest impact first. Each action names the finding rows it resolves and, when a fix is wanted, the act-skill to hand off to (refactor, test, impeccable - the audit itself never edits code).
+Highest impact first. Each action names the finding rows it resolves and, when a fix is wanted, the implementation capability to hand off to. The audit itself never edits code.
1. {{action_1}}
2. {{action_2}}
3. {{action_3}}
+## Delegated reports
+
+- UI experience: {{project-relative ui-review.md path, unavailable, or not requested}}
+
## Coverage
Proves each pillar was examined. A pillar with no findings is still scanned and listed here. A pillar that could not be examined (missing tool or runtime) is listed under Skipped with the reason - never silently dropped.
diff --git a/plugins/aidd-ui/.claude-plugin/plugin.json b/plugins/aidd-ui/.claude-plugin/plugin.json
index 3bf68df5b..949e51813 100644
--- a/plugins/aidd-ui/.claude-plugin/plugin.json
+++ b/plugins/aidd-ui/.claude-plugin/plugin.json
@@ -2,13 +2,17 @@
"$schema": "https://json.schemastore.org/claude-code-plugin-manifest.json",
"name": "aidd-ui",
"version": "0.2.1-alpha.0",
- "description": "ALPHA, not ready for use. UI and UX concern for the AI-Driven Development framework. Use when the user wants to design, review, or improve a frontend interface. Do NOT use for backend-only or non-UI tasks.",
+ "description": "ALPHA. Versioned UI systems, feature experience contracts, evidence reviews, accessibility, and interface adaptation.",
"author": {
"name": "AI-Driven Dev",
"url": "https://github.com/ai-driven-dev"
},
"skills": [
- "./skills/01-hello"
+ "./skills/01-system",
+ "./skills/02-design",
+ "./skills/03-review",
+ "./skills/04-accessibility",
+ "./skills/05-adapt"
],
"keywords": [
"ui",
diff --git a/plugins/aidd-ui/CATALOG.md b/plugins/aidd-ui/CATALOG.md
index 73912f57f..f2d4cd97e 100644
--- a/plugins/aidd-ui/CATALOG.md
+++ b/plugins/aidd-ui/CATALOG.md
@@ -8,7 +8,11 @@ Auto-generated index of skills, agents, references and assets shipped by the `ai
- [`.claude-plugin`](#claude-plugin)
- [`skills`](#skills)
- - [`skills/01-hello`](#skills01-hello)
+ - [`skills/01-system`](#skills01-system)
+ - [`skills/02-design`](#skills02-design)
+ - [`skills/03-review`](#skills03-review)
+ - [`skills/04-accessibility`](#skills04-accessibility)
+ - [`skills/05-adapt`](#skills05-adapt)
---
@@ -20,10 +24,74 @@ Auto-generated index of skills, agents, references and assets shipped by the `ai
### `skills`
-#### `skills/01-hello`
+#### `skills/01-system`
| Group | File | Description |
|-------|------|---|
-| `actions` | [01-greet.md](skills/01-hello/actions/01-greet.md) | - |
-| `-` | [SKILL.md](skills/01-hello/SKILL.md) | `Smoke-test that confirms the aidd-ui plugin loads. Use when the user wants to verify the alpha aidd-ui plugin is installed and reachable. Not for real UI or UX design work.` |
+| `actions` | [01-inspect.md](skills/01-system/actions/01-inspect.md) | - |
+| `actions` | [02-map.md](skills/01-system/actions/02-map.md) | - |
+| `actions` | [03-specialize.md](skills/01-system/actions/03-specialize.md) | - |
+| `actions` | [04-adopt.md](skills/01-system/actions/04-adopt.md) | - |
+| `actions` | [05-establish.md](skills/01-system/actions/05-establish.md) | - |
+| `actions` | [06-extend.md](skills/01-system/actions/06-extend.md) | - |
+| `actions` | [07-retire.md](skills/01-system/actions/07-retire.md) | - |
+| `actions` | [08-reconcile.md](skills/01-system/actions/08-reconcile.md) | - |
+| `actions` | [09-promote.md](skills/01-system/actions/09-promote.md) | - |
+| `assets` | [system-contract.md](skills/01-system/assets/system-contract.md) | - |
+| `assets` | [system-delta.md](skills/01-system/assets/system-delta.md) | - |
+| `references` | [authority.md](skills/01-system/references/authority.md) | - |
+| `references` | [delta-path.md](skills/01-system/references/delta-path.md) | - |
+| `references` | [lifecycle.md](skills/01-system/references/lifecycle.md) | - |
+| `references` | [mutation.md](skills/01-system/references/mutation.md) | - |
+| `references` | [scope.md](skills/01-system/references/scope.md) | - |
+| `-` | [SKILL.md](skills/01-system/SKILL.md) | `Manages versioned shared UI system contracts and change deltas. Use when the user wants to map or govern shared interface conventions as explicit AIDD artifacts. Not for feature decisions, project memory, or source implementation.` |
+
+#### `skills/02-design`
+
+| Group | File | Description |
+|-------|------|---|
+| `actions` | [01-frame.md](skills/02-design/actions/01-frame.md) | - |
+| `actions` | [02-inspect.md](skills/02-design/actions/02-inspect.md) | - |
+| `actions` | [03-specialize.md](skills/02-design/actions/03-specialize.md) | - |
+| `actions` | [04-structure.md](skills/02-design/actions/04-structure.md) | - |
+| `actions` | [05-compose.md](skills/02-design/actions/05-compose.md) | - |
+| `actions` | [06-write.md](skills/02-design/actions/06-write.md) | - |
+| `actions` | [07-verify.md](skills/02-design/actions/07-verify.md) | - |
+| `assets` | [ui-contract.md](skills/02-design/assets/ui-contract.md) | - |
+| `references` | [evidence.md](skills/02-design/references/evidence.md) | - |
+| `references` | [specialists.md](skills/02-design/references/specialists.md) | - |
+| `-` | [SKILL.md](skills/02-design/SKILL.md) | `Creates or revises an AIDD ui.md experience contract. Use when the user wants implementation ready feature UI decisions versioned from product intent and current evidence. Not for shared system governance, review findings, or source implementation.` |
+
+#### `skills/03-review`
+
+| Group | File | Description |
+|-------|------|---|
+| `actions` | [01-inspect.md](skills/03-review/actions/01-inspect.md) | - |
+| `actions` | [02-specialize.md](skills/03-review/actions/02-specialize.md) | - |
+| `actions` | [03-assess.md](skills/03-review/actions/03-assess.md) | - |
+| `actions` | [04-write.md](skills/03-review/actions/04-write.md) | - |
+| `assets` | [review-report.md](skills/03-review/assets/review-report.md) | - |
+| `references` | [findings.md](skills/03-review/references/findings.md) | - |
+| `references` | [fingerprint.md](skills/03-review/references/fingerprint.md) | - |
+| `-` | [SKILL.md](skills/03-review/SKILL.md) | `Produces an evidence pinned AIDD experience review report. Use when the user wants to diagnose and prioritize interface or flow defects before acceptance or rework. Not for implementation correctness or normative contract changes.` |
+
+#### `skills/04-accessibility`
+
+| Group | File | Description |
+|-------|------|---|
+| `actions` | [01-inspect.md](skills/04-accessibility/actions/01-inspect.md) | - |
+| `actions` | [02-specify.md](skills/04-accessibility/actions/02-specify.md) | - |
+| `actions` | [03-evaluate.md](skills/04-accessibility/actions/03-evaluate.md) | - |
+| `references` | [fragments.md](skills/04-accessibility/references/fragments.md) | - |
+| `-` | [SKILL.md](skills/04-accessibility/SKILL.md) | `Returns provider fragments for AIDD UI contracts, system deltas, or reviews. Use when the user wants to define, assess, or confirm accessibility behavior with evidence. Not for overall review priority, artifact composition, or source implementation.` |
+
+#### `skills/05-adapt`
+
+| Group | File | Description |
+|-------|------|---|
+| `actions` | [01-inspect.md](skills/05-adapt/actions/01-inspect.md) | - |
+| `actions` | [02-specify.md](skills/05-adapt/actions/02-specify.md) | - |
+| `actions` | [03-evaluate.md](skills/05-adapt/actions/03-evaluate.md) | - |
+| `references` | [fragments.md](skills/05-adapt/references/fragments.md) | - |
+| `-` | [SKILL.md](skills/05-adapt/SKILL.md) | `Returns context transformation fragments for AIDD UI artifacts. Use when the user wants to define, assess, or confirm behavior across space, input, or platform contexts. Not for task hierarchy, accessibility, or source implementation.` |
diff --git a/plugins/aidd-ui/README.md b/plugins/aidd-ui/README.md
index 868d24cb1..a5bbda78f 100644
--- a/plugins/aidd-ui/README.md
+++ b/plugins/aidd-ui/README.md
@@ -2,27 +2,49 @@
# aidd-ui 🚧 alpha
-UI and UX concern for the AI-Driven Development framework.
+UI experience and shared interface-system decisions for the AI-Driven Development framework.
-> ⚠️ **ALPHA — NOT READY FOR USE.** `0.1.0-alpha.0`. This plugin ships a single smoke-test skill and no real UI/UX capability yet. Do not install it expecting to use it; it exists only to validate the scaffold. APIs, skills, and naming may change or be removed without notice.
+> **Alpha.** Contracts may change, and the plugin remains off the curated install path.
-> Status: alpha (experimental).
+`aidd-ui` owns what an interface and its shared UI system must preserve. It consumes product intent and hands implementation ready decisions to engineering.
-This plugin is in alpha (`0.1.0-alpha.0`). It lives on a dedicated branch off `next` and is registered with `recommended: false`, so it stays off the curated install path until it stabilises and graduates to `main`. While it is not in the published marketplace yet, test it from a local checkout of this branch:
-
-```
-claude --plugin-dir plugins/aidd-ui # zero-marketplace, session-scoped
-# or, persistent:
-/plugin marketplace add . # register this checkout as a local marketplace
-/plugin install aidd-ui@aidd-framework
+```text
+product intent + current evidence
+ → shared UI system contract
+ → feature UI contract
+ → engineering implementation
+ → experience review
```
-Then run `aidd-ui:01-hello` to confirm it loads.
-
-One starter skill today; real UI and UX skills land as the concern stabilises.
+Code is current implementation truth. Project memory is a compact stable map. UI contracts are decision authority.
## Skills
-| Bracket ID | Skill | Description |
-| ---------- | ----- | ----------- |
-| [7.1] | [hello](skills/01-hello/SKILL.md) | Smoke-test skill that confirms the plugin loads. |
+| Skill | Owns | Produces |
+| --- | --- | --- |
+| [system](skills/01-system/SKILL.md) | shared UI system lifecycle | system maps, versioned contracts, and lifecycle deltas |
+| [design](skills/02-design/SKILL.md) | feature experience decisions | versioned `ui.md` |
+| [review](skills/03-review/SKILL.md) | feature experience diagnosis and priority | non-normative `ui-review.md` |
+| [accessibility](skills/04-accessibility/SKILL.md) | accessibility requirements and verdicts | typed specialist fragments |
+| [adapt](skills/05-adapt/SKILL.md) | space, input, and platform transformations | typed specialist fragments |
+
+`01-system` stores the current shared contract at `aidd_docs/ui/systems/.md`, immutable prior revisions under `.history/`, and one task local `system-delta--.md` per proposed change. It decides the system. Engineering implements its sources and verification conditions.
+
+Install explicitly, then invoke the capability matching the decision owner:
+
+```text
+/plugin install aidd-ui@aidd-framework
+/aidd-ui:01-system discover
+/aidd-ui:02-design create
+```
+
+## Boundaries
+
+- Product requirements are consumed, not authored here.
+- Project memory is read only. Drift is reported for a separate refresh.
+- Shared system and feature experience contracts are owned here, not source code.
+- Engineering consumes ready contracts and owns implementation correctness.
+- External design documents are evidence until explicitly adopted.
+- Existing page patterns, composites, primitives, tokens, and layout conventions are reused before extension or creation.
+- Assets may be contracted by role, source, constraints, and acceptance. Binary production remains outside this plugin.
+- No design tool integration, image generation, browser automation, visual regression, component library, or token build pipeline is bundled.
diff --git a/plugins/aidd-ui/skills/01-hello/SKILL.md b/plugins/aidd-ui/skills/01-hello/SKILL.md
deleted file mode 100644
index e3406a95d..000000000
--- a/plugins/aidd-ui/skills/01-hello/SKILL.md
+++ /dev/null
@@ -1,21 +0,0 @@
----
-name: 01-hello
-description: Smoke-test that confirms the aidd-ui plugin loads. Use when the user wants to verify the alpha aidd-ui plugin is installed and reachable. Not for real UI or UX design work.
----
-
-# Skill: hello
-
-Confirm the aidd-ui plugin loads and is reachable.
-
-## Actions
-
-| # | Action | Role |
-| --- | ------- | ------------------------------------------- |
-| 01 | `greet` | Greet the user and confirm the skill works |
-
-Single action skill: run `greet` and return its message.
-Before running an action, read its file in `actions/`, not only the table or assets.
-
-## Prerequisites
-
-- The plugin loaded locally (`claude --plugin-dir plugins/aidd-ui`, or installed from the marketplace).
diff --git a/plugins/aidd-ui/skills/01-hello/actions/01-greet.md b/plugins/aidd-ui/skills/01-hello/actions/01-greet.md
deleted file mode 100644
index 57b1aa825..000000000
--- a/plugins/aidd-ui/skills/01-hello/actions/01-greet.md
+++ /dev/null
@@ -1,15 +0,0 @@
-# 01 - greet
-
-Greet the caller to confirm the skill is reachable.
-
-## Output
-
-A short greeting printed in the chat.
-
-## Process
-
-1. **Print.** Print "Hello from aidd-ui (alpha)."
-
-## Test
-
-- The chat shows the line "Hello from aidd-ui (alpha)."
diff --git a/plugins/aidd-ui/skills/01-system/SKILL.md b/plugins/aidd-ui/skills/01-system/SKILL.md
new file mode 100644
index 000000000..9adc1e1a8
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/SKILL.md
@@ -0,0 +1,65 @@
+---
+name: 01-system
+description: Manages versioned shared UI system contracts and change deltas. Use when the user wants to map or govern shared interface conventions as explicit AIDD artifacts. Not for feature decisions, project memory, or source implementation.
+argument-hint: system request | delta
+---
+
+# UI System
+
+```mermaid
+flowchart LR
+ discover([discover]) --> inspect
+ adopt_request([adopt]) --> inspect
+ establish_request([establish]) --> inspect
+ extend_request([extend]) --> inspect
+ retire_request([retire]) --> inspect
+ reject_request([reject]) --> inspect
+ reconcile_request([reconcile]) --> inspect
+ promote_request([promote]) --> inspect
+ inspect -->|missing target or scope conflict| stopped([stopped])
+ inspect -->|discover| map --> current([system map])
+ inspect -->|adopt, establish, extend, or retire| specialize
+ specialize -->|adopt concern unresolved| unresolved([unresolved])
+ specialize -->|adopt| adopt
+ adopt -->|approval missing| unresolved
+ adopt -->|lock, id, or scope conflict| stopped
+ adopt -->|approved| active([active contract])
+ specialize -->|establish| establish
+ establish -->|lock, id, or scope conflict| stopped
+ establish -->|written| delta([system delta])
+ specialize -->|extend| extend
+ extend -->|reuse sufficient| reused([reuse decision])
+ extend -->|lock or base conflict| stopped
+ extend -->|shared gap| delta
+ specialize -->|retire| retire
+ retire -->|lock or base conflict| stopped
+ retire -->|written| delta
+ inspect -->|reconcile or reject| reconcile
+ inspect -->|promote| reconcile
+ reconcile -->|lock conflict| stopped
+ reconcile -->|classified, rejected, or not promotable| result([reconciliation result])
+ reconcile -->|verified base and promote request| promote
+ promote -->|lock, evidence, base, or write conflict| stopped
+ promote -->|success| promoted([promoted contract])
+```
+
+## Actions
+
+Read only the next action file required by the flow above.
+
+| Action | Does |
+| --- | --- |
+| inspect | resolve system scope and evidence |
+| map | report the current interface system |
+| specialize | obtain applicable specialist decisions |
+| adopt | record an implemented system |
+| establish | authorize a minimum viable system |
+| extend | authorize the smallest shared change |
+| retire | authorize removal of an active system |
+| reconcile | classify contract and implementation drift |
+| promote | merge a verified delta into the contract |
+
+## Transversal rules
+
+- Own versioned shared UI system contracts and their change deltas.
+- Never modify application source or project memory.
diff --git a/plugins/aidd-ui/skills/01-system/actions/01-inspect.md b/plugins/aidd-ui/skills/01-system/actions/01-inspect.md
new file mode 100644
index 000000000..27268fb06
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/01-inspect.md
@@ -0,0 +1,28 @@
+# 01 - Inspect
+
+Resolve the target UI system, its scope, and the evidence needed by the requested operation.
+
+## Input
+
+The project root, target workspace or surface, and system request.
+
+## Output
+
+An evidence map covering matching contracts and deltas, current implementation, project memory, external design documents, conflicts, and missing proof.
+
+## Process
+
+1. **Scope.** Resolve zero or one matching current contract with [scope.md](../references/scope.md).
+2. **Read.** Inspect the matched contract and deltas, then canonical token, theme, style, component, pattern, breakpoint, and asset sources in the target workspace.
+3. **Compare.** Apply [authority.md](../references/authority.md) to project memory and external design documents.
+4. **Classify.** Separate evidenced shared conventions, feature choices, conflicts, and gaps.
+ - When no evidence exists and creation was not requested, report the boundary and stop.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Monorepo | the target resolves zero or one active contract |
+| Contract conflict | both sources remain visible and neither wins silently |
+| Missing memory | inspection completes from contracts and repository evidence |
+| Backend only | no UI artifact is proposed without an explicit creation request |
diff --git a/plugins/aidd-ui/skills/01-system/actions/02-map.md b/plugins/aidd-ui/skills/01-system/actions/02-map.md
new file mode 100644
index 000000000..25df2a8d1
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/02-map.md
@@ -0,0 +1,27 @@
+# 02 - Map
+
+Return the current shared UI system without changing it.
+
+## Input
+
+The evidence map from [01-inspect.md](01-inspect.md) in discover mode.
+
+## Output
+
+A compact system map naming the active contract when present, its revision and scope, canonical implementation sources, confirmed conventions, conflicts, drift, and evidence gaps.
+
+## Process
+
+1. **Select.** Keep shared tokens, layouts, components, states, adaptation rules, accessibility rules, and assets that have direct evidence.
+2. **Reference.** Name canonical source paths instead of copying implementation catalogs or every value.
+3. **Separate.** Keep planned change, drift, stale memory, and unconfirmed evidence outside the map.
+4. **Return.** Return only evidenced categories without writing an artifact.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Active contract | id, revision, scope, and implementation sources are named |
+| Lightweight project | every reported convention cites a source and categories without evidence are absent |
+| External `DESIGN.md` | it is evidence, never adopted automatically |
+| Conflicting systems | ambiguity remains explicit when dominance is unsupported |
diff --git a/plugins/aidd-ui/skills/01-system/actions/03-specialize.md b/plugins/aidd-ui/skills/01-system/actions/03-specialize.md
new file mode 100644
index 000000000..154aabdca
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/03-specialize.md
@@ -0,0 +1,31 @@
+# 03 - Specialize
+
+Obtain applicable shared accessibility and adaptation decisions from their owning capabilities.
+
+## Input
+
+The system evidence map and requested adopt, establish, extend, or retire operation.
+
+## Output
+
+Provider-owned fragments with provenance, plus unresolved concerns.
+
+## Process
+
+1. **Select.** Identify only shared accessibility or context-transformation concerns affected by the requested operation.
+2. **Discover.** Resolve providers at runtime by capability description.
+3. **Invoke.** Request `confirm` for adoption and `define` for a future delta.
+ - Supply scope, nullable system revision, and evidence paths.
+ - Admit only confirmed fragments into an adopted contract.
+4. **Resolve.** Return the provider outcome without rewriting its fields or verdict.
+ - When a required provider cannot run, leave the concern unresolved.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Existing behavior adopted | defective behavior is not canonized as a convention |
+| Conforming behavior adopted | a provider-confirmed rule and its provenance enter the contract |
+| Future shared behavior | provider requirements are preserved in the delta |
+| Provider unavailable | the affected decision stays unresolved |
+| Irrelevant concern | no boilerplate provider call is made |
diff --git a/plugins/aidd-ui/skills/01-system/actions/04-adopt.md b/plugins/aidd-ui/skills/01-system/actions/04-adopt.md
new file mode 100644
index 000000000..b06013583
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/04-adopt.md
@@ -0,0 +1,36 @@
+# 04 - Adopt
+
+Record an implemented shared UI system as an active revision 1 contract.
+
+## Input
+
+An evidence map with no current matching id or ambiguous active scope and implemented shared UI sources.
+
+## Output
+
+`aidd_docs/ui/systems/.md` at revision `1`, filled from [system-contract.md](../assets/system-contract.md).
+
+## Process
+
+1. **Require.** Require a canonical shared source or two evidenced use sites.
+ - Stop for a current matching id or equal or unorderable active scope overlap.
+2. **Draft.** Capture evidenced decisions, source paths, and confirmed fragments from [03-specialize.md](03-specialize.md).
+ - Keep defects and evidence gaps outside the contract.
+3. **Approve.** Require explicit user approval or an authorized caller mandate for the exact contract.
+4. **Lock.** Apply [mutation.md](../references/mutation.md) and repeat the competing-contract check under the lock.
+5. **Write.** Fill the asset with `status: active`, `revision: 1`, `supersedes: null`, normalized scope paths, and implementation sources.
+6. **Verify.** Read the file back and confirm every decision is supported by current implementation evidence.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Shared implementation | the active contract cites canonical sources or repeated use |
+| Partial system | only confirmed shared surfaces are adopted |
+| Specialist defect | it remains outside the accepted contract and is reported |
+| Specialist fragment integrated | its provider name and verdict are unchanged |
+| Competing contract | adoption stops before writing |
+| Nested active scope | a strict child or parent scope remains resolvable by specificity |
+| First system | the exclusive lock works before the systems directory exists |
+| Concurrent mutation | adoption stops without replacing another writer's result |
+| No approval | no active contract is created |
diff --git a/plugins/aidd-ui/skills/01-system/actions/05-establish.md b/plugins/aidd-ui/skills/01-system/actions/05-establish.md
new file mode 100644
index 000000000..cce8d548f
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/05-establish.md
@@ -0,0 +1,38 @@
+# 05 - Establish
+
+Authorize the minimum shared system required when no coherent system exists.
+
+## Input
+
+An explicit shared UI need and an evidence map with no current contract for the proposed id or ambiguous active scope.
+
+## Output
+
+A delta at [delta-path.md](../references/delta-path.md), filled from [system-delta.md](../assets/system-delta.md) with `mode: establish` and `base_revision: null`.
+
+## Process
+
+1. **Lock.** Apply [mutation.md](../references/mutation.md) and rebuild the scope evidence under the lock.
+ - Stop when a current contract has the proposed id or an active contract has an equal or unorderable scope overlap.
+2. **Bound.** Include only conventions required by the stated work.
+ - Do not create a full token taxonomy or component catalog.
+3. **Reuse.** Preserve evidenced local values and patterns before proposing new foundations.
+4. **Draft.** Write the delta with normalized scope, expected sources, specialist fragments, acceptance, constraints, and unresolved items.
+5. **Finalize.** Set the delta lifecycle state.
+ - Without exact authorization, keep `status: draft`.
+ - With exact authorization, record the approval source and set `status: approved`.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| No system | every proposed convention cites a requirement and no unrequested foundation category appears |
+| Retired id exists | establishment stops without overwriting it |
+| Retired different id | its former scope does not block a new system id |
+| Nested active scope | a strict child or parent scope remains resolvable by specificity |
+| Missing specialist decision | the delta stays draft with an unresolved item |
+| Approval | the exact reviewed delta becomes approved |
+| Concurrent mutation | the write stops without replacing another writer's result |
+| Multiple systems | each change has a distinct system and delta filename |
+| First system | the exclusive lock works before the systems directory exists |
+| No implementation | no application source or active contract is created |
diff --git a/plugins/aidd-ui/skills/01-system/actions/06-extend.md b/plugins/aidd-ui/skills/01-system/actions/06-extend.md
new file mode 100644
index 000000000..45e33f9bc
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/06-extend.md
@@ -0,0 +1,32 @@
+# 06 - Extend
+
+Authorize the smallest shared change that satisfies a new UI need.
+
+## Input
+
+An active system contract, its implementation evidence, and an explicit unmet shared need.
+
+## Output
+
+A delta at [delta-path.md](../references/delta-path.md) with `mode: extend` and `base_revision` equal to the active revision.
+
+## Process
+
+1. **Match.** Search existing page patterns, composites, primitives, tokens, and layout conventions in that order.
+ - When the current system closes the need, return reuse and stop.
+2. **Prepare.** Render the smallest extension and any rejected parallel convention in memory.
+3. **Lock.** Apply [mutation.md](../references/mutation.md) and recheck the active base under the lock.
+4. **Draft.** Record target scope, expected sources, affected states, specialist fragments with exact provider names, acceptance conditions, and `status: draft` without implementation code.
+5. **Finalize.** Set the delta lifecycle state.
+ - Without exact authorization, keep `status: draft`.
+ - With exact authorization, record the approval source and set `status: approved`.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Existing surface fits | no delta is written |
+| Extension | unmet need, affected surface, and states are explicit |
+| New primitive | failed reuse and extension options are evidenced |
+| Concurrent change | the delta records the exact active base revision |
+| Concurrent mutation | the write stops without replacing another writer's result |
diff --git a/plugins/aidd-ui/skills/01-system/actions/07-retire.md b/plugins/aidd-ui/skills/01-system/actions/07-retire.md
new file mode 100644
index 000000000..87660da42
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/07-retire.md
@@ -0,0 +1,34 @@
+# 07 - Retire
+
+Authorize removal of an active UI system from scope resolution.
+
+## Input
+
+An active system contract and explicit retirement intent.
+
+## Output
+
+A delta at [delta-path.md](../references/delta-path.md) with `mode: retire`, the active base, dependencies, and migration acceptance.
+
+## Process
+
+1. **Lock.** Apply [mutation.md](../references/mutation.md) and recheck the active base under the lock.
+2. **Confirm.** Require explicit intent to remove or replace the system.
+ - Treat absent usage as evidence, not authorization.
+3. **Trace.** Find UI contracts, active deltas, and implementation sources that still reference the system.
+4. **Plan.** List active consumers as migration dependencies that block verification but not approval.
+5. **Resolve.** Classify the migration outcome.
+ - While the outcome is ambiguous, keep the delta draft.
+ - When the authorized outcome is decommissioning, do not require a replacement.
+6. **Finalize.** Record the exact authorized retirement without deleting contract history.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Active consumers | an approved delta may name them as required migration work |
+| Consumers remain | the delta cannot become verified |
+| Approved replacement | the replacement id and migration conditions are present |
+| No replacement | explicit decommissioning and consumer removal make the outcome complete |
+| Delta written | it contains migration acceptance without changing the contract |
+| Concurrent mutation | the write stops without replacing another writer's result |
diff --git a/plugins/aidd-ui/skills/01-system/actions/08-reconcile.md b/plugins/aidd-ui/skills/01-system/actions/08-reconcile.md
new file mode 100644
index 000000000..d3607f8ca
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/08-reconcile.md
@@ -0,0 +1,35 @@
+# 08 - Reconcile
+
+Classify differences among contracts, deltas, implementation, and memory.
+
+## Input
+
+The evidence map, active contract when present, and relevant system deltas.
+
+## Output
+
+A reconciliation result classifying each difference, plus an authorized delta status transition when proven.
+
+## Process
+
+1. **Classify.** Assign each difference one class from [authority.md](../references/authority.md).
+ - When a delta status may change, apply [mutation.md](../references/mutation.md) and reclassify under the lock.
+2. **Transition.** Apply only a transition allowed by [lifecycle.md](../references/lifecycle.md).
+ - Mark a stale-base delta `superseded` without rebasing it.
+ - Mark an exact draft or approved delta `rejected` only from explicit authorization.
+ - Mark an approved delta `verified` only when every acceptance condition resolves at one implementation commit.
+3. **Record.** Store the commit, verified sources, and evidence for verification.
+ - Leave the delta approved when required runtime proof is unavailable.
+4. **Preserve.** Surface unauthorized code drift without choosing a winner.
+5. **Stop.** Promotion and memory refresh are separate explicit operations.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Approved, code unchanged | classified as pending, not drift |
+| Code matches delta | delta becomes verified with evidence |
+| Runtime unavailable | delta remains approved |
+| Stale base | delta becomes superseded without contract mutation |
+| Explicit rejection | the exact draft or approved delta becomes rejected |
+| Concurrent mutation | status transition stops without replacing another writer's result |
diff --git a/plugins/aidd-ui/skills/01-system/actions/09-promote.md b/plugins/aidd-ui/skills/01-system/actions/09-promote.md
new file mode 100644
index 000000000..0f7ee966a
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/actions/09-promote.md
@@ -0,0 +1,45 @@
+# 09 - Promote
+
+Merge one verified delta into its UI system contract.
+
+## Input
+
+A specific verified system delta and its active base contract when one exists.
+
+## Output
+
+The updated active or retired system contract and the same delta marked `promoted`.
+
+## Process
+
+1. **Lock.** Apply [mutation.md](../references/mutation.md).
+2. **Recheck.** Validate the delta and current contract under the lock against [lifecycle.md](../references/lifecycle.md).
+ - For `establish`, require no current contract with the id and no equal or unorderable active scope overlap.
+ - For `extend`, require every verified source to prove the change against the active base.
+ - For `retire`, require migrated consumers and disconnected old sources.
+ - When retirement declares a replacement, require its implementation sources to resolve.
+ - Do not require an active replacement contract.
+3. **Render.** Prepare the complete contract, archive, and promoted delta bodies in memory.
+ - Establishment creates revision `1` from target scope and verified sources without an archive or history directory.
+ - Extension archives and increments the active contract.
+ - Retirement archives and increments the contract to `retired` while retaining historical source paths.
+4. **Write.** Replace the contract and delta with the ordered, recoverable writes in [mutation.md](../references/mutation.md).
+5. **Read back.** Confirm the archive, contract revision, and promoted delta before releasing the lock.
+6. **Signal.** Report stable-memory drift for a separate refresh.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Verified delta | contract advances exactly one revision |
+| Unresolvable commit or source | promotion fails without mutation |
+| Stale base | promotion fails without mutation |
+| Interrupted write | an exact retry completes promotion and any mismatched state stops for reconciliation |
+| Concurrent promotion | the loser stops without replacing another writer's files |
+| Stale lock | promotion stops and reports the lock without guessing ownership |
+| Retired id establishment | promotion stops without replacing the retired head |
+| Retired different id | its former scope permits establishment of a new id |
+| First revision | establishment creates no empty history directory |
+| Retirement | history remains and status becomes retired |
+| Retired source removed | absence may satisfy retirement verification and the historical path remains in the contract |
+| Pinned old revision | it resolves from the immutable history file |
diff --git a/plugins/aidd-ui/skills/01-system/assets/system-contract.md b/plugins/aidd-ui/skills/01-system/assets/system-contract.md
new file mode 100644
index 000000000..787a485b9
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/assets/system-contract.md
@@ -0,0 +1,54 @@
+---
+id: {system-id}
+revision: {positive integer}
+status: {active | retired}
+scope:
+ - {normalized project-relative UI root}
+sources:
+ - {canonical implementation path}
+supersedes: {system-id@revision or null}
+---
+
+
+
+# UI System: {name}
+
+## Intent
+
+{What this shared system enables and the products or workspaces it serves.}
+
+## Foundations
+
+| Decision | Contract | Evidence |
+| --- | --- | --- |
+| {color, type, spacing, shape, depth, or motion foundation} | {accepted rule} | {canonical source path} |
+
+## Surfaces
+
+| Pattern, component, or token | Contract | States | Source |
+| --- | --- | --- | --- |
+| {shared surface} | {when and how it is used} | {applicable states} | {canonical source path} |
+
+## Adaptation
+
+| Provider | Target and scope | Evidence | Required transformation | Acceptance |
+| --- | --- | --- | --- | --- |
+| {provider provenance} | {space, input, or platform target} | {source} | {shared behavior} | {observable condition} |
+
+## Accessibility
+
+| Provider | Target and scope | Evidence | Required behavior | Acceptance |
+| --- | --- | --- | --- | --- |
+| {provider provenance} | {shared interaction} | {source} | {accessible behavior} | {observable condition} |
+
+## Assets
+
+| Asset family | Role | Canonical source |
+| --- | --- | --- |
+| {icons, imagery, type, or other asset} | {accepted use} | {project path} |
+
+## Deprecations
+
+| Surface | Replacement | Removal condition |
+| --- | --- | --- |
+| {deprecated convention} | {accepted replacement} | {condition} |
diff --git a/plugins/aidd-ui/skills/01-system/assets/system-delta.md b/plugins/aidd-ui/skills/01-system/assets/system-delta.md
new file mode 100644
index 000000000..1bcdf7810
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/assets/system-delta.md
@@ -0,0 +1,63 @@
+---
+id: {delta-id}
+system: {system-id}
+base_revision: {positive integer or null}
+mode: {establish | extend | retire}
+status: {draft | approved | verified | promoted | rejected | superseded}
+approval_source: {user confirmation, orchestrator mandate, or null}
+verification_commit: {commit id or null}
+target_scope:
+ - {normalized project-relative UI root}
+expected_sources:
+ - {planned canonical implementation path}
+verified_sources:
+ - {implemented canonical path or empty until verified}
+---
+
+
+
+# UI System Delta: {title}
+
+## Need
+
+{Explicit requirement and why the active system cannot already satisfy it.}
+
+## Reuse
+
+| Existing surface | Source | Role |
+| --- | --- | --- |
+| {pattern, component, token, or convention} | {project path} | {how it is reused} |
+
+## Change
+
+| Decision | Evidence | Consequence | Rejected alternative |
+| --- | --- | --- | --- |
+| {smallest shared change} | {requirement or implementation evidence} | {contract effect} | {optional rejected parallel convention} |
+
+## States
+
+| State or context | Required behavior | Acceptance |
+| --- | --- | --- |
+| {shared component or pattern state} | {behavior} | {observable condition} |
+
+## Specialist Fragments
+
+| Provider | Concern and scope | Evidence | Required behavior | Acceptance | System impact |
+| --- | --- | --- | --- | --- | --- |
+| {provider} | {accessibility or adaptation target and scope} | {evidence} | {behavior} | {condition} | {impact or none} |
+
+## Dependencies
+
+- {dependent UI contract, implementation source, or replacement system}
+
+## Implementation Constraints
+
+- {constraint without component code or CSS}
+
+## Verification
+
+- {evidence required before promotion}
+
+## Unresolved
+
+- {decision that keeps the delta draft}
diff --git a/plugins/aidd-ui/skills/01-system/references/authority.md b/plugins/aidd-ui/skills/01-system/references/authority.md
new file mode 100644
index 000000000..0bae8ff9a
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/references/authority.md
@@ -0,0 +1,24 @@
+# UI system authority
+
+## Evidence priority
+
+1. explicit user requirement.
+2. approved delta for authorized future behavior.
+3. active UI system contract for accepted shared decisions.
+4. repository code for implemented behavior.
+5. project memory as a compact summary.
+6. external design documents as supporting evidence.
+
+Code wins against memory. Contract and code differences remain visible until reconciliation.
+
+## Difference classes
+
+| Class | Meaning |
+| --- | --- |
+| approved pending change | code has not implemented an approved delta |
+| conforming implementation | code satisfies the active contract or approved delta |
+| unauthorized code drift | code changed shared behavior without authority |
+| stale contract | accepted contract no longer represents intended behavior |
+| stale memory | memory conflicts with current repository evidence |
+| external-document mismatch | supporting design evidence conflicts with authority |
+| scope conflict | contracts match the same target without a unique owner |
diff --git a/plugins/aidd-ui/skills/01-system/references/delta-path.md b/plugins/aidd-ui/skills/01-system/references/delta-path.md
new file mode 100644
index 000000000..0fd449861
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/references/delta-path.md
@@ -0,0 +1,7 @@
+# System delta path
+
+1. Reuse the task folder containing the supplied requirement or UI contract.
+2. Otherwise use an explicit caller supplied task folder.
+3. Otherwise create `aidd_docs/tasks//_/`.
+
+Write the delta there as `system-delta--.md`.
diff --git a/plugins/aidd-ui/skills/01-system/references/lifecycle.md b/plugins/aidd-ui/skills/01-system/references/lifecycle.md
new file mode 100644
index 000000000..4251cc2a8
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/references/lifecycle.md
@@ -0,0 +1,21 @@
+# UI system lifecycle
+
+## Delta states
+
+```text
+draft -> approved -> verified -> promoted
+draft | approved -> rejected
+draft | approved | verified -> superseded
+```
+
+- Editing an approved delta creates a new draft.
+- Verification records one implementation commit and its evidence.
+- Promotion requires a verified delta against the current base.
+- A promoted delta is historical, not a feature dependency.
+
+## Revisions
+
+- The current contract is `aidd_docs/ui/systems/.md`.
+- Its prior body is `.history/@.md`.
+- Resolve current first, then immutable history.
+- Never edit a history file.
diff --git a/plugins/aidd-ui/skills/01-system/references/mutation.md b/plugins/aidd-ui/skills/01-system/references/mutation.md
new file mode 100644
index 000000000..b42ba478e
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/references/mutation.md
@@ -0,0 +1,11 @@
+# System mutation protocol
+
+1. Acquire `.aidd-ui-systems.lock` at the project root with an atomic directory create before re-reading or writing mutable state.
+2. Stop when the lock directory exists. Remove only the lock directory created by this operation.
+3. Re-read the current contract and affected delta under the lock, then validate the requested transition.
+4. Render changed bodies to sibling temporary files on the same filesystem.
+5. Create immutable history with an exclusive create. If the path exists, require its body to match exactly.
+6. Replace each current file by atomic rename. Create `.history/` only when a prior revision must be archived.
+7. Read back every result before releasing the lock.
+
+The project-root lock works before the systems directory exists and serializes scope checks across different ids. Promotion writes the contract before the delta. If interrupted between them, a retry may finish only when the current contract exactly matches the revision rendered from that delta. Any other mismatch stops for reconciliation.
diff --git a/plugins/aidd-ui/skills/01-system/references/scope.md b/plugins/aidd-ui/skills/01-system/references/scope.md
new file mode 100644
index 000000000..ed3e113ac
--- /dev/null
+++ b/plugins/aidd-ui/skills/01-system/references/scope.md
@@ -0,0 +1,11 @@
+# UI system scope
+
+- Store normalized project-relative UI roots.
+- Resolve the most specific active scope.
+- Stop on equal or unorderable overlaps.
+- Permit strict parent and child scopes because the child is more specific.
+- Treat shared packages as sources, not inherited scopes.
+- Do not infer contract inheritance.
+- Block establishment when the id has an active or retired current contract.
+- Block establishment when another active contract has an equal or unorderable overlap.
+- A retired contract with another id does not own an active scope.
diff --git a/plugins/aidd-ui/skills/02-design/SKILL.md b/plugins/aidd-ui/skills/02-design/SKILL.md
new file mode 100644
index 000000000..f118e937b
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/SKILL.md
@@ -0,0 +1,45 @@
+---
+name: 02-design
+description: Creates or revises an AIDD ui.md experience contract. Use when the user wants implementation ready feature UI decisions versioned from product intent and current evidence. Not for shared system governance, review findings, or source implementation.
+argument-hint: create | revise
+---
+
+# UI Design
+
+```mermaid
+flowchart LR
+ create([create]) --> frame
+ revise([revise]) --> frame
+ frame -->|blocking intent gap| stopped([stopped])
+ frame --> inspect
+ inspect -->|no UI target or scope conflict| stopped
+ inspect --> specialize --> structure --> compose --> write --> verify
+ write -->|lock, archive, revision, or recovery conflict| stopped
+ verify -->|lock, receipt, or revision conflict| stopped
+ verify -->|ready| ready([ready contract])
+ verify -->|unresolved| draft([draft contract])
+ verify -->|content defect| compose
+ verify -->|serialization or version defect| write
+```
+
+## Actions
+
+Read only the next action file required by the flow above.
+
+| Action | Does |
+| --- | --- |
+| frame | isolate the feature intent |
+| inspect | resolve existing UI authority |
+| specialize | obtain applicable specialist decisions |
+| structure | define feature structure and states |
+| compose | decide the feature experience |
+| write | record the versioned UI contract |
+| verify | prove contract readiness |
+
+## Transversal rules
+
+- Own feature-local experience decisions.
+- Reference shared system decisions by exact revision.
+- In revise mode, preserve information architecture and task flow unless the source explicitly authorizes changing them.
+- Preserve factual or legal meaning unless the source explicitly authorizes changing it.
+- Never modify application source, UI system contracts, or project memory.
diff --git a/plugins/aidd-ui/skills/02-design/actions/01-frame.md b/plugins/aidd-ui/skills/02-design/actions/01-frame.md
new file mode 100644
index 000000000..8a3fa4b15
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/01-frame.md
@@ -0,0 +1,28 @@
+# 01 - Frame
+
+Isolate the feature intent without recreating product requirements.
+
+## Input
+
+The user's request or requirements artifact, plus `create` or `revise` mode.
+
+## Output
+
+A compact frame naming the contract target, objective, user task, platform, affected surfaces, constraints, sources, and material unknowns.
+
+## Process
+
+1. **Locate.** Reuse the supplied artifact folder or create `aidd_docs/tasks//_/`.
+2. **Extract.** Keep only facts that constrain the interface experience and retain their sources.
+3. **Classify.** Use `create` without a contract and `revise` against an identified revision.
+ - For one material experience unknown, ask one focused question and stop.
+ - Keep other unknowns explicit.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Existing requirements | each frame fact is sourced or explicitly derived |
+| Revise mode | the existing contract id and revision are named |
+| Missing essential fact | design decisions wait for one focused question |
+| Complete frame | it contains no new product requirement or implementation choice |
diff --git a/plugins/aidd-ui/skills/02-design/actions/02-inspect.md b/plugins/aidd-ui/skills/02-design/actions/02-inspect.md
new file mode 100644
index 000000000..abaa219f3
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/02-inspect.md
@@ -0,0 +1,33 @@
+# 02 - Inspect
+
+Resolve the UI authority and implementation evidence for the feature target.
+
+## Input
+
+The frame from [01-frame.md](01-frame.md) and the project root.
+
+## Output
+
+An evidence map naming zero or one active UI system contract, implementation sources, relevant feature patterns, drift, and unresolved shared needs.
+
+## Process
+
+1. **Scope.** Select the affected frontend workspace before reading monorepo root configuration.
+2. **Resolve.** Match the most specific active UI system scope.
+ - Stop on equal or unorderable overlaps.
+ - Treat shared packages as sources, not inherited scopes.
+3. **Confirm.** Compare available evidence with [evidence.md](../references/evidence.md).
+ - Cite paths and behavior without copying source syntax.
+ - When no UI evidence exists and the request does not explicitly create an interface, report the boundary and stop.
+4. **Separate.** Record an unmet shared need as a system-delta dependency.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Active system | its id, revision, scope, and canonical sources are named |
+| Scope conflict | design stops without arbitrarily selecting a contract |
+| Stale memory | repository reality is reported and memory remains unchanged |
+| Shared gap | it becomes a system dependency, not a feature-local convention |
+| Backend only | no interface is invented without explicit intent |
+| Source evidence | it is referenced by path without markup, CSS, or framework excerpts |
diff --git a/plugins/aidd-ui/skills/02-design/actions/03-specialize.md b/plugins/aidd-ui/skills/02-design/actions/03-specialize.md
new file mode 100644
index 000000000..fc509a7ee
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/03-specialize.md
@@ -0,0 +1,28 @@
+# 03 - Specialize
+
+Obtain applicable accessibility and adaptation decisions from their owning capabilities.
+
+## Input
+
+The frame and evidence map.
+
+## Output
+
+Specialist fragments conforming to [specialists.md](../references/specialists.md), plus unverified capabilities.
+
+## Process
+
+1. **Select.** Identify only accessibility and space, input, or platform concerns that materially affect this feature.
+2. **Discover.** Resolve each provider at runtime by capability description.
+3. **Resolve.** Invoke each provider with the frame, nullable system revision, evidence paths, and `define` operation.
+ - Record the exact discovered capability name in every returned fragment.
+ - When a required provider cannot run, mark its concern unverified.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Provider available | every fragment carries its exact discovered capability name |
+| Provider unavailable | the applicable concern is unverified, not inferred |
+| Shared impact | the fragment becomes a system-delta dependency |
+| Irrelevant concern | no boilerplate fragment is requested |
diff --git a/plugins/aidd-ui/skills/02-design/actions/04-structure.md b/plugins/aidd-ui/skills/02-design/actions/04-structure.md
new file mode 100644
index 000000000..d8476b19d
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/04-structure.md
@@ -0,0 +1,29 @@
+# 04 - Structure
+
+Define feature information and interaction structure before visual treatment.
+
+## Input
+
+The frame, evidence map, and specialist fragments.
+
+## Output
+
+A feature structure naming screens, regions, information order, actions, responsibilities, transitions, and applicable states.
+
+## Process
+
+1. **Order.** Arrange information and actions around the stated user task.
+2. **Assign.** Give each feature region one responsibility.
+3. **Model.** Include only applicable default, loading, empty, error, disabled, success, destructive, permission, offline, timeout, localization, and extreme-content states.
+4. **Preserve.** Apply specialist required behavior without changing its verdict.
+5. **Represent.** Select the minimum structural representation.
+ - When spatial relationships remain ambiguous, add a low-fidelity view.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Region or action | it traces to the frame, system, or evidence map |
+| State included | its trigger and observable outcome are named |
+| Specialist behavior | it appears without reinterpretation |
+| Low-fidelity view | it contains structure, not arbitrary styling or final copy |
diff --git a/plugins/aidd-ui/skills/02-design/actions/05-compose.md b/plugins/aidd-ui/skills/02-design/actions/05-compose.md
new file mode 100644
index 000000000..e8a37774e
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/05-compose.md
@@ -0,0 +1,39 @@
+# 05 - Compose
+
+Turn the feature structure into explicit experience decisions.
+
+## Input
+
+The structure, evidence map, active UI system, and specialist fragments.
+
+## Output
+
+Feature-local interface decisions, reused system surfaces, and required system-delta references.
+
+## Process
+
+1. **Reuse.** Apply the reuse order in [evidence.md](../references/evidence.md) to every region and interaction.
+2. **Decide.** Record material feature choices with evidence and consequence.
+ - Include a rejected alternative only when it explains the decision.
+3. **Source.** Reuse existing assets by path or record only the role, constraints, and acceptance required for a missing asset.
+4. **Express.** Specify only evidenced interface copy, hierarchy, visual emphasis, density, alignment, feedback, and motion that implementation must preserve.
+5. **Depend.** Reference an existing delta or leave the shared gap unresolved.
+6. **Compare.** Apply the selected contract mode.
+ - In `revise` mode, record preserved and changed decisions against the prior contract.
+ - In `create` mode, record no superseded contract.
+7. **Bound.** Use system vocabulary without component code, CSS, or framework recipes.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Existing surface fits | it is named at its exact contract revision |
+| Shared gap | a system-delta path is referenced, not duplicated |
+| Feature choice | it remains local to this contract |
+| Interface copy | it traces to intent or system evidence and preserves factual meaning |
+| Feature motion | trigger and feedback role are explicit while the applicable accessibility fragment is preserved |
+| Existing asset | its project path and role are named |
+| Missing asset | role, constraints, and acceptance are explicit without producing a binary |
+| Inapplicable expression | no empty checklist or speculative decision is added |
+| Revise mode | preserved and changed decisions are explicit |
+| Final direction | it contains no production implementation |
diff --git a/plugins/aidd-ui/skills/02-design/actions/06-write.md b/plugins/aidd-ui/skills/02-design/actions/06-write.md
new file mode 100644
index 000000000..16482ed8e
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/06-write.md
@@ -0,0 +1,56 @@
+# 06 - Write
+
+Record the feature experience as a versioned UI contract.
+
+## Input
+
+The frame, feature decisions, specialist fragments, system references, and unresolved items.
+
+## Output
+
+`ui.md` in the feature task folder, filled from [ui-contract.md](../assets/ui-contract.md), plus its id, revision, and SHA-256 body digest.
+
+## Process
+
+1. **Lock.** Acquire `.ui.lock` with an atomic directory create before reading mutable state.
+ - Stop when the lock already exists.
+ - Remove only the lock directory created by this run.
+2. **Version.** Start at revision `1` or increment the exact current revision under the lock.
+ - Set `supersedes` to `@`.
+ - Archive the prior body at `.ui-history/@.md`.
+3. **Pin.** Record each active system revision and required delta path.
+ - `systems: []` is valid when no shared system decision applies.
+ - Omit a future system entry for a no-base establishment only when no current matching id or equal or unorderable active scope overlap exists.
+4. **Integrate.** Place fragments with [specialists.md](../references/specialists.md).
+ - Keep an applicable concern unverified when its exact discovered provider name is absent.
+5. **Status.** Write `status: draft` until [07-verify.md](07-verify.md) publishes the verified body.
+ - Record blocking unknowns or draft, rejected, superseded, stale, or promoted dependencies.
+ - Replace a promoted delta with its new system revision before verification.
+6. **Write.** Render sibling temporary files on the same filesystem, then replace the current contract by atomic rename while the lock is held.
+ - Create an archive with exclusive create only when a prior revision exists.
+ - Require a matching body when the archive path already exists.
+ - Remove asset placeholders and empty optional sections.
+ - Never copy source code or delta bodies into the contract.
+ - If interrupted after archive creation, retry only when the immutable archive matches.
+ - Replace the current contract after an exact retry check.
+7. **Verify.** Read back the archive when applicable and the current contract before releasing the lock.
+ - Return the exact id, revision, and SHA-256 digest read from the published draft.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Contract written | id, revision, draft status, systems, and required deltas are valid |
+| No shared system | a draft contract may use `systems: []` when no shared decision applies |
+| Specialist unavailable | status remains draft and the gap is explicit |
+| Specialist provenance missing | the contract stays draft |
+| Required delta draft | status remains draft |
+| Approved establishment | the draft may omit the not-yet-created system entry |
+| Required delta promoted | pin the promoted system revision and remove the delta before verification |
+| Revision | the prior revision is traceable and not silently lost |
+| Archived revision | its body is immutable and resolves by id and revision |
+| Concurrent revision | the write stops without replacing the newer contract |
+| Existing lock | the write stops without mutation |
+| Interrupted write | an exact retry completes the current write without changing history |
+| Write receipt | id, revision, and digest match the published draft body |
+| Evidence cited | the contract names paths and behavior without copying source syntax |
diff --git a/plugins/aidd-ui/skills/02-design/actions/07-verify.md b/plugins/aidd-ui/skills/02-design/actions/07-verify.md
new file mode 100644
index 000000000..9c7c38dd1
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/actions/07-verify.md
@@ -0,0 +1,47 @@
+# 07 - Verify
+
+Prove the UI contract is internally consistent and publish its readiness atomically.
+
+## Input
+
+The draft `ui.md`, its expected id, revision, and SHA-256 digest from [06-write.md](06-write.md), plus referenced systems, deltas, requirements, and specialist fragments.
+
+## Output
+
+The verified `ui.md` marked `ready`, or a readiness result with the draft and defects routed back to composition or writing.
+
+## Process
+
+1. **Lock.** Acquire `.ui.lock` with an atomic directory create and re-read the current draft.
+ - Stop when the lock already exists.
+ - Remove only the lock directory created by this run.
+ - Stop when id, revision, or SHA-256 body digest differs from the write receipt.
+2. **Resolve.** Resolve every pinned revision and required-delta path.
+ - For a no-base establishment, prove no current contract has its id and no active contract has an equal or unorderable scope overlap.
+ - Permit `systems: []` only when no shared system decision applies.
+3. **Trace.** Confirm each hard requirement maps to a decision or explicit unresolved item and every applicable state has observable behavior.
+4. **Compare.** Confirm specialist fragments and exact provider names with [specialists.md](../references/specialists.md), then prove feature decisions do not redefine shared system rules.
+5. **Classify.** Return `ready`, `draft`, or a fixable defect.
+ - Route content defects to `compose`.
+ - Route serialization or version defects to `write`.
+6. **Reject.** Fail any placeholder, unsupported compliance claim, implementation code, CSS, or framework recipe.
+7. **Finalize.** Apply exactly one classified outcome.
+ - For `ready`, replace only the draft status through a sibling temporary file and atomic rename while the lock is held.
+ - For `ready`, read back the exact verified body and status before releasing the lock.
+ - For `draft` or a defect, leave the contract byte-identical and return the owning action.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Ready contract | all references resolve and no blocking item remains |
+| Ready publication | no `ready` body is visible before all checks pass |
+| Stale system revision | status is draft until explicitly reconciled |
+| Establishment delta | ready only with `base_revision: null`, no current matching id, and no equal or unorderable active scope overlap |
+| No shared system | a ready contract proves its decisions from feature evidence without inventing shared conventions |
+| Specialist fragment | provenance and verdict match the provider output |
+| Missing provider name | the applicable concern prevents ready publication |
+| Final output | only the draft status changes while application source, system contracts, and memory remain unchanged |
+| Verification failure | `ui.md` remains byte-identical and the owning action is named |
+| Existing lock | verification stops without mutation |
+| Concurrent revision | verification stops instead of publishing another run's draft |
diff --git a/plugins/aidd-ui/skills/02-design/assets/ui-contract.md b/plugins/aidd-ui/skills/02-design/assets/ui-contract.md
new file mode 100644
index 000000000..db757db74
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/assets/ui-contract.md
@@ -0,0 +1,81 @@
+---
+id: {feature-id}
+revision: {positive integer}
+status: {draft | ready}
+systems:
+ - id: {system-id}
+ revision: {positive integer}
+required_deltas:
+ - {project-relative system-delta path}
+supersedes: {prior contract id and revision or null}
+---
+
+
+
+# UI Contract: {feature}
+
+## Intent
+
+- User: {target user}
+- Task: {primary task}
+- Outcome: {observable outcome}
+
+## User Flow
+
+{ordered interaction flow}
+
+## Screens
+
+| Screen or region | Responsibility | Primary action |
+| --- | --- | --- |
+| {name} | {one responsibility} | {action} |
+
+## System Reuse
+
+| Surface | System revision | Source | Use |
+| --- | --- | --- | --- |
+| {pattern, composite, primitive, token, or layout} | {system-id@revision} | {project path} | {role} |
+
+## Interaction States
+
+| State | Trigger | Feedback | Recovery or next action |
+| --- | --- | --- | --- |
+| {state} | {trigger} | {observable feedback} | {recovery or next action} |
+
+## Assets
+
+| Role | Source or requirement | Constraints | Acceptance |
+| --- | --- | --- | --- |
+| {feature-local visual role} | {existing source path or required asset} | {content, crop, format, or behavior constraint} | {observable condition} |
+
+## Adaptation
+
+| Provider | Target and scope | Evidence | Required behavior | Acceptance | System impact |
+| --- | --- | --- | --- | --- | --- |
+| {provider} | {target and scope} | {evidence} | {behavior} | {condition} | {impact or none} |
+
+## Accessibility
+
+| Provider | Target and scope | Evidence | Required behavior | Acceptance | System impact |
+| --- | --- | --- | --- | --- | --- |
+| {provider} | {target and scope} | {evidence} | {behavior} | {condition} | {impact or none} |
+
+## UI Decisions
+
+| Decision | Evidence | Consequence | Rejected alternative |
+| --- | --- | --- | --- |
+| {feature choice} | {requirement or convention} | {constraint to preserve} | {optional alternative and reason} |
+
+## Interface Expression
+
+| Decision | Evidence | Acceptance |
+| --- | --- | --- |
+| {applicable copy, hierarchy, emphasis, density, alignment, feedback, or motion decision} | {requirement or system evidence} | {observable condition} |
+
+## Implementation Constraints
+
+- {experience constraint without implementation code}
+
+## Unresolved
+
+- {missing decision and why it blocks readiness}
diff --git a/plugins/aidd-ui/skills/02-design/references/evidence.md b/plugins/aidd-ui/skills/02-design/references/evidence.md
new file mode 100644
index 000000000..f617167ce
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/references/evidence.md
@@ -0,0 +1,22 @@
+# Feature UI evidence
+
+## Decision priority
+
+1. explicit user requirement.
+2. approved system delta for authorized future behavior.
+3. active UI system contract at the pinned revision.
+4. current implementation for present behavior.
+5. confirmed project memory as a compact map.
+6. minimal feature-local decision.
+
+Code wins against memory. A system contract and code mismatch remains visible for system reconciliation. Feature design never chooses a silent winner.
+
+## Reuse order
+
+1. existing page pattern.
+2. existing composite component.
+3. existing primitive.
+4. existing token.
+5. existing layout convention.
+
+External design documents are supporting evidence. They do not replace an active AIDD UI system contract.
diff --git a/plugins/aidd-ui/skills/02-design/references/specialists.md b/plugins/aidd-ui/skills/02-design/references/specialists.md
new file mode 100644
index 000000000..8845d7e80
--- /dev/null
+++ b/plugins/aidd-ui/skills/02-design/references/specialists.md
@@ -0,0 +1,12 @@
+# Specialist integration
+
+| Field | Integration rule |
+| --- | --- |
+| provider | keep the exact discovered capability name |
+| target and scope | keep unchanged |
+| evidence | keep unchanged |
+| required behavior | keep unchanged |
+| acceptance | keep unchanged |
+| system impact | convert only to a delta dependency, never a local rule |
+
+Place fragments in their owned contract section. Never recalculate a specialist decision.
diff --git a/plugins/aidd-ui/skills/03-review/SKILL.md b/plugins/aidd-ui/skills/03-review/SKILL.md
new file mode 100644
index 000000000..65dd75d8a
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/SKILL.md
@@ -0,0 +1,35 @@
+---
+name: 03-review
+description: Produces an evidence pinned AIDD experience review report. Use when the user wants to diagnose and prioritize interface or flow defects before acceptance or rework. Not for implementation correctness or normative contract changes.
+argument-hint: interface | flow
+---
+
+# UI Review
+
+```mermaid
+flowchart LR
+ interface([interface]) --> inspect
+ flow([flow]) --> inspect
+ inspect -->|insufficient evidence| incomplete([incomplete review])
+ inspect --> specialize --> assess --> write
+ write -->|findings| findings([prioritized review])
+ write -->|no defect| clean([review with no findings])
+```
+
+## Actions
+
+Read only the next action file required by the flow above.
+
+| Action | Does |
+| --- | --- |
+| inspect | pin review targets and evidence |
+| specialize | obtain applicable specialist verdicts |
+| assess | diagnose feature experience defects |
+| write | record the nonnormative review |
+
+## Transversal rules
+
+- Own cross-concern task diagnosis and priority.
+- Specialists own accessibility and adaptation verdicts.
+- Treat findings as nonnormative.
+- State assessed and unassessed coverage explicitly.
diff --git a/plugins/aidd-ui/skills/03-review/actions/01-inspect.md b/plugins/aidd-ui/skills/03-review/actions/01-inspect.md
new file mode 100644
index 000000000..f7905f60e
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/actions/01-inspect.md
@@ -0,0 +1,29 @@
+# 01 - Inspect
+
+Pin the interface and evidence being reviewed.
+
+## Input
+
+An existing screen, flow, rendered interface, screenshot, or implementation location.
+
+## Output
+
+An evidence inventory naming the target commit, relevant worktree fingerprint, UI contract revision, system revisions, requirements, observations, paths, and gaps.
+
+## Process
+
+1. **Locate.** Resolve the relevant workspace, interface entry points, task, and requirement source.
+2. **Pin.** Record the current commit, exact artifact revisions, and [fingerprint.md](../references/fingerprint.md) digest.
+3. **Observe.** Prefer rendered behavior over implementation evidence.
+ - Use implementation evidence only for unreachable states.
+4. **Compare.** Report contract, implementation, and memory contradictions without resolving them.
+ - When neither interface nor requirement evidence can be observed, report the missing evidence and stop.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Evidence inventory | each item names a path, revision, commit, or runtime observation |
+| Dirty worktree | the report pins a reproducible fingerprint of relevant changes |
+| Drift | all conflicting sources remain visible |
+| No UI evidence | no experience claim is fabricated |
diff --git a/plugins/aidd-ui/skills/03-review/actions/02-specialize.md b/plugins/aidd-ui/skills/03-review/actions/02-specialize.md
new file mode 100644
index 000000000..a4f1352ab
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/actions/02-specialize.md
@@ -0,0 +1,26 @@
+# 02 - Specialize
+
+Obtain applicable accessibility and adaptation verdicts.
+
+## Input
+
+The pinned evidence inventory.
+
+## Output
+
+Typed specialist finding fragments with provider provenance, plus unassessed applicable concerns.
+
+## Process
+
+1. **Select.** Identify accessibility and space, input, or platform concerns that apply to observed behavior.
+2. **Discover.** Resolve each provider at runtime by capability description.
+3. **Resolve.** Invoke each provider with the pinned target, evidence, and requested `assess` operation.
+ - When a provider cannot run, mark its applicable concern unassessed.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Provider available | its fragment and provenance remain unchanged |
+| Provider unavailable | coverage says unassessed and no verdict is invented |
+| Specialist finding | review may prioritize it but does not rewrite it |
diff --git a/plugins/aidd-ui/skills/03-review/actions/03-assess.md b/plugins/aidd-ui/skills/03-review/actions/03-assess.md
new file mode 100644
index 000000000..b45cfde9b
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/actions/03-assess.md
@@ -0,0 +1,32 @@
+# 03 - Assess
+
+Diagnose feature experience defects and prioritize all owned findings.
+
+## Input
+
+The evidence inventory and specialist fragments.
+
+## Output
+
+A coverage result and findings ordered `blocker`, `important`, then `minor`.
+
+## Process
+
+1. **Evaluate.** Compare observable task behavior with requirements, the UI contract, and pinned system decisions.
+ - Check whether task priority, information order, control affordance, feedback, and required states remain true.
+ - Assess applicable interface copy, hierarchy, visual emphasis, density, alignment, and motion only against explicit evidence.
+2. **Exclude.** Accept accessibility and adaptation findings only from their specialists.
+3. **Prioritize.** Assign overall priority using [findings.md](../references/findings.md) without altering specialist verdicts.
+4. **Bound.** State required behavior and owner without adding implementation steps.
+ - Preserve specialist fields unchanged.
+5. **Report.** Keep evidence gaps separate from findings.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Feature finding | it includes evidence, impact, outcome, owner, and priority |
+| Specialist finding | its content and provenance are unchanged |
+| Aesthetic preference | it is absent without requirement or system evidence |
+| Expression defect | the violated copy, hierarchy, feedback, or motion decision is cited |
+| Technical issue | it appears only through an observable experience consequence |
diff --git a/plugins/aidd-ui/skills/03-review/actions/04-write.md b/plugins/aidd-ui/skills/03-review/actions/04-write.md
new file mode 100644
index 000000000..b02020e69
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/actions/04-write.md
@@ -0,0 +1,28 @@
+# 04 - Write
+
+Record the review without changing normative UI artifacts.
+
+## Input
+
+The pinned evidence, coverage result, and prioritized findings.
+
+## Output
+
+`ui-review.md` beside the supplied task artifact or in `aidd_docs/tasks//_/`, filled from [review-report.md](../assets/review-report.md).
+
+## Process
+
+1. **Pin.** Record the target, commit, relevant-worktree fingerprint, UI contract revision, and UI system revisions.
+2. **Integrate.** Add only overall priority and owner to specialist findings.
+3. **Separate.** List unassessed concerns and unavailable evidence outside findings.
+4. **Write.** Remove placeholders and empty optional sections from the nonnormative report.
+5. **Verify.** Read back the report and confirm no source, contract, system, or memory file changed.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Report written | its evidence target is reproducible from pinned identifiers |
+| Specialist finding | its verdict matches provider output |
+| No findings | coverage and evidence gaps remain explicit |
+| Read-only review | only `ui-review.md` is created or updated |
diff --git a/plugins/aidd-ui/skills/03-review/assets/review-report.md b/plugins/aidd-ui/skills/03-review/assets/review-report.md
new file mode 100644
index 000000000..b654942b5
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/assets/review-report.md
@@ -0,0 +1,40 @@
+---
+target: {project-relative interface target}
+commit: {commit id}
+worktree_fingerprint: {clean or SHA-256 digest from the skill reference}
+ui_contract: {project-relative ui.md path or null}
+ui_revision: {positive integer or null}
+systems:
+ - id: {system-id}
+ revision: {positive integer}
+reviewed_at: {ISO-8601 timestamp}
+normative: false
+---
+
+
+
+# UI Review: {target}
+
+## Coverage
+
+- Assessed: {domains and evidence}
+- Unassessed: {applicable domains and missing evidence or provider}
+
+## Findings
+
+### {priority}: {finding}
+
+- Domain: {feature experience, accessibility, or adaptation}
+- Provider: {review capability or exact specialist provider}
+- Target: {interface target}
+- Scope: {affected state or context}
+- Evidence: {observable evidence}
+- Impact: {user consequence}
+- Required behavior: {behavior that must become true, preserved from specialist when applicable}
+- Acceptance: {observable pass condition supplied by a specialist, when applicable}
+- System impact: {shared impact supplied by a specialist, when applicable}
+- Owner: {capability that owns the correction decision}
+
+## Open Evidence
+
+- {missing observation and why it matters}
diff --git a/plugins/aidd-ui/skills/03-review/references/findings.md b/plugins/aidd-ui/skills/03-review/references/findings.md
new file mode 100644
index 000000000..23774ac53
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/references/findings.md
@@ -0,0 +1,11 @@
+# Review findings
+
+## Priority
+
+| Priority | Threshold |
+| --- | --- |
+| `blocker` | prevents task completion, safe recovery, or essential access |
+| `important` | materially increases error, effort, ambiguity, or exclusion |
+| `minor` | bounded inconsistency or refinement defect |
+
+Each finding contains: `domain`, `finding`, `evidence`, `impact`, `required behavior`, `owner`, and `provenance`. Order by user consequence. Keep independent defects separate.
diff --git a/plugins/aidd-ui/skills/03-review/references/fingerprint.md b/plugins/aidd-ui/skills/03-review/references/fingerprint.md
new file mode 100644
index 000000000..5c64fd678
--- /dev/null
+++ b/plugins/aidd-ui/skills/03-review/references/fingerprint.md
@@ -0,0 +1,11 @@
+# Relevant worktree fingerprint
+
+Return `clean` when the target paths have no tracked or untracked changes.
+
+Otherwise hash these bytes with SHA-256:
+
+1. `git diff --binary HEAD -- `.
+2. each untracked target path in bytewise path order.
+3. a null byte, the project-relative path, a null byte, and the file bytes for each path.
+
+Record the resulting lowercase hexadecimal digest.
diff --git a/plugins/aidd-ui/skills/04-accessibility/SKILL.md b/plugins/aidd-ui/skills/04-accessibility/SKILL.md
new file mode 100644
index 000000000..dda894835
--- /dev/null
+++ b/plugins/aidd-ui/skills/04-accessibility/SKILL.md
@@ -0,0 +1,36 @@
+---
+name: 04-accessibility
+description: Returns provider fragments for AIDD UI contracts, system deltas, or reviews. Use when the user wants to define, assess, or confirm accessibility behavior with evidence. Not for overall review priority, artifact composition, or source implementation.
+argument-hint: define | assess | confirm
+---
+
+# Accessibility
+
+```mermaid
+flowchart LR
+ define([define]) --> inspect
+ assess([assess]) --> inspect
+ confirm([confirm]) --> inspect
+ inspect -->|required evidence missing| unverified([unverified])
+ inspect -->|define| specify --> requirements([requirement fragments])
+ inspect -->|assess or confirm| evaluate
+ evaluate -->|assess| findings([finding fragments])
+ evaluate -->|confirm| rules([confirmed-rule fragments])
+ evaluate -->|none supported| none([no supported fragment])
+```
+
+## Actions
+
+Read only the next action file required by the flow above.
+
+| Action | Does |
+| --- | --- |
+| inspect | collect applicable accessibility evidence |
+| specify | return requirement fragments |
+| evaluate | return findings or confirmed rules |
+
+## Transversal rules
+
+- Own accessibility requirements and verdicts.
+- Do not own overall review priority or artifact composition.
+- Never modify application source, UI artifacts, or project memory.
diff --git a/plugins/aidd-ui/skills/04-accessibility/actions/01-inspect.md b/plugins/aidd-ui/skills/04-accessibility/actions/01-inspect.md
new file mode 100644
index 000000000..2143447d9
--- /dev/null
+++ b/plugins/aidd-ui/skills/04-accessibility/actions/01-inspect.md
@@ -0,0 +1,32 @@
+# 01 - Inspect
+
+Collect accessibility evidence for the target interface.
+
+## Input
+
+An interface proposal or existing interface, its UI system revision when one exists, and the relevant project area.
+
+## Output
+
+The confirmed accessibility bar, interaction model, semantic and state evidence, runtime observations, and evidence gaps.
+
+## Process
+
+1. **Read.** Inspect requirements, shared components, implementation, project-memory pointers, and the pinned UI system when one exists.
+2. **Select.** Keep only semantics, keyboard, focus, naming, contrast, errors, labels, target size, announcements, or reduced motion that apply.
+3. **Observe.** Use runtime evidence when assessing existing behavior that cannot be proven statically.
+4. **Bound.** Classify evidence by the requested mode.
+ - `define`: use requirements and repository evidence when no system exists.
+ - `assess` or `confirm`: mark unavailable runtime evidence unverified.
+ - Any mode: report contract or memory drift without resolving it.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Existing accessibility bar | its exact system revision and sources are named |
+| Runtime unavailable in assess mode | runtime-only behavior is unverified |
+| Prospective behavior in define mode | an observable acceptance condition can resolve it without current runtime proof |
+| No active system | requirements and repository evidence remain usable |
+| Concern irrelevant | it is omitted rather than emitted as boilerplate |
+| Drift | conflicting evidence remains explicit and no artifact changes |
diff --git a/plugins/aidd-ui/skills/04-accessibility/actions/02-specify.md b/plugins/aidd-ui/skills/04-accessibility/actions/02-specify.md
new file mode 100644
index 000000000..c024fdccc
--- /dev/null
+++ b/plugins/aidd-ui/skills/04-accessibility/actions/02-specify.md
@@ -0,0 +1,27 @@
+# 02 - Specify
+
+Define observable accessibility behavior for a proposed interface.
+
+## Input
+
+The proposal and evidence from [01-inspect.md](01-inspect.md).
+
+## Output
+
+Requirement fragments conforming to [fragments.md](../references/fragments.md).
+
+## Process
+
+1. **Align.** Reuse the pinned accessibility bar and existing interaction patterns.
+2. **Specify.** State the user interaction, required behavior, and observable acceptance condition.
+3. **Classify.** Set system impact only for a shared convention change.
+4. **Defer.** List missing evidence or a missing shared system decision outside the fragment.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Fragment produced | every required field is present and evidence is cited |
+| Existing convention fits | no system extension is claimed |
+| Shared behavior changes | system impact names the exact gap, not its solution |
+| Unsupported compliance claim | it is absent |
diff --git a/plugins/aidd-ui/skills/04-accessibility/actions/03-evaluate.md b/plugins/aidd-ui/skills/04-accessibility/actions/03-evaluate.md
new file mode 100644
index 000000000..69d9adb1f
--- /dev/null
+++ b/plugins/aidd-ui/skills/04-accessibility/actions/03-evaluate.md
@@ -0,0 +1,32 @@
+# 03 - Evaluate
+
+Return accessibility findings or confirmed shared rules from observable evidence.
+
+## Input
+
+The requested `assess` or `confirm` mode and evidence from [01-inspect.md](01-inspect.md).
+
+## Output
+
+Fragments conforming to [fragments.md](../references/fragments.md), plus unverified concerns.
+
+## Process
+
+1. **Compare.** Evaluate observed behavior against requirements, pinned conventions, and relevant platform semantics.
+2. **Classify.** Return only the fragment type requested by the mode.
+ - `assess`: emit each defect with its impact and required behavior.
+ - `confirm`: emit a rule only when a canonical shared source or repeated use proves its behavior and scope.
+3. **Exclude.** Keep defects out of confirmed rules and missing evidence outside all fragments.
+4. **Return.** Return the selected outcome.
+ - When no finding or confirmed rule is supported, state that outcome explicitly.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Finding produced | every required field and observable evidence is present |
+| Confirmed shared behavior | a sourced rule and its shared scope are returned |
+| Canonical shared component | its owned behavior may be confirmed before repeated use |
+| Unsupported claim | it is unverified, not a finding |
+| Keyboard or focus defect | the exact control and behavior are named |
+| Wrong mode output | a finding never appears as a confirmed rule |
diff --git a/plugins/aidd-ui/skills/04-accessibility/references/fragments.md b/plugins/aidd-ui/skills/04-accessibility/references/fragments.md
new file mode 100644
index 000000000..bb492c0ae
--- /dev/null
+++ b/plugins/aidd-ui/skills/04-accessibility/references/fragments.md
@@ -0,0 +1,9 @@
+# Accessibility fragments
+
+| Output | Required fields |
+| --- | --- |
+| requirement | provider, target, scope, evidence, required behavior, acceptance, system impact |
+| finding | provider, target, scope, evidence, finding, impact, required behavior, acceptance, system impact |
+| confirmed rule | provider, target, scope, evidence, required behavior, acceptance, system impact |
+
+List missing evidence separately. Never emit an unresolved item as a verdict.
diff --git a/plugins/aidd-ui/skills/05-adapt/SKILL.md b/plugins/aidd-ui/skills/05-adapt/SKILL.md
new file mode 100644
index 000000000..2f306c907
--- /dev/null
+++ b/plugins/aidd-ui/skills/05-adapt/SKILL.md
@@ -0,0 +1,38 @@
+---
+name: 05-adapt
+description: Returns context transformation fragments for AIDD UI artifacts. Use when the user wants to define, assess, or confirm behavior across space, input, or platform contexts. Not for task hierarchy, accessibility, or source implementation.
+argument-hint: define | assess | confirm
+---
+
+# UI Adaptation
+
+```mermaid
+flowchart LR
+ define([define]) --> inspect
+ assess([assess]) --> inspect
+ confirm([confirm]) --> inspect
+ inspect -->|required evidence missing| unverified([unverified])
+ inspect -->|define| specify --> requirements([requirement fragments])
+ inspect -->|assess or confirm| evaluate
+ evaluate -->|assess| findings([finding fragments])
+ evaluate -->|confirm| rules([confirmed-rule fragments])
+ evaluate -->|none supported| none([no supported fragment])
+```
+
+## Actions
+
+Read only the next action file required by the flow above.
+
+| Action | Does |
+| --- | --- |
+| inspect | collect adaptation evidence |
+| specify | return requirement fragments |
+| evaluate | return findings or confirmed rules |
+
+## Transversal rules
+
+- Own transformations across context.
+- Feature design owns invariant task hierarchy.
+- Exclude keyboard operability, focus, minimum target size, and accessibility zoom.
+- Accessibility owns excluded concerns.
+- Never modify application source, UI artifacts, or project memory.
diff --git a/plugins/aidd-ui/skills/05-adapt/actions/01-inspect.md b/plugins/aidd-ui/skills/05-adapt/actions/01-inspect.md
new file mode 100644
index 000000000..f7f578942
--- /dev/null
+++ b/plugins/aidd-ui/skills/05-adapt/actions/01-inspect.md
@@ -0,0 +1,31 @@
+# 01 - Inspect
+
+Collect evidence for interface behavior across space, input, and platform contexts.
+
+## Input
+
+An interface proposal or existing interface, its UI system revision when one exists, and the relevant workspace.
+
+## Output
+
+Confirmed breakpoints, layout primitives, navigation changes, density, overlays, overflow, input behavior, content pressures, runtime observations, and evidence gaps.
+
+## Process
+
+1. **Scope.** Select the affected frontend workspace and interface regions.
+2. **Read.** Inspect configuration, layout primitives, shared patterns, implementation, project-memory pointers, and the pinned UI system when one exists.
+3. **Observe.** Collect space, orientation, pointer, and platform evidence required by the requested mode.
+ - `define`: use requirements and repository evidence when no system exists.
+ - `assess` or `confirm`: mark unobserved contexts unverified.
+4. **Pressure.** Keep only evidenced long-content, localization, and density constraints.
+5. **Bound.** Report drift without resolving it.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Breakpoint named | its system revision and repository source are cited |
+| Runtime observation | context and resulting behavior are named |
+| Monorepo | evidence comes from the affected frontend workspace |
+| No active system | requirements and repository evidence remain usable |
+| Untested context | no behavior is inferred from absence of evidence |
diff --git a/plugins/aidd-ui/skills/05-adapt/actions/02-specify.md b/plugins/aidd-ui/skills/05-adapt/actions/02-specify.md
new file mode 100644
index 000000000..0a06c96ff
--- /dev/null
+++ b/plugins/aidd-ui/skills/05-adapt/actions/02-specify.md
@@ -0,0 +1,27 @@
+# 02 - Specify
+
+Define required interface transformations across contexts.
+
+## Input
+
+The proposal, invariant task hierarchy, and evidence from [01-inspect.md](01-inspect.md).
+
+## Output
+
+Requirement fragments conforming to [fragments.md](../references/fragments.md).
+
+## Process
+
+1. **Preserve.** Keep the feature's primary task and required information available.
+2. **Transform.** Define applicable stacking, collapse, wrapping, persistence, density, overflow, overlay, and input changes.
+3. **Reuse.** Apply pinned breakpoints and layout primitives before reporting system impact.
+4. **Describe.** Use available space and input capability, not arbitrary device models.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Fragment produced | every required field and observable acceptance condition is present |
+| Existing breakpoint fits | no system impact is claimed |
+| New breakpoint needed | an evidenced failure at existing breakpoints is named |
+| Overflow adapts | content access and interaction remain explicit |
diff --git a/plugins/aidd-ui/skills/05-adapt/actions/03-evaluate.md b/plugins/aidd-ui/skills/05-adapt/actions/03-evaluate.md
new file mode 100644
index 000000000..40e149507
--- /dev/null
+++ b/plugins/aidd-ui/skills/05-adapt/actions/03-evaluate.md
@@ -0,0 +1,32 @@
+# 03 - Evaluate
+
+Return adaptation findings or confirmed shared rules from observed behavior.
+
+## Input
+
+The requested `assess` or `confirm` mode and evidence from [01-inspect.md](01-inspect.md).
+
+## Output
+
+Fragments conforming to [fragments.md](../references/fragments.md), plus unverified contexts.
+
+## Process
+
+1. **Compare.** Evaluate observed transformations against requirements, task priority, and pinned conventions.
+2. **Classify.** Return only the fragment type requested by the mode.
+ - `assess`: emit each defect with its impact and required behavior.
+ - `confirm`: emit a rule only when a canonical shared source or repeated use proves its trigger, transformation, and scope.
+3. **Exclude.** Keep defects out of confirmed rules and untested contexts outside all fragments.
+4. **Return.** Return the selected outcome.
+ - When no finding or confirmed rule is supported, state that outcome explicitly.
+
+## Test
+
+| Case | Pass |
+| --- | --- |
+| Finding produced | every required field and observable evidence is present |
+| Confirmed transformation | its trigger, behavior, scope, and source are returned |
+| Canonical shared layout | its owned transformation may be confirmed before repeated use |
+| Existing primitive solves it | the acceptance condition references that primitive |
+| Context untested | no defect is claimed |
+| Wrong mode output | a finding never appears as a confirmed rule |
diff --git a/plugins/aidd-ui/skills/05-adapt/references/fragments.md b/plugins/aidd-ui/skills/05-adapt/references/fragments.md
new file mode 100644
index 000000000..e3a56a043
--- /dev/null
+++ b/plugins/aidd-ui/skills/05-adapt/references/fragments.md
@@ -0,0 +1,9 @@
+# Adaptation fragments
+
+| Output | Required fields |
+| --- | --- |
+| requirement | provider, target, scope, evidence, required behavior, acceptance, system impact |
+| finding | provider, target, scope, evidence, finding, impact, required behavior, acceptance, system impact |
+| confirmed rule | provider, target, scope, evidence, required behavior, acceptance, system impact |
+
+List untested contexts separately. Never emit an unobserved context as a verdict.
diff --git a/scripts/skill-eval.mjs b/scripts/skill-eval.mjs
index fc04ea823..d864afb5f 100644
--- a/scripts/skill-eval.mjs
+++ b/scripts/skill-eval.mjs
@@ -19,10 +19,10 @@
// Local / opt-in only: needs an authenticated `claude` CLI and spends tokens.
// Not a CI gate.
-import { mkdtempSync, mkdirSync, writeFileSync, cpSync, rmSync, readFileSync, existsSync } from "node:fs";
+import { mkdtempSync, mkdirSync, writeFileSync, cpSync, rmSync, readFileSync, existsSync, readdirSync } from "node:fs";
import { tmpdir } from "node:os";
import { join, dirname, resolve } from "node:path";
-import { spawn } from "node:child_process";
+import { execFileSync, spawn } from "node:child_process";
import { fileURLToPath } from "node:url";
const HERE = dirname(fileURLToPath(import.meta.url));
@@ -62,7 +62,11 @@ function runClaude(prompt, cwd) {
child.stdout.on("data", (d) => (out += d));
child.stderr.on("data", (d) => (out += d));
child.on("error", ko);
- child.on("close", () => ok(out));
+ child.on("close", (code, signal) => {
+ if (code === 0 && !signal) return ok(out);
+ const cause = signal ? `signal ${signal}` : `exit ${code}`;
+ ko(new Error(`claude failed with ${cause}\n${out.slice(-2000)}`));
+ });
child.stdin.end();
});
}
@@ -71,6 +75,23 @@ function has(haystack, needle) {
return haystack.toLowerCase().includes(String(needle).toLowerCase());
}
+function snapshotFiles(root) {
+ const files = {};
+ const walk = (rel = "") => {
+ for (const entry of readdirSync(join(root, rel), { withFileTypes: true })) {
+ const next = join(rel, entry.name);
+ if (!rel && [".claude", ".git"].includes(entry.name)) continue;
+ if (entry.isDirectory()) {
+ files[`${next}/`] = "";
+ walk(next);
+ }
+ else if (entry.isFile()) files[next] = readFileSync(join(root, next)).toString("base64");
+ }
+ };
+ walk();
+ return files;
+}
+
// One assertion = { ok: boolean, label: string }
async function evaluate(expect, ctx) {
const checks = [];
@@ -110,6 +131,20 @@ async function evaluate(expect, ctx) {
checks.push({ ok: new RegExp(re, "i").test(ctx.stdout), label: `stdout matches /${re}/` });
}
+ const after = snapshotFiles(ctx.tmp);
+ const allowed = new Set([
+ ...(expect.filesExist || []),
+ ...Object.keys(expect.fileContains || {}),
+ ...Object.keys(expect.fileNotContains || {}),
+ ...(expect.allowMutations || []),
+ ]);
+ for (const name of new Set([...Object.keys(ctx.snapshot), ...Object.keys(after)])) {
+ const allowedDirectory = name.endsWith("/") && [...allowed].some((file) => file.startsWith(name));
+ if (ctx.snapshot[name] !== after[name] && !allowed.has(name) && !allowedDirectory) {
+ checks.push({ ok: false, label: `unexpected mutation: ${name}` });
+ }
+ }
+
if (expect.judge) {
if (!JUDGE) {
checks.push({ ok: true, skipped: true, label: `judge (skipped, pass --judge): ${expect.judge}` });
@@ -128,23 +163,50 @@ async function evaluate(expect, ctx) {
function setupCase(c) {
const tmp = mkdtempSync(join(tmpdir(), "skilleval-"));
- const skillDst = join(tmp, ".claude", "skills", c.evalName);
- mkdirSync(skillDst, { recursive: true });
- cpSync(join(skillsDir(c), c.skill), skillDst, { recursive: true });
- // A skill may run a script its plugin bundles. Stage it next to the skill so
- // the sandbox matches an installed plugin rather than a skill copied alone.
- const hooks = join(ROOT, "plugins", c.plugin || "aidd-refine", "hooks");
- if (existsSync(hooks)) cpSync(hooks, join(skillDst, "hooks"), { recursive: true });
- // Rewrite the frontmatter name so it matches the unique eval folder.
- const skillMd = join(skillDst, "SKILL.md");
- const rewritten = readFileSync(skillMd, "utf8").replace(/^name:.*$/m, `name: ${c.evalName}`);
- writeFileSync(skillMd, rewritten);
+ const setup = { ...(c.setup?.files || {}) };
+ const stageSkill = (spec) => {
+ const plugin = spec.plugin || c.plugin || "aidd-refine";
+ const skillDst = join(tmp, ".claude", "skills", spec.evalName);
+ mkdirSync(skillDst, { recursive: true });
+ cpSync(join(ROOT, "plugins", plugin, "skills", spec.skill), skillDst, { recursive: true });
+ // A skill may run a script its plugin bundles. Stage it next to the skill so
+ // the sandbox matches an installed plugin rather than a skill copied alone.
+ const hooks = join(ROOT, "plugins", plugin, "hooks");
+ if (existsSync(hooks)) cpSync(hooks, join(skillDst, "hooks"), { recursive: true });
+ // Rewrite frontmatter so each staged capability has a unique project name.
+ const skillMd = join(skillDst, "SKILL.md");
+ const rewritten = readFileSync(skillMd, "utf8").replace(/^name:.*$/m, `name: ${spec.evalName}`);
+ writeFileSync(skillMd, rewritten);
+ };
+ stageSkill(c);
+ for (const provider of c.providers || []) stageSkill(provider);
for (const [rel, content] of Object.entries(c.setup?.files || {})) {
const dst = join(tmp, rel);
mkdirSync(dirname(dst), { recursive: true });
writeFileSync(dst, content);
}
- return tmp;
+ if (c.setup?.git) {
+ execFileSync("git", ["init", "-q", "-b", "main"], { cwd: tmp });
+ execFileSync("git", ["config", "user.name", "Skill Eval"], { cwd: tmp });
+ execFileSync("git", ["config", "user.email", "skill-eval@example.invalid"], { cwd: tmp });
+ execFileSync("git", ["add", "."], { cwd: tmp });
+ execFileSync("git", ["commit", "-qm", "fixture"], { cwd: tmp });
+ const commit = execFileSync("git", ["rev-parse", "HEAD"], { cwd: tmp, encoding: "utf8" }).trim();
+ for (const rel of Object.keys(c.setup?.files || {})) {
+ const dst = join(tmp, rel);
+ const content = readFileSync(dst, "utf8");
+ if (content.includes("{{COMMIT}}")) {
+ const resolved = content.replaceAll("{{COMMIT}}", commit);
+ writeFileSync(dst, resolved);
+ setup[rel] = resolved;
+ }
+ }
+ if (execFileSync("git", ["status", "--short"], { cwd: tmp, encoding: "utf8" }).trim()) {
+ execFileSync("git", ["add", "."], { cwd: tmp });
+ execFileSync("git", ["commit", "-qm", "fixture metadata"], { cwd: tmp });
+ }
+ }
+ return { tmp, setup, snapshot: snapshotFiles(tmp) };
}
async function runCase(c) {
@@ -154,10 +216,11 @@ async function runCase(c) {
let checks;
let stdout = "";
try {
- tmp = setupCase(c);
+ const fixture = setupCase(c);
+ tmp = fixture.tmp;
const prompt = c.prompt.replaceAll("{{SKILL}}", c.evalName);
stdout = await runClaude(prompt, tmp);
- checks = await evaluate(c.expect, { tmp, stdout, setup: c.setup?.files || {} });
+ checks = await evaluate(c.expect, { tmp, stdout, setup: fixture.setup, snapshot: fixture.snapshot });
} catch (err) {
checks = [{ ok: false, label: `run error: ${err.message}` }];
}
diff --git a/scripts/skill-eval/cases.json b/scripts/skill-eval/cases.json
index 90aacca46..5d775e93b 100644
--- a/scripts/skill-eval/cases.json
+++ b/scripts/skill-eval/cases.json
@@ -317,5 +317,1568 @@
]
}
}
+ },
+ {
+ "plugin": "aidd-dev",
+ "skill": "01-plan",
+ "evalName": "xeval-dev-plan-ui-contract",
+ "name": "plans frontend work from a ready versioned UI contract",
+ "setup": {
+ "files": {
+ "src/Checkout.jsx": "export function Checkout() { return Current checkout; }\n",
+ "aidd_docs/ui/systems/app.md": "---\nid: app\nrevision: 1\nstatus: active\nscope:\n - src\nsources:\n - src/Checkout.jsx\nsupersedes: null\n---\n\n# UI System: App\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/requirement.md": "# Checkout\n\nImplement the approved checkout interface contract.\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/ui.md": "---\nid: checkout\nrevision: 2\nstatus: ready\nsystems:\n - id: app\n revision: 1\nrequired_deltas: []\nsupersedes: checkout@1\n---\n\n# UI Contract: Checkout\n\n## Intent\n\n- Task: submit payment and recover from errors\n\n## Interaction States\n\n| State | Trigger | Feedback | Recovery or next action |\n| --- | --- | --- | --- |\n| pending | submit | Processing | wait |\n| error | payment fails | inline error | retry |\n"
+ }
+ },
+ "prompt": "Use the {{SKILL}} skill to plan aidd_docs/tasks/2026_08/2026_08_23_checkout/requirement.md. This is frontend work and its current ready UI contract is beside the requirement. Run headlessly, consume that contract without redesigning it, and write the plan and phases in the same task folder.",
+ "expect": {
+ "filesExist": [
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/plan.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md"
+ ],
+ "filesUnchanged": [
+ "src/Checkout.jsx",
+ "aidd_docs/ui/systems/app.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/requirement.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/ui.md"
+ ],
+ "fileContains": {
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md": [
+ "## UI Contract",
+ "ui.md@2",
+ "app@1"
+ ]
+ },
+ "fileNotContains": {
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md": [
+ "## Wireframe"
+ ]
+ },
+ "judgeFiles": [
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/plan.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md"
+ ],
+ "judge": "The implementation plan consumes checkout ui.md revision 2 and app system revision 1, preserves the experience decisions by reference, and does not invent a wireframe or modify normative UI artifacts."
+ }
+ },
+ {
+ "plugin": "aidd-dev",
+ "skill": "02-implement",
+ "evalName": "xeval-dev-implement-ui-drift",
+ "name": "stops before implementation when a UI dependency drifts",
+ "setup": {
+ "files": {
+ "src/Checkout.jsx": "export function Checkout() { return unchanged; }\n",
+ "aidd_docs/ui/systems/app.md": "---\nid: app\nrevision: 2\nstatus: active\nscope:\n - src\nsources:\n - src/Checkout.jsx\nsupersedes: app@1\n---\n\n# UI System: App\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/ui.md": "---\nid: checkout\nrevision: 3\nstatus: ready\nsystems:\n - id: app\n revision: 2\nrequired_deltas:\n - aidd_docs/tasks/2026_08/2026_08_23_checkout/system-delta-app-errors.md\nsupersedes: checkout@2\n---\n\n# UI Contract: Checkout\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/system-delta-app-errors.md": "---\nid: errors\nsystem: app\nbase_revision: 1\nmode: extend\nstatus: superseded\napproval_source: user\nverification_commit: null\ntarget_scope:\n - src\nexpected_sources:\n - src/Checkout.jsx\nverified_sources: []\n---\n\n# UI System Delta: Errors\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/plan.md": "---\nobjective: Implement checkout\nstatus: pending\n---\n\n# Plan: Checkout\n\n## Phases\n\n| # | Phase | File |\n| --- | --- | --- |\n| 1 | checkout | [phase-1.md](./phase-1.md) |\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md": "---\nstatus: pending\n---\n\n# Instruction: Checkout\n\n## UI Contract\n\n- Contract: `aidd_docs/tasks/2026_08/2026_08_23_checkout/ui.md@3`\n- Systems: app@2\n- Implement deltas: aidd_docs/tasks/2026_08/2026_08_23_checkout/system-delta-app-errors.md\n- Consume deltas: none\n- Depends on phases: none\n"
+ }
+ },
+ "prompt": "Use the {{SKILL}} skill on aidd_docs/tasks/2026_08/2026_08_23_checkout/plan.md. Revalidate the referenced UI graph before any implementation and stop deterministically on drift.",
+ "expect": {
+ "filesUnchanged": [
+ "src/Checkout.jsx",
+ "aidd_docs/ui/systems/app.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/ui.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/system-delta-app-errors.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/plan.md",
+ "aidd_docs/tasks/2026_08/2026_08_23_checkout/phase-1.md"
+ ],
+ "stdoutContains": [
+ "replan needed",
+ "superseded"
+ ],
+ "judge": "Implementation stops before branch, status, phase, or source mutation because a required UI system delta is superseded."
+ }
+ },
+ {
+ "plugin": "aidd-ui",
+ "skill": "02-design",
+ "evalName": "xeval-ui-design",
+ "name": "designs from a lightweight UI and explicit visual direction",
+ "providers": [
+ {
+ "plugin": "aidd-ui",
+ "skill": "04-accessibility",
+ "evalName": "xeval-ui-a11y-provider"
+ },
+ {
+ "plugin": "aidd-ui",
+ "skill": "05-adapt",
+ "evalName": "xeval-ui-adapt-provider"
+ }
+ ],
+ "setup": {
+ "files": {
+ "package.json": "{ \"name\": \"orders\", \"dependencies\": { \"react\": \"^19.0.0\" } }\n",
+ "public/warehouse-mark.png": "existing-asset-fixture\n",
+ "src/App.jsx": "export function App() { return
Orders
; }\n",
+ "src/styles.css": ".page { max-width: 60rem; margin: 0 auto; padding: 1rem; }\nbutton { min-height: 44px; }\nbutton:focus-visible { outline: 2px solid currentColor; }\n@media (min-width: 48rem) { .page { padding: 2rem; } }\n",
+ "aidd_docs/tasks/2026_08/2026_08_23_order_search/requirements.md": "# Order search\n\nWarehouse operators use a keyboard, not a scanner, to repeatedly search by order ID. Search stays primary. Results show order ID, status, destination, and Review. Use exact result status copy `Ready to review`. Cover loading, empty, recoverable error, and result states. Reveal fresh results with a motion cue as feedback, but remove that cue under the reduced-motion preference. Long IDs remain fully accessible. Below the existing 48rem breakpoint, stack result metadata while keeping Review adjacent to its order. Every field has a persistent label and status feedback is announced. Reuse `public/warehouse-mark.png` in the header. The empty state requires a feature-local illustration that depicts an empty sorting tray, remains legible at constrained widths, and has an acceptance requirement, but no binary asset is supplied or requested from this capability. Use a brutalist visual direction.\n"
+ }
+ },
+ "prompt": "Use the {{SKILL}} skill in create mode with aidd_docs/tasks/2026_08/2026_08_23_order_search/requirements.md. Discover and use the installed accessibility and adaptation providers. Write aidd_docs/tasks/2026_08/2026_08_23_order_search/ui.md. You are running headless: do not ask questions or implement code.",
+ "expect": {
+ "filesExist": [
+ "aidd_docs/tasks/2026_08/2026_08_23_order_search/ui.md"
+ ],
+ "filesUnchanged": [
+ "package.json",
+ "public/warehouse-mark.png",
+ "src/App.jsx",
+ "src/styles.css",
+ "aidd_docs/tasks/2026_08/2026_08_23_order_search/requirements.md"
+ ],
+ "filesAbsent": [
+ "aidd_docs/memory/design.md",
+ "public/order-empty.png"
+ ],
+ "fileContains": {
+ "aidd_docs/tasks/2026_08/2026_08_23_order_search/ui.md": [
+ "status: ready",
+ "brutalist",
+ "loading",
+ "empty",
+ "error",
+ "Ready to review",
+ "public/warehouse-mark.png",
+ "empty sorting tray",
+ "fresh results",
+ "feedback",
+ "reduced-motion",
+ "Accessibility",
+ "Adaptation",
+ "xeval-ui-a11y-provider",
+ "xeval-ui-adapt-provider"
+ ]
+ },
+ "fileNotContains": {
+ "aidd_docs/tasks/2026_08/2026_08_23_order_search/ui.md": [
+ "{feature-id}",
+ "