ai-developer-skill-os 1.8.1 → 2.0.0

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 (55) hide show
  1. package/README.md +130 -171
  2. package/docs/CHI_TIET_SKILLS.md +89 -81
  3. package/docs/HUONG_DAN_SU_DUNG.md +120 -152
  4. package/package.json +1 -1
  5. package/skills/{qk-accessibility-audit → _archive_old_skills/qk-accessibility-audit}/SKILL.md +1 -1
  6. package/skills/{qk-agent-orchestrator → _archive_old_skills/qk-agent-orchestrator}/SKILL.md +1 -1
  7. package/skills/{qk-bug-fix → _archive_old_skills/qk-bug-fix}/SKILL.md +1 -1
  8. package/skills/{qk-component-generator → _archive_old_skills/qk-component-generator}/SKILL.md +1 -1
  9. package/skills/{qk-database-engineer → _archive_old_skills/qk-database-engineer}/SKILL.md +1 -1
  10. package/skills/{qk-design-system → _archive_old_skills/qk-design-system}/SKILL.md +1 -1
  11. package/skills/{qk-form-builder → _archive_old_skills/qk-form-builder}/SKILL.md +1 -1
  12. package/skills/{qk-frontend-architecture → _archive_old_skills/qk-frontend-architecture}/SKILL.md +1 -1
  13. package/skills/{qk-frontend-debug → _archive_old_skills/qk-frontend-debug}/SKILL.md +1 -1
  14. package/skills/{qk-frontend-performance → _archive_old_skills/qk-frontend-performance}/SKILL.md +1 -1
  15. package/skills/{qk-git-engineer → _archive_old_skills/qk-git-engineer}/SKILL.md +1 -1
  16. package/skills/_archive_old_skills/qk-help/SKILL.md +67 -0
  17. package/skills/{qk-state-management → _archive_old_skills/qk-state-management}/SKILL.md +1 -1
  18. package/skills/{qk-table-crud-generator → _archive_old_skills/qk-table-crud-generator}/SKILL.md +1 -1
  19. package/skills/qk-access-policy/SKILL.md +127 -0
  20. package/skills/qk-ai-builder/SKILL.md +33 -0
  21. package/skills/qk-api-lifecycle/SKILL.md +420 -0
  22. package/skills/qk-bug-resolution/SKILL.md +371 -0
  23. package/skills/qk-context-loader/SKILL.md +206 -0
  24. package/skills/qk-data-lifecycle/SKILL.md +135 -0
  25. package/skills/qk-design-to-code/SKILL.md +33 -0
  26. package/skills/qk-docs/SKILL.md +335 -0
  27. package/skills/qk-documentation-system/SKILL.md +33 -0
  28. package/skills/qk-engineering-standard/SKILL.md +171 -0
  29. package/skills/qk-engineering-standard/rules/backend.md +122 -0
  30. package/skills/qk-engineering-standard/rules/database.md +3 -0
  31. package/skills/qk-engineering-standard/rules/frontend.md +152 -0
  32. package/skills/qk-engineering-standard/rules/security.md +3 -0
  33. package/skills/qk-engineering-standard/rules/testing.md +3 -0
  34. package/skills/qk-feature-delivery/SKILL.md +432 -0
  35. package/skills/qk-help/SKILL.md +95 -67
  36. package/skills/qk-orchestrator/SKILL.md +272 -0
  37. package/skills/qk-policy-engine/SKILL.md +33 -0
  38. package/skills/qk-production-release/SKILL.md +127 -0
  39. package/skills/qk-project-bootstrap/SKILL.md +33 -0
  40. package/skills/qk-project-health/SKILL.md +650 -0
  41. package/skills/qk-project-memory/SKILL.md +33 -0
  42. package/skills/qk-system-evolution/SKILL.md +315 -0
  43. package/skills/qk-ui-audit/SKILL.md +152 -0
  44. package/skills/qk-ui-system-builder/SKILL.md +444 -0
  45. package/skills/qk-validation-gate/SKILL.md +33 -0
  46. /package/skills/{qk-api-integration → _archive_old_skills/qk-api-integration}/SKILL.md +0 -0
  47. /package/skills/{qk-auth-security → _archive_old_skills/qk-auth-security}/SKILL.md +0 -0
  48. /package/skills/{qk-backend-architecture → _archive_old_skills/qk-backend-architecture}/SKILL.md +0 -0
  49. /package/skills/{qk-context-manager → _archive_old_skills/qk-context-manager}/SKILL.md +0 -0
  50. /package/skills/{qk-deployment → _archive_old_skills/qk-deployment}/SKILL.md +0 -0
  51. /package/skills/{qk-frontend-testing → _archive_old_skills/qk-frontend-testing}/SKILL.md +0 -0
  52. /package/skills/{qk-migration → _archive_old_skills/qk-migration}/SKILL.md +0 -0
  53. /package/skills/{qk-project-audit → _archive_old_skills/qk-project-audit}/SKILL.md +0 -0
  54. /package/skills/{qk-refactor → _archive_old_skills/qk-refactor}/SKILL.md +0 -0
  55. /package/skills/{qk-ui-builder → _archive_old_skills/qk-ui-builder}/SKILL.md +0 -0
@@ -1,67 +1,95 @@
1
- ---
2
- name: qk-help
3
- description: >-
4
- Tra cứu danh sách toàn bộ kỹ năng (skills) hiện có và đọc các mẹo (pro-tips) kết hợp kỹ năng để tăng tốc độ code.
5
- version: 1.0.0
6
- category: engineering
7
- tags: [help, list, tips, guide, manual]
8
- platforms: [antigravity, claude-code, kilo-code, cursor, windsurf]
9
- ---
10
-
11
- # 📚 Cẩm nang AI Developer Skill OS
12
-
13
- > **Nhiệm vụ của bạn (AI):** Khi người dùng gọi lệnh `./qk-help`, hãy xuất ra màn hình (bằng tiếng Việt) danh sách các kỹ năng phân theo nhóm và các Mẹo sử dụng (Pro-tips) dưới đây một cách sinh động, dễ đọc (dùng markdown, in đậm, emoji). Không cần phân tích code, chỉ đóng vai trò là "Sách hướng dẫn sử dụng".
14
-
15
- ---
16
-
17
- ## 🎯 1. Danh sách Kỹ năng (Skills Directory)
18
-
19
- Dưới đây là các kỹ năng chính bạn có thể gọi bằng cách gõ `./qk-[tên-kỹ-năng]`:
20
-
21
- ### 🎨 Frontend (Giao diện)
22
- - **`qk-ui-builder`**: Xây dựng UI, Layout, Component, Modal phức tạp.
23
- - **`qk-table-crud-generator`**: Chuyên vẽ bảng danh sách (Table), phân trang, lọc form Thêm/Sửa/Xóa.
24
- - **`qk-form-builder`**: Chuyên làm Form nhập liệu, validate (Zod/Yup).
25
- - **`qk-component-generator`**: Tạo Component độc lập, tái sử dụng (Button, Input, Card).
26
- - **`qk-state-management`**: Xử lý Redux, Zustand, React Query.
27
- - **`qk-frontend-debug`**: Bắt bệnh vỡ layout, infinite re-render, lỗi Hydration.
28
- - **`qk-frontend-performance`**: Tối ưu tốc độ, chống re-render thừa.
29
- - **`qk-frontend-architecture`**: vấn kiến trúc thư mục Frontend.
30
- - **`qk-frontend-testing`**: Viết Unit Test / E2E Test cho Frontend.
31
- - **`qk-accessibility-audit`**: Sửa lỗi a11y, hỗ trợ Screen reader.
32
-
33
- ### ⚙️ Engineering & Integration (Tích hợp)
34
- - **`qk-api-integration`**: [Cực mạnh] Bóc tách tài liệu API (Curl, Postman) -> Gen Type, Service, Hook -> (Tùy chọn) Ốp thẳng vào UI.
35
- - **`qk-refactor`**: Tối ưu, dọn dẹp nguồn sạch sẽ.
36
- - **`qk-bug-fix`**: Chẩn đoán lỗi sâu và sửa an toàn.
37
- - **`qk-project-audit`**: Quét toàn bộ dự án tìm nợ kỹ thuật.
38
- - **`qk-git-engineer`**: Viết Commit / PR chuẩn Conventional.
39
- - **`qk-migration`**: Nâng cấp version framework / thư viện.
40
- - **`qk-agent-orchestrator`**: Kiến trúc sư, lên plan phân rã task lớn.
41
- - **`qk-context-manager`**: Tóm tắt kiến trúc dự án.
42
-
43
- ### 🗄️ Backend (Máy chủ)
44
- - **`qk-database-engineer`**: Thiết kế Schema, ORM (Prisma/Drizzle), Migration.
45
- - **`qk-backend-architecture`**: Setup kiến trúc Backend (Node/Nest/Python).
46
- - **`qk-auth-security`**: Phân quyền RBAC, JWT, OAuth.
47
- - **`qk-deployment`**: Viết Dockerfile, CI/CD Pipeline.
48
-
49
- ---
50
-
51
- ## 💡 2. Mẹo sử dụng Nâng cao (Pro-Tips)
52
-
53
- ### Mẹo 1: Kết hợp Kỹ năng (Skill Chaining) 🔗
54
- Đừng bắt AI làm từ A-Z bằng 1 câu prompt. Hãy gọi liên hoàn:
55
- > *"Hãy dùng `./qk-api-integration` để bóc tách API này thành hook React Query. Sau đó dùng `./qk-table-crud-generator` vẽ cái Bảng hiển thị danh sách tích hợp hook đó."*
56
-
57
- ### Mẹo 2: Chế độ "Một phát ăn ngay" (End-to-End) 🚀
58
- Nếu bạn đã sẵn 1 màn hình UI (chỉ thiếu data), hãy ép `qk-api-integration` làm End-to-End:
59
- > *"./qk-api-integration Dưới đây là API Get Profile. Hãy khai báo Type, viết Hook TÍCH HỢP THẲNG LUÔN vào file \`Profile.tsx\` đang mở."*
60
-
61
- ### Mẹo 3: Truyền tham số ép buộc (Arguments) 🎯
62
- Bạn thể ép AI dùng công nghệ bạn muốn bằng cách thêm \`--tham_số\`:
63
- > *"./qk-ui-builder --fw=react --css=tailwind Hãy vẽ màn hình Đăng nhập."*
64
-
65
- ### Mẹo 4: Nhờ "Kiến trúc sư" phân việc 🧠
66
- Nếu bạn một tính năng quá lớn (ví dụ: Làm tính năng Giỏ Hàng), đừng tự chia việc, hãy gọi:
67
- > *"./qk-agent-orchestrator Tôi muốn làm tính năng Giỏ hàng. Hãy phân tích và lên kế hoạch gọi các skill \`qk-\` nào cho phù hợp."*
1
+ ---
2
+ name: qk-help
3
+ purpose: Tra cứu danh sách toàn bộ kỹ năng (skills) hiện có và đọc các mẹo (pro-tips) kết hợp kỹ năng.
4
+ mode_supported: [quick, standard]
5
+ input: [User query]
6
+ output: [Skill list, guides]
7
+ workflow: [1. Nhận câu hỏi -> 2. Tra cứu -> 3. Phản hồi]
8
+ allowed_tools: [read_file, list_dir]
9
+ handoff_to: [none]
10
+ ---
11
+
12
+ # 🛠️ qk-help - Quy Trình Vận Hành Chuẩn (SOP)
13
+
14
+ > **Mô tả:** Tra cứu danh sách toàn bộ kỹ năng (skills) hiện có và đọc các mẹo (pro-tips) kết hợp kỹ năng.
15
+
16
+ ## 🎯 1. Mục Tiêu (Goal)
17
+ - Cung cấp danh sách các kỹ năng hệ thống (AI-OS) cho người dùng.
18
+ - Hướng dẫn cách kết hợp các kỹ năng để tạo ra chuỗi giá trị (workflow).
19
+
20
+ ## 🔄 2. Chuỗi Hành Động (Chain of Thought / SOP)
21
+ *(Bắt buộc AI phải suy nghĩ và làm theo đúng thứ tự)*
22
+ 1. **Phân tích (Analyze):** Phân tích câu hỏi của người dùng xem họ đang tìm kiếm gì.
23
+ 2. **Tra cứu (Plan):** Kiểm tra danh sách các kỹ năng hoặc mẹo sử dụng trong phần Deep Knowledge.
24
+ 3. **Thực thi (Execute):** Định dạng trả lời câu hỏi một cách dễ hiểu nhất.
25
+ 4. **Xác thực (Verify):** Đảm bảo không giới thiệu các skill không tồn tại.
26
+
27
+ ## 🛡️ 3. Ràng Buộc & Quy Tắc (Constraints)
28
+ - Chỉ được liệt các skill đang có thực trong dự án.
29
+ - Mọi quyết định kỹ thuật phải dựa trên nội dung tại phần Deep Knowledge (nếu có).
30
+
31
+ ## 🤝 4. Giao Thức Bàn Giao (Handoff Protocol)
32
+ - Đích đến: `none`
33
+ - Nội dung bàn giao: Trả về kết quả hiển thị cho người dùng.
34
+
35
+ ## 📚 5. Kiến Thức Chuyên Sâu (Deep Knowledge)
36
+
37
+ *(Nền tảng kiến thức quy tắc chi tiết kế thừa từ kỹ sư)*
38
+
39
+ # 📚 Cẩm nang AI Developer Skill OS
40
+
41
+ > **Nhiệm vụ của bạn (AI):** Khi người dùng gọi lệnh `./qk-help`, hãy xuất ra màn hình (bằng tiếng Việt) danh sách các kỹ năng phân theo nhóm và các Mẹo sử dụng (Pro-tips) dưới đây một cách sinh động, dễ đọc (dùng markdown, in đậm, emoji). Không cần phân tích code, chỉ đóng vai trò là "Sách hướng dẫn sử dụng".
42
+
43
+ ---
44
+
45
+ ## 🎯 1. Danh sách Kỹ năng (Skills Directory)
46
+
47
+ Dưới đây các kỹ năng chính bạn có thể gọi bằng cách gõ `./qk-[tên-kỹ-năng]`:
48
+
49
+ ### 🎨 Frontend (Giao diện)
50
+ - **`qk-ui-builder`**: Xây dựng UI, Layout, Component, Modal phức tạp.
51
+ - **`qk-table-crud-generator`**: Chuyên vẽ bảng danh sách (Table), phân trang, lọc và form Thêm/Sửa/Xóa.
52
+ - **`qk-form-builder`**: Chuyên làm Form nhập liệu, validate (Zod/Yup).
53
+ - **`qk-component-generator`**: Tạo Component độc lập, tái sử dụng (Button, Input, Card).
54
+ - **`qk-state-management`**: Xử Redux, Zustand, React Query.
55
+ - **`qk-frontend-debug`**: Bắt bệnh vỡ layout, infinite re-render, lỗi Hydration.
56
+ - **`qk-frontend-performance`**: Tối ưu tốc độ, chống re-render thừa.
57
+ - **`qk-frontend-architecture`**: vấn kiến trúc thư mục Frontend.
58
+ - **`qk-frontend-testing`**: Viết Unit Test / E2E Test cho Frontend.
59
+ - **`qk-accessibility-audit`**: Sửa lỗi a11y, hỗ trợ Screen reader.
60
+
61
+ ### ⚙️ Engineering & Integration (Tích hợp)
62
+ - **`qk-api-integration`**: [Cực mạnh] Bóc tách tài liệu API (Curl, Postman) -> Gen Type, Service, Hook -> (Tùy chọn) Ốp thẳng vào UI.
63
+ - **`qk-refactor`**: Tối ưu, dọn dẹp nguồn sạch sẽ.
64
+ - **`qk-bug-fix`**: Chẩn đoán lỗi sâu và sửa an toàn.
65
+ - **`qk-project-audit`**: Quét toàn bộ dự án tìm nợ kỹ thuật.
66
+ - **`qk-git-engineer`**: Viết Commit / PR chuẩn Conventional.
67
+ - **`qk-migration`**: Nâng cấp version framework / thư viện.
68
+ - **`qk-agent-orchestrator`**: Kiến trúc sư, lên plan phân rã task lớn.
69
+ - **`qk-context-manager`**: Tóm tắt kiến trúc dự án.
70
+
71
+ ### 🗄️ Backend (Máy chủ)
72
+ - **`qk-database-engineer`**: Thiết kế Schema, ORM (Prisma/Drizzle), Migration.
73
+ - **`qk-backend-architecture`**: Setup kiến trúc Backend (Node/Nest/Python).
74
+ - **`qk-auth-security`**: Phân quyền RBAC, JWT, OAuth.
75
+ - **`qk-deployment`**: Viết Dockerfile, CI/CD Pipeline.
76
+
77
+ ---
78
+
79
+ ## 💡 2. Mẹo sử dụng Nâng cao (Pro-Tips)
80
+
81
+ ### Mẹo 1: Kết hợp Kỹ năng (Skill Chaining) 🔗
82
+ Đừng bắt AI làm từ A-Z bằng 1 câu prompt. Hãy gọi liên hoàn:
83
+ > *"Hãy dùng `./qk-api-integration` để bóc tách API này thành hook React Query. Sau đó dùng `./qk-table-crud-generator` vẽ cái Bảng hiển thị danh sách tích hợp hook đó."*
84
+
85
+ ### Mẹo 2: Chế độ "Một phát ăn ngay" (End-to-End) 🚀
86
+ Nếu bạn đã có sẵn 1 màn hình UI (chỉ thiếu data), hãy ép `qk-api-integration` làm End-to-End:
87
+ > *"./qk-api-integration Dưới đây là API Get Profile. Hãy khai báo Type, viết Hook và TÍCH HỢP THẲNG LUÔN vào file \`Profile.tsx\` đang mở."*
88
+
89
+ ### Mẹo 3: Truyền tham số ép buộc (Arguments) 🎯
90
+ Bạn có thể ép AI dùng công nghệ bạn muốn bằng cách thêm \`--tham_số\`:
91
+ > *"./qk-ui-builder --fw=react --css=tailwind Hãy vẽ màn hình Đăng nhập."*
92
+
93
+ ### Mẹo 4: Nhờ "Kiến trúc sư" phân việc 🧠
94
+ Nếu bạn có một tính năng quá lớn (ví dụ: Làm tính năng Giỏ Hàng), đừng tự chia việc, hãy gọi:
95
+ > *"./qk-agent-orchestrator Tôi muốn làm tính năng Giỏ hàng. Hãy phân tích và lên kế hoạch gọi các skill \`qk-\` nào cho phù hợp."*
@@ -0,0 +1,272 @@
1
+ ---
2
+ name: qk-orchestrator
3
+ purpose: Điều hướng request, phân tích ý đồ và chọn workflow phù hợp nhất.
4
+ mode_supported: [standard]
5
+ input: [User request]
6
+ output: [Workflow được chọn và bàn giao cho skill tương ứng]
7
+ workflow: [1. Nhận lệnh -> 2. Phân tích -> 3. Handoff]
8
+ allowed_tools: [ask_question, run_command]
9
+ handoff_to: [qk-context-loader]
10
+ ---
11
+
12
+ # 🛠️ qk-orchestrator - Quy Trình Vận Hành Chuẩn (SOP)
13
+
14
+ > **Mô tả:** Điều hướng request, phân tích ý đồ và chọn workflow phù hợp nhất.
15
+
16
+ ## 🎯 1. Mục Tiêu (Goal)
17
+ - Hoàn thành thành công tác vụ được giao liên quan đến nhiệm vụ của skill.
18
+ - Đảm bảo chất lượng mã nguồn và tính nhất quán của hệ thống.
19
+
20
+ ## 🔄 2. Chuỗi Hành Động (Chain of Thought / SOP)
21
+ *(Bắt buộc AI phải suy nghĩ và làm theo đúng thứ tự)*
22
+ 1. **Phân tích (Analyze):** Thu thập ngữ cảnh và hiểu rõ yêu cầu đầu vào.
23
+ 2. **Lên kế hoạch (Plan):** Xác định các bước cần thay đổi/tạo mới dựa trên bộ luật (rules).
24
+ 3. **Thực thi (Execute):** Tiến hành sửa đổi mã nguồn hoặc tạo tài liệu.
25
+ 4. **Xác thực (Verify):** Đảm bảo đầu ra đáp ứng đúng yêu cầu và không vi phạm quy định.
26
+
27
+ ## 🛡️ 3. Ràng Buộc & Quy Tắc (Constraints)
28
+ - CẤM bỏ qua việc kiểm tra `qk-engineering-standard` trước khi viết code.
29
+ - Mọi quyết định kỹ thuật phải dựa trên nội dung tại phần Deep Knowledge (nếu có).
30
+
31
+ ## 🤝 4. Giao Thức Bàn Giao (Handoff Protocol)
32
+ - Đích đến: `qk-context-loader`
33
+ - Nội dung bàn giao: Chuyển toàn bộ ngữ cảnh và kết quả đã thực thi cho bước tiếp theo.
34
+
35
+ ## 📚 5. Kiến Thức Chuyên Sâu (Deep Knowledge)
36
+
37
+ *(Nền tảng kiến thức và quy tắc chi tiết kế thừa từ kỹ sư)*
38
+
39
+ ---
40
+
41
+
42
+
43
+ # Agent Orchestrator
44
+
45
+ > **Language rule:**
46
+ > Use English for: code, identifiers, file names, architecture terms, technical decisions.
47
+ > Use the user's language for: explanations, questions, summaries, and feedback.
48
+ > The user may write in any language — detect and match it automatically.
49
+
50
+ > ⚠️ **CRITICAL CONSTRAINT: This skill MUST NOT write any code.**
51
+ > Its only job is to analyze, plan, and delegate.
52
+ > If the orchestrator starts writing implementation code — it is violating its role.
53
+ > Immediately stop and delegate to the appropriate skill instead.
54
+
55
+ ---
56
+
57
+ ## Trigger
58
+
59
+ Activate this skill when:
60
+ - User describes a task without knowing where to start
61
+ - User request spans multiple concerns (UI + API + state + tests)
62
+ - Request is ambiguous and needs decomposition before action
63
+ - User says: "help me plan", "what should I do first", "how do I approach this"
64
+
65
+ ---
66
+
67
+ ## Scope
68
+
69
+ - ✅ Analyze the user's request
70
+ - ✅ Identify which skills are needed
71
+ - ✅ Define the correct execution order
72
+ - ✅ Create a step-by-step plan
73
+ - ✅ Delegate each step to the correct skill
74
+ - ✅ Track overall progress
75
+
76
+ ---
77
+
78
+ ## Non-goals
79
+
80
+ - ❌ Do NOT write implementation code
81
+ - ❌ Do NOT modify files
82
+ - ❌ Do NOT fix bugs directly (delegate to `bug-fix`)
83
+ - ❌ Do NOT build UI directly (delegate to `ui-builder`)
84
+ - ❌ Do NOT make architectural decisions unilaterally (delegate to `frontend-architecture`)
85
+
86
+ ---
87
+
88
+ ## Workflow
89
+
90
+ ### Phase 1 — Request Analysis
91
+
92
+ Parse the user's request:
93
+
94
+ 1. **What** is being asked? (feature, fix, refactor, review, deploy?)
95
+ 2. **Where** does it belong? (frontend, backend, shared, infrastructure?)
96
+ 3. **What is the scope?** (single component, full feature, entire codebase?)
97
+ 4. **What is unknown?** List any ambiguities that need clarification.
98
+
99
+ If critical information is missing → ask before planning.
100
+
101
+ ---
102
+
103
+ ### Phase 2 — Skill Selection
104
+
105
+ Map the request to skills from the registry:
106
+
107
+ | Request type | Recommended skill(s) |
108
+ |---|---|
109
+ | "I don't know what's wrong" | `project-audit` → `bug-fix` |
110
+ | "Build a new page" | `frontend-architecture` → `design-system` → `ui-builder` |
111
+ | "Add API call" | `context-manager` → `api-integration` |
112
+ | "App is slow" | `project-audit` → `frontend-performance` |
113
+ | "Upgrade dependencies" | `migration` |
114
+ | "Write tests" | `frontend-testing` |
115
+
116
+ Always check dependencies from `skills.json` — load dependent skills first.
117
+
118
+ ---
119
+
120
+ ### Phase 3 — Execution Plan
121
+
122
+ Produce a numbered, ordered plan. Each step maps to one skill.
123
+
124
+ Format:
125
+ ```
126
+ Step 1: [skill-name] — [what it will do]
127
+ Step 2: [skill-name] — [what it will do]
128
+ Step 3: [skill-name] — [what it will do]
129
+ ```
130
+
131
+ Mark dependencies explicitly:
132
+ ```
133
+ Step 2 requires Step 1 to complete first.
134
+ ```
135
+
136
+ ---
137
+
138
+ ### Phase 4 — Delegation
139
+
140
+ For each step in the plan:
141
+ 1. Announce which skill is being activated
142
+ 2. Pass relevant context to that skill
143
+ 3. Wait for skill output
144
+ 4. Confirm completion before moving to next step
145
+
146
+ ---
147
+
148
+ ### Phase 5 — Progress Tracking
149
+
150
+ After each skill completes:
151
+ - Mark step as ✅ done
152
+ - Note any output or blockers
153
+ - Adjust remaining plan if needed
154
+ - Report overall progress to user
155
+
156
+ ---
157
+
158
+ ## Decision Tree
159
+
160
+ ```
161
+ Is the request clear enough to plan?
162
+ ├── No → Ask 1-3 clarifying questions, then plan
163
+ └── Yes → Does it span multiple concerns?
164
+ ├── Yes → Create multi-step plan with skill sequence
165
+ └── No → Route directly to single skill
166
+ ```
167
+
168
+ ```
169
+ Does a skill dependency exist?
170
+ ├── Yes → Run dependency skill first
171
+ └── No → Run skill directly
172
+ ```
173
+
174
+ ---
175
+
176
+ ## Output Format
177
+
178
+ ```
179
+ 📋 Plan: [Brief description of what we're doing]
180
+
181
+ Step 1: `[skill-name]` — [Purpose]
182
+ Step 2: `[skill-name]` — [Purpose] ← requires Step 1
183
+ Step 3: `[skill-name]` — [Purpose]
184
+
185
+ ⏳ Starting with Step 1...
186
+ ```
187
+
188
+ After each step:
189
+ ```
190
+ ✅ Step 1 complete: [Brief outcome]
191
+ ▶️ Moving to Step 2: `[skill-name]`
192
+ ```
193
+
194
+ ---
195
+
196
+ ## Validation Checklist
197
+
198
+ Before finishing orchestration:
199
+
200
+ - [ ] All planned steps completed
201
+ - [ ] Each step was handled by the correct skill
202
+ - [ ] No code was written by the orchestrator itself
203
+ - [ ] User has been informed of final outcome
204
+ - [ ] Next recommended actions provided if relevant
205
+
206
+ ---
207
+
208
+ ## Examples
209
+
210
+ See `examples/` folder.
211
+
212
+ ---
213
+
214
+
215
+
216
+ # 📚 Cẩm nang AI Developer Skill OS
217
+
218
+ > **Nhiệm vụ của bạn (AI):** Khi người dùng gọi lệnh `./qk-help`, hãy xuất ra màn hình (bằng tiếng Việt) danh sách các kỹ năng phân theo nhóm và các Mẹo sử dụng (Pro-tips) dưới đây một cách sinh động, dễ đọc (dùng markdown, in đậm, emoji). Không cần phân tích code, chỉ đóng vai trò là "Sách hướng dẫn sử dụng".
219
+
220
+ ---
221
+
222
+ ## 🎯 1. Danh sách Kỹ năng (Skills Directory)
223
+
224
+ Dưới đây là các kỹ năng chính bạn có thể gọi bằng cách gõ `./qk-[tên-kỹ-năng]`:
225
+
226
+ ### 🎨 Frontend (Giao diện)
227
+ - **`qk-ui-builder`**: Xây dựng UI, Layout, Component, Modal phức tạp.
228
+ - **`qk-table-crud-generator`**: Chuyên vẽ bảng danh sách (Table), phân trang, lọc và form Thêm/Sửa/Xóa.
229
+ - **`qk-form-builder`**: Chuyên làm Form nhập liệu, validate (Zod/Yup).
230
+ - **`qk-component-generator`**: Tạo Component độc lập, tái sử dụng (Button, Input, Card).
231
+ - **`qk-state-management`**: Xử lý Redux, Zustand, React Query.
232
+ - **`qk-frontend-debug`**: Bắt bệnh vỡ layout, infinite re-render, lỗi Hydration.
233
+ - **`qk-frontend-performance`**: Tối ưu tốc độ, chống re-render thừa.
234
+ - **`qk-frontend-architecture`**: Tư vấn kiến trúc thư mục Frontend.
235
+ - **`qk-frontend-testing`**: Viết Unit Test / E2E Test cho Frontend.
236
+ - **`qk-accessibility-audit`**: Sửa lỗi a11y, hỗ trợ Screen reader.
237
+
238
+ ### ⚙️ Engineering & Integration (Tích hợp)
239
+ - **`qk-api-integration`**: [Cực mạnh] Bóc tách tài liệu API (Curl, Postman) -> Gen Type, Service, Hook -> (Tùy chọn) Ốp thẳng vào UI.
240
+ - **`qk-refactor`**: Tối ưu, dọn dẹp mã nguồn sạch sẽ.
241
+ - **`qk-bug-fix`**: Chẩn đoán lỗi sâu và sửa an toàn.
242
+ - **`qk-project-audit`**: Quét toàn bộ dự án tìm nợ kỹ thuật.
243
+ - **`qk-git-engineer`**: Viết Commit / PR chuẩn Conventional.
244
+ - **`qk-migration`**: Nâng cấp version framework / thư viện.
245
+ - **`qk-agent-orchestrator`**: Kiến trúc sư, lên plan phân rã task lớn.
246
+ - **`qk-context-manager`**: Tóm tắt kiến trúc dự án.
247
+
248
+ ### 🗄️ Backend (Máy chủ)
249
+ - **`qk-database-engineer`**: Thiết kế Schema, ORM (Prisma/Drizzle), Migration.
250
+ - **`qk-backend-architecture`**: Setup kiến trúc Backend (Node/Nest/Python).
251
+ - **`qk-auth-security`**: Phân quyền RBAC, JWT, OAuth.
252
+ - **`qk-deployment`**: Viết Dockerfile, CI/CD Pipeline.
253
+
254
+ ---
255
+
256
+ ## 💡 2. Mẹo sử dụng Nâng cao (Pro-Tips)
257
+
258
+ ### Mẹo 1: Kết hợp Kỹ năng (Skill Chaining) 🔗
259
+ Đừng bắt AI làm từ A-Z bằng 1 câu prompt. Hãy gọi liên hoàn:
260
+ > *"Hãy dùng `./qk-api-integration` để bóc tách API này thành hook React Query. Sau đó dùng `./qk-table-crud-generator` vẽ cái Bảng hiển thị danh sách tích hợp hook đó."*
261
+
262
+ ### Mẹo 2: Chế độ "Một phát ăn ngay" (End-to-End) 🚀
263
+ Nếu bạn đã có sẵn 1 màn hình UI (chỉ thiếu data), hãy ép `qk-api-integration` làm End-to-End:
264
+ > *"./qk-api-integration Dưới đây là API Get Profile. Hãy khai báo Type, viết Hook và TÍCH HỢP THẲNG LUÔN vào file \`Profile.tsx\` đang mở."*
265
+
266
+ ### Mẹo 3: Truyền tham số ép buộc (Arguments) 🎯
267
+ Bạn có thể ép AI dùng công nghệ bạn muốn bằng cách thêm \`--tham_số\`:
268
+ > *"./qk-ui-builder --fw=react --css=tailwind Hãy vẽ màn hình Đăng nhập."*
269
+
270
+ ### Mẹo 4: Nhờ "Kiến trúc sư" phân việc 🧠
271
+ Nếu bạn có một tính năng quá lớn (ví dụ: Làm tính năng Giỏ Hàng), đừng tự chia việc, hãy gọi:
272
+ > *"./qk-agent-orchestrator Tôi muốn làm tính năng Giỏ hàng. Hãy phân tích và lên kế hoạch gọi các skill \`qk-\` nào cho phù hợp."*
@@ -0,0 +1,33 @@
1
+ ---
2
+ name: qk-policy-engine
3
+ purpose: Động cơ xét duyệt chính sách, đảm bảo tác vụ hợp lệ trước khi thực thi.
4
+ mode_supported: [enterprise]
5
+ input: [Task request]
6
+ output: [Policy validation result]
7
+ workflow: [1. Đọc chính sách -> 2. Đối chiếu request -> 3. Phê duyệt/Từ chối]
8
+ allowed_tools: [read_file]
9
+ handoff_to: [qk-access-policy]
10
+ ---
11
+
12
+ # 🛠️ qk-policy-engine - Quy Trình Vận Hành Chuẩn (SOP)
13
+
14
+ > **Mô tả:** Động cơ xét duyệt chính sách, đảm bảo tác vụ hợp lệ trước khi thực thi.
15
+
16
+ ## 🎯 1. Mục Tiêu (Goal)
17
+ - Hoàn thành thành công tác vụ được giao liên quan đến nhiệm vụ của skill.
18
+ - Đảm bảo chất lượng mã nguồn và tính nhất quán của hệ thống.
19
+
20
+ ## 🔄 2. Chuỗi Hành Động (Chain of Thought / SOP)
21
+ *(Bắt buộc AI phải suy nghĩ và làm theo đúng thứ tự)*
22
+ 1. **Phân tích (Analyze):** Thu thập ngữ cảnh và hiểu rõ yêu cầu đầu vào.
23
+ 2. **Lên kế hoạch (Plan):** Xác định các bước cần thay đổi/tạo mới dựa trên bộ luật (rules).
24
+ 3. **Thực thi (Execute):** Tiến hành sửa đổi mã nguồn hoặc tạo tài liệu.
25
+ 4. **Xác thực (Verify):** Đảm bảo đầu ra đáp ứng đúng yêu cầu và không vi phạm quy định.
26
+
27
+ ## 🛡️ 3. Ràng Buộc & Quy Tắc (Constraints)
28
+ - CẤM bỏ qua việc kiểm tra `qk-engineering-standard` trước khi viết code.
29
+ - Mọi quyết định kỹ thuật phải dựa trên nội dung tại phần Deep Knowledge (nếu có).
30
+
31
+ ## 🤝 4. Giao Thức Bàn Giao (Handoff Protocol)
32
+ - Đích đến: `qk-access-policy`
33
+ - Nội dung bàn giao: Chuyển toàn bộ ngữ cảnh và kết quả đã thực thi cho bước tiếp theo.
@@ -0,0 +1,127 @@
1
+ ---
2
+ name: qk-production-release
3
+ purpose: Build, CI/CD, Deploy, Observability, Security Release.
4
+ mode_supported: [enterprise]
5
+ input: [Release candidate]
6
+ output: [Production deployment]
7
+ workflow: [1. Build -> 2. CI -> 3. Deploy -> 4. Observe -> 5. Security Audit]
8
+ allowed_tools: [run_command]
9
+ handoff_to: [none]
10
+ ---
11
+
12
+ # 🛠️ qk-production-release - Quy Trình Vận Hành Chuẩn (SOP)
13
+
14
+ > **Mô tả:** Build, CI/CD, Deploy, Observability, Security Release.
15
+
16
+ ## 🎯 1. Mục Tiêu (Goal)
17
+ - Hoàn thành thành công tác vụ được giao liên quan đến nhiệm vụ của skill.
18
+ - Đảm bảo chất lượng mã nguồn và tính nhất quán của hệ thống.
19
+
20
+ ## 🔄 2. Chuỗi Hành Động (Chain of Thought / SOP)
21
+ *(Bắt buộc AI phải suy nghĩ và làm theo đúng thứ tự)*
22
+ 1. **Phân tích (Analyze):** Thu thập ngữ cảnh và hiểu rõ yêu cầu đầu vào.
23
+ 2. **Lên kế hoạch (Plan):** Xác định các bước cần thay đổi/tạo mới dựa trên bộ luật (rules).
24
+ 3. **Thực thi (Execute):** Tiến hành sửa đổi mã nguồn hoặc tạo tài liệu.
25
+ 4. **Xác thực (Verify):** Đảm bảo đầu ra đáp ứng đúng yêu cầu và không vi phạm quy định.
26
+
27
+ ## 🛡️ 3. Ràng Buộc & Quy Tắc (Constraints)
28
+ - CẤM bỏ qua việc kiểm tra `qk-engineering-standard` trước khi viết code.
29
+ - Mọi quyết định kỹ thuật phải dựa trên nội dung tại phần Deep Knowledge (nếu có).
30
+
31
+ ## 🤝 4. Giao Thức Bàn Giao (Handoff Protocol)
32
+ - Đích đến: `none`
33
+ - Nội dung bàn giao: Chuyển toàn bộ ngữ cảnh và kết quả đã thực thi cho bước tiếp theo.
34
+
35
+ ## 📚 5. Kiến Thức Chuyên Sâu (Deep Knowledge)
36
+
37
+ *(Nền tảng kiến thức và quy tắc chi tiết kế thừa từ kỹ sư)*
38
+
39
+ ---
40
+
41
+
42
+
43
+ # Deployment & DevOps
44
+
45
+ > **Language rule:**
46
+ > Use English for: code, identifiers, file names, architecture terms, technical decisions.
47
+ > Use the user's language for: explanations, questions, summaries, and feedback.
48
+ > The user may write in any language — detect and match it automatically.
49
+
50
+ ---
51
+
52
+ ## Trigger
53
+
54
+ Activate this skill when:
55
+ - User asks "how do I deploy this?", "create a Dockerfile", or "setup CI/CD"
56
+ - Configuring GitHub Actions, GitLab CI, or Jenkins
57
+ - Preparing a project for Vercel, Netlify, Render, or AWS
58
+ - Setting up environment variables for production
59
+
60
+ ---
61
+
62
+ ## Scope
63
+
64
+ - ✅ **Containerization:** Write `Dockerfile` and `docker-compose.yml`.
65
+ - ✅ **CI/CD Pipelines:** Write GitHub Actions YAML for testing, building, and deploying.
66
+ - ✅ **Environment Setup:** Create `.env.example` and document required production variables.
67
+ - ✅ **Build Scripts:** Ensure `package.json` has correct build and start commands.
68
+
69
+ ---
70
+
71
+ ## Non-goals
72
+
73
+ - ❌ Do NOT expose real production secrets. Always use placeholders or CI secrets.
74
+ - ❌ Do NOT over-complicate (e.g., don't setup Kubernetes if a simple Docker container on a VPS is enough).
75
+
76
+ ---
77
+
78
+ ## Workflow
79
+
80
+ ### Phase 1 — Platform Selection
81
+
82
+ Ask the user where they are deploying (if not specified):
83
+ 1. **PaaS (Vercel, Render, Heroku):** Very easy, mostly relies on `vercel.json` or standard build scripts. No Docker needed usually.
84
+ 2. **VPS/VM (DigitalOcean, AWS EC2):** Needs Docker and/or PM2 + Nginx reverse proxy.
85
+ 3. **Container Service (AWS ECS, Google Cloud Run):** Needs a highly optimized Dockerfile.
86
+
87
+ ### Phase 2 — Containerization (If required)
88
+
89
+ Create a multi-stage Dockerfile for minimal image size:
90
+ 1. `deps` stage: Install dependencies.
91
+ 2. `builder` stage: Build the app.
92
+ 3. `runner` stage: Copy only the built assets and prod modules, start the app.
93
+
94
+ ### Phase 3 — CI/CD Pipeline
95
+
96
+ Create `.github/workflows/deploy.yml`:
97
+ - Trigger on `push` to `main`.
98
+ - Job 1: Setup Node/Python/Go, install deps, run tests, run linter.
99
+ - Job 2: Build image and push to registry, or deploy to PaaS.
100
+
101
+ ### Phase 4 — Environment Variables
102
+
103
+ Audit the codebase for `process.env.XYZ` and create a `.env.example` file listing every required variable.
104
+
105
+ ---
106
+
107
+ ## Output Format
108
+
109
+ ```
110
+ 🚀 Deployment Plan
111
+ ─────────────────────────────────────────────────
112
+ Target: [Vercel / Docker VPS / AWS]
113
+ Tooling: [GitHub Actions, Docker]
114
+
115
+ Files Created/Modified:
116
+ ✅ `Dockerfile` (Multi-stage build)
117
+ ✅ `.github/workflows/deploy.yml`
118
+ ✅ `.env.example`
119
+
120
+ ⚠️ Prerequisites:
121
+ Before deploying, you must set these secrets in GitHub Actions:
122
+ - `DOCKER_USERNAME`
123
+ - `DATABASE_URL`
124
+
125
+ 🔗 Next Steps:
126
+ Commit these files and push to `main` to trigger the pipeline.
127
+ ```
@@ -0,0 +1,33 @@
1
+ ---
2
+ name: qk-project-bootstrap
3
+ purpose: Khởi tạo hệ thống, setup dự án chuẩn từ con số 0.
4
+ mode_supported: [enterprise]
5
+ input: [Project specs]
6
+ output: [Scaffolded project]
7
+ workflow: [1. Setup Folder -> 2. Config Lint/Format -> 3. Setup UI/API/Test]
8
+ allowed_tools: [run_command, write_to_file]
9
+ handoff_to: [none]
10
+ ---
11
+
12
+ # 🛠️ qk-project-bootstrap - Quy Trình Vận Hành Chuẩn (SOP)
13
+
14
+ > **Mô tả:** Khởi tạo hệ thống, setup dự án chuẩn từ con số 0.
15
+
16
+ ## 🎯 1. Mục Tiêu (Goal)
17
+ - Hoàn thành thành công tác vụ được giao liên quan đến nhiệm vụ của skill.
18
+ - Đảm bảo chất lượng mã nguồn và tính nhất quán của hệ thống.
19
+
20
+ ## 🔄 2. Chuỗi Hành Động (Chain of Thought / SOP)
21
+ *(Bắt buộc AI phải suy nghĩ và làm theo đúng thứ tự)*
22
+ 1. **Phân tích (Analyze):** Thu thập ngữ cảnh và hiểu rõ yêu cầu đầu vào.
23
+ 2. **Lên kế hoạch (Plan):** Xác định các bước cần thay đổi/tạo mới dựa trên bộ luật (rules).
24
+ 3. **Thực thi (Execute):** Tiến hành sửa đổi mã nguồn hoặc tạo tài liệu.
25
+ 4. **Xác thực (Verify):** Đảm bảo đầu ra đáp ứng đúng yêu cầu và không vi phạm quy định.
26
+
27
+ ## 🛡️ 3. Ràng Buộc & Quy Tắc (Constraints)
28
+ - CẤM bỏ qua việc kiểm tra `qk-engineering-standard` trước khi viết code.
29
+ - Mọi quyết định kỹ thuật phải dựa trên nội dung tại phần Deep Knowledge (nếu có).
30
+
31
+ ## 🤝 4. Giao Thức Bàn Giao (Handoff Protocol)
32
+ - Đích đến: `none`
33
+ - Nội dung bàn giao: Chuyển toàn bộ ngữ cảnh và kết quả đã thực thi cho bước tiếp theo.