From vista
Plan a new feature through interactive questioning, producing domain requirements and architecture diagrams.
How this skill is triggered — by the user, by Claude, or both
Slash command
/vista:planThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Plan a new feature through deep interactive questioning, producing domain requirements and architecture diagrams as the source of truth.
Plan a new feature through deep interactive questioning, producing domain requirements and architecture diagrams as the source of truth.
/vista:plan <feature-name>
user-auth, payment-flow)1a. Scaffold the feature directory:
python vista/scripts/setup-feature.py --name $ARGUMENTS
This creates docs/<name>/ with:
domain-requirements.md — Domain requirements templatespecs/ — Specification documents directory (populated later by /vista:specs)arch/ — Architecture diagrams directory with empty _arch.json manifestprogress.txt — Progress trackingIMPLEMENTATION_PLAN.md — Implementation plan (populated by Ralph loops)If the directory already exists, the script exits gracefully. Proceed to Step 1b.
1b. Brief codebase exploration:
Use subagents to quickly understand the project's existing patterns before asking questions.
vista/skills/plan/references/discovery-process.mdLaunch 1-3 Explore agents in parallel to discover:
Present a concise summary of findings to the user. This gives both you and the user shared context before diving into requirements.
This is the core of the plan skill. Use AskUserQuestion extensively — ask about every major area until the user is satisfied.
Reference: vista/skills/plan/references/domain-requirements-template.md
Work through these areas interactively:
Write answers incrementally to docs/<name>/domain-requirements.md as each area is discussed. Don't wait until the end.
As requirements emerge, identify components with heavy logic that would benefit from test-driven development. Look for:
Add a ## TDD Candidates section at the end of domain-requirements.md:
## TDD Candidates
- **[ComponentName]**: [reason — e.g., "Complex state machine with 8 states and 15 transitions"]
- **[ComponentName]**: [reason — e.g., "Pricing calculation with discount stacking rules"]
After questioning is complete, tell the user:
Consider running
/vista:tdd <name>to generate test-first diagrams for flagged components before proceeding to specs.
Based on the completed domain-requirements.md, generate diagram files in arch/.
Generate diagrams based on the requirements gathered. Default to Mermaid (.mmd) for all diagram types. Use alternative formats when they provide clear advantages:
| Diagram | File | When to Create |
|---|---|---|
| System Architecture | system-architecture.mmd | Always — shows major components and relationships |
| User Flow | user-flow.mmd | Always — shows primary user journeys as flowchart |
| Data Model | data-model.mmd | When entities/data exist — ER diagram |
| Sequence Diagrams | sequence-{flow}.mmd | For each key interaction flow (typically 2-5) |
| State Diagrams | state-{component}.mmd | For stateful components (if any) |
| Design Rationale | design-rationale.md | Optional — prose documentation, ADRs, architecture decisions |
Not every feature needs every diagram type. Use judgment based on complexity.
Supported formats:
| Format | Extension | Best For | Rendering |
|---|---|---|---|
| Mermaid | .mmd | Default — all diagram types (flowchart, sequence, ER, state, etc.) | Client-side via mermaid.js |
| PlantUML | .puml | Optional — detailed UML class/sequence diagrams when Mermaid syntax is limiting | Server-side via PlantUML server |
| D2 | .d2 | Optional — architecture diagrams with clean declarative syntax | Raw source (Kroki server optional) |
| Graphviz | .dot | Optional — dependency graphs, network topology diagrams | Client-side via viz.js WASM |
| Draw.io | .drawio | Optional — complex visual diagrams created with Draw.io editor | Iframe via viewer.diagrams.net |
| Markdown | .md | Optional — prose documentation, design rationale, ADRs | marked.js with inline editing |
Each .mmd file must contain valid Mermaid syntax. Follow these conventions:
Example system architecture:
flowchart TD
subgraph Client
UI[Web UI]
Cache[Local Cache]
end
subgraph Server
API[REST API]
Auth[Auth Service]
DB[(Database)]
end
UI --> API
API --> Auth
API --> DB
UI --> Cache
Example ER diagram:
erDiagram
USER ||--o{ ORDER : places
ORDER ||--|{ LINE_ITEM : contains
PRODUCT ||--o{ LINE_ITEM : "appears in"
USER {
string id PK
string email
string name
}
ORDER {
string id PK
string user_id FK
date created_at
string status
}
Update arch/_arch.json to reference all generated diagrams:
{
"feature": "<name>",
"diagrams": [
{
"name": "System Architecture",
"file": "system-architecture.mmd",
"type": "mermaid",
"diagramType": "flowchart",
"category": "architecture",
"description": "High-level system components and their relationships"
},
{
"name": "User Flow",
"file": "user-flow.mmd",
"type": "mermaid",
"diagramType": "flowchart",
"category": "architecture",
"description": "Primary user journey through the feature"
},
{
"name": "Design Rationale",
"file": "design-rationale.md",
"type": "markdown",
"diagramType": "custom",
"category": "architecture",
"description": "Architecture decisions and design rationale"
}
]
}
The manifest must conform to vista/templates/arch-schema.json. Valid type values: mermaid, drawio, plantuml, d2, graphviz, markdown. Non-mermaid types should use diagramType: "custom".
Discover the dashboard URL by calling the ralph_providers MCP tool and reading dashboard_url from the response.
Tell the user:
Review diagrams in the web dashboard:
<dashboard_url>/project/<project-id>/arch/<feature-name>
Use the AI chat panel to discuss and iterate on diagrams.
Or review directly by reading the .mmd files in the terminal and discussing changes.
Next steps:
/vista:tdd <name> — Generate TDD diagrams for flagged heavy-logic components/vista:specs <name> — Generate detailed specifications from requirements + diagramsAfter completion, docs/<name>/ contains:
docs/<name>/
├── arch/
│ ├── _arch.json # Diagram manifest (auto-updated by DiagramWatcher)
│ ├── system-architecture.mmd # System components overview
│ ├── user-flow.mmd # User journey flowchart
│ ├── data-model.mmd # Entity-relationship diagram
│ ├── sequence-*.mmd # Interaction sequence diagrams
│ ├── state-*.mmd # State transition diagrams (if applicable)
│ ├── *.puml # PlantUML diagrams (optional)
│ ├── *.d2 # D2 diagrams (optional)
│ ├── *.dot # Graphviz diagrams (optional)
│ └── *.md # Markdown documentation (optional, editable inline)
├── specs/ # Empty (populated by /vista:specs)
├── domain-requirements.md # Filled domain requirements with TDD candidates
├── progress.txt # Progress tracking
└── IMPLEMENTATION_PLAN.md # Template (populated by Ralph loops)
Reference documents in vista/skills/plan/references/:
domain-requirements-template.md — Template and questioning guide for domain requirementsdiscovery-process.md — Guide for codebase exploration with subagentsagent-prompts.md — Reusable agent prompt templates for discoveryexamples.md — Example plans showing the 3-step workflowCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub ribeec20/vista-marketplace --plugin vista