moai-adk 0.11.0__py3-none-any.whl → 0.12.1__py3-none-any.whl

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.

Potentially problematic release.


This version of moai-adk might be problematic. Click here for more details.

Files changed (265) hide show
  1. moai_adk/core/issue_creator.py +2 -2
  2. moai_adk/core/project/detector.py +285 -12
  3. moai_adk/templates/.claude/agents/alfred/cc-manager.md +316 -0
  4. moai_adk/templates/.claude/agents/alfred/debug-helper.md +208 -0
  5. moai_adk/templates/.claude/agents/alfred/doc-syncer.md +214 -0
  6. moai_adk/templates/.claude/agents/alfred/git-manager.md +406 -0
  7. moai_adk/templates/.claude/agents/alfred/implementation-planner.md +350 -0
  8. moai_adk/templates/.claude/agents/alfred/project-manager.md +273 -0
  9. moai_adk/templates/.claude/agents/alfred/quality-gate.md +343 -0
  10. moai_adk/templates/.claude/agents/alfred/skill-factory.md +865 -0
  11. moai_adk/templates/.claude/agents/alfred/spec-builder.md +287 -0
  12. moai_adk/templates/.claude/agents/alfred/tag-agent.md +287 -0
  13. moai_adk/templates/.claude/agents/alfred/tdd-implementer.md +326 -0
  14. moai_adk/templates/.claude/agents/alfred/trust-checker.md +375 -0
  15. moai_adk/templates/.claude/commands/alfred/0-project.md +1187 -0
  16. moai_adk/templates/.claude/commands/alfred/1-plan.md +734 -0
  17. moai_adk/templates/.claude/commands/alfred/2-run.md +551 -0
  18. moai_adk/templates/.claude/commands/alfred/3-sync.md +689 -0
  19. moai_adk/templates/.claude/commands/alfred/9-feedback.md +149 -0
  20. moai_adk/templates/.claude/hooks/alfred/alfred_hooks.py +208 -0
  21. moai_adk/templates/.claude/hooks/alfred/core/project.py +744 -0
  22. moai_adk/templates/.claude/hooks/alfred/core/timeout.py +136 -0
  23. moai_adk/templates/.claude/hooks/alfred/core/ttl_cache.py +109 -0
  24. moai_adk/templates/.claude/hooks/alfred/core/version_cache.py +198 -0
  25. moai_adk/templates/.claude/hooks/alfred/notification__handle_events.py +94 -0
  26. moai_adk/templates/.claude/hooks/alfred/post_tool__log_changes.py +94 -0
  27. moai_adk/templates/.claude/hooks/alfred/pre_tool__auto_checkpoint.py +100 -0
  28. moai_adk/templates/.claude/hooks/alfred/session_end__cleanup.py +94 -0
  29. moai_adk/templates/.claude/hooks/alfred/session_start__show_project_info.py +94 -0
  30. moai_adk/templates/.claude/hooks/alfred/shared/core/__init__.py +170 -0
  31. moai_adk/templates/.claude/hooks/alfred/shared/core/checkpoint.py +271 -0
  32. moai_adk/templates/.claude/hooks/alfred/shared/core/context.py +67 -0
  33. moai_adk/templates/.claude/hooks/alfred/shared/core/project.py +749 -0
  34. moai_adk/templates/.claude/hooks/alfred/shared/core/tags.py +230 -0
  35. moai_adk/templates/.claude/hooks/alfred/shared/core/version_cache.py +198 -0
  36. moai_adk/templates/.claude/hooks/alfred/shared/handlers/__init__.py +21 -0
  37. moai_adk/templates/.claude/hooks/alfred/shared/handlers/notification.py +156 -0
  38. moai_adk/templates/.claude/hooks/alfred/shared/handlers/session.py +174 -0
  39. moai_adk/templates/.claude/hooks/alfred/shared/handlers/tool.py +87 -0
  40. moai_adk/templates/.claude/hooks/alfred/shared/handlers/user.py +61 -0
  41. moai_adk/templates/.claude/hooks/alfred/stop__handle_interrupt.py +94 -0
  42. moai_adk/templates/.claude/hooks/alfred/subagent_stop__handle_subagent_end.py +94 -0
  43. moai_adk/templates/.claude/hooks/alfred/user_prompt__jit_load_docs.py +111 -0
  44. moai_adk/templates/.claude/hooks/alfred/utils/__init__.py +1 -0
  45. moai_adk/templates/.claude/hooks/alfred/utils/timeout.py +136 -0
  46. moai_adk/templates/.claude/output-styles/alfred/agentic-coding.md +640 -0
  47. moai_adk/templates/.claude/output-styles/alfred/moai-adk-learning.md +696 -0
  48. moai_adk/templates/.claude/output-styles/alfred/study-with-alfred.md +474 -0
  49. moai_adk/templates/.claude/settings.json +144 -0
  50. moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/SKILL.md +113 -0
  51. moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/examples.md +29 -0
  52. moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/reference.md +28 -0
  53. moai_adk/templates/.claude/skills/moai-alfred-git-workflow/SKILL.md +122 -0
  54. moai_adk/templates/.claude/skills/moai-alfred-git-workflow/examples.md +29 -0
  55. moai_adk/templates/.claude/skills/moai-alfred-git-workflow/reference.md +29 -0
  56. moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/SKILL.md +237 -0
  57. moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/examples.md +615 -0
  58. moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/reference.md +653 -0
  59. moai_adk/templates/.claude/skills/moai-alfred-language-detection/SKILL.md +113 -0
  60. moai_adk/templates/.claude/skills/moai-alfred-language-detection/examples.md +29 -0
  61. moai_adk/templates/.claude/skills/moai-alfred-language-detection/reference.md +28 -0
  62. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/SKILL.md +113 -0
  63. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/examples.md +29 -0
  64. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/reference.md +28 -0
  65. moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/SKILL.md +113 -0
  66. moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/examples.md +29 -0
  67. moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/reference.md +28 -0
  68. moai_adk/templates/.claude/skills/moai-alfred-trust-validation/SKILL.md +113 -0
  69. moai_adk/templates/.claude/skills/moai-alfred-trust-validation/examples.md +29 -0
  70. moai_adk/templates/.claude/skills/moai-alfred-trust-validation/reference.md +28 -0
  71. moai_adk/templates/.claude/skills/moai-cc-agents/SKILL.md +269 -0
  72. moai_adk/templates/.claude/skills/moai-cc-agents/templates/agent-template.md +32 -0
  73. moai_adk/templates/.claude/skills/moai-cc-claude-md/SKILL.md +298 -0
  74. moai_adk/templates/.claude/skills/moai-cc-claude-md/templates/CLAUDE-template.md +26 -0
  75. moai_adk/templates/.claude/skills/moai-cc-commands/SKILL.md +307 -0
  76. moai_adk/templates/.claude/skills/moai-cc-commands/templates/command-template.md +21 -0
  77. moai_adk/templates/.claude/skills/moai-cc-hooks/SKILL.md +252 -0
  78. moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/pre-bash-check.sh +19 -0
  79. moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/preserve-permissions.sh +19 -0
  80. moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/validate-bash-command.py +24 -0
  81. moai_adk/templates/.claude/skills/moai-cc-mcp-plugins/SKILL.md +199 -0
  82. moai_adk/templates/.claude/skills/moai-cc-mcp-plugins/templates/settings-mcp-template.json +39 -0
  83. moai_adk/templates/.claude/skills/moai-cc-memory/SKILL.md +316 -0
  84. moai_adk/templates/.claude/skills/moai-cc-memory/templates/session-summary-template.md +18 -0
  85. moai_adk/templates/.claude/skills/moai-cc-settings/SKILL.md +263 -0
  86. moai_adk/templates/.claude/skills/moai-cc-settings/templates/settings-complete-template.json +30 -0
  87. moai_adk/templates/.claude/skills/moai-cc-skills/SKILL.md +291 -0
  88. moai_adk/templates/.claude/skills/moai-cc-skills/templates/SKILL-template.md +15 -0
  89. moai_adk/templates/.claude/skills/moai-domain-backend/SKILL.md +290 -0
  90. moai_adk/templates/.claude/skills/moai-domain-backend/examples.md +1633 -0
  91. moai_adk/templates/.claude/skills/moai-domain-backend/reference.md +660 -0
  92. moai_adk/templates/.claude/skills/moai-domain-cli-tool/SKILL.md +123 -0
  93. moai_adk/templates/.claude/skills/moai-domain-cli-tool/examples.md +29 -0
  94. moai_adk/templates/.claude/skills/moai-domain-cli-tool/reference.md +30 -0
  95. moai_adk/templates/.claude/skills/moai-domain-data-science/SKILL.md +123 -0
  96. moai_adk/templates/.claude/skills/moai-domain-data-science/examples.md +29 -0
  97. moai_adk/templates/.claude/skills/moai-domain-data-science/reference.md +30 -0
  98. moai_adk/templates/.claude/skills/moai-domain-database/SKILL.md +123 -0
  99. moai_adk/templates/.claude/skills/moai-domain-database/examples.md +29 -0
  100. moai_adk/templates/.claude/skills/moai-domain-database/reference.md +30 -0
  101. moai_adk/templates/.claude/skills/moai-domain-devops/SKILL.md +124 -0
  102. moai_adk/templates/.claude/skills/moai-domain-devops/examples.md +29 -0
  103. moai_adk/templates/.claude/skills/moai-domain-devops/reference.md +31 -0
  104. moai_adk/templates/.claude/skills/moai-domain-frontend/SKILL.md +124 -0
  105. moai_adk/templates/.claude/skills/moai-domain-frontend/examples.md +29 -0
  106. moai_adk/templates/.claude/skills/moai-domain-frontend/reference.md +31 -0
  107. moai_adk/templates/.claude/skills/moai-domain-ml/SKILL.md +123 -0
  108. moai_adk/templates/.claude/skills/moai-domain-ml/examples.md +29 -0
  109. moai_adk/templates/.claude/skills/moai-domain-ml/reference.md +30 -0
  110. moai_adk/templates/.claude/skills/moai-domain-mobile-app/SKILL.md +123 -0
  111. moai_adk/templates/.claude/skills/moai-domain-mobile-app/examples.md +29 -0
  112. moai_adk/templates/.claude/skills/moai-domain-mobile-app/reference.md +30 -0
  113. moai_adk/templates/.claude/skills/moai-domain-security/SKILL.md +123 -0
  114. moai_adk/templates/.claude/skills/moai-domain-security/examples.md +29 -0
  115. moai_adk/templates/.claude/skills/moai-domain-security/reference.md +30 -0
  116. moai_adk/templates/.claude/skills/moai-domain-web-api/SKILL.md +123 -0
  117. moai_adk/templates/.claude/skills/moai-domain-web-api/examples.md +29 -0
  118. moai_adk/templates/.claude/skills/moai-domain-web-api/reference.md +30 -0
  119. moai_adk/templates/.claude/skills/moai-essentials-debug/SKILL.md +303 -0
  120. moai_adk/templates/.claude/skills/moai-essentials-debug/examples.md +1064 -0
  121. moai_adk/templates/.claude/skills/moai-essentials-debug/reference.md +1047 -0
  122. moai_adk/templates/.claude/skills/moai-essentials-perf/SKILL.md +113 -0
  123. moai_adk/templates/.claude/skills/moai-essentials-perf/examples.md +29 -0
  124. moai_adk/templates/.claude/skills/moai-essentials-perf/reference.md +28 -0
  125. moai_adk/templates/.claude/skills/moai-essentials-refactor/SKILL.md +113 -0
  126. moai_adk/templates/.claude/skills/moai-essentials-refactor/examples.md +29 -0
  127. moai_adk/templates/.claude/skills/moai-essentials-refactor/reference.md +28 -0
  128. moai_adk/templates/.claude/skills/moai-essentials-review/SKILL.md +113 -0
  129. moai_adk/templates/.claude/skills/moai-essentials-review/examples.md +29 -0
  130. moai_adk/templates/.claude/skills/moai-essentials-review/reference.md +28 -0
  131. moai_adk/templates/.claude/skills/moai-foundation-ears/SKILL.md +116 -0
  132. moai_adk/templates/.claude/skills/moai-foundation-ears/examples.md +29 -0
  133. moai_adk/templates/.claude/skills/moai-foundation-ears/reference.md +28 -0
  134. moai_adk/templates/.claude/skills/moai-foundation-git/SKILL.md +122 -0
  135. moai_adk/templates/.claude/skills/moai-foundation-git/examples.md +29 -0
  136. moai_adk/templates/.claude/skills/moai-foundation-git/reference.md +29 -0
  137. moai_adk/templates/.claude/skills/moai-foundation-langs/SKILL.md +113 -0
  138. moai_adk/templates/.claude/skills/moai-foundation-langs/examples.md +29 -0
  139. moai_adk/templates/.claude/skills/moai-foundation-langs/reference.md +28 -0
  140. moai_adk/templates/.claude/skills/moai-foundation-specs/SKILL.md +113 -0
  141. moai_adk/templates/.claude/skills/moai-foundation-specs/examples.md +29 -0
  142. moai_adk/templates/.claude/skills/moai-foundation-specs/reference.md +28 -0
  143. moai_adk/templates/.claude/skills/moai-foundation-tags/SKILL.md +113 -0
  144. moai_adk/templates/.claude/skills/moai-foundation-tags/examples.md +29 -0
  145. moai_adk/templates/.claude/skills/moai-foundation-tags/reference.md +28 -0
  146. moai_adk/templates/.claude/skills/moai-foundation-trust/SKILL.md +307 -0
  147. moai_adk/templates/.claude/skills/moai-foundation-trust/examples.md +0 -0
  148. moai_adk/templates/.claude/skills/moai-foundation-trust/reference.md +1099 -0
  149. moai_adk/templates/.claude/skills/moai-lang-c/SKILL.md +124 -0
  150. moai_adk/templates/.claude/skills/moai-lang-c/examples.md +29 -0
  151. moai_adk/templates/.claude/skills/moai-lang-c/reference.md +31 -0
  152. moai_adk/templates/.claude/skills/moai-lang-cpp/SKILL.md +124 -0
  153. moai_adk/templates/.claude/skills/moai-lang-cpp/examples.md +29 -0
  154. moai_adk/templates/.claude/skills/moai-lang-cpp/reference.md +31 -0
  155. moai_adk/templates/.claude/skills/moai-lang-csharp/SKILL.md +123 -0
  156. moai_adk/templates/.claude/skills/moai-lang-csharp/examples.md +29 -0
  157. moai_adk/templates/.claude/skills/moai-lang-csharp/reference.md +30 -0
  158. moai_adk/templates/.claude/skills/moai-lang-dart/SKILL.md +123 -0
  159. moai_adk/templates/.claude/skills/moai-lang-dart/examples.md +29 -0
  160. moai_adk/templates/.claude/skills/moai-lang-dart/reference.md +30 -0
  161. moai_adk/templates/.claude/skills/moai-lang-go/SKILL.md +124 -0
  162. moai_adk/templates/.claude/skills/moai-lang-go/examples.md +29 -0
  163. moai_adk/templates/.claude/skills/moai-lang-go/reference.md +31 -0
  164. moai_adk/templates/.claude/skills/moai-lang-java/SKILL.md +124 -0
  165. moai_adk/templates/.claude/skills/moai-lang-java/examples.md +29 -0
  166. moai_adk/templates/.claude/skills/moai-lang-java/reference.md +31 -0
  167. moai_adk/templates/.claude/skills/moai-lang-javascript/SKILL.md +125 -0
  168. moai_adk/templates/.claude/skills/moai-lang-javascript/examples.md +29 -0
  169. moai_adk/templates/.claude/skills/moai-lang-javascript/reference.md +32 -0
  170. moai_adk/templates/.claude/skills/moai-lang-kotlin/SKILL.md +124 -0
  171. moai_adk/templates/.claude/skills/moai-lang-kotlin/examples.md +29 -0
  172. moai_adk/templates/.claude/skills/moai-lang-kotlin/reference.md +31 -0
  173. moai_adk/templates/.claude/skills/moai-lang-php/SKILL.md +123 -0
  174. moai_adk/templates/.claude/skills/moai-lang-php/examples.md +29 -0
  175. moai_adk/templates/.claude/skills/moai-lang-php/reference.md +30 -0
  176. moai_adk/templates/.claude/skills/moai-lang-python/SKILL.md +431 -0
  177. moai_adk/templates/.claude/skills/moai-lang-python/examples.md +624 -0
  178. moai_adk/templates/.claude/skills/moai-lang-python/reference.md +316 -0
  179. moai_adk/templates/.claude/skills/moai-lang-r/SKILL.md +123 -0
  180. moai_adk/templates/.claude/skills/moai-lang-r/examples.md +29 -0
  181. moai_adk/templates/.claude/skills/moai-lang-r/reference.md +30 -0
  182. moai_adk/templates/.claude/skills/moai-lang-ruby/SKILL.md +124 -0
  183. moai_adk/templates/.claude/skills/moai-lang-ruby/examples.md +29 -0
  184. moai_adk/templates/.claude/skills/moai-lang-ruby/reference.md +31 -0
  185. moai_adk/templates/.claude/skills/moai-lang-rust/SKILL.md +124 -0
  186. moai_adk/templates/.claude/skills/moai-lang-rust/examples.md +29 -0
  187. moai_adk/templates/.claude/skills/moai-lang-rust/reference.md +31 -0
  188. moai_adk/templates/.claude/skills/moai-lang-scala/SKILL.md +123 -0
  189. moai_adk/templates/.claude/skills/moai-lang-scala/examples.md +29 -0
  190. moai_adk/templates/.claude/skills/moai-lang-scala/reference.md +30 -0
  191. moai_adk/templates/.claude/skills/moai-lang-shell/SKILL.md +123 -0
  192. moai_adk/templates/.claude/skills/moai-lang-shell/examples.md +29 -0
  193. moai_adk/templates/.claude/skills/moai-lang-shell/reference.md +30 -0
  194. moai_adk/templates/.claude/skills/moai-lang-sql/SKILL.md +124 -0
  195. moai_adk/templates/.claude/skills/moai-lang-sql/examples.md +29 -0
  196. moai_adk/templates/.claude/skills/moai-lang-sql/reference.md +31 -0
  197. moai_adk/templates/.claude/skills/moai-lang-swift/SKILL.md +123 -0
  198. moai_adk/templates/.claude/skills/moai-lang-swift/examples.md +29 -0
  199. moai_adk/templates/.claude/skills/moai-lang-swift/reference.md +30 -0
  200. moai_adk/templates/.claude/skills/moai-lang-typescript/SKILL.md +127 -0
  201. moai_adk/templates/.claude/skills/moai-lang-typescript/examples.md +29 -0
  202. moai_adk/templates/.claude/skills/moai-lang-typescript/reference.md +34 -0
  203. moai_adk/templates/.claude/skills/moai-skill-factory/CHECKLIST.md +482 -0
  204. moai_adk/templates/.claude/skills/moai-skill-factory/EXAMPLES.md +278 -0
  205. moai_adk/templates/.claude/skills/moai-skill-factory/INTERACTIVE-DISCOVERY.md +524 -0
  206. moai_adk/templates/.claude/skills/moai-skill-factory/METADATA.md +477 -0
  207. moai_adk/templates/.claude/skills/moai-skill-factory/PARALLEL-ANALYSIS-REPORT.md +429 -0
  208. moai_adk/templates/.claude/skills/moai-skill-factory/PYTHON-VERSION-MATRIX.md +391 -0
  209. moai_adk/templates/.claude/skills/moai-skill-factory/SKILL-FACTORY-WORKFLOW.md +431 -0
  210. moai_adk/templates/.claude/skills/moai-skill-factory/SKILL-UPDATE-ADVISOR.md +577 -0
  211. moai_adk/templates/.claude/skills/moai-skill-factory/SKILL.md +271 -0
  212. moai_adk/templates/.claude/skills/moai-skill-factory/STEP-BY-STEP-GUIDE.md +466 -0
  213. moai_adk/templates/.claude/skills/moai-skill-factory/STRUCTURE.md +583 -0
  214. moai_adk/templates/.claude/skills/moai-skill-factory/WEB-RESEARCH.md +526 -0
  215. moai_adk/templates/.claude/skills/moai-skill-factory/reference.md +465 -0
  216. moai_adk/templates/.claude/skills/moai-skill-factory/scripts/generate-structure.sh +328 -0
  217. moai_adk/templates/.claude/skills/moai-skill-factory/scripts/validate-skill.sh +312 -0
  218. moai_adk/templates/.claude/skills/moai-skill-factory/templates/SKILL_TEMPLATE.md +245 -0
  219. moai_adk/templates/.claude/skills/moai-skill-factory/templates/examples-template.md +285 -0
  220. moai_adk/templates/.claude/skills/moai-skill-factory/templates/reference-template.md +278 -0
  221. moai_adk/templates/.claude/skills/moai-skill-factory/templates/scripts-template.sh +303 -0
  222. moai_adk/templates/.claude/skills/moai-spec-authoring/README.md +137 -0
  223. moai_adk/templates/.claude/skills/moai-spec-authoring/SKILL.md +219 -0
  224. moai_adk/templates/.claude/skills/moai-spec-authoring/examples/validate-spec.sh +161 -0
  225. moai_adk/templates/.claude/skills/moai-spec-authoring/examples.md +541 -0
  226. moai_adk/templates/.claude/skills/moai-spec-authoring/reference.md +622 -0
  227. moai_adk/templates/.github/workflows/c-tag-validation.yml +83 -0
  228. moai_adk/templates/.github/workflows/cpp-tag-validation.yml +79 -0
  229. moai_adk/templates/.github/workflows/csharp-tag-validation.yml +65 -0
  230. moai_adk/templates/.github/workflows/dart-tag-validation.yml +82 -0
  231. moai_adk/templates/.github/workflows/java-tag-validation.yml +75 -0
  232. moai_adk/templates/.github/workflows/kotlin-tag-validation.yml +67 -0
  233. moai_adk/templates/.github/workflows/php-tag-validation.yml +56 -0
  234. moai_adk/templates/.github/workflows/ruby-tag-validation.yml +68 -0
  235. moai_adk/templates/.github/workflows/rust-tag-validation.yml +73 -0
  236. moai_adk/templates/.github/workflows/shell-tag-validation.yml +65 -0
  237. moai_adk/templates/.github/workflows/swift-tag-validation.yml +79 -0
  238. moai_adk/templates/.moai/config.json +113 -0
  239. moai_adk/templates/.moai/memory/CLAUDE-AGENTS-GUIDE.md +208 -0
  240. moai_adk/templates/.moai/memory/CLAUDE-PRACTICES.md +369 -0
  241. moai_adk/templates/.moai/memory/CLAUDE-RULES.md +539 -0
  242. moai_adk/templates/.moai/memory/DEVELOPMENT-GUIDE.md +344 -0
  243. moai_adk/templates/.moai/memory/GITFLOW-PROTECTION-POLICY.md +330 -0
  244. moai_adk/templates/.moai/memory/ISSUE-LABEL-MAPPING.md +150 -0
  245. moai_adk/templates/.moai/memory/SKILLS-DESCRIPTION-POLICY.md +218 -0
  246. moai_adk/templates/.moai/memory/SPEC-METADATA.md +356 -0
  247. moai_adk/templates/.moai/memory/gitflow-protection-policy.md +330 -0
  248. moai_adk/templates/.moai/memory/spec-metadata.md +356 -0
  249. moai_adk/templates/.moai/project/product.md +161 -0
  250. moai_adk/templates/.moai/project/structure.md +156 -0
  251. moai_adk/templates/.moai/project/tech.md +227 -0
  252. moai_adk/templates/CLAUDE.md +90 -10
  253. moai_adk/templates/workflows/go-tag-validation.yml +130 -0
  254. moai_adk/templates/workflows/javascript-tag-validation.yml +135 -0
  255. moai_adk/templates/workflows/python-tag-validation.yml +118 -0
  256. moai_adk/templates/workflows/typescript-tag-validation.yml +154 -0
  257. {moai_adk-0.11.0.dist-info → moai_adk-0.12.1.dist-info}/METADATA +43 -1
  258. moai_adk-0.12.1.dist-info/RECORD +330 -0
  259. moai_adk-0.11.0.dist-info/RECORD +0 -77
  260. /moai_adk/templates/.github/workflows/{release.yml → moai-adk-release.yml} +0 -0
  261. /moai_adk/templates/.github/workflows/{spec-issue-sync.yml → moai-adk-spec-issue-sync.yml} +0 -0
  262. /moai_adk/templates/.github/workflows/{tag-validation.yml → moai-adk-tag-validation.yml} +0 -0
  263. {moai_adk-0.11.0.dist-info → moai_adk-0.12.1.dist-info}/WHEEL +0 -0
  264. {moai_adk-0.11.0.dist-info → moai_adk-0.12.1.dist-info}/entry_points.txt +0 -0
  265. {moai_adk-0.11.0.dist-info → moai_adk-0.12.1.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,551 @@
1
+ ---
2
+ name: alfred:2-run
3
+ description: "Execute planned work (TDD implementation, prototyping, documentation, etc.)"
4
+ # Translations:
5
+ # - ko: "계획된 작업 실행 (TDD 구현, 프로토타이핑, 문서화 등)"
6
+ # - ja: "計画されたタスクの実行(TDD実装、プロトタイピング、ドキュメント作成など)"
7
+ # - zh: "执行计划任务(TDD实现、原型开发、文档编写等)"
8
+ argument-hint: "SPEC-ID - All with SPEC ID to implement (e.g. SPEC-001) or all \"SPEC Implementation\""
9
+ allowed-tools:
10
+ - Read
11
+ - Write
12
+ - Edit
13
+ - MultiEdit
14
+ - Bash(python3:*)
15
+ - Bash(pytest:*)
16
+ - Bash(npm:*)
17
+ - Bash(node:*)
18
+ - Bash(git:*)
19
+ - Task
20
+ - WebFetch
21
+ - Grep
22
+ - Glob
23
+ - TodoWrite
24
+ ---
25
+
26
+ # ⚒️ MoAI-ADK Phase 2: Run the plan - Flexible implementation strategy
27
+ > **Note**: Interactive prompts use `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)` for TUI selection menus. The skill is loaded on-demand when user interaction is required.
28
+ >
29
+ > **Batched Design**: All AskUserQuestion calls follow batched design principles (1-4 questions per call) to minimize user interaction turns. See CLAUDE.md section "Alfred Command Completion Pattern" for details.
30
+
31
+ <!-- @CODE:ALF-WORKFLOW-001:CMD-RUN -->
32
+
33
+ **4-Step Workflow Integration**: This command implements Step 3 of Alfred's workflow (Task Execution with TodoWrite tracking). See CLAUDE.md for full workflow details.
34
+
35
+ ## 🎯 Command Purpose
36
+
37
+ Analyze SPEC documents to execute planned tasks. It supports not only TDD implementation but also various execution scenarios such as prototyping and documentation work.
38
+
39
+ **Run on**: $ARGUMENTS
40
+
41
+ ## 💡 Execution philosophy: “Plan → Run → Sync”
42
+
43
+ `/alfred:2-run` is a general-purpose command that does not simply "build" code, but **performs** a planned task.
44
+
45
+ ### 3 main scenarios
46
+
47
+ #### Scenario 1: TDD implementation (main method) ⭐
48
+ ```bash
49
+ /alfred:2-run SPEC-AUTH-001
50
+ → RED → GREEN → REFACTOR
51
+ → Implement high-quality code through test-driven development
52
+ ```
53
+
54
+ #### Scenario 2: Prototyping
55
+ ```bash
56
+ /alfred:2-run SPEC-PROTO-001
57
+ → Prototype implementation for quick verification
58
+ → Quick feedback with minimal testing
59
+ ```
60
+
61
+ #### Scenario 3: Documentation tasks
62
+ ```bash
63
+ /alfred:2-run SPEC-DOCS-001
64
+ → Writing documentation and generating sample code
65
+ → API documentation, tutorials, guides, etc.
66
+ ```
67
+
68
+ > **Standard two-step workflow** (see `CLAUDE.md` - "Alfred Command Execution Pattern" for details)
69
+
70
+ ## 📋 Execution flow
71
+
72
+ 1. **SPEC Analysis**: Requirements extraction and complexity assessment
73
+ 2. **Establishment of implementation strategy**: Determine the optimized approach for each language (TDD, prototype, documentation, etc.)
74
+ 3. **User Confirmation**: Review and approve action plan
75
+ 4. **Execute work**: Perform work according to the approved plan
76
+ 5. **Git Operations**: Creating step-by-step commits with git-manager
77
+
78
+ ## 🧠 Associated Skills & Agents
79
+
80
+ | Agent | Core Skill | Purpose |
81
+ | ---------------------- | -------------------------------- | --------------------------------------- |
82
+ | implementation-planner | `moai-alfred-language-detection` | Detect language and design architecture |
83
+ | tdd-implementer | `moai-essentials-debug` | Implement TDD (RED → GREEN → REFACTOR) |
84
+ | quality-gate | `moai-alfred-trust-validation` | Verify TRUST 5 principles |
85
+ | git-manager | `moai-alfred-git-workflow` | Commit and manage Git workflows |
86
+
87
+ **Note**: TUI Survey Skill is used for user confirmations during the run phase and is shared across all interactive prompts.
88
+
89
+ ## 🔗 Associated Agent
90
+
91
+ - **Phase 1**: implementation-planner (📋 technical architect) - SPEC analysis and establishment of execution strategy
92
+ - **Phase 2**: tdd-implementer (🔬 senior developer) - Dedicated to execution work
93
+ - **Phase 2.5**: quality-gate (🛡️ Quality Assurance Engineer) - TRUST principle verification (automatically)
94
+ - **Phase 3**: git-manager (🚀 Release Engineer) - Dedicated to Git commits
95
+
96
+ ## 💡 Example of use
97
+
98
+ Users can run commands as follows:
99
+ - `/alfred:2-run SPEC-001` - Run a specific SPEC
100
+ - `/alfred:2-run all` - Run all SPECs in batches
101
+ - `/alfred:2-run SPEC-003 --test` - Run only tests
102
+
103
+ ## 🔍 STEP 1: SPEC analysis and execution plan establishment
104
+
105
+ STEP 1 consists of **two independent phases** to provide flexible workflow based on task complexity:
106
+
107
+ ### 📋 STEP 1 Workflow Overview
108
+
109
+ ```
110
+ ┌─────────────────────────────────────────────────────────────┐
111
+ │ STEP 1: SPEC Analysis & Planning │
112
+ ├─────────────────────────────────────────────────────────────┤
113
+ │ │
114
+ │ Phase A (OPTIONAL) │
115
+ │ ┌─────────────────────────────────────────┐ │
116
+ │ │ 🔍 Explore Agent │ │
117
+ │ │ • Browse existing codebase │ │
118
+ │ │ • Find similar implementations │ │
119
+ │ │ • Identify patterns & architecture │ │
120
+ │ └─────────────────────────────────────────┘ │
121
+ │ ↓ │
122
+ │ (exploration results) │
123
+ │ ↓ │
124
+ │ Phase B (REQUIRED) │
125
+ │ ┌─────────────────────────────────────────┐ │
126
+ │ │ ⚙️ implementation-planner Agent │ │
127
+ │ │ • Analyze SPEC requirements │ │
128
+ │ │ • Design execution strategy │ │
129
+ │ │ • Create implementation plan │ │
130
+ │ │ • Request user approval │ │
131
+ │ └─────────────────────────────────────────┘ │
132
+ │ ↓ │
133
+ │ (user approval via AskUserQuestion) │
134
+ │ ↓ │
135
+ │ PROCEED TO STEP 2 │
136
+ └─────────────────────────────────────────────────────────────┘
137
+ ```
138
+
139
+ **Key Points**:
140
+ - **Phase A is optional** - Skip if you don't need to explore existing code
141
+ - **Phase B is required** - Always runs to analyze SPEC and create execution plan
142
+ - **Results flow forward** - Exploration results (if any) are passed to implementation-planner
143
+
144
+ ---
145
+
146
+ ### 🔍 Phase A: Codebase Exploration (OPTIONAL)
147
+
148
+ **Use the Explore agent when you need to understand existing code before planning.**
149
+
150
+ #### When to use Phase A:
151
+
152
+ - ✅ Need to understand existing code structure/patterns
153
+ - ✅ Need to find similar function implementations for reference
154
+ - ✅ Need to understand project architectural rules
155
+ - ✅ Need to check libraries and versions being used
156
+
157
+ #### How to invoke Explore agent:
158
+
159
+ ```
160
+ Invoking the Task tool (Explore agent):
161
+ - subagent_type: "Explore"
162
+ - description: "Explore existing code structures and patterns"
163
+ - prompt: "Please explore existing code related to SPEC-$ARGUMENTS:
164
+ - Similar function implementation code (src/)
165
+ - Test patterns for reference (tests/)
166
+ - Architectural patterns and design patterns
167
+ - Current libraries and versions (package.json, requirements.txt)
168
+ thoroughness level: medium"
169
+ ```
170
+
171
+ **Note**: If you skip Phase A, proceed directly to Phase B.
172
+
173
+ ---
174
+
175
+ ### ⚙️ Phase B: Execution Planning (REQUIRED)
176
+
177
+ **Call the implementation-planner agent to analyze SPEC and establish execution strategy.**
178
+
179
+ This phase is **always required** regardless of whether Phase A was executed.
180
+
181
+ #### How to invoke implementation-planner:
182
+
183
+ ```
184
+ Task tool call:
185
+ - subagent_type: "implementation-planner"
186
+ - description: "SPEC analysis and establishment of execution strategy"
187
+ - prompt: "Please analyze the SPEC of $ARGUMENTS and establish an execution plan.
188
+ It must include the following:
189
+ 1. SPEC requirements extraction and complexity assessment
190
+ 2. Library and tool selection (using WebFetch)
191
+ 3. TAG chain design
192
+ 4. Step-by-step execution plan
193
+ 5. Risks and response plans
194
+ 6. Create action plan and use `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)` to confirm the next action with the user
195
+ (Optional) Explore results: $EXPLORE_RESULTS"
196
+ ```
197
+
198
+ **Note**: If Phase A was executed, pass the exploration results via `$EXPLORE_RESULTS` variable.
199
+
200
+ ### SPEC analysis in progress
201
+
202
+ 1. **SPEC document analysis**
203
+ - Requirements extraction and complexity assessment
204
+ - Check technical constraints
205
+ - Dependency and impact scope analysis
206
+ - (Optional) Identify existing code structure based on Explore results
207
+
208
+ 2. **Establish execution strategy**
209
+ - Detect project language and optimize execution strategy
210
+ - Determine approach (TDD, prototyping, documentation, etc.)
211
+ - Estimate expected work scope and time
212
+
213
+ 3. **Check and specify library versions (required)**
214
+ - **Web search**: Check the latest stable versions of all libraries to be used through `WebSearch`
215
+ - **Specify versions**: Specify the exact version for each library in the implementation plan report (e.g. `fastapi>=0.118.3`)
216
+ - **Stability priority**: Exclude beta/alpha versions, select only production stable versions
217
+ - **Check compatibility**: Verify version compatibility between libraries
218
+ - **Search keyword examples**:
219
+ - `"FastAPI latest stable version 2025"`
220
+ - `"SQLAlchemy 2.0 latest stable version 2025"`
221
+ - `"React 18 latest stable version 2025"`
222
+
223
+ 4. **Report action plan**
224
+ - Present step-by-step action plan
225
+ - Identify potential risk factors
226
+ - Set quality gate checkpoints
227
+ - **Specify library version (required)**
228
+
229
+ ### User verification steps
230
+
231
+ After reviewing the action plan, select one of the following:
232
+ - **"Proceed"** or **"Start"**: Start executing the task as planned
233
+ - **"Modify [Content]"**: Request a plan modification
234
+ - **"Abort"**: Stop the task
235
+
236
+ ---
237
+
238
+ ## 🚀 STEP 2: Execute task (after user approval)
239
+
240
+ After user approval (gathered through `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)`), **call the tdd-implementer agent using the Task tool**.
241
+
242
+ ### ⚙️ How to call an agent
243
+
244
+ **STEP 2 calls tdd-implementer using the Task tool**:
245
+
246
+ ```
247
+ Call the Task tool:
248
+ - subagent_type: "tdd-implementer"
249
+ - description: "Execute task with TDD implementation"
250
+ - prompt: """You are tdd-implementer agent.
251
+
252
+ LANGUAGE CONFIGURATION:
253
+ - conversation_language: {{CONVERSATION_LANGUAGE}}
254
+ - language_name: {{CONVERSATION_LANGUAGE_NAME}}
255
+
256
+ CRITICAL INSTRUCTION:
257
+ Code and technical output MUST be in English.
258
+ Code comments MAY be in {{CONVERSATION_LANGUAGE}} if appropriate.
259
+ Test descriptions and documentation can use {{CONVERSATION_LANGUAGE}}.
260
+
261
+ SKILL INVOCATION:
262
+ Use explicit Skill() calls when needed:
263
+ - Skill("moai-alfred-language-detection") for project language detection
264
+ - Skill("moai-lang-python") or language-specific Skills for best practices
265
+ - Skill("moai-essentials-debug") when tests fail
266
+ - Skill("moai-essentials-refactor") during REFACTOR phase
267
+
268
+ TASK: Execute the task according to the plan approved in STEP 1.
269
+
270
+ For TDD scenario:
271
+ - Perform RED → GREEN → REFACTOR cycle
272
+ - Perform the following for each TAG:
273
+ 1. RED Phase: Write a test that fails with the @TEST:ID tag
274
+ 2. GREEN Phase: Minimal implementation with the @CODE:ID tag
275
+ 3. REFACTOR Phase: Improve code quality
276
+ 4. Verify TAG completion conditions and proceed to the next TAG
277
+
278
+ Execute on: $ARGUMENTS"""
279
+ ```
280
+
281
+ ## 🔗 TDD optimization for each language
282
+
283
+ ### Project language detection and optimal routing
284
+
285
+ `tdd-implementer` automatically detects the language of your project and selects the optimal TDD tools and workflow:
286
+
287
+ - **Language detection**: Analyze project files (package.json, pyproject.toml, go.mod, etc.)
288
+ - **Tool selection**: Automatically select the optimal test framework for each language
289
+ - **TAG application**: Write @TAG annotations directly in code files
290
+ - **Run cycle**: RED → GREEN → REFACTOR sequential process
291
+
292
+ ### TDD tool mapping
293
+
294
+ #### Backend/System
295
+
296
+ | SPEC Type | Implementation language | Test Framework | Performance Goals | Coverage Goals |
297
+ | ------------------- | ----------------------- | ---------------------- | ----------------- | -------------- |
298
+ | **CLI/System** | TypeScript | jest + ts-node | < 18ms | 95%+ |
299
+ | **API/Backend** | TypeScript | Jest + SuperTest | < 50ms | 90%+ |
300
+ | **Frontend** | TypeScript | Jest + Testing Library | < 100ms | 85%+ |
301
+ | **Data Processing** | TypeScript | Jest + Mock | < 200ms | 85%+ |
302
+ | **Python Project** | Python | pytest + mypy | Custom | 85%+ |
303
+
304
+ #### Mobile Framework
305
+
306
+ | SPEC Type | Implementation language | Test Framework | Performance Goals | Coverage Goals |
307
+ | ---------------- | ----------------------- | -------------------------- | ----------------- | -------------- |
308
+ | **Flutter App** | Dart | flutter test + widget test | < 100ms | 85%+ |
309
+ | **React Native** | TypeScript | Jest + RN Testing Library | < 100ms | 85%+ |
310
+ | **iOS App** | Swift | XCTest + XCUITest | < 150ms | 80%+ |
311
+ | **Android App** | Kotlin | JUnit + Espresso | < 150ms | 80%+ |
312
+
313
+ ## 🚀 Optimized agent collaboration structure
314
+
315
+ - **Phase 1**: `implementation-planner` agent analyzes SPEC and establishes execution strategy
316
+ - **Phase 2**: `tdd-implementer` agent executes tasks (TDD cycle, prototyping, documentation, etc.)
317
+ - **Phase 2.5**: `quality-gate` agent verifies TRUST principle and quality verification (automatically)
318
+ - **Phase 3**: `git-manager` agent processes all commits at once after task completion
319
+ - **Single responsibility principle**: Each agent is responsible only for its own area of expertise
320
+ - **Inter-agent call prohibited**: Each agent runs independently, sequential calls are made only at the command level
321
+
322
+ ## 🔄 Step 2 Workflow Execution Order
323
+
324
+ ### Phase 1: Analysis and planning phase
325
+
326
+ The `implementation-planner` agent does the following:
327
+
328
+ 1. **SPEC document analysis**: Requirements extraction and complexity assessment of specified SPEC ID
329
+ 2. **Library selection**: Check the latest stable version and verify compatibility through WebFetch
330
+ 3. **TAG chain design**: Determine TAG order and dependency
331
+ 4. **Establishment of implementation strategy**: Step-by-step implementation plan and risk identification
332
+ 5. **Create action plan**: Create a structured plan and, via `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)`, collect user approval before proceeding
333
+
334
+ ### Phase 2: Task execution phase (after approval)
335
+
336
+ The `tdd-implementer` agent performs **TAG-by-TAG** after user approval (based on TDD scenario):
337
+
338
+ 1. **RED Phase**: Write a failing test (add @TEST:ID tag) and check for failure
339
+ 2. **GREEN Phase**: Write minimal code that passes the test (add @CODE:ID tag)
340
+ 3. **REFACTOR Phase**: Improve code quality (without changing functionality)
341
+ 4. **TAG completion confirmation**: Verify the completion conditions of each TAG and proceed to the next TAG
342
+
343
+ ### Phase 2.5: Quality verification gate (automatic execution)
344
+
345
+ After the job execution is complete, the `quality-gate` agent **automatically** performs quality verification.
346
+
347
+ **Automatic execution conditions**:
348
+ - Automatically invoked upon completion of task execution
349
+ - Manually invoked upon user request
350
+
351
+ **Verification items**:
352
+ - **TRUST principle verification**: Trust-checker script execution and result parsing
353
+ - T (Testable): Test coverage ≥ 85%
354
+ - R (Readable): Code readability (file≤300 LOC, function≤50 LOC, Complexity≤10)
355
+ - U (Unified): Architectural integrity
356
+ - S (Secured): No security vulnerabilities
357
+ - T (Traceable): @TAG chain integrity
358
+ - **Code style**: Run and verify linter (ESLint/Pylint)
359
+ - **Test Coverage**: Run language-specific coverage tools and verify goal achievement
360
+ - **TAG chain verification**: Check orphan TAGs, missing TAGs
361
+ - **Dependency verification**: Check security vulnerabilities
362
+
363
+ **How ​​it works**: When Alfred completes job execution, it automatically calls the quality-gate agent to perform quality verification.
364
+
365
+ **Handling verification results**:
366
+
367
+ ✅ **PASS (0 Critical, 5 or less Warnings)**:
368
+ - Proceed to Phase 3 (Git work)
369
+ - Create a quality report
370
+
371
+ ⚠️ **WARNING (0 Critical, 6 or more Warnings)**:
372
+ - Display warning
373
+ - User choice: "Continue" or "Re-verify after modification"
374
+
375
+ ❌ **CRITICAL (1 or more Critical)**:
376
+ - Block Git commits
377
+ - Detailed report on items requiring improvement (including file: line information)
378
+ - Recommended tdd-implementer re-invocation
379
+
380
+ **Skip verification option**: To skip quality verification, use the `--skip-quality-check` option.
381
+
382
+ ### Phase 3: Git operations (git-manager)
383
+
384
+ After the `git-manager` agent completes the task **at once**:
385
+
386
+ 1. **Create checkpoint**: Backup point before starting work
387
+ 2. **Structured Commit**: Step-by-step commit creation (RED→GREEN→REFACTOR for TDD)
388
+ 3. **Final synchronization**: Apply Git strategy for each mode and remote synchronization
389
+
390
+
391
+ ## 📋 STEP 1 Execution Guide: SPEC Analysis and Planning
392
+
393
+ ### 1. SPEC document analysis
394
+
395
+ Alfred calls the implementation-planner agent to check the SPEC document and create an execution plan.
396
+
397
+ #### Analysis Checklist
398
+
399
+ - [ ] **Requirements clarity**: Are the functional requirements in the SPEC specific?
400
+ - [ ] **Technical constraints**: Check performance, compatibility, and security requirements
401
+ - [ ] **Dependency analysis**: Connection points with existing code and scope of impact
402
+ - [ ] **Complexity assessment**: Implementation difficulty and expected workload
403
+
404
+ ### 2. Determine implementation strategy
405
+
406
+ #### TypeScript execution criteria
407
+
408
+ | SPEC characteristics | execution language | Reason |
409
+ | -------------------- | ------------------- | --------------------------------------------------------- |
410
+ | CLI/System Tools | TypeScript | High performance (18ms), type safety, SQLite3 integration |
411
+ | API/Backend | TypeScript | Node.js ecosystem, Express/Fastify compatibility |
412
+ | Frontend | TypeScript | React/Vue native support |
413
+ | data processing | TypeScript | High-performance asynchronous processing, type safety |
414
+ | User Python Project | Python tool support | MoAI-ADK provides Python project development tools |
415
+
416
+ #### Approach
417
+
418
+ - **Bottom-up**: Utility → Service → API
419
+ - **Top-down**: API → Service → Utility
420
+ - **Middle-out**: Core logic → Bidirectional expansion
421
+
422
+ ### 3. Generate action plan report
423
+
424
+ Present your plan in the following format:
425
+
426
+ ```
427
+ ## Execution Plan Report: [SPEC-ID]
428
+
429
+ ### 📊 Analysis Results
430
+ - **Complexity**: [Low/Medium/High]
431
+ - **Estimated Work Time**: [Time Estimation]
432
+ - **Key Technical Challenges**: [Technical Difficulties]
433
+
434
+ ### 🎯 Execution Strategy
435
+ - **Language of choice**: [Python/TypeScript + Reason]
436
+ - **Approach**: [Bottom-up/Top-down/Middle-out or Prototype/Documentation]
437
+ - **Core module**: [Major work target]
438
+
439
+ ### 📦 Library version (required - based on web search)
440
+ **Backend dependencies** (example):
441
+ | package | Latest stable version | installation command |
442
+ | ---------- | --------------------- | -------------------- |
443
+ | FastAPI | 0.118.3 | fastapi>=0.118.3 |
444
+ | SQLAlchemy | 2.0.43 | sqlalchemy>=2.0.43 |
445
+
446
+ **Frontend dependency** (example):
447
+ | package | Latest stable version | installation command |
448
+ | ------- | --------------------- | -------------------- |
449
+ | React | 18.3.1 | react@^18.3.1 |
450
+ | Vite | 7.1.9 | vite@^7.1.9 |
451
+
452
+ **Important Compatibility Information**:
453
+ - [Specific Version Requirements]
454
+ - [Known Compatibility Issues]
455
+
456
+ ### ⚠️ Risk Factors
457
+ - **Technical Risk**: [Expected Issues]
458
+ - **Dependency Risk**: [External Dependency Issues]
459
+ - **Schedule Risk**: [Possible Delay]
460
+
461
+ ### ✅ Quality Gates
462
+ - **Test Coverage**: [Goal %]
463
+ - **Performance Goals**: [Specific Metrics]
464
+ - **Security Checkpoints**: [Verification Items]
465
+
466
+ ---
467
+ **Approval Request**: Do you want to proceed with the above plan?
468
+ (Choose between “Proceed,” “Modify [Content],” or “Abort”)
469
+ ```
470
+
471
+ ---
472
+
473
+ ## 🚀 STEP 2 Execution Guide: Execute Task (After Approval)
474
+
475
+ Only if the user selects **"Proceed"** or **"Start"** will Alfred call the tdd-implementer agent to start the task.
476
+
477
+ ### TDD step-by-step guide
478
+
479
+ 1. **RED**: Writing failure tests with Given/When/Then structure. Follow test file rules for each language and simply record failure logs.
480
+ 2. **GREEN**: Add only the minimal implementation that makes the tests pass. Optimization is postponed to the REFACTOR stage.
481
+ 3. **REFACTOR**: Removal of duplication, explicit naming, structured logging/exception handling enhancements. Split into additional commits if necessary.
482
+
483
+ **TRUST 5 Principles Linkage** (Details: `development-guide.md` - "TRUST 5 Principles"):
484
+ - **T (Test First)**: Writing SPEC-based tests in the RED stage
485
+ - **R (Readable)**: Readability in the REFACTOR stage Improvement (file≤300 LOC, function≤50 LOC)
486
+ - **T (Trackable)**: Maintain @TAG traceability at all stages.
487
+
488
+ > TRUST 5 principles provide only basic recommendations, so if you need a structure that exceeds `simplicity_threshold`, proceed with the basis in SPEC or ADR.
489
+
490
+ ## Agent role separation
491
+
492
+ ### implementation-planner dedicated area
493
+
494
+ - SPEC document analysis and requirements extraction
495
+ - Library selection and version management
496
+ - TAG chain design and sequence decision
497
+ - Establishment of implementation strategy and identification of risks
498
+ - Creation of execution plan
499
+
500
+ ### tdd-implementer dedicated area
501
+
502
+ - Execute tasks (TDD, prototyping, documentation, etc.)
503
+ - Write and run tests (TDD scenarios)
504
+ - Add and manage TAG comments
505
+ - Improve code quality (refactoring)
506
+ - Run language-specific linters/formatters
507
+
508
+ ### Quality-gate dedicated area
509
+
510
+ - TRUST principle verification
511
+ - Code style verification
512
+ - Test coverage verification
513
+ - TAG chain integrity verification
514
+ - Dependency security verification
515
+
516
+ ### git-manager dedicated area
517
+
518
+ - All Git commit operations (add, commit, push)
519
+ - Checkpoint creation for each task stage
520
+ - Apply commit strategy for each mode
521
+ - Git branch/tag management
522
+ - Remote synchronization processing
523
+
524
+ ## Quality Gate Checklist
525
+
526
+ - Test coverage ≥ `.moai/config.json.test_coverage_target` (default 85%)
527
+ - Pass linter/formatter (`ruff`, `eslint --fix`, `gofmt`, etc.)
528
+ - Check presence of structured logging or observation tool call
529
+ - @TAG update needed changes note (used by doc-syncer in next step)
530
+
531
+ ---
532
+
533
+ ## 🧠 Context Management
534
+
535
+ > For more information: `.moai/memory/development-guide.md` - see section "Context Engineering"
536
+
537
+ ### Core strategy of this command
538
+
539
+ **Load first**: `.moai/specs/SPEC-XXX/spec.md` (implementation target requirement)
540
+
541
+ **Recommendation**: Job execution completed successfully. You can experience better performance and context management by starting a new chat session with the `/clear` or `/new` command before proceeding to the next step (`/alfred:3-sync`).
542
+
543
+ ---
544
+
545
+ ## Next steps
546
+
547
+ **Recommendation**: For better performance and context management, start a new chat session with the `/clear` or `/new` command before proceeding to the next step.
548
+
549
+ - After task execution is complete, document synchronization proceeds with `/alfred:3-sync`
550
+ - All Git operations are dedicated to the git-manager agent to ensure consistency
551
+ - Only command-level orchestration is used without direct calls between agents