ai-engineering-init 1.1.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.
- package/.claude/agents/code-reviewer.md +139 -0
- package/.claude/agents/project-manager.md +159 -0
- package/.claude/audio/completed.wav +0 -0
- package/.claude/commands/add-todo.md +255 -0
- package/.claude/commands/check.md +210 -0
- package/.claude/commands/crud.md +454 -0
- package/.claude/commands/dev.md +503 -0
- package/.claude/commands/init-docs.md +681 -0
- package/.claude/commands/next.md +251 -0
- package/.claude/commands/progress.md +242 -0
- package/.claude/commands/start.md +199 -0
- package/.claude/commands/sync.md +307 -0
- package/.claude/commands/update-status.md +428 -0
- package/.claude/docs/Mixin/344/275/277/347/224/250/346/214/207/345/215/227.md +299 -0
- package/.claude/docs/README.md +167 -0
- package/.claude/docs//345/211/215/347/253/257/345/274/200/345/217/221/346/214/207/345/215/227.md +599 -0
- package/.claude/docs//345/220/216/347/253/257/345/274/200/345/217/221/346/214/207/345/215/227.md +726 -0
- package/.claude/docs//345/267/245/344/275/234/346/265/201/345/274/200/345/217/221/346/214/207/345/215/227.md +714 -0
- package/.claude/docs//345/267/245/345/205/267/347/261/273/344/275/277/347/224/250/346/214/207/345/215/227.md +463 -0
- package/.claude/docs//346/225/260/346/215/256/345/272/223/350/256/276/350/256/241/350/247/204/350/214/203.md +390 -0
- package/.claude/docs//346/226/260/345/212/237/350/203/275/345/274/200/345/217/221/346/265/201/347/250/213/350/247/204/350/214/203.md +688 -0
- package/.claude/docs//346/226/260/351/241/271/347/233/256/345/274/200/345/217/221/346/265/201/347/250/213.md +365 -0
- package/.claude/docs//346/241/206/346/236/266/350/257/264/346/230/216.md +393 -0
- package/.claude/docs//350/267/257/347/224/261/351/205/215/347/275/256/346/214/207/345/215/227.md +246 -0
- package/.claude/framework-config.json +73 -0
- package/.claude/hooks/pre-tool-use.js +117 -0
- package/.claude/hooks/skill-forced-eval.js +167 -0
- package/.claude/hooks/stop.js +58 -0
- package/.claude/settings.json +41 -0
- package/.claude/skills/add-skill/SKILL.md +352 -0
- package/.claude/skills/api-development/SKILL.md +560 -0
- package/.claude/skills/architecture-design/SKILL.md +756 -0
- package/.claude/skills/backend-annotations/SKILL.md +674 -0
- package/.claude/skills/banana-image/CHANGELOG.md +37 -0
- package/.claude/skills/banana-image/README.md +146 -0
- package/.claude/skills/banana-image/SKILL.md +164 -0
- package/.claude/skills/banana-image/assets/logo.png +0 -0
- package/.claude/skills/banana-image/references/advanced-usage.md +189 -0
- package/.claude/skills/banana-image/scripts/apply_template.py +125 -0
- package/.claude/skills/banana-image/scripts/banana_image_exec.ts +412 -0
- package/.claude/skills/banana-image/scripts/batch_prep.py +82 -0
- package/.claude/skills/banana-image/scripts/package-lock.json +1437 -0
- package/.claude/skills/banana-image/scripts/package.json +18 -0
- package/.claude/skills/banana-image/scripts/requirements.txt +10 -0
- package/.claude/skills/banana-image/templates/poster.json +22 -0
- package/.claude/skills/banana-image/templates/product.json +17 -0
- package/.claude/skills/banana-image/templates/social.json +22 -0
- package/.claude/skills/banana-image/templates/thumbnail.json +17 -0
- package/.claude/skills/brainstorm/SKILL.md +648 -0
- package/.claude/skills/bug-detective/SKILL.md +1206 -0
- package/.claude/skills/code-patterns/SKILL.md +590 -0
- package/.claude/skills/collaborating-with-codex/SKILL.md +174 -0
- package/.claude/skills/collaborating-with-codex/scripts/codex_bridge.py +275 -0
- package/.claude/skills/collaborating-with-gemini/SKILL.md +194 -0
- package/.claude/skills/collaborating-with-gemini/scripts/gemini_bridge.py +275 -0
- package/.claude/skills/crud-development/SKILL.md +649 -0
- package/.claude/skills/data-permission/SKILL.md +599 -0
- package/.claude/skills/database-ops/SKILL.md +407 -0
- package/.claude/skills/error-handler/SKILL.md +371 -0
- package/.claude/skills/file-oss-management/SKILL.md +863 -0
- package/.claude/skills/git-workflow/SKILL.md +375 -0
- package/.claude/skills/json-serialization/SKILL.md +357 -0
- package/.claude/skills/leniu-api-development/SKILL.md +803 -0
- package/.claude/skills/leniu-architecture-design/SKILL.md +598 -0
- package/.claude/skills/leniu-backend-annotations/SKILL.md +664 -0
- package/.claude/skills/leniu-code-patterns/SKILL.md +365 -0
- package/.claude/skills/leniu-crud-development/SKILL.md +1110 -0
- package/.claude/skills/leniu-data-permission/SKILL.md +256 -0
- package/.claude/skills/leniu-database-ops/SKILL.md +426 -0
- package/.claude/skills/leniu-error-handler/SKILL.md +462 -0
- package/.claude/skills/leniu-java-amount-handling/SKILL.md +461 -0
- package/.claude/skills/leniu-java-code-style/SKILL.md +510 -0
- package/.claude/skills/leniu-java-concurrent/SKILL.md +400 -0
- package/.claude/skills/leniu-java-entity/SKILL.md +751 -0
- package/.claude/skills/leniu-java-export/SKILL.md +560 -0
- package/.claude/skills/leniu-java-logging/SKILL.md +832 -0
- package/.claude/skills/leniu-java-mq/SKILL.md +338 -0
- package/.claude/skills/leniu-java-mybatis/SKILL.md +640 -0
- package/.claude/skills/leniu-java-report-query-param/SKILL.md +291 -0
- package/.claude/skills/leniu-java-task/SKILL.md +367 -0
- package/.claude/skills/leniu-java-total-line/SKILL.md +195 -0
- package/.claude/skills/leniu-marketing-price-rule-customizer/SKILL.md +301 -0
- package/.claude/skills/leniu-marketing-recharge-rule-customizer/SKILL.md +285 -0
- package/.claude/skills/leniu-mealtime/SKILL.md +215 -0
- package/.claude/skills/leniu-redis-cache/SKILL.md +316 -0
- package/.claude/skills/leniu-security-guard/SKILL.md +520 -0
- package/.claude/skills/leniu-utils-toolkit/SKILL.md +380 -0
- package/.claude/skills/openspec-apply-change/SKILL.md +156 -0
- package/.claude/skills/openspec-archive-change/SKILL.md +114 -0
- package/.claude/skills/openspec-bulk-archive-change/SKILL.md +246 -0
- package/.claude/skills/openspec-continue-change/SKILL.md +118 -0
- package/.claude/skills/openspec-explore/SKILL.md +290 -0
- package/.claude/skills/openspec-ff-change/SKILL.md +101 -0
- package/.claude/skills/openspec-new-change/SKILL.md +74 -0
- package/.claude/skills/openspec-onboard/SKILL.md +529 -0
- package/.claude/skills/openspec-sync-specs/SKILL.md +138 -0
- package/.claude/skills/openspec-verify-change/SKILL.md +168 -0
- package/.claude/skills/performance-doctor/SKILL.md +627 -0
- package/.claude/skills/project-navigator/SKILL.md +305 -0
- package/.claude/skills/redis-cache/SKILL.md +839 -0
- package/.claude/skills/scheduled-jobs/SKILL.md +633 -0
- package/.claude/skills/security-guard/SKILL.md +748 -0
- package/.claude/skills/sms-mail/SKILL.md +766 -0
- package/.claude/skills/social-login/SKILL.md +668 -0
- package/.claude/skills/store-pc/SKILL.md +366 -0
- package/.claude/skills/task-tracker/SKILL.md +307 -0
- package/.claude/skills/tech-decision/SKILL.md +393 -0
- package/.claude/skills/tenant-management/SKILL.md +603 -0
- package/.claude/skills/test-development/SKILL.md +755 -0
- package/.claude/skills/ui-pc/SKILL.md +438 -0
- package/.claude/skills/utils-toolkit/SKILL.md +615 -0
- package/.claude/skills/websocket-sse/SKILL.md +716 -0
- package/.claude/skills/workflow-engine/SKILL.md +676 -0
- package/.claude/templates//345/276/205/345/212/236/346/270/205/345/215/225/346/250/241/346/235/277.md +56 -0
- package/.claude/templates//351/234/200/346/261/202/346/226/207/346/241/243/346/250/241/346/235/277.md +85 -0
- package/.claude/templates//351/241/271/347/233/256/347/212/266/346/200/201/346/250/241/346/235/277.md +43 -0
- package/.codex/skills/add-skill/SKILL.md +352 -0
- package/.codex/skills/add-todo/SKILL.md +269 -0
- package/.codex/skills/api-development/SKILL.md +693 -0
- package/.codex/skills/architecture-design/SKILL.md +628 -0
- package/.codex/skills/backend-annotations/SKILL.md +664 -0
- package/.codex/skills/banana-image/CHANGELOG.md +37 -0
- package/.codex/skills/banana-image/README.md +146 -0
- package/.codex/skills/banana-image/SKILL.md +164 -0
- package/.codex/skills/banana-image/assets/logo.png +0 -0
- package/.codex/skills/banana-image/references/advanced-usage.md +189 -0
- package/.codex/skills/banana-image/scripts/apply_template.py +125 -0
- package/.codex/skills/banana-image/scripts/banana_image_exec.ts +412 -0
- package/.codex/skills/banana-image/scripts/batch_prep.py +82 -0
- package/.codex/skills/banana-image/scripts/package-lock.json +1437 -0
- package/.codex/skills/banana-image/scripts/package.json +18 -0
- package/.codex/skills/banana-image/scripts/requirements.txt +10 -0
- package/.codex/skills/banana-image/templates/poster.json +22 -0
- package/.codex/skills/banana-image/templates/product.json +17 -0
- package/.codex/skills/banana-image/templates/social.json +22 -0
- package/.codex/skills/banana-image/templates/thumbnail.json +17 -0
- package/.codex/skills/brainstorm/SKILL.md +648 -0
- package/.codex/skills/bug-detective/SKILL.md +1206 -0
- package/.codex/skills/check/SKILL.md +367 -0
- package/.codex/skills/code-patterns/SKILL.md +442 -0
- package/.codex/skills/collaborating-with-codex/SKILL.md +174 -0
- package/.codex/skills/collaborating-with-codex/scripts/codex_bridge.py +275 -0
- package/.codex/skills/collaborating-with-gemini/SKILL.md +194 -0
- package/.codex/skills/collaborating-with-gemini/scripts/gemini_bridge.py +275 -0
- package/.codex/skills/crud/SKILL.md +265 -0
- package/.codex/skills/crud-development/SKILL.md +637 -0
- package/.codex/skills/data-permission/SKILL.md +591 -0
- package/.codex/skills/database-ops/SKILL.md +553 -0
- package/.codex/skills/dev/SKILL.md +187 -0
- package/.codex/skills/error-handler/SKILL.md +361 -0
- package/.codex/skills/file-oss-management/SKILL.md +863 -0
- package/.codex/skills/git-workflow/SKILL.md +375 -0
- package/.codex/skills/init-docs/SKILL.md +194 -0
- package/.codex/skills/json-serialization/SKILL.md +357 -0
- package/.codex/skills/leniu-api-development/SKILL.md +803 -0
- package/.codex/skills/leniu-architecture-design/SKILL.md +594 -0
- package/.codex/skills/leniu-backend-annotations/SKILL.md +662 -0
- package/.codex/skills/leniu-code-patterns/SKILL.md +365 -0
- package/.codex/skills/leniu-crud-development/SKILL.md +1110 -0
- package/.codex/skills/leniu-data-permission/SKILL.md +256 -0
- package/.codex/skills/leniu-database-ops/SKILL.md +426 -0
- package/.codex/skills/leniu-error-handler/SKILL.md +462 -0
- package/.codex/skills/leniu-java-amount-handling/SKILL.md +461 -0
- package/.codex/skills/leniu-java-code-style/SKILL.md +510 -0
- package/.codex/skills/leniu-java-concurrent/SKILL.md +400 -0
- package/.codex/skills/leniu-java-entity/SKILL.md +751 -0
- package/.codex/skills/leniu-java-export/SKILL.md +560 -0
- package/.codex/skills/leniu-java-logging/SKILL.md +832 -0
- package/.codex/skills/leniu-java-mq/SKILL.md +338 -0
- package/.codex/skills/leniu-java-mybatis/SKILL.md +640 -0
- package/.codex/skills/leniu-java-report-query-param/SKILL.md +291 -0
- package/.codex/skills/leniu-java-task/SKILL.md +367 -0
- package/.codex/skills/leniu-java-total-line/SKILL.md +195 -0
- package/.codex/skills/leniu-marketing-price-rule-customizer/SKILL.md +301 -0
- package/.codex/skills/leniu-marketing-recharge-rule-customizer/SKILL.md +285 -0
- package/.codex/skills/leniu-mealtime/SKILL.md +215 -0
- package/.codex/skills/leniu-redis-cache/SKILL.md +316 -0
- package/.codex/skills/leniu-security-guard/SKILL.md +520 -0
- package/.codex/skills/leniu-utils-toolkit/SKILL.md +378 -0
- package/.codex/skills/next/SKILL.md +137 -0
- package/.codex/skills/openspec-apply-change/SKILL.md +156 -0
- package/.codex/skills/openspec-archive-change/SKILL.md +114 -0
- package/.codex/skills/openspec-bulk-archive-change/SKILL.md +246 -0
- package/.codex/skills/openspec-continue-change/SKILL.md +118 -0
- package/.codex/skills/openspec-explore/SKILL.md +290 -0
- package/.codex/skills/openspec-ff-change/SKILL.md +101 -0
- package/.codex/skills/openspec-new-change/SKILL.md +74 -0
- package/.codex/skills/openspec-onboard/SKILL.md +529 -0
- package/.codex/skills/openspec-sync-specs/SKILL.md +138 -0
- package/.codex/skills/openspec-verify-change/SKILL.md +168 -0
- package/.codex/skills/performance-doctor/SKILL.md +627 -0
- package/.codex/skills/progress/SKILL.md +193 -0
- package/.codex/skills/project-navigator/SKILL.md +286 -0
- package/.codex/skills/redis-cache/SKILL.md +829 -0
- package/.codex/skills/scheduled-jobs/SKILL.md +633 -0
- package/.codex/skills/security-guard/SKILL.md +739 -0
- package/.codex/skills/sms-mail/SKILL.md +766 -0
- package/.codex/skills/social-login/SKILL.md +668 -0
- package/.codex/skills/start/SKILL.md +154 -0
- package/.codex/skills/store-pc/SKILL.md +491 -0
- package/.codex/skills/sync/SKILL.md +149 -0
- package/.codex/skills/task-tracker/SKILL.md +307 -0
- package/.codex/skills/tech-decision/SKILL.md +393 -0
- package/.codex/skills/tenant-management/SKILL.md +603 -0
- package/.codex/skills/test-development/SKILL.md +755 -0
- package/.codex/skills/ui-pc/SKILL.md +475 -0
- package/.codex/skills/update-status/SKILL.md +159 -0
- package/.codex/skills/utils-toolkit/SKILL.md +593 -0
- package/.codex/skills/websocket-sse/SKILL.md +716 -0
- package/.codex/skills/workflow-engine/SKILL.md +676 -0
- package/.cursor/agents/code-reviewer.md +139 -0
- package/.cursor/agents/project-manager.md +159 -0
- package/.cursor/commands/opsx-apply.md +152 -0
- package/.cursor/commands/opsx-archive.md +157 -0
- package/.cursor/commands/opsx-bulk-archive.md +242 -0
- package/.cursor/commands/opsx-continue.md +114 -0
- package/.cursor/commands/opsx-explore.md +174 -0
- package/.cursor/commands/opsx-ff.md +94 -0
- package/.cursor/commands/opsx-new.md +69 -0
- package/.cursor/commands/opsx-onboard.md +525 -0
- package/.cursor/commands/opsx-sync.md +134 -0
- package/.cursor/commands/opsx-verify.md +164 -0
- package/.cursor/mcp.json +22 -0
- package/.cursor/skills/add-skill/SKILL.md +352 -0
- package/.cursor/skills/api-development/SKILL.md +560 -0
- package/.cursor/skills/architecture-design/SKILL.md +756 -0
- package/.cursor/skills/backend-annotations/SKILL.md +674 -0
- package/.cursor/skills/banana-image/CHANGELOG.md +37 -0
- package/.cursor/skills/banana-image/README.md +146 -0
- package/.cursor/skills/banana-image/SKILL.md +164 -0
- package/.cursor/skills/banana-image/assets/logo.png +0 -0
- package/.cursor/skills/banana-image/references/advanced-usage.md +189 -0
- package/.cursor/skills/banana-image/scripts/apply_template.py +125 -0
- package/.cursor/skills/banana-image/scripts/banana_image_exec.ts +412 -0
- package/.cursor/skills/banana-image/scripts/batch_prep.py +82 -0
- package/.cursor/skills/banana-image/scripts/package-lock.json +1437 -0
- package/.cursor/skills/banana-image/scripts/package.json +18 -0
- package/.cursor/skills/banana-image/scripts/requirements.txt +10 -0
- package/.cursor/skills/banana-image/templates/poster.json +22 -0
- package/.cursor/skills/banana-image/templates/product.json +17 -0
- package/.cursor/skills/banana-image/templates/social.json +22 -0
- package/.cursor/skills/banana-image/templates/thumbnail.json +17 -0
- package/.cursor/skills/brainstorm/SKILL.md +648 -0
- package/.cursor/skills/bug-detective/SKILL.md +1206 -0
- package/.cursor/skills/code-patterns/SKILL.md +590 -0
- package/.cursor/skills/collaborating-with-codex/SKILL.md +174 -0
- package/.cursor/skills/collaborating-with-codex/scripts/codex_bridge.py +275 -0
- package/.cursor/skills/collaborating-with-gemini/SKILL.md +194 -0
- package/.cursor/skills/collaborating-with-gemini/scripts/gemini_bridge.py +275 -0
- package/.cursor/skills/crud-development/SKILL.md +649 -0
- package/.cursor/skills/data-permission/SKILL.md +599 -0
- package/.cursor/skills/database-ops/SKILL.md +407 -0
- package/.cursor/skills/error-handler/SKILL.md +371 -0
- package/.cursor/skills/file-oss-management/SKILL.md +863 -0
- package/.cursor/skills/git-workflow/SKILL.md +375 -0
- package/.cursor/skills/json-serialization/SKILL.md +357 -0
- package/.cursor/skills/leniu-api-development/SKILL.md +803 -0
- package/.cursor/skills/leniu-architecture-design/SKILL.md +598 -0
- package/.cursor/skills/leniu-backend-annotations/SKILL.md +664 -0
- package/.cursor/skills/leniu-code-patterns/SKILL.md +365 -0
- package/.cursor/skills/leniu-crud-development/SKILL.md +1110 -0
- package/.cursor/skills/leniu-data-permission/SKILL.md +256 -0
- package/.cursor/skills/leniu-database-ops/SKILL.md +426 -0
- package/.cursor/skills/leniu-error-handler/SKILL.md +462 -0
- package/.cursor/skills/leniu-java-amount-handling/SKILL.md +461 -0
- package/.cursor/skills/leniu-java-code-style/SKILL.md +510 -0
- package/.cursor/skills/leniu-java-concurrent/SKILL.md +400 -0
- package/.cursor/skills/leniu-java-entity/SKILL.md +751 -0
- package/.cursor/skills/leniu-java-export/SKILL.md +560 -0
- package/.cursor/skills/leniu-java-logging/SKILL.md +832 -0
- package/.cursor/skills/leniu-java-mq/SKILL.md +338 -0
- package/.cursor/skills/leniu-java-mybatis/SKILL.md +640 -0
- package/.cursor/skills/leniu-java-report-query-param/SKILL.md +291 -0
- package/.cursor/skills/leniu-java-task/SKILL.md +367 -0
- package/.cursor/skills/leniu-java-total-line/SKILL.md +195 -0
- package/.cursor/skills/leniu-marketing-price-rule-customizer/SKILL.md +301 -0
- package/.cursor/skills/leniu-marketing-recharge-rule-customizer/SKILL.md +285 -0
- package/.cursor/skills/leniu-mealtime/SKILL.md +215 -0
- package/.cursor/skills/leniu-redis-cache/SKILL.md +316 -0
- package/.cursor/skills/leniu-security-guard/SKILL.md +520 -0
- package/.cursor/skills/leniu-utils-toolkit/SKILL.md +380 -0
- package/.cursor/skills/openspec-apply-change/SKILL.md +156 -0
- package/.cursor/skills/openspec-archive-change/SKILL.md +114 -0
- package/.cursor/skills/openspec-bulk-archive-change/SKILL.md +246 -0
- package/.cursor/skills/openspec-continue-change/SKILL.md +118 -0
- package/.cursor/skills/openspec-explore/SKILL.md +290 -0
- package/.cursor/skills/openspec-ff-change/SKILL.md +101 -0
- package/.cursor/skills/openspec-new-change/SKILL.md +74 -0
- package/.cursor/skills/openspec-onboard/SKILL.md +529 -0
- package/.cursor/skills/openspec-sync-specs/SKILL.md +138 -0
- package/.cursor/skills/openspec-verify-change/SKILL.md +168 -0
- package/.cursor/skills/performance-doctor/SKILL.md +627 -0
- package/.cursor/skills/project-navigator/SKILL.md +305 -0
- package/.cursor/skills/redis-cache/SKILL.md +839 -0
- package/.cursor/skills/scheduled-jobs/SKILL.md +633 -0
- package/.cursor/skills/security-guard/SKILL.md +748 -0
- package/.cursor/skills/sms-mail/SKILL.md +766 -0
- package/.cursor/skills/social-login/SKILL.md +668 -0
- package/.cursor/skills/store-pc/SKILL.md +366 -0
- package/.cursor/skills/task-tracker/SKILL.md +307 -0
- package/.cursor/skills/tech-decision/SKILL.md +393 -0
- package/.cursor/skills/tenant-management/SKILL.md +603 -0
- package/.cursor/skills/test-development/SKILL.md +755 -0
- package/.cursor/skills/ui-pc/SKILL.md +438 -0
- package/.cursor/skills/utils-toolkit/SKILL.md +615 -0
- package/.cursor/skills/websocket-sse/SKILL.md +716 -0
- package/.cursor/skills/workflow-engine/SKILL.md +676 -0
- package/AGENTS.md +669 -0
- package/CLAUDE.md +205 -0
- package/README.md +205 -0
- package/bin/index.js +179 -0
- package/init.sh +178 -0
- package/package.json +27 -0
|
@@ -0,0 +1,352 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: add-skill
|
|
3
|
+
description: |
|
|
4
|
+
当需要为框架增加新技能、为新的模块功能编写技能文档时自动使用此 Skill。
|
|
5
|
+
|
|
6
|
+
触发场景:
|
|
7
|
+
- 需要为新模块添加技能
|
|
8
|
+
- 需要为新功能编写技能文档
|
|
9
|
+
- 需要扩展框架的技能系统
|
|
10
|
+
- 需要将实现步骤转化为可复用技能
|
|
11
|
+
|
|
12
|
+
触发词:添加技能、创建技能、新技能、技能开发、写技能、技能文档、skill 创建
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# 技能创建指南
|
|
16
|
+
|
|
17
|
+
## 概述
|
|
18
|
+
|
|
19
|
+
本指南用于在 RuoYi-Vue-Plus 框架中添加新的技能(Skill)。技能通过 UserPromptSubmit Hook 自动评估和激活,确保 AI 在编码前加载领域专业知识。
|
|
20
|
+
|
|
21
|
+
**技能系统工作原理**:
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
用户提交问题
|
|
25
|
+
↓ skill-forced-eval.js Hook 触发
|
|
26
|
+
注入技能评估指令
|
|
27
|
+
↓ AI 评估匹配的技能
|
|
28
|
+
逐个调用 Skill(技能名)
|
|
29
|
+
↓ 读取 .claude/skills/{技能名}/SKILL.md
|
|
30
|
+
AI 获得领域知识后开始实现
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
## YAML 头部规范
|
|
36
|
+
|
|
37
|
+
每个 SKILL.md 文件**必须**以 YAML 头部开始:
|
|
38
|
+
|
|
39
|
+
```yaml
|
|
40
|
+
---
|
|
41
|
+
name: {技能名称}
|
|
42
|
+
description: |
|
|
43
|
+
{第一行:简短描述(一句话说明技能用途或定位)}
|
|
44
|
+
|
|
45
|
+
触发场景:
|
|
46
|
+
- {场景1}
|
|
47
|
+
- {场景2}
|
|
48
|
+
- {场景3}
|
|
49
|
+
(至少3个场景)
|
|
50
|
+
|
|
51
|
+
触发词:{关键词1}、{关键词2}、{关键词3}、{关键词4}、{关键词5}
|
|
52
|
+
(至少5个触发词,用中文顿号分隔)
|
|
53
|
+
---
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### name 字段规范
|
|
57
|
+
|
|
58
|
+
| 规则 | 说明 | 示例 |
|
|
59
|
+
|------|------|------|
|
|
60
|
+
| **格式** | kebab-case(全小写,横线连接) | `json-serialization` |
|
|
61
|
+
| **禁止** | 下划线、驼峰、空格 | ~~`json_serialization`~~, ~~`jsonSerialization`~~ |
|
|
62
|
+
| **长度** | 1-4 个单词 | `ui-pc`, `crud-development`, `redis-cache` |
|
|
63
|
+
|
|
64
|
+
### description 第一行风格
|
|
65
|
+
|
|
66
|
+
第一行没有强制格式,参考现有技能的两种常见风格:
|
|
67
|
+
|
|
68
|
+
**风格 A:直述型**(多数技能采用)
|
|
69
|
+
```yaml
|
|
70
|
+
description: |
|
|
71
|
+
后端 CRUD 开发规范。基于 RuoYi-Vue-Plus 三层架构。
|
|
72
|
+
后端安全开发规范。包含 Sa-Token 认证授权、数据脱敏。
|
|
73
|
+
后端工具类使用指南。包含 MapstructUtils、StringUtils 等。
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
**风格 B:触发型**
|
|
77
|
+
```yaml
|
|
78
|
+
description: |
|
|
79
|
+
当需要进行技术选型、对比方案时自动使用此 Skill。
|
|
80
|
+
当需要为框架增加新技能时自动使用此 Skill。
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
### 实际技能 YAML 头部示例
|
|
84
|
+
|
|
85
|
+
```yaml
|
|
86
|
+
---
|
|
87
|
+
name: crud-development
|
|
88
|
+
description: |
|
|
89
|
+
后端 CRUD 开发规范。基于 RuoYi-Vue-Plus 三层架构(Controller → Service → Mapper),无独立 DAO 层。
|
|
90
|
+
|
|
91
|
+
触发场景:
|
|
92
|
+
- 新建业务模块的 CRUD 功能
|
|
93
|
+
- 创建 Entity、BO、VO、Service、Mapper、Controller
|
|
94
|
+
- 分页查询、新增、修改、删除、导出
|
|
95
|
+
- 查询条件构建(buildQueryWrapper)
|
|
96
|
+
|
|
97
|
+
触发词:CRUD、增删改查、新建模块、Entity、BO、VO、Service、Mapper、Controller、分页查询、buildQueryWrapper、@AutoMapper、BaseMapperPlus、TenantEntity
|
|
98
|
+
---
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
```yaml
|
|
102
|
+
---
|
|
103
|
+
name: redis-cache
|
|
104
|
+
description: |
|
|
105
|
+
当需要使用Redis缓存、分布式锁、限流等功能时自动使用此Skill。
|
|
106
|
+
|
|
107
|
+
触发场景:
|
|
108
|
+
- 使用Redis缓存数据
|
|
109
|
+
- 配置Spring Cache缓存注解
|
|
110
|
+
- 实现分布式锁
|
|
111
|
+
- 实现接口限流
|
|
112
|
+
|
|
113
|
+
触发词:Redis、缓存、Cache、@Cacheable、@CacheEvict、@CachePut、RedisUtils、CacheUtils、分布式锁、RLock、限流、RateLimiter
|
|
114
|
+
---
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
119
|
+
## 第 1 步:规划
|
|
120
|
+
|
|
121
|
+
### 1.1 定义技能属性
|
|
122
|
+
|
|
123
|
+
创建前先明确:
|
|
124
|
+
|
|
125
|
+
| 属性 | 说明 | 示例 |
|
|
126
|
+
|------|------|------|
|
|
127
|
+
| **名称** | kebab-case 格式 | `payment-gateway` |
|
|
128
|
+
| **类别** | 后端/通用/前端(需 plus-ui) | 后端 |
|
|
129
|
+
| **触发场景** | 至少 3 个具体场景 | 支付接入、退款处理、对账 |
|
|
130
|
+
| **触发词** | 至少 5 个关键词 | 支付、退款、订单、对账、Payment |
|
|
131
|
+
| **参考代码** | 项目中的真实代码位置 | `ruoyi-modules/ruoyi-system/` |
|
|
132
|
+
|
|
133
|
+
### 1.2 检查范围冲突
|
|
134
|
+
|
|
135
|
+
查看现有技能列表,确保不与已有技能重叠:
|
|
136
|
+
|
|
137
|
+
**当前已有技能**(`.claude/skills/` 下 33 个):
|
|
138
|
+
|
|
139
|
+
| 分类 | 技能 |
|
|
140
|
+
|------|------|
|
|
141
|
+
| 后端开发 | crud-development, api-development, database-ops, backend-annotations, utils-toolkit, error-handler |
|
|
142
|
+
| 安全权限 | security-guard, data-permission, tenant-management |
|
|
143
|
+
| 中间件 | redis-cache, json-serialization, scheduled-jobs, file-oss-management |
|
|
144
|
+
| 通信集成 | websocket-sse, sms-mail, social-login, workflow-engine |
|
|
145
|
+
| 质量保障 | test-development, bug-detective, performance-doctor, code-patterns |
|
|
146
|
+
| 架构决策 | architecture-design, tech-decision, brainstorm, project-navigator |
|
|
147
|
+
| 工具流程 | git-workflow, task-tracker, add-skill |
|
|
148
|
+
| 前端(需 plus-ui) | ui-pc, store-pc |
|
|
149
|
+
| 特殊功能 | banana-image, collaborating-with-codex, collaborating-with-gemini |
|
|
150
|
+
|
|
151
|
+
如果新技能与现有技能有交集,在 SKILL.md 中用"注意"段落说明边界:
|
|
152
|
+
```markdown
|
|
153
|
+
注意:如果是认证授权(登录、Token、Sa-Token),请使用 security-guard。
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
---
|
|
157
|
+
|
|
158
|
+
## 第 2 步:编写 SKILL.md
|
|
159
|
+
|
|
160
|
+
### 2.1 文件位置
|
|
161
|
+
|
|
162
|
+
```
|
|
163
|
+
.claude/skills/{技能名}/SKILL.md
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
### 2.2 推荐内容结构
|
|
167
|
+
|
|
168
|
+
```markdown
|
|
169
|
+
---
|
|
170
|
+
name: {技能名称}
|
|
171
|
+
description: |
|
|
172
|
+
{描述、触发场景、触发词}
|
|
173
|
+
---
|
|
174
|
+
|
|
175
|
+
# {技能标题}
|
|
176
|
+
|
|
177
|
+
## 概述
|
|
178
|
+
{简明介绍,1-2 段}
|
|
179
|
+
|
|
180
|
+
## 核心工具类/API
|
|
181
|
+
{主要类和方法列表}
|
|
182
|
+
|
|
183
|
+
## 使用规范
|
|
184
|
+
{最佳实践和规则}
|
|
185
|
+
|
|
186
|
+
## 代码示例
|
|
187
|
+
{真实代码片段}
|
|
188
|
+
|
|
189
|
+
## 常见错误
|
|
190
|
+
{正确做法 vs 错误做法对比}
|
|
191
|
+
|
|
192
|
+
## 注意
|
|
193
|
+
{与其他技能的边界说明}
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
### 2.3 内容质量要点
|
|
197
|
+
|
|
198
|
+
- **代码示例必须来自项目实际代码**,不要虚构类名、方法名
|
|
199
|
+
- **包名统一 `org.dromara.*`**,不要出现 `com.ruoyi.*`
|
|
200
|
+
- **三层架构**:Controller → Service → Mapper,无 DAO 层
|
|
201
|
+
- **对象转换用 `MapstructUtils.convert()`**,不要写 BeanUtils
|
|
202
|
+
- 技能不需要固定行数要求,以内容实用为准(实际范围 200-650 行)
|
|
203
|
+
|
|
204
|
+
### 2.4 不同类型技能的侧重
|
|
205
|
+
|
|
206
|
+
| 类型 | 侧重 | 示例 |
|
|
207
|
+
|------|------|------|
|
|
208
|
+
| 后端开发类 | 代码模板、标准写法、禁止项 | crud-development |
|
|
209
|
+
| 工具类 | API 列表、使用示例、返回值 | utils-toolkit |
|
|
210
|
+
| 中间件类 | 配置方法、集成步骤、注意事项 | redis-cache |
|
|
211
|
+
| 流程类 | 步骤说明、决策树、检查清单 | brainstorm |
|
|
212
|
+
|
|
213
|
+
---
|
|
214
|
+
|
|
215
|
+
## 第 3 步:注册技能
|
|
216
|
+
|
|
217
|
+
技能需要在两个位置注册,才能被系统识别和激活。
|
|
218
|
+
|
|
219
|
+
### 3.1 在 Hook 中注册
|
|
220
|
+
|
|
221
|
+
**文件**:`.claude/hooks/skill-forced-eval.js`
|
|
222
|
+
|
|
223
|
+
在 `可用技能(纯后端项目):` 列表中添加一行:
|
|
224
|
+
|
|
225
|
+
```javascript
|
|
226
|
+
- {技能名}: {触发词,用/分隔}
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
**示例**:
|
|
230
|
+
```javascript
|
|
231
|
+
- payment-gateway: 支付/退款/对账/Payment/支付宝/微信支付
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
**注意**:按逻辑分组插入,不是追加到末尾。
|
|
235
|
+
|
|
236
|
+
### 3.2 在 AGENTS.md 中注册
|
|
237
|
+
|
|
238
|
+
**文件**:`AGENTS.md` 的"技能清单与触发条件"表格
|
|
239
|
+
|
|
240
|
+
在对应分类下添加一行:
|
|
241
|
+
|
|
242
|
+
```markdown
|
|
243
|
+
| `{技能名}` | {触发条件简述} |
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
**示例**:
|
|
247
|
+
```markdown
|
|
248
|
+
| `payment-gateway` | 支付接入、退款、对账、支付宝/微信支付 |
|
|
249
|
+
```
|
|
250
|
+
|
|
251
|
+
### 3.3 验证注册
|
|
252
|
+
|
|
253
|
+
```bash
|
|
254
|
+
# 检查 hook 文件
|
|
255
|
+
grep "payment-gateway" .claude/hooks/skill-forced-eval.js
|
|
256
|
+
|
|
257
|
+
# 检查 AGENTS.md
|
|
258
|
+
grep "payment-gateway" AGENTS.md
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
---
|
|
262
|
+
|
|
263
|
+
## 第 4 步:Codex 同步
|
|
264
|
+
|
|
265
|
+
项目同时支持 Claude Code(`.claude/`)和 Codex CLI(`.codex/`)两个系统。
|
|
266
|
+
|
|
267
|
+
### 同步步骤
|
|
268
|
+
|
|
269
|
+
```bash
|
|
270
|
+
# 1. 创建 Codex 目录
|
|
271
|
+
mkdir -p .codex/skills/{技能名}
|
|
272
|
+
|
|
273
|
+
# 2. 复制文件
|
|
274
|
+
cp .claude/skills/{技能名}/SKILL.md .codex/skills/{技能名}/SKILL.md
|
|
275
|
+
|
|
276
|
+
# 3. 验证一致性
|
|
277
|
+
diff .claude/skills/{技能名}/SKILL.md .codex/skills/{技能名}/SKILL.md
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
**注意**:
|
|
281
|
+
- `.codex/skills/` 中额外存放斜杠命令型技能(如 dev, crud, check 等),这些不需要在 `.claude/` 中创建
|
|
282
|
+
- 普通技能(非斜杠命令)需要保持两个目录一致
|
|
283
|
+
|
|
284
|
+
---
|
|
285
|
+
|
|
286
|
+
## 第 5 步:验证
|
|
287
|
+
|
|
288
|
+
### 完整检查清单
|
|
289
|
+
|
|
290
|
+
**文件**:
|
|
291
|
+
- [ ] `.claude/skills/{技能名}/SKILL.md` 已创建
|
|
292
|
+
- [ ] `.codex/skills/{技能名}/SKILL.md` 已同步
|
|
293
|
+
|
|
294
|
+
**YAML 头部**:
|
|
295
|
+
- [ ] `name` 使用 kebab-case 格式
|
|
296
|
+
- [ ] description 包含触发场景(至少 3 个)
|
|
297
|
+
- [ ] description 包含触发词(至少 5 个)
|
|
298
|
+
- [ ] 各部分之间有空行
|
|
299
|
+
|
|
300
|
+
**注册**:
|
|
301
|
+
- [ ] `.claude/hooks/skill-forced-eval.js` 已添加技能条目
|
|
302
|
+
- [ ] `AGENTS.md` 已添加技能条目
|
|
303
|
+
|
|
304
|
+
**内容**:
|
|
305
|
+
- [ ] 代码示例来自项目实际代码,无虚构内容
|
|
306
|
+
- [ ] 包名使用 `org.dromara.*`
|
|
307
|
+
- [ ] 与现有技能无范围冲突(或已说明边界)
|
|
308
|
+
|
|
309
|
+
---
|
|
310
|
+
|
|
311
|
+
## 常见陷阱
|
|
312
|
+
|
|
313
|
+
### 1. 遗漏注册
|
|
314
|
+
|
|
315
|
+
**症状**:技能文件存在但从不被激活
|
|
316
|
+
|
|
317
|
+
**原因**:只创建了 SKILL.md,没有在 Hook 和 AGENTS.md 中注册
|
|
318
|
+
|
|
319
|
+
**解决**:完成第 3 步的两处注册
|
|
320
|
+
|
|
321
|
+
### 2. 触发词过于宽泛
|
|
322
|
+
|
|
323
|
+
**症状**:技能在不相关场景被频繁误触发
|
|
324
|
+
|
|
325
|
+
**原因**:触发词太通用(如"开发"、"功能")
|
|
326
|
+
|
|
327
|
+
**解决**:使用具体术语(如"CRUD开发"、"支付接入")
|
|
328
|
+
|
|
329
|
+
### 3. 代码示例虚构
|
|
330
|
+
|
|
331
|
+
**症状**:AI 参考技能生成的代码使用了不存在的类或方法
|
|
332
|
+
|
|
333
|
+
**原因**:编写技能时没有验证引用的类名、方法名在项目中真实存在
|
|
334
|
+
|
|
335
|
+
**解决**:编写前用 Grep/Glob 搜索确认引用的类和方法确实存在
|
|
336
|
+
|
|
337
|
+
### 4. 忘记同步到 Codex
|
|
338
|
+
|
|
339
|
+
**症状**:Claude Code 中正常,Codex CLI 中找不到技能
|
|
340
|
+
|
|
341
|
+
**原因**:只在 `.claude/skills/` 创建,未复制到 `.codex/skills/`
|
|
342
|
+
|
|
343
|
+
**解决**:`cp .claude/skills/{技能名}/SKILL.md .codex/skills/{技能名}/SKILL.md`
|
|
344
|
+
|
|
345
|
+
### 5. 技能范围与现有技能重叠
|
|
346
|
+
|
|
347
|
+
**症状**:同一个问题触发多个技能,指导矛盾
|
|
348
|
+
|
|
349
|
+
**解决**:在 SKILL.md 末尾添加"注意"段落说明边界,例如:
|
|
350
|
+
```
|
|
351
|
+
注意:如果是行级数据权限(@DataPermission),请使用 data-permission。
|
|
352
|
+
```
|