| name | sync-design-docs |
| description | Update design documentation in the design/ folder to reflect code changes. Use after modifying skill templates, agent templates, CLI code, or architecture. Triggers: /sync-design-docs, 'update design docs', 'sync design documents'. |
| allowed-tools | ["Read","Grep","Glob","Edit","Write"] |
Sync Design Documents
You are updating the developer-facing design documentation in design/
to reflect recent code changes. All design documents MUST be written in Korean.
Step 1: Identify Changed Components
Use Glob and Read to check the current state of:
- Skills โ
src/templates/skills/*/SKILL.md
- Agents โ
src/templates/agents/*.md
- CLI โ
src/commands/*.js, src/utils/*.js, src/index.js
- Config โ
package.json, src/templates/config.json
Step 2: Read Current Design Docs
Read all design documents:
design/architecture.md โ ์ ์ฒด ์ํคํ
์ฒ, CLI ๊ตฌ์กฐ, ์ปดํฌ๋ํธ ๋ชฉ๋ก
design/codeinspector.md โ Code Inspector ์์ธ ์ค๊ณ, ์๋ธ์์ด์ ํธ ์๊ณ ๋ฆฌ์ฆ
design/hacksimulator.md โ Hack Simulator ์์ธ ์ค๊ณ, ์๋ธ์์ด์ ํธ ์๊ณ ๋ฆฌ์ฆ
Step 3: Detect Differences
Compare the design docs against the actual code. Look for:
- New or removed agents/skills
- Changed agent tools or frontmatter fields
- Modified algorithms or step sequences
- New API integrations or tool dependencies
- Changed data flow (report format, config fields, etc.)
- New or removed CLI commands or options
Step 4: Apply Updates
For each discrepancy found, update the relevant design document:
architecture.md should reflect:
- Component inventory table (skills, agents, prefixes, tools)
- CLI flow diagram
- File operations functions
- External API dependencies
- YAML frontmatter examples
codeinspector.md should reflect:
- Sequence diagram (sub-agents launched)
- Each sub-agent's algorithm flowchart
- API request/response examples
- Ecosystem mappings
- CVSS severity mappings
- i18n translation references
- Error handling behavior
hacksimulator.md should reflect:
- Sequence diagram (planner โ approval โ executor)
- Target determination flow
- Intensity levels and their test categories
- Attack planner algorithm
- Attack executor algorithm (passive/active/aggressive)
- Safety mechanisms
- Codeinspector feedback loop
- Comparison table
Step 5: Verify Consistency
After updates, verify:
Step 6: Report Changes
Display a summary of what was updated:
## ์ค๊ณ ๋ฌธ์ ๋๊ธฐํ ์๋ฃ
### ๋ณ๊ฒฝ๋ ํ์ผ
- design/architecture.md โ {๋ณ๊ฒฝ ๋ด์ฉ ์์ฝ}
- design/codeinspector.md โ {๋ณ๊ฒฝ ๋ด์ฉ ์์ฝ}
- design/hacksimulator.md โ {๋ณ๊ฒฝ ๋ด์ฉ ์์ฝ}
### ๋ณ๊ฒฝ ์ฌ์
- {์ฝ๋ ๋ณ๊ฒฝ์ ๋ฐ๋ฅธ ๊ตฌ์ฒด์ ์ด์ }
Rules
- ALL design documents MUST be written in Korean (ํ๊ตญ์ด)
- Technical terms (CVE, XSS, OWASP, CVSS, OSV, API, HTTP, etc.) stay in English
- Mermaid diagram node labels may use English for brevity where needed
- Do NOT change the overall document structure unless necessary
- Keep Mermaid diagrams up-to-date with actual execution flows
- If a new agent or skill was added, add its algorithm section
- If an agent or skill was removed, remove its section