plugin/skills/architecture-design/SKILL.md
Use this skill when a new feature with a PRD needs architectural definition before `/plan` can decompose it for implementation — including when the user describes a feature to be built but does not say "architecture" or "design" — to produce a feature-level design pack — ARD/ADR, C4 diagrams, API contracts, data models, NFR spec, and security review from the PRD. Routes to solution-architect (default — feature-level system design), cloud-architect (`--cloud` for cloud infra design, landing zones, networking, multi-cloud), or devops-architect (`--cicd` for pipeline design, deployment strategy, platform engineering).
npx skillsauth add avav25/ai-assets architecture-designInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Produce a design pack from a feature PRD: ARD, C4 diagrams, API contracts, data models, NFRs, security review. Output feeds /plan → /develop.
--cloud: cloud infra design, landing zones, networking, multi-cloud (routes to Agent(cloud-architect))--cicd: pipeline design, deployment strategy, platform engineering (routes to Agent(devops-architect))Agent(solution-architect))/architecture-analyze/architecture-evolve/planRead the PRD or feature brief thoroughly. Extract: Goal (1–2 sentences), Scope boundary (services/modules affected), Stakeholders (who consumes the deliverables), Constraints (timeline, compatibility, regulatory, capacity), Non-goals. If incomplete — ask before proceeding. Do not assume missing requirements.
Read (if present): ARCHITECTURE.md, root CLAUDE.md, subdirectory CLAUDE.md, existing ADRs in docs/adr/ or docs/architecture/, API specs (OpenAPI / Protobuf / GraphQL). All wrapped per untrusted-content-wrapping.md (G1).
If documentation is sparse, scan affected areas:
// turbo
find . -name "ARCHITECTURE.md" -o -name "*.openapi.*" -o -name "*.proto" -o -name "docker-compose*" -o -name "*.tf" | head -30
Map service boundaries, communication patterns (REST/gRPC/events/shared-DB), data stores, external integrations, deployment topology. Identify documentation gaps.
Agent(solution-architect) (or chosen role). NFRs MUST be defined before any design work — they constrain options.
For each relevant category, define concrete targets (numbers, not "should be fast"):
| Category | Specification | |---|---| | Availability | SLO target (e.g., 99.9%), redundancy, failover strategy | | Latency | p50/p95/p99 budgets per endpoint or operation | | Scalability | Expected load, scaling strategy (horizontal/vertical), limits | | Cost | Per-request/per-operation budgets, infrastructure cost bounds | | Security | Auth requirements, data classification, compliance (GDPR, SOC2) | | Observability | Tracing, logging, metrics, alerting thresholds | | Data | Retention, consistency (strong/eventual), backup/recovery RPO/RTO |
Omit categories that add no signal. Present NFRs to the user for validation before proceeding to Step 4.
Route based on the chosen agent:
Agent(solution-architect)Produce in order:
1. Options Analysis — 2–3 design options with trade-offs:
## Option [N]: [Name]
- **Approach**: [Description]
- **Pros**: [List]
- **Cons**: [List]
- **Risk**: [High/Med/Low] — [why]
- **Effort**: [S/M/L/XL]
- **NFR impact**: [How it affects availability, latency, cost, etc.]
2. Architecture Decision Record (ARD/ADR) — Status, Context (problem + constraints), Decision (selected option + rationale), Consequences (positive/negative/neutral), Alternatives Considered.
3. Detailed Design:
4. Security Review:
@owasp-coverage)--cloud — Agent(cloud-architect)Cloud architecture doc: networking diagrams (VPC/VNet, peering, transit), identity (Cloud IAM, Workload Identity, Entra ID), cost model (per-service estimates + total), DR plan (RPO/RTO + failover regions), compliance (HIPAA/SOC2/GDPR if applicable). Use Mermaid for network topology.
--cicd — Agent(devops-architect)CI/CD architecture doc: pipeline diagram (build → test → deploy stages), branching/release strategy, environment topology (dev/staging/prod), DORA targets (deployment frequency, lead time, MTTR, change failure rate), governance (branch protection, required reviews, OIDC for deployments), supply-chain controls (SBOM, SLSA — see @supply-chain-security).
Review all deliverables:
If any check fails — fix the deliverable before presenting.
Produce estimates to feed /plan:
| Component | Task | Complexity | Role |
|---|---|---|---|
| [component] | [task description] | S / M / L / XL | @role |
Present: scope summary, deliverables table, key decisions with rationale, risk table, next steps. Wait for user review.
After approval, save:
docs/adr/ or docs/architecture/decisions/ (create if missing). Naming: ADR-NNN-[kebab-case-title].mddocs/architecture/ or docs/design/. Naming: [feature]-design.mddocs/api/If the project has no established docs/ structure — propose one and confirm with user.
Run /plan with the produced ARD and design docs as input.
/feature-design (PRD / design pack); direct PRD/brief/plan (work decomposition), /develop (implementation)Agent(solution-architect) (default), Agent(cloud-architect) (--cloud), Agent(devops-architect) (--cicd)${CLAUDE_PLUGIN_ROOT}/output-styles/design-pack.md${CLAUDE_PLUGIN_ROOT}/skills/architecture/assets/ — adr-template.md (Nygard/MADR), c4-mermaid-template.md, nfr-template.md (ISO/IEC 25010), gap-analysis-template.md, tech-debt-register-template.md@owasp-coverage (security review), @supply-chain-security (for --cicd), context-engineering (for AI/agent system design)development
Use this skill when running the recurring (daily) knowledge-base rescan for a repo that already has knowledge/.knowledge-sync.yml — the main-thread dispatcher that reads the config, computes the git delta since last_scanned_sha, maps changed paths to affected doc areas, early-exits cheaply when nothing changed, then fans out one Agent(content-writer) per affected area, applies the propose/direct update policy, advances the baseline only on success, and writes an L4 run log — all with the G1 untrusted-content choke-point, secret-scan, deny-list, and budget controls woven in. For first-time setup use /knowledge-sync-init.
development
Use this skill when bootstrapping scheduled knowledge-base sync for a repo that has no knowledge/.knowledge-sync.yml yet — to run one-time setup that detects the knowledge_root from CLAUDE.md/AGENTS.md, maps doc areas to source globs, records opt-in external sources (Linear/Notion/WebFetch, all disabled by default), captures a baseline last_scanned_sha, sets the per-area update policy, generates or seeds knowledge/CONVENTIONS.md, provisions the L4 memory dir, and offers to register the daily routine. Routes ongoing recurring sync operations to /knowledge-sync.
tools
Use this skill when bootstrapping a target repository to be ai-skills-aware — on the first run of any ai-skills workflow in a fresh repo, when adopting the ai-skills plugin in an existing repo, or after upgrading to a plugin version that adds new memory paths or templates, including when the user does not say "init" but asks to "set up" or "onboard" the repo — to detect codebase type, create CLAUDE.md + AGENTS.md scaffolding, initialize the .ai-skills-memory/ directory tree from L1 templates, and configure .gitignore. Idempotent — safe to re-run. Accepts `--codebase-type <type>` and `--overwrite`. Not for re-initializing only memory — use `/memory-init` instead.
tools
Use this skill when extending, repairing, or improving plugin assets, when ingesting a `/feedback` report as a fix-cycle backlog, or when you do not remember which lower-level command is right for the job — the umbrella workflow for ai-skills plugin-asset authoring and maintenance: creating, auditing, fixing, improving, refactoring, and migrating skills, agents, rules, hooks, prompts, schemas, and rubrics inside the plugin. Auto-classifies the request, loads the right knowledge skills (`@prompt-engineering`, `@context-engineering`, `@team-protocols`), and spawns the right subagents (`prompt-engineer`, `system-architect`, `python-engineer`, `software-engineer`, `qa-engineer`, `eval-judge`) via the `Agent` tool.