@mmerterden/multi-agent-pipeline 12.4.0 → 12.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/CHANGELOG.md +169 -0
  2. package/README.md +1 -1
  3. package/docs/features.md +20 -0
  4. package/index.js +7 -1
  5. package/install/_dev-only-files.mjs +1 -0
  6. package/package.json +4 -3
  7. package/pipeline/agents/security-auditor.md +1 -1
  8. package/pipeline/commands/archive-guard.md +5 -5
  9. package/pipeline/commands/multi-agent/SKILL.md +2 -0
  10. package/pipeline/commands/multi-agent/design-check/SKILL.md +287 -0
  11. package/pipeline/commands/multi-agent/help/SKILL.md +45 -5
  12. package/pipeline/commands/multi-agent/refactor/SKILL.md +92 -12
  13. package/pipeline/commands/multi-agent/review/SKILL.md +1 -1
  14. package/pipeline/commands/multi-agent/sync/SKILL.md +119 -12
  15. package/pipeline/commands/multi-agent/test/SKILL.md +1 -1
  16. package/pipeline/commands/sim-test.md +5 -5
  17. package/pipeline/lib/credential-store.sh +32 -0
  18. package/pipeline/lib/extract-conventions.sh +1 -0
  19. package/pipeline/lib/repo-cache.sh +1 -0
  20. package/pipeline/lib/shadow-git.sh +8 -0
  21. package/pipeline/multi-agent-refs/cross-cli-contract.md +3 -3
  22. package/pipeline/multi-agent-refs/phases/phase-0-init.md +9 -1
  23. package/pipeline/multi-agent-refs/phases/phase-3-dev.md +2 -2
  24. package/pipeline/multi-agent-refs/phases/phase-4-review.md +3 -2
  25. package/pipeline/multi-agent-refs/phases/phase-5-test.md +14 -4
  26. package/pipeline/multi-agent-refs/phases.md +2 -0
  27. package/pipeline/multi-agent-refs/prompt-assembly.md +31 -0
  28. package/pipeline/preferences-template.json +18 -1
  29. package/pipeline/schemas/agent-state.schema.json +90 -0
  30. package/pipeline/schemas/design-check-config.schema.json +162 -0
  31. package/pipeline/schemas/learnings-ledger.schema.json +4 -0
  32. package/pipeline/schemas/migrations/state-2.0.0-to-2.1.0.mjs +30 -12
  33. package/pipeline/schemas/prefs.schema.json +161 -5
  34. package/pipeline/schemas/token-budget.json +2 -2
  35. package/pipeline/schemas/triage-corpus.schema.json +5 -1
  36. package/pipeline/scripts/README.md +7 -5
  37. package/pipeline/scripts/classify-plan-safety.mjs +8 -3
  38. package/pipeline/scripts/cost-budget-check.mjs +9 -5
  39. package/pipeline/scripts/eval-mine-corpus.mjs +19 -5
  40. package/pipeline/scripts/fixtures/install-layout.tsv +7 -7
  41. package/pipeline/scripts/gc-worktrees.sh +23 -1
  42. package/pipeline/scripts/learning-curve.mjs +167 -0
  43. package/pipeline/scripts/learnings-ledger.mjs +27 -2
  44. package/pipeline/scripts/lint-mcp-refs.mjs +207 -0
  45. package/pipeline/scripts/memory-load.sh +5 -1
  46. package/pipeline/scripts/render-work-summary.sh +4 -1
  47. package/pipeline/scripts/repo-map.mjs +1 -1
  48. package/pipeline/scripts/smoke-command-inventory.sh +81 -0
  49. package/pipeline/scripts/smoke-commands-skills-parity.sh +1 -1
  50. package/pipeline/scripts/smoke-compliance-skills.sh +4 -4
  51. package/pipeline/scripts/smoke-cross-cli-behavior.sh +12 -2
  52. package/pipeline/scripts/smoke-generate-issue.sh +6 -5
  53. package/pipeline/scripts/smoke-learning-curve.sh +61 -0
  54. package/pipeline/scripts/smoke-per-repo-memory.sh +2 -2
  55. package/pipeline/scripts/smoke-review-readiness.sh +3 -2
  56. package/pipeline/scripts/smoke-schema-validation.sh +19 -5
  57. package/pipeline/scripts/smoke-shadow-git.sh +4 -2
  58. package/pipeline/scripts/triage-memory.mjs +66 -10
  59. package/pipeline/scripts/uninstall.mjs +1 -1
  60. package/pipeline/skills/.skill-manifest.json +24 -8
  61. package/pipeline/skills/.skills-index.json +39 -3
  62. package/pipeline/skills/shared/README.md +10 -6
  63. package/pipeline/skills/shared/core/apple-archive-compliance/SKILL.md +10 -8
  64. package/pipeline/skills/shared/core/multi-agent-design-check/SKILL.md +248 -0
  65. package/pipeline/skills/shared/core/multi-agent-help/SKILL.md +22 -0
  66. package/pipeline/skills/shared/core/multi-agent-refactor/SKILL.md +67 -11
  67. package/pipeline/skills/shared/core/multi-agent-review/SKILL.md +1 -1
  68. package/pipeline/skills/shared/core/multi-agent-sync/SKILL.md +51 -9
  69. package/pipeline/skills/shared/core/multi-agent-test/SKILL.md +1 -1
  70. package/pipeline/skills/skills-index.md +8 -4
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "schemaVersion": "1.0.0",
3
- "skillCount": 189,
3
+ "skillCount": 193,
4
4
  "entries": [
5
5
  {
6
6
  "name": "accessibility-compliance-accessibility-audit",
@@ -794,6 +794,15 @@
794
794
  "triggerPaths": [],
795
795
  "relativePath": "shared/core/multi-agent-create-jira/SKILL.md"
796
796
  },
797
+ {
798
+ "name": "multi-agent-design-check",
799
+ "description": "Mock-mode vs Figma design audit (iOS / Android, local-only). Pick repo + module, gate on mock support, enumerate every state driver into a countable target set, build Debug in a worktree, launch in mock mode, fetch Figma variants, compare each pixel + px-spacing + typography + color, and export a si",
800
+ "platform": null,
801
+ "group": "core",
802
+ "triggerKeywords": [],
803
+ "triggerPaths": [],
804
+ "relativePath": "shared/core/multi-agent-design-check/SKILL.md"
805
+ },
797
806
  {
798
807
  "name": "multi-agent-dev",
799
808
  "description": "Fast development mode: Init → Dev (Opus) → Test → Commit → Report. Analysis, planning, and review phases are skipped.",
@@ -848,6 +857,15 @@
848
857
  "triggerPaths": [],
849
858
  "relativePath": "shared/core/multi-agent-finish/SKILL.md"
850
859
  },
860
+ {
861
+ "name": "multi-agent-forget",
862
+ "description": "Remove a saved /multi-agent routine (created by /multi-agent:save): deletes its local-only command and its registry entry. Asks which one and confirms.",
863
+ "platform": null,
864
+ "group": "core",
865
+ "triggerKeywords": [],
866
+ "triggerPaths": [],
867
+ "relativePath": "shared/core/multi-agent-forget/SKILL.md"
868
+ },
851
869
  {
852
870
  "name": "multi-agent-garbage-collect",
853
871
  "description": "Sweep leftover /tmp scratch (picker state, review diffs, channel payloads, analysis drafts) from past runs. Dry-run first; confirms before deleting.",
@@ -958,7 +976,7 @@
958
976
  },
959
977
  {
960
978
  "name": "multi-agent-refactor",
961
- "description": "Analyse the project: extract adapted best-practices, hunt real bugs + improvement areas, check upstream drift of derived skills, draft one plan, take approval, develop, then ask whether to sync.",
979
+ "description": "Analyse the project: extract adapted best-practices, hunt real bugs + improvement areas, check upstream drift of derived skills, research the companion dev-toolkit MCP server against current MCP practice, draft one plan, take approval, develop, then ask whether to sync.",
962
980
  "platform": null,
963
981
  "group": "core",
964
982
  "triggerKeywords": [],
@@ -1001,6 +1019,24 @@
1001
1019
  "triggerPaths": [],
1002
1020
  "relativePath": "shared/core/multi-agent-review-jira/SKILL.md"
1003
1021
  },
1022
+ {
1023
+ "name": "multi-agent-routines",
1024
+ "description": "List your saved /multi-agent routines (from /multi-agent:save) with what each one does, rendered in outputLanguage.",
1025
+ "platform": null,
1026
+ "group": "core",
1027
+ "triggerKeywords": [],
1028
+ "triggerPaths": [],
1029
+ "relativePath": "shared/core/multi-agent-routines/SKILL.md"
1030
+ },
1031
+ {
1032
+ "name": "multi-agent-save",
1033
+ "description": "Save a recurring job as a reusable /multi-agent:<name> command. Reviews the conversation + your CLAUDE.md for candidate routines, you pick one and name it; stored local-only, never synced.",
1034
+ "platform": null,
1035
+ "group": "core",
1036
+ "triggerKeywords": [],
1037
+ "triggerPaths": [],
1038
+ "relativePath": "shared/core/multi-agent-save/SKILL.md"
1039
+ },
1004
1040
  {
1005
1041
  "name": "multi-agent-scan",
1006
1042
  "description": "Skill security scan: walks local skill directories against a tiered pattern catalog.",
@@ -1048,7 +1084,7 @@
1048
1084
  },
1049
1085
  {
1050
1086
  "name": "multi-agent-sync",
1051
- "description": "One-shot sync of the entire multi-agent ecosystem: Claude Code, Copilot CLI, pipeline repo, and website.",
1087
+ "description": "One-shot sync of the entire multi-agent ecosystem: Claude Code, Copilot CLI, pipeline repo, website, and the dev-toolkit MCP server.",
1052
1088
  "platform": null,
1053
1089
  "group": "core",
1054
1090
  "triggerKeywords": [],
@@ -2,11 +2,11 @@
2
2
 
3
3
  Single source of truth for skills delivered to both Claude Code (`~/.claude/skills/`) and Copilot CLI (`~/.copilot/skills/`) by the installer.
4
4
 
5
- **Total:** 189 skills (41 core + 148 external). Auto-generated by `scripts/gen-skills-index.mjs` - do not edit by hand.
5
+ **Total:** 193 skills (45 core + 148 external). Auto-generated by `scripts/gen-skills-index.mjs` - do not edit by hand.
6
6
 
7
7
  ## Directory layout
8
8
 
9
- - **`core/`** - 41 `multi-agent*` orchestration skills that are pipeline-critical. Edits here are core-code changes.
9
+ - **`core/`** - 45 `multi-agent*` orchestration skills that are pipeline-critical. Edits here are core-code changes.
10
10
  - **`external/`** - 148 iOS / Android / generic skills imported from the upstream skill library. Mirrors of third-party guidance.
11
11
  - Install destination stays flat: both trees flatten into `~/.claude/skills/` and `~/.copilot/skills/`. See ADR-0006 for the rationale.
12
12
 
@@ -14,7 +14,7 @@ Source layout is logical grouping only - skill discovery at runtime is unchang
14
14
 
15
15
  ## Categories
16
16
 
17
- - [Pipeline Orchestration](#pipeline-orchestration) - 41
17
+ - [Pipeline Orchestration](#pipeline-orchestration) - 45
18
18
  - [iOS / Apple Ecosystem](#ios-apple-ecosystem) - 88
19
19
  - [Android / Kotlin](#android-kotlin) - 13
20
20
  - [Web / Frontend](#web-frontend) - 10
@@ -25,7 +25,7 @@ Source layout is logical grouping only - skill discovery at runtime is unchang
25
25
 
26
26
  | Skill | Group | Description |
27
27
  |-------|-------|-------------|
28
- | [`apple-archive-compliance`](./core/apple-archive-compliance/) | `core` | Apple App Store Review compliance - wraps the dev-toolkit-mcp `ios_app_store_audit` tool (17-rule deep scan) with ITMS error code mapping |
28
+ | [`apple-archive-compliance`](./core/apple-archive-compliance/) | `core` | Apple App Store Review compliance - wraps the dev-toolkit-mcp `ios_app_store_audit` tool (18-rule deep scan) with ITMS error code mapping |
29
29
  | [`google-play-compliance`](./core/google-play-compliance/) | `core` | Google Play Store publication compliance - bundletool + aapt2 + apksigner orchestration + 21-rule policy catalog with Play Console error c |
30
30
  | [`multi-agent`](./core/multi-agent/) | `core` | Task orchestrator: runs the full pipeline from a Jira ID or GitHub Issue URL - analysis → plan → TDD development → parallel review (Fable |
31
31
  | [`multi-agent-analysis`](./core/multi-agent-analysis/) | `core` | Standalone feature-spec analysis (v3 template). Platform-agnostic concept layer with repo-driven convention extraction and per-platform Pass |
@@ -34,12 +34,14 @@ Source layout is logical grouping only - skill discovery at runtime is unchang
34
34
  | [`multi-agent-build-optimize`](./core/multi-agent-build-optimize/) | `core` | Wrapper that dispatches to xcode-build-orchestrator on iOS repos. Benchmarks the current Xcode build, runs compilation / project / SPM analy |
35
35
  | [`multi-agent-channels`](./core/multi-agent-channels/) | `core` | Multi-channel reporter - Jira/Confluence/Wiki/PR description. Multi-select channels + content, humanizer pass, reviewer-preserving Bitbuck |
36
36
  | [`multi-agent-create-jira`](./core/multi-agent-create-jira/) | `core` | Create a standards-compliant Jira issue (Task / Bug / Story): asks the type, mines project conventions, drafts from a standard template with |
37
+ | [`multi-agent-design-check`](./core/multi-agent-design-check/) | `core` | Mock-mode vs Figma design audit (iOS / Android, local-only). Pick repo + module, gate on mock support, enumerate every state driver into a c |
37
38
  | [`multi-agent-dev`](./core/multi-agent-dev/) | `core` | Fast development mode: Init → Dev (Opus) → Test → Commit → Report. Analysis, planning, and review phases are skipped. |
38
39
  | [`multi-agent-dev-autopilot`](./core/multi-agent-dev-autopilot/) | `core` | Fastest mode: Dev (Opus) plus Autopilot. Init → Dev → Commit → Report with zero confirmations. |
39
40
  | [`multi-agent-dev-local`](./core/multi-agent-dev-local/) | `core` | Fast mode + local - Init → Dev(Opus) → Commit → Report, no worktree. |
40
41
  | [`multi-agent-dev-local-autopilot`](./core/multi-agent-dev-local-autopilot/) | `core` | Fastest + local - Dev(Opus) + autopilot, no worktree, zero interaction. |
41
42
  | [`multi-agent-diff-explain`](./core/multi-agent-diff-explain/) | `core` | Map Phase 4 triage findings to branch diff lines. Read-only post-hoc command, used after review to answer 'which finding lines up with which |
42
43
  | [`multi-agent-finish`](./core/multi-agent-finish/) | `core` | Continue already-done LOCAL work through the pipeline tail: Review → Build+Test → Commit/PR → Report (technical analysis + Jira test-scenari |
44
+ | [`multi-agent-forget`](./core/multi-agent-forget/) | `core` | Remove a saved /multi-agent routine (created by /multi-agent:save): deletes its local-only command and its registry entry. Asks which one an |
43
45
  | [`multi-agent-garbage-collect`](./core/multi-agent-garbage-collect/) | `core` | Sweep leftover /tmp scratch (picker state, review diffs, channel payloads, analysis drafts) from past runs. Dry-run first; confirms before d |
44
46
  | [`multi-agent-help`](./core/multi-agent-help/) | `core` | Multi-agent pipeline usage guide - renders in EN or TR per prefs.global.outputLanguage (falls back to promptLanguage for backward compatib |
45
47
  | [`multi-agent-issue`](./core/multi-agent-issue/) | `core` | List unassigned GitHub issues, pick one, auto-assign, and launch the multi-agent pipeline. |
@@ -52,17 +54,19 @@ Source layout is logical grouping only - skill discovery at runtime is unchang
52
54
  | [`multi-agent-manual-test`](./core/multi-agent-manual-test/) | `core` | Switch to the active task's branch and prepare it for manual testing in Xcode. Phase 5 standalone (the UI Bug Hunter lives at multi-agent-te |
53
55
  | [`multi-agent-prune-logs`](./core/multi-agent-prune-logs/) | `core` | Delete per-task project logs under ~/.claude/logs/multi-agent (filter by age/project/task). Audit trail + metrics are preserved. Dry-run fir |
54
56
  | [`multi-agent-purge`](./core/multi-agent-purge/) | `core` | ⚠️ Wipes every worktree, branch, log, and state file. Irreversible; asks for double confirmation. |
55
- | [`multi-agent-refactor`](./core/multi-agent-refactor/) | `core` | Analyse the project: extract adapted best-practices, hunt real bugs + improvement areas, check upstream drift of derived skills, draft one p |
57
+ | [`multi-agent-refactor`](./core/multi-agent-refactor/) | `core` | Analyse the project: extract adapted best-practices, hunt real bugs + improvement areas, check upstream drift of derived skills, research th |
56
58
  | [`multi-agent-resume`](./core/multi-agent-resume/) | `core` | Resume a stopped or failed task from the phase where it left off. |
57
59
  | [`multi-agent-review`](./core/multi-agent-review/) | `core` | Run parallel review on a branch diff or a Pull Request: 2 models on Claude Code (Fable + Sonnet), 3 models on Copilot CLI (GPT + Opus + Sonn |
58
60
  | [`multi-agent-review-issue`](./core/multi-agent-review-issue/) | `core` | Assess whether a GitHub issue is ready for multi-agent development: fetch it, grade scope / acceptance criteria / repro / design / API / sta |
59
61
  | [`multi-agent-review-jira`](./core/multi-agent-review-jira/) | `core` | Assess whether a Jira issue is ready for multi-agent development: fetch it, grade scope / acceptance criteria / repro / design / API / stack |
62
+ | [`multi-agent-routines`](./core/multi-agent-routines/) | `core` | List your saved /multi-agent routines (from /multi-agent:save) with what each one does, rendered in outputLanguage. |
63
+ | [`multi-agent-save`](./core/multi-agent-save/) | `core` | Save a recurring job as a reusable /multi-agent:<name> command. Reviews the conversation + your CLAUDE.md for candidate routines, you pick o |
60
64
  | [`multi-agent-scan`](./core/multi-agent-scan/) | `core` | Skill security scan: walks local skill directories against a tiered pattern catalog. |
61
65
  | [`multi-agent-search`](./core/multi-agent-search/) | `core` | Log search across every agent-log.md with smart ranking and filters. Optional --semantic flag queries the per-repo triage corpus. |
62
66
  | [`multi-agent-setup`](./core/multi-agent-setup/) | `core` | First-run setup wizard: keychain token discovery, Git Identity onboarding, and pipeline preparation. |
63
67
  | [`multi-agent-stack`](./core/multi-agent-stack/) | `core` | Select the active stack for this repo by enabling the matching marketplace plugin(s) in .claude/settings.json (ios/android/mobile/backend/fr |
64
68
  | [`multi-agent-status`](./core/multi-agent-status/) | `core` | Show every multi-agent task's ID, phase, branch, and status. |
65
- | [`multi-agent-sync`](./core/multi-agent-sync/) | `core` | One-shot sync of the entire multi-agent ecosystem: Claude Code, Copilot CLI, pipeline repo, and website. |
69
+ | [`multi-agent-sync`](./core/multi-agent-sync/) | `core` | One-shot sync of the entire multi-agent ecosystem: Claude Code, Copilot CLI, pipeline repo, website, and the dev-toolkit MCP server. |
66
70
  | [`multi-agent-test`](./core/multi-agent-test/) | `core` | UI Bug Hunter - iOS Simulator (simctl) + Android Emulator (adb). Auto-detects platform. Screenshot + tap + analyze on the booted device. T |
67
71
  | [`multi-agent-uninstall`](./core/multi-agent-uninstall/) | `core` | Uninstall the pipeline from Claude Code + Copilot CLI. Keychain access tokens are always left untouched; --all-data also clears pipeline set |
68
72
  | [`multi-agent-update`](./core/multi-agent-update/) | `core` | Update the pipeline to the latest version: git pull, install, migrate. |
@@ -1,14 +1,14 @@
1
1
  ---
2
2
  name: apple-archive-compliance
3
3
  language: en
4
- description: "Apple App Store Review compliance - wraps the dev-toolkit-mcp `ios_app_store_audit` tool (17-rule deep scan) with ITMS error code mapping + EN/TR humanizer templates. Consumed by: /multi-agent:test 'store-ready' (primary dispatch), Phase 4 Security Auditor (catalog cross-ref on Info.plist / PrivacyInfo / entitlements diffs), /multi-agent:review (PR citation), /multi-agent:channels (PR body auto-augmentation). Wiring enforced by smoke-compliance-skills.sh."
4
+ description: "Apple App Store Review compliance - wraps the dev-toolkit-mcp `ios_app_store_audit` tool (18-rule deep scan) with ITMS error code mapping + EN/TR humanizer templates. Consumed by: /multi-agent:test 'store-ready' (primary dispatch), Phase 4 Security Auditor (catalog cross-ref on Info.plist / PrivacyInfo / entitlements diffs), /multi-agent:review (PR citation), /multi-agent:channels (PR body auto-augmentation). Wiring enforced by smoke-compliance-skills.sh."
5
5
  user-invocable: true
6
6
  argument-hint: '[archive-path] [--threshold=error|warning|info] [--format=markdown|json] [--lang=en|tr] - no-arg: picks most recent .xcarchive from ~/Library/Developer/Xcode/Archives/'
7
7
  ---
8
8
 
9
9
  # apple-archive-compliance - Apple App Store Review Compliance Skill
10
10
 
11
- Pre-submission compliance check for iOS `.xcarchive` bundles. Wraps the [`ios_app_store_audit`](https://github.com/mmerterden/dev-toolkit-mcp) MCP tool (17-rule deep audit shipped inside `@mmerterden/dev-toolkit-mcp` v2.4+) and humanizes its JSON output into actionable Turkish / English markdown reports. Catches rejection-causing issues (ITMS error codes, App Store Review Guideline violations) **before** uploading to App Store Connect.
11
+ Pre-submission compliance check for iOS `.xcarchive` bundles. Wraps the [`ios_app_store_audit`](https://github.com/mmerterden/dev-toolkit-mcp) MCP tool (18-rule deep audit shipped inside `@mmerterden/dev-toolkit-mcp` v2.9.0+) and humanizes its JSON output into actionable Turkish / English markdown reports. Catches rejection-causing issues (ITMS error codes, App Store Review Guideline violations) **before** uploading to App Store Connect.
12
12
 
13
13
  **This skill does NOT reimplement the rule engine** - it invokes the MCP tool and maps its output through a knowledge catalog. Rule logic stays in dev-toolkit-mcp's `tools/ios-app-store-audit/`; this skill is the orchestration + humanization layer.
14
14
 
@@ -25,12 +25,12 @@ Pre-submission compliance check for iOS `.xcarchive` bundles. Wraps the [`ios_ap
25
25
 
26
26
  ### Prerequisite detection
27
27
 
28
- The 17-rule scan is provided by the `ios_app_store_audit` tool in `@mmerterden/dev-toolkit-mcp` ≥ v2.4. Two invocation modes:
28
+ The 18-rule scan is provided by the `ios_app_store_audit` tool in `@mmerterden/dev-toolkit-mcp` ≥ v2.9.0. Two invocation modes:
29
29
 
30
30
  **A. Native MCP tool call** (preferred when running inside an MCP-aware editor):
31
31
 
32
32
  ```text
33
- mcp__dev_toolkit__ios_app_store_audit({
33
+ mcp__dev-toolkit__ios_app_store_audit({
34
34
  archive_path: "<path>",
35
35
  rules: "all" // "all" | "core" | "deep" | csv of ruleIDs
36
36
  })
@@ -88,7 +88,7 @@ fi
88
88
  RULES="${RULES:-all}" # all | core | deep | csv of ruleIDs
89
89
 
90
90
  # Mode A - native MCP call (replaces this whole block when running inside Claude Code / Copilot CLI):
91
- # mcp__dev_toolkit__ios_app_store_audit({ archive_path: "$ARCHIVE_PATH", rules: "$RULES" })
91
+ # mcp__dev-toolkit__ios_app_store_audit({ archive_path: "$ARCHIVE_PATH", rules: "$RULES" })
92
92
  # Mode B - direct Node invocation (fallback):
93
93
  node -e "
94
94
  import('@mmerterden/dev-toolkit-mcp/tools/ios-app-store-audit/index.js').then(async m => {
@@ -107,7 +107,7 @@ VIOLATIONS=$(jq -c '.violations[]' /tmp/archiveguard-$$.json)
107
107
 
108
108
  **Cache filename:** writes `/tmp/archiveguard-$$.json` so `/multi-agent:channels` and the skill's downstream consumers can pick it up via the `find /tmp -name 'archiveguard-*.json'` glob.
109
109
 
110
- ## 17-Rule Catalog
110
+ ## 18-Rule Catalog
111
111
 
112
112
  Apple App Store Review Guidelines + ITMS upload error codes that the underlying scanner enforces. Rule IDs match the source-of-truth IDs in `dev-toolkit-mcp/tools/ios-app-store-audit/rules/<ruleID>.js` (stable across versions).
113
113
 
@@ -130,6 +130,7 @@ Apple App Store Review Guidelines + ITMS upload error codes that the underlying
130
130
  | 15 | `production-hygiene` | - | `print()` / `NSLog()` / `debugPrint()` symbol presence + mock/test JSON files shipped in bundle | warning |
131
131
  | 16 | `duplicate-resource` | - | Same asset under multiple paths (bloats bundle) | info |
132
132
  | 17 | `dead-reference` | - | Files referenced in Xcode proj but absent from archive | warning |
133
+ | 18 | `sdk-floor` | ITMS-90725 | `DTSDKName` / `DTPlatformVersion` major ≥ 26 and `DTXcode` ≥ 2600 (iOS 26 / Xcode 26 floor, in force since 2026-04-28) | error |
133
134
 
134
135
  ## Severity mapping for consumers
135
136
 
@@ -256,12 +257,12 @@ If `:test "store-ready"` ran recently and its JSON is cached, channels command's
256
257
  multi-agent-test "store-ready" --format=json --auto-pick
257
258
 
258
259
  # Direct MCP tool call (any MCP-aware editor)
259
- mcp__dev_toolkit__ios_app_store_audit({ archive_path: "~/Library/Developer/Xcode/Archives/2026-04-21/MyApp.xcarchive", rules: "all" })
260
+ mcp__dev-toolkit__ios_app_store_audit({ archive_path: "~/Library/Developer/Xcode/Archives/2026-04-21/MyApp.xcarchive", rules: "all" })
260
261
  ```
261
262
 
262
263
  ### Phase 4 Security Auditor (catalog cross-ref, no binary invocation)
263
264
 
264
- When a Phase 4 review diff touches iOS release-relevant paths (`Info.plist`, `PrivacyInfo.xcprivacy`, `*.entitlements`, `AppDelegate.swift`, `project.pbxproj`), the security-auditor persona loads this skill's 17-rule catalog and cites matching ruleIDs next to its findings. No binary invocation at review time - catalog reads are free.
265
+ When a Phase 4 review diff touches iOS release-relevant paths (`Info.plist`, `PrivacyInfo.xcprivacy`, `*.entitlements`, `AppDelegate.swift`, `project.pbxproj`), the security-auditor persona loads this skill's 18-rule catalog and cites matching ruleIDs next to its findings. No binary invocation at review time - catalog reads are free.
265
266
 
266
267
  ```
267
268
  # Example finding from Phase 4 Security Auditor (wired in v5.8.1):
@@ -313,3 +314,4 @@ The appended section is structured:
313
314
  - **v5.8.1** - 3 additional consumer surfaces wired (Phase 4 Security Auditor cross-ref, `/multi-agent:review` citation, `/multi-agent:channels` PR-body auto-augmentation). Regression-locked by `smoke-compliance-skills.sh` (45 assertions).
314
315
  - **v6.0.0** - `language: en` frontmatter tag; 4-consumer Examples section expanded.
315
316
  - **v8.4.0** - Migrated off the standalone ArchiveGuard Swift binary. Backend is now the `ios_app_store_audit` tool inside `@mmerterden/dev-toolkit-mcp` ≥ v2.4 (full Node port of the 17 rules). All four consumer surfaces unchanged; rule IDs and JSON output shape preserved for backward compatibility. Rule catalog now points to `dev-toolkit-mcp/tools/ios-app-store-audit/rules/`. ArchiveGuard repo deprecated.
317
+ - **Unreleased** - Catalog grows to 18 rules: adds `sdk-floor` (ITMS-90725, iOS 26 / Xcode 26 build floor in force since 2026-04-28), which nothing previously checked. `embedded-sdk`'s missing-framework-privacy-manifest finding moves from a `5.1.1` WARNING to `ITMS-91061` ERROR, an enforced rejection since 2025-02-12 - archives that used to pass with a warning now fail. Requires `@mmerterden/dev-toolkit-mcp` ≥ v2.9.0.
@@ -0,0 +1,248 @@
1
+ ---
2
+ name: multi-agent-design-check
3
+ language: en
4
+ description: "Mock-mode vs Figma design audit (iOS / Android, local-only). Pick repo + module, gate on mock support, enumerate every state driver into a countable target set, build Debug in a worktree, launch in mock mode, fetch Figma variants, compare each pixel + px-spacing + typography + color, and export a side-by-side annotated report (HTML + PDF + Confluence) to ~/DesignChecks. A coverage gate fails the run when a target is neither audited nor skipped with a reason."
5
+ user-invocable: true
6
+ argument-hint: '[scope] - empty = whole module; screen name; screen@variant; Figma URL(s); --resume'
7
+ ---
8
+
9
+ # multi-agent-design-check - Mock-mode vs Figma design audit
10
+
11
+ Local, on-device design-conformance auditor. Runs the app in a **mock mode** on a simulator / emulator and compares each screen (and every mock variant the build exposes) against its Figma design at the **pixel + geometry + typography + color** level, then produces a detailed report.
12
+
13
+ **Local-only**: no CI/CD, no cron, no commits, no PR. Read-only audit; writes a report to `~/DesignChecks/`. The worktree only isolates the Debug build.
14
+
15
+ > **Language**: `promptLanguage=en` always (this spec stays English). `outputLanguage` applies to conversational lines and the human-readable report - pass it to `design_report` as `report.lang` (engine defaults to English, ships `en` + `tr` packs, per-key `report.labels` overrides). `ask_choice` labels/headers, branch names, paths, code identifiers stay English.
16
+
17
+ ## Scope - `$ARGUMENTS`
18
+
19
+ The scope decides which **inventory targets** (Phase 0 step 5) the run must audit. It never changes how thoroughly each target is audited.
20
+
21
+ | Form | Example | Scope |
22
+ |------|---------|-------|
23
+ | empty / `module` | (no argument) | Every target in the module's inventory |
24
+ | screen name | `boarding-pass` | Every target whose `screen` matches (case/separator-insensitive) |
25
+ | `screen@variant` | `boarding-pass@expired` | One target |
26
+ | target id | `scenario-case:boardingpassoutcome-expired` | One target, exactly |
27
+ | Figma URL(s) | `https://figma.com/design/…?node-id=1-2` | Only the frames those URLs name |
28
+ | `--resume` | `--resume` | The unaudited remainder of the most recent run for this repo + module |
29
+ | combinations | `seat-map summary@semi-success` | Union of the above, space- or newline-separated |
30
+
31
+ A scope matching **no** inventory target is an error, not an empty run: print the closest inventory ids and halt.
32
+
33
+ **Whole-module is the default, and it is meant to finish.** The inventory prices each target (`cost: relaunch | in-app`) and batches them into a run `plan`, so a 50-target module is typically about a dozen relaunches rather than fifty - a full audit is one sitting, not a project. Scope exists for resuming an interrupted run and for re-checking one screen after a fix, **not** for trimming an audit down to what feels affordable. The coverage gate applies to the **scoped** set, so a deliberate scoped run is never penalised for out-of-scope targets, and `--resume` closes the remainder.
34
+
35
+ ## Pipeline
36
+
37
+ ```
38
+ Phase 0: Init & Gate → repo + module picker, platform detect, MOCK FEASIBILITY GATE, SCENARIO INVENTORY, scope resolve, report dir, worktree
39
+ Phase 1: Build & Launch → Debug build in worktree, boot device, install, launch in mock mode
40
+ Phase 2: Figma → fetch module frame tree, enumerate + map variants (ask when ambiguous)
41
+ Phase 3: Drive & Compare → per plan batch: one launch → capture + flip in-app states → match → batch-ask → compare
42
+ Phase 4: Report → coverage gate + assemble + export HTML + PDF (+ Confluence) to ~/DesignChecks/
43
+ ```
44
+
45
+ ## Requirements
46
+
47
+ - **iOS**: Xcode + Simulator. **Android**: Android SDK + emulator / device.
48
+ - **MCP**: `dev-toolkit` (>= 2.8.0, for `design_scenario_inventory`, the `design_report` coverage gate, and `design_visual_compare` region alignment) + an authenticated Figma MCP (`mcp__claude_ai_Figma__*`).
49
+ - The selected module must support a mock mode (Phase 0 gate). No mock support → halt.
50
+
51
+ ## Phase Tracker (mandatory)
52
+
53
+ ```bash
54
+ bash $HOME/.copilot/scripts/phase-tracker.sh init "$TASK_ID"
55
+ for p in "0:Init & Gate" "1:Build & Launch" "2:Figma" "3:Drive & Compare" "4:Report"; do
56
+ bash $HOME/.copilot/scripts/phase-tracker.sh add "${p%%:*}" "${p#*:}"
57
+ done
58
+ ```
59
+ Copilot / plain shell has no TaskList widget - after every state change call `phase-tracker.sh render` (prints a bordered ANSI card). Do NOT call TaskCreate here.
60
+
61
+ ## STOP-AND-CONFIRM
62
+
63
+ Every Phase 0 / Phase 2 decision uses the `ask_choice` picker (`$HOME/.copilot/lib/ask-choice.sh`). Print a `Step <i>/<n>: <what it decides>` breadcrumb first. Confirmation required even with one option; state inheritance from a previous run is FORBIDDEN.
64
+
65
+ ---
66
+
67
+ ## Phase 0 - Init, Feasibility Gate & Inventory
68
+
69
+ 0. **MCP CURRENCY GATE (first, before anything expensive)** - an MCP stdio server publishes its tool list once at `initialize` and never re-reads the code, so a session bound to a process that started before the last update keeps serving the OLD tool list while still reporting "connected". Finding that out after a Debug build and a device drive wastes the run and yields a report missing the checks this spec depends on.
70
+
71
+ Assert both halves:
72
+
73
+ a. **Session** - `mcp__dev-toolkit__design_scenario_inventory` must be callable and `mcp__dev-toolkit__design_visual_compare` must accept `live_region`. Absent → the session holds a stale process.
74
+
75
+ b. **Disk** - probe the configured server, which reports what a fresh connection WOULD serve:
76
+ ```bash
77
+ printf '%s\n%s\n' \
78
+ '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"probe","version":"1"}}}' \
79
+ '{"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}' \
80
+ | node "<dev-toolkit path>/index.js" 2>/dev/null | python3 -c "
81
+ import sys,json
82
+ for l in sys.stdin:
83
+ try: m=json.loads(l)
84
+ except: continue
85
+ if m.get('id')==1: print('version', m['result']['serverInfo']['version'])
86
+ if m.get('id')==2:
87
+ n=[t['name'] for t in m['result']['tools']]
88
+ print('tools', len(n), 'inventory', 'design_scenario_inventory' in n)"
89
+ ```
90
+
91
+ - **disk OK, session missing the tool** → **HALT**; the user must reconnect the MCP server (a stale build advertises one fewer `design_*` tool, which is the quickest tell). If a reconnect does not take, lingering server processes are the usual cause - compare `ps -o lstart=` start times against the code's mtime.
92
+ - **disk stale** → **HALT**; the checkout needs updating first.
93
+ - **both current** → continue.
94
+
95
+ Never substitute a local `node` call for a missing tool: the run would silently lose the coverage gate and region alignment, which is the exact failure this gate prevents.
96
+
97
+ 1. **Repo picker** - `$HOME/.copilot/multi-agent-refs/_repo-picker.md`. Account picker skipped (Figma token user-supplied) unless Confluence export needs a token.
98
+ 2. **Module picker** - `$HOME/.copilot/multi-agent-refs/_dev-context.md` (auto-suggest `.gitmodules` via `submodule-detector.sh`). Pick the module to audit (multi-module = audit each independently).
99
+ 3. **Platform detect** - `.xcodeproj`/`Package.swift`→iOS, `build.gradle*`→Android. Persist `state.platform`.
100
+ 4. **MOCK FEASIBILITY GATE** on the module path:
101
+ ```
102
+ mcp__dev-toolkit__design_mock_detect({ repo_path, platform, extra_keys })
103
+ ```
104
+ (`extra_keys` from `config mock.keys`.)
105
+ - `false` → **HALT** with `reason`; the module cannot be audited. Never fabricate a comparison.
106
+ - `"debug-only"` → warn via ask_choice (variants can't be toggled at launch; only default Debug state comparable), Continue / Cancel.
107
+ - `true` → persist `state.designCheck.mock` (mechanism, activation, variantsHint, evidence).
108
+ 5. **SCENARIO INVENTORY (this is the audit's target set)**:
109
+ ```
110
+ mcp__dev-toolkit__design_scenario_inventory({ repo_path, platform,
111
+ extra_launch_args: <config inventory.extraLaunchArgs>,
112
+ extra_targets: <config inventory.extraTargets>,
113
+ ignore_targets: <config inventory.ignoreTargets> })
114
+ ```
115
+ Returns `targets[]` - each `{ id, kind, label, screen, driver, cost, evidence }` - plus `plan[]`, `relaunchCount`, `groups[]`, `byKind`, `byCost`, `ignored[]`, `truncated`, `scanStrategy`. Kinds: `launch-arg`, `scenario-case`, **`prefix-code`** (a mock repository branching on the prefix of the reference the user types - usually the LARGEST group, and the one a selector-only search misses entirely), `code-scenario`, `fixture`, `deep-link`.
116
+
117
+ This list, not the agent's reading of the code and not what the UI happens to expose to tapping, is what the run is measured against. Persist verbatim to `state.designCheck.inventory`.
118
+ - `targetCount: 0` → warn that only the default launch state is auditable (a `debug-only` project legitimately lands here).
119
+ - `truncated: true` → the target set is INCOMPLETE. Say so now and pass `coverage.truncatedInventory: true` in Phase 4 so the gate fails instead of reporting a clean percentage of a partial denominator; narrow to a screen and work through the module in `--resume` steps.
120
+ - `ignored[]` non-empty → list what the config dropped, so a stale `ignoreTargets` cannot quietly shrink the audit.
121
+ 6. **Scope resolve** - intersect `$ARGUMENTS` with `inventory.targets`; persist `state.designCheck.scope = { argument, targetIds[] }`.
122
+
123
+ Print the resolved set grouped by screen **with its relaunch cost**: `<n> targets · <relaunchCount> relaunches`. Read the cost from `plan`, not from the target count - one relaunch serves every in-app target on that screen, so a 50-target module is typically a dozen relaunches. **Whole-module is the intended default**; ask_choice only when `relaunchCount` exceeds `config coverage.confirmAbove` (default 25), phrased as a cost estimate rather than an invitation to shrink the audit. Never offer a smaller scope as the easy path.
124
+ 7. **`--resume`** - read the most recent `~/DesignChecks/{repo}__{module}/*/run-state.json`; scope becomes that run's targets minus `covered` minus `skipped`. No previous run → say so and fall back to whole-module scope after confirmation.
125
+ 8. **Report dir** - create `~/DesignChecks/{repo}__{module}/{UTC-timestamp}/` (plus `assets/`) now and persist as `state.designCheck.reportDir`. Phase 3 writes captures, comparison images, and `run-state.json` into it, so it must exist before driving starts.
126
+ 9. **Worktree** - `{projectRoot}/{worktreeBasePath}/{taskId}` (default `.worktrees/DC-<shortId>`), never under $HOME. Prune stale locks + add `.worktrees/` to `.git/info/exclude` first.
127
+
128
+ Persist `agent-state.json` (`mode: "design-check"`, platform, projectRoot, worktreePath, module, designCheck).
129
+
130
+ ## Phase 1 - Build & Launch (mock)
131
+
132
+ 1. **Debug build** in the worktree: iOS `mcp__dev-toolkit__ios_xcodebuild({ scheme, configuration: "Debug", action: "build" })`; Android `./gradlew :<module>:assembleDebug`.
133
+ 2. **Boot + install**: iOS list/boot device + `xcrun simctl install`; Android running emulator + `adb install -r`.
134
+ 3. **Deterministic state**: iOS `ios_status_bar({ preset: "clean" })`; fix appearance + locale.
135
+ 4. **Launch mock**: `mcp__dev-toolkit__design_mock_launch({ platform, bundle_id|package_name, launch_arg|intent_extra })` from Phase 0 activation. `debug-only` → just launch the Debug build. The build is installed once; Phase 3 relaunches it per target rather than rebuilding.
136
+
137
+ ## Phase 2 - Figma fetch & variant mapping (module-scoped)
138
+
139
+ Figma **discovery** happens only here: the frame tree is fetched once and no later phase browses Figma for candidates. Phase 3 may fetch a specific node the user hands over in the 3.3 batch-ask - a targeted fetch of an already-identified frame, and the only Figma call allowed after this phase.
140
+
141
+ 1. Resolve the Figma URL (`$ARGUMENTS` or ask). Parse `fileKey` + `nodeId` (`-`→`:`).
142
+ 2. `mcp__claude_ai_Figma__get_metadata` → frame tree; direct child frames = candidate variants.
143
+ 3. Map each scoped target's `screen` + `label` (and `variantsHint`) → frames by similarity. Ambiguous/unmatched → deferred to the Phase 3.3 batch-ask (where the live capture can be shown); never guess. `debug-only` → single default variant.
144
+ 4. Per variant: `get_screenshot` (design PNG) + `get_design_context` (bbox, itemSpacing, paddings, fontSize/fontFamily, fills, CodeConnect name). Flatten to `figma_spec`; record `figmaFrame` size.
145
+
146
+ Persist `state.designCheck.variants[]`.
147
+
148
+ ## Phase 3 - Drive every scoped target → capture → match → batch-ask → compare
149
+
150
+ **This phase iterates `state.designCheck.scope.targetIds` - a finite list decided in Phase 0. It ends when every id is resolved, not when the UI stops offering new taps.** Tap-walking alone cannot reach a state needing a different launch argument, scenario case, or typed scenario code - which is exactly how a module's error / edge states go missing.
151
+
152
+ ### 3.1 Drive the inventory's plan, batch by batch
153
+
154
+ **Follow `inventory.plan`, filtered to the scoped ids.** Each batch is one launch: the batch's relaunch target opens a screen, and every in-app target for that screen is flipped while the app is already there. Driving the plan is what makes full coverage affordable - target-by-target relaunching is what made earlier runs give up a third of the way in.
155
+
156
+ Per batch: launch once with the batch's `launch` driver (or the plain mock activation for `(default launch)`) → navigate → capture the relaunch target → for each in-app target, flip its selector, let the screen re-render, capture. **No relaunch between in-app targets.**
157
+
158
+ Per-target activation by `driver.type`:
159
+
160
+ | `driver.type` | Activation |
161
+ |---|---|
162
+ | `launch-arg` | `design_mock_launch({ launch_arg: "<mock activation> <driver.launchArg>" })` - the mock switch AND the target's flag together |
163
+ | `intent-extra` | `design_mock_launch({ intent_extra: "<mock extra> <driver.intentExtra>" })` |
164
+ | `scenario` | Set `driver.enum` to `driver.case` through the build's debug scenario picker, then drive the flow that consumes it |
165
+ | `code` (from `prefix-code`) | Type a reference beginning with `driver.code` at the entry field, then walk to `driver.appliesTo`. The prefix decides which fixture the mock repository returns - this is how most per-screen variants are reached |
166
+ | `code` (from `code-scenario`) | Same entry field, flow-wide code not owned by one screen |
167
+ | `fixture` | Activate the launch arg / scenario that reads `driver.file`; when nothing does → skip with reason "fixture not reachable from any driver" |
168
+ | `deep-link` | `ios_open_url` / `android_open_url` with `driver.url` |
169
+ | `manual` | Config-declared: follow the config's note, or skip with that note as the reason |
170
+
171
+ While a target's state is on screen, also capture the **sub-states reachable from it by tapping** - overlays, bottom sheets, modals, popups, inline errors, QR / share sheets. These cost no relaunch and belong to the target that exposed them (`<id>#<sub-label>`).
172
+
173
+ Per capture: `ios_screenshot`/`android_screenshot` (save PNG into the Phase 0 report dir) + `mcp__dev-toolkit__design_ui_geometry` → append to `state.designCheck.captured[]` with the target id and a human label. **Persist `state` and `run-state.json` after every capture** so a dying run resumes from where it stopped.
174
+
175
+ Unreachable target → record `{ id, reason }` in `state.designCheck.skipped[]` with a concrete reason ("scenario picker not present in this build", "needs a live PNR", "crashes on launch: <symbol>"). "Requires a scenario / prefix / launch-arg" is **not** a reason - that describes the work, and the work is this phase's job.
176
+
177
+ ### 3.2 Match each capture → Figma frame (auto)
178
+
179
+ Resolve each captured screen's frame from the Phase 2 tree; match by structure/content; accept only a **confident** match → `pairs[]`.
180
+
181
+ ### 3.3 Batch-ask the user for EVERYTHING unmatched (ONE prompt, WITH the visual)
182
+
183
+ Collect ALL unmatched captures into a single list and ask ONCE - never guess, never show a wrong frame. **Show each unmatched screen's captured screenshot** (attach the PNG), name the screen, ask for the Figma node-id / URL in `outputLanguage`, optionally list best-guess candidates. Each answer becomes a confirmed pair; a declined screen is a skip with reason "no Figma frame supplied".
184
+
185
+ ### 3.4 Compare ALL pairs in one pass
186
+
187
+ ```
188
+ mcp__dev-toolkit__design_visual_compare({ figma_png, live_png, out_dir, label,
189
+ figma_spec, live_geometry, figma_frame, live_screen,
190
+ crop_top_live, tolerance_px: 2, color_tolerance: 3, max_diff_pct: 1.0 })
191
+ ```
192
+ Collect findings (spacing/size/position px, color ΔE hex, typography), perceptualPct, images.
193
+
194
+ **Bottom sheets, modals, and any partial overlay need region alignment.** Their Figma frame covers only the sheet while the capture is the whole screen; passing that pair as-is stretches a full screen onto a sheet-shaped frame, misplacing every element inside the sheet and burying the real defect in noise. For any capture whose frame is not full-screen add:
195
+
196
+ ```
197
+ live_region: <the sheet container's {x,y,w,h} from design_ui_geometry>,
198
+ expected_region: <where the design puts that sheet, same units>
199
+ ```
200
+ - `live_region` rebases the comparison onto the sheet's own box - read it from the `design_ui_geometry` element that IS the sheet container, never from a guess.
201
+ - `expected_region` comes from the Figma frame's placement inside its parent screen frame; with it the engine emits an `inset` finding per edge.
202
+ - `crop_top_live` is ignored when `live_region` is given (the region crop already excluded chrome).
203
+
204
+ **Edge insets are defects, not tolerances.** A design showing a sheet flush to the screen edges is not satisfied by one floating in from them, and the reverse is equally wrong. Report every `inset` finding as a deviation with its px delta; never absorb a side gap as "close enough" and never raise `tolerance_px` to make one disappear. The sheet's internal content padding is measured by the normal element pairing once the region alignment is right.
205
+
206
+ **Component reference** (best-effort): Code Connect atom → attach matching `*.figma.swift`/`*.figma.kt` component render.
207
+ **Fix prompt**: compose a paste-ready developer prompt from the findings.
208
+
209
+ ### 3.5 Close the ledger
210
+
211
+ Every scoped target id ends in exactly one bucket: **covered** (captured AND compared) or **skipped** (with a concrete reason from 3.1 / 3.3). Write `run-state.json` into the Phase 0 report dir with `{ targetIds, covered, skipped }` so `--resume` can pick up the remainder.
212
+
213
+ Before leaving this phase, compare `covered.length + skipped.length` against `scope.targetIds.length`. A mismatch is a set of targets nobody decided about - go back and drive them, or record why they cannot be driven. Reaching Phase 4 with a mismatch is the worst of both worlds: the work is undone AND the run is marked incomplete.
214
+
215
+ ## Phase 4 - Report, coverage gate & export
216
+
217
+ 1. Output dir: `state.designCheck.reportDir`, already created in Phase 0, holding Phase 3's captures and comparison images. Do not mint a second timestamped dir.
218
+ 2. Assemble the report object:
219
+ ```
220
+ { project, module, platform, figmaUrl, figmaFileKey, timestamp, lang: <outputLanguage>,
221
+ coverage: { targets: <scoped target ids/objects>, covered: <audited ids>,
222
+ skipped: [{ id, group, reason }],
223
+ truncatedInventory: <inventory.truncated>,
224
+ floor: <config coverage.floor, optional> },
225
+ variants: [{ name, figmaNodeId, perceptualPct, passed, compareSize, liveSize,
226
+ images, findings, fixPrompt, componentRefs }] }
227
+ ```
228
+ Pass **ids**, not counts: the engine then names each unaccounted target instead of printing an anonymous tally. `compareSize` / `liveSize` come straight from the `design_visual_compare` result.
229
+ 3. Export:
230
+ ```
231
+ mcp__dev-toolkit__design_report({ report, out_dir: state.designCheck.reportDir,
232
+ formats: ["html","pdf"] (+ "confluence" if enabled) })
233
+ ```
234
+ HTML self-contained with the gate banner on top; PDF via Playwright (reports `pdfError` if unavailable); Confluence only if enabled (reuse `multi-agent-channels` adapter), else graceful skip.
235
+ 4. **COVERAGE GATE (blocking, not advisory)** - read `coverage` from the tool result and persist to `state.designCheck.coverage`:
236
+ - `gate: "pass"` → print per-variant PASS/FAIL + findings + report paths.
237
+ - `gate: "fail"` → the run is **INCOMPLETE**. Print `coverageError`, the `unaccountedIds`, and the command that closes the gap (`--resume`). Do not present an incomplete audit as finished, and never pad the covered list to make the gate pass.
238
+
239
+ The gate is a last line of defence, not the plan. If it fires, Phase 3 left work undone - drive the missing targets, then report.
240
+ 5. Remove the worktree unless asked to keep it. The report dir is never removed.
241
+
242
+ ## Notes
243
+
244
+ - Feasibility is real - report honestly and stop when a module has no mock support; never fabricate a partial comparison.
245
+ - **The inventory is the contract**: Phase 0 step 5 decides what "done" means. An audit that visits the linear happy path and lists the rest as "not visited" is the failure mode this pipeline exists to prevent; the gate makes it visible instead of polite.
246
+ - **Chunk with scope, not with silence**: a 50-target module is a legitimate multi-run job. Scope it, close each run's gate, let `--resume` carry the remainder.
247
+ - "Pixel perfect" is perceptual + geometric (scale normalized, chrome cropped); deltas reported in px/pt/hex with a tolerance.
248
+ - The `design_*` engine is generic; project specifics (mock keys, extra launch args / targets, node overrides, status-bar crop, coverage floor, Confluence toggle) come from `design-check-config.json` / prefs, never hardcoded.
@@ -128,6 +128,17 @@ Manual Test (Phase 5 standalone - Xcode hint flow):
128
128
  /multi-agent:manual-test [#N] Checkout task branch, print Xcode/SourceTree hints.
129
129
  (Renamed from :test in v5.7.4.)
130
130
 
131
+ Design Check (mock-mode vs Figma, local-only - dev-toolkit-mcp design_* tools):
132
+
133
+ /multi-agent:design-check Whole-module design audit: enumerate every state driver into a target set,
134
+ /multi-agent:design-check <scope> drive each one in mock mode via idb, compare vs Figma (padding/width/spacing/
135
+ /multi-agent:design-check --resume font/color/component/localization), export HTML+PDF to ~/DesignChecks.
136
+ Scope: empty=module / screen / screen@variant / target-id / Figma URL(s).
137
+ COVERAGE GATE: a target is audited or skipped WITH a reason, else the run
138
+ is reported INCOMPLETE. --resume covers the remainder of the last run.
139
+ Unresolved frame → shows you the screenshot and asks for the node-id.
140
+ Drives dev-toolkit design_* : design_mock_detect / _scenario_inventory / _mock_launch / _ui_geometry / _visual_compare / _report.
141
+
131
142
  ------------------------------------------------------------
132
143
 
133
144
  Setup:
@@ -266,6 +277,17 @@ Manuel Test (Phase 5 standalone - Xcode hint akışı):
266
277
  /multi-agent:manual-test [#N] Task branch'ine checkout, Xcode/SourceTree hint basar.
267
278
  (v5.7.4'te :test'ten :manual-test'e rename.)
268
279
 
280
+ Design Check (mock-mod vs Figma, yalnızca lokal - dev-toolkit-mcp design_* tool'ları):
281
+
282
+ /multi-agent:design-check Tüm modül tasarım denetimi: her state sürücüsünü hedef kümesine çıkar,
283
+ /multi-agent:design-check <scope> her birini mock modda idb ile sür, Figma ile karşılaştır (padding/genişlik/
284
+ /multi-agent:design-check --resume spacing/font/renk/component/localization), HTML+PDF rapor ~/DesignChecks.
285
+ Kapsam: boş=modül / ekran / ekran@varyant / target-id / Figma URL(leri).
286
+ KAPSAM GEÇİDİ: hedef ya denetlenir ya da GEREKÇEYLE atlanır; aksi hâlde
287
+ koşu EKSİK raporlanır. --resume son koşunun kalanını kapatır.
288
+ Figma karşılığı bulunamazsa SANA screenshot'ı gösterip node-id sorar.
289
+ Sürdüğü dev-toolkit design_* : design_mock_detect / _scenario_inventory / _mock_launch / _ui_geometry / _visual_compare / _report.
290
+
269
291
  ------------------------------------------------------------
270
292
 
271
293
  Setup: