@relipa/ai-flow-kit 0.1.4 → 0.1.5-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (326) hide show
  1. package/README.md +0 -0
  2. package/bin/aiflow.js +0 -0
  3. package/bin/ak.js +0 -0
  4. package/custom/harness/playwright/.env.example +0 -0
  5. package/custom/harness/playwright/playwright.config.ts +0 -0
  6. package/custom/harness/playwright/tests/e2e/auth.setup.ts +0 -0
  7. package/custom/harness/playwright/tests/e2e/fixtures/test.ts +0 -0
  8. package/custom/harness/playwright/tests/e2e/pages/BasePage.ts +0 -0
  9. package/custom/harness/playwright/tests/e2e/support/auth.ts +0 -0
  10. package/custom/mcp-presets/README.md +0 -0
  11. package/custom/mcp-presets/backlog.json +0 -0
  12. package/custom/mcp-presets/figma-desktop.json +0 -0
  13. package/custom/mcp-presets/figma.json +0 -0
  14. package/custom/mcp-presets/gitnexus.json +0 -0
  15. package/custom/mcp-presets/google-sheets.json +0 -0
  16. package/custom/mcp-presets/jira.json +0 -0
  17. package/custom/mcp-presets/playwright.json +0 -0
  18. package/custom/prompts/bug-fix.md +0 -0
  19. package/custom/prompts/feature.md +0 -0
  20. package/custom/prompts/investigation.md +0 -0
  21. package/custom/rules/code-style.md +0 -0
  22. package/custom/rules/java/code-style.md +0 -0
  23. package/custom/rules/java/naming.md +0 -0
  24. package/custom/rules/java/review-checklist.md +0 -0
  25. package/custom/rules/java/spring-boot-examples.md +0 -0
  26. package/custom/rules/javascript/code-style.md +0 -0
  27. package/custom/rules/javascript/naming.md +0 -0
  28. package/custom/rules/ml-conventions.md +0 -0
  29. package/custom/rules/ml-review-checklist.md +0 -0
  30. package/custom/rules/naming.md +0 -0
  31. package/custom/rules/php/code-style.md +0 -0
  32. package/custom/rules/php/naming.md +0 -0
  33. package/custom/rules/project-conventions.md +67 -51
  34. package/custom/rules/review-checklist.md +0 -0
  35. package/custom/rules/test-patterns.md +0 -0
  36. package/custom/skills/automation-testing/SKILL.md +0 -0
  37. package/custom/skills/automation-testing/templates/BasePage.ts +0 -0
  38. package/custom/skills/automation-testing/templates/PageObject.example.ts +0 -0
  39. package/custom/skills/automation-testing/templates/playwright.config.ts +0 -0
  40. package/custom/skills/automation-testing/templates/spec.example.ts +0 -0
  41. package/custom/skills/ba-skills/{skill-ba-xay-dung-business-rules-v1.md → skill-ba-build-business-rules-v1.md} +0 -0
  42. package/custom/skills/ba-skills/{skill-ba-template-phan-tich-ban-dau-v1.md → skill-ba-initial-analysis-template-v1.md} +0 -0
  43. package/custom/skills/ba-skills/{skill-ba-phan-tich-ban-dau-v1.md → skill-ba-initial-analysis-v1.md} +2 -2
  44. package/custom/skills/ba-skills/{skill-ba-ve-luong-mermaid-v1.md → skill-ba-mermaid-flowchart-v1.md} +0 -0
  45. package/custom/skills/ba-skills/{skill-ba-qa-template-v1.md → skill-ba-qna-template-v1.md} +0 -0
  46. package/custom/skills/ba-skills/{skill-ba-qa-v1.md → skill-ba-qna-v1.md} +2 -2
  47. package/custom/skills/ba-skills/{skill-ba-template-uc-v1.md → skill-ba-uc-template-v1.md} +0 -0
  48. package/custom/skills/ba-skills/{skill-ba-prototype-v1.md → skill-ba-ui-prototype-v1.md} +2 -2
  49. package/custom/skills/ba-skills/{skill-ba-viet-spec-uc-v1.md → skill-ba-write-uc-spec-v1.md} +4 -4
  50. package/custom/skills/coverage-check/SKILL.md +0 -0
  51. package/custom/skills/deploy-model/SKILL.md +0 -0
  52. package/custom/skills/design-experiment/SKILL.md +0 -0
  53. package/custom/skills/evaluate-model/SKILL.md +0 -0
  54. package/custom/skills/evidence-aggregation/SKILL.md +0 -0
  55. package/custom/skills/execute-flow/SKILL.md +0 -0
  56. package/custom/skills/execute-flow/templates/playwright.config.ts +0 -0
  57. package/custom/skills/explore-data/SKILL.md +0 -0
  58. package/custom/skills/figma-to-component/SKILL.md +0 -0
  59. package/custom/skills/frame-ml-problem/SKILL.md +0 -0
  60. package/custom/skills/gate-review/SKILL.md +1 -1
  61. package/custom/skills/generate-spec/SKILL.md +99 -99
  62. package/custom/skills/generate-test-report/SKILL.md +0 -0
  63. package/custom/skills/generate-test-report/templates/test-report.md +0 -0
  64. package/custom/skills/generate-testcase/SKILL.md +0 -0
  65. package/custom/skills/generate-testcase/templates/testcase.md +0 -0
  66. package/custom/skills/impact-analysis/SKILL.md +0 -0
  67. package/custom/skills/improve-algorithm/SKILL.md +0 -0
  68. package/custom/skills/investigate-bug/SKILL.md +0 -0
  69. package/custom/skills/log-bug/SKILL.md +0 -0
  70. package/custom/skills/pr-impact-analysis/SKILL.md +0 -0
  71. package/custom/skills/read-study-requirement/SKILL.md +7 -5
  72. package/custom/skills/report-customer/SKILL.md +0 -0
  73. package/custom/skills/retest-orchestration/SKILL.md +0 -0
  74. package/custom/skills/review-plan/SKILL.md +194 -194
  75. package/custom/skills/script-sync/SKILL.md +0 -0
  76. package/custom/skills/test-analysis/SKILL.md +0 -0
  77. package/custom/skills/test-skills/categories/00-core/00.01.requirement-analysis.md +0 -0
  78. package/custom/skills/test-skills/categories/00-core/00.02.risk-analysis.md +0 -0
  79. package/custom/skills/test-skills/categories/00-core/00.03.test-scenario-builder.md +0 -0
  80. package/custom/skills/test-skills/categories/00-core/00.04.testcase-review.md +0 -0
  81. package/custom/skills/test-skills/categories/01-test-design/01.01.boundary-value-analysis.md +0 -0
  82. package/custom/skills/test-skills/categories/01-test-design/01.02.equivalence.partitioning.md +0 -0
  83. package/custom/skills/test-skills/categories/01-test-design/01.03.decision-table.md +0 -0
  84. package/custom/skills/test-skills/categories/01-test-design/01.04.state.transition.md +0 -0
  85. package/custom/skills/test-skills/categories/01-test-design/01.05.pairwise.md +0 -0
  86. package/custom/skills/test-skills/categories/01-test-design/01.06.error-guessing.md +0 -0
  87. package/custom/skills/test-skills/categories/02-ui-testing/02.01.UI-layout.md +0 -0
  88. package/custom/skills/test-skills/categories/02-ui-testing/02.02.form-validation.md +0 -0
  89. package/custom/skills/test-skills/categories/02-ui-testing/02.03.navigation.md +0 -0
  90. package/custom/skills/test-skills/categories/02-ui-testing/02.04.localization.md +0 -0
  91. package/custom/skills/test-skills/categories/02-ui-testing/02.05.accessibility.md +0 -0
  92. package/custom/skills/test-skills/categories/03-business-testing/03.01.CRUD-testing.md +0 -0
  93. package/custom/skills/test-skills/categories/03-business-testing/03.02.workflow-testing.md +0 -0
  94. package/custom/skills/test-skills/categories/03-business-testing/03.03.permission-testing.md +0 -0
  95. package/custom/skills/test-skills/categories/03-business-testing/03.04.dependency-validation.md +0 -0
  96. package/custom/skills/test-skills/categories/03-business-testing/03.05.notification-testing.md +0 -0
  97. package/custom/skills/test-skills/categories/03-business-testing/03.06.calculation.testing.md +0 -0
  98. package/custom/skills/test-skills/categories/04-data-testing/04.01.database-testing.md +0 -0
  99. package/custom/skills/test-skills/categories/04-data-testing/04.02.import-export-testing.md +0 -0
  100. package/custom/skills/test-skills/categories/04-data-testing/04.03.data-mapping.md +0 -0
  101. package/custom/skills/test-skills/categories/04-data-testing/04.04.duplicate-handling.md +0 -0
  102. package/custom/skills/test-skills/categories/04-data-testing/04.05.migration.md +0 -0
  103. package/custom/skills/test-skills/categories/05-integration/05.01.API-testing.md +0 -0
  104. package/custom/skills/test-skills/categories/05-integration/05.02.third-party-integration.md +0 -0
  105. package/custom/skills/test-skills/categories/05-integration/05.03.batch-processing.md +0 -0
  106. package/custom/skills/test-skills/categories/05-integration/05.04.file-upload-download.md +0 -0
  107. package/custom/skills/test-skills/categories/08-domain-skills/CMS.md +0 -0
  108. package/custom/skills/test-skills/categories/08-domain-skills/Ecommerce.md +0 -0
  109. package/custom/skills/test-skills/categories/99-review/99.01.coverage-review.md +0 -0
  110. package/custom/skills/test-skills/categories/99-review/99.02.knowledge-learning.md +0 -0
  111. package/custom/skills/test-skills/categories/99-review/99.03.repository-update.md +0 -0
  112. package/custom/skills/test-skills/categories/99-review/99.04.change-history.md +0 -0
  113. package/custom/skills/test-skills/rules/directory-and-naming-convention.md +158 -0
  114. package/custom/skills/test-skills/rules/{QA_Writing_Standards.md → qa-writing-standards.md} +0 -0
  115. package/custom/skills/test-skills/template/{template_testcase.md → testcase-template.md} +0 -0
  116. package/custom/skills/train-model/SKILL.md +0 -0
  117. package/custom/templates/laravel.md +0 -0
  118. package/custom/templates/nestjs.md +0 -0
  119. package/custom/templates/nextjs.md +0 -0
  120. package/custom/templates/nodejs-express.md +0 -0
  121. package/custom/templates/php-plain.md +0 -0
  122. package/custom/templates/php.md +0 -0
  123. package/custom/templates/python-django.md +0 -0
  124. package/custom/templates/python-fastapi.md +0 -0
  125. package/custom/templates/python-ml.md +0 -0
  126. package/custom/templates/python.md +0 -0
  127. package/custom/templates/reactjs.md +0 -0
  128. package/custom/templates/shared/coding-workflow.md +15 -0
  129. package/custom/templates/shared/create-spec-workflow.md +80 -89
  130. package/custom/templates/shared/create-testcase-workflow.md +86 -84
  131. package/custom/templates/shared/gate-workflow.md +64 -11
  132. package/custom/templates/shared/ml-gate-workflow.md +0 -0
  133. package/custom/templates/spring-boot.md +0 -0
  134. package/custom/templates/tools/claude.md +13 -13
  135. package/custom/templates/tools/copilot.md +12 -12
  136. package/custom/templates/tools/cursor.md +12 -12
  137. package/custom/templates/tools/gemini.md +22 -22
  138. package/custom/templates/tools/generic.md +17 -17
  139. package/custom/templates/vue-nuxt.md +0 -0
  140. package/docs/common/AIFLOW.md +10 -10
  141. package/docs/common/CHANGELOG.md +33 -9
  142. package/docs/common/QUICK_START.md +0 -0
  143. package/docs/common/ai-integration.md +53 -53
  144. package/docs/common/cli-reference.md +0 -0
  145. package/docs/common/configuration.md +0 -0
  146. package/docs/common/getting-started.md +0 -0
  147. package/docs/common/troubleshooting.md +0 -0
  148. package/docs/common/workflows/bug-fix.md +126 -126
  149. package/docs/common/workflows/feature.md +123 -123
  150. package/docs/common/workflows/figma.md +0 -0
  151. package/docs/common/workflows/impact-analysis.md +0 -0
  152. package/docs/common/workflows/investigation.md +0 -0
  153. package/docs/common/workflows/refactor.md +0 -0
  154. package/docs/project/ARCHITECTURE.md +0 -0
  155. package/index.js +0 -0
  156. package/package.json +1 -1
  157. package/scripts/checkpoint.js +0 -0
  158. package/scripts/config.js +0 -0
  159. package/scripts/context.js +0 -0
  160. package/scripts/create-score-excel.js +41 -47
  161. package/scripts/detect.js +0 -0
  162. package/scripts/doctor.js +0 -0
  163. package/scripts/gitnexus-worker.js +0 -0
  164. package/scripts/guide.js +0 -0
  165. package/scripts/hooks/block-git-write.js +0 -0
  166. package/scripts/hooks/session-start.js +10 -5
  167. package/scripts/hooks/session-stop.js +0 -0
  168. package/scripts/init.js +5 -0
  169. package/scripts/memory.js +0 -0
  170. package/scripts/prompt.js +0 -0
  171. package/scripts/remove.js +0 -0
  172. package/scripts/review.js +0 -0
  173. package/scripts/scaffold-playwright.js +0 -0
  174. package/scripts/task.js +69 -22
  175. package/scripts/telemetry/cli.js +0 -0
  176. package/scripts/telemetry/config.js +0 -0
  177. package/scripts/telemetry/crypto.js +0 -0
  178. package/scripts/telemetry/flush.js +0 -0
  179. package/scripts/telemetry/record.js +0 -0
  180. package/scripts/update.js +0 -0
  181. package/scripts/use.js +3 -2
  182. package/scripts/validate.js +0 -0
  183. package/upstream/.claude-plugin/marketplace.json +0 -0
  184. package/upstream/.claude-plugin/plugin.json +0 -0
  185. package/upstream/.codex/INSTALL.md +0 -0
  186. package/upstream/.cursor-plugin/plugin.json +0 -0
  187. package/upstream/.gitattributes +0 -0
  188. package/upstream/.github/FUNDING.yml +0 -0
  189. package/upstream/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
  190. package/upstream/.github/ISSUE_TEMPLATE/config.yml +0 -0
  191. package/upstream/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
  192. package/upstream/.github/ISSUE_TEMPLATE/platform_support.md +0 -0
  193. package/upstream/.github/PULL_REQUEST_TEMPLATE.md +0 -0
  194. package/upstream/.opencode/INSTALL.md +0 -0
  195. package/upstream/.opencode/plugins/superpowers.js +0 -0
  196. package/upstream/.version-bump.json +0 -0
  197. package/upstream/AGENTS.md +0 -0
  198. package/upstream/CHANGELOG.md +0 -0
  199. package/upstream/CLAUDE.md +0 -0
  200. package/upstream/CODE_OF_CONDUCT.md +0 -0
  201. package/upstream/GEMINI.md +0 -0
  202. package/upstream/LICENSE +0 -0
  203. package/upstream/README.md +0 -0
  204. package/upstream/RELEASE-NOTES.md +0 -0
  205. package/upstream/agents/code-reviewer.md +0 -0
  206. package/upstream/commands/brainstorm.md +0 -0
  207. package/upstream/commands/execute-plan.md +0 -0
  208. package/upstream/commands/write-plan.md +0 -0
  209. package/upstream/docs/README.codex.md +0 -0
  210. package/upstream/docs/README.opencode.md +0 -0
  211. package/upstream/docs/plans/2025-11-22-opencode-support-design.md +0 -0
  212. package/upstream/docs/plans/2025-11-22-opencode-support-implementation.md +0 -0
  213. package/upstream/docs/plans/2025-11-28-skills-improvements-from-user-feedback.md +0 -0
  214. package/upstream/docs/plans/2026-01-17-visual-brainstorming.md +0 -0
  215. package/upstream/docs/superpowers/plans/2026-01-22-document-review-system.md +0 -0
  216. package/upstream/docs/superpowers/plans/2026-02-19-visual-brainstorming-refactor.md +0 -0
  217. package/upstream/docs/superpowers/plans/2026-03-11-zero-dep-brainstorm-server.md +0 -0
  218. package/upstream/docs/superpowers/plans/2026-03-23-codex-app-compatibility.md +0 -0
  219. package/upstream/docs/superpowers/specs/2026-01-22-document-review-system-design.md +0 -0
  220. package/upstream/docs/superpowers/specs/2026-02-19-visual-brainstorming-refactor-design.md +0 -0
  221. package/upstream/docs/superpowers/specs/2026-03-11-zero-dep-brainstorm-server-design.md +0 -0
  222. package/upstream/docs/superpowers/specs/2026-03-23-codex-app-compatibility-design.md +0 -0
  223. package/upstream/docs/testing.md +0 -0
  224. package/upstream/docs/windows/polyglot-hooks.md +0 -0
  225. package/upstream/gemini-extension.json +0 -0
  226. package/upstream/hooks/hooks-cursor.json +0 -0
  227. package/upstream/hooks/hooks.json +0 -0
  228. package/upstream/hooks/run-hook.cmd +0 -0
  229. package/upstream/hooks/session-start +0 -0
  230. package/upstream/package.json +0 -0
  231. package/upstream/scripts/bump-version.sh +0 -0
  232. package/upstream/skills/brainstorming/SKILL.md +0 -0
  233. package/upstream/skills/brainstorming/scripts/frame-template.html +0 -0
  234. package/upstream/skills/brainstorming/scripts/helper.js +0 -0
  235. package/upstream/skills/brainstorming/scripts/server.cjs +0 -0
  236. package/upstream/skills/brainstorming/scripts/start-server.sh +0 -0
  237. package/upstream/skills/brainstorming/scripts/stop-server.sh +0 -0
  238. package/upstream/skills/brainstorming/spec-document-reviewer-prompt.md +0 -0
  239. package/upstream/skills/brainstorming/visual-companion.md +0 -0
  240. package/upstream/skills/dispatching-parallel-agents/SKILL.md +0 -0
  241. package/upstream/skills/executing-plans/SKILL.md +0 -0
  242. package/upstream/skills/finishing-a-development-branch/SKILL.md +0 -0
  243. package/upstream/skills/receiving-code-review/SKILL.md +0 -0
  244. package/upstream/skills/requesting-code-review/SKILL.md +0 -0
  245. package/upstream/skills/requesting-code-review/code-reviewer.md +0 -0
  246. package/upstream/skills/subagent-driven-development/SKILL.md +0 -0
  247. package/upstream/skills/subagent-driven-development/code-quality-reviewer-prompt.md +0 -0
  248. package/upstream/skills/subagent-driven-development/implementer-prompt.md +0 -0
  249. package/upstream/skills/subagent-driven-development/spec-reviewer-prompt.md +0 -0
  250. package/upstream/skills/systematic-debugging/CREATION-LOG.md +0 -0
  251. package/upstream/skills/systematic-debugging/SKILL.md +0 -0
  252. package/upstream/skills/systematic-debugging/condition-based-waiting-example.ts +0 -0
  253. package/upstream/skills/systematic-debugging/condition-based-waiting.md +0 -0
  254. package/upstream/skills/systematic-debugging/defense-in-depth.md +0 -0
  255. package/upstream/skills/systematic-debugging/find-polluter.sh +0 -0
  256. package/upstream/skills/systematic-debugging/root-cause-tracing.md +0 -0
  257. package/upstream/skills/systematic-debugging/test-academic.md +0 -0
  258. package/upstream/skills/systematic-debugging/test-pressure-1.md +0 -0
  259. package/upstream/skills/systematic-debugging/test-pressure-2.md +0 -0
  260. package/upstream/skills/systematic-debugging/test-pressure-3.md +0 -0
  261. package/upstream/skills/tdd-lean/SKILL.md +0 -0
  262. package/upstream/skills/test-driven-development/SKILL.md +0 -0
  263. package/upstream/skills/test-driven-development/testing-anti-patterns.md +0 -0
  264. package/upstream/skills/using-git-worktrees/SKILL.md +0 -0
  265. package/upstream/skills/using-superpowers/SKILL.md +0 -0
  266. package/upstream/skills/using-superpowers/references/codex-tools.md +0 -0
  267. package/upstream/skills/using-superpowers/references/copilot-tools.md +0 -0
  268. package/upstream/skills/using-superpowers/references/gemini-tools.md +0 -0
  269. package/upstream/skills/verification-before-completion/SKILL.md +0 -0
  270. package/upstream/skills/writing-plans/SKILL.md +0 -0
  271. package/upstream/skills/writing-plans/plan-document-reviewer-prompt.md +0 -0
  272. package/upstream/skills/writing-skills/SKILL.md +0 -0
  273. package/upstream/skills/writing-skills/anthropic-best-practices.md +0 -0
  274. package/upstream/skills/writing-skills/examples/CLAUDE_MD_TESTING.md +0 -0
  275. package/upstream/skills/writing-skills/graphviz-conventions.dot +0 -0
  276. package/upstream/skills/writing-skills/persuasion-principles.md +0 -0
  277. package/upstream/skills/writing-skills/render-graphs.js +0 -0
  278. package/upstream/skills/writing-skills/testing-skills-with-subagents.md +0 -0
  279. package/upstream/tests/brainstorm-server/package-lock.json +0 -0
  280. package/upstream/tests/brainstorm-server/package.json +0 -0
  281. package/upstream/tests/brainstorm-server/server.test.js +0 -0
  282. package/upstream/tests/brainstorm-server/windows-lifecycle.test.sh +0 -0
  283. package/upstream/tests/brainstorm-server/ws-protocol.test.js +0 -0
  284. package/upstream/tests/claude-code/README.md +0 -0
  285. package/upstream/tests/claude-code/analyze-token-usage.py +0 -0
  286. package/upstream/tests/claude-code/run-skill-tests.sh +0 -0
  287. package/upstream/tests/claude-code/test-document-review-system.sh +0 -0
  288. package/upstream/tests/claude-code/test-helpers.sh +0 -0
  289. package/upstream/tests/claude-code/test-subagent-driven-development-integration.sh +0 -0
  290. package/upstream/tests/claude-code/test-subagent-driven-development.sh +0 -0
  291. package/upstream/tests/explicit-skill-requests/prompts/action-oriented.txt +0 -0
  292. package/upstream/tests/explicit-skill-requests/prompts/after-planning-flow.txt +0 -0
  293. package/upstream/tests/explicit-skill-requests/prompts/claude-suggested-it.txt +0 -0
  294. package/upstream/tests/explicit-skill-requests/prompts/i-know-what-sdd-means.txt +0 -0
  295. package/upstream/tests/explicit-skill-requests/prompts/mid-conversation-execute-plan.txt +0 -0
  296. package/upstream/tests/explicit-skill-requests/prompts/please-use-brainstorming.txt +0 -0
  297. package/upstream/tests/explicit-skill-requests/prompts/skip-formalities.txt +0 -0
  298. package/upstream/tests/explicit-skill-requests/prompts/subagent-driven-development-please.txt +0 -0
  299. package/upstream/tests/explicit-skill-requests/prompts/use-systematic-debugging.txt +0 -0
  300. package/upstream/tests/explicit-skill-requests/run-all.sh +0 -0
  301. package/upstream/tests/explicit-skill-requests/run-claude-describes-sdd.sh +0 -0
  302. package/upstream/tests/explicit-skill-requests/run-extended-multiturn-test.sh +0 -0
  303. package/upstream/tests/explicit-skill-requests/run-haiku-test.sh +0 -0
  304. package/upstream/tests/explicit-skill-requests/run-multiturn-test.sh +0 -0
  305. package/upstream/tests/explicit-skill-requests/run-test.sh +0 -0
  306. package/upstream/tests/opencode/run-tests.sh +0 -0
  307. package/upstream/tests/opencode/setup.sh +0 -0
  308. package/upstream/tests/opencode/test-plugin-loading.sh +0 -0
  309. package/upstream/tests/opencode/test-priority.sh +0 -0
  310. package/upstream/tests/opencode/test-tools.sh +0 -0
  311. package/upstream/tests/skill-triggering/prompts/dispatching-parallel-agents.txt +0 -0
  312. package/upstream/tests/skill-triggering/prompts/executing-plans.txt +0 -0
  313. package/upstream/tests/skill-triggering/prompts/requesting-code-review.txt +0 -0
  314. package/upstream/tests/skill-triggering/prompts/systematic-debugging.txt +0 -0
  315. package/upstream/tests/skill-triggering/prompts/test-driven-development.txt +0 -0
  316. package/upstream/tests/skill-triggering/prompts/writing-plans.txt +0 -0
  317. package/upstream/tests/skill-triggering/run-all.sh +0 -0
  318. package/upstream/tests/skill-triggering/run-test.sh +0 -0
  319. package/upstream/tests/subagent-driven-dev/go-fractals/design.md +0 -0
  320. package/upstream/tests/subagent-driven-dev/go-fractals/plan.md +0 -0
  321. package/upstream/tests/subagent-driven-dev/go-fractals/scaffold.sh +0 -0
  322. package/upstream/tests/subagent-driven-dev/run-test.sh +0 -0
  323. package/upstream/tests/subagent-driven-dev/svelte-todo/design.md +0 -0
  324. package/upstream/tests/subagent-driven-dev/svelte-todo/plan.md +0 -0
  325. package/upstream/tests/subagent-driven-dev/svelte-todo/scaffold.sh +0 -0
  326. package/custom/skills/test-skills/rules/Directory_and_Naming_Convention.md +0 -257
@@ -13,9 +13,9 @@ Các skill sau đây được cài tự động vào `.claude/skills/test-skills
13
13
 
14
14
  | Skill | File |
15
15
  |---|---|
16
- | `QA Writing Standards` | `.claude/skills/test-skills/rules/QA_Writing_Standards.md` |
17
- | `Directory & Naming Convention` | `.claude/skills/test-skills/rules/Directory_and_Naming_Convention.md` |
18
- | `Template TestCase` | `.claude/skills/test-skills/template/template_testcase.md` |
16
+ | `QA Writing Standards` | `.claude/skills/test-skills/rules/qa-writing-standards.md` |
17
+ | `Directory & Naming Convention` | `.claude/skills/test-skills/rules/directory-and-naming-convention.md` |
18
+ | `Template TestCase` | `.claude/skills/test-skills/template/testcase-template.md` |
19
19
  | `00.01 Requirement Analysis` | `.claude/skills/test-skills/categories/00-core/00.01.requirement-analysis.md` |
20
20
  | `00.02 Risk Analysis` | `.claude/skills/test-skills/categories/00-core/00.02.risk-analysis.md` |
21
21
  | `00.03 Test Scenario Builder` | `.claude/skills/test-skills/categories/00-core/00.03.test-scenario-builder.md` |
@@ -46,40 +46,40 @@ Các skill sau đây được cài tự động vào `.claude/skills/test-skills
46
46
  ### Cấu trúc thư mục đầu ra
47
47
 
48
48
  ```
49
- docs/ak-{project}/testcase/
50
- ├── Result/
51
- ├── [functionId]_01_Requirement_Analysis_Result.md ← Gate 1 tạo
52
- │ ├── [functionId]_02_Test_Scenarios_Result.md ← Gate 2 tạo
53
- │ ├── [functionId]_03_Test_Cases_Draft_Result.md ← Gate 3 tạo
54
- │ └── [functionId]_04_Test_Cases_Final_Result.md ← Gate 4 tạo (đồng thời với TestCase)
55
- ├── QA/
56
- ├── [functionId]_01_Requirement_Analysis_QA.md ← Gate 1 tạo (nếu có issue)
57
- ├── [functionId]_02_Scenario_Building_QA.md ← Gate 2 tạo (nếu có issue)
58
- ├── [functionId]_03_Test_Design_QA.md ← Gate 3 tạo (nếu có issue)
59
- │ └── [functionId]_04_Test_Review_QA.md ← Gate 4 tạo
60
- └── TestCase/
61
- └── [functionId]_TestCase.md ← Gate 4 tạo đồng thời với 04_Final_Result
49
+ 03.Testing/
50
+ ├── 01.Testcases/
51
+ └── [functionId]/[functionId]_TestCase.md ← Gate 4 tạo
52
+ └── 07.AI-Artifacts/
53
+ └── [functionId]/
54
+ ├── [functionId]_01_Requirement_Analysis_Result.md ← Gate 1 tạo
55
+ ├── [functionId]_01_Requirement_Analysis_QA.md ← Gate 1 tạo (nếu có issue)
56
+ ├── [functionId]_02_Test_Scenarios_Result.md ← Gate 2 tạo
57
+ ├── [functionId]_02_Scenario_Building_QA.md ← Gate 2 tạo (nếu có issue)
58
+ ├── [functionId]_03_Test_Cases_Draft_Result.md ← Gate 3 tạo
59
+ ├── [functionId]_03_Test_Design_QA.md ← Gate 3 tạo (nếu có issue)
60
+ ├── [functionId]_04_Test_Cases_Final_Result.md ← Gate 4 tạo (cùng TestCase)
61
+ └── [functionId]_04_Test_Review_QA.md ← Gate 4 tạo
62
62
  ```
63
63
 
64
- Ví dụ: `functionId = AD06`, `project = kcandy` → thư mục gốc là `docs/ak-kcandy/testcase/`
64
+ Ví dụ: `functionId = AD06` → thư mục gốc là `03.Testing/`
65
65
 
66
66
  ---
67
67
 
68
68
  ### Quy trình tổng quan 4 Gates
69
69
 
70
70
  ```
71
- (testcase/ = docs/ak-{project}/testcase/ — viết tắt cho ngắn gọn)
71
+ (AI-Artifacts/ = 03.Testing/07.AI-Artifacts/ — viết tắt cho ngắn gọn)
72
72
 
73
- [Input: SRS / Jira / Backlog / Spec file] → Pre-flight: xác định functionId + thư mục đầu ra
73
+ [Input: SRS / Jira / Backlog / Spec file] → Pre-flight: BẮT BUỘC xác định functionId
74
74
 
75
- Gate 1: Phân tích yêu cầu & Đánh giá rủi ro → testcase/Result/ + testcase/QA/
75
+ Gate 1: Phân tích yêu cầu & Đánh giá rủi ro → AI-Artifacts/[functionId]/
76
76
  ↓ APPROVED
77
- Gate 2: Xây dựng Kịch bản (Scenario Building) → testcase/Result/ + testcase/QA/
77
+ Gate 2: Xây dựng Kịch bản (Scenario Building) → AI-Artifacts/[functionId]/
78
78
  ↓ APPROVED
79
- Gate 3: Thiết kế Test Case chi tiết → testcase/Result/ + testcase/QA/
79
+ Gate 3: Thiết kế Test Case chi tiết → AI-Artifacts/[functionId]/
80
80
  ↓ APPROVED
81
- Gate 4: Review & Tối ưu hóa → testcase/Result/ + testcase/QA/
82
- + testcase/TestCase/[functionId]_TestCase.md
81
+ Gate 4: Review & Tối ưu hóa → AI-Artifacts/[functionId]/
82
+ + 03.Testing/01.Testcases/[functionId]/[functionId]_TestCase.md
83
83
  ↓ APPROVED (Fully / Conditionally)
84
84
  Sẵn sàng thực thi kiểm thử
85
85
  ```
@@ -88,57 +88,47 @@ Sẵn sàng thực thi kiểm thử
88
88
 
89
89
  ### GATE 1 — Phân tích yêu cầu & Đánh giá rủi ro (auto-start)
90
90
 
91
- **Mục tiêu:** Tiếp nhận đầu vào, hiểu nghiệp vụ, xác định phạm vi kiểm thử, nhận diện rủi ro và phát hiện vấn đề cần làm trước khi xây dựng kịch bản.
91
+ **Mục tiêu:** Tiếp nhận đầu vào, hiểu nghiệp vụ, xác định phạm vi kiểm thử, nhận diện rủi ro và **đào sâu làm rõ toàn bộ vấn đề hồ ngay tại gate này** (hỏi QA từng câu một, tiếp tục đến khi hết nghi vấn Critical/Major) — để Gate 2, 3, 4 phía sau hiếm khi phải dừng lại hỏi thêm.
92
92
 
93
93
  **Đầu ra (Outputs):**
94
- - `docs/ak-{project}/testcase/Result/[functionId]_01_Requirement_Analysis_Result.md`
95
- - `docs/ak-{project}/testcase/QA/[functionId]_01_Requirement_Analysis_QA.md` (nếu có issue)
94
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_Result.md`
95
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_QA.md` (nếu có issue)
96
96
 
97
97
  **Bước thực hiện:**
98
98
 
99
99
  #### Bước 0: Pre-flight — Xác định functionId và thư mục đầu ra
100
100
 
101
- **Xác định `functionId`:**
101
+ **Xác định `functionId` (BẮT BUỘC):**
102
102
 
103
103
  Kiểm tra theo thứ tự ưu tiên:
104
104
  1. Trường `functionId` hoặc `screenId` trong `.aiflow/context/current.json`
105
105
  2. Rút gọn từ `ticketId` — bỏ dấu gạch, giữ ký hiệu (ví dụ: `AD-06` → `AD06`)
106
- 3. Nếu không tìm thấy → **hỏi QA ngay**:
106
+ 3. Nếu không tìm thấy → **BẮT BUỘC hỏi QA ngay**:
107
107
 
108
108
  ```
109
109
  Không tìm thấy functionId trong context.
110
110
  Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-LOGIN, PM-003):
111
111
  ```
112
112
 
113
- → Đợi QA trả lời, ghi nhận giá trị, dùng cho toàn bộ workflow.
113
+ → Đợi QA trả lời, ghi nhận giá trị, dùng cho toàn bộ workflow. KHÔNG ĐƯỢC TIẾP TỤC NẾU CHƯA CÓ functionId.
114
114
 
115
- **Xác định `{project}` và thư mục đầu ra:**
115
+ **Xác định thư mục đầu ra:**
116
116
 
117
- 1. Lấy `{project}` theo thứ tự ưu tiên:
118
- - Trường `project` trong `.aiflow/context/current.json`
119
- - Tên thư mục gốc workspace (chuyển lowercase, thay space bằng `-`)
120
-
121
- 2. Kiểm tra tồn tại thư mục `docs/ak-{project}/testcase/` trong root dự án:
117
+ 1. Kiểm tra tồn tại thư mục `03.Testing/` trong root dự án:
122
118
  - **Tìm thấy** → thông báo xác nhận:
123
119
  ```
124
- ✓ Thư mục đầu ra: docs/ak-{project}/testcase/
120
+ ✓ Thư mục đầu ra: 03.Testing/
125
121
  ✓ functionId: [functionId]
126
122
  → Bắt đầu Gate 1...
127
123
  ```
128
- - **Không tìm thấy** → **hỏi QA**:
129
- ```
130
- Không tìm thấy thư mục docs/ak-{project}/testcase/.
131
- Tên project là gì? (ví dụ: kcandy, crm-app)
132
- ```
133
- → Nhận tên project từ QA → chuyển lowercase → tạo toàn bộ cây thư mục:
124
+ - **Không tìm thấy** → tạo toàn bộ cây thư mục:
134
125
  ```
135
- docs/ak-{project}/testcase/Result/
136
- docs/ak-{project}/testcase/QA/
137
- docs/ak-{project}/testcase/TestCase/
126
+ 03.Testing/01.Testcases/[functionId]/
127
+ 03.Testing/07.AI-Artifacts/[functionId]/
138
128
  ```
139
129
  → Thông báo:
140
130
  ```
141
- ✓ Đã tạo thư mục: docs/ak-{project}/testcase/
131
+ ✓ Đã tạo thư mục: 03.Testing/
142
132
  ✓ functionId: [functionId]
143
133
  → Bắt đầu Gate 1...
144
134
  ```
@@ -150,7 +140,7 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
150
140
  - Nếu có file yêu cầu thô được chỉ định → đọc file đó
151
141
 
152
142
  #### Bước 2: Phân tích yêu cầu và đánh giá rủi ro
153
- - **READ skill:** `.claude/skills/test-skills/rules/QA_Writing_Standards.md` — đọc trước để nắm quy ước chung
143
+ - **READ skill:** `.claude/skills/test-skills/rules/qa-writing-standards.md` — đọc trước để nắm quy ước chung
154
144
  - **READ skill:** `.claude/skills/test-skills/categories/00-core/00.01.requirement-analysis.md`
155
145
  - **READ skill:** `.claude/skills/test-skills/categories/00-core/00.02.risk-analysis.md`
156
146
  - Phân tích đầy đủ **16 mục** theo skill 00.01:
@@ -171,17 +161,24 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
171
161
  15. Risk / điểm dễ lỗi
172
162
  16. Q&A / Out of Scope
173
163
  - Đánh giá rủi ro theo skill 00.02: kỹ thuật, dữ liệu, nghiệp vụ, hệ thống
174
- - **Issue Handling:**
175
- - Critical/Major DỪNG, tạo QA artifact, chờ phản hồi (không sinh Result artifact)
176
- - Minor Ghi TBD marker (`[TBD<issue-id>: tả]`), tiếp tục, carry-forward sang gate sau
164
+
165
+ #### Bước 2b: Đào sâu làm với QA/Stakeholder (Interactive Clarification)
166
+ **Mục tiêu:** xử dứt điểm mọi mơ hồ/nghi vấn ngay tại Gate 1 đây gate DUY NHẤT được phép dừng lại hỏi tự do; Gate 2-4 sau đó chỉ hỏi cho phát sinh thực sự mới (xem quy tắc ở các Gate đó).
167
+
168
+ - **Critical/Major** → **KHÔNG** chỉ gộp vào một file QA rồi im lặng chờ. Hỏi ngay trong hội thoại theo đúng Interaction Rule đã khai báo (hỏi **TỪNG CÂU MỘT**, đợi QA trả lời rồi mới hỏi câu tiếp theo, KHÔNG hỏi dồn nhiều câu):
169
+ - Với mỗi nghi vấn ở mục 16 (Q&A/Out of Scope) hoặc phát sinh trong lúc phân tích 16 mục, ưu tiên đề xuất 2-3 cách hiểu/giả định hợp lý để QA chọn nhanh (multiple-choice) thay vì hỏi mở.
170
+ - Tiếp tục hỏi tuần tự, đào sâu thêm nếu câu trả lời còn hé lộ nghi vấn mới, cho đến khi **không còn Critical/Major nào chưa rõ**.
171
+ - Không sinh Result artifact (Bước 3) trước khi toàn bộ Critical/Major đã được làm rõ.
172
+ - **Minor** → Ghi TBD marker (`[TBD — <issue-id>: mô tả]`), tiếp tục, carry-forward sang gate sau (không cần dừng hỏi).
177
173
 
178
174
  #### Bước 3: Soạn thảo kết quả phân tích yêu cầu
179
175
  - Artifact đầu ra phải có: Feature Summary, Actor & Persona, Business Rules (16 mục), Risk Matrix, Test Scope
180
- - Lưu: `docs/ak-{project}/testcase/Result/[functionId]_01_Requirement_Analysis_Result.md`
176
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_Result.md`
181
177
 
182
- #### Bước 4: Soạn thảo QA Artifact (nếu có issue)
183
- - Cấu trúc: Metadata, Detected Issues (Severity), Clarification Questions, Assumptions, Resolution Tracking
184
- - Lưu: `docs/ak-{project}/testcase/QA/[functionId]_01_Requirement_Analysis_QA.md`
178
+ #### Bước 4: Soạn thảo QA Artifact (biên bản resolution, nếu có issue)
179
+ - File này ghi lại **kết quả** của Bước 2b (đã hỏi gì, QA trả lời gì) không phải chế dừng chính.
180
+ - Cấu trúc: Metadata, Detected Issues (Severity), Clarification Questions kèm Câu trả lời đã nhận, Assumptions, Resolution Tracking
181
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_QA.md`
185
182
 
186
183
  #### Bước 5: Gate Review & Pause
187
184
  - **INVOKE** `gate-review` skill (generate mode) — ghi `.aiflow/review/gate-1-[functionId].md`
@@ -193,9 +190,10 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
193
190
  → Nếu blocked: làm theo gate-review skill response protocol
194
191
 
195
192
  **Definition of Done:**
196
- - [ ] `functionId` và `{project}` đã được xác định, thư mục đầu ra đã sẵn sàng
193
+ - [ ] `functionId` đã được xác định, thư mục đầu ra đã sẵn sàng
197
194
  - [ ] File `01_Requirement_Analysis_Result.md` có đủ 16 mục + Risk Matrix + Test Scope
198
- - [ ] File `01_Requirement_Analysis_QA.md` đã tạo nếu issue (Critical/Major đã giải quyết)
195
+ - [ ] Toàn bộ Critical/Major đã được hỏi trực tiếp (từng câu một) và có câu trả lời từ QA — không còn nghi vấn bỏ ngỏ
196
+ - [ ] File `01_Requirement_Analysis_QA.md` đã tạo nếu có issue, ghi lại đầy đủ câu hỏi + câu trả lời (Bước 2b)
199
197
  - [ ] Không có giả định nào được tự ý chốt thành fact mà không đưa vào QA
200
198
 
201
199
  > **Telemetry:** Run `ak gate 1 start --ticket [functionId]` khi bắt đầu gate này.
@@ -210,11 +208,11 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
210
208
  **Điều kiện vào Gate 2:** Gate 1 đã **APPROVED** và `01_Requirement_Analysis_Result.md` đã hoàn chỉnh.
211
209
 
212
210
  **Đầu vào (Inputs):**
213
- - `docs/ak-{project}/testcase/Result/[functionId]_01_Requirement_Analysis_Result.md`
211
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_Result.md`
214
212
 
215
213
  **Đầu ra (Outputs):**
216
- - `docs/ak-{project}/testcase/Result/[functionId]_02_Test_Scenarios_Result.md`
217
- - `docs/ak-{project}/testcase/QA/[functionId]_02_Scenario_Building_QA.md` (nếu có issue)
214
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_02_Test_Scenarios_Result.md`
215
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_02_Scenario_Building_QA.md` (nếu có issue)
218
216
 
219
217
  **Bước thực hiện:**
220
218
 
@@ -245,10 +243,11 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
245
243
  - Cột: Scenario ID, Feature/Module, Check List, Scenario Type, Target Req ID, Priority, Test Data
246
244
  - Business Flow Mapping (E2E diagram dạng text)
247
245
  - Draft RTM (Scenario ID → Requirement ID từ `01_Requirement_Analysis_Result.md`)
248
- - Lưu: `docs/ak-{project}/testcase/Result/[functionId]_02_Test_Scenarios_Result.md`
246
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_02_Test_Scenarios_Result.md`
249
247
 
250
- #### Bước 5: Soạn thảo QA Artifact (nếu có issue)
251
- - Lưu: `docs/ak-{project}/testcase/QA/[functionId]_02_Scenario_Building_QA.md`
248
+ #### Bước 5: Soạn thảo QA Artifact (nếu có issue — NGOẠI LỆ)
249
+ - **Chỉ tạo khi có vấn đề THỰC SỰ MỚI**, chỉ lộ ra khi xây dựng kịch bản (vd: một nhánh luồng nghiệp vụ không thấy được ở mức phân tích yêu cầu). **KHÔNG** hỏi lại điều đã có câu trả lời/assumption trong `01_Requirement_Analysis_Result.md` hoặc `01_Requirement_Analysis_QA.md` — đọc lại 2 file đó trước khi quyết định hỏi thêm.
250
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_02_Scenario_Building_QA.md`
252
251
  - Minor issues → TBD marker + carry-forward, tiếp tục workflow
253
252
 
254
253
  #### Bước 6: Gate Review & Pause
@@ -279,18 +278,18 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
279
278
  **Điều kiện vào Gate 3:** Gate 2 đã **APPROVED** và `02_Test_Scenarios_Result.md` đã hoàn chỉnh.
280
279
 
281
280
  **Đầu vào (Inputs):**
282
- - `docs/ak-{project}/testcase/Result/[functionId]_01_Requirement_Analysis_Result.md`
283
- - `docs/ak-{project}/testcase/Result/[functionId]_02_Test_Scenarios_Result.md`
281
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_Result.md`
282
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_02_Test_Scenarios_Result.md`
284
283
 
285
284
  **Đầu ra (Outputs):**
286
- - `docs/ak-{project}/testcase/Result/[functionId]_03_Test_Cases_Draft_Result.md`
287
- - `docs/ak-{project}/testcase/QA/[functionId]_03_Test_Design_QA.md` (nếu có issue)
285
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_03_Test_Cases_Draft_Result.md`
286
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_03_Test_Design_QA.md` (nếu có issue)
288
287
 
289
288
  **Bước thực hiện:**
290
289
 
291
290
  #### Bước 1: Đọc template và quy ước bắt buộc
292
- - **READ template:** `.claude/skills/test-skills/template/template_testcase.md` — **BẮT BUỘC** tuân thủ 100%
293
- - **READ skill:** `.claude/skills/test-skills/rules/QA_Writing_Standards.md`
291
+ - **READ template:** `.claude/skills/test-skills/template/testcase-template.md` — **BẮT BUỘC** tuân thủ 100%
292
+ - **READ skill:** `.claude/skills/test-skills/rules/qa-writing-standards.md`
294
293
 
295
294
  #### Bước 2: Áp dụng kỹ thuật thiết kế TC cơ bản (luôn áp dụng)
296
295
  - **READ:** `.claude/skills/test-skills/categories/01-test-design/01.01.boundary-value-analysis.md` — BVA cho tất cả trường số/text có giới hạn
@@ -329,10 +328,11 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
329
328
  - **Section 3.5**: Exceptions & Systems (Error Guessing cases)
330
329
  - Bổ sung: Coverage Matrix (Scenario ID → TC ID), Test Data tổng hợp
331
330
  - Ghi TBD marker khi thiếu thông tin: `[TBD — <issue-id>: mô tả ngắn]`
332
- - Lưu: `docs/ak-{project}/testcase/Result/[functionId]_03_Test_Cases_Draft_Result.md`
331
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_03_Test_Cases_Draft_Result.md`
333
332
 
334
- #### Bước 7: Soạn thảo QA Artifact (nếu có issue)
335
- - Lưu: `docs/ak-{project}/testcase/QA/[functionId]_03_Test_Design_QA.md`
333
+ #### Bước 7: Soạn thảo QA Artifact (nếu có issue — NGOẠI LỆ)
334
+ - **Chỉ tạo khi có vấn đề THỰC SỰ MỚI**, chỉ lộ ra khi thiết kế test case chi tiết (vd: một tổ hợp dữ liệu biên chưa từng được nhắc tới). **KHÔNG** hỏi lại điều đã có câu trả lời/assumption trong artifact của Gate 1 hoặc Gate 2 — đọc lại các file đó trước khi quyết định hỏi thêm.
335
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_03_Test_Design_QA.md`
336
336
  - Cấu trúc: Metadata, Detected Issues, Clarification Questions, Assumptions, Resolution Tracking
337
337
 
338
338
  #### Bước 8: Gate Review & Pause
@@ -345,7 +345,7 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
345
345
  → Nếu blocked: làm theo gate-review skill response protocol
346
346
 
347
347
  **Definition of Done:**
348
- - [ ] 100% tuân thủ `template_testcase.md` — không tự định nghĩa cấu trúc mới
348
+ - [ ] 100% tuân thủ `testcase-template.md` — không tự định nghĩa cấu trúc mới
349
349
  - [ ] Mọi trường input (cả Required và Optional) đã qua ma trận skill 02.02
350
350
  - [ ] TC Name section 3.3 bắt đầu bằng `"Kiểm tra trường [Tên Trường]..."`
351
351
  - [ ] Coverage Matrix mapping Scenario ID → TC ID đầy đủ
@@ -364,13 +364,13 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
364
364
  **Điều kiện vào Gate 4:** Gate 3 đã **APPROVED** và `03_Test_Cases_Draft_Result.md` đã hoàn chỉnh.
365
365
 
366
366
  **Đầu vào (Inputs):**
367
- - `docs/ak-{project}/testcase/Result/[functionId]_01_Requirement_Analysis_Result.md`
368
- - `docs/ak-{project}/testcase/Result/[functionId]_03_Test_Cases_Draft_Result.md`
367
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_01_Requirement_Analysis_Result.md`
368
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_03_Test_Cases_Draft_Result.md`
369
369
 
370
370
  **Đầu ra (Outputs) — sinh ĐỒNG THỜI:**
371
- - `docs/ak-{project}/testcase/Result/[functionId]_04_Test_Cases_Final_Result.md`
372
- - `docs/ak-{project}/testcase/QA/[functionId]_04_Test_Review_QA.md`
373
- - `docs/ak-{project}/testcase/TestCase/[functionId]_TestCase.md`
371
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_04_Test_Cases_Final_Result.md`
372
+ - `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_04_Test_Review_QA.md`
373
+ - `03.Testing/01.Testcases/[functionId]/[functionId]_TestCase.md`
374
374
 
375
375
  > **Quy tắc Gate 4:** Ba artifact trên phải được sinh ĐỒNG THỜI. Không tạo một file mà thiếu file kia.
376
376
 
@@ -401,19 +401,19 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
401
401
  - Final Test Cases (Approved, đã loại trùng và out-of-scope)
402
402
  - RTM Final (Req ID → Scenario ID → TC ID)
403
403
  - Sign-off Status (xem bảng bên dưới)
404
- - Lưu: `docs/ak-{project}/testcase/Result/[functionId]_04_Test_Cases_Final_Result.md`
404
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_04_Test_Cases_Final_Result.md`
405
405
 
406
406
  #### Bước 4: Soạn thảo QA Artifact
407
407
  - Artifact `[functionId]_04_Test_Review_QA.md` gồm: Metadata, Findings, Issues, Sign-off Status
408
- - Lưu: `docs/ak-{project}/testcase/QA/[functionId]_04_Test_Review_QA.md`
408
+ - Lưu: `03.Testing/07.AI-Artifacts/[functionId]/[functionId]_04_Test_Review_QA.md`
409
409
 
410
410
  #### Bước 5: Sinh TestCase Artifact — BẮT BUỘC đồng thời với Bước 3 & 4
411
- - Artifact `[functionId]_TestCase.md` theo `template_testcase.md` — **chỉ gồm:**
411
+ - Artifact `[functionId]_TestCase.md` theo `testcase-template.md` — **chỉ gồm:**
412
412
  - **Mục 1**: Thông tin chung (điền functionId, ngày tạo)
413
413
  - **Mục 2**: Kết quả kiểm thử tổng hợp (reset về 0 chờ execution)
414
414
  - **Mục 3**: Danh sách Test Cases Chi Tiết (toàn bộ 5 sections đã Approved)
415
415
  - **KHÔNG chứa:** Review Summary, Findings, RTM, Coverage Matrix, Sign-off (thuộc `04_Final_Result.md`)
416
- - Lưu: `docs/ak-{project}/testcase/TestCase/[functionId]_TestCase.md`
416
+ - Lưu: `03.Testing/01.Testcases/[functionId]/[functionId]_TestCase.md`
417
417
 
418
418
  #### Bước 6: Xác nhận Sign-off Status
419
419
 
@@ -451,7 +451,7 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
451
451
  |---|---|---|
452
452
  | Gate 1 | `QA_Writing_Standards`, `00.01 Requirement Analysis`, `00.02 Risk Analysis` | `01_Requirement_Analysis_Result.md`, `01_QA.md` |
453
453
  | Gate 2 | `00.03 Scenario Builder`, `01.06 Error Guessing`, `03.02 Workflow Testing`, Domain skills | `02_Test_Scenarios_Result.md`, `02_QA.md` |
454
- | Gate 3 | `template_testcase`, `01.01 BVA`, `01.02 EP`, `01.03 Decision Table`, `01.06 Error Guessing`, `02.01`–`02.04`, `03.01`, `03.03`, `04.01`, `04.04` | `03_Test_Cases_Draft_Result.md`, `03_QA.md` |
454
+ | Gate 3 | `testcase-template`, `01.01 BVA`, `01.02 EP`, `01.03 Decision Table`, `01.06 Error Guessing`, `02.01`–`02.04`, `03.01`, `03.03`, `04.01`, `04.04` | `03_Test_Cases_Draft_Result.md`, `03_QA.md` |
455
455
  | Gate 4 | `00.04 TC Review`, `99.01 Coverage Review` | `04_Final_Result.md`, `04_QA.md`, `[functionId]_TestCase.md` |
456
456
 
457
457
  ---
@@ -465,6 +465,8 @@ Vui lòng cung cấp mã định danh cho chức năng này (ví dụ: AD06, TC-
465
465
  - ✅ **BẮT BUỘC** chạy Bước 0 ở Gate 1 — xác nhận `functionId` và thư mục đầu ra trước khi làm bất cứ điều gì
466
466
  - ✅ **BẮT BUỘC** đọc skill từ `.claude/skills/test-skills/` — không suy luận từ bộ nhớ
467
467
  - ✅ **BẮT BUỘC** invoke `gate-review` cuối mỗi gate và chờ APPROVED
468
- - ✅ **BẮT BUỘC** tuân thủ 100% `template_testcase.md` ở Gate 3 và Gate 4
468
+ - ✅ **BẮT BUỘC** tuân thủ 100% `testcase-template.md` ở Gate 3 và Gate 4
469
469
  - ✅ **BẮT BUỘC** ba artifact Gate 4 sinh ĐỒNG THỜI
470
470
  - ✅ **BẮT BUỘC** Issue Critical/Major phải giải quyết xong trước khi sinh Result artifact
471
+ - ✅ **BẮT BUỘC** Gate 1 là gate đào sâu Q&A chính — hỏi QA từng câu một (Bước 2b) cho đến khi hết nghi vấn Critical/Major, trước khi chuyển Gate 2
472
+ - ❌ **KHÔNG** ở Gate 2-4 tạo QA artifact/hỏi lại cho vấn đề đã có câu trả lời hoặc assumption rõ ràng trong artifact của gate trước — QA artifact ở các gate này chỉ dành cho phát sinh THỰC SỰ MỚI
@@ -29,28 +29,69 @@ If `taskType` is missing or unrecognized, default to the DEV workflow and ask ON
29
29
 
30
30
  > **For:** `feature` · `bug-fix` · `refactor` · `investigation` · `documentation`
31
31
 
32
+ ### Cấu trúc thư mục đầu ra
33
+
34
+ ```
35
+ 04.Coding/
36
+ ├── 00.Overview/_Index.md ← Tracker: F-ID | Ticket | Dev | Gate | PR (cập nhật mỗi gate)
37
+ ├── 01.Requirements/[functionId]/[ticketId].md ← Gate 1 tạo
38
+ ├── 02.Plans/[functionId]/[ticketId].md ← Gate 2 tạo
39
+ ├── 03.TDD-Notes/[functionId]/[ticketId].md ← Gate 3 tạo
40
+ ├── 04.Reviews/[functionId]/[ticketId].md ← Gate 4 tạo
41
+ └── 05.Pull-Requests/[functionId]/[ticketId].md ← Gate 5 tạo
42
+ ```
43
+
44
+ - `[functionId]`: mã định danh chức năng **do dự án quy định** (ví dụ `F-001_User-Login`, `AD06`, `UC-LOGIN`) — không ép format. Một feature có thể có nhiều ticket → folder theo functionId, file theo ticketId.
45
+ - `[ticketId]`: lấy từ `taskId` trong `.aiflow/context/current.json` (ví dụ `TICKET-100.md`).
46
+
32
47
  ### GATE 1 — AI Analyze Requirement (auto-start)
33
48
 
34
49
  **INVOKE:** `read-study-requirement` skill
35
50
 
36
51
  AI actively reads ticket + source code to understand the requirement:
52
+
53
+ 0. **Pre-flight — xác định `functionId` và thư mục đầu ra (BẮT BUỘC):**
54
+
55
+ Kiểm tra theo thứ tự ưu tiên:
56
+ 1. Trường `functionId` hoặc `screenId` trong `.aiflow/context/current.json`
57
+ 2. **Suy ra từ input**: nếu đầu vào có file UC Spec / tài liệu do BA bàn giao (trong `supplementaryContext[]`, description, hoặc file được chỉ định khi `ak use <file>`) → đọc nội dung file để tìm functionId, hoặc suy từ đường dẫn thư mục chứa file (ví dụ file nằm ở `02.BA-Specs/04.UC-Specs/[functionId]/UC-Spec_v1.md` → lấy `[functionId]`). Có thể tra thêm `04.Coding/00.Overview/_Index.md` hoặc `00.Project-Overview/Function-List.md` theo tên feature.
58
+ → Tìm được ứng viên → **hỏi xác nhận** thay vì hỏi trống:
59
+ ```
60
+ functionId của task này có phải là [X] không? (Y / hoặc nhập giá trị đúng)
61
+ ```
62
+ 3. Không suy ra được → hỏi DEV trực tiếp:
63
+ ```
64
+ Không tìm thấy functionId trong context.
65
+ Vui lòng cung cấp mã định danh chức năng theo quy ước dự án (ví dụ: F-001_User-Login, AD06):
66
+ ```
67
+
68
+ → Đợi DEV trả lời, dùng giá trị này cho toàn bộ 5 Gates. **KHÔNG ĐƯỢC TIẾP TỤC NẾU CHƯA CÓ functionId.**
69
+
70
+ Sau đó kiểm tra thư mục `04.Coding/` trong root dự án — chưa có thì tạo đủ cây thư mục (00.Overview → 05.Pull-Requests) và file tracker `00.Overview/_Index.md`. Thông báo:
71
+ ```
72
+ ✓ Thư mục đầu ra: 04.Coding/
73
+ ✓ functionId: [functionId] ✓ ticketId: [ticketId]
74
+ → Bắt đầu Gate 1...
75
+ ```
76
+
37
77
  1. Read `.aiflow/context/current.json` — ticket info
38
78
  2. **Pre-flight: sync with remote** — run `git status --porcelain`; if working tree is clean, run `git pull --ff-only` to pull the latest source from remote. Skip the pull (with a `⚠️` notice to DEV) if there are uncommitted changes, the branch has diverged, or no remote tracking branch exists.
39
79
  3. Read source code — architecture, related files, data flow
40
80
  4. If anything is unclear — ask ONE question at a time, wait for reply
41
- 5. Output `plan/[ticket-id]/requirement.md` with:
42
- - Requirements summary, source code analysis
81
+ 5. Output `04.Coding/01.Requirements/[functionId]/[ticketId].md` with:
82
+ - Requirements summary (ticket summary + AC), source code analysis
43
83
  - Proposed solution and approach
44
84
  - Impact analysis, effort estimate, testing plan
45
- 6. **INVOKE** `gate-review` skill (generate mode) write `.aiflow/review/gate-1-[ticket-id].md`
46
- 7. Display gate pause message from `gate-review` skill — wait for **APPROVED**
85
+ 6. Update tracker row in `04.Coding/00.Overview/_Index.md`: `| [F-ID] | [ticketId] | [feature] | [dev] | ✅⬜⬜⬜⬜ Gate 1 | - |`
86
+ 7. **INVOKE** `gate-review` skill (generate mode) write `.aiflow/review/gate-1-[ticket-id].md`
87
+ 8. Display gate pause message from `gate-review` skill — wait for **APPROVED**
47
88
 
48
89
  **When APPROVED received:**
49
90
  → **INVOKE** `gate-review` skill (verify mode) — run `ak review check --gate 1 --ticket [ticket-id]`
50
91
  → If passed: run `ak gate 1 approved --ticket [ticket-id]` → proceed to Gate 2
51
92
  → If blocked: follow gate-review skill response protocol
52
93
 
53
- > **Tip:** If auto-start doesn't trigger, the developer can start this gate by typing: **"start"**, **"Gate 1"** or **"Analyze ticket"**.
94
+ > **Tip:** If auto-start doesn't trigger, the developer can start this gate by typing: **"start"**, **"Gate 1"** or **"Analyze ticket"**. If this chat session was already open when the ticket was loaded (`ak use`), those phrases won't mean anything to the AI yet since the `SessionStart` hook did not re-run — run **`/coding`** instead to load the ticket context manually.
54
95
 
55
96
  DO NOT just check format — **understand the content and propose solutions**.
56
97
 
@@ -63,8 +104,9 @@ DO NOT just check format — **understand the content and propose solutions**.
63
104
 
64
105
  **INVOKE:** `generate-spec` skill, then `superpowers:writing-plans`
65
106
 
66
- - Create a detailed TDD implementation plan based on the approved requirement.
67
- - Output `plan/[ticket-id]/plan.md` with the detailed TDD implementation plan.
107
+ - Create a detailed TDD implementation plan based on the approved requirement (`04.Coding/01.Requirements/[functionId]/[ticketId].md`).
108
+ - Output `04.Coding/02.Plans/[functionId]/[ticketId].md` with the detailed TDD implementation plan (step-by-step, file list, test-first order).
109
+ - Update tracker row in `04.Coding/00.Overview/_Index.md` (Gate 2 ✅).
68
110
  - **INVOKE** `gate-review` skill (generate mode) — write `.aiflow/review/gate-2-[ticket-id].md`
69
111
  - Display gate pause message from `gate-review` skill — CODE WILL NOT BE GENERATED until all items checked and APPROVED received.
70
112
 
@@ -86,6 +128,10 @@ Only runs after Gate 2 has been APPROVED.
86
128
  - Complex feature (3+ files): `superpowers:subagent-driven-development`
87
129
  - Write tests FIRST — run to confirm FAIL -> implement -> PASS.
88
130
  - Bug fix EXTRA: `superpowers:systematic-debugging` + `investigate-bug` skill first.
131
+ - Output `04.Coding/03.TDD-Notes/[functionId]/[ticketId].md`:
132
+ - **Test List** — danh sách test viết TRƯỚC khi implement (checklist `- [ ] TC-01: ...`)
133
+ - **Implementation Notes** — ghi chú phát sinh trong quá trình code
134
+ - Update tracker row in `04.Coding/00.Overview/_Index.md` (Gate 3 ✅) when tests PASS.
89
135
 
90
136
  > **Telemetry:** Run `ak gate 3 start --ticket [ticket-id]` when starting this gate. Run as-is — do NOT append shell redirects.
91
137
 
@@ -99,7 +145,8 @@ Mandatory order:
99
145
  1. `superpowers:verification-before-completion` — all tests must PASS
100
146
  2. `impact-analysis` skill — check for breaking changes
101
147
  3. Tick `custom/rules/review-checklist.md`
102
- 4. Create `plan/[ticket-id]/summary.md`
148
+ 4. Create `04.Coding/04.Reviews/[functionId]/[ticketId].md` — Test Results, Impact Analysis (files changed, affected features, breaking changes), Review Checklist
149
+ 5. Update tracker row in `04.Coding/00.Overview/_Index.md` (Gate 4 ✅)
103
150
 
104
151
  Then:
105
152
  - **INVOKE** `gate-review` skill (generate mode) — write `.aiflow/review/gate-4-[ticket-id].md`
@@ -124,7 +171,13 @@ Then:
124
171
  Only runs after Gate 4 has been APPROVED.
125
172
 
126
173
  **INVOKE:** `superpowers:requesting-code-review`
127
- Guide on creating a Pull Request with the ticket link.
174
+
175
+ 1. Create `04.Coding/05.Pull-Requests/[functionId]/[ticketId].md` — PR description gồm:
176
+ - Ticket link, danh sách thay đổi chính, How to Test, Checklist for Reviewer
177
+ - **Related Docs links:** UC Spec (`02.BA-Specs/04.UC-Specs/[functionId]/`), Test Case (`03.Testing/01.Testcases/[functionId]/`), Dev Plan (`04.Coding/02.Plans/[functionId]/[ticketId].md`)
178
+ 2. **Lưu tài liệu `04.Coding/` lên remote (GitLab) TRƯỚC khi tạo Pull Request.**
179
+ 3. Guide on creating a Pull Request — dùng nội dung file trên làm PR description.
180
+ 4. Update tracker row in `04.Coding/00.Overview/_Index.md` (Gate 5 ✅ Done + PR link).
128
181
 
129
182
  > **Telemetry:** Run `ak gate 5 start --ticket [ticket-id]` when starting this gate. Run as-is — do NOT append shell redirects.
130
183
 
@@ -357,7 +410,7 @@ Coverage: [N]% acceptance criteria
357
410
 
358
411
  ### GATE 1 — Pre-flight & Work Plan (auto-start)
359
412
 
360
- **INVOKE:** `execute-flow` skill (from `custom/skills/execute-flow/SKILL.md`)
413
+ **INVOKE:** `execute-flow` skill (from `custom/skills/test-skills/execute-flow/SKILL.md`)
361
414
 
362
415
  Pre-flight checks (stop and report if any fail):
363
416
  0. **MCP Playwright is configured** — check `~/.claude/settings.json` (global user-level) for a `playwright` key in `mcpServers`. This is global — set once, works across all repos.
@@ -396,7 +449,7 @@ BASE_URL: [url]
396
449
 
397
450
  Only runs after Gate 1 APPROVED.
398
451
 
399
- **INVOKE:** `script-sync` skill (from `custom/skills/script-sync/SKILL.md`)
452
+ **INVOKE:** `script-sync` skill (from `custom/skills/test-skills/script-sync/SKILL.md`)
400
453
 
401
454
  Hash-based TC↔script sync — for each TC in the file:
402
455
  - **New TC** (no matching `@tc-hash` in spec): generate Playwright test using MCP (`browser_navigate` → `browser_snapshot` → `browser_generate_locator`). Never fabricate selectors.
File without changes
File without changes
@@ -1,13 +1,13 @@
1
- # Claude AI System Instructions
2
-
3
- You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
-
5
- > **Important:** Always read `.aiflow/context/current.json` to load ticket context and check the `plan/` directory for existing progress before starting any task.
6
-
7
- If Gate 1 does not auto-start, wait for the developer to type **"start"**, **"Gate 1"** or **"Analyze ticket"**.
8
-
9
- ## Interaction Rules:
10
-
11
- - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
12
- - **NEVER BATCH QUESTIONS:** Only ask one question per message.
13
- - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
1
+ # Claude AI System Instructions
2
+
3
+ You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
+
5
+ > **Important:** Always read `.aiflow/context/current.json` to load ticket context and check the `04.Coding/` docs directory for existing progress before starting any task.
6
+
7
+ If Gate 1 does not auto-start, wait for the developer to type **"start"**, **"Gate 1"** or **"Analyze ticket"**.
8
+
9
+ ## Interaction Rules:
10
+
11
+ - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
12
+ - **NEVER BATCH QUESTIONS:** Only ask one question per message.
13
+ - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
@@ -1,12 +1,12 @@
1
- # GitHub Copilot Custom Instructions
2
-
3
- You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
-
5
- > **Important:** Always check for context in `.aiflow/context/current.json` and progress in the `plan/` folder before suggesting changes.
6
-
7
- If the Gate Workflow hasn't started, wait for the developer to type **"start"** or **"Gate 1"**.
8
-
9
- ## Interaction Rules:
10
- - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
- - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
- - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
1
+ # GitHub Copilot Custom Instructions
2
+
3
+ You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
+
5
+ > **Important:** Always check for context in `.aiflow/context/current.json` and progress in the `04.Coding/` docs folder before suggesting changes.
6
+
7
+ If the Gate Workflow hasn't started, wait for the developer to type **"start"** or **"Gate 1"**.
8
+
9
+ ## Interaction Rules:
10
+ - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
+ - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
+ - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
@@ -1,12 +1,12 @@
1
- # Cursor AI Project Rules
2
-
3
- You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
-
5
- > **Important:** Always check `.aiflow/context/current.json` and the `plan/` directory before starting any task to understand current context and progress.
6
-
7
- If Gate 1 doesn't auto-start, wait for the developer to type **"start"**, **"Gate 1"** or **"Analyze ticket"**.
8
-
9
- ## Interaction Rules:
10
- - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
- - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
- - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
1
+ # Cursor AI Project Rules
2
+
3
+ You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
+
5
+ > **Important:** Always check `.aiflow/context/current.json` and the `04.Coding/` docs directory before starting any task to understand current context and progress.
6
+
7
+ If Gate 1 doesn't auto-start, wait for the developer to type **"start"**, **"Gate 1"** or **"Analyze ticket"**.
8
+
9
+ ## Interaction Rules:
10
+ - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
+ - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
+ - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
@@ -1,22 +1,22 @@
1
- # Gemini AI System Instructions
2
-
3
- You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
-
5
- > **Important:** When starting a session, always read `.aiflow/context/current.json` to load ticket context and check the `plan/` directory for existing progress.
6
-
7
- If no instructions are automatically followed, wait for the developer to type **"start"** or **"Gate 1"** to start the analysis.
8
-
9
- ## Interaction Rules:
10
- - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
- - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
- - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
13
- - **PROJECT CONVENTIONS:** Before writing any output file (plan, requirement, summary), read `custom/rules/project-conventions.md`. These rules override upstream skill defaults.
14
-
15
- ## Telemetry Command (detect once, use everywhere)
16
-
17
- Before the first gate, run this to detect the correct `ak` command for your environment:
18
- ```bash
19
- command -v ak >/dev/null 2>&1 && echo "USE: ak" || echo "USE: ak.cmd"
20
- ```
21
- Use whichever prints (e.g. `ak` on native Linux/Mac/Windows, `ak.cmd` on WSL without ak installed).
22
- All `ak gate ...` examples below assume the detected command. Substitute accordingly.
1
+ # Gemini AI System Instructions
2
+
3
+ You are an expert AI assistant specialized in this project's stack. Follow the Gate Workflow and Team Rules strictly.
4
+
5
+ > **Important:** When starting a session, always read `.aiflow/context/current.json` to load ticket context and check the `04.Coding/` docs directory for existing progress.
6
+
7
+ If no instructions are automatically followed, wait for the developer to type **"start"** or **"Gate 1"** to start the analysis.
8
+
9
+ ## Interaction Rules:
10
+ - **COLLABORATIVE SKILLS:** When a skill (like `read-study-requirement`) says to "ask one question at a time", you MUST stop and wait for the developer's reply before proceeding.
11
+ - **NEVER BATCH QUESTIONS:** Only ask one question per message.
12
+ - **WAIT FOR APPROVAL:** Do not move to the next Gate until you receive "APPROVED".
13
+ - **PROJECT CONVENTIONS:** Before writing any output file (plan, requirement, summary), read `custom/rules/project-conventions.md`. These rules override upstream skill defaults.
14
+
15
+ ## Telemetry Command (detect once, use everywhere)
16
+
17
+ Before the first gate, run this to detect the correct `ak` command for your environment:
18
+ ```bash
19
+ command -v ak >/dev/null 2>&1 && echo "USE: ak" || echo "USE: ak.cmd"
20
+ ```
21
+ Use whichever prints (e.g. `ak` on native Linux/Mac/Windows, `ak.cmd` on WSL without ak installed).
22
+ All `ak gate ...` examples below assume the detected command. Substitute accordingly.