ai-toolkit-rules
Mandatory engineering, security, testing, git, performance, quality, and response rules.…
Generates and compares parallel interface designs (Ousterhout 'Design It Twice'). Triggers: design API, interface options, compare modules, design it twice.
$ npx -y skills add softspark/ai-toolkit --skill design-an-interface --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/design-an-interfaceContext preview
The summary Claude sees to decide when to auto-load this skill.
Generates and compares parallel interface designs (Ousterhout 'Design It Twice'). Triggers: design API, interface options, compare modules, design it twice.
name: design-an-interface description: "Generates and compares parallel interface designs (Ousterhout 'Design It Twice'). Triggers: design API, interface options, compare modules, design it twice." user-invocable: true effort: high argument-hint: "[module or interface to design]" allowed-tools: Read, Grep, Glob, Bash, Agent
$ARGUMENTS
Generate 3+ radically different interface designs using parallel sub-agents, then compare. Based on "Design It Twice" from "A Philosophy of Software Design."
/design-an-interface [module or interface to design]
1. **Gathers** requirements and constraints 2. **Spawns** 3+ parallel sub-agents with different design constraints 3. **Presents** each design with signatures, usage examples, and trade-offs 4. **Compares** on simplicity, depth, efficiency, and correctness 5. **Synthesizes** best elements into final recommendation
Before designing, understand:
Spawn 3+ sub-agents simultaneously using Agent tool. Each gets a **radically different** constraint:
| Agent | Constraint | |-------|-----------| | Agent 1 | Minimize method count — aim for 1-3 methods max | | Agent 2 | Maximize flexibility — support many use cases | | Agent 3 | Optimize for the most common case | | Agent 4 | Take inspiration from a specific paradigm/library |
Each agent outputs: 1. Interface signature (types/methods) 2. Usage example (how caller uses it) 3. What this design hides internally 4. Trade-offs of this approach
Show each design sequentially so user can absorb each approach before comparison: 1. **Interface signature** — types, methods, params 2. **Usage examples** — how callers actually use it 3. **What it hides** — complexity kept internal
Compare in prose (not tables) on:
| Criterion | Description | |-----------|-------------| | Interface simplicity | Fewer methods, simpler params | | General-purpose vs specialized | Flexibility vs focus | | Implementation efficiency | Does shape allow efficient internals? | | Depth | Small interface hiding significant complexity (good) vs large interface with thin implementation (bad) | | Ease of correct use | vs ease of misuse |
Often the best design combines insights from multiple options. Give an opinionated recommendation. Ask:
When upcoming design explorations will involve visual content (mockups, layout comparisons, architecture diagrams), offer the browser companion:
> "Some of these interface designs might be easier to compare visually. I can show diagrams and side-by-side comparisons in a browser. Want to try it?"
**This offer MUST be its own message.** Do not combine with other questions. Wait for response.
If accepted, start the server and use it for visual comparisons only. Text/conceptual questions stay in terminal.
See [../write-a-prd/reference/visual-companion.md](../write-a-prd/reference/visual-companion.md) for details.
This skill designs interfaces. It does NOT write implementation code.
AI coding toolkit with machine-enforced safety, 116 skills, 44 agents, lifecycle hooks, persona presets, opt-in plugin packs, and benchmark tooling.
Repo: softspark/ai-toolkit
Mandatory engineering, security, testing, git, performance, quality, and response rules.…
Searches past coding sessions for observations, decisions, context. Triggers: mem-search,…
Accessibility validator: WCAG 2.1 AA, EN 301 549, EAA. Triggers: a11y, accessibility, WCAG,…
Creates new specialized agents with frontmatter, tools, delegation. Triggers: new agent,…
Analyzes code quality, complexity, patterns across codebase. Triggers: quality report,…
API design: naming, versioning, pagination, idempotency, OpenAPI, error contracts and safe…