AgentSkillsCN

Check

在实施前全面核查设计文档的完整性。 依据已定义的组件逐一排查遗漏细节,并提示用户及时补全。 触发词:check、verify、validate design、设计验证、验证

SKILL.md
--- frontmatter
id: check
name: Check
description: |
  Verify design document completeness before implementation.
  Identifies missing details based on defined components and asks user to fill gaps.

  Triggers: check, verify, validate design, 설계 검증, 검증
user-invocable: true
version: 1.0.0
triggers:
  - "check"
  - "verify"
  - "validate"
  - "design review"
requires: ["arch"]
platform: all
recommended_model: sonnet
allowed-tools:
  - Read
  - Write
  - Glob
  - LS
  - AskQuestion

Language: This skill is written in English for universal compatibility. Always respond in the user's language unless explicitly requested otherwise. If uncertain about the user's language, ask for clarification.

Architect Review Workflow

Verify design document completeness and identify missing details that will be needed during implementation.

💡 Recommended Model

Sonnet recommended (analysis task) / Opus for complex designs

🔄 Tool Fallback

ToolAlternative when unavailable
ReadRequest file path from user → ask for copy-paste
AskQuestion"Please select: 1) OptionA 2) OptionB 3) OptionC" format

📁 Document Structure

code
projectRoot/
  └── docs/
        └── {serviceName}/
              ├── spec.md  # Input (optional)
              └── arch.md     # Input & Output (updated)

Phase 0: Skill Entry

0-1. Model Recommendation

💡 Sonnet is sufficient for this skill. This is an analysis task, not a creative design task.

0-2. Collect Service Name

Use AskQuestion:

json
{
  "title": "Architect Review",
  "questions": [
    {
      "id": "service_name",
      "prompt": "Which service's design document do you want to review?",
      "options": [
        {"id": "input", "label": "I will type the service name"}
      ]
    }
  ]
}

Or detect from context if user provides file path.

0-3. Load Design Document

Read docs/{serviceName}/arch.md

If not found → Error: "Design document not found. Run /arch first."


Phase 1: Component Detection

Scan the design document and detect which components are defined:

Detection Checklist

ComponentDetection MethodTriggers Additional Checks
Authentication"인증", "auth", "OAuth", "JWT" in documentToken refresh, Session management
DatabaseDB schema tables definedSoft delete, Indexes, Migrations
REST APIAPI endpoints definedPagination, Rate limiting, Versioning
External API callsExternal API list existsRetry policy, Caching, Fallback
Async processingCelery, Queue, Worker mentionedError handling, Retry, DLQ
Real-timeSSE, WebSocket mentionedConnection management, Heartbeat
File storageUpload, S3, file mentionedSize limits, Cleanup policy
CachingRedis, Cache mentionedTTL policy, Invalidation
K8s/DockerDeployment config existsHealth check, Resource limits
LLM/AILLM, OpenAI, Claude mentionedCost control, Token limits

Phase 2: Gap Analysis

For each detected component, check if required details are defined:

Authentication Gaps

Required DetailCheckIf Missing
Token refresh logicIs refresh token flow defined?Ask user
Token expiration timeIs expiry duration specified?Ask user
Session invalidationHow to logout/revoke?Ask user

Database Gaps

Required DetailCheckIf Missing
Soft delete vs Hard deleteIs deletion strategy defined?Ask user
Index strategyAre indexes defined for query patterns?Suggest based on API
Migration strategyIs Alembic/migration mentioned?Suggest

REST API Gaps

Required DetailCheckIf Missing
PaginationIs pagination defined for list APIs?Ask user
Rate limitingIs rate limit policy defined?Ask user
API versioningIs /v1/ or versioning mentioned?Suggest
Request validationIs validation logic defined?Suggest

External API Gaps

Required DetailCheckIf Missing
Retry policyIs retry count/backoff defined?Ask user
Caching strategyIs response caching defined?Ask user
Fallback behaviorWhat if external API fails?Ask user
Timeout settingsIs timeout defined?Suggest default

Async Processing Gaps

Required DetailCheckIf Missing
Error handlingWhat if task fails?Ask user
Retry policyIs retry count defined?Ask user
Dead letter queueIs DLQ/failed task handling defined?Suggest
IdempotencyCan task be safely retried?Ask user

Real-time Gaps

Required DetailCheckIf Missing
Connection timeoutIs SSE/WS timeout defined?Suggest default
Reconnection logicClient reconnection strategy?Suggest
HeartbeatIs keep-alive mechanism defined?Suggest

Infrastructure Gaps

Required DetailCheckIf Missing
Health check endpointIs /health or probe defined?Suggest
Liveness/ReadinessAre K8s probes defined?Suggest if K8s
Graceful shutdownIs shutdown handling defined?Suggest
Logging strategyIs log format/level defined?Ask user
MonitoringIs metrics/alerting defined?Ask user

LLM/AI Gaps

Required DetailCheckIf Missing
Cost trackingIs token/cost logging defined?Suggest
Usage limitsIs per-user limit defined?Already in doc?
Fallback modelWhat if primary model fails?Ask user
Prompt versioningIs prompt management defined?Suggest

Phase 3: Q&A Loop

For each gap found, ask user to fill:

Use AskQuestion for choices:

json
{
  "title": "Missing Detail: Token Refresh",
  "questions": [
    {
      "id": "token_refresh",
      "prompt": "Token refresh logic is not defined. How should expired tokens be handled?",
      "options": [
        {"id": "refresh_token", "label": "Use refresh token (recommended)"},
        {"id": "re_login", "label": "Require re-login"},
        {"id": "long_expiry", "label": "Use long expiry (24h+)"},
        {"id": "skip", "label": "Skip for now (decide during implementation)"}
      ]
    }
  ]
}

For open-ended questions:

"Pagination is not defined for list APIs. What should be the default page size?"

Suggested: 20 items per page, max 100

Skip Handling

If user selects "Skip for now":

  • Mark as ⚠️ TBD in document
  • Continue to next gap
  • List all skipped items at the end

Phase 4: Document Update

Update docs/{serviceName}/arch.md with filled gaps.

Update Location

Add new section or update existing sections:

markdown
## 12. Additional Design Details (from Review)

### Authentication Details
- Token expiration: 1 hour
- Refresh token expiration: 7 days
- Refresh flow: POST /api/v1/auth/refresh with refresh_token

### API Details
- Pagination: 20 items default, 100 max
- Rate limiting: 100 requests/minute per user

### Infrastructure Details
- Health check: GET /health (returns 200 OK)
- Graceful shutdown: 30 second timeout

### ⚠️ TBD (Skipped)
- Monitoring strategy
- Log aggregation

Sync History Update

Add to Sync History section:

markdown
| {date} | review | check | 설계 완성도 검증 - {N}개 항목 추가 |

Phase 5: Summary Report

Present review summary to user:

markdown
## Architect Review Complete

### Components Detected
- ✅ Authentication (Google OAuth + JWT)
- ✅ Database (PostgreSQL, 10 tables)
- ✅ REST API (15 endpoints)
- ✅ Async Processing (Celery)
- ✅ Real-time (SSE)
- ✅ External APIs (4 services)
- ✅ LLM (OpenAI GPT-4)

### Gaps Filled: 8
| Item | Decision |
|------|----------|
| Token refresh | Use refresh token |
| Pagination | 20 items default |
| Health check | GET /health added |
| ... | ... |

### Skipped (TBD): 2
- Monitoring strategy
- Log aggregation

### Document Updated
`docs/{serviceName}/arch.md` - 12. Additional Design Details section added

### Next Step
Run `/build` to start implementation.

Completion Message

Architect Review Complete

Output: docs/{serviceName}/arch.md (updated)

  • Gaps filled: {N}
  • Skipped (TBD): {M}

Next Step: Run /build to start implementation.


Review Checklist Reference

Quick reference for common gaps by component:

ComponentCommon Gaps
AuthToken refresh, Session timeout, Logout flow
DBSoft delete, Indexes, Cascade rules
APIPagination, Rate limit, Versioning, Validation
External APIRetry, Cache, Timeout, Fallback
AsyncError handling, Retry, DLQ, Idempotency
Real-timeTimeout, Reconnect, Heartbeat
InfraHealth check, Probes, Graceful shutdown, Logging
LLMCost tracking, Limits, Fallback, Prompt versioning