ui-ux-master 1.1.0 → 1.2.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.
package/README.md CHANGED
@@ -1,6 +1,12 @@
1
- # UI/UX Master
1
+ # UI/UX Master 🎨✨
2
2
 
3
- The one-stop UI/UX skill for AI coding agents.
3
+ [![npm version](https://badge.fury.io/js/ui-ux-master.svg)](https://badge.fury.io/js/ui-ux-master)
4
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
+ [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](http://makeapullrequest.com)
6
+
7
+ **The ultimate UI/UX skill for AI coding agents.** Turn your AI into a Senior Product Designer, UX Researcher, and Frontend Lead in seconds.
8
+
9
+ Author: Rupak Biswas.
4
10
 
5
11
  Use it with a normal prompt plus one trigger:
6
12
 
@@ -16,6 +22,15 @@ Most AI UI prompts produce pretty screens but miss the hard parts: research assu
16
22
 
17
23
  UI/UX Master is built to make agents behave like a senior product designer, UX researcher, accessibility reviewer, design-system lead, and frontend handoff partner in one workflow.
18
24
 
25
+ ## 🚀 Supercharge Your AI Workflow
26
+
27
+ AI agents are great at writing code, but they often struggle with **Information Architecture**, **Accessibility (WCAG)**, and **Design Systems**. `ui-ux-master` bridges this gap.
28
+
29
+ By installing this tool, you instantly give **Claude**, **Cursor**, **Windsurf**, **Codex**, **Gemini**, **Antigravity**, and universal/custom-instruction agents the ability to:
30
+ - 🧠 **Think like a designer:** Understand user flows and journey maps before coding.
31
+ - ♿ **Audit for accessibility:** Automatically check for WCAG 2.2 AA compliance and ARIA patterns.
32
+ - 🧩 **Enforce design systems:** Keep your brand colors, typography, and spacing consistent.
33
+
19
34
  ## What Makes It Different
20
35
 
21
36
  | Common open-source prompt/skill | UI/UX Master |
@@ -28,6 +43,17 @@ UI/UX Master is built to make agents behave like a senior product designer, UX r
28
43
  | Weak accessibility coverage | WCAG 2.2 AA plus advanced ARIA/widget patterns and test matrix |
29
44
  | No deployment validation | Release validator, npm package metadata, tests, and deployment zip builder |
30
45
  | No product-risk coverage | Ethics, privacy, dark-pattern, high-risk domain, AI-interface, and inclusive-design checks |
46
+ | Hidden from AI tooling | Ships `llms.txt`, machine-readable manifest, system prompt add-ons, and a local MCP server for automatic discovery |
47
+
48
+ ## AI Discoverability
49
+
50
+ UI/UX Master is now designed for both humans and AI systems to discover:
51
+
52
+ - `llms.txt` gives agents a concise map of the package.
53
+ - `ai-discovery/ui-ux-master.manifest.json` provides a machine-readable manifest.
54
+ - `system-prompts/` contains full, compact, and MCP-focused system prompt add-ons.
55
+ - `ui-ux-master-mcp` exposes the package through a local MCP server with tools, resources, and prompts.
56
+ - Project installs copy these discovery assets into `.ui-ux-master/` so no-save `npx` installs remain usable after the npm cache disappears.
31
57
 
32
58
  ## Capabilities
33
59
 
@@ -92,9 +118,43 @@ npx ui-ux-master install --project --dry-run
92
118
  | Gemini CLI | `GEMINI.md` marked section | type `/ui-ux-master` |
93
119
  | Cursor | `.cursor/rules/ui-ux-master.mdc` | type `/ui-ux-master` |
94
120
  | Other agents | `agent-templates/universal/ui-ux-master-trigger.md` | copy trigger into instruction file |
121
+ | MCP clients | `ui-ux-master-mcp` | discover tools/resources/prompts automatically |
95
122
 
96
123
  See `docs/slash-command-compatibility.md` for details.
97
124
 
125
+ ## System Prompt Add-ons
126
+
127
+ Copy one of these into any AI custom-instructions field when the agent does not support project rules:
128
+
129
+ - `system-prompts/ui-ux-master-system-add-on.md` — full add-on.
130
+ - `system-prompts/ui-ux-master-compact.md` — compact add-on.
131
+ - `system-prompts/ui-ux-master-mcp-add-on.md` — MCP-focused add-on.
132
+
133
+ ## MCP Server
134
+
135
+ Run the local MCP server:
136
+
137
+ ```bash
138
+ ui-ux-master-mcp
139
+ # or without global install
140
+ npx -y --package ui-ux-master ui-ux-master-mcp
141
+ ```
142
+
143
+ MCP client config:
144
+
145
+ ```json
146
+ {
147
+ "mcpServers": {
148
+ "ui-ux-master": {
149
+ "command": "npx",
150
+ "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]
151
+ }
152
+ }
153
+ }
154
+ ```
155
+
156
+ See `docs/mcp-server.md` for tools, resources, prompts, and Hermes config.
157
+
98
158
  ## Usage Examples
99
159
 
100
160
  ```text
@@ -126,6 +186,8 @@ ui-ux-master install --project --agents claude,codex,windsurf,antigravity,gemini
126
186
  ui-ux-master install --project --dry-run
127
187
  ui-ux-master doctor
128
188
  ui-ux-master where
189
+ ui-ux-master mcp
190
+ ui-ux-master-mcp
129
191
  ui-ux-master uninstall --project
130
192
  ```
131
193
 
@@ -135,8 +197,12 @@ ui-ux-master uninstall --project
135
197
  - `references/` — advanced playbooks and standards-aligned checklists.
136
198
  - `templates/` — briefs, audits, component specs, design-system specs, and project UI/UX memory template.
137
199
  - `agent-templates/` — Claude, Codex, Windsurf, Antigravity, Gemini, Cursor, and universal `/ui-ux-master` activation rules.
138
- - `docs/` — cross-agent slash-command compatibility docs.
200
+ - `docs/` — cross-agent slash-command compatibility docs and MCP server docs.
201
+ - `system-prompts/` — full, compact, and MCP-focused system prompt add-ons.
202
+ - `ai-discovery/` — machine-readable discovery manifest.
203
+ - `llms.txt` — AI-readable package map.
139
204
  - `bin/ui-ux-master.mjs` — npm CLI installer.
205
+ - `bin/ui-ux-master-mcp.mjs` — local MCP server.
140
206
  - `scripts/validate_skill.py` — dependency-free release validator.
141
207
  - `scripts/build_deployment_zip.py` — clean deployment zip builder.
142
208
  - `tests/` — npm installer and package smoke tests.
@@ -175,6 +241,7 @@ UI/UX Master is designed to outperform narrow UI prompt packs and simple design
175
241
  5. Project memory: durable brand/design consistency via `.ui-ux-memory.md`.
176
242
  6. Release engineering: npm packaging, CLI installer, validation, tests, and deployment zip.
177
243
  7. Advanced risk coverage: ethics, privacy, dark patterns, localization, platform conventions, high-risk domains, and AI UX transparency.
244
+ 8. AI discoverability: `llms.txt`, manifest, system prompt add-ons, and local MCP server.
178
245
 
179
246
  ## Deployment Readiness Checklist
180
247
 
@@ -183,6 +250,8 @@ UI/UX Master is designed to outperform narrow UI prompt packs and simple design
183
250
  - [ ] `npm pack --dry-run` contains only intended files.
184
251
  - [ ] `ui-ux-master install --project --dry-run` works.
185
252
  - [ ] Agent templates contain `/ui-ux-master` and do not include local absolute paths.
253
+ - [ ] System prompt add-ons and MCP docs are included and mention `/ui-ux-master`.
254
+ - [ ] MCP smoke test returns `tools/list` and `resources/list` successfully.
186
255
  - [ ] No `node_modules`, `__pycache__`, `.pyc`, graphify cache, coverage, logs, secrets, or local credentials are included.
187
256
 
188
257
  ## Known Limitations
package/SKILL.md CHANGED
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  name: ui-ux-master
3
3
  description: "Use when an agent must design, audit, improve, prototype, specify, or hand off any UI/UX work end-to-end. Provides one-stop UX strategy, research, IA, flows, wireframes, visual design, design systems, accessibility, usability testing, conversion, and engineering handoff workflows."
4
- version: 1.1.0
5
- author: Hermes Agent
4
+ version: 1.2.0
5
+ author: Rupak Biswas
6
6
  license: MIT
7
7
  platforms: [linux, macos, windows]
8
8
  metadata:
@@ -19,15 +19,26 @@ This is a one-stop UI/UX skill for agents. Use it whenever the user asks for any
19
19
 
20
20
  The job is not only to make screens look good. The job is to solve the user's goal with a usable, accessible, coherent, implementable interface. Always connect design choices to user needs, product goals, content, system constraints, and measurable outcomes.
21
21
 
22
- ## Cross-Agent Activation
22
+ ## Cross-Agent Activation
23
+
24
+ This skill is opt-in. In Codex, Claude, Windsurf, Antigravity, Gemini, Cursor, and other agents, activate it only when the user includes `/ui-ux-master` in the prompt or invokes the installed native slash command. If the user does not mention `/ui-ux-master`, do not apply this skill automatically.
25
+
26
+ When activated, the user can write naturally, for example: `/ui-ux-master audit this checkout flow` or `/ui-ux-master design a premium SaaS landing page`. Treat the rest of the prompt as the task and follow this SKILL.md plus the referenced files.
23
27
 
24
- This skill is opt-in. In Codex, Claude, Windsurf, Antigravity, Gemini, Cursor, and other agents, activate it only when the user includes `/ui-ux-master` in the prompt or invokes the installed native slash command. If the user does not mention `/ui-ux-master`, do not apply this skill automatically.
28
+ ## AI Discovery and MCP
25
29
 
26
- When activated, the user can write naturally, for example: `/ui-ux-master audit this checkout flow` or `/ui-ux-master design a premium SaaS landing page`. Treat the rest of the prompt as the task and follow this SKILL.md plus the referenced files.
30
+ This package exposes the workflow through human-readable instructions and machine-readable discovery assets:
27
31
 
28
- ## Core Operating Rule
32
+ - `llms.txt` gives AI agents a short map of the package.
33
+ - `ai-discovery/ui-ux-master.manifest.json` describes activation, entrypoints, tools, resources, prompts, and supported agents.
34
+ - `system-prompts/` contains full, compact, and MCP-focused system prompt add-ons.
35
+ - `bin/ui-ux-master-mcp.mjs` runs a local read-only MCP server that exposes UI/UX Master tools, resources, and prompts.
29
36
 
30
- Do not jump directly to visuals. Work in this order unless the user explicitly asks for a narrow task:
37
+ Use MCP and system prompt add-ons only as discovery/activation layers. The workflow remains opt-in and should still require `/ui-ux-master` unless the user explicitly asks to use UI/UX Master.
38
+
39
+ ## Core Operating Rule
40
+
41
+ Do not jump directly to visuals. Work in this order unless the user explicitly asks for a narrow task:
31
42
 
32
43
  1. Check for existing UI/UX memory and branding first: `.ui-ux-memory.md`, design tokens, CSS variables, theme files, existing components, fonts, color scheme, and representative screens.
33
44
  2. If memory exists, follow it as the design baseline. If no memory exists, create one for the application using `templates/ui-ux-memory.md` after inspecting existing branding or asking minimum high-value questions for a fresh project.
@@ -693,22 +704,29 @@ Use the supporting files in this skill folder when useful:
693
704
  - `references/ui-ux-frontend-implementation-rules.md` — mandatory frontend implementation rules so agents do not miss stack inspection, states, accessibility, responsiveness, tokens, QA, or handoff.
694
705
  - `references/wcag-aa-quick-reference.md` — practical WCAG 2.2 AA reference for agents.
695
706
  - `references/design-system-playbook.md` — how to create or extend a design system.
696
- - `references/top-100-brand-website-analysis.md` — top global brand website patterns and reusable frontend methods.
697
- - `references/ux-research-methods.md` — research planning, method selection, evidence confidence, and ethical research rules.
698
- - `references/usability-heuristics.md` — heuristic review, cognitive rules, and severity scoring.
699
- - `references/platform-guidelines.md` — web, iOS, Android/Material, Windows, desktop, kiosk, email, TV, and cross-platform rules.
700
- - `references/content-design-and-i18n.md` — UX writing, microcopy, localization, RTL, and content handoff.
701
- - `references/ux-measurement-quality-gates.md` — task success metrics, UX measurement, accessibility gates, and definition of done.
702
- - `references/ethical-inclusive-design.md` — dark-pattern avoidance, privacy UX, inclusive design, high-risk and AI interface rules.
703
- - `references/service-design-journey-mapping.md` — journey maps, service blueprints, support handoff, and omnichannel checks.
704
- - `references/data-visualization-dashboard-ux.md` — dashboard, table, chart, data-grid, and alerting UX rules.
705
- - `references/accessibility-advanced-patterns.md` — complex widget accessibility and screen-reader test matrix.
706
- - `references/ui-ux-curriculum-and-standards.md` — basic-to-advanced UI/UX curriculum and standards map.
707
- - `references/competitive-landscape.md` — competitor gaps and strategy for staying ahead.
707
+ - `references/top-100-brand-website-analysis.md` — top global brand website patterns and reusable frontend methods.
708
+ - `references/ux-research-methods.md` — research planning, method selection, evidence confidence, and ethical research rules.
709
+ - `references/usability-heuristics.md` — heuristic review, cognitive rules, and severity scoring.
710
+ - `references/platform-guidelines.md` — web, iOS, Android/Material, Windows, desktop, kiosk, email, TV, and cross-platform rules.
711
+ - `references/content-design-and-i18n.md` — UX writing, microcopy, localization, RTL, and content handoff.
712
+ - `references/ux-measurement-quality-gates.md` — task success metrics, UX measurement, accessibility gates, and definition of done.
713
+ - `references/ethical-inclusive-design.md` — dark-pattern avoidance, privacy UX, inclusive design, high-risk and AI interface rules.
714
+ - `references/service-design-journey-mapping.md` — journey maps, service blueprints, support handoff, and omnichannel checks.
715
+ - `references/data-visualization-dashboard-ux.md` — dashboard, table, chart, data-grid, and alerting UX rules.
716
+ - `references/accessibility-advanced-patterns.md` — complex widget accessibility and screen-reader test matrix.
717
+ - `references/ui-ux-curriculum-and-standards.md` — basic-to-advanced UI/UX curriculum and standards map.
718
+ - `references/competitive-landscape.md` — competitor gaps and strategy for staying ahead.
708
719
  - `docs/slash-command-compatibility.md` — cross-agent `/ui-ux-master` trigger compatibility.
720
+ - `docs/mcp-server.md` — MCP tools, resources, prompts, client configs, and smoke testing.
721
+ - `llms.txt` — AI-readable package map for discovery by agents and indexing tools.
722
+ - `ai-discovery/ui-ux-master.manifest.json` — machine-readable manifest for activation, entrypoints, MCP, and capabilities.
723
+ - `system-prompts/ui-ux-master-system-add-on.md` — full system prompt add-on.
724
+ - `system-prompts/ui-ux-master-compact.md` — compact system prompt add-on.
725
+ - `system-prompts/ui-ux-master-mcp-add-on.md` — MCP-focused system prompt add-on.
709
726
  - `agent-templates/` — Claude, Codex, Windsurf, Antigravity, Gemini, Cursor, and universal installer templates.
710
727
  - `bin/ui-ux-master.mjs` — npm CLI installer.
711
- - `templates/ui-ux-brief.md` — intake and requirements template.
728
+ - `bin/ui-ux-master-mcp.mjs` — local read-only MCP server.
729
+ - `templates/ui-ux-brief.md` — intake and requirements template.
712
730
  - `templates/ui-ux-memory.md` — project UI/UX memory file template to copy into an application root as `.ui-ux-memory.md`.
713
731
  - `templates/ui-ux-audit-report.md` — audit output template.
714
732
  - `templates/component-spec.md` — component handoff template.
@@ -0,0 +1,84 @@
1
+ {
2
+ "schema_version": "1.0",
3
+ "name": "ui-ux-master",
4
+ "title": "UI/UX Master",
5
+ "version": "1.2.0",
6
+ "author": "Rupak Biswas",
7
+ "description": "One-stop UI/UX master skill for AI agents with opt-in /ui-ux-master activation, system prompt add-ons, project-local skill assets, and local MCP discovery.",
8
+ "activation": {
9
+ "trigger": "/ui-ux-master",
10
+ "mode": "opt-in-only",
11
+ "do_not_auto_apply_without_trigger": true
12
+ },
13
+ "entrypoints": {
14
+ "skill": "SKILL.md",
15
+ "readme": "README.md",
16
+ "llms": "llms.txt",
17
+ "mcp_server_bin": "ui-ux-master-mcp",
18
+ "cli_bin": "ui-ux-master"
19
+ },
20
+ "system_prompt_addons": [
21
+ "system-prompts/ui-ux-master-system-add-on.md",
22
+ "system-prompts/ui-ux-master-compact.md",
23
+ "system-prompts/ui-ux-master-mcp-add-on.md"
24
+ ],
25
+ "mcp": {
26
+ "server_name": "ui-ux-master",
27
+ "transport": "stdio",
28
+ "command": "npx",
29
+ "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"],
30
+ "tools": [
31
+ "get_skill",
32
+ "list_assets",
33
+ "get_asset",
34
+ "generate_system_prompt",
35
+ "create_memory_template",
36
+ "install_instructions"
37
+ ],
38
+ "resources": [
39
+ "ui-ux-master://skill",
40
+ "ui-ux-master://readme",
41
+ "ui-ux-master://llms",
42
+ "ui-ux-master://manifest",
43
+ "ui-ux-master://system-prompt",
44
+ "ui-ux-master://compact-prompt",
45
+ "ui-ux-master://mcp-prompt",
46
+ "ui-ux-master://mcp-docs",
47
+ "ui-ux-master://checklist",
48
+ "ui-ux-master://memory-template"
49
+ ],
50
+ "prompts": [
51
+ "ui-ux-master",
52
+ "ui-ux-audit",
53
+ "ui-ux-redesign",
54
+ "ui-ux-design-system",
55
+ "ui-ux-accessibility-review"
56
+ ]
57
+ },
58
+ "supported_agents": [
59
+ "Claude Code",
60
+ "Codex",
61
+ "Windsurf",
62
+ "Antigravity",
63
+ "Gemini CLI",
64
+ "Cursor",
65
+ "MCP clients",
66
+ "Universal agents"
67
+ ],
68
+ "capabilities": [
69
+ "UX strategy",
70
+ "UX research planning",
71
+ "information architecture",
72
+ "user flows",
73
+ "wireframes",
74
+ "visual design direction",
75
+ "design systems",
76
+ "accessibility",
77
+ "responsive design",
78
+ "content design",
79
+ "localization",
80
+ "ethical UX",
81
+ "frontend implementation handoff",
82
+ "QA and acceptance criteria"
83
+ ]
84
+ }
@@ -0,0 +1,243 @@
1
+ #!/usr/bin/env node
2
+ import fs from 'node:fs';
3
+ import path from 'node:path';
4
+ import readline from 'node:readline';
5
+ import { fileURLToPath } from 'node:url';
6
+
7
+ const __filename = fileURLToPath(import.meta.url);
8
+ const packageRoot = path.resolve(path.dirname(__filename), '..');
9
+ const protocolVersion = '2024-11-05';
10
+
11
+ const assetMap = {
12
+ skill: 'SKILL.md',
13
+ readme: 'README.md',
14
+ llms: 'llms.txt',
15
+ manifest: 'ai-discovery/ui-ux-master.manifest.json',
16
+ system_prompt: 'system-prompts/ui-ux-master-system-add-on.md',
17
+ compact_prompt: 'system-prompts/ui-ux-master-compact.md',
18
+ mcp_prompt: 'system-prompts/ui-ux-master-mcp-add-on.md',
19
+ mcp_docs: 'docs/mcp-server.md',
20
+ slash_docs: 'docs/slash-command-compatibility.md',
21
+ memory_workflow: 'references/ui-ux-memory-workflow.md',
22
+ frontend_rules: 'references/ui-ux-frontend-implementation-rules.md',
23
+ complete_checklist: 'references/ui-ux-complete-checklist.md',
24
+ wcag: 'references/wcag-aa-quick-reference.md',
25
+ accessibility_patterns: 'references/accessibility-advanced-patterns.md',
26
+ design_system_playbook: 'references/design-system-playbook.md',
27
+ memory_template: 'templates/ui-ux-memory.md',
28
+ };
29
+
30
+ const resourceMap = {
31
+ 'ui-ux-master://skill': 'SKILL.md',
32
+ 'ui-ux-master://readme': 'README.md',
33
+ 'ui-ux-master://llms': 'llms.txt',
34
+ 'ui-ux-master://manifest': 'ai-discovery/ui-ux-master.manifest.json',
35
+ 'ui-ux-master://system-prompt': 'system-prompts/ui-ux-master-system-add-on.md',
36
+ 'ui-ux-master://compact-prompt': 'system-prompts/ui-ux-master-compact.md',
37
+ 'ui-ux-master://mcp-prompt': 'system-prompts/ui-ux-master-mcp-add-on.md',
38
+ 'ui-ux-master://mcp-docs': 'docs/mcp-server.md',
39
+ 'ui-ux-master://checklist': 'references/ui-ux-complete-checklist.md',
40
+ 'ui-ux-master://memory-template': 'templates/ui-ux-memory.md',
41
+ };
42
+
43
+ function readRel(rel) {
44
+ const full = path.resolve(packageRoot, rel);
45
+ if (!full.startsWith(packageRoot)) throw new Error('Path escapes package root');
46
+ return fs.readFileSync(full, 'utf8');
47
+ }
48
+
49
+ function textContent(text) {
50
+ return [{ type: 'text', text }];
51
+ }
52
+
53
+ function jsonText(obj) {
54
+ return textContent(JSON.stringify(obj, null, 2));
55
+ }
56
+
57
+ function tool(name, description, properties = {}, required = []) {
58
+ return {
59
+ name,
60
+ description,
61
+ inputSchema: {
62
+ type: 'object',
63
+ properties,
64
+ required,
65
+ additionalProperties: false,
66
+ },
67
+ };
68
+ }
69
+
70
+ function listTools() {
71
+ return [
72
+ tool('get_skill', 'Return the main UI/UX Master SKILL.md content.', {}, []),
73
+ tool('list_assets', 'List discoverable UI/UX Master assets, references, prompts, and resources.', {}, []),
74
+ tool('get_asset', 'Return a named package asset such as skill, readme, system_prompt, complete_checklist, or memory_template.', {
75
+ name: { type: 'string', description: `Asset name. Allowed: ${Object.keys(assetMap).join(', ')}` },
76
+ }, ['name']),
77
+ tool('generate_system_prompt', 'Generate a system prompt add-on for an AI agent.', {
78
+ mode: { type: 'string', enum: ['full', 'compact', 'mcp'], default: 'full' },
79
+ agent: { type: 'string', description: 'Optional target agent name such as Claude, Codex, Windsurf, Cursor, Gemini, Antigravity, or universal.' },
80
+ }, []),
81
+ tool('create_memory_template', 'Return a project .ui-ux-memory.md template with optional project name inserted.', {
82
+ projectName: { type: 'string', description: 'Optional project/product name.' },
83
+ }, []),
84
+ tool('install_instructions', 'Return install instructions for npm, project agent rules, or MCP clients.', {
85
+ target: { type: 'string', enum: ['npm', 'project', 'global', 'mcp', 'claude-desktop', 'hermes', 'cursor', 'codex', 'windsurf', 'gemini', 'antigravity', 'universal'], default: 'project' },
86
+ }, []),
87
+ ];
88
+ }
89
+
90
+ function callTool(name, args = {}) {
91
+ switch (name) {
92
+ case 'get_skill':
93
+ return { content: textContent(readRel('SKILL.md')) };
94
+ case 'list_assets':
95
+ return { content: jsonText({ assets: assetMap, resources: Object.keys(resourceMap), prompts: listPrompts().map(p => p.name), tools: listTools().map(t => t.name) }) };
96
+ case 'get_asset': {
97
+ const rel = assetMap[args.name];
98
+ if (!rel) throw new Error(`Unknown asset '${args.name}'. Use list_assets first.`);
99
+ return { content: textContent(readRel(rel)) };
100
+ }
101
+ case 'generate_system_prompt': {
102
+ const mode = args.mode || 'full';
103
+ const rel = mode === 'compact' ? assetMap.compact_prompt : mode === 'mcp' ? assetMap.mcp_prompt : assetMap.system_prompt;
104
+ const agentLine = args.agent ? `\n\nTarget agent: ${args.agent}. Keep the /ui-ux-master opt-in rule and use that agent's instruction format when applying this add-on.\n` : '';
105
+ return { content: textContent(readRel(rel) + agentLine) };
106
+ }
107
+ case 'create_memory_template': {
108
+ let text = readRel('templates/ui-ux-memory.md');
109
+ if (args.projectName) text = text.replace('# UI/UX Memory', `# UI/UX Memory — ${args.projectName}`);
110
+ return { content: textContent(text) };
111
+ }
112
+ case 'install_instructions':
113
+ return { content: textContent(installInstructions(args.target || 'project')) };
114
+ default:
115
+ throw new Error(`Unknown tool '${name}'`);
116
+ }
117
+ }
118
+
119
+ function installInstructions(target) {
120
+ const common = 'After install, activate with: /ui-ux-master <your normal UI/UX request>';
121
+ const map = {
122
+ npm: 'npm install -g ui-ux-master\nui-ux-master install --global',
123
+ project: 'npm install --save-dev ui-ux-master\nnpx ui-ux-master install --project',
124
+ global: 'npm install -g ui-ux-master\nui-ux-master install --global',
125
+ mcp: 'npx -y --package ui-ux-master ui-ux-master-mcp\n# or after install: ui-ux-master-mcp',
126
+ hermes: 'mcp_servers:\n ui_ux_master:\n command: "npx"\n args: ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]',
127
+ 'claude-desktop': '{\n "mcpServers": {\n "ui-ux-master": {\n "command": "npx",\n "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]\n }\n }\n}',
128
+ cursor: 'npx ui-ux-master install --project --agents cursor',
129
+ codex: 'npx ui-ux-master install --project --agents codex',
130
+ windsurf: 'npx ui-ux-master install --project --agents windsurf',
131
+ gemini: 'npx ui-ux-master install --project --agents gemini',
132
+ antigravity: 'npx ui-ux-master install --project --agents antigravity',
133
+ universal: 'Copy system-prompts/ui-ux-master-system-add-on.md into the agent custom instructions, or run npx ui-ux-master install --project --agents universal',
134
+ };
135
+ return `${map[target] || map.project}\n\n${common}`;
136
+ }
137
+
138
+ function listResources() {
139
+ return Object.entries(resourceMap).map(([uri, rel]) => ({
140
+ uri,
141
+ name: path.basename(rel),
142
+ description: `UI/UX Master asset: ${rel}`,
143
+ mimeType: rel.endsWith('.json') ? 'application/json' : 'text/markdown',
144
+ }));
145
+ }
146
+
147
+ function readResource(uri) {
148
+ const rel = resourceMap[uri];
149
+ if (!rel) throw new Error(`Unknown resource '${uri}'`);
150
+ return { contents: [{ uri, mimeType: rel.endsWith('.json') ? 'application/json' : 'text/markdown', text: readRel(rel) }] };
151
+ }
152
+
153
+ function listPrompts() {
154
+ return [
155
+ { name: 'ui-ux-master', description: 'Activate the full UI/UX Master workflow for a normal user task.', arguments: [{ name: 'task', description: 'The user UI/UX request.', required: true }] },
156
+ { name: 'ui-ux-audit', description: 'Audit a screen, flow, app, or URL for UX, UI, accessibility, and handoff issues.', arguments: [{ name: 'target', description: 'What to audit.', required: true }] },
157
+ { name: 'ui-ux-redesign', description: 'Redesign a product area while preserving or intentionally evolving brand conventions.', arguments: [{ name: 'target', description: 'What to redesign.', required: true }] },
158
+ { name: 'ui-ux-design-system', description: 'Create or extend a design system with tokens, components, governance, and QA.', arguments: [{ name: 'scope', description: 'Product/component scope.', required: true }] },
159
+ { name: 'ui-ux-accessibility-review', description: 'Run a WCAG-focused accessibility and interaction review.', arguments: [{ name: 'target', description: 'Screen, component, or flow.', required: true }] },
160
+ ];
161
+ }
162
+
163
+ function getPrompt(name, args = {}) {
164
+ const task = args.task || args.target || args.scope || 'the requested UI/UX work';
165
+ const map = {
166
+ 'ui-ux-master': `/ui-ux-master ${task}\n\nUse the full UI/UX Master workflow. Check UI/UX memory first. Produce implementation-ready output.`,
167
+ 'ui-ux-audit': `/ui-ux-master audit ${task} for UX clarity, accessibility, responsive behavior, content, trust, conversion, states, and implementation quality. Return prioritized findings and fixes.`,
168
+ 'ui-ux-redesign': `/ui-ux-master redesign ${task}. Preserve existing brand/tokens/components unless a redesign is requested. Include IA, flow, layout, states, accessibility, responsive rules, copy, and developer handoff.`,
169
+ 'ui-ux-design-system': `/ui-ux-master create or extend a design system for ${task}. Include tokens, components, variants, states, accessibility, governance, examples, QA, and acceptance criteria.`,
170
+ 'ui-ux-accessibility-review': `/ui-ux-master review ${task} for WCAG 2.2 AA, keyboard, focus, semantics, screen reader behavior, contrast, motion, forms, error recovery, and test coverage.`,
171
+ };
172
+ if (!map[name]) throw new Error(`Unknown prompt '${name}'`);
173
+ return { messages: [{ role: 'user', content: { type: 'text', text: map[name] } }] };
174
+ }
175
+
176
+ function ok(id, result) {
177
+ process.stdout.write(JSON.stringify({ jsonrpc: '2.0', id, result }) + '\n');
178
+ }
179
+
180
+ function err(id, error, code = -32603) {
181
+ process.stdout.write(JSON.stringify({ jsonrpc: '2.0', id, error: { code, message: error?.message || String(error) } }) + '\n');
182
+ }
183
+
184
+ function handle(message) {
185
+ const { id, method, params = {} } = message;
186
+ try {
187
+ if (method === 'initialize') {
188
+ ok(id, {
189
+ protocolVersion,
190
+ capabilities: { tools: {}, resources: {}, prompts: {} },
191
+ serverInfo: { name: 'ui-ux-master', version: readPackageVersion() },
192
+ });
193
+ } else if (method === 'notifications/initialized') {
194
+ // no response for notifications
195
+ } else if (method === 'ping') {
196
+ ok(id, {});
197
+ } else if (method === 'tools/list') {
198
+ ok(id, { tools: listTools() });
199
+ } else if (method === 'tools/call') {
200
+ ok(id, callTool(params.name, params.arguments || {}));
201
+ } else if (method === 'resources/list') {
202
+ ok(id, { resources: listResources() });
203
+ } else if (method === 'resources/read') {
204
+ ok(id, readResource(params.uri));
205
+ } else if (method === 'prompts/list') {
206
+ ok(id, { prompts: listPrompts() });
207
+ } else if (method === 'prompts/get') {
208
+ ok(id, getPrompt(params.name, params.arguments || {}));
209
+ } else {
210
+ err(id, new Error(`Method not found: ${method}`), -32601);
211
+ }
212
+ } catch (e) {
213
+ err(id, e);
214
+ }
215
+ }
216
+
217
+ function readPackageVersion() {
218
+ try {
219
+ return JSON.parse(readRel('package.json')).version || '0.0.0';
220
+ } catch {
221
+ return '0.0.0';
222
+ }
223
+ }
224
+
225
+ function printHelp() {
226
+ console.log(`UI/UX Master MCP Server\n\nRun over stdio for MCP clients:\n ui-ux-master-mcp\n\nExample client config:\n{\n "mcpServers": {\n "ui-ux-master": {\n "command": "npx",\n "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]\n }\n }\n}`);
227
+ }
228
+
229
+ if (process.argv.includes('--help') || process.argv.includes('-h')) {
230
+ printHelp();
231
+ process.exit(0);
232
+ }
233
+
234
+ const rl = readline.createInterface({ input: process.stdin, crlfDelay: Infinity });
235
+ rl.on('line', (line) => {
236
+ const trimmed = line.trim();
237
+ if (!trimmed) return;
238
+ try {
239
+ handle(JSON.parse(trimmed));
240
+ } catch (e) {
241
+ err(null, e);
242
+ }
243
+ });
@@ -81,8 +81,8 @@ function wanted(opts, name) {
81
81
 
82
82
  function copyProjectSkillAssets(root, dryRun) {
83
83
  const dest = path.join(root, '.ui-ux-master');
84
- const files = ['SKILL.md', 'README.md', 'LICENSE', 'package.json'];
85
- const dirs = ['references', 'templates', 'docs'];
84
+ const files = ['SKILL.md', 'README.md', 'LICENSE', 'package.json', 'llms.txt'];
85
+ const dirs = ['references', 'templates', 'docs', 'system-prompts', 'ai-discovery'];
86
86
  for (const file of files) {
87
87
  writeFile(path.join(dest, file), read(file), dryRun);
88
88
  }
@@ -161,7 +161,7 @@ function doctor(opts) {
161
161
  console.log(`target root: ${root}`);
162
162
  console.log(`node: ${process.version}`);
163
163
  console.log(`trigger: /ui-ux-master`);
164
- const required = ['SKILL.md', 'README.md', 'references/ui-ux-complete-checklist.md', 'agent-templates/universal/ui-ux-master-trigger.md'];
164
+ const required = ['SKILL.md', 'README.md', 'llms.txt', 'references/ui-ux-complete-checklist.md', 'agent-templates/universal/ui-ux-master-trigger.md', 'system-prompts/ui-ux-master-system-add-on.md', 'docs/mcp-server.md', 'bin/ui-ux-master-mcp.mjs'];
165
165
  let ok = true;
166
166
  for (const rel of required) {
167
167
  const exists = fs.existsSync(path.join(packageRoot, rel));
@@ -172,7 +172,7 @@ function doctor(opts) {
172
172
  }
173
173
 
174
174
  function help() {
175
- console.log(`UI/UX Master\n\nUsage:\n ui-ux-master install [--project|--global] [--agents claude,codex,windsurf,antigravity,gemini,cursor,universal] [--dir path] [--dry-run]\n ui-ux-master uninstall [--project] [--dir path] [--dry-run]\n ui-ux-master doctor [--dir path]\n ui-ux-master where\n\nAfter install, use: /ui-ux-master <your normal UI/UX prompt>`);
175
+ console.log(`UI/UX Master\n\nUsage:\n ui-ux-master install [--project|--global] [--agents claude,codex,windsurf,antigravity,gemini,cursor,universal] [--dir path] [--dry-run]\n ui-ux-master uninstall [--project] [--dir path] [--dry-run]\n ui-ux-master doctor [--dir path]\n ui-ux-master where\n ui-ux-master mcp\n ui-ux-master-mcp\n\nAfter install, use: /ui-ux-master <your normal UI/UX prompt>\nMCP: npx -y --package ui-ux-master ui-ux-master-mcp`);
176
176
  }
177
177
 
178
178
  const opts = parseArgs(process.argv.slice(2));
@@ -185,6 +185,8 @@ if (opts.postinstall) {
185
185
  uninstallProject(findProjectRoot(opts.dir || process.cwd()), opts);
186
186
  } else if (opts.command === 'doctor') {
187
187
  doctor(opts);
188
+ } else if (opts.command === 'mcp' || opts.command === 'ui-ux-master-mcp') {
189
+ await import('./ui-ux-master-mcp.mjs');
188
190
  } else if (opts.command === 'where') {
189
191
  console.log(packageRoot);
190
192
  } else {
@@ -0,0 +1,106 @@
1
+ # UI/UX Master MCP Server
2
+
3
+ UI/UX Master includes a local MCP server so AI clients can discover the skill automatically as tools, resources, and reusable prompts.
4
+
5
+ ## Why MCP Matters
6
+
7
+ MCP lets compatible AI clients discover local capabilities without relying only on human-readable README files. Project installs also copy the same assets into `.ui-ux-master/`, so MCP clients and text-trigger agents can both find the same source of truth. With this package, agents can:
8
+
9
+ - list UI/UX Master tools;
10
+ - read the main skill and references as MCP resources;
11
+ - retrieve system prompt add-ons;
12
+ - generate project memory templates;
13
+ - get install instructions for supported agents;
14
+ - start common UI/UX workflows through MCP prompts.
15
+
16
+ ## Run the Server
17
+
18
+ After global install:
19
+
20
+ ```bash
21
+ ui-ux-master-mcp
22
+ ```
23
+
24
+ Without global install:
25
+
26
+ ```bash
27
+ npx -y --package ui-ux-master ui-ux-master-mcp
28
+ ```
29
+
30
+ The server communicates over stdio using JSON-RPC/MCP-compatible methods.
31
+
32
+ ## Claude Desktop / MCP Client Config
33
+
34
+ ```json
35
+ {
36
+ "mcpServers": {
37
+ "ui-ux-master": {
38
+ "command": "npx",
39
+ "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]
40
+ }
41
+ }
42
+ }
43
+ ```
44
+
45
+ ## Hermes Native MCP Config
46
+
47
+ ```yaml
48
+ mcp_servers:
49
+ ui_ux_master:
50
+ command: "npx"
51
+ args: ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]
52
+ ```
53
+
54
+ Restart the agent after adding the config so it can discover the tools.
55
+
56
+ ## Tools
57
+
58
+ | Tool | Purpose |
59
+ |---|---|
60
+ | `get_skill` | Return the main `SKILL.md` content. |
61
+ | `list_assets` | List discoverable assets, resources, prompts, and tools. |
62
+ | `get_asset` | Return a named asset such as `system_prompt`, `complete_checklist`, `memory_template`, or `frontend_rules`. |
63
+ | `generate_system_prompt` | Generate full, compact, or MCP-focused system prompt add-ons. |
64
+ | `create_memory_template` | Return a `.ui-ux-memory.md` template, optionally with a project name. |
65
+ | `install_instructions` | Return install instructions for npm, project, global, MCP, Hermes, Claude Desktop, Cursor, Codex, Windsurf, Gemini, Antigravity, or universal agents. |
66
+
67
+ ## Resources
68
+
69
+ | URI | Content |
70
+ |---|---|
71
+ | `ui-ux-master://skill` | Main skill. |
72
+ | `ui-ux-master://readme` | README. |
73
+ | `ui-ux-master://llms` | AI discovery text. |
74
+ | `ui-ux-master://manifest` | Machine-readable AI manifest. |
75
+ | `ui-ux-master://system-prompt` | Full system prompt add-on. |
76
+ | `ui-ux-master://compact-prompt` | Compact system prompt add-on. |
77
+ | `ui-ux-master://mcp-prompt` | MCP-focused prompt add-on. |
78
+ | `ui-ux-master://mcp-docs` | This document. |
79
+ | `ui-ux-master://checklist` | Complete UI/UX checklist. |
80
+ | `ui-ux-master://memory-template` | UI/UX memory template. |
81
+
82
+ ## Prompts
83
+
84
+ | Prompt | Purpose |
85
+ |---|---|
86
+ | `ui-ux-master` | Activate the full workflow for a normal UI/UX task. |
87
+ | `ui-ux-audit` | Audit a screen, product, flow, URL, or component. |
88
+ | `ui-ux-redesign` | Redesign a product area with handoff-ready output. |
89
+ | `ui-ux-design-system` | Create or extend tokens, components, governance, and QA. |
90
+ | `ui-ux-accessibility-review` | Perform a WCAG-focused accessibility review. |
91
+
92
+ ## Manual Smoke Test
93
+
94
+ ```bash
95
+ printf '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{}}\n{"jsonrpc":"2.0","id":2,"method":"tools/list","params":{}}\n' | node bin/ui-ux-master-mcp.mjs
96
+ ```
97
+
98
+ Expected output: JSON-RPC responses containing server info and a tools array.
99
+
100
+ ## Security
101
+
102
+ The MCP server is read-only. It exposes package content and generated prompt text. It does not write files, execute shell commands, read arbitrary paths, or access credentials.
103
+
104
+ ## Activation Reminder
105
+
106
+ Even through MCP, UI/UX Master remains opt-in. Use the workflow only when the user includes `/ui-ux-master` or explicitly asks to use UI/UX Master.
package/llms.txt ADDED
@@ -0,0 +1,24 @@
1
+ # llms.txt
2
+
3
+ # UI/UX Master
4
+
5
+ > One-stop UI/UX master skill for AI coding agents. Activate with `/ui-ux-master` only.
6
+
7
+ Important files for AI discovery:
8
+
9
+ - `SKILL.md`: primary orchestration skill.
10
+ - `README.md`: installation, usage, positioning, validation, and package details.
11
+ - `system-prompts/ui-ux-master-system-add-on.md`: full system prompt add-on.
12
+ - `system-prompts/ui-ux-master-compact.md`: compact add-on for short custom-instruction fields.
13
+ - `system-prompts/ui-ux-master-mcp-add-on.md`: MCP usage instructions.
14
+ - `docs/mcp-server.md`: MCP server tools, resources, prompts, and client config.
15
+ - `docs/slash-command-compatibility.md`: cross-agent `/ui-ux-master` behavior.
16
+ - `ai-discovery/ui-ux-master.manifest.json`: machine-readable package manifest.
17
+
18
+ Activation rule:
19
+
20
+ Use UI/UX Master only when the user includes `/ui-ux-master`. If the user does not include `/ui-ux-master`, do not apply this workflow automatically.
21
+
22
+ MCP:
23
+
24
+ Run `ui-ux-master-mcp` or `npx -y --package ui-ux-master ui-ux-master-mcp` to expose the package as local MCP tools/resources/prompts.
package/package.json CHANGED
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "name": "ui-ux-master",
3
- "version": "1.1.0",
4
- "description": "One-stop UI/UX master skill for AI agents with opt-in /ui-ux-master activation across Claude, Codex, Windsurf, Antigravity, Gemini, Cursor, and universal agents.",
3
+ "version": "1.2.0",
4
+ "description": "One-stop UI/UX master skill for AI agents with opt-in /ui-ux-master activation, system prompt add-ons, AI discovery assets, and local MCP server support.",
5
5
  "type": "module",
6
6
  "bin": {
7
- "ui-ux-master": "./bin/ui-ux-master.mjs"
7
+ "ui-ux-master": "./bin/ui-ux-master.mjs",
8
+ "ui-ux-master-mcp": "./bin/ui-ux-master-mcp.mjs"
8
9
  },
9
10
  "files": [
10
11
  "SKILL.md",
@@ -15,6 +16,9 @@
15
16
  "templates/",
16
17
  "agent-templates/",
17
18
  "docs/",
19
+ "system-prompts/",
20
+ "ai-discovery/",
21
+ "llms.txt",
18
22
  "bin/",
19
23
  "scripts/",
20
24
  "tests/"
@@ -41,10 +45,15 @@
41
45
  "cursor",
42
46
  "slash-command",
43
47
  "agent-skill",
44
- "frontend"
48
+ "frontend",
49
+ "mcp",
50
+ "model-context-protocol",
51
+ "system-prompt",
52
+ "ai-discovery",
53
+ "llms-txt"
45
54
  ],
46
55
  "license": "MIT",
47
- "author": "UI/UX Master contributors",
56
+ "author": "Rupak Biswas",
48
57
  "engines": {
49
58
  "node": ">=18"
50
59
  },
@@ -21,7 +21,14 @@ REQUIRED = [
21
21
  "LICENSE",
22
22
  "package.json",
23
23
  "bin/ui-ux-master.mjs",
24
+ "bin/ui-ux-master-mcp.mjs",
24
25
  "docs/slash-command-compatibility.md",
26
+ "docs/mcp-server.md",
27
+ "llms.txt",
28
+ "ai-discovery/ui-ux-master.manifest.json",
29
+ "system-prompts/ui-ux-master-system-add-on.md",
30
+ "system-prompts/ui-ux-master-compact.md",
31
+ "system-prompts/ui-ux-master-mcp-add-on.md",
25
32
  "agent-templates/claude/commands/ui-ux-master.md",
26
33
  "agent-templates/universal/ui-ux-master-trigger.md",
27
34
  "agent-templates/codex/AGENTS.append.md",
@@ -77,11 +84,17 @@ REQUIRED_PHRASES = [
77
84
  "privacy",
78
85
  "/ui-ux-master",
79
86
  "Cross-Agent Activation",
87
+ "AI Discovery and MCP",
88
+ "system prompt",
89
+ "MCP",
80
90
  ]
81
91
 
82
92
  REQUIRED_HEADINGS = {
83
93
  "README.md": ["## Install with npm", "## Supported Agents", "## Competitive Positioning", "## Validation and Testing", "## Deployment Readiness Checklist"],
84
94
  "docs/slash-command-compatibility.md": ["## What `/ui-ux-master` Does", "## Native Slash Commands vs Text Triggers", "## Supported Agents"],
95
+ "docs/mcp-server.md": ["## Why MCP Matters", "## Tools", "## Resources", "## Prompts", "## Security"],
96
+ "system-prompts/ui-ux-master-system-add-on.md": ["## Activation Rule", "## Source of Truth", "## Required Behavior"],
97
+ "system-prompts/ui-ux-master-mcp-add-on.md": ["## MCP Discovery", "## Behavior", "## Hermes Example"],
85
98
  "references/ux-research-methods.md": ["## Research Decision Tree", "## Research Plan Template", "## Evidence Confidence Levels"],
86
99
  "references/usability-heuristics.md": ["## Nielsen's 10 Usability Heuristics", "## Severity Rating"],
87
100
  "references/platform-guidelines.md": ["## Web App", "## iOS / Apple Platforms", "## Android / Material", "## Cross-Platform Rule"],
@@ -170,6 +183,8 @@ def check_skill_frontmatter_and_body() -> None:
170
183
  fail("description must be <=1024 chars")
171
184
  if not description.startswith("Use when"):
172
185
  fail('description should start with "Use when"')
186
+ if fm.get("author") != "Rupak Biswas":
187
+ fail("SKILL.md author must be Rupak Biswas")
173
188
  if len(content) > 100_000:
174
189
  fail("SKILL.md exceeds 100,000 characters")
175
190
  if len(content) > 45_000:
@@ -185,7 +200,7 @@ def check_package_json() -> None:
185
200
  data = json.loads(PACKAGE.read_text(encoding="utf-8"))
186
201
  except Exception as exc:
187
202
  fail(f"package.json is invalid JSON: {exc}")
188
- for key in ["name", "version", "description", "type", "bin", "files", "scripts", "license", "engines"]:
203
+ for key in ["name", "version", "description", "type", "bin", "files", "scripts", "license", "author", "engines"]:
189
204
  if key not in data:
190
205
  fail(f"package.json missing {key}")
191
206
  if data["name"] != "ui-ux-master":
@@ -196,10 +211,14 @@ def check_package_json() -> None:
196
211
  fail("package.json license must be MIT")
197
212
  if data.get("bin", {}).get("ui-ux-master") != "./bin/ui-ux-master.mjs":
198
213
  fail("package.json bin.ui-ux-master must point to ./bin/ui-ux-master.mjs")
214
+ if data.get("bin", {}).get("ui-ux-master-mcp") != "./bin/ui-ux-master-mcp.mjs":
215
+ fail("package.json bin.ui-ux-master-mcp must point to ./bin/ui-ux-master-mcp.mjs")
216
+ if data.get("author") != "Rupak Biswas":
217
+ fail("package.json author must be Rupak Biswas")
199
218
  for script in ["validate", "test", "prepack"]:
200
219
  if script not in data.get("scripts", {}):
201
220
  fail(f"package.json scripts missing {script}")
202
- required_files = ["SKILL.md", "references/", "templates/", "agent-templates/", "docs/", "bin/", "scripts/", "tests/"]
221
+ required_files = ["SKILL.md", "references/", "templates/", "agent-templates/", "docs/", "system-prompts/", "ai-discovery/", "llms.txt", "bin/", "scripts/", "tests/"]
203
222
  for item in required_files:
204
223
  if item not in data.get("files", []):
205
224
  fail(f"package.json files missing {item}")
@@ -209,7 +228,7 @@ def check_bin_installer() -> None:
209
228
  text = (ROOT / "bin/ui-ux-master.mjs").read_text(encoding="utf-8")
210
229
  if not text.startswith("#!/usr/bin/env node"):
211
230
  fail("bin/ui-ux-master.mjs must have node shebang")
212
- for phrase in ["install", "doctor", "uninstall", "--dry-run", "fileURLToPath", "/ui-ux-master", "copyProjectSkillAssets", ".ui-ux-master"]:
231
+ for phrase in ["install", "doctor", "uninstall", "--dry-run", "fileURLToPath", "/ui-ux-master", "copyProjectSkillAssets", ".ui-ux-master", "system-prompts", "ai-discovery", "ui-ux-master-mcp"]:
213
232
  if phrase not in text:
214
233
  fail(f"bin installer missing {phrase}")
215
234
  forbidden = ["C:\\", "C:/xampp", "C:/Users", "/home/"]
@@ -234,9 +253,53 @@ def check_agent_templates() -> None:
234
253
  fail(f"slash compatibility docs missing {agent}")
235
254
 
236
255
 
256
+ def check_mcp_server() -> None:
257
+ text = (ROOT / "bin/ui-ux-master-mcp.mjs").read_text(encoding="utf-8")
258
+ if not text.startswith("#!/usr/bin/env node"):
259
+ fail("bin/ui-ux-master-mcp.mjs must have node shebang")
260
+ for phrase in ["tools/list", "tools/call", "resources/list", "resources/read", "prompts/list", "prompts/get", "ui-ux-master://skill", "generate_system_prompt"]:
261
+ if phrase not in text:
262
+ fail(f"MCP server missing {phrase}")
263
+ for bad in ["C:\\", "C:/xampp", "C:/Users", "/workspace"]:
264
+ if bad in text:
265
+ fail(f"MCP server contains local absolute path: {bad}")
266
+
267
+
268
+ def check_discovery_assets() -> None:
269
+ manifest = json.loads((ROOT / "ai-discovery/ui-ux-master.manifest.json").read_text(encoding="utf-8"))
270
+ if manifest.get("author") != "Rupak Biswas":
271
+ fail("AI manifest author must be Rupak Biswas")
272
+ if manifest.get("activation", {}).get("trigger") != "/ui-ux-master":
273
+ fail("AI manifest trigger must be /ui-ux-master")
274
+ if "ui-ux-master-mcp" not in manifest.get("entrypoints", {}).get("mcp_server_bin", ""):
275
+ fail("AI manifest missing mcp_server_bin entrypoint")
276
+ expected_resources = {
277
+ "ui-ux-master://skill",
278
+ "ui-ux-master://readme",
279
+ "ui-ux-master://llms",
280
+ "ui-ux-master://manifest",
281
+ "ui-ux-master://system-prompt",
282
+ "ui-ux-master://compact-prompt",
283
+ "ui-ux-master://mcp-prompt",
284
+ "ui-ux-master://mcp-docs",
285
+ "ui-ux-master://checklist",
286
+ "ui-ux-master://memory-template",
287
+ }
288
+ actual_resources = set(manifest.get("mcp", {}).get("resources", []))
289
+ missing_resources = sorted(expected_resources - actual_resources)
290
+ if missing_resources:
291
+ fail("AI manifest missing MCP resources: " + ", ".join(missing_resources))
292
+ for rel in ["README.md", "LICENSE", "llms.txt", "system-prompts/ui-ux-master-system-add-on.md", "system-prompts/ui-ux-master-compact.md", "system-prompts/ui-ux-master-mcp-add-on.md", "docs/mcp-server.md"]:
293
+ text = (ROOT / rel).read_text(encoding="utf-8")
294
+ if rel in {"README.md", "LICENSE"} and "Rupak Biswas" not in text:
295
+ fail(f"{rel} must identify Rupak Biswas")
296
+ if rel not in {"LICENSE"} and "/ui-ux-master" not in text:
297
+ fail(f"{rel} must mention /ui-ux-master")
298
+
299
+
237
300
  def check_referenced_files_exist() -> None:
238
301
  content = SKILL.read_text(encoding="utf-8")
239
- refs = sorted(set(re.findall(r"`((?:references|templates|agent-templates|docs|bin|scripts)/[^`]+?\.(?:md|mjs|py)|README\.md)`", content)))
302
+ refs = sorted(set(re.findall(r"`((?:references|templates|agent-templates|docs|bin|scripts|system-prompts|ai-discovery)/[^`]+?\.(?:md|mdc|mjs|py|json)|README\.md|llms\.txt)`", content)))
240
303
  for rel in refs:
241
304
  if rel in {"docs/ui-ux-memory.md", "docs/design/ui-ux-memory.md", "design/ui-ux-memory.md"}:
242
305
  continue
@@ -289,6 +352,8 @@ def main() -> None:
289
352
  check_package_json()
290
353
  check_bin_installer()
291
354
  check_agent_templates()
355
+ check_mcp_server()
356
+ check_discovery_assets()
292
357
  check_referenced_files_exist()
293
358
  check_markdown_links()
294
359
  check_release_artifacts(strict=args.release)
@@ -0,0 +1,5 @@
1
+ # UI/UX Master Compact System Prompt
2
+
3
+ Use UI/UX Master only when the user includes `/ui-ux-master`. Otherwise ignore this add-on.
4
+
5
+ When active, read `.ui-ux-master/SKILL.md` first, then relevant `.ui-ux-master/references/*` and `.ui-ux-master/templates/*`. Check `.ui-ux-memory.md` or equivalent before designing. Preserve existing brand, tokens, components, and platform conventions unless the user asks for redesign. Cover UX strategy, IA, flows, layout, states, accessibility, responsive behavior, content, localization risks, ethics/privacy, QA, metrics, and developer handoff. State whether UI/UX memory was read, created, updated, or unavailable.
@@ -0,0 +1,49 @@
1
+ # UI/UX Master MCP System Prompt Add-on
2
+
3
+ Use this add-on when an agent can connect to local MCP servers.
4
+
5
+ ## MCP Discovery
6
+
7
+ If an MCP server named `ui-ux-master` is available, discover and use its tools/resources/prompts when the user includes `/ui-ux-master`.
8
+
9
+ Expected local stdio command:
10
+
11
+ ```bash
12
+ npx ui-ux-master-mcp
13
+ ```
14
+
15
+ or, after package install:
16
+
17
+ ```bash
18
+ ui-ux-master-mcp
19
+ ```
20
+
21
+ ## Behavior
22
+
23
+ - Use MCP resources to read the latest skill, references, templates, and system prompt add-ons.
24
+ - Use MCP prompts to start common workflows such as audit, redesign, design-system creation, frontend handoff, or accessibility review.
25
+ - Use MCP tools for structured outputs such as install instructions, project memory templates, checklist retrieval, and prompt generation.
26
+ - Still activate only when `/ui-ux-master` is present.
27
+ - Prefer `.ui-ux-master/` project-local files when they exist; use MCP as the discovery and retrieval layer.
28
+
29
+ ## Hermes Example
30
+
31
+ ```yaml
32
+ mcp_servers:
33
+ ui_ux_master:
34
+ command: "npx"
35
+ args: ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]
36
+ ```
37
+
38
+ ## Claude Desktop / Other MCP Clients Example
39
+
40
+ ```json
41
+ {
42
+ "mcpServers": {
43
+ "ui-ux-master": {
44
+ "command": "npx",
45
+ "args": ["-y", "--package", "ui-ux-master", "ui-ux-master-mcp"]
46
+ }
47
+ }
48
+ }
49
+ ```
@@ -0,0 +1,47 @@
1
+ # UI/UX Master System Prompt Add-on
2
+
3
+ Use this add-on in any AI coding agent that supports custom instructions, system prompts, project rules, or model context.
4
+
5
+ ## Activation Rule
6
+
7
+ Activate UI/UX Master only when the user includes `/ui-ux-master` in the request. If the user does not include `/ui-ux-master`, do not apply this workflow automatically.
8
+
9
+ ## Source of Truth
10
+
11
+ When active, read `.ui-ux-master/SKILL.md` first. If `.ui-ux-master/` is not available, read the installed `ui-ux-master` package files. Use these references when relevant:
12
+
13
+ - `.ui-ux-master/references/ui-ux-memory-workflow.md`
14
+ - `.ui-ux-master/references/ui-ux-frontend-implementation-rules.md`
15
+ - `.ui-ux-master/references/ui-ux-complete-checklist.md`
16
+ - `.ui-ux-master/references/wcag-aa-quick-reference.md`
17
+ - `.ui-ux-master/references/accessibility-advanced-patterns.md`
18
+ - `.ui-ux-master/references/design-system-playbook.md`
19
+ - `.ui-ux-master/templates/ui-ux-memory.md`
20
+
21
+ ## Required Behavior
22
+
23
+ 1. Treat the rest of the prompt after `/ui-ux-master` as the user task.
24
+ 2. Check for existing UI/UX memory before designing: `.ui-ux-memory.md`, `docs/ui-ux-memory.md`, `docs/design/ui-ux-memory.md`, or `design/ui-ux-memory.md`.
25
+ 3. Inspect existing brand, tokens, components, CSS, routes, screenshots, dependencies, and similar screens before proposing UI changes.
26
+ 4. Preserve existing design conventions unless the user asks for redesign or rebrand.
27
+ 5. Include accessibility, responsive behavior, screen states, error/empty/loading/success states, content design, localization risks, platform conventions, analytics, QA, and developer handoff.
28
+ 6. If implementing frontend code, follow existing stack conventions and avoid arbitrary new dependencies.
29
+ 7. State whether UI/UX memory was read, created, updated, or unavailable.
30
+
31
+ ## Default Output Shape
32
+
33
+ When the user does not request a specific format, return:
34
+
35
+ - Product/user goal
36
+ - Assumptions and evidence confidence
37
+ - UX/IA/flow recommendations
38
+ - Visual and interaction direction
39
+ - Component/state specifications
40
+ - Accessibility and responsive requirements
41
+ - Content/copy recommendations
42
+ - Implementation handoff and acceptance criteria
43
+ - QA checklist and next steps
44
+
45
+ ## Quality Bar
46
+
47
+ Do not stop at pretty screens. Produce senior-level UI/UX work that is usable, accessible, coherent, implementable, brand-consistent, and measurable.
@@ -2,11 +2,12 @@ import assert from 'node:assert/strict';
2
2
  import fs from 'node:fs';
3
3
  import os from 'node:os';
4
4
  import path from 'node:path';
5
- import { execFileSync } from 'node:child_process';
5
+ import { execFileSync, spawnSync } from 'node:child_process';
6
6
  import test from 'node:test';
7
7
 
8
8
  const root = path.resolve(import.meta.dirname, '..');
9
9
  const bin = path.join(root, 'bin', 'ui-ux-master.mjs');
10
+ const mcpBin = path.join(root, 'bin', 'ui-ux-master-mcp.mjs');
10
11
  const pkg = JSON.parse(fs.readFileSync(path.join(root, 'package.json'), 'utf8'));
11
12
  const templates = [
12
13
  'agent-templates/claude/commands/ui-ux-master.md',
@@ -22,10 +23,21 @@ function run(args, cwd = root) {
22
23
  return execFileSync(process.execPath, [bin, ...args], { cwd, encoding: 'utf8' });
23
24
  }
24
25
 
25
- test('package exposes ui-ux-master bin', () => {
26
+ function runMcp(messages) {
27
+ const input = messages.map(m => JSON.stringify(m)).join('\n') + '\n';
28
+ const res = spawnSync(process.execPath, [mcpBin], { input, encoding: 'utf8', cwd: root, timeout: 5000 });
29
+ assert.equal(res.status, 0, res.stderr);
30
+ return res.stdout.trim().split(/\n+/).map(line => JSON.parse(line));
31
+ }
32
+
33
+ test('package exposes cli and mcp bins with Rupak Biswas author', () => {
34
+ assert.equal(pkg.author, 'Rupak Biswas');
26
35
  assert.equal(pkg.bin['ui-ux-master'], './bin/ui-ux-master.mjs');
36
+ assert.equal(pkg.bin['ui-ux-master-mcp'], './bin/ui-ux-master-mcp.mjs');
27
37
  assert.ok(fs.existsSync(bin));
38
+ assert.ok(fs.existsSync(mcpBin));
28
39
  assert.ok(fs.readFileSync(bin, 'utf8').startsWith('#!/usr/bin/env node'));
40
+ assert.ok(fs.readFileSync(mcpBin, 'utf8').startsWith('#!/usr/bin/env node'));
29
41
  });
30
42
 
31
43
  test('agent templates include trigger and avoid local absolute paths', () => {
@@ -38,10 +50,29 @@ test('agent templates include trigger and avoid local absolute paths', () => {
38
50
  }
39
51
  });
40
52
 
53
+ test('discovery assets and system prompts exist', () => {
54
+ const required = [
55
+ 'llms.txt',
56
+ 'ai-discovery/ui-ux-master.manifest.json',
57
+ 'system-prompts/ui-ux-master-system-add-on.md',
58
+ 'system-prompts/ui-ux-master-compact.md',
59
+ 'system-prompts/ui-ux-master-mcp-add-on.md',
60
+ 'docs/mcp-server.md',
61
+ ];
62
+ for (const rel of required) {
63
+ const text = fs.readFileSync(path.join(root, rel), 'utf8');
64
+ assert.match(text, /\/ui-ux-master/);
65
+ }
66
+ const manifest = JSON.parse(fs.readFileSync(path.join(root, 'ai-discovery/ui-ux-master.manifest.json'), 'utf8'));
67
+ assert.equal(manifest.author, 'Rupak Biswas');
68
+ assert.equal(manifest.activation.trigger, '/ui-ux-master');
69
+ assert.equal(manifest.entrypoints.mcp_server_bin, 'ui-ux-master-mcp');
70
+ });
71
+
41
72
  test('cli help doctor and where work', () => {
42
- assert.match(run(['--help']), /ui-ux-master install/);
73
+ assert.match(run(['--help']), /ui-ux-master-mcp/);
43
74
  assert.match(run(['where']).trim(), /UI-UX Skills|ui-ux-master/i);
44
- assert.match(run(['doctor', '--dry-run']), /trigger: \/ui-ux-master/);
75
+ assert.match(run(['doctor', '--dry-run']), /bin\/ui-ux-master-mcp\.mjs|bin\\ui-ux-master-mcp\.mjs/);
45
76
  });
46
77
 
47
78
  test('project install dry-run does not write', () => {
@@ -58,6 +89,9 @@ test('project install writes expected files and is idempotent', () => {
58
89
  run(['install', '--project', '--dir', dir]);
59
90
  run(['install', '--project', '--dir', dir]);
60
91
  assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'SKILL.md')));
92
+ assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'llms.txt')));
93
+ assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'ai-discovery', 'ui-ux-master.manifest.json')));
94
+ assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'system-prompts', 'ui-ux-master-system-add-on.md')));
61
95
  assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'references', 'ui-ux-memory-workflow.md')));
62
96
  assert.ok(fs.existsSync(path.join(dir, '.ui-ux-master', 'templates', 'ui-ux-memory.md')));
63
97
  assert.ok(fs.existsSync(path.join(dir, '.claude', 'commands', 'ui-ux-master.md')));
@@ -69,3 +103,29 @@ test('project install writes expected files and is idempotent', () => {
69
103
  assert.match(agents, /\.ui-ux-master\/SKILL\.md/);
70
104
  assert.match(agents, /\/ui-ux-master/);
71
105
  });
106
+
107
+ test('mcp server lists tools resources prompts and can return the skill', () => {
108
+ const responses = runMcp([
109
+ { jsonrpc: '2.0', id: 1, method: 'initialize', params: {} },
110
+ { jsonrpc: '2.0', id: 2, method: 'tools/list', params: {} },
111
+ { jsonrpc: '2.0', id: 3, method: 'resources/list', params: {} },
112
+ { jsonrpc: '2.0', id: 4, method: 'prompts/list', params: {} },
113
+ { jsonrpc: '2.0', id: 5, method: 'tools/call', params: { name: 'get_asset', arguments: { name: 'system_prompt' } } },
114
+ ]);
115
+ assert.equal(responses[0].result.serverInfo.name, 'ui-ux-master');
116
+ assert.ok(responses[1].result.tools.some(t => t.name === 'generate_system_prompt'));
117
+ assert.ok(responses[2].result.resources.some(r => r.uri === 'ui-ux-master://skill'));
118
+ assert.ok(responses[2].result.resources.some(r => r.uri === 'ui-ux-master://memory-template'));
119
+ assert.ok(responses[3].result.prompts.some(p => p.name === 'ui-ux-audit'));
120
+ assert.match(responses[4].result.content[0].text, /Activation Rule/);
121
+ });
122
+
123
+ test('mcp server handles prompt retrieval and unknown methods correctly', () => {
124
+ const responses = runMcp([
125
+ { jsonrpc: '2.0', id: 1, method: 'prompts/get', params: { name: 'ui-ux-design-system', arguments: { scope: 'admin dashboard' } } },
126
+ { jsonrpc: '2.0', id: 2, method: 'not/a-method', params: {} },
127
+ ]);
128
+ assert.match(responses[0].result.messages[0].content.text, /\/ui-ux-master/);
129
+ assert.match(responses[0].result.messages[0].content.text, /admin dashboard/);
130
+ assert.equal(responses[1].error.code, -32601);
131
+ });