Ac tools human agentic design

From WaterplanAI/agentic-config · View interactive version

Ac tools human agentic design is an AI agent skill from the GitHub repository WaterplanAI/agentic-config. Generates interactive HTML prototypes optimized for dual human+agent interaction. Produces semantic, accessible designs with Tailwind + DaisyUI (Tier A) or React + shadcn/ui + Vite (Tier B). Triggers on keywords: prototype, design, UI prototype, landing page, dashboard, form design, human-agentic, h

How to use this skill

Skill file

Human-Agentic Design

Compatibility Note

This pi wrapper preserves the original optional Playwright preview loop, but the documented non-MCP fallback remains mandatory when preview tooling is unavailable.

Generates live, interactive prototype designs optimized for dual human+agent interaction. Every prototype is equally usable by humans (visual interaction) and AI agents (programmatic interaction via accessibility trees).

Purpose

Workflow

1. Environment Probe

Detect available capabilities. Run these checks silently (no user prompting):

# Check Playwright MCP availability (tool list includes mcp__playwright__*)
# Check Node.js
if NODE_BIN=$(command -v node); then "$NODE_BIN" --version; fi

Tier Selection:

Report detected tier to user in one line:

Environment: Tier [A|B] | Playwright: [available|unavailable] | Node: [vX.Y.Z|not found]

If user explicitly requests a tier, honor that request regardless of detection.

2. Parse Request

Identify from user prompt:

If page type matches a built-in template, use it as starting point. Read the template from templates/<type>.html within this skill directory.

3. Generate Code

Tier A (HTML + Tailwind CDN + DaisyUI CDN):

Tier B (React + shadcn/ui + Vite):

MANDATORY for ALL generated code (both tiers):

  1. Semantic HTML: <main>, <nav>, <header>, <footer>, <article>, <section>, <button> (not <div onclick>)
  2. ARIA only when native HTML insufficient
  3. data-testid on every interactive element (semantic names)
  4. URL-driven state via search params
  5. JSON-LD metadata in <script type="application/ld+json">
  6. No Shadow DOM (light DOM only)
  7. Explicit label associations (<label for>, <fieldset> + <legend>)
  8. Keyboard navigable (tab order, focus indicators, escape to close modals)

4. Write Files

Output directory: /tmp/pi-prototypes/<session-id>/

Generate <session-id> as: YYYYMMDD-HHMM-<slug> where <slug> is a 2-3 word kebab-case description of the prototype.

# Create output directory
mkdir -p /tmp/pi-prototypes/<session-id>

Write all files using the Write tool.

5. Preview (Playwright MCP)

If Playwright MCP is available:

Tier A preview:

1. Start server:    python3 -m http.server 8080 -d /tmp/pi-prototypes/<session-id>
2. Navigate:        mcp__playwright__browser_navigate -> http://localhost:8080
3. Screenshot:      mcp__playwright__browser_take_screenshot (desktop viewport)
4. A11y snapshot:   mcp__playwright__browser_snapshot
5. Responsive:      mcp__playwright__browser_resize (375x667) -> screenshot -> resize back

Tier B preview:

1. Install deps:    cd /tmp/pi-prototypes/<session-id> && npm install
2. Start Vite:      npm run dev (background)
3. Navigate:        mcp__playwright__browser_navigate -> http://localhost:5173
4. Screenshot:      mcp__playwright__browser_take_screenshot
5. A11y snapshot:   mcp__playwright__browser_snapshot
6. Responsive:      mcp__playwright__browser_resize (375x667) -> screenshot -> resize back

If Playwright MCP unavailable:

Output file paths and manual open instructions:

Prototype ready at: /tmp/pi-prototypes/<session-id>/index.html

To preview:
  Option 1: open /tmp/pi-prototypes/<session-id>/index.html
  Option 2: cd /tmp/pi-prototypes/<session-id> && python3 -m http.server 8080
             Then open http://localhost:8080

6. Validate

After generating, validate against checklist (read cookbook/validation.md):

Report validation result. Fix any failures before delivering.

7. Iterate

When user provides feedback:

  1. Re-read relevant cookbook files if needed
  2. Edit specific sections of generated files (prefer Edit over full rewrite)
  3. Re-preview via Playwright MCP (if available)
  4. Re-validate
  5. Report changes made

8. Deliver

Provide:

Environment Detection Details

Playwright MCP Detection

The skill's allowed-tools includes Playwright MCP tools. If these tools are available in the current session, the preview loop is enabled. If not available (tools not registered), graceful fallback to file paths only.

Do NOT error or warn loudly about Playwright absence. Simply skip the preview step and provide file paths.

Node.js Detection

if NODE_BIN=$(command -v node); then
    NODE_VERSION=$("$NODE_BIN" --version)
    echo "Node.js $NODE_VERSION detected - Tier B available"
else
    echo "Node.js not found - Tier A only"
fi

Port Conflict Resolution (Tier A)

If python3 -m http.server 8080 fails (port in use), try 8081, 8082, etc. up to 8090.

Port Conflict Resolution (Tier B)

Vite auto-increments ports. If 5173 is taken, it uses 5174, etc. No manual handling needed.

Error Handling

| Scenario | Behavior |

|----------|----------|

| Playwright MCP unavailable | Output file paths, print manual open instructions. NO error. |

| Node.js not installed | Stay on Tier A. Inform user Tier B requires Node.js. |

| CDN unreachable (offline) | Warn user. Suggest: npm install -D tailwindcss daisyui |

| Vite dev server fails | Fall back to Tier A single-file generation. |

| Port conflict | Auto-increment port (see above). |

| Template not found | Generate from scratch using principles + tier cookbook. |

Anti-Patterns (NEVER DO)

Output Format

After generation, output a summary:

## Prototype Generated

**Tier**: A (HTML + Tailwind CDN + DaisyUI CDN)
**Type**: <page-type>
**Files**:
  - /tmp/pi-prototypes/<session-id>/index.html

**Preview**: [screenshot if Playwright available]
**A11y Validation**: PASS | X landmarks detected: main, nav, header, footer
**Semantic Checks**: PASS | h1 present, heading hierarchy valid, N data-testid attributes

To open: open /tmp/pi-prototypes/<session-id>/index.html

Responsive Breakpoints

When testing responsive design via Playwright MCP:

| Device | Width | Height |

|--------|-------|--------|

| Mobile | 375 | 667 |

| Tablet | 768 | 1024 |

| Desktop | 1440 | 900 |

Supporting Files

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.