Prd V06 Architecture Design logo

Prd V06 Architecture Design

Community
mattgierhart
prd-v06-architecture-design

Define how system components connect, establishing boundaries, patterns, and integration approaches during PRD v0.6 Architecture. Triggers on requests to design architecture, create system design, define component relationships, or when user asks "design architecture", "system design", "how do components connect?", "architecture decisions", "technical architecture", "system overview". Consumes TECH- (stack selections), RISK- (constraints), FEA- (features). Outputs ARC- entries documenting architecture decisions with rationale. Feeds v0.6 Technical Specification.

Overview

Publishermattgierhart
RepositoryPRD-driven-context-engineering
Skill nameprd-v06-architecture-design
Stars
179
Forks
11
Bundled files
3
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 3 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by mattgierhart on GitHub. Read the source before you install it.

Installation

Install the Prd V06 Architecture Design AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/mattgierhart/PRD-driven-context-engineering.git /tmp/PRD-driven-context-engineering
mkdir -p .claude/skills
cp -r /tmp/PRD-driven-context-engineering/plugins/prd-ce/skills/prd-v06-architecture-design .claude/skills/prd-v06-architecture-design
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Prd V06 Architecture Design in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Prd V06 Architecture Design on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Prd V06 Architecture Design is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Architecture Design

Position in workflow: v0.5 Technical Stack Selection → v0.6 Architecture Design → v0.6 Technical Specification

Architecture defines how your system components connect. This skill transforms stack selections into a coherent system design with explicit boundaries and integration patterns.

Consumes

This skill requires prior work from v0.3-v0.5:

  • TECH-* technology decisions (from v0.5 Technical Stack Selection) — Tech choices become components; Build items become internal services, Buy/Integrate items become external connections
  • RISK-* risk entries (from v0.5 Risk Discovery Interview) — High-priority RISK-* entries must have architectural mitigations; drives design decisions on failover, security, scaling
  • FEA-* feature entries (from v0.3 Features Value Planning) — Features determine what components must be built; complex features may require distributed patterns
  • ARC-* existing architecture decisions (from prior products if brownfield) — Inherited patterns constrain new designs (monolith with microservice, library reuse, auth pattern, etc.)

This skill assumes v0.5 Technical Stack Selection is complete with TECH- entries providing technology foundations.

Produces

This skill creates/updates:

  • ARC-* entries (architecture decisions, status-based) — Decisions for structure, integration, security, performance, data, DevOps with rationale, alternatives considered, and consequences. No confidence scores; decisions have Status: Proposed/Accepted/Superseded
  • System boundary diagram — Visual representation showing trust boundaries, components, and external integrations
  • RISK-to-Architecture mapping — Validation showing every high-priority RISK-* has corresponding ARC-* mitigation or explicit acceptance
  • Conformance rules (on ARC- entries) — for any decision that makes a structural claim ("X must not depend on Y", "all Z go through one adapter"), a machine-checkable rule. This turns the architecture into the expected topology (the blueprint graph) the v0.7 build is diffed against, and feeds the architecture_conformance readiness dimension. See docs/DEVELOPMENT_GRAPH.md.

All ARC- entries should include:

  • Category: Structure/Integration/Security/Performance/Data/DevOps
  • Context: What prompted this decision (derived from TECH-/RISK-/FEA- inputs)
  • Decision: What was chosen
  • Rationale: Why (not just what)
  • Alternatives Rejected: Options considered and why not chosen
  • Consequences: What this enables and constrains
  • Related IDs: TECH-XXX, RISK-XXX, FEA-XXX references

Example ARC- entry (Structure):

markdown
ARC-001: Monolith with Module Boundaries
Category: Structure
Context: Team of 2 developers; unclear domain boundaries at v0.6; TECH-001 (Next.js) supports monolith pattern
Decision: Single Next.js application with domain-based module folders (auth/, reports/, data-sources/), clear module interfaces

Rationale:
  - TECH-001 (Next.js) designed for monoliths
  - Avoids ops complexity of microservices
  - Can extract services later when scaling needs emerge
  - Enables fast iteration for MVP

Alternatives Rejected:
  - Microservices: Premature (team too small); adds ops burden
  - Serverless: Harder to share code; cold start latency concerns (impacts UJ-001 response time)
  - Layered monolith: Less clear boundaries; module pattern better for future extraction

Consequences:
  - Enables: Fast iteration, simple deployment, shared state across domains
  - Constrains: Single scaling unit (can't scale auth independently); must be disciplined about module boundaries

Related IDs: TECH-001 (Next.js), RISK-005 (scaling concerns), FEA-001..FEA-020 (all features in one deployment)
Status: Accepted

Example ARC- entry (Security, addressing RISK-):

markdown
ARC-005: JWT with HTTP-Only Cookies
Category: Security
Context: Need session management for authenticated users; RISK-008 (security compliance) and TECH-003 (Clerk auth) guide this
Decision: JWTs stored in HTTP-only cookies, 1-hour expiry, refresh via /refresh endpoint

Rationale:
  - HTTP-only prevents XSS token theft (mitigates RISK-008 surface area)
  - Short expiry limits damage window if token stolen
  - Refresh flow handles long sessions gracefully
  - TECH-003 (Clerk) handles token lifecycle, we just enforce storage pattern

Alternatives Rejected:
  - localStorage: Vulnerable to XSS (RISK-008 violation)
  - Long-lived tokens: Increases risk exposure time (RISK-008)
  - Server sessions: Scaling complexity; would require Redis (not in TECH-)

Consequences:
  - Enables: Stateless auth, horizontal scaling
  - Constrains: Must handle refresh flow in frontend; logout requires token invalidation

Related IDs: TECH-003 (Clerk handles token generation), RISK-008 (security compliance), BR-010 (auth requirements)
Status: Accepted

Architecture Decision Categories

CategoryWhat It CoversExample Decisions
StructureComponent organization, boundariesMonolith vs microservices, module structure
IntegrationExternal service connectionsAPI gateway pattern, webhook handlers
SecurityAuth, authorization, data protectionJWT strategy, role-based access
PerformanceScaling, caching, optimizationCDN strategy, database indexing
DataStorage, flow, consistencyEvent sourcing, CQRS, replication
DevOpsDeployment, monitoring, CI/CDContainer orchestration, observability

Design Process

  1. Pull TECH- decisions — What technologies are we building with?
  2. Pull RISK- constraints — What must the architecture account for?
  3. Pull FEA- features — What must the system do?
  4. Define system boundaries — What's in/out of scope?
  5. Map component relationships — How do parts connect?
  6. Document integration patterns — How do Buy/Integrate items connect?
  7. Create ARC- entries — Record decisions with rationale

System Boundary Definition

Before designing components, define what's inside and outside your system:

Inside (Build):

  • Core business logic
  • Differentiating features
  • Custom workflows

Outside (Buy/Integrate):

  • Authentication provider
  • Payment processor
  • Email service
  • Analytics

Boundary Questions:

  • Where does data enter the system?
  • Where does data leave the system?
  • What trust boundaries exist?
  • What must be fast vs. can be eventual?

Component Relationship Patterns

For Build Components

PatternWhen to UseExample
MonolithMVP, small team, unclear boundariesSingle Next.js app
Modular MonolithGrowing codebase, clear domainsModules with defined interfaces
MicroservicesClear boundaries, scaling needsSeparate auth, billing, core services

Rule for MVP: Start monolith, extract services when you have evidence of need.

For Buy/Integrate Components

PatternWhen to UseExample
Direct IntegrationSimple, trusted serviceCall Stripe API directly
Adapter LayerWant to swap providers laterAbstract over auth provider
Event BridgeAsync, decoupledWebhooks → event queue → handlers

Integration Architecture Patterns

Pattern: Vendor Abstraction

When you Buy a service but want flexibility to switch:

┌─────────────────────────────────────┐
│           Your Application          │
├─────────────────────────────────────┤
│       Payment Abstraction Layer     │
│   interface PaymentProvider {       │
│     charge(amount, token): Result   │
│   }                                 │
├─────────────────────────────────────┤
│  StripeAdapter  │  PaddleAdapter    │
└─────────────────┴───────────────────┘

When to use: High switching cost, multiple viable providers, strategic flexibility needed.

Pattern: Webhook Handler

When integrating with external events:

External Service → Webhook Endpoint → Event Queue → Handler
                   Signature Verify
                   Idempotency Check
                   Enqueue for processing

When to use: External services push events (Stripe, GitHub, etc.).

ARC- Output Template

ARC-XXX: [Decision Title]
Category: [Structure | Integration | Security | Performance | Data | DevOps]
Context: [What prompted this decision]
Decision: [What we decided]
Rationale: [Why this choice]

Alternatives Rejected:
  - [Option A]: [Why not]
  - [Option B]: [Why not]

Consequences:
  - Enables: [What this makes possible]
  - Constrains: [What this limits]

Conformance Rule (optional — for structural claims):
  - Rule: [e.g. "engine/ must not import the UI framework"]
  - Check: [type · scope · target, e.g. forbidden_import · engine/** · vscode]
  (verified against the as-built code in v0.7 → architecture_conformance; see docs/DEVELOPMENT_GRAPH.md)

Related IDs: [TECH-XXX, RISK-XXX, FEA-XXX]
Status: [Proposed | Accepted | Superseded]

Example ARC- entry:

ARC-001: Monolith with Module Boundaries
Category: Structure
Context: Need to choose application structure for MVP launch
Decision: Single Next.js application with domain-based module folders

Rationale:
  - Team of 2 developers, single deployment simplifies ops
  - Unclear domain boundaries at this stage
  - Can extract services later when patterns emerge

Alternatives Rejected:
  - Microservices: Premature; adds ops complexity without proven need
  - Serverless functions: Harder to share code, cold start concerns

Consequences:
  - Enables: Fast iteration, simple deployment, shared state
  - Constrains: Single scaling unit, must be disciplined about module boundaries

Related IDs: TECH-001 (Next.js), RISK-005 (scaling concerns)
Status: Accepted

Example ARC- entry (Security):

ARC-005: JWT with HTTP-Only Cookies
Category: Security
Context: Need session management strategy for authenticated users
Decision: JWTs stored in HTTP-only cookies, 1-hour expiry, refresh via /refresh endpoint

Rationale:
  - HTTP-only prevents XSS access to tokens
  - Short expiry limits damage from stolen tokens
  - Refresh flow handles long sessions gracefully

Alternatives Rejected:
  - localStorage: Vulnerable to XSS
  - Long-lived tokens: Security risk if compromised
  - Server-side sessions: Scaling complexity, Redis dependency

Consequences:
  - Enables: Stateless auth, horizontal scaling
  - Constrains: Must handle refresh flow in frontend, logout requires invalidation strategy

Related IDs: TECH-001 (Clerk handles this), RISK-008 (security compliance)
Status: Accepted

System Diagram Elements

When creating architecture diagrams, include:

ElementSymbolPurpose
Service/ComponentBoxInternal services, modules
External SystemCloud/cylinderThird-party services, DBs
Trust BoundaryDashed lineSecurity perimeters
Data FlowArrowHow data moves
Integration PointDiamondWhere systems connect

Example Diagram Structure

┌─────────────────────────────────────────────────────────┐
│                    TRUST BOUNDARY                        │
│  ┌─────────────┐     ┌─────────────┐    ┌────────────┐  │
│  │   Frontend  │────▶│   API       │───▶│  Database  │  │
│  │   (Next.js) │     │  (tRPC)     │    │  (Supabase)│  │
│  └─────────────┘     └──────┬──────┘    └────────────┘  │
│                             │                            │
└─────────────────────────────┼────────────────────────────┘
              ┌───────────────┼───────────────┐
              ▼               ▼               ▼
        ┌──────────┐   ┌──────────┐   ┌──────────┐
        │  Stripe  │   │  Clerk   │   │  Resend  │
        │ (payments)│  │  (auth)  │   │ (email)  │
        └──────────┘   └──────────┘   └──────────┘
                    EXTERNAL SERVICES

RISK- to Architecture Mapping

Every high-priority risk should have an architectural response:

RiskArchitecture Response
RISK-001: API dependency outageARC-010: Add retry + circuit breaker
RISK-003: Data breachARC-005: Encryption at rest + transit
RISK-007: Scaling bottleneckARC-012: Cache layer, read replicas

Anti-Patterns to Avoid

Anti-PatternSignalFix
Architecture astronautOver-engineering for 1000x scaleDesign for 10x current needs
Missing boundariesEverything can call everythingDefine clear interfaces
Ignoring RISK-Architecture doesn't address risksMap each High RISK- to ARC-
Vendor lock-inNo abstraction over critical servicesAdd adapter layer for switching
Diagram without decisionsPretty pictures, no ARC- recordsEvery box needs documented rationale
Premature microservices5 services for MVPStart monolith, extract later

Quality Gates

Before proceeding to Technical Specification:

  • All TECH- Build items have component placement
  • All TECH- Buy/Integrate items have integration pattern
  • High-priority RISK- entries have architectural mitigation
  • Trust boundaries clearly defined
  • Data flow documented
  • ARC- entries created for major decisions

Downstream Connections

ARC- entries feed into:

ConsumerWhat It UsesExample
Technical SpecificationARC- informs API designARC-001 (monolith) → unified API surface
v0.7 Build ExecutionARC- defines EPIC scopeARC-003 (auth module) → EPIC-02
Development Graph (v0.7)ARC- conformance rules become code checksARC-004 (no UI import in engine/) → architecture_conformance verdict
Infrastructure SetupARC- drives deploymentARC-010 (edge caching) → CDN config
Security ReviewSecurity ARC- entriesARC-005 → pen test scope

Detailed References

  • Architecture pattern examples: See references/examples.md
  • ARC- entry template: See assets/arc.md
  • Diagram templates: See references/diagrams.md

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Prd V06 Architecture Design AI skill do?

Define how system components connect, establishing boundaries, patterns, and integration approaches during PRD v0.6 Architecture. Triggers on requests to design architecture, create system design, define component relationships, or when user asks "design architecture", "system design", "how do components connect?", "architecture decisions", "technical architecture", "system overview". Consumes TECH- (stack selections), RISK- (constraints), FEA- (features). Outputs ARC- entries documenting architecture decisions with rationale. Feeds v0.6 Technical Specification.

Why use Prd V06 Architecture Design on TypingMind?

Because you install it once and use it with any model. Prd V06 Architecture Design is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Prd V06 Architecture Design in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/mattgierhart/PRD-driven-context-engineering/tree/main/plugins/prd-ce/skills/prd-v06-architecture-design. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Prd V06 Architecture Design?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Prd V06 Architecture Design?

As many as you like. As long as a model supports skills, you can use Prd V06 Architecture Design with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Prd V06 Architecture Design AI skill free?

Yes. It is published on GitHub by mattgierhart under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇