Skip to content

prototype — Throwaway Prototyping

  • Trigger: /prototype or keywords "prototype", "quick demo", "throwaway", "try a few designs"
  • Best for: Design validation, data model exploration, UI comparison, feasibility checks
  • Not for: Production feature development, code needing full test coverage

Overview

prototype builds quick throwaway prototypes. It routes between two branches:

  • Terminal app — Validate state machines, business logic, data models
  • UI variants — Toggle between radically different UI designs from one route

Core philosophy: validate the design before investing in implementation.

Trigger Conditions

prototype auto-triggers when you:

  • Mention "prototype", "try it out", "quick validation"
  • Want to verify a design before building
  • Are unsure about a data model or state machine
  • Use the /prototype command

Examples

Example 1: State Machine Validation

/prototype I want to validate an order state machine: pending → paid → shipped → delivered, with cancel and refund support

Claude builds a terminal app for hands-on state transitions, checking for:

  • Unreachable states
  • State conflicts under concurrency
  • Missing transition paths

Example 2: Data Model Exploration

/prototype Design a permission system data model supporting RBAC and org hierarchy permissions

Example 3: UI Design Comparison

/prototype Design 3 different layout options for the user settings page

Claude generates 3 toggleable UI variants on one route for side-by-side comparison.

Example 4: API Design Validation

/prototype Design a RESTful API for a blog system, validate URL structure and request/response format

Example 5: Algorithm Validation

/prototype Verify a permutation generation algorithm with input [1,2,3,4], check correctness and large-input performance

Workflow

  1. Define the validation goal — What are you testing?
  2. Build prototype — Claude creates a minimal runnable version
  3. Interactive testing — You run and test the prototype
  4. Gather feedback — Find design issues or confirm the approach
  5. Discard or reference — Prototype code is thrown away; keep only the design decisions

Notes

  • Prototypes are disposable — don't build production code directly on them
  • No test coverage, error handling, or performance optimization needed
  • After validation, use /tdd or normal development for implementation
  • If the prototype reveals design flaws, that's a success, not a failure
  • UI prototypes focus on layout and interaction flow, not visual polish
  • tdd — After prototype validation, implement with TDD
  • grill-me — Deep questioning during the design phase
  • to-prd — Generate a PRD after prototype validation