ccgx-workflow 1.0.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 (212) hide show
  1. package/LICENSE +22 -0
  2. package/README.md +469 -0
  3. package/README.zh-CN.md +466 -0
  4. package/bin/ccg.mjs +2 -0
  5. package/dist/cli.d.mts +1 -0
  6. package/dist/cli.d.ts +1 -0
  7. package/dist/cli.mjs +173 -0
  8. package/dist/index.d.mts +1774 -0
  9. package/dist/index.d.ts +1774 -0
  10. package/dist/index.mjs +2029 -0
  11. package/dist/shared/ccgx-workflow.WgUzkiC3.mjs +5248 -0
  12. package/package.json +129 -0
  13. package/templates/commands/agents/assumptions-analyzer.md +129 -0
  14. package/templates/commands/agents/code-fixer.md +292 -0
  15. package/templates/commands/agents/codebase-mapper.md +152 -0
  16. package/templates/commands/agents/debug-session-manager.md +247 -0
  17. package/templates/commands/agents/debugger.md +111 -0
  18. package/templates/commands/agents/eval-auditor.md +171 -0
  19. package/templates/commands/agents/framework-selector.md +152 -0
  20. package/templates/commands/agents/get-current-datetime.md +29 -0
  21. package/templates/commands/agents/init-architect.md +114 -0
  22. package/templates/commands/agents/integration-checker.md +163 -0
  23. package/templates/commands/agents/interface-auditor.md +170 -0
  24. package/templates/commands/agents/nyquist-auditor.md +131 -0
  25. package/templates/commands/agents/pattern-mapper.md +111 -0
  26. package/templates/commands/agents/phase-runner.md +321 -0
  27. package/templates/commands/agents/plan-checker.md +255 -0
  28. package/templates/commands/agents/planner.md +320 -0
  29. package/templates/commands/agents/team-architect.md +186 -0
  30. package/templates/commands/agents/team-qa.md +121 -0
  31. package/templates/commands/agents/team-reviewer.md +157 -0
  32. package/templates/commands/agents/ui-ux-designer.md +573 -0
  33. package/templates/commands/agents/verifier.md +274 -0
  34. package/templates/commands/analyze.md +210 -0
  35. package/templates/commands/autonomous.md +792 -0
  36. package/templates/commands/cancel.md +132 -0
  37. package/templates/commands/clean-branches.md +117 -0
  38. package/templates/commands/codex-exec.md +404 -0
  39. package/templates/commands/commit.md +151 -0
  40. package/templates/commands/context.md +332 -0
  41. package/templates/commands/debate.md +165 -0
  42. package/templates/commands/debug.md +226 -0
  43. package/templates/commands/enhance.md +64 -0
  44. package/templates/commands/execute.md +380 -0
  45. package/templates/commands/init.md +123 -0
  46. package/templates/commands/optimize.md +217 -0
  47. package/templates/commands/plan.md +373 -0
  48. package/templates/commands/result.md +106 -0
  49. package/templates/commands/review.md +338 -0
  50. package/templates/commands/rollback.md +116 -0
  51. package/templates/commands/spec-impl.md +139 -0
  52. package/templates/commands/spec-init.md +101 -0
  53. package/templates/commands/spec-plan.md +210 -0
  54. package/templates/commands/spec-research.md +152 -0
  55. package/templates/commands/spec-review.md +120 -0
  56. package/templates/commands/status.md +206 -0
  57. package/templates/commands/team-exec.md +265 -0
  58. package/templates/commands/test.md +236 -0
  59. package/templates/commands/verify-work.md +338 -0
  60. package/templates/commands/verify.md +66 -0
  61. package/templates/commands/workflow.md +190 -0
  62. package/templates/commands/worktree.md +128 -0
  63. package/templates/hooks/ccg-context-monitor.js +159 -0
  64. package/templates/hooks/ccg-session-state.cjs +510 -0
  65. package/templates/hooks/ccg-statusline.js +142 -0
  66. package/templates/output-styles/abyss-command.md +56 -0
  67. package/templates/output-styles/abyss-concise.md +89 -0
  68. package/templates/output-styles/abyss-cultivator.md +302 -0
  69. package/templates/output-styles/abyss-ritual.md +70 -0
  70. package/templates/output-styles/engineer-professional.md +89 -0
  71. package/templates/output-styles/laowang-engineer.md +127 -0
  72. package/templates/output-styles/nekomata-engineer.md +120 -0
  73. package/templates/output-styles/ojousama-engineer.md +121 -0
  74. package/templates/prompts/claude/analyzer.md +59 -0
  75. package/templates/prompts/claude/architect.md +54 -0
  76. package/templates/prompts/claude/debugger.md +71 -0
  77. package/templates/prompts/claude/optimizer.md +73 -0
  78. package/templates/prompts/claude/reviewer.md +63 -0
  79. package/templates/prompts/claude/tester.md +69 -0
  80. package/templates/prompts/codex/analyzer.md +58 -0
  81. package/templates/prompts/codex/architect.md +54 -0
  82. package/templates/prompts/codex/debugger.md +74 -0
  83. package/templates/prompts/codex/optimizer.md +81 -0
  84. package/templates/prompts/codex/reviewer.md +73 -0
  85. package/templates/prompts/codex/tester.md +62 -0
  86. package/templates/prompts/gemini/analyzer.md +61 -0
  87. package/templates/prompts/gemini/architect.md +55 -0
  88. package/templates/prompts/gemini/debugger.md +78 -0
  89. package/templates/prompts/gemini/frontend.md +64 -0
  90. package/templates/prompts/gemini/optimizer.md +84 -0
  91. package/templates/prompts/gemini/reviewer.md +80 -0
  92. package/templates/prompts/gemini/tester.md +68 -0
  93. package/templates/rules/ccg-skill-routing.md +83 -0
  94. package/templates/rules/ccg-skills.md +71 -0
  95. package/templates/scripts/ccg-phase-runner-launcher.mjs +467 -0
  96. package/templates/scripts/invoke-model.mjs +949 -0
  97. package/templates/scripts/repatch-gemini-plugin.mjs +194 -0
  98. package/templates/skills/SKILL.md +92 -0
  99. package/templates/skills/domains/ai/SKILL.md +35 -0
  100. package/templates/skills/domains/ai/agent-dev.md +242 -0
  101. package/templates/skills/domains/ai/llm-security.md +288 -0
  102. package/templates/skills/domains/ai/prompt-and-eval.md +279 -0
  103. package/templates/skills/domains/ai/rag-system.md +542 -0
  104. package/templates/skills/domains/architecture/SKILL.md +43 -0
  105. package/templates/skills/domains/architecture/api-design.md +225 -0
  106. package/templates/skills/domains/architecture/caching.md +299 -0
  107. package/templates/skills/domains/architecture/cloud-native.md +285 -0
  108. package/templates/skills/domains/architecture/message-queue.md +329 -0
  109. package/templates/skills/domains/architecture/security-arch.md +297 -0
  110. package/templates/skills/domains/data-engineering/SKILL.md +208 -0
  111. package/templates/skills/domains/development/SKILL.md +47 -0
  112. package/templates/skills/domains/development/cpp.md +246 -0
  113. package/templates/skills/domains/development/go.md +323 -0
  114. package/templates/skills/domains/development/java.md +277 -0
  115. package/templates/skills/domains/development/python.md +288 -0
  116. package/templates/skills/domains/development/rust.md +313 -0
  117. package/templates/skills/domains/development/shell.md +313 -0
  118. package/templates/skills/domains/development/typescript.md +277 -0
  119. package/templates/skills/domains/devops/SKILL.md +40 -0
  120. package/templates/skills/domains/devops/cost-optimization.md +272 -0
  121. package/templates/skills/domains/devops/database.md +217 -0
  122. package/templates/skills/domains/devops/devsecops.md +198 -0
  123. package/templates/skills/domains/devops/git-workflow.md +181 -0
  124. package/templates/skills/domains/devops/observability.md +280 -0
  125. package/templates/skills/domains/devops/performance.md +336 -0
  126. package/templates/skills/domains/devops/testing.md +283 -0
  127. package/templates/skills/domains/frontend-design/SKILL.md +244 -0
  128. package/templates/skills/domains/frontend-design/agents/openai.yaml +4 -0
  129. package/templates/skills/domains/frontend-design/claymorphism/SKILL.md +121 -0
  130. package/templates/skills/domains/frontend-design/claymorphism/references/tokens.css +52 -0
  131. package/templates/skills/domains/frontend-design/component-patterns.md +202 -0
  132. package/templates/skills/domains/frontend-design/engineering.md +287 -0
  133. package/templates/skills/domains/frontend-design/glassmorphism/SKILL.md +142 -0
  134. package/templates/skills/domains/frontend-design/glassmorphism/references/tokens.css +32 -0
  135. package/templates/skills/domains/frontend-design/liquid-glass/SKILL.md +139 -0
  136. package/templates/skills/domains/frontend-design/liquid-glass/references/tokens.css +81 -0
  137. package/templates/skills/domains/frontend-design/neubrutalism/SKILL.md +145 -0
  138. package/templates/skills/domains/frontend-design/neubrutalism/references/tokens.css +44 -0
  139. package/templates/skills/domains/frontend-design/reference/color-and-contrast.md +132 -0
  140. package/templates/skills/domains/frontend-design/reference/interaction-design.md +195 -0
  141. package/templates/skills/domains/frontend-design/reference/motion-design.md +99 -0
  142. package/templates/skills/domains/frontend-design/reference/responsive-design.md +114 -0
  143. package/templates/skills/domains/frontend-design/reference/spatial-design.md +100 -0
  144. package/templates/skills/domains/frontend-design/reference/typography.md +133 -0
  145. package/templates/skills/domains/frontend-design/reference/ux-writing.md +107 -0
  146. package/templates/skills/domains/frontend-design/state-management.md +680 -0
  147. package/templates/skills/domains/frontend-design/ui-aesthetics.md +110 -0
  148. package/templates/skills/domains/frontend-design/ux-principles.md +156 -0
  149. package/templates/skills/domains/infrastructure/SKILL.md +201 -0
  150. package/templates/skills/domains/mobile/SKILL.md +225 -0
  151. package/templates/skills/domains/orchestration/SKILL.md +30 -0
  152. package/templates/skills/domains/orchestration/multi-agent.md +263 -0
  153. package/templates/skills/domains/security/SKILL.md +73 -0
  154. package/templates/skills/domains/security/blue-team.md +436 -0
  155. package/templates/skills/domains/security/code-audit.md +265 -0
  156. package/templates/skills/domains/security/pentest.md +226 -0
  157. package/templates/skills/domains/security/red-team.md +374 -0
  158. package/templates/skills/domains/security/threat-intel.md +372 -0
  159. package/templates/skills/domains/security/vuln-research.md +369 -0
  160. package/templates/skills/impeccable/adapt/SKILL.md +201 -0
  161. package/templates/skills/impeccable/animate/SKILL.md +176 -0
  162. package/templates/skills/impeccable/arrange/SKILL.md +126 -0
  163. package/templates/skills/impeccable/audit/SKILL.md +149 -0
  164. package/templates/skills/impeccable/bolder/SKILL.md +118 -0
  165. package/templates/skills/impeccable/clarify/SKILL.md +185 -0
  166. package/templates/skills/impeccable/colorize/SKILL.md +144 -0
  167. package/templates/skills/impeccable/critique/SKILL.md +203 -0
  168. package/templates/skills/impeccable/critique/reference/cognitive-load.md +106 -0
  169. package/templates/skills/impeccable/critique/reference/heuristics-scoring.md +234 -0
  170. package/templates/skills/impeccable/critique/reference/personas.md +178 -0
  171. package/templates/skills/impeccable/delight/SKILL.md +305 -0
  172. package/templates/skills/impeccable/distill/SKILL.md +123 -0
  173. package/templates/skills/impeccable/extract/SKILL.md +94 -0
  174. package/templates/skills/impeccable/harden/SKILL.md +357 -0
  175. package/templates/skills/impeccable/normalize/SKILL.md +72 -0
  176. package/templates/skills/impeccable/onboard/SKILL.md +248 -0
  177. package/templates/skills/impeccable/optimize/SKILL.md +268 -0
  178. package/templates/skills/impeccable/overdrive/SKILL.md +143 -0
  179. package/templates/skills/impeccable/polish/SKILL.md +205 -0
  180. package/templates/skills/impeccable/quieter/SKILL.md +104 -0
  181. package/templates/skills/impeccable/teach-impeccable/SKILL.md +72 -0
  182. package/templates/skills/impeccable/typeset/SKILL.md +117 -0
  183. package/templates/skills/orchestration/multi-agent/SKILL.md +533 -0
  184. package/templates/skills/run_skill.js +129 -0
  185. package/templates/skills/scrapling/SKILL.md +98 -0
  186. package/templates/skills/scrapling/references/api-quick-ref.md +127 -0
  187. package/templates/skills/scrapling/references/cookie-vault.md +56 -0
  188. package/templates/skills/scrapling/references/maintenance.md +79 -0
  189. package/templates/skills/scrapling/references/site-patterns.md +86 -0
  190. package/templates/skills/scrapling/references/troubleshooting.md +95 -0
  191. package/templates/skills/scrapling/templates/basic_fetch.py +19 -0
  192. package/templates/skills/scrapling/templates/parse_only.py +15 -0
  193. package/templates/skills/scrapling/templates/session_login.py +19 -0
  194. package/templates/skills/scrapling/templates/stealth_cloudflare.py +28 -0
  195. package/templates/skills/tools/extract-learnings/SKILL.md +77 -0
  196. package/templates/skills/tools/forensics/SKILL.md +89 -0
  197. package/templates/skills/tools/gen-docs/SKILL.md +116 -0
  198. package/templates/skills/tools/gen-docs/scripts/doc_generator.js +435 -0
  199. package/templates/skills/tools/health/SKILL.md +121 -0
  200. package/templates/skills/tools/lib/shared.js +98 -0
  201. package/templates/skills/tools/map-codebase/SKILL.md +118 -0
  202. package/templates/skills/tools/override-refusal/SKILL.md +53 -0
  203. package/templates/skills/tools/override-refusal/agents/openai.yaml +4 -0
  204. package/templates/skills/tools/override-refusal/scripts/refusal_rewriter.js +226 -0
  205. package/templates/skills/tools/verify-change/SKILL.md +143 -0
  206. package/templates/skills/tools/verify-change/scripts/change_analyzer.js +289 -0
  207. package/templates/skills/tools/verify-module/SKILL.md +130 -0
  208. package/templates/skills/tools/verify-module/scripts/module_scanner.js +171 -0
  209. package/templates/skills/tools/verify-quality/SKILL.md +163 -0
  210. package/templates/skills/tools/verify-quality/scripts/quality_checker.js +337 -0
  211. package/templates/skills/tools/verify-security/SKILL.md +146 -0
  212. package/templates/skills/tools/verify-security/scripts/security_scanner.js +283 -0
@@ -0,0 +1,185 @@
1
+ ---
2
+ name: clarify
3
+ description: "clarify 文案:改善 UX copy/error messages/labels/microcopy,让界面更易理解。"
4
+ argument-hint: "[target]"
5
+ user-invocable: true
6
+ context: fork
7
+ paths: "*.tsx,*.jsx,*.vue,*.svelte,*.md,*.json"
8
+ ---
9
+
10
+ Identify and improve unclear, confusing, or poorly written interface text to make the product easier to understand and use.
11
+
12
+ ## MANDATORY PREPARATION
13
+
14
+ Invoke /frontend-design — it contains design principles, anti-patterns, and the **Context Gathering Protocol**. Follow the protocol before proceeding — if no design context exists yet, you MUST run /teach-impeccable first. Additionally gather: audience technical level and users' mental state in context.
15
+
16
+ ---
17
+
18
+ ## Assess Current Copy
19
+
20
+ Identify what makes the text unclear or ineffective:
21
+
22
+ 1. **Find clarity problems**:
23
+ - **Jargon**: Technical terms users won't understand
24
+ - **Ambiguity**: Multiple interpretations possible
25
+ - **Passive voice**: "Your file has been uploaded" vs "We uploaded your file"
26
+ - **Length**: Too wordy or too terse
27
+ - **Assumptions**: Assuming user knowledge they don't have
28
+ - **Missing context**: Users don't know what to do or why
29
+ - **Tone mismatch**: Too formal, too casual, or inappropriate for situation
30
+
31
+ 2. **Understand the context**:
32
+ - Who's the audience? (Technical? General? First-time users?)
33
+ - What's the user's mental state? (Stressed during error? Confident during success?)
34
+ - What's the action? (What do we want users to do?)
35
+ - What's the constraint? (Character limits? Space limitations?)
36
+
37
+ **CRITICAL**: Clear copy helps users succeed. Unclear copy creates frustration, errors, and support tickets.
38
+
39
+ ## Plan Copy Improvements
40
+
41
+ Create a strategy for clearer communication:
42
+
43
+ - **Primary message**: What's the ONE thing users need to know?
44
+ - **Action needed**: What should users do next (if anything)?
45
+ - **Tone**: How should this feel? (Helpful? Apologetic? Encouraging?)
46
+ - **Constraints**: Length limits, brand voice, localization considerations
47
+
48
+ **IMPORTANT**: Good UX writing is invisible. Users should understand immediately without noticing the words.
49
+
50
+ ## Improve Copy Systematically
51
+
52
+ Refine text across these common areas:
53
+
54
+ ### Error Messages
55
+ **Bad**: "Error 403: Forbidden"
56
+ **Good**: "You don't have permission to view this page. Contact your admin for access."
57
+
58
+ **Bad**: "Invalid input"
59
+ **Good**: "Email addresses need an @ symbol. Try: name@example.com"
60
+
61
+ **Principles**:
62
+ - Explain what went wrong in plain language
63
+ - Suggest how to fix it
64
+ - Don't blame the user
65
+ - Include examples when helpful
66
+ - Link to help/support if applicable
67
+
68
+ ### Form Labels & Instructions
69
+ **Bad**: "DOB (MM/DD/YYYY)"
70
+ **Good**: "Date of birth" (with placeholder showing format)
71
+
72
+ **Bad**: "Enter value here"
73
+ **Good**: "Your email address" or "Company name"
74
+
75
+ **Principles**:
76
+ - Use clear, specific labels (not generic placeholders)
77
+ - Show format expectations with examples
78
+ - Explain why you're asking (when not obvious)
79
+ - Put instructions before the field, not after
80
+ - Keep required field indicators clear
81
+
82
+ ### Button & CTA Text
83
+ **Bad**: "Click here" | "Submit" | "OK"
84
+ **Good**: "Create account" | "Save changes" | "Got it, thanks"
85
+
86
+ **Principles**:
87
+ - Describe the action specifically
88
+ - Use active voice (verb + noun)
89
+ - Match user's mental model
90
+ - Be specific ("Save" is better than "OK")
91
+
92
+ ### Help Text & Tooltips
93
+ **Bad**: "This is the username field"
94
+ **Good**: "Choose a username. You can change this later in Settings."
95
+
96
+ **Principles**:
97
+ - Add value (don't just repeat the label)
98
+ - Answer the implicit question ("What is this?" or "Why do you need this?")
99
+ - Keep it brief but complete
100
+ - Link to detailed docs if needed
101
+
102
+ ### Empty States
103
+ **Bad**: "No items"
104
+ **Good**: "No projects yet. Create your first project to get started."
105
+
106
+ **Principles**:
107
+ - Explain why it's empty (if not obvious)
108
+ - Show next action clearly
109
+ - Make it welcoming, not dead-end
110
+
111
+ ### Success Messages
112
+ **Bad**: "Success"
113
+ **Good**: "Settings saved! Your changes will take effect immediately."
114
+
115
+ **Principles**:
116
+ - Confirm what happened
117
+ - Explain what happens next (if relevant)
118
+ - Be brief but complete
119
+ - Match the user's emotional moment (celebrate big wins)
120
+
121
+ ### Loading States
122
+ **Bad**: "Loading..." (for 30+ seconds)
123
+ **Good**: "Analyzing your data... this usually takes 30-60 seconds"
124
+
125
+ **Principles**:
126
+ - Set expectations (how long?)
127
+ - Explain what's happening (when it's not obvious)
128
+ - Show progress when possible
129
+ - Offer escape hatch if appropriate ("Cancel")
130
+
131
+ ### Confirmation Dialogs
132
+ **Bad**: "Are you sure?"
133
+ **Good**: "Delete 'Project Alpha'? This can't be undone."
134
+
135
+ **Principles**:
136
+ - State the specific action
137
+ - Explain consequences (especially for destructive actions)
138
+ - Use clear button labels ("Delete project" not "Yes")
139
+ - Don't overuse confirmations (only for risky actions)
140
+
141
+ ### Navigation & Wayfinding
142
+ **Bad**: Generic labels like "Items" | "Things" | "Stuff"
143
+ **Good**: Specific labels like "Your projects" | "Team members" | "Settings"
144
+
145
+ **Principles**:
146
+ - Be specific and descriptive
147
+ - Use language users understand (not internal jargon)
148
+ - Make hierarchy clear
149
+ - Consider information scent (breadcrumbs, current location)
150
+
151
+ ## Apply Clarity Principles
152
+
153
+ Every piece of copy should follow these rules:
154
+
155
+ 1. **Be specific**: "Enter email" not "Enter value"
156
+ 2. **Be concise**: Cut unnecessary words (but don't sacrifice clarity)
157
+ 3. **Be active**: "Save changes" not "Changes will be saved"
158
+ 4. **Be human**: "Oops, something went wrong" not "System error encountered"
159
+ 5. **Be helpful**: Tell users what to do, not just what happened
160
+ 6. **Be consistent**: Use same terms throughout (don't vary for variety)
161
+
162
+ **NEVER**:
163
+ - Use jargon without explanation
164
+ - Blame users ("You made an error" → "This field is required")
165
+ - Be vague ("Something went wrong" without explanation)
166
+ - Use passive voice unnecessarily
167
+ - Write overly long explanations (be concise)
168
+ - Use humor for errors (be empathetic instead)
169
+ - Assume technical knowledge
170
+ - Vary terminology (pick one term and stick with it)
171
+ - Repeat information (headers restating intros, redundant explanations)
172
+ - Use placeholders as the only labels (they disappear when users type)
173
+
174
+ ## Verify Improvements
175
+
176
+ Test that copy improvements work:
177
+
178
+ - **Comprehension**: Can users understand without context?
179
+ - **Actionability**: Do users know what to do next?
180
+ - **Brevity**: Is it as short as possible while remaining clear?
181
+ - **Consistency**: Does it match terminology elsewhere?
182
+ - **Tone**: Is it appropriate for the situation?
183
+
184
+ Remember: You're a clarity expert with excellent communication skills. Write like you're explaining to a smart friend who's unfamiliar with the product. Be clear, be helpful, be human.
185
+
@@ -0,0 +1,144 @@
1
+ ---
2
+ name: colorize
3
+ description: "colorize 上色:为单调/灰暗的设计加入战略性 color/palette,让界面更有表现力。"
4
+ argument-hint: "[target]"
5
+ user-invocable: true
6
+ context: fork
7
+ paths: "*.tsx,*.jsx,*.vue,*.svelte,*.css,*.scss"
8
+ ---
9
+
10
+ Strategically introduce color to designs that are too monochromatic, gray, or lacking in visual warmth and personality.
11
+
12
+ ## MANDATORY PREPARATION
13
+
14
+ Invoke /frontend-design — it contains design principles, anti-patterns, and the **Context Gathering Protocol**. Follow the protocol before proceeding — if no design context exists yet, you MUST run /teach-impeccable first. Additionally gather: existing brand colors.
15
+
16
+ ---
17
+
18
+ ## Assess Color Opportunity
19
+
20
+ Analyze the current state and identify opportunities:
21
+
22
+ 1. **Understand current state**:
23
+ - **Color absence**: Pure grayscale? Limited neutrals? One timid accent?
24
+ - **Missed opportunities**: Where could color add meaning, hierarchy, or delight?
25
+ - **Context**: What's appropriate for this domain and audience?
26
+ - **Brand**: Are there existing brand colors we should use?
27
+
28
+ 2. **Identify where color adds value**:
29
+ - **Semantic meaning**: Success (green), error (red), warning (yellow/orange), info (blue)
30
+ - **Hierarchy**: Drawing attention to important elements
31
+ - **Categorization**: Different sections, types, or states
32
+ - **Emotional tone**: Warmth, energy, trust, creativity
33
+ - **Wayfinding**: Helping users navigate and understand structure
34
+ - **Delight**: Moments of visual interest and personality
35
+
36
+ If any of these are unclear from the codebase, Ask the user using AskUserQuestion.
37
+
38
+ **CRITICAL**: More color ≠ better. Strategic color beats rainbow vomit every time. Every color should have a purpose.
39
+
40
+ ## Plan Color Strategy
41
+
42
+ Create a purposeful color introduction plan:
43
+
44
+ - **Color palette**: What colors match the brand/context? (Choose 2-4 colors max beyond neutrals)
45
+ - **Dominant color**: Which color owns 60% of colored elements?
46
+ - **Accent colors**: Which colors provide contrast and highlights? (30% and 10%)
47
+ - **Application strategy**: Where does each color appear and why?
48
+
49
+ **IMPORTANT**: Color should enhance hierarchy and meaning, not create chaos. Less is more when it matters more.
50
+
51
+ ## Introduce Color Strategically
52
+
53
+ Add color systematically across these dimensions:
54
+
55
+ ### Semantic Color
56
+ - **State indicators**:
57
+ - Success: Green tones (emerald, forest, mint)
58
+ - Error: Red/pink tones (rose, crimson, coral)
59
+ - Warning: Orange/amber tones
60
+ - Info: Blue tones (sky, ocean, indigo)
61
+ - Neutral: Gray/slate for inactive states
62
+
63
+ - **Status badges**: Colored backgrounds or borders for states (active, pending, completed, etc.)
64
+ - **Progress indicators**: Colored bars, rings, or charts showing completion or health
65
+
66
+ ### Accent Color Application
67
+ - **Primary actions**: Color the most important buttons/CTAs
68
+ - **Links**: Add color to clickable text (maintain accessibility)
69
+ - **Icons**: Colorize key icons for recognition and personality
70
+ - **Headers/titles**: Add color to section headers or key labels
71
+ - **Hover states**: Introduce color on interaction
72
+
73
+ ### Background & Surfaces
74
+ - **Tinted backgrounds**: Replace pure gray (`#f5f5f5`) with warm neutrals (`oklch(97% 0.01 60)`) or cool tints (`oklch(97% 0.01 250)`)
75
+ - **Colored sections**: Use subtle background colors to separate areas
76
+ - **Gradient backgrounds**: Add depth with subtle, intentional gradients (not generic purple-blue)
77
+ - **Cards & surfaces**: Tint cards or surfaces slightly for warmth
78
+
79
+ **Use OKLCH for color**: It's perceptually uniform, meaning equal steps in lightness *look* equal. Great for generating harmonious scales.
80
+
81
+ ### Data Visualization
82
+ - **Charts & graphs**: Use color to encode categories or values
83
+ - **Heatmaps**: Color intensity shows density or importance
84
+ - **Comparison**: Color coding for different datasets or timeframes
85
+
86
+ ### Borders & Accents
87
+ - **Accent borders**: Add colored left/top borders to cards or sections
88
+ - **Underlines**: Color underlines for emphasis or active states
89
+ - **Dividers**: Subtle colored dividers instead of gray lines
90
+ - **Focus rings**: Colored focus indicators matching brand
91
+
92
+ ### Typography Color
93
+ - **Colored headings**: Use brand colors for section headings (maintain contrast)
94
+ - **Highlight text**: Color for emphasis or categories
95
+ - **Labels & tags**: Small colored labels for metadata or categories
96
+
97
+ ### Decorative Elements
98
+ - **Illustrations**: Add colored illustrations or icons
99
+ - **Shapes**: Geometric shapes in brand colors as background elements
100
+ - **Gradients**: Colorful gradient overlays or mesh backgrounds
101
+ - **Blobs/organic shapes**: Soft colored shapes for visual interest
102
+
103
+ ## Balance & Refinement
104
+
105
+ Ensure color addition improves rather than overwhelms:
106
+
107
+ ### Maintain Hierarchy
108
+ - **Dominant color** (60%): Primary brand color or most used accent
109
+ - **Secondary color** (30%): Supporting color for variety
110
+ - **Accent color** (10%): High contrast for key moments
111
+ - **Neutrals** (remaining): Gray/black/white for structure
112
+
113
+ ### Accessibility
114
+ - **Contrast ratios**: Ensure WCAG compliance (4.5:1 for text, 3:1 for UI components)
115
+ - **Don't rely on color alone**: Use icons, labels, or patterns alongside color
116
+ - **Test for color blindness**: Verify red/green combinations work for all users
117
+
118
+ ### Cohesion
119
+ - **Consistent palette**: Use colors from defined palette, not arbitrary choices
120
+ - **Systematic application**: Same color meanings throughout (green always = success)
121
+ - **Temperature consistency**: Warm palette stays warm, cool stays cool
122
+
123
+ **NEVER**:
124
+ - Use every color in the rainbow (choose 2-4 colors beyond neutrals)
125
+ - Apply color randomly without semantic meaning
126
+ - Put gray text on colored backgrounds—it looks washed out; use a darker shade of the background color or transparency instead
127
+ - Use pure gray for neutrals—add subtle color tint (warm or cool) for sophistication
128
+ - Use pure black (`#000`) or pure white (`#fff`) for large areas
129
+ - Violate WCAG contrast requirements
130
+ - Use color as the only indicator (accessibility issue)
131
+ - Make everything colorful (defeats the purpose)
132
+ - Default to purple-blue gradients (AI slop aesthetic)
133
+
134
+ ## Verify Color Addition
135
+
136
+ Test that colorization improves the experience:
137
+
138
+ - **Better hierarchy**: Does color guide attention appropriately?
139
+ - **Clearer meaning**: Does color help users understand states/categories?
140
+ - **More engaging**: Does the interface feel warmer and more inviting?
141
+ - **Still accessible**: Do all color combinations meet WCAG standards?
142
+ - **Not overwhelming**: Is color balanced and purposeful?
143
+
144
+ Remember: Color is emotional and powerful. Use it to create warmth, guide attention, communicate meaning, and express personality. But restraint and strategy matter more than saturation and variety. Be colorful, but be intentional.
@@ -0,0 +1,203 @@
1
+ ---
2
+ name: critique
3
+ description: "critique UX 评估:视觉层级/信息架构/情感共鸣/认知负荷量化打分 + persona 测试。"
4
+ argument-hint: "[area (feature, page, component...)]"
5
+ user-invocable: true
6
+ context: fork
7
+ paths: "*.tsx,*.jsx,*.vue,*.svelte,*.css,*.scss"
8
+ ---
9
+
10
+ ## MANDATORY PREPARATION
11
+
12
+ Invoke /frontend-design — it contains design principles, anti-patterns, and the **Context Gathering Protocol**. Follow the protocol before proceeding — if no design context exists yet, you MUST run /teach-impeccable first. Additionally gather: what the interface is trying to accomplish.
13
+
14
+ ---
15
+
16
+ Conduct a holistic design critique, evaluating whether the interface actually works — not just technically, but as a designed experience. Think like a design director giving feedback.
17
+
18
+ ## Phase 1: Design Critique
19
+
20
+ Evaluate the interface across these dimensions:
21
+
22
+ ### 1. AI Slop Detection (CRITICAL)
23
+
24
+ **This is the most important check.** Does this look like every other AI-generated interface from 2024-2025?
25
+
26
+ Review the design against ALL the **DON'T** guidelines in the frontend-design skill — they are the fingerprints of AI-generated work. Check for the AI color palette, gradient text, dark mode with glowing accents, glassmorphism, hero metric layouts, identical card grids, generic fonts, and all other tells.
27
+
28
+ **The test**: If you showed this to someone and said "AI made this," would they believe you immediately? If yes, that's the problem.
29
+
30
+ ### 2. Visual Hierarchy
31
+ - Does the eye flow to the most important element first?
32
+ - Is there a clear primary action? Can you spot it in 2 seconds?
33
+ - Do size, color, and position communicate importance correctly?
34
+ - Is there visual competition between elements that should have different weights?
35
+
36
+ ### 3. Information Architecture & Cognitive Load
37
+ > *Consult [cognitive-load](reference/cognitive-load.md) for the working memory rule and 8-item checklist*
38
+ - Is the structure intuitive? Would a new user understand the organization?
39
+ - Is related content grouped logically?
40
+ - Are there too many choices at once? Count visible options at each decision point — if >4, flag it
41
+ - Is the navigation clear and predictable?
42
+ - **Progressive disclosure**: Is complexity revealed only when needed, or dumped on the user upfront?
43
+ - **Run the 8-item cognitive load checklist** from the reference. Report failure count: 0–1 = low (good), 2–3 = moderate, 4+ = critical.
44
+
45
+ ### 4. Emotional Journey
46
+ - What emotion does this interface evoke? Is that intentional?
47
+ - Does it match the brand personality?
48
+ - Does it feel trustworthy, approachable, premium, playful — whatever it should feel?
49
+ - Would the target user feel "this is for me"?
50
+ - **Peak-end rule**: Is the most intense moment positive? Does the experience end well (confirmation, celebration, clear next step)?
51
+ - **Emotional valleys**: Check for onboarding frustration, error cliffs, feature discovery gaps, or anxiety spikes at high-stakes moments (payment, delete, commit)
52
+ - **Interventions at negative moments**: Are there design interventions where users are likely to feel frustrated or anxious? (progress indicators, reassurance copy, undo options, social proof)
53
+
54
+ ### 5. Discoverability & Affordance
55
+ - Are interactive elements obviously interactive?
56
+ - Would a user know what to do without instructions?
57
+ - Are hover/focus states providing useful feedback?
58
+ - Are there hidden features that should be more visible?
59
+
60
+ ### 6. Composition & Balance
61
+ - Does the layout feel balanced or uncomfortably weighted?
62
+ - Is whitespace used intentionally or just leftover?
63
+ - Is there visual rhythm in spacing and repetition?
64
+ - Does asymmetry feel designed or accidental?
65
+
66
+ ### 7. Typography as Communication
67
+ - Does the type hierarchy clearly signal what to read first, second, third?
68
+ - Is body text comfortable to read? (line length, spacing, size)
69
+ - Do font choices reinforce the brand/tone?
70
+ - Is there enough contrast between heading levels?
71
+
72
+ ### 8. Color with Purpose
73
+ - Is color used to communicate, not just decorate?
74
+ - Does the palette feel cohesive?
75
+ - Are accent colors drawing attention to the right things?
76
+ - Does it work for colorblind users? (not just technically — does meaning still come through?)
77
+
78
+ ### 9. States & Edge Cases
79
+ - Empty states: Do they guide users toward action, or just say "nothing here"?
80
+ - Loading states: Do they reduce perceived wait time?
81
+ - Error states: Are they helpful and non-blaming?
82
+ - Success states: Do they confirm and guide next steps?
83
+
84
+ ### 10. Microcopy & Voice
85
+ - Is the writing clear and concise?
86
+ - Does it sound like a human (the right human for this brand)?
87
+ - Are labels and buttons unambiguous?
88
+ - Does error copy help users fix the problem?
89
+
90
+ ## Phase 2: Present Findings
91
+
92
+ Structure your feedback as a design director would:
93
+
94
+ ### Design Health Score
95
+ > *Consult [heuristics-scoring](reference/heuristics-scoring.md)*
96
+
97
+ Score each of Nielsen's 10 heuristics 0–4. Present as a table:
98
+
99
+ | # | Heuristic | Score | Key Issue |
100
+ |---|-----------|-------|-----------|
101
+ | 1 | Visibility of System Status | ? | [specific finding or "—" if solid] |
102
+ | 2 | Match System / Real World | ? | |
103
+ | 3 | User Control and Freedom | ? | |
104
+ | 4 | Consistency and Standards | ? | |
105
+ | 5 | Error Prevention | ? | |
106
+ | 6 | Recognition Rather Than Recall | ? | |
107
+ | 7 | Flexibility and Efficiency | ? | |
108
+ | 8 | Aesthetic and Minimalist Design | ? | |
109
+ | 9 | Error Recovery | ? | |
110
+ | 10 | Help and Documentation | ? | |
111
+ | **Total** | | **??/40** | **[Rating band]** |
112
+
113
+ Be honest with scores. A 4 means genuinely excellent. Most real interfaces score 20–32.
114
+
115
+ ### Anti-Patterns Verdict
116
+ **Start here.** Pass/fail: Does this look AI-generated? List specific tells from the skill's Anti-Patterns section. Be brutally honest.
117
+
118
+ ### Overall Impression
119
+ A brief gut reaction — what works, what doesn't, and the single biggest opportunity.
120
+
121
+ ### What's Working
122
+ Highlight 2–3 things done well. Be specific about why they work.
123
+
124
+ ### Priority Issues
125
+ The 3–5 most impactful design problems, ordered by importance.
126
+
127
+ For each issue, tag with **P0–P3 severity** (consult [heuristics-scoring](reference/heuristics-scoring.md) for severity definitions):
128
+ - **[P?] What**: Name the problem clearly
129
+ - **Why it matters**: How this hurts users or undermines goals
130
+ - **Fix**: What to do about it (be concrete)
131
+ - **Suggested command**: Which command could address this (from: /audit, /critique, /normalize, /polish, /distill, /clarify, /optimize, /harden, /animate, /colorize, /bolder, /quieter, /delight, /extract, /adapt, /onboard, /typeset, /arrange, /overdrive, /teach-impeccable)
132
+
133
+ ### Persona Red Flags
134
+ > *Consult [personas](reference/personas.md)*
135
+
136
+ Auto-select 2–3 personas most relevant to this interface type (use the selection table in the reference). If `CLAUDE.md` contains a `## Design Context` section from `teach-impeccable`, also generate 1–2 project-specific personas from the audience/brand info.
137
+
138
+ For each selected persona, walk through the primary user action and list specific red flags found:
139
+
140
+ **Alex (Power User)**: No keyboard shortcuts detected. Form requires 8 clicks for primary action. Forced modal onboarding. ⚠️ High abandonment risk.
141
+
142
+ **Jordan (First-Timer)**: Icon-only nav in sidebar. Technical jargon in error messages ("404 Not Found"). No visible help. ⚠️ Will abandon at step 2.
143
+
144
+ Be specific — name the exact elements and interactions that fail each persona. Don't write generic persona descriptions; write what broke for them.
145
+
146
+ ### Minor Observations
147
+ Quick notes on smaller issues worth addressing.
148
+
149
+ **Remember**:
150
+ - Be direct — vague feedback wastes everyone's time
151
+ - Be specific — "the submit button" not "some elements"
152
+ - Say what's wrong AND why it matters to users
153
+ - Give concrete suggestions, not just "consider exploring..."
154
+ - Prioritize ruthlessly — if everything is important, nothing is
155
+ - Don't soften criticism — developers need honest feedback to ship great design
156
+
157
+ ## Phase 3: Ask the User
158
+
159
+ **After presenting findings**, use targeted questions based on what was actually found. Ask the user using AskUserQuestion. These answers will shape the action plan.
160
+
161
+ Ask questions along these lines (adapt to the specific findings — do NOT ask generic questions):
162
+
163
+ 1. **Priority direction**: Based on the issues found, ask which category matters most to the user right now. For example: "I found problems with visual hierarchy, color usage, and information overload. Which area should we tackle first?" Offer the top 2–3 issue categories as options.
164
+
165
+ 2. **Design intent**: If the critique found a tonal mismatch, ask whether it was intentional. For example: "The interface feels clinical and corporate. Is that the intended tone, or should it feel warmer/bolder/more playful?" Offer 2–3 tonal directions as options based on what would fix the issues found.
166
+
167
+ 3. **Scope**: Ask how much the user wants to take on. For example: "I found N issues. Want to address everything, or focus on the top 3?" Offer scope options like "Top 3 only", "All issues", "Critical issues only".
168
+
169
+ 4. **Constraints** (optional — only ask if relevant): If the findings touch many areas, ask if anything is off-limits. For example: "Should any sections stay as-is?" This prevents the plan from touching things the user considers done.
170
+
171
+ **Rules for questions**:
172
+ - Every question must reference specific findings from Phase 2 — never ask generic "who is your audience?" questions
173
+ - Keep it to 2–4 questions maximum — respect the user's time
174
+ - Offer concrete options, not open-ended prompts
175
+ - If findings are straightforward (e.g., only 1–2 clear issues), skip questions and go directly to Phase 4
176
+
177
+ ## Phase 4: Recommended Actions
178
+
179
+ **After receiving the user's answers**, present a prioritized action summary reflecting the user's priorities and scope from Phase 3.
180
+
181
+ ### Action Summary
182
+
183
+ List recommended commands in priority order, based on the user's answers:
184
+
185
+ 1. **`/command-name`** — Brief description of what to fix (specific context from critique findings)
186
+ 2. **`/command-name`** — Brief description (specific context)
187
+ ...
188
+
189
+ **Rules for recommendations**:
190
+ - Only recommend commands from: /audit, /critique, /normalize, /polish, /distill, /clarify, /optimize, /harden, /animate, /colorize, /bolder, /quieter, /delight, /extract, /adapt, /onboard, /typeset, /arrange, /overdrive, /teach-impeccable
191
+ - Order by the user's stated priorities first, then by impact
192
+ - Each item's description should carry enough context that the command knows what to focus on
193
+ - Map each Priority Issue to the appropriate command
194
+ - Skip commands that would address zero issues
195
+ - If the user chose a limited scope, only include items within that scope
196
+ - If the user marked areas as off-limits, exclude commands that would touch those areas
197
+ - End with `/polish` as the final step if any fixes were recommended
198
+
199
+ After presenting the summary, tell the user:
200
+
201
+ > You can ask me to run these one at a time, all at once, or in any order you prefer.
202
+ >
203
+ > Re-run `/critique` after fixes to see your score improve.
@@ -0,0 +1,106 @@
1
+ # Cognitive Load Assessment
2
+
3
+ Cognitive load is the total mental effort required to use an interface. Overloaded users make mistakes, get frustrated, and leave. This reference helps identify and fix cognitive overload.
4
+
5
+ ---
6
+
7
+ ## Three Types of Cognitive Load
8
+
9
+ ### Intrinsic Load — The Task Itself
10
+ Complexity inherent to what the user is trying to do. You can't eliminate this, but you can structure it.
11
+
12
+ **Manage it by**:
13
+ - Breaking complex tasks into discrete steps
14
+ - Providing scaffolding (templates, defaults, examples)
15
+ - Progressive disclosure — show what's needed now, hide the rest
16
+ - Grouping related decisions together
17
+
18
+ ### Extraneous Load — Bad Design
19
+ Mental effort caused by poor design choices. **Eliminate this ruthlessly** — it's pure waste.
20
+
21
+ **Common sources**:
22
+ - Confusing navigation that requires mental mapping
23
+ - Unclear labels that force users to guess meaning
24
+ - Visual clutter competing for attention
25
+ - Inconsistent patterns that prevent learning
26
+ - Unnecessary steps between user intent and result
27
+
28
+ ### Germane Load — Learning Effort
29
+ Mental effort spent building understanding. This is *good* cognitive load — it leads to mastery.
30
+
31
+ **Support it by**:
32
+ - Progressive disclosure that reveals complexity gradually
33
+ - Consistent patterns that reward learning
34
+ - Feedback that confirms correct understanding
35
+ - Onboarding that teaches through action, not walls of text
36
+
37
+ ---
38
+
39
+ ## Cognitive Load Checklist
40
+
41
+ Evaluate the interface against these 8 items:
42
+
43
+ - [ ] **Single focus**: Can the user complete their primary task without distraction from competing elements?
44
+ - [ ] **Chunking**: Is information presented in digestible groups (≤4 items per group)?
45
+ - [ ] **Grouping**: Are related items visually grouped together (proximity, borders, shared background)?
46
+ - [ ] **Visual hierarchy**: Is it immediately clear what's most important on the screen?
47
+ - [ ] **One thing at a time**: Can the user focus on a single decision before moving to the next?
48
+ - [ ] **Minimal choices**: Are decisions simplified (≤4 visible options at any decision point)?
49
+ - [ ] **Working memory**: Does the user need to remember information from a previous screen to act on the current one?
50
+ - [ ] **Progressive disclosure**: Is complexity revealed only when the user needs it?
51
+
52
+ **Scoring**: Count the failed items. 0–1 failures = low cognitive load (good). 2–3 = moderate (address soon). 4+ = high cognitive load (critical fix needed).
53
+
54
+ ---
55
+
56
+ ## The Working Memory Rule
57
+
58
+ **Humans can hold ≤4 items in working memory at once** (Miller's Law revised by Cowan, 2001).
59
+
60
+ At any decision point, count the number of distinct options, actions, or pieces of information a user must simultaneously consider:
61
+ - **≤4 items**: Within working memory limits — manageable
62
+ - **5–7 items**: Pushing the boundary — consider grouping or progressive disclosure
63
+ - **8+ items**: Overloaded — users will skip, misclick, or abandon
64
+
65
+ **Practical applications**:
66
+ - Navigation menus: ≤5 top-level items (group the rest under clear categories)
67
+ - Form sections: ≤4 fields visible per group before a visual break
68
+ - Action buttons: 1 primary, 1–2 secondary, group the rest in a menu
69
+ - Dashboard widgets: ≤4 key metrics visible without scrolling
70
+ - Pricing tiers: ≤3 options (more causes analysis paralysis)
71
+
72
+ ---
73
+
74
+ ## Common Cognitive Load Violations
75
+
76
+ ### 1. The Wall of Options
77
+ **Problem**: Presenting 10+ choices at once with no hierarchy.
78
+ **Fix**: Group into categories, highlight recommended, use progressive disclosure.
79
+
80
+ ### 2. The Memory Bridge
81
+ **Problem**: User must remember info from step 1 to complete step 3.
82
+ **Fix**: Keep relevant context visible, or repeat it where it's needed.
83
+
84
+ ### 3. The Hidden Navigation
85
+ **Problem**: User must build a mental map of where things are.
86
+ **Fix**: Always show current location (breadcrumbs, active states, progress indicators).
87
+
88
+ ### 4. The Jargon Barrier
89
+ **Problem**: Technical or domain language forces translation effort.
90
+ **Fix**: Use plain language. If domain terms are unavoidable, define them inline.
91
+
92
+ ### 5. The Visual Noise Floor
93
+ **Problem**: Every element has the same visual weight — nothing stands out.
94
+ **Fix**: Establish clear hierarchy: one primary element, 2–3 secondary, everything else muted.
95
+
96
+ ### 6. The Inconsistent Pattern
97
+ **Problem**: Similar actions work differently in different places.
98
+ **Fix**: Standardize interaction patterns. Same type of action = same type of UI.
99
+
100
+ ### 7. The Multi-Task Demand
101
+ **Problem**: Interface requires processing multiple simultaneous inputs (reading + deciding + navigating).
102
+ **Fix**: Sequence the steps. Let the user do one thing at a time.
103
+
104
+ ### 8. The Context Switch
105
+ **Problem**: User must jump between screens/tabs/modals to gather info for a single decision.
106
+ **Fix**: Co-locate the information needed for each decision. Reduce back-and-forth.