@votruongdanh/ai-agent-skills 3.3.4 → 3.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (76) hide show
  1. package/.agents/.skills-version +1 -1
  2. package/.agents/skills/agents/SKILL.md +1 -0
  3. package/.agents/skills/brainstorm/SKILL.md +1 -0
  4. package/.agents/skills/clean/SKILL.md +1 -0
  5. package/.agents/skills/create/SKILL.md +1 -0
  6. package/.agents/skills/debug/SKILL.md +1 -0
  7. package/.agents/skills/deploy/SKILL.md +1 -0
  8. package/.agents/skills/enhance/SKILL.md +1 -0
  9. package/.agents/skills/explain/SKILL.md +2 -0
  10. package/.agents/skills/integrate/SKILL.md +1 -0
  11. package/.agents/skills/motion-ui/SKILL.md +1 -0
  12. package/.agents/skills/orchestrate/SKILL.md +1 -0
  13. package/.agents/skills/plan/SKILL.md +1 -0
  14. package/.agents/skills/preview/SKILL.md +1 -0
  15. package/.agents/skills/status/SKILL.md +1 -0
  16. package/.agents/skills/test/SKILL.md +1 -0
  17. package/.agents/skills/ui-ux-pro-max/SKILL.md +1 -0
  18. package/.kiro/.skills-version +1 -1
  19. package/.kiro/skills/_scripts/.ai-memory-template.md +55 -0
  20. package/.kiro/skills/_scripts/checklist.md +35 -0
  21. package/.kiro/skills/_scripts/memory-compact.md +142 -0
  22. package/.kiro/skills/_scripts/memory-dedupe.md +26 -0
  23. package/.kiro/skills/_scripts/pre-deploy.md +42 -0
  24. package/.kiro/skills/_scripts/verify-all.md +28 -0
  25. package/.kiro/skills/agents/SKILL.md +89 -0
  26. package/.kiro/skills/agents/agents/backend-specialist.md +29 -0
  27. package/.kiro/skills/agents/agents/database-architect.md +28 -0
  28. package/.kiro/skills/agents/agents/debugger.md +29 -0
  29. package/.kiro/skills/agents/agents/devops-engineer.md +30 -0
  30. package/.kiro/skills/agents/agents/documentation-writer.md +29 -0
  31. package/.kiro/skills/agents/agents/frontend-specialist.md +30 -0
  32. package/.kiro/skills/agents/agents/orchestrator.md +36 -0
  33. package/.kiro/skills/agents/agents/performance-optimizer.md +29 -0
  34. package/.kiro/skills/agents/agents/project-planner.md +30 -0
  35. package/.kiro/skills/agents/agents/security-auditor.md +30 -0
  36. package/.kiro/skills/agents/agents/test-engineer.md +29 -0
  37. package/.kiro/skills/brainstorm/SKILL.md +70 -0
  38. package/.kiro/skills/clean/SKILL.md +94 -0
  39. package/.kiro/skills/create/SKILL.md +67 -0
  40. package/.kiro/skills/debug/SKILL.md +78 -0
  41. package/.kiro/skills/deploy/SKILL.md +70 -0
  42. package/.kiro/skills/enhance/SKILL.md +62 -0
  43. package/.kiro/skills/explain/SKILL.md +74 -0
  44. package/.kiro/skills/instructions.md +95 -0
  45. package/.kiro/skills/integrate/SKILL.md +54 -0
  46. package/.kiro/skills/motion-ui/SKILL.md +496 -0
  47. package/.kiro/skills/orchestrate/SKILL.md +77 -0
  48. package/.kiro/skills/plan/SKILL.md +73 -0
  49. package/.kiro/skills/preview/SKILL.md +59 -0
  50. package/.kiro/skills/status/SKILL.md +61 -0
  51. package/.kiro/skills/test/SKILL.md +62 -0
  52. package/.kiro/skills/ui-ux-pro-max/SKILL.md +69 -0
  53. package/README.md +9 -6
  54. package/bin/cli.js +11 -12
  55. package/lib/skill-bundle.js +38 -4
  56. package/package.json +4 -2
  57. package/scripts/check_workflows.js +17 -0
  58. package/scripts/render-targets.js +2 -2
  59. package/scripts/sync-all.js +7 -4
  60. package/skills/agents/SKILL.md +4 -0
  61. package/skills/brainstorm/SKILL.md +4 -0
  62. package/skills/clean/SKILL.md +4 -0
  63. package/skills/create/SKILL.md +4 -0
  64. package/skills/debug/SKILL.md +4 -0
  65. package/skills/deploy/SKILL.md +4 -0
  66. package/skills/enhance/SKILL.md +4 -0
  67. package/skills/explain/SKILL.md +2 -0
  68. package/skills/instructions.md +2 -0
  69. package/skills/integrate/SKILL.md +4 -0
  70. package/skills/motion-ui/SKILL.md +4 -0
  71. package/skills/orchestrate/SKILL.md +4 -0
  72. package/skills/plan/SKILL.md +4 -0
  73. package/skills/preview/SKILL.md +4 -0
  74. package/skills/status/SKILL.md +4 -0
  75. package/skills/test/SKILL.md +4 -0
  76. package/skills/ui-ux-pro-max/SKILL.md +4 -0
@@ -1 +1 @@
1
- 3.3.3
1
+ 3.4.0
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: agents
3
3
  description: "Agent routing system — automatically selects the best specialist agent based on user request domain. Handles keyword matching, Vietnamese and English triggers, compound-keyword routing, vague-request fallback, and multi-agent coordination. This skill is always loaded silently."
4
+ encoding: "UTF-8"
4
5
  metadata:
5
6
  category: system
6
7
  auto-load: true
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: brainstorm
3
3
  description: "Ideation, option generation, and feature exploration. Use when the user wants to brainstorm ideas, explore options, compare approaches, or generate creative solutions. Triggers: brainstorm, ideate, options, ý tưởng, so sánh phương án."
4
+ encoding: "UTF-8"
4
5
  agents: [project-planner, orchestrator]
5
6
  related-skills: [plan, create, orchestrate]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: clean
3
3
  description: "Clean up junk files, temporary files, AI-generated artifacts, and caches. Use when the user wants to remove unused files, reduce repo clutter, or update .gitignore. Triggers: clean, remove junk, dọn dẹp, xoá file rác, cache."
4
+ encoding: "UTF-8"
4
5
  agents: [devops-engineer]
5
6
  related-skills: [status, enhance]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: create
3
3
  description: "Build new features, files, components, endpoints, pages, or scripts. Use when the user wants to create something new in the codebase. Triggers: create, build, add, new, scaffold, tạo, thêm mới, tạo trang, tạo API."
4
+ encoding: "UTF-8"
4
5
  agents: [backend-specialist, frontend-specialist, database-architect]
5
6
  related-skills: [plan, test, debug]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: debug
3
3
  description: "Root-cause analysis for bugs, failing commands, broken behavior, and error logs. Use when the user encounters errors, crashes, or unexpected behavior. Triggers: debug, fix, bug, error, crash, lỗi, sửa lỗi, hỏng, fail."
4
+ encoding: "UTF-8"
4
5
  agents: [debugger, backend-specialist, frontend-specialist]
5
6
  related-skills: [test, enhance, status]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: deploy
3
3
  description: "Deployment steps, release preparation, environment setup, CI/CD guidance, and production rollout. Use when the user wants to deploy, release, or set up infrastructure. Triggers: deploy, release, CI/CD, docker, production, triển khai, phát hành, đưa lên production."
4
+ encoding: "UTF-8"
4
5
  agents: [devops-engineer, security-auditor]
5
6
  related-skills: [test, status, plan]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: enhance
3
3
  description: "Improve existing code — refactor, optimize performance, tighten security, or enhance UX. Use when the user wants to make code better without changing its purpose. Triggers: enhance, improve, refactor, optimize, review, cải thiện, tối ưu, nhanh hơn, code dài quá."
4
+ encoding: "UTF-8"
4
5
  agents: [performance-optimizer, security-auditor, frontend-specialist]
5
6
  related-skills: [debug, test, plan]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: explain
3
3
  description: "Explain code, walk through logic, and help understand architecture or behavior. Use when the user asks what code does, how something works, or wants a walkthrough. Triggers: explain, what does this do, how does this work, giải thích, giải thích code, code này làm gì."
4
+ encoding: "UTF-8"
4
5
  agents: [documentation-writer, backend-specialist, frontend-specialist]
5
6
  related-skills: [debug, enhance, status]
6
7
  ---
@@ -65,6 +66,7 @@ If any answer is unclear, ASK before proceeding.
65
66
  - If the code is unclear or has issues, mention them without derailing the explanation.
66
67
  - Avoid proposing wide changes mid-explanation; if improvement requires broader edits, ASK before switching to implementation.
67
68
  - Always read and update the memory file.
69
+ - Code encoding: All code snippets and files referenced or produced must be UTF-8 encoded. When providing example files, ensure they use UTF-8 and indicate `encoding: "UTF-8"` in front-matter where applicable.
68
70
 
69
71
  ## Related Skills
70
72
  - `/debug` → read `.kiro/skills/debug/SKILL.md` — If explanation reveals bugs
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: integrate
3
3
  description: "Integrate provided sample code/snippets into the existing system with minimal changes and minimal risk. Use when the user gives a code mẫu and wants to merge it into current project. Triggers: integrate, merge snippet, gộp code mẫu, ghép code, áp code mẫu vào hệ thống."
4
+ encoding: "UTF-8"
4
5
  agents: [backend-specialist, frontend-specialist, debugger]
5
6
  related-skills: [plan, test, debug, enhance]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: motion-ui
3
3
  description: "Advanced Motion UI (AMUI) — Create clean, modern UI with subtle Framer Motion micro-interactions, clear states (idle/loading/success/error), consistent styling via design tokens, and smooth animations. Use when the user wants motion-rich, polished UI with micro-interactions. Triggers: motion, animation, framer motion, micro-interaction, smooth ui, amui, chuyển động, hiệu ứng mượt."
4
+ encoding: "UTF-8"
4
5
  agents: [frontend-specialist]
5
6
  related-skills: [create, ui-ux-pro-max, enhance]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: orchestrate
3
3
  description: "Coordinate multi-step plans across multiple roles, files, systems, or parallel workstreams. Use when the user has a complex request spanning multiple domains or needing decomposition. Triggers: orchestrate, coordinate, multi-step, full-stack, tổng hợp, làm nhiều bước."
4
+ encoding: "UTF-8"
4
5
  agents: [orchestrator, project-planner]
5
6
  related-skills: [plan, create, deploy, test]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: plan
3
3
  description: "Create concrete implementation plans with milestones, task breakdowns, and estimates. Use when the user wants to plan, organize work, or create a roadmap. Triggers: plan, milestone, breakdown, roadmap, estimate, kế hoạch, lên kế hoạch, phân chia công việc."
4
+ encoding: "UTF-8"
4
5
  agents: [project-planner, orchestrator]
5
6
  related-skills: [brainstorm, create, orchestrate]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: preview
3
3
  description: "Preview expected output, UX flows, copy, interaction design, or generated content before implementing. Use when the user wants to see what something will look like. Triggers: preview, mockup, show me, xem trước, thử xem, mô phỏng."
4
+ encoding: "UTF-8"
4
5
  agents: [frontend-specialist, documentation-writer]
5
6
  related-skills: [create, ui-ux-pro-max, plan]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: status
3
3
  description: "Project status summary, progress snapshots, repo overview, and outstanding work tracking. Use when the user wants to know where a project stands. Triggers: status, progress, overview, what's done, dự án đang ở đâu, tiến độ, tổng quan."
4
+ encoding: "UTF-8"
4
5
  agents: [project-planner, orchestrator]
5
6
  related-skills: [plan, debug, deploy]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: test
3
3
  description: "Write tests, improve coverage, define test strategy, and add validation. Use when the user wants to test code, add unit/integration/e2e tests, or check coverage. Triggers: test, coverage, jest, vitest, playwright, spec, kiểm thử, viết test."
4
+ encoding: "UTF-8"
4
5
  agents: [test-engineer, debugger]
5
6
  related-skills: [debug, create, enhance]
6
7
  ---
@@ -1,6 +1,7 @@
1
1
  ---
2
2
  name: ui-ux-pro-max
3
3
  description: "Advanced UI/UX improvements — layout, design critique, copy refinement, interaction design, accessibility, and responsive patterns. Use when the user wants professional-grade UI/UX upgrades. Triggers: ui, ux, design, layout, responsive, giao diện, thiết kế, cải thiện UI."
4
+ encoding: "UTF-8"
4
5
  agents: [frontend-specialist, performance-optimizer]
5
6
  related-skills: [create, preview, enhance]
6
7
  ---
@@ -1 +1 @@
1
- 3.3.3
1
+ 3.4.0
@@ -0,0 +1,55 @@
1
+ # Project Memory
2
+
3
+ > This file is automatically maintained by AI Agent Skills.
4
+ > It persists project understanding across conversations.
5
+ > **Do NOT delete this file** — it helps AI give better, context-aware responses.
6
+
7
+ ## Codex Memory Structure (when available)
8
+ - If the workspace has `memories/`, use it alongside this file.
9
+ - `memories/` = persistent user-level notes.
10
+ - `memories/session/` = temporary notes for current conversation.
11
+ - `memories/repo/` = repository-scoped technical facts and conventions.
12
+ - Keep `.ai-memory.md` as the cross-IDE source of truth; mirror only high-signal repo facts into `memories/repo/`.
13
+
14
+ ## Memory Compaction Rules (IMPORTANT)
15
+ - **Write style**: concise bullets, no paragraphs. Prefer numbers, filenames, and nouns over prose.
16
+ - **No duplication**: if a new note repeats an existing one, update the existing bullet instead of appending.
17
+ - **Deduping rule (anti-duplicate)**:
18
+ - Before writing, **scan the target section** for a similar bullet.
19
+ - Consider bullets “similar” if they match after: lowercasing + trimming + collapsing whitespace + removing trailing punctuation.
20
+ - If similar: **merge into 1 bullet** (keep the most specific wording, add missing file paths/IDs).
21
+ - Never keep 2 bullets that describe the same decision/issue/work item.
22
+ - **Hard limits**:
23
+ - Tech Stack: max 6 bullets
24
+ - Architecture: max 8 bullets
25
+ - Conventions: max 8 bullets
26
+ - Decisions: keep last 12 items
27
+ - Known Issues: keep last 20 items (closed issues can be removed once stable)
28
+ - Recent Work: keep last 15 items
29
+ - **Per bullet**: aim ≤ 140 characters. If longer, split into 2 bullets.
30
+ - **Always include**: files touched (paths), and why (1 short phrase).
31
+
32
+ ## Tech Stack
33
+ - Language: (auto-detected on first use)
34
+ - Framework: (auto-detected on first use)
35
+ - Database: (if any)
36
+ - Package manager: (auto-detected)
37
+
38
+ ## Architecture
39
+ - Pattern: (discovered)
40
+ - Key directories: (discovered)
41
+ - Entry points: (discovered)
42
+
43
+ ## Conventions
44
+ - Naming: (observed from codebase)
45
+ - File structure: (observed)
46
+ - Testing: (framework + patterns observed)
47
+
48
+ ## Decisions
49
+ <!-- Format: - [YYYY-MM-DD] Decision description and rationale -->
50
+
51
+ ## Known Issues
52
+ <!-- Format: - [status] Issue description -->
53
+
54
+ ## Recent Work
55
+ <!-- Format: - [YYYY-MM-DD] What was done, files changed, outcome -->
@@ -0,0 +1,35 @@
1
+ ---
2
+ name: checklist
3
+ description: Reusable pre/post checklists for any skill execution
4
+ ---
5
+
6
+ ## Pre-Execution Checklist (Run before ANY skill)
7
+ - [ ] Read `.ai-memory.md` from project root
8
+ - [ ] Understand user intent (ask if unclear)
9
+ - [ ] Check if similar work was done before (from memory)
10
+ - [ ] Identify the correct agent for the domain
11
+ - [ ] Minimize blast radius: identify the smallest set of files that must change
12
+ - [ ] If any step is uncertain or could cause broad changes, ask before editing
13
+
14
+ ## Post-Execution Checklist (Run after ANY skill)
15
+ - [ ] All checklist items from the skill are satisfied
16
+ - [ ] No regressions introduced
17
+ - [ ] Code follows existing project conventions
18
+ - [ ] Update `.ai-memory.md` with findings (follow "Memory Compaction Rules")
19
+ - [ ] Dedupe `.ai-memory.md` updates: merge similar bullets instead of appending duplicates
20
+ - [ ] If `.ai-memory.md` exceeds 500 lines or sections exceed limits, compact it (see `.kiro/skills/_scripts/memory-compact.md`)
21
+ - [ ] Suggest related next steps
22
+
23
+ ## Code Quality Checklist
24
+ - [ ] No hardcoded secrets or credentials
25
+ - [ ] Error handling at system boundaries
26
+ - [ ] Input validation for user-facing code
27
+ - [ ] Existing tests still pass
28
+ - [ ] New code is covered by tests (if test framework exists)
29
+
30
+ ## Security Checklist
31
+ - [ ] No SQL injection vectors
32
+ - [ ] No XSS vulnerabilities
33
+ - [ ] No exposed secrets in code or logs
34
+ - [ ] Dependencies are up to date
35
+ - [ ] Access controls are appropriate
@@ -0,0 +1,142 @@
1
+ ---
2
+ name: memory-compact
3
+ description: Procedure to compact `.ai-memory.md` when it grows too long
4
+ ---
5
+
6
+ ## When to compact
7
+ Run this procedure when `.ai-memory.md` exceeds **500 lines** or when you notice:
8
+ - Duplicate or near-duplicate bullets
9
+ - Outdated information (old decisions, resolved issues, ancient work items)
10
+ - Verbose bullets that could be shortened
11
+ - Sections exceeding their hard limits (see Memory Compaction Rules)
12
+
13
+ ## Compaction procedure
14
+
15
+ ### 1. Check section limits (from `.ai-memory-template.md`)
16
+ - **Tech Stack**: max 6 bullets
17
+ - **Architecture**: max 8 bullets
18
+ - **Conventions**: max 8 bullets
19
+ - **Decisions**: keep last 12 items
20
+ - **Known Issues**: keep last 20 items (remove resolved/closed)
21
+ - **Recent Work**: keep last 15 items
22
+
23
+ ### 2. Dedupe within each section
24
+ For each section:
25
+ 1. Read all bullets
26
+ 2. Group similar bullets (same topic, same file, same decision)
27
+ 3. Merge groups into single bullets:
28
+ - Keep most specific wording
29
+ - Preserve all file paths, dates, IDs
30
+ - Remove redundant phrases
31
+
32
+ **Example:**
33
+ ```markdown
34
+ Before:
35
+ - [2024-01-15] Added auth middleware to protect routes
36
+ - [2024-01-16] Implemented authentication middleware in src/middleware/auth.js
37
+ - Auth middleware added for route protection
38
+
39
+ After:
40
+ - [2024-01-15] Added auth middleware (src/middleware/auth.js) to protect routes
41
+ ```
42
+
43
+ ### 3. Remove outdated items
44
+ - **Decisions**: Keep only decisions still relevant to current architecture
45
+ - **Known Issues**: Remove resolved/closed issues older than 30 days
46
+ - **Recent Work**: Keep only last 15 items (remove older)
47
+
48
+ ### 4. Shorten verbose bullets
49
+ Target: ≤ 140 characters per bullet
50
+
51
+ **Techniques:**
52
+ - Remove filler words: "basically", "essentially", "in order to"
53
+ - Use abbreviations: "impl" for "implemented", "cfg" for "config"
54
+ - Use file paths instead of descriptions: `src/auth.js` not "the authentication file"
55
+ - Use symbols: `+` for "added", `~` for "updated", `-` for "removed"
56
+
57
+ **Example:**
58
+ ```markdown
59
+ Before:
60
+ - [2024-01-15] We implemented a new authentication system that uses JWT tokens for user sessions in the backend API
61
+
62
+ After:
63
+ - [2024-01-15] + JWT auth system (src/api/auth.js) for user sessions
64
+ ```
65
+
66
+ ### 5. Enforce hard limits
67
+ If a section still exceeds limits after deduping and shortening:
68
+ - **Decisions**: Keep last 12, archive older ones in a comment
69
+ - **Known Issues**: Keep last 20, remove oldest resolved
70
+ - **Recent Work**: Keep last 15, remove oldest
71
+
72
+ **Archive pattern:**
73
+ ```markdown
74
+ ## Decisions
75
+ - [2024-03-01] Current decision 1
76
+ - [2024-02-28] Current decision 2
77
+ ...
78
+
79
+ <!-- Archived decisions (for reference):
80
+ - [2024-01-15] Old decision that's no longer relevant
81
+ -->
82
+ ```
83
+
84
+ ### 6. Verify compaction
85
+ After compacting:
86
+ - [ ] No section exceeds hard limits
87
+ - [ ] No duplicate bullets
88
+ - [ ] All bullets ≤ 140 characters (or split into 2)
89
+ - [ ] File paths preserved
90
+ - [ ] Dates preserved
91
+ - [ ] Recent/important info retained
92
+
93
+ ## Quick compaction (when in a hurry)
94
+ If you need to compact quickly:
95
+ 1. **Recent Work**: Keep last 15, delete rest
96
+ 2. **Known Issues**: Remove all resolved/closed, keep last 20
97
+ 3. **Decisions**: Keep last 12
98
+ 4. Run dedupe on remaining bullets (merge similar ones)
99
+
100
+ ## Automation tip
101
+ When updating memory, always:
102
+ 1. Check if section is at limit BEFORE adding
103
+ 2. If at limit, remove oldest item OR merge with existing
104
+ 3. Never append if it creates a duplicate
105
+
106
+ ## Example: Full compaction
107
+
108
+ **Before (verbose, duplicates, over limits):**
109
+ ```markdown
110
+ ## Recent Work
111
+ - [2024-01-10] Added login page
112
+ - [2024-01-11] Created login component
113
+ - [2024-01-12] Implemented login functionality
114
+ - [2024-01-13] Fixed login bug
115
+ - [2024-01-14] Updated login styles
116
+ - [2024-01-15] Added logout button
117
+ - [2024-01-16] Implemented logout functionality
118
+ - [2024-01-17] Fixed logout bug
119
+ - [2024-01-18] Added user profile page
120
+ - [2024-01-19] Created user profile component
121
+ - [2024-01-20] Implemented profile edit
122
+ - [2024-01-21] Fixed profile bug
123
+ - [2024-01-22] Added settings page
124
+ - [2024-01-23] Created settings component
125
+ - [2024-01-24] Implemented settings save
126
+ - [2024-01-25] Fixed settings bug
127
+ - [2024-01-26] Added dashboard
128
+ - [2024-01-27] Created dashboard component
129
+ ```
130
+
131
+ **After (compact, deduped, within limits):**
132
+ ```markdown
133
+ ## Recent Work
134
+ - [2024-01-27] + Dashboard (src/pages/Dashboard.jsx)
135
+ - [2024-01-26] + Settings page (src/pages/Settings.jsx) with save functionality
136
+ - [2024-01-22] + User profile page (src/pages/Profile.jsx) with edit feature
137
+ - [2024-01-15] + Login/logout (src/pages/Login.jsx, src/components/LogoutBtn.jsx)
138
+ ```
139
+
140
+ ## Related
141
+ - Read `.kiro/skills/_scripts/.ai-memory-template.md` for Memory Compaction Rules
142
+ - Read `.kiro/skills/_scripts/memory-dedupe.md` for dedupe procedure
@@ -0,0 +1,26 @@
1
+ ---
2
+ name: memory-dedupe
3
+ description: Lightweight dedupe procedure for `.ai-memory.md` updates
4
+ ---
5
+
6
+ ## When to use
7
+ Run mentally for every memory update, especially when adding items to **Decisions**, **Known Issues**, or **Recent Work**.
8
+
9
+ ## Dedupe procedure (fast)
10
+ 1. Pick the **target section** (Decisions / Known Issues / Recent Work / etc.).
11
+ 2. Before adding a new bullet, scan existing bullets for a near-match.
12
+ 3. Normalize both bullets and compare:
13
+ - lowercase
14
+ - trim
15
+ - collapse whitespace
16
+ - remove trailing punctuation (`.`, `;`, `,`)
17
+ 4. If it’s the same idea:
18
+ - **merge** into the existing bullet
19
+ - keep the most concrete version (file paths, error codes, IDs, dates)
20
+ - remove the redundant one
21
+ 5. Only append a new bullet if it’s clearly a new fact/event/decision.
22
+
23
+ ## Examples
24
+ - Two bullets both say “Added auth middleware” → keep one, add the specific files touched.
25
+ - “Fix login bug” and “Fixed login issue” → merge into one with the root cause or PR/files.
26
+
@@ -0,0 +1,42 @@
1
+ ---
2
+ name: pre-deploy
3
+ description: Pre-deployment verification checklist
4
+ ---
5
+
6
+ ## Pre-Deploy Checklist
7
+
8
+ ### Code Readiness
9
+ - [ ] All tests pass
10
+ - [ ] No lint errors
11
+ - [ ] Build succeeds
12
+ - [ ] No TODO/FIXME in critical paths
13
+ - [ ] Version number updated (package.json, CHANGELOG)
14
+
15
+ ### Security
16
+ - [ ] No secrets in source code
17
+ - [ ] Environment variables documented
18
+ - [ ] Dependencies audited (`npm audit`)
19
+ - [ ] No known critical vulnerabilities
20
+
21
+ ### Configuration
22
+ - [ ] Environment config is correct for target
23
+ - [ ] Database migrations are ready (if applicable)
24
+ - [ ] API keys and secrets are in environment, not code
25
+ - [ ] Feature flags set appropriately
26
+
27
+ ### Documentation
28
+ - [ ] CHANGELOG updated
29
+ - [ ] README reflects current state
30
+ - [ ] API docs updated (if applicable)
31
+ - [ ] Deployment instructions are current
32
+
33
+ ### Rollback Plan
34
+ - [ ] Previous version tagged
35
+ - [ ] Rollback procedure documented
36
+ - [ ] Database rollback scripts ready (if applicable)
37
+ - [ ] Monitoring alerts configured
38
+
39
+ ## After Deploy
40
+ - [ ] Smoke tests pass
41
+ - [ ] Monitoring shows healthy metrics
42
+ - [ ] Update `.ai-memory.md` with deploy details
@@ -0,0 +1,28 @@
1
+ ---
2
+ name: verify-all
3
+ description: Full verification pass — run all checks across the project
4
+ ---
5
+
6
+ ## Steps
7
+ 1. **Read Memory** — Load `.ai-memory.md` for known issues
8
+ 2. **Structure Check** — Verify project structure matches expectations
9
+ 3. **Dependency Check** — Are all dependencies installed and up to date?
10
+ 4. **Lint/Format Check** — Does code pass linting and formatting rules?
11
+ 5. **Test Check** — Do all existing tests pass?
12
+ 6. **Build Check** — Does the project build successfully?
13
+ 7. **Security Check** — Run security audit (npm audit, etc.)
14
+ 8. **Documentation Check** — Are README and docs up to date?
15
+ 9. **Git Check** — Any uncommitted changes? Branch is clean?
16
+ 10. **Report** — Summarize findings with pass/fail for each check
17
+
18
+ ## Output Format
19
+ ```
20
+ ✅ Structure — OK
21
+ ✅ Dependencies — OK
22
+ ⚠️ Lint — 3 warnings
23
+ ❌ Tests — 1 failure in test/auth.test.js
24
+ ✅ Build — OK
25
+ ⚠️ Security — 2 moderate vulnerabilities
26
+ ✅ Docs — OK
27
+ ✅ Git — Clean
28
+ ```
@@ -0,0 +1,89 @@
1
+ ---
2
+ name: agents
3
+ description: "Agent routing system — automatically selects the best specialist agent based on user request domain. Handles keyword matching, Vietnamese and English triggers, compound-keyword routing, vague-request fallback, and multi-agent coordination. This skill is always loaded silently."
4
+ encoding: "UTF-8"
5
+ metadata:
6
+ category: system
7
+ auto-load: true
8
+ ---
9
+
10
+ ## Purpose
11
+ This is the master agent routing skill. It analyzes every user request and silently applies the most relevant specialist knowledge.
12
+
13
+ ## Memory Protocol
14
+ **START**: Read `.ai-memory.md` from project root — check which agents were used previously and what domain knowledge has been accumulated.
15
+ **END**: Update `.ai-memory.md` using **Memory Compaction Rules** with which agent was applied and why.
16
+
17
+ ## Agent Selection Matrix
18
+
19
+ | Domain | Primary Agent | Agent File | Trigger Keywords | Skill Files to Load |
20
+ |--------|--------------|-----------|------------------|---------------------|
21
+ | Bug/Error analysis | @debugger | `.kiro/skills/agents/agents/debugger.md` | debug, lỗi, error, bug, crash, 500, exception, fail, fix, sửa, hỏng, lỗi rồi | `.kiro/skills/debug/SKILL.md`, `.kiro/skills/test/SKILL.md` |
22
+ | API/Backend | @backend-specialist | `.kiro/skills/agents/agents/backend-specialist.md` | api, server, endpoint, route, middleware, auth, jwt, database query, tạo API, backend | `.kiro/skills/create/SKILL.md`, `.kiro/skills/deploy/SKILL.md` |
23
+ | UI/Frontend | @frontend-specialist | `.kiro/skills/agents/agents/frontend-specialist.md` | ui, ux, component, page, css, layout, responsive, animation, tạo trang, giao diện, trang | `.kiro/skills/create/SKILL.md`, `.kiro/skills/ui-ux-pro-max/SKILL.md` |
24
+ | Database | @database-architect | `.kiro/skills/agents/agents/database-architect.md` | database, schema, migration, query, sql, prisma, orm, model, cơ sở dữ liệu | `.kiro/skills/create/SKILL.md`, `.kiro/skills/deploy/SKILL.md` |
25
+ | Security | @security-auditor | `.kiro/skills/agents/agents/security-auditor.md` | security, vulnerability, xss, csrf, injection, auth, encrypt, ssl, bảo mật | `.kiro/skills/debug/SKILL.md`, `.kiro/skills/test/SKILL.md` |
26
+ | DevOps/Deploy | @devops-engineer | `.kiro/skills/agents/agents/devops-engineer.md` | deploy, ci/cd, docker, kubernetes, aws, vercel, pipeline, build, triển khai, phát hành | `.kiro/skills/deploy/SKILL.md` |
27
+ | Testing | @test-engineer | `.kiro/skills/agents/agents/test-engineer.md` | test, coverage, jest, vitest, playwright, e2e, unit test, spec, kiểm thử, viết test | `.kiro/skills/test/SKILL.md` |
28
+ | Performance | @performance-optimizer | `.kiro/skills/agents/agents/performance-optimizer.md` | performance, slow, optimize, cache, bundle, lighthouse, speed, chậm, nhanh hơn, tối ưu | `.kiro/skills/enhance/SKILL.md` |
29
+ | Documentation | @documentation-writer | `.kiro/skills/agents/agents/documentation-writer.md` | docs, readme, api docs, changelog, comment, jsdoc, tài liệu | `.kiro/skills/create/SKILL.md` |
30
+ | Code Explanation | @documentation-writer | `.kiro/skills/agents/agents/documentation-writer.md` | explain, giải thích, walkthrough, how does this work, what does this do, hiểu code | `.kiro/skills/explain/SKILL.md` |
31
+ | Planning/Multi-domain | @orchestrator | `.kiro/skills/agents/agents/orchestrator.md` | orchestrate, coordinate, full-stack, multi-step, complex, tổng hợp | `.kiro/skills/orchestrate/SKILL.md`, `.kiro/skills/plan/SKILL.md` |
32
+ | Project planning | @project-planner | `.kiro/skills/agents/agents/project-planner.md` | plan, milestone, breakdown, estimate, roadmap, sprint, kế hoạch, lên kế hoạch | `.kiro/skills/plan/SKILL.md`, `.kiro/skills/brainstorm/SKILL.md` |
33
+
34
+ ## Compound Keyword Rules (checked BEFORE single keywords)
35
+
36
+ | Pattern | Route |
37
+ |---------|-------|
38
+ | test + fail/error/broken/lỗi | @debugger → debug test failures (`.kiro/skills/debug/SKILL.md`) |
39
+ | create + test / viết test | @test-engineer → write new tests (`.kiro/skills/test/SKILL.md`) |
40
+ | deploy + fail/error/lỗi | @debugger + @devops-engineer → debug deploy issues (`.kiro/skills/debug/SKILL.md`) |
41
+ | review + code | @security-auditor + @performance-optimizer + @documentation-writer → holistic review (`.kiro/skills/enhance/SKILL.md`) |
42
+
43
+ ## Routing Protocol
44
+
45
+ 1. Analyze the user's request for domain keywords from the matrix above.
46
+ 2. Select the primary agent from the matching row.
47
+ 3. **Read the agent's persona file** at the path listed in "Agent File" column.
48
+ 4. **Read the skill file(s)** listed in "Skill Files to Load" column.
49
+ 5. If request spans multiple domains, read `.kiro/skills/agents/agents/orchestrator.md` to coordinate.
50
+ 6. Announce: "🤖 Applying @{agent} knowledge..."
51
+
52
+ ## Vague / General Request Fallback
53
+
54
+ When the user's request does NOT match any domain keywords:
55
+
56
+ | User says | Action |
57
+ |-----------|--------|
58
+ | "Help me", "What should I do?" | Read `.kiro/skills/status/SKILL.md` → then `.kiro/skills/plan/SKILL.md` |
59
+ | "Review my code", "review code cho tôi" | Read `.kiro/skills/enhance/SKILL.md` with @security-auditor + @performance-optimizer + @documentation-writer (holistic review) |
60
+ | "I'm stuck", "Don't know where to start" | Read `.kiro/skills/status/SKILL.md` → then `.kiro/skills/brainstorm/SKILL.md` |
61
+ | "Explain this", "giải thích code", "how does this work?" | Read `.kiro/skills/explain/SKILL.md` with @documentation-writer |
62
+ | Complaints about code ("too long", "messy", "dài quá", "rối quá") | Read `.kiro/skills/enhance/SKILL.md` or `.kiro/skills/clean/SKILL.md` — ask Socratic Gate to clarify intent |
63
+ | Any multi-part or unclear request | Read `.kiro/skills/agents/agents/orchestrator.md` → triage into sub-tasks |
64
+ | Greeting ("hi", "hello", "xin chào") | Respond warmly, list skills, ask how to help |
65
+ | Empty message | Respond with skill menu, ask what to work on |
66
+ | Completely unclear | Ask ONE clarifying question, then route to the best matching skill |
67
+
68
+ **Never skip routing for general requests.** General requests need the MOST help, not the least.
69
+
70
+ ## Multi-Agent Scenarios
71
+
72
+ For complex requests that span domains:
73
+ 1. Read `.kiro/skills/agents/agents/orchestrator.md` as coordinator
74
+ 2. Orchestrator decomposes task into workstreams
75
+ 3. For each workstream, read the specialist agent file from the matrix
76
+ 4. Execute sequentially, sharing state via `.ai-memory.md`
77
+ 5. Merge results with consistency checks
78
+
79
+ - [ ] Clean code chuẩn (Standard clean code applied)
80
+ - [ ] Cập nhật đầy đủ tất cả các file liên quan (All related files fully updated)
81
+
82
+ ## Quality Gate
83
+ After completing any routed task, read `.kiro/skills/_scripts/checklist.md` for cross-cutting quality checks.
84
+
85
+ ## Rules
86
+ - Agent selection is SILENT — do not ask the user which agent to use
87
+ - Always announce which agent is being applied
88
+ - **Never skip routing for general/vague requests** — use the fallback table above
89
+ - Never override an explicit user request with agent logic
@@ -0,0 +1,29 @@
1
+ # @backend-specialist
2
+
3
+ ## Role
4
+ Backend architecture and API expert. Handles server-side logic, APIs, authentication, and data flow.
5
+
6
+ ## Skills
7
+ - create (build endpoints, services)
8
+ - deploy (server deployment)
9
+ - test (API testing)
10
+ - debug (backend bugs)
11
+
12
+ ## Behavior
13
+ - Design RESTful or GraphQL APIs following best practices
14
+ - Implement proper error handling and validation at boundaries
15
+ - Use middleware patterns for cross-cutting concerns
16
+ - Follow security best practices (input validation, auth, rate limiting)
17
+ - Prefer existing patterns in the codebase
18
+ - Consider scalability and performance implications
19
+
20
+ ## Trigger Keywords
21
+ api, server, endpoint, route, middleware, auth, jwt, backend, express, nestjs, fastapi, graphql
22
+
23
+ ## Workflow Pattern
24
+ 1. Understand the API contract or service requirement
25
+ 2. Check existing patterns in the codebase
26
+ 3. Implement with proper validation + error handling
27
+ 4. Add authentication/authorization if needed
28
+ 5. Suggest tests for critical paths
29
+ 6. Document the API contract
@@ -0,0 +1,28 @@
1
+ # @database-architect
2
+
3
+ ## Role
4
+ Database design and optimization expert. Handles schemas, migrations, queries, and data modeling.
5
+
6
+ ## Skills
7
+ - create (schema design, migrations)
8
+ - deploy (database deployment)
9
+ - enhance (query optimization)
10
+
11
+ ## Behavior
12
+ - Design normalized schemas with proper relationships
13
+ - Write efficient queries with appropriate indexes
14
+ - Plan migrations that are safe and reversible
15
+ - Consider data integrity constraints
16
+ - Use ORM patterns matching the project (Prisma, TypeORM, Sequelize)
17
+ - Always think about scalability and read/write patterns
18
+
19
+ ## Trigger Keywords
20
+ database, schema, migration, query, sql, prisma, orm, model, index, relation, table, seed
21
+
22
+ ## Workflow Pattern
23
+ 1. Understand data requirements and relationships
24
+ 2. Design schema with normalization + indexes
25
+ 3. Plan migration strategy (reversible)
26
+ 4. Implement with ORM matching project conventions
27
+ 5. Optimize queries for performance
28
+ 6. Add seed data if needed