create-yss-spec 3.4.10 → 3.5.2

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 (642) hide show
  1. package/README.md +8 -4
  2. package/package.json +1 -1
  3. package/src/api/_sync-service.js +141 -23
  4. package/src/cli/args.js +3 -0
  5. package/src/cli/help.js +14 -2
  6. package/src/cli/index.js +3 -0
  7. package/src/cli/prompts.js +5 -1
  8. package/src/cli/router.js +2 -0
  9. package/src/commands/attach.js +21 -5
  10. package/src/commands/diff.js +1 -0
  11. package/src/commands/doctor.js +1 -0
  12. package/src/commands/init.js +4 -1
  13. package/src/commands/skills.js +253 -0
  14. package/src/commands/sync.js +4 -0
  15. package/src/family-identity.js +2 -2
  16. package/src/template/asset-runtime.js +228 -0
  17. package/src/template/attach-planner.js +1 -1
  18. package/src/template/distribution-runtime.js +165 -0
  19. package/src/template/instance-runtime.js +76 -29
  20. package/src/template/layout-migration.js +160 -0
  21. package/src/template/migration-runtime.js +2 -2
  22. package/src/template/ownership-policy.js +17 -1
  23. package/src/template/prune-planner.js +6 -1
  24. package/src/template/sync-planner.js +4 -1
  25. package/src/template/verification-runtime.js +56 -1
  26. package/src/validation/metadata.js +24 -1
  27. package/template/.agents/rules/yss-ai-skills.md +1 -1
  28. package/template/.agents/skills/.strategic-design-skills-manifest.json +7 -8
  29. package/template/.agents/skills/.yss-skills-manifest.json +2 -2
  30. package/template/.agents/skills/alibaba-java-code-style/SKILL.md +1 -1
  31. package/template/.agents/skills/code-review/SKILL.md +6 -6
  32. package/template/.agents/skills/code-review/references/yss-review-standards.md +1 -1
  33. package/template/.agents/skills/cross-repo-implementation-routing/SKILL.md +2 -2
  34. package/template/.agents/skills/i-have-adhd/SKILL.md +1 -1
  35. package/template/.agents/skills/i-have-adhd/references/yss-adaptation.md +1 -1
  36. package/template/.agents/skills/i-have-adhd/tests/verify-integration.mjs +2 -2
  37. package/template/.agents/skills/implementation-repo-onboarding/SKILL.md +2 -2
  38. package/template/.agents/skills/llm-wiki/references/discover.md +3 -3
  39. package/template/.agents/skills/prototype-review/SKILL.md +4 -4
  40. package/template/.agents/skills/setup-matt-pocock-skills/SKILL.md +10 -10
  41. package/template/.agents/skills/triage/SKILL.md +1 -1
  42. package/template/.agents/skills/yss-application/references/profiles/layered-mvc-service.md +1 -1
  43. package/template/.agents/skills/yss-application/references/profiles/mvc-data-analysis-v1.md +1 -1
  44. package/template/.agents/skills/yss-backend-spec-review/SKILL.md +1 -1
  45. package/template/.agents/skills/yss-backend-spec-review/references/check-inputs.md +1 -1
  46. package/template/.agents/skills/yss-cache/SKILL.md +6 -5
  47. package/template/.agents/skills/yss-cache/references/annotations.md +3 -1
  48. package/template/.agents/skills/yss-cache/references/architecture.md +4 -2
  49. package/template/.agents/skills/yss-cache/references/configuration.md +6 -3
  50. package/template/.agents/skills/yss-cache/references/jetcache.md +21 -0
  51. package/template/.agents/skills/yss-cache/references/redis-fallback.md +5 -3
  52. package/template/.agents/skills/yss-cache/references/verification.md +10 -4
  53. package/template/.agents/skills/yss-cache/scripts/verify-cache-component.sh +26 -20
  54. package/template/.agents/skills/yss-ddd-scaffold-generator/SKILL.md +2 -2
  55. package/template/.agents/skills/yss-ddd-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  56. package/template/.agents/skills/yss-design-system/SKILL.md +10 -10
  57. package/template/.agents/skills/yss-design-system/references/design-qa-theme.md +3 -3
  58. package/template/.agents/skills/yss-design-system/references/design-system.md +3 -3
  59. package/template/.agents/skills/yss-distributed-id/SKILL.md +14 -58
  60. package/template/.agents/skills/yss-distributed-id/agents/openai.yaml +2 -2
  61. package/template/.agents/skills/yss-distributed-id/references/README.md +11 -47
  62. package/template/.agents/skills/yss-exception/SKILL.md +1 -1
  63. package/template/.agents/skills/yss-frontend-scaffold-generator/SKILL.md +2 -2
  64. package/template/.agents/skills/yss-frontend-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  65. package/template/.agents/skills/yss-frontend-scaffold-generator/scripts/refresh_baseline.mjs +2 -2
  66. package/template/.agents/skills/yss-implementation-contract-compiler/SKILL.md +9 -9
  67. package/template/.agents/skills/yss-implementation-contract-compiler/references/boundaries.md +1 -1
  68. package/template/.agents/skills/yss-implementation-contract-compiler/references/compiler-contract.yaml +9 -9
  69. package/template/.agents/skills/yss-implementation-contract-compiler/references/slice-implementation-contract-v2.md +3 -3
  70. package/template/.agents/skills/yss-implementation-contract-compiler/references/slice-implementation-contract.md +1 -1
  71. package/template/.agents/skills/yss-implementation-contract-compiler/references/strategic-handoff-routing.md +1 -1
  72. package/template/.agents/skills/yss-layered-mvc-scaffold-generator/SKILL.md +2 -2
  73. package/template/.agents/skills/yss-layered-mvc-scaffold-generator/scripts/data-analysis-profile.mjs +5 -5
  74. package/template/.agents/skills/yss-layered-mvc-scaffold-generator/scripts/generate_scaffold.mjs +2 -2
  75. package/template/.agents/skills/yss-layered-mvc-scaffold-generator/scripts/scaffold-generator.test.mjs +42 -0
  76. package/template/.agents/skills/yss-mybatis/SKILL.md +14 -2
  77. package/template/.agents/skills/yss-openapi-draft-review/SKILL.md +2 -2
  78. package/template/.agents/skills/yss-openapi-governance/SKILL.md +7 -7
  79. package/template/.agents/skills/yss-product-lifecycle/SKILL.md +11 -11
  80. package/template/.agents/skills/yss-product-lifecycle/references/matt-yss-adapter.md +5 -5
  81. package/template/.agents/skills/yss-product-lifecycle/references/orchestration-contract.yaml +70 -47
  82. package/template/.agents/skills/yss-product-lifecycle/references/orchestration.md +22 -14
  83. package/template/.agents/skills/yss-product-lifecycle/references/request-triage.md +2 -0
  84. package/template/.agents/skills/yss-product-lifecycle/references/state-model.md +11 -11
  85. package/template/.agents/skills/yss-product-lifecycle/references/user-decisions.md +2 -2
  86. package/template/.agents/skills/yss-prototype-stage/SKILL.md +9 -9
  87. package/template/.agents/skills/yss-prototype-stage/references/existing-ui-entry.md +1 -1
  88. package/template/.agents/skills/yss-prototype-stage/scripts/build-antd-prototype.mjs +1 -1
  89. package/template/.agents/skills/yss-prototype-stage/scripts/offline-html.mjs +3 -3
  90. package/template/.agents/skills/yss-prototype-stage/tests/browser-smoke.mjs +2 -2
  91. package/template/.agents/skills/yss-prototype-stage/tests/run-scenarios.mjs +4 -4
  92. package/template/.agents/skills/yss-prototype-stage/tests/workbench-smoke.mjs +1 -1
  93. package/template/.agents/skills/yss-repository/SKILL.md +3 -2
  94. package/template/.agents/skills/yss-repository/references/profiles/layered-mvc-service.md +1 -1
  95. package/template/.agents/skills/yss-repository/references/profiles/mvc-data-analysis-v1.md +1 -1
  96. package/template/.agents/skills/yss-repository/tests/profile-routing.test.mjs +2 -2
  97. package/template/.agents/skills/yss-research/SKILL.md +2 -2
  98. package/template/.agents/skills/yss-skill-source-index-refresh/references/backend-component-platform-compatibility.md +1 -1
  99. package/template/.agents/skills/yss-stage-decision/SKILL.md +5 -5
  100. package/template/.agents/skills/yss-stage-decision/references/domain-strategy-contract.md +1 -1
  101. package/template/.agents/skills/yss-stage-decision/references/strategic-handoff-routing.md +1 -1
  102. package/template/.agents/skills/yss-tactical-design/SKILL.md +2 -2
  103. package/template/.agents/skills/yss-tactical-design/references/strategic-handoff-routing.md +1 -1
  104. package/template/.agents/skills/yss-tactical-design/references/tactical-design-contract.md +1 -1
  105. package/template/.agents/skills/yss-technical-design/SKILL.md +6 -6
  106. package/template/.agents/skills/yss-technical-design/references/technical-design-contract.md +1 -1
  107. package/template/.agents/skills/yss-ui/SKILL.md +1 -1
  108. package/template/.agents/skills/yss-up-springboot3/SKILL.md +1 -1
  109. package/template/.agents/skills/yss-web-controller/SKILL.md +1 -1
  110. package/template/.agents/skills/yss-web-controller/references/profiles/layered-mvc-service.md +1 -1
  111. package/template/.codex/skills/alibaba-java-code-style/SKILL.md +1 -1
  112. package/template/.codex/skills/code-review/SKILL.md +6 -6
  113. package/template/.codex/skills/code-review/references/yss-review-standards.md +1 -1
  114. package/template/.codex/skills/cross-repo-implementation-routing/SKILL.md +2 -2
  115. package/template/.codex/skills/i-have-adhd/SKILL.md +1 -1
  116. package/template/.codex/skills/i-have-adhd/references/yss-adaptation.md +1 -1
  117. package/template/.codex/skills/i-have-adhd/tests/verify-integration.mjs +2 -2
  118. package/template/.codex/skills/implementation-repo-onboarding/SKILL.md +2 -2
  119. package/template/.codex/skills/llm-wiki/references/discover.md +3 -3
  120. package/template/.codex/skills/prototype-review/SKILL.md +4 -4
  121. package/template/.codex/skills/setup-matt-pocock-skills/SKILL.md +10 -10
  122. package/template/.codex/skills/triage/SKILL.md +1 -1
  123. package/template/.codex/skills/yss-application/references/profiles/layered-mvc-service.md +1 -1
  124. package/template/.codex/skills/yss-application/references/profiles/mvc-data-analysis-v1.md +1 -1
  125. package/template/.codex/skills/yss-backend-spec-review/SKILL.md +1 -1
  126. package/template/.codex/skills/yss-backend-spec-review/references/check-inputs.md +1 -1
  127. package/template/.codex/skills/yss-cache/SKILL.md +6 -5
  128. package/template/.codex/skills/yss-cache/references/annotations.md +3 -1
  129. package/template/.codex/skills/yss-cache/references/architecture.md +4 -2
  130. package/template/.codex/skills/yss-cache/references/configuration.md +6 -3
  131. package/template/.codex/skills/yss-cache/references/jetcache.md +21 -0
  132. package/template/.codex/skills/yss-cache/references/redis-fallback.md +5 -3
  133. package/template/.codex/skills/yss-cache/references/verification.md +10 -4
  134. package/template/.codex/skills/yss-cache/scripts/verify-cache-component.sh +26 -20
  135. package/template/.codex/skills/yss-ddd-scaffold-generator/SKILL.md +2 -2
  136. package/template/.codex/skills/yss-ddd-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  137. package/template/.codex/skills/yss-design-system/SKILL.md +10 -10
  138. package/template/.codex/skills/yss-design-system/references/design-qa-theme.md +3 -3
  139. package/template/.codex/skills/yss-design-system/references/design-system.md +3 -3
  140. package/template/.codex/skills/yss-distributed-id/SKILL.md +14 -58
  141. package/template/.codex/skills/yss-distributed-id/agents/openai.yaml +2 -2
  142. package/template/.codex/skills/yss-distributed-id/references/README.md +11 -47
  143. package/template/.codex/skills/yss-exception/SKILL.md +1 -1
  144. package/template/.codex/skills/yss-frontend-scaffold-generator/SKILL.md +2 -2
  145. package/template/.codex/skills/yss-frontend-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  146. package/template/.codex/skills/yss-frontend-scaffold-generator/scripts/refresh_baseline.mjs +2 -2
  147. package/template/.codex/skills/yss-implementation-contract-compiler/SKILL.md +9 -9
  148. package/template/.codex/skills/yss-implementation-contract-compiler/references/boundaries.md +1 -1
  149. package/template/.codex/skills/yss-implementation-contract-compiler/references/compiler-contract.yaml +9 -9
  150. package/template/.codex/skills/yss-implementation-contract-compiler/references/slice-implementation-contract-v2.md +3 -3
  151. package/template/.codex/skills/yss-implementation-contract-compiler/references/slice-implementation-contract.md +1 -1
  152. package/template/.codex/skills/yss-implementation-contract-compiler/references/strategic-handoff-routing.md +1 -1
  153. package/template/.codex/skills/yss-layered-mvc-scaffold-generator/SKILL.md +2 -2
  154. package/template/.codex/skills/yss-layered-mvc-scaffold-generator/scripts/data-analysis-profile.mjs +5 -5
  155. package/template/.codex/skills/yss-layered-mvc-scaffold-generator/scripts/generate_scaffold.mjs +2 -2
  156. package/template/.codex/skills/yss-layered-mvc-scaffold-generator/scripts/scaffold-generator.test.mjs +42 -0
  157. package/template/.codex/skills/yss-mybatis/SKILL.md +14 -2
  158. package/template/.codex/skills/yss-openapi-draft-review/SKILL.md +2 -2
  159. package/template/.codex/skills/yss-openapi-governance/SKILL.md +7 -7
  160. package/template/.codex/skills/yss-product-lifecycle/SKILL.md +11 -11
  161. package/template/.codex/skills/yss-product-lifecycle/references/matt-yss-adapter.md +5 -5
  162. package/template/.codex/skills/yss-product-lifecycle/references/orchestration-contract.yaml +70 -47
  163. package/template/.codex/skills/yss-product-lifecycle/references/orchestration.md +22 -14
  164. package/template/.codex/skills/yss-product-lifecycle/references/request-triage.md +2 -0
  165. package/template/.codex/skills/yss-product-lifecycle/references/state-model.md +11 -11
  166. package/template/.codex/skills/yss-product-lifecycle/references/user-decisions.md +2 -2
  167. package/template/.codex/skills/yss-prototype-stage/SKILL.md +9 -9
  168. package/template/.codex/skills/yss-prototype-stage/references/existing-ui-entry.md +1 -1
  169. package/template/.codex/skills/yss-prototype-stage/scripts/build-antd-prototype.mjs +1 -1
  170. package/template/.codex/skills/yss-prototype-stage/scripts/offline-html.mjs +3 -3
  171. package/template/.codex/skills/yss-prototype-stage/tests/browser-smoke.mjs +2 -2
  172. package/template/.codex/skills/yss-prototype-stage/tests/run-scenarios.mjs +4 -4
  173. package/template/.codex/skills/yss-prototype-stage/tests/workbench-smoke.mjs +1 -1
  174. package/template/.codex/skills/yss-repository/SKILL.md +3 -2
  175. package/template/.codex/skills/yss-repository/references/profiles/layered-mvc-service.md +1 -1
  176. package/template/.codex/skills/yss-repository/references/profiles/mvc-data-analysis-v1.md +1 -1
  177. package/template/.codex/skills/yss-repository/tests/profile-routing.test.mjs +2 -2
  178. package/template/.codex/skills/yss-research/SKILL.md +2 -2
  179. package/template/.codex/skills/yss-skill-source-index-refresh/references/backend-component-platform-compatibility.md +1 -1
  180. package/template/.codex/skills/yss-stage-decision/SKILL.md +5 -5
  181. package/template/.codex/skills/yss-stage-decision/references/domain-strategy-contract.md +1 -1
  182. package/template/.codex/skills/yss-stage-decision/references/strategic-handoff-routing.md +1 -1
  183. package/template/.codex/skills/yss-tactical-design/SKILL.md +2 -2
  184. package/template/.codex/skills/yss-tactical-design/references/strategic-handoff-routing.md +1 -1
  185. package/template/.codex/skills/yss-tactical-design/references/tactical-design-contract.md +1 -1
  186. package/template/.codex/skills/yss-technical-design/SKILL.md +6 -6
  187. package/template/.codex/skills/yss-technical-design/references/technical-design-contract.md +1 -1
  188. package/template/.codex/skills/yss-ui/SKILL.md +1 -1
  189. package/template/.codex/skills/yss-up-springboot3/SKILL.md +1 -1
  190. package/template/.codex/skills/yss-web-controller/SKILL.md +1 -1
  191. package/template/.codex/skills/yss-web-controller/references/profiles/layered-mvc-service.md +1 -1
  192. package/template/.cursor/skills/alibaba-java-code-style/SKILL.md +1 -1
  193. package/template/.cursor/skills/code-review/SKILL.md +6 -6
  194. package/template/.cursor/skills/code-review/references/yss-review-standards.md +1 -1
  195. package/template/.cursor/skills/cross-repo-implementation-routing/SKILL.md +2 -2
  196. package/template/.cursor/skills/i-have-adhd/SKILL.md +1 -1
  197. package/template/.cursor/skills/i-have-adhd/references/yss-adaptation.md +1 -1
  198. package/template/.cursor/skills/i-have-adhd/tests/verify-integration.mjs +2 -2
  199. package/template/.cursor/skills/implementation-repo-onboarding/SKILL.md +2 -2
  200. package/template/.cursor/skills/llm-wiki/references/discover.md +3 -3
  201. package/template/.cursor/skills/prototype-review/SKILL.md +4 -4
  202. package/template/.cursor/skills/setup-matt-pocock-skills/SKILL.md +10 -10
  203. package/template/.cursor/skills/triage/SKILL.md +1 -1
  204. package/template/.cursor/skills/yss-application/references/profiles/layered-mvc-service.md +1 -1
  205. package/template/.cursor/skills/yss-application/references/profiles/mvc-data-analysis-v1.md +1 -1
  206. package/template/.cursor/skills/yss-backend-spec-review/SKILL.md +1 -1
  207. package/template/.cursor/skills/yss-backend-spec-review/references/check-inputs.md +1 -1
  208. package/template/.cursor/skills/yss-cache/SKILL.md +6 -5
  209. package/template/.cursor/skills/yss-cache/references/annotations.md +3 -1
  210. package/template/.cursor/skills/yss-cache/references/architecture.md +4 -2
  211. package/template/.cursor/skills/yss-cache/references/configuration.md +6 -3
  212. package/template/.cursor/skills/yss-cache/references/jetcache.md +21 -0
  213. package/template/.cursor/skills/yss-cache/references/redis-fallback.md +5 -3
  214. package/template/.cursor/skills/yss-cache/references/verification.md +10 -4
  215. package/template/.cursor/skills/yss-cache/scripts/verify-cache-component.sh +26 -20
  216. package/template/.cursor/skills/yss-ddd-scaffold-generator/SKILL.md +2 -2
  217. package/template/.cursor/skills/yss-ddd-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  218. package/template/.cursor/skills/yss-design-system/SKILL.md +10 -10
  219. package/template/.cursor/skills/yss-design-system/references/design-qa-theme.md +3 -3
  220. package/template/.cursor/skills/yss-design-system/references/design-system.md +3 -3
  221. package/template/.cursor/skills/yss-distributed-id/SKILL.md +14 -58
  222. package/template/.cursor/skills/yss-distributed-id/agents/openai.yaml +2 -2
  223. package/template/.cursor/skills/yss-distributed-id/references/README.md +11 -47
  224. package/template/.cursor/skills/yss-exception/SKILL.md +1 -1
  225. package/template/.cursor/skills/yss-frontend-scaffold-generator/SKILL.md +2 -2
  226. package/template/.cursor/skills/yss-frontend-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  227. package/template/.cursor/skills/yss-frontend-scaffold-generator/scripts/refresh_baseline.mjs +2 -2
  228. package/template/.cursor/skills/yss-implementation-contract-compiler/SKILL.md +9 -9
  229. package/template/.cursor/skills/yss-implementation-contract-compiler/references/boundaries.md +1 -1
  230. package/template/.cursor/skills/yss-implementation-contract-compiler/references/compiler-contract.yaml +9 -9
  231. package/template/.cursor/skills/yss-implementation-contract-compiler/references/slice-implementation-contract-v2.md +3 -3
  232. package/template/.cursor/skills/yss-implementation-contract-compiler/references/slice-implementation-contract.md +1 -1
  233. package/template/.cursor/skills/yss-implementation-contract-compiler/references/strategic-handoff-routing.md +1 -1
  234. package/template/.cursor/skills/yss-layered-mvc-scaffold-generator/SKILL.md +2 -2
  235. package/template/.cursor/skills/yss-layered-mvc-scaffold-generator/scripts/data-analysis-profile.mjs +5 -5
  236. package/template/.cursor/skills/yss-layered-mvc-scaffold-generator/scripts/generate_scaffold.mjs +2 -2
  237. package/template/.cursor/skills/yss-layered-mvc-scaffold-generator/scripts/scaffold-generator.test.mjs +42 -0
  238. package/template/.cursor/skills/yss-mybatis/SKILL.md +14 -2
  239. package/template/.cursor/skills/yss-openapi-draft-review/SKILL.md +2 -2
  240. package/template/.cursor/skills/yss-openapi-governance/SKILL.md +7 -7
  241. package/template/.cursor/skills/yss-product-lifecycle/SKILL.md +11 -11
  242. package/template/.cursor/skills/yss-product-lifecycle/references/matt-yss-adapter.md +5 -5
  243. package/template/.cursor/skills/yss-product-lifecycle/references/orchestration-contract.yaml +70 -47
  244. package/template/.cursor/skills/yss-product-lifecycle/references/orchestration.md +22 -14
  245. package/template/.cursor/skills/yss-product-lifecycle/references/request-triage.md +2 -0
  246. package/template/.cursor/skills/yss-product-lifecycle/references/state-model.md +11 -11
  247. package/template/.cursor/skills/yss-product-lifecycle/references/user-decisions.md +2 -2
  248. package/template/.cursor/skills/yss-prototype-stage/SKILL.md +9 -9
  249. package/template/.cursor/skills/yss-prototype-stage/references/existing-ui-entry.md +1 -1
  250. package/template/.cursor/skills/yss-prototype-stage/scripts/build-antd-prototype.mjs +1 -1
  251. package/template/.cursor/skills/yss-prototype-stage/scripts/offline-html.mjs +3 -3
  252. package/template/.cursor/skills/yss-prototype-stage/tests/browser-smoke.mjs +2 -2
  253. package/template/.cursor/skills/yss-prototype-stage/tests/run-scenarios.mjs +4 -4
  254. package/template/.cursor/skills/yss-prototype-stage/tests/workbench-smoke.mjs +1 -1
  255. package/template/.cursor/skills/yss-repository/SKILL.md +3 -2
  256. package/template/.cursor/skills/yss-repository/references/profiles/layered-mvc-service.md +1 -1
  257. package/template/.cursor/skills/yss-repository/references/profiles/mvc-data-analysis-v1.md +1 -1
  258. package/template/.cursor/skills/yss-repository/tests/profile-routing.test.mjs +2 -2
  259. package/template/.cursor/skills/yss-research/SKILL.md +2 -2
  260. package/template/.cursor/skills/yss-skill-source-index-refresh/references/backend-component-platform-compatibility.md +1 -1
  261. package/template/.cursor/skills/yss-stage-decision/SKILL.md +5 -5
  262. package/template/.cursor/skills/yss-stage-decision/references/domain-strategy-contract.md +1 -1
  263. package/template/.cursor/skills/yss-stage-decision/references/strategic-handoff-routing.md +1 -1
  264. package/template/.cursor/skills/yss-tactical-design/SKILL.md +2 -2
  265. package/template/.cursor/skills/yss-tactical-design/references/strategic-handoff-routing.md +1 -1
  266. package/template/.cursor/skills/yss-tactical-design/references/tactical-design-contract.md +1 -1
  267. package/template/.cursor/skills/yss-technical-design/SKILL.md +6 -6
  268. package/template/.cursor/skills/yss-technical-design/references/technical-design-contract.md +1 -1
  269. package/template/.cursor/skills/yss-ui/SKILL.md +1 -1
  270. package/template/.cursor/skills/yss-up-springboot3/SKILL.md +1 -1
  271. package/template/.cursor/skills/yss-web-controller/SKILL.md +1 -1
  272. package/template/.cursor/skills/yss-web-controller/references/profiles/layered-mvc-service.md +1 -1
  273. package/template/.cursorrules +1 -1
  274. package/template/.pi/skills/alibaba-java-code-style/SKILL.md +1 -1
  275. package/template/.pi/skills/code-review/SKILL.md +6 -6
  276. package/template/.pi/skills/code-review/references/yss-review-standards.md +1 -1
  277. package/template/.pi/skills/cross-repo-implementation-routing/SKILL.md +2 -2
  278. package/template/.pi/skills/i-have-adhd/SKILL.md +1 -1
  279. package/template/.pi/skills/i-have-adhd/references/yss-adaptation.md +1 -1
  280. package/template/.pi/skills/i-have-adhd/tests/verify-integration.mjs +2 -2
  281. package/template/.pi/skills/implementation-repo-onboarding/SKILL.md +2 -2
  282. package/template/.pi/skills/llm-wiki/references/discover.md +3 -3
  283. package/template/.pi/skills/prototype-review/SKILL.md +4 -4
  284. package/template/.pi/skills/setup-matt-pocock-skills/SKILL.md +10 -10
  285. package/template/.pi/skills/triage/SKILL.md +1 -1
  286. package/template/.pi/skills/yss-application/references/profiles/layered-mvc-service.md +1 -1
  287. package/template/.pi/skills/yss-application/references/profiles/mvc-data-analysis-v1.md +1 -1
  288. package/template/.pi/skills/yss-backend-spec-review/SKILL.md +1 -1
  289. package/template/.pi/skills/yss-backend-spec-review/references/check-inputs.md +1 -1
  290. package/template/.pi/skills/yss-cache/SKILL.md +6 -5
  291. package/template/.pi/skills/yss-cache/references/annotations.md +3 -1
  292. package/template/.pi/skills/yss-cache/references/architecture.md +4 -2
  293. package/template/.pi/skills/yss-cache/references/configuration.md +6 -3
  294. package/template/.pi/skills/yss-cache/references/jetcache.md +21 -0
  295. package/template/.pi/skills/yss-cache/references/redis-fallback.md +5 -3
  296. package/template/.pi/skills/yss-cache/references/verification.md +10 -4
  297. package/template/.pi/skills/yss-cache/scripts/verify-cache-component.sh +26 -20
  298. package/template/.pi/skills/yss-ddd-scaffold-generator/SKILL.md +2 -2
  299. package/template/.pi/skills/yss-ddd-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  300. package/template/.pi/skills/yss-design-system/SKILL.md +10 -10
  301. package/template/.pi/skills/yss-design-system/references/design-qa-theme.md +3 -3
  302. package/template/.pi/skills/yss-design-system/references/design-system.md +3 -3
  303. package/template/.pi/skills/yss-distributed-id/SKILL.md +14 -58
  304. package/template/.pi/skills/yss-distributed-id/agents/openai.yaml +2 -2
  305. package/template/.pi/skills/yss-distributed-id/references/README.md +11 -47
  306. package/template/.pi/skills/yss-exception/SKILL.md +1 -1
  307. package/template/.pi/skills/yss-frontend-scaffold-generator/SKILL.md +2 -2
  308. package/template/.pi/skills/yss-frontend-scaffold-generator/scripts/generate_scaffold.mjs +1 -1
  309. package/template/.pi/skills/yss-frontend-scaffold-generator/scripts/refresh_baseline.mjs +2 -2
  310. package/template/.pi/skills/yss-implementation-contract-compiler/SKILL.md +9 -9
  311. package/template/.pi/skills/yss-implementation-contract-compiler/references/boundaries.md +1 -1
  312. package/template/.pi/skills/yss-implementation-contract-compiler/references/compiler-contract.yaml +9 -9
  313. package/template/.pi/skills/yss-implementation-contract-compiler/references/slice-implementation-contract-v2.md +3 -3
  314. package/template/.pi/skills/yss-implementation-contract-compiler/references/slice-implementation-contract.md +1 -1
  315. package/template/.pi/skills/yss-implementation-contract-compiler/references/strategic-handoff-routing.md +1 -1
  316. package/template/.pi/skills/yss-layered-mvc-scaffold-generator/SKILL.md +2 -2
  317. package/template/.pi/skills/yss-layered-mvc-scaffold-generator/scripts/data-analysis-profile.mjs +5 -5
  318. package/template/.pi/skills/yss-layered-mvc-scaffold-generator/scripts/generate_scaffold.mjs +2 -2
  319. package/template/.pi/skills/yss-layered-mvc-scaffold-generator/scripts/scaffold-generator.test.mjs +42 -0
  320. package/template/.pi/skills/yss-mybatis/SKILL.md +14 -2
  321. package/template/.pi/skills/yss-openapi-draft-review/SKILL.md +2 -2
  322. package/template/.pi/skills/yss-openapi-governance/SKILL.md +7 -7
  323. package/template/.pi/skills/yss-product-lifecycle/SKILL.md +11 -11
  324. package/template/.pi/skills/yss-product-lifecycle/references/matt-yss-adapter.md +5 -5
  325. package/template/.pi/skills/yss-product-lifecycle/references/orchestration-contract.yaml +70 -47
  326. package/template/.pi/skills/yss-product-lifecycle/references/orchestration.md +22 -14
  327. package/template/.pi/skills/yss-product-lifecycle/references/request-triage.md +2 -0
  328. package/template/.pi/skills/yss-product-lifecycle/references/state-model.md +11 -11
  329. package/template/.pi/skills/yss-product-lifecycle/references/user-decisions.md +2 -2
  330. package/template/.pi/skills/yss-prototype-stage/SKILL.md +9 -9
  331. package/template/.pi/skills/yss-prototype-stage/references/existing-ui-entry.md +1 -1
  332. package/template/.pi/skills/yss-prototype-stage/scripts/build-antd-prototype.mjs +1 -1
  333. package/template/.pi/skills/yss-prototype-stage/scripts/offline-html.mjs +3 -3
  334. package/template/.pi/skills/yss-prototype-stage/tests/browser-smoke.mjs +2 -2
  335. package/template/.pi/skills/yss-prototype-stage/tests/run-scenarios.mjs +4 -4
  336. package/template/.pi/skills/yss-prototype-stage/tests/workbench-smoke.mjs +1 -1
  337. package/template/.pi/skills/yss-repository/SKILL.md +3 -2
  338. package/template/.pi/skills/yss-repository/references/profiles/layered-mvc-service.md +1 -1
  339. package/template/.pi/skills/yss-repository/references/profiles/mvc-data-analysis-v1.md +1 -1
  340. package/template/.pi/skills/yss-repository/tests/profile-routing.test.mjs +2 -2
  341. package/template/.pi/skills/yss-research/SKILL.md +2 -2
  342. package/template/.pi/skills/yss-skill-source-index-refresh/references/backend-component-platform-compatibility.md +1 -1
  343. package/template/.pi/skills/yss-stage-decision/SKILL.md +5 -5
  344. package/template/.pi/skills/yss-stage-decision/references/domain-strategy-contract.md +1 -1
  345. package/template/.pi/skills/yss-stage-decision/references/strategic-handoff-routing.md +1 -1
  346. package/template/.pi/skills/yss-tactical-design/SKILL.md +2 -2
  347. package/template/.pi/skills/yss-tactical-design/references/strategic-handoff-routing.md +1 -1
  348. package/template/.pi/skills/yss-tactical-design/references/tactical-design-contract.md +1 -1
  349. package/template/.pi/skills/yss-technical-design/SKILL.md +6 -6
  350. package/template/.pi/skills/yss-technical-design/references/technical-design-contract.md +1 -1
  351. package/template/.pi/skills/yss-ui/SKILL.md +1 -1
  352. package/template/.pi/skills/yss-up-springboot3/SKILL.md +1 -1
  353. package/template/.pi/skills/yss-web-controller/SKILL.md +1 -1
  354. package/template/.pi/skills/yss-web-controller/references/profiles/layered-mvc-service.md +1 -1
  355. package/template/{docs → .template-spec}/adr/README.md +1 -1
  356. package/template/{docs → .template-spec}/agents/README.md +1 -1
  357. package/template/{docs → .template-spec}/agents/backend-architecture-profiles.md +2 -2
  358. package/template/{docs → .template-spec}/agents/digital-human-roles.md +6 -6
  359. package/template/{docs → .template-spec}/agents/digital-human-roles.yaml +5 -5
  360. package/template/{docs → .template-spec}/agents/gitlab-workflow-skills.md +2 -2
  361. package/template/{docs → .template-spec}/agents/issue-tracker.md +1 -1
  362. package/template/{docs → .template-spec}/agents/skill-migrations.md +6 -2
  363. package/template/{docs → .template-spec}/agents/triage-labels.md +1 -1
  364. package/template/{docs → .template-spec}/agents/yss-skill-registry.yaml +9 -8
  365. package/template/{docs → .template-spec}/architecture/README.md +3 -3
  366. package/template/{docs → .template-spec}/architecture/templates/tech-design-template.md +3 -1
  367. package/template/{docs → .template-spec}/design/README.md +12 -12
  368. package/template/{docs → .template-spec}/design/design.md +20 -20
  369. package/template/{docs/design/templates/interaction-spec-template.md → .template-spec/design/templates/examples/model-publishing-interaction.example.md} +6 -4
  370. package/template/{docs/design/templates/state-matrix-template.md → .template-spec/design/templates/examples/model-publishing-state-matrix.example.md} +3 -1
  371. package/template/.template-spec/design/templates/interaction-spec-template.md +61 -0
  372. package/template/{docs → .template-spec}/design/templates/product-overview-design-template.md +11 -11
  373. package/template/{docs → .template-spec}/design/templates/prototype-evidence-template.yaml +4 -4
  374. package/template/{docs → .template-spec}/design/templates/prototype-review-checklist.md +1 -1
  375. package/template/.template-spec/design/templates/state-matrix-template.md +29 -0
  376. package/template/.template-spec/design/tokens/.design-md-projection.json +13 -0
  377. package/template/{docs → .template-spec}/engineering/backend-platforms.md +1 -1
  378. package/template/{docs → .template-spec}/plan/entry-review.md +8 -4
  379. package/template/{docs → .template-spec}/plan/templates/plan-template.md +1 -1
  380. package/template/{docs → .template-spec}/process/contract-reading.md +1 -1
  381. package/template/{docs → .template-spec}/process/lifecycle-artifact-map.md +5 -5
  382. package/template/.template-spec/process/lifecycle-registry-baseline.json +253 -0
  383. package/template/{docs → .template-spec}/process/lifecycle-registry.yaml +19 -12
  384. package/template/{docs → .template-spec}/process/plan-migration.md +1 -1
  385. package/template/{docs → .template-spec}/process/schemas/digital-human-task-package.schema.json +14 -1
  386. package/template/{docs → .template-spec}/process/schemas/lifecycle-checkpoint.schema.json +15 -0
  387. package/template/{docs → .template-spec}/process/schemas/lifecycle-registry.schema.json +1 -1
  388. package/template/{docs → .template-spec}/process/schemas/strategic-design-handoff-v3.schema.json +1 -1
  389. package/template/{docs → .template-spec}/process/schemas/strategic-design-handoff-v4.schema.json +1 -1
  390. package/template/{docs → .template-spec}/process/schemas/strategic-design-handoff-v5.schema.json +1 -1
  391. package/template/{docs → .template-spec}/process/schemas/strategic-design-handoff.schema.json +1 -1
  392. package/template/{docs → .template-spec}/process/stage-tracking.md +1 -1
  393. package/template/{docs → .template-spec}/process/subagent-collaboration.md +2 -2
  394. package/template/{docs → .template-spec}/templates/build-architecture-checklist-template.md +2 -2
  395. package/template/{docs → .template-spec}/templates/digital-human-runtime-profile-template.md +2 -2
  396. package/template/{docs → .template-spec}/templates/grok-bot-profile-template.md +1 -1
  397. package/template/{docs → .template-spec}/templates/local-parent-ticket-template.md +1 -1
  398. package/template/.template-spec/templates/release-note-template.md +29 -0
  399. package/template/.template-spec/templates/retro-report-template.md +24 -0
  400. package/template/{docs → .template-spec}/templates/subagent-task-package-template.md +3 -3
  401. package/template/.template-spec/templates/verification-record-template.md +64 -0
  402. package/template/{docs → .template-spec}/templates/vertical-slice-ticket-template.md +5 -10
  403. package/template/{docs → .template-spec}/user-guide//347/224/250/346/210/267/346/211/213/345/206/214.md +1 -1
  404. package/template/{docs → .template-spec}/user-guide//347/224/250/346/210/267/346/211/213/345/206/214/347/264/242/345/274/225.md +4 -4
  405. package/template/AGENTS.md +12 -12
  406. package/template/CONTEXT.md +3 -3
  407. package/template/README.md +22 -25
  408. package/template/scripts/backend-delivery +1 -1
  409. package/template/scripts/design-md +2 -0
  410. package/template/scripts/lib/api-contract-decision.mjs +1 -1
  411. package/template/scripts/lib/approved-execution-context.mjs +5 -5
  412. package/template/scripts/lib/backend-delivery.mjs +4 -4
  413. package/template/scripts/lib/backend-platform.mjs +1 -1
  414. package/template/scripts/lib/backend-review.mjs +1 -1
  415. package/template/scripts/lib/backend-scaffold-prerequisites.mjs +1 -1
  416. package/template/scripts/lib/backend-standards-coverage.mjs +2 -2
  417. package/template/scripts/lib/context-reconciliation.mjs +1 -1
  418. package/template/scripts/lib/contract-views.mjs +9 -9
  419. package/template/scripts/lib/delivery-preflight.mjs +6 -6
  420. package/template/scripts/lib/design-md.mjs +230 -0
  421. package/template/scripts/lib/digital-human-roles.mjs +2 -2
  422. package/template/scripts/lib/existing-backend-architecture.mjs +1 -1
  423. package/template/scripts/lib/existing-ui-baseline.mjs +1 -1
  424. package/template/scripts/lib/frontend-delivery.mjs +2 -2
  425. package/template/scripts/lib/governance-layout.mjs +74 -0
  426. package/template/scripts/lib/harness-execution-scope.mjs +2 -2
  427. package/template/scripts/lib/lifecycle-context-query.mjs +11 -3
  428. package/template/scripts/lib/lifecycle-registry.mjs +46 -7
  429. package/template/scripts/lib/lifecycle-status.mjs +111 -0
  430. package/template/scripts/lib/lifecycle-transition.mjs +71 -10
  431. package/template/scripts/lib/openapi-draft-validation.mjs +1 -1
  432. package/template/scripts/lib/plan-spec-entry-view.mjs +48 -0
  433. package/template/scripts/lib/plan-spec-entry.mjs +3 -3
  434. package/template/scripts/lib/skill-registry.mjs +16 -9
  435. package/template/scripts/lib/skill-supply-chain.mjs +34 -15
  436. package/template/scripts/lib/slice-contract-preparation.mjs +3 -3
  437. package/template/scripts/lib/slice-contract.mjs +1 -1
  438. package/template/scripts/lib/slice-repositories.mjs +1 -1
  439. package/template/scripts/lib/slice-task-package.mjs +3 -3
  440. package/template/scripts/lib/stage-tracking-migration.mjs +2 -2
  441. package/template/scripts/lib/stage-tracking.mjs +5 -5
  442. package/template/scripts/lib/strategic-feedback.mjs +2 -2
  443. package/template/scripts/lib/strategic-handoff-routing.mjs +2 -2
  444. package/template/scripts/lib/strategic-handoff.mjs +15 -15
  445. package/template/scripts/lib/task-package-schema.mjs +2 -2
  446. package/template/scripts/lib/task-package.mjs +1 -1
  447. package/template/scripts/lib/technical-design-boundary.mjs +1 -1
  448. package/template/scripts/lib/user-decision.mjs +2 -1
  449. package/template/scripts/lifecycle-status +14 -0
  450. package/template/scripts/plan-spec-entry +21 -0
  451. package/template/scripts/strategic-consumer-entry +1 -1
  452. package/template/scripts/strategic-handoff +1 -1
  453. package/template/scripts/verify-frontend-implementation-evidence +1 -1
  454. package/template/scripts/verify-governance-layout +15 -0
  455. package/template/scripts/verify-lifecycle-checkpoint +1 -1
  456. package/template/scripts/verify-project-instance +13 -10
  457. package/template/scripts/verify-scaffold-architecture-decisions +1 -1
  458. package/template/scripts/verify-strategic-context-import +3 -3
  459. package/template/skills-lock.json +80 -95
  460. package/template.manifest.json +30 -15
  461. package/template.snapshot.json +5 -5
  462. package/template/.agents/skills/grill-me/SKILL.md +0 -7
  463. package/template/.agents/skills/grill-me/agents/openai.yaml +0 -5
  464. package/template/.agents/skills/yss-distributed-id/assets/AutoIdInterceptor.java +0 -246
  465. package/template/.agents/skills/yss-distributed-id/assets/EnableDistributedId.java +0 -25
  466. package/template/.agents/skills/yss-distributed-id/assets/LeafConf.java +0 -36
  467. package/template/.codex/skills/grill-me/SKILL.md +0 -7
  468. package/template/.codex/skills/grill-me/agents/openai.yaml +0 -5
  469. package/template/.codex/skills/yss-distributed-id/assets/AutoIdInterceptor.java +0 -246
  470. package/template/.codex/skills/yss-distributed-id/assets/EnableDistributedId.java +0 -25
  471. package/template/.codex/skills/yss-distributed-id/assets/LeafConf.java +0 -36
  472. package/template/.cursor/skills/grill-me/SKILL.md +0 -7
  473. package/template/.cursor/skills/grill-me/agents/openai.yaml +0 -5
  474. package/template/.cursor/skills/yss-distributed-id/assets/AutoIdInterceptor.java +0 -246
  475. package/template/.cursor/skills/yss-distributed-id/assets/EnableDistributedId.java +0 -25
  476. package/template/.cursor/skills/yss-distributed-id/assets/LeafConf.java +0 -36
  477. package/template/.pi/skills/grill-me/SKILL.md +0 -7
  478. package/template/.pi/skills/grill-me/agents/openai.yaml +0 -5
  479. package/template/.pi/skills/yss-distributed-id/assets/AutoIdInterceptor.java +0 -246
  480. package/template/.pi/skills/yss-distributed-id/assets/EnableDistributedId.java +0 -25
  481. package/template/.pi/skills/yss-distributed-id/assets/LeafConf.java +0 -36
  482. package/template/docs/agents/archify-integration.md +0 -19
  483. package/template/docs/agents/yss-plugin-dependency-contract.md +0 -45
  484. package/template/docs/api/.gitkeep +0 -0
  485. package/template/docs/api/specs/.gitkeep +0 -0
  486. package/template/docs/architecture/.gitkeep +0 -0
  487. package/template/docs/design/design-system-sync.yaml +0 -13
  488. package/template/docs/design/facts/antdv-next/1.5.2/cli-help.txt +0 -38
  489. package/template/docs/design/facts/antdv-next/1.5.2/component-list.json +0 -434
  490. package/template/docs/design/facts/antdv-next/1.5.2/components/Alert/demo-basic.json +0 -7
  491. package/template/docs/design/facts/antdv-next/1.5.2/components/Alert/info.json +0 -246
  492. package/template/docs/design/facts/antdv-next/1.5.2/components/Alert/semantic.json +0 -40
  493. package/template/docs/design/facts/antdv-next/1.5.2/components/Alert/token.json +0 -32
  494. package/template/docs/design/facts/antdv-next/1.5.2/components/Button/demo-basic.json +0 -7
  495. package/template/docs/design/facts/antdv-next/1.5.2/components/Button/info.json +0 -190
  496. package/template/docs/design/facts/antdv-next/1.5.2/components/Button/semantic.json +0 -20
  497. package/template/docs/design/facts/antdv-next/1.5.2/components/Button/token.json +0 -256
  498. package/template/docs/design/facts/antdv-next/1.5.2/components/Input/demo-basic.json +0 -7
  499. package/template/docs/design/facts/antdv-next/1.5.2/components/Input/info.json +0 -460
  500. package/template/docs/design/facts/antdv-next/1.5.2/components/Input/semantic.json +0 -70
  501. package/template/docs/design/facts/antdv-next/1.5.2/components/Input/token.json +0 -123
  502. package/template/docs/design/facts/antdv-next/1.5.2/components/Modal/demo-basic.json +0 -7
  503. package/template/docs/design/facts/antdv-next/1.5.2/components/Modal/info.json +0 -646
  504. package/template/docs/design/facts/antdv-next/1.5.2/components/Modal/semantic.json +0 -50
  505. package/template/docs/design/facts/antdv-next/1.5.2/components/Modal/token.json +0 -130
  506. package/template/docs/design/facts/antdv-next/1.5.2/components/Select/demo-basic.json +0 -7
  507. package/template/docs/design/facts/antdv-next/1.5.2/components/Select/info.json +0 -640
  508. package/template/docs/design/facts/antdv-next/1.5.2/components/Select/semantic.json +0 -70
  509. package/template/docs/design/facts/antdv-next/1.5.2/components/Select/token.json +0 -172
  510. package/template/docs/design/facts/antdv-next/1.5.2/components/Table/demo-basic.json +0 -7
  511. package/template/docs/design/facts/antdv-next/1.5.2/components/Table/info.json +0 -1010
  512. package/template/docs/design/facts/antdv-next/1.5.2/components/Table/semantic.json +0 -70
  513. package/template/docs/design/facts/antdv-next/1.5.2/components/Table/token.json +0 -263
  514. package/template/docs/design/facts/antdv-next/1.5.2/components/Tag/demo-basic.json +0 -7
  515. package/template/docs/design/facts/antdv-next/1.5.2/components/Tag/info.json +0 -321
  516. package/template/docs/design/facts/antdv-next/1.5.2/components/Tag/semantic.json +0 -25
  517. package/template/docs/design/facts/antdv-next/1.5.2/components/Tag/token.json +0 -25
  518. package/template/docs/design/facts/antdv-next/1.5.2/design-md.json +0 -3
  519. package/template/docs/design/facts/antdv-next/1.5.2/manifest.json +0 -215
  520. package/template/docs/design/facts/antdv-next/1.5.2/resolution-probe.json +0 -5
  521. package/template/docs/design/preview-dark.html +0 -178
  522. package/template/docs/design/preview.css +0 -730
  523. package/template/docs/design/preview.html +0 -178
  524. package/template/docs/design/preview.js +0 -71
  525. package/template/docs/design/prototypes/.gitkeep +0 -1
  526. package/template/docs/design/tokens/.design-md-projection.json +0 -13
  527. package/template/docs/implementation/.gitkeep +0 -1
  528. package/template/docs/plan/IDEATION.md +0 -96
  529. package/template/docs/process/MATT-POCOCK-ENGINEERING-SKILLS.md +0 -13
  530. package/template/docs/process/PDCA-SCRUM.md +0 -10
  531. package/template/docs/process/github-workflows.md +0 -52
  532. package/template/docs/process/harness-executive-blueprint.md +0 -10
  533. package/template/docs/releases/.gitkeep +0 -1
  534. package/template/docs/requirements/README.md +0 -85
  535. package/template/docs/requirements/tickets/.gitkeep +0 -1
  536. package/template/docs/templates/agent-brief-template.md +0 -46
  537. package/template/docs/templates/architecture-proposal-template.md +0 -18
  538. package/template/docs/templates/implementation-plan-template.md +0 -16
  539. package/template/docs/templates/implementation-routing-template.md +0 -350
  540. package/template/docs/templates/release-note-template.md +0 -14
  541. package/template/docs/templates/requirement-freeze-template.md +0 -63
  542. package/template/docs/templates/retro-report-template.md +0 -16
  543. package/template/docs/templates/risk-register-template.md +0 -11
  544. package/template/docs/templates/user-story-template.md +0 -20
  545. package/template/docs/templates/verification-record-template.md +0 -53
  546. package/template/docs/testing/README.md +0 -110
  547. /package/template/{docs → .template-spec}/agents/domain.md +0 -0
  548. /package/template/{docs → .template-spec}/api/templates/openapi-draft-review-checklist.md +0 -0
  549. /package/template/{docs → .template-spec}/api/templates/openapi-draft-validation-record-template.yaml +0 -0
  550. /package/template/{docs → .template-spec}/api/templates/openapi-freeze-record-template.md +0 -0
  551. /package/template/{docs → .template-spec}/api/templates/openapi-json-export-record-template.md +0 -0
  552. /package/template/{docs → .template-spec}/architecture/templates/architecture-deepening-template.md +0 -0
  553. /package/template/{docs → .template-spec}/architecture/templates/architecture-review-checklist.md +0 -0
  554. /package/template/{docs → .template-spec}/architecture/templates/business-architecture-template.md +0 -0
  555. /package/template/{docs → .template-spec}/architecture/templates/data-architecture-template.md +0 -0
  556. /package/template/{docs → .template-spec}/architecture/templates/engineering-baseline-review-template.md +0 -0
  557. /package/template/{docs → .template-spec}/architecture/templates/functional-architecture-template.md +0 -0
  558. /package/template/{docs → .template-spec}/architecture/templates/system-overview-design-template.md +0 -0
  559. /package/template/{docs → .template-spec}/design/diagrams/README.md +0 -0
  560. /package/template/{docs → .template-spec}/design/schemas/visual-baseline.schema.json +0 -0
  561. /package/template/{docs → .template-spec}/design/templates/prototype-confirmation-template.md +0 -0
  562. /package/template/{docs → .template-spec}/design/templates/visual-baseline-template.yaml +0 -0
  563. /package/template/{docs → .template-spec}/design/tokens/theme.json +0 -0
  564. /package/template/{docs → .template-spec}/design/tokens/tokens.compact.json +0 -0
  565. /package/template/{docs → .template-spec}/design/tokens/tokens.dark.json +0 -0
  566. /package/template/{docs → .template-spec}/design/tokens/tokens.default.json +0 -0
  567. /package/template/{docs → .template-spec}/design/tokens/variables.css +0 -0
  568. /package/template/{docs → .template-spec}/design/tokens/variables.dark.css +0 -0
  569. /package/template/{docs → .template-spec}/engineering/backend-platforms.json +0 -0
  570. /package/template/{docs → .template-spec}/plan/README.md +0 -0
  571. /package/template/{docs → .template-spec}/plan/templates/competitive-analysis-template.md +0 -0
  572. /package/template/{docs → .template-spec}/plan/templates/competitive-matrix-template.md +0 -0
  573. /package/template/{docs → .template-spec}/plan/templates/market-analysis-template.md +0 -0
  574. /package/template/{docs → .template-spec}/plan/templates/user-pain-points-template.md +0 -0
  575. /package/template/{docs → .template-spec}/process/delivery-preflight.md +0 -0
  576. /package/template/{docs → .template-spec}/process/document-writing.md +0 -0
  577. /package/template/{docs → .template-spec}/process/existing-backend-architecture.md +0 -0
  578. /package/template/{docs → .template-spec}/process/existing-ui-baseline.md +0 -0
  579. /package/template/{docs → .template-spec}/process/frontend-backend-delivery.md +0 -0
  580. /package/template/{docs → .template-spec}/process/harness-process-tailoring.md +0 -0
  581. /package/template/{docs → .template-spec}/process/implementation-repo-integration.md +0 -0
  582. /package/template/{docs/process/lifecycle-registry-baseline.json → .template-spec/process/lifecycle-registry-baseline-v1.json} +0 -0
  583. /package/template/{docs → .template-spec}/process/schemas/api-contract-decision-v2.schema.json +0 -0
  584. /package/template/{docs → .template-spec}/process/schemas/api-contract-decision.schema.json +0 -0
  585. /package/template/{docs → .template-spec}/process/schemas/backend-architecture-identity.schema.json +0 -0
  586. /package/template/{docs → .template-spec}/process/schemas/backend-delivery-verification.schema.json +0 -0
  587. /package/template/{docs → .template-spec}/process/schemas/backend-delivery.schema.json +0 -0
  588. /package/template/{docs → .template-spec}/process/schemas/context-reconciliation.schema.json +0 -0
  589. /package/template/{docs → .template-spec}/process/schemas/data-architecture-decision.schema.json +0 -0
  590. /package/template/{docs → .template-spec}/process/schemas/delivery-preflight-input.schema.json +0 -0
  591. /package/template/{docs → .template-spec}/process/schemas/delivery-preflight-result.schema.json +0 -0
  592. /package/template/{docs → .template-spec}/process/schemas/existing-ui-baseline.schema.json +0 -0
  593. /package/template/{docs → .template-spec}/process/schemas/frontend-delivery-acceptance-v1.schema.json +0 -0
  594. /package/template/{docs → .template-spec}/process/schemas/frontend-delivery-acceptance-v3.schema.json +0 -0
  595. /package/template/{docs → .template-spec}/process/schemas/frontend-delivery-acceptance.schema.json +0 -0
  596. /package/template/{docs → .template-spec}/process/schemas/frontend-implementation-evidence.schema.json +0 -0
  597. /package/template/{docs → .template-spec}/process/schemas/frontend-strategic-preflight-v2.schema.json +0 -0
  598. /package/template/{docs → .template-spec}/process/schemas/frontend-strategic-preflight.schema.json +0 -0
  599. /package/template/{docs → .template-spec}/process/schemas/implementation-repository-preparation-result.schema.json +0 -0
  600. /package/template/{docs → .template-spec}/process/schemas/openapi-draft-validation-record.schema.json +0 -0
  601. /package/template/{docs → .template-spec}/process/schemas/project-scaffold-contract.schema.json +0 -0
  602. /package/template/{docs → .template-spec}/process/schemas/review-bundle.schema.json +0 -0
  603. /package/template/{docs → .template-spec}/process/schemas/scaffold-architecture-decisions.schema.json +0 -0
  604. /package/template/{docs → .template-spec}/process/schemas/slice-implementation-contract-v3.schema.json +0 -0
  605. /package/template/{docs → .template-spec}/process/schemas/stage-tracking.schema.json +0 -0
  606. /package/template/{docs → .template-spec}/process/schemas/strategic-consumer-feedback.schema.json +0 -0
  607. /package/template/{docs → .template-spec}/process/schemas/strategic-feedback-adjudication.schema.json +0 -0
  608. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-delivery-verification.schema.json +0 -0
  609. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-delivery.schema.json +0 -0
  610. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-domain-strategy-v3.schema.json +0 -0
  611. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-domain-strategy.schema.json +0 -0
  612. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-export-v2.schema.json +0 -0
  613. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-export.schema.json +0 -0
  614. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-import-receipt-v3.schema.json +0 -0
  615. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-import-receipt.schema.json +0 -0
  616. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-package.schema.json +0 -0
  617. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-stage-decision-package-v3.schema.json +0 -0
  618. /package/template/{docs → .template-spec}/process/schemas/strategic-handoff-stage-decision-package.schema.json +0 -0
  619. /package/template/{docs → .template-spec}/process/schemas/subagent-task-package.schema.json +0 -0
  620. /package/template/{docs → .template-spec}/process/schemas/user-decision.schema.json +0 -0
  621. /package/template/{docs → .template-spec}/process/strategic-handoff-package.md +0 -0
  622. /package/template/{docs → .template-spec}/process/templates/context-reconciliation-template.yaml +0 -0
  623. /package/template/{docs → .template-spec}/process/templates/frontend-implementation-plan-template.yaml +0 -0
  624. /package/template/{docs → .template-spec}/process/templates/frontend-implementation-verification-template.yaml +0 -0
  625. /package/template/{docs → .template-spec}/process/templates/lifecycle-checkpoint-template.yaml +0 -0
  626. /package/template/{docs → .template-spec}/process/templates/scaffold-architecture-decisions-template.yaml +0 -0
  627. /package/template/{docs → .template-spec}/process/templates/stage-checkpoint-template.md +0 -0
  628. /package/template/{docs → .template-spec}/process/templates/user-decision-template.yaml +0 -0
  629. /package/template/{docs → .template-spec}/templates/adr-template.md +0 -0
  630. /package/template/{docs → .template-spec}/templates/approval-record-template.yaml +0 -0
  631. /package/template/{docs → .template-spec}/templates/cross-repo-slice-template.md +0 -0
  632. /package/template/{docs → .template-spec}/templates/examples/lifecycle-writing-examples.md +0 -0
  633. /package/template/{docs → .template-spec}/templates/implementation-repo-registry-template.md +0 -0
  634. /package/template/{docs → .template-spec}/templates/openapi-spec-template.yaml +0 -0
  635. /package/template/{docs → .template-spec}/templates/review-bundle-template.yaml +0 -0
  636. /package/template/{docs → .template-spec}/templates/review-report-template.md +0 -0
  637. /package/template/{docs → .template-spec}/templates/spec-delta-template.md +0 -0
  638. /package/template/{docs → .template-spec}/templates/spec-template.md +0 -0
  639. /package/template/{docs → .template-spec}/user-guide/yss-ui-mcp.md +0 -0
  640. /package/template/{docs → .template-spec}/user-guide//346/212/200/346/234/257/350/256/276/350/256/241/347/224/250/346/210/267/346/214/207/345/215/227.md" +0 -0
  641. /package/template/{docs → .template-spec}/user-guide//350/256/276/345/244/207/345/200/237/347/224/250/350/264/257/347/251/277/346/241/210/344/276/213.md" +0 -0
  642. /package/template/{docs → .template-spec}/user-guide//351/230/266/346/256/265/346/216/245/345/205/245/344/270/216/344/272/247/347/211/251/345/244/215/347/224/250/344/275/277/347/224/250/346/211/213/345/206/214.md" +0 -0
@@ -3,15 +3,17 @@
3
3
  ## 组件
4
4
 
5
5
  ```bash
6
- ./mvnw -f yss-microservice-components/yss-component-cache-parent/pom.xml verify
6
+ ./mvnw -f yss-microservice-components/yss-component-cache-parent/pom.xml clean verify
7
7
  ```
8
8
 
9
9
  跨模块测试使用父 reactor 的 `-pl <module> -am`,避免解析本地旧 SNAPSHOT。也可运行:
10
10
 
11
11
  ```bash
12
- scripts/verify-cache-component.sh --source-root /path/to/yss-cloud-microservice
12
+ scripts/verify-cache-component.sh --platform-line boot3-java17 --source-root /path/to/boot3/yss-cloud-microservice
13
13
  ```
14
14
 
15
+ 运行前将 `JAVA_HOME` 与 `PATH` 设为所选平台的 JDK(Boot 2 为 Java 8,Boot 3 为 Java 17);脚本从 `clean verify` 后的每个 cache class 检查 major,无法读取任一 class 即失败。
16
+
15
17
  ## 消费项目
16
18
 
17
19
  ```bash
@@ -22,13 +24,17 @@ scripts/verify-cache-component.sh --source-root /path/to/yss-cloud-microservice
22
24
 
23
25
  ## 验收矩阵
24
26
 
27
+ 通用命中、隔离和失效项适用于所选平台线;下述 `failure-mode`、区域策略、`empty-key-eviction` 与 JetCache 场景核验的是当前 Boot 3 / Java 17 组件。Boot 2 的对应行为按其源码和实际配置另行验证。
28
+
25
29
  - 首次调用执行业务,第二次相同 key 命中缓存。
26
30
  - 不同租户/业务 key 不串值。
27
31
  - 更新、删除、状态变更后旧值失效。
28
32
  - `condition`、`unless` 和异常返回行为符合预期。
29
33
  - 默认 TTL 和枚举覆盖 TTL 在后端物理存在。
30
- - Redis 停止后行为符合 fallback 配置;恢复后旧 Redis 值不会重新出现。
34
+ - Redis 故障时 fail-fast、bypass、fallback 的查询与显式写行为分别符合配置;恢复时脏 Redis 区域必须失效,失效失败不得切回。
35
+ - 区域 TTL/容量/空值策略按实际后端生效;`SimpleKey.EMPTY` 在 legacy-clear 与 evict 下分别执行清区与单 key 删除。
36
+ - JetCache 分别验证包装器与原生 `QuickConfig`:包装器即使配置广播频道也不自动同步本地失效;原生 `BOTH + syncLocal(true)` 在频道、相同 area/name 和订阅生效后,用两个独立 JVM 验证更新、删除与未订阅时的旧值边界;第二次创建不改变首次缓存配置。
31
37
  - Sentinel/Cluster 创建正确连接工厂,Cluster 使用 DB 0。
32
38
  - Docker 可用时真实 Redis 认证、JSON template、JDK cache serialization 和 TTL 测试实际执行。
33
- - Java 8 组件 class major version 为 52。
39
+ - 所选 Boot 2 / Java 8 源码 class major 为 52;Boot 3 / Java 17 为 61。两条平台线分别使用匹配的源码根运行脚本,Docker 不可用时单独报告真实 Redis 集成测试未执行。
34
40
  - `git diff --check` 通过,消费 starter 构建通过。
@@ -1,16 +1,18 @@
1
1
  #!/usr/bin/env bash
2
2
  set -u
3
3
 
4
+ platform_line=""
4
5
  source_root=""
5
6
  consumer_root=""
6
7
  consumer_module=""
7
8
 
8
9
  usage() {
9
- echo "Usage: $0 [--source-root PATH] [--consumer-root PATH --consumer-module MODULE]" >&2
10
+ echo "Usage: $0 --platform-line <boot2-java8|boot3-java17> [--source-root PATH] [--consumer-root PATH --consumer-module MODULE]" >&2
10
11
  }
11
12
 
12
13
  while [ "$#" -gt 0 ]; do
13
14
  case "$1" in
15
+ --platform-line) [ "$#" -ge 2 ] || { usage; exit 2; }; platform_line=$2; shift 2 ;;
14
16
  --source-root) [ "$#" -ge 2 ] || { usage; exit 2; }; source_root=$2; shift 2 ;;
15
17
  --consumer-root) [ "$#" -ge 2 ] || { usage; exit 2; }; consumer_root=$2; shift 2 ;;
16
18
  --consumer-module) [ "$#" -ge 2 ] || { usage; exit 2; }; consumer_module=$2; shift 2 ;;
@@ -19,21 +21,19 @@ while [ "$#" -gt 0 ]; do
19
21
  esac
20
22
  done
21
23
 
24
+ case "$platform_line" in
25
+ boot2-java8) expected_major=52; configured_root=${YSS_SOURCE_ROOT_BOOT2_JAVA8:-} ;;
26
+ boot3-java17) expected_major=61; configured_root=${YSS_SOURCE_ROOT_BOOT3_JAVA17:-} ;;
27
+ *) usage; exit 2 ;;
28
+ esac
29
+
22
30
  if [ -z "$source_root" ]; then
23
- source_root=${YSS_SOURCE_ROOT:-}
24
- fi
25
- if [ -z "$source_root" ]; then
26
- for candidate in "$PWD" "$PWD/.." "$HOME/Projects/yss-cloud-microservice" "$HOME/Documents/yss-project/yss-cloud-microservice"; do
27
- if [ -d "$candidate/yss-microservice-components/yss-component-cache-parent" ]; then
28
- source_root=$candidate
29
- break
30
- fi
31
- done
31
+ source_root=$configured_root
32
32
  fi
33
33
 
34
34
  parent="${source_root%/}/yss-microservice-components/yss-component-cache-parent"
35
35
  if [ -z "$source_root" ] || [ ! -f "$parent/pom.xml" ]; then
36
- echo "ERROR: cannot locate cache parent; use --source-root or YSS_SOURCE_ROOT" >&2
36
+ echo "ERROR: cannot locate cache parent for $platform_line; use --source-root or its generation-specific YSS_SOURCE_ROOT variable" >&2
37
37
  exit 2
38
38
  fi
39
39
  if [ ! -x "$source_root/mvnw" ]; then
@@ -46,7 +46,7 @@ if { [ -n "$consumer_root" ] && [ -z "$consumer_module" ]; } || { [ -z "$consume
46
46
  fi
47
47
 
48
48
  echo "== Cache reactor verify =="
49
- (cd "$source_root" && ./mvnw -f "$parent/pom.xml" verify) || exit 1
49
+ (cd "$source_root" && ./mvnw -f "$parent/pom.xml" clean verify) || exit 1
50
50
 
51
51
  echo "== Docker integration status =="
52
52
  report="$parent/yss-component-redis-cache/target/surefire-reports/TEST-com.yss.cloud.cache.redis.config.RedisStandaloneIntegrationTest.xml"
@@ -66,14 +66,14 @@ fi
66
66
 
67
67
  echo "== Diff whitespace =="
68
68
  if command -v git >/dev/null 2>&1 && git -C "$source_root" rev-parse --is-inside-work-tree >/dev/null 2>&1; then
69
- git -C "$source_root" diff --check || exit 1
69
+ git -C "$source_root" diff --check -- yss-microservice-components/yss-component-cache-parent || exit 1
70
70
  else
71
71
  echo "SKIP: source root is not a Git worktree"
72
72
  fi
73
73
 
74
- echo "== Java 8 bytecode =="
75
- classes=$(find "$parent" -path '*/target/classes/*.class' -type f | head -1)
76
- if [ -z "$classes" ]; then
74
+ echo "== $platform_line bytecode (major $expected_major) =="
75
+ class_count=$(find "$parent" -path '*/target/classes/*.class' -type f | wc -l | tr -d ' ')
76
+ if [ "$class_count" -eq 0 ]; then
77
77
  echo "ERROR: no compiled cache class found" >&2
78
78
  exit 1
79
79
  fi
@@ -81,12 +81,18 @@ if ! command -v javap >/dev/null 2>&1; then
81
81
  echo "ERROR: javap is required for bytecode verification" >&2
82
82
  exit 2
83
83
  fi
84
- majors=$(find "$parent" -path '*/target/classes/*.class' -type f -exec javap -verbose {} \; 2>/dev/null | sed -n 's/.*major version: *//p' | sort -u)
85
- if [ "$majors" != "52" ]; then
86
- echo "ERROR: expected only Java 8 major version 52, found: $majors" >&2
84
+ major_lines=$(find "$parent" -path '*/target/classes/*.class' -type f -exec javap -verbose {} \; 2>/dev/null | sed -n 's/.*major version: *//p')
85
+ checked_count=$(printf '%s\n' "$major_lines" | sed '/^$/d' | wc -l | tr -d ' ')
86
+ if [ "$checked_count" -ne "$class_count" ]; then
87
+ echo "ERROR: javap inspected $checked_count of $class_count compiled cache classes" >&2
88
+ exit 1
89
+ fi
90
+ majors=$(printf '%s\n' "$major_lines" | sort -u)
91
+ if [ "$majors" != "$expected_major" ]; then
92
+ echo "ERROR: expected only $platform_line major version $expected_major, found: $majors" >&2
87
93
  exit 1
88
94
  fi
89
- echo "PASS: all cache classes use major version 52"
95
+ echo "PASS: all cache classes use major version $expected_major"
90
96
 
91
97
  if [ -n "$consumer_root" ]; then
92
98
  echo "== Consumer build =="
@@ -32,7 +32,7 @@ description: 用于生成完整的 YSS DDD 多模块后端脚手架。当用户
32
32
  - Spring MVC、Servlet、Validation、Jackson 和 starter 坐标消费共享平台清单;Java 下限和允许组合由当前平台条目决定。Jakarta 转换不包括 `javax.sql` 等 Java SE API。
33
33
  - 平台候选维护验证产物标记 `platform_verification=candidate`,不能交给业务生成、升级完成等级或进入首切片验证。测试夹具不证明 YSS 兼容。
34
34
 
35
- 版本清单、合同字段、候选验证和支持晋级规则见 仓库共享合同 `docs/engineering/backend-platforms.md`。
35
+ 版本清单、合同字段、候选验证和支持晋级规则见 仓库共享合同 `.template-spec/engineering/backend-platforms.md`。
36
36
 
37
37
  ## 优先流程
38
38
 
@@ -74,7 +74,7 @@ description: 用于生成完整的 YSS DDD 多模块后端脚手架。当用户
74
74
  - 生成后的后端工程必须使用项目根目录 `./mvnw ...` 执行构建、测试、运行和 CI 验证;不得在 README、实施记录、Ticket、Review 或 Release 中默认写裸 `mvn ...`。既有仓库确实无法使用 wrapper 时,必须记录受控例外。
75
75
  - 原型确认后,`scaffold_status=required` 才能进入本 skill;本 skill 的生成边界是工程结构、POM、配置、Wrapper 和机械模板,不是业务实现。
76
76
  - 脚手架合同必须携带 `contract_id`、`contract_version`、实现合同编译器 draft 引用、生命周期批准引用、持久化引用、当前版本、允许写路径、预期证据文件和验证命令;字段缺失或版本过期时阻断。
77
- - 新脚手架只接受统一 Project Scaffold Contract schema v4,并必须以原始字节摘要绑定批准且当前的 Technical Design、Data Architecture Decision v1、API Contract Decision v1 和真实工程合同批准记录。API `required` 必须闭包绑定同一 OpenAPI YAML 字节的 Validation、独立 Review、Freeze 与工程批准;`not-applicable` 必须绑定评估、明确原因和证据且禁止空占位资产。历史 Manifest 只读审计见 [历史兼容边界](references/generator-maintenance.md),不得用于新生成。
77
+ - 新脚手架只接受统一 Project Scaffold Contract schema v4,并必须以原始字节摘要绑定批准且当前的 Technical Design、Data Architecture Decision v1、API Contract Decision(新建 v2;历史 v1 只读兼容,准备与迁移见 `.template-spec/process/contract-reading.md`) 和真实工程合同批准记录。API `required` 必须闭包绑定同一 OpenAPI YAML 字节的 Validation、独立 Review、Freeze 与工程批准;`not-applicable` 必须绑定评估、明确原因和证据且禁止空占位资产。历史 Manifest 只读审计见 [历史兼容边界](references/generator-maintenance.md),不得用于新生成。
78
78
  - DDD 固定 `target-domain-model`、`mybatis-plus`、H2 验证、`web` DTO、`yss-internal`;平台与 Validation 命名空间由共享清单约束。普通 MyBatis、独立 client module、client-in-domain 和其他旧架构仍为 `unsupported`。
79
79
  - 运行生成器必须传入 `--contract-file`;生成器会校验合同 `status=approved`、`current_version`、`primary_skill`、`controlled-generation`、实际输出路径和固定三条验证命令,不接受仅凭任意字符串引用的放行。
80
80
  - 生成项目必须写入 Manifest v4 `.yss/scaffold-generation.json`,记录技术、数据与 API 设计门禁、架构选择及 digest、生成器、合同 digest、Target Profile、模块闭包、模板 digest、下游完整 当前合同 freshness、generator-owned 文件 hash、严格 `generation_policy` 和完成等级;清单缺失或不一致时不得交给后续 实现合同编译器。
@@ -209,7 +209,7 @@ export class ScaffoldGenerator {
209
209
  if (!contract || Array.isArray(contract) || typeof contract !== "object") fail("脚手架合同必须是 JSON 对象");
210
210
  if (contract.schema_version !== 4) fail(`unsupported: 后端新生成只接受 Project Scaffold Contract v4,收到 v${contract.schema_version}`);
211
211
  if (contract.kind !== "project-scaffold-contract" || contract.delivery_role !== "backend" || contract.scaffold_kind !== "backend-ddd") fail("schema v4 合同必须绑定 backend/backend-ddd");
212
- validateJsonSchema(contract, path.join(REPOSITORY_ROOT, "docs/process/schemas/project-scaffold-contract.schema.json"), { label: "Project Scaffold Contract v4" });
212
+ validateJsonSchema(contract, path.join(REPOSITORY_ROOT, ".template-spec/process/schemas/project-scaffold-contract.schema.json"), { label: "Project Scaffold Contract v4" });
213
213
  const requiredMetadata = [["--contract-id", this.options.contractId], ["--contract-version", this.options.contractVersion], ["--approval-ref", this.options.approvalRef], ["--compiler-draft-ref", this.options.compilerDraftRef], ["--persisted-ref", this.options.persistedRef]];
214
214
  const missing = requiredMetadata.filter(([, value]) => !isPresent(value)).map(([flag]) => flag);
215
215
  if (missing.length) fail(`生成项目必须提供当前已批准脚手架合同的完整元数据: ${missing.join(", ")}`);
@@ -10,24 +10,24 @@ description: 建立或核验 YSS 设计系统、主题 Token 与页面视觉一
10
10
  ## 权威资料
11
11
 
12
12
  - 规范源:根 `DESIGN.md`,是项目视觉 Token 与组件视觉变体的唯一事实来源,使用 Google `design.md` alpha canonical H2 章节。
13
- - 团队治理说明:`docs/design/design.md`,解释 YSS 生命周期、组件路线、状态与验收,不重新定义 `DESIGN.md` 中的具体值。
14
- - 项目 Token 快照:`docs/design/tokens/theme.json`、`docs/design/tokens/tokens.default.json`、`docs/design/tokens/tokens.dark.json`、`docs/design/tokens/tokens.compact.json`、`docs/design/tokens/variables.css`、`docs/design/tokens/variables.dark.css`;它们是派生实现视图,不得反向覆盖规范源。
15
- - 本技能执行清单:`references/design-system.md`,用于 Agent 执行和评审,不替代 `docs/design/design.md`。
13
+ - 团队治理说明:`.template-spec/design/design.md`,解释 YSS 生命周期、组件路线、状态与验收,不重新定义 `DESIGN.md` 中的具体值。
14
+ - 项目 Token 快照:`.template-spec/design/tokens/theme.json`、`.template-spec/design/tokens/tokens.default.json`、`.template-spec/design/tokens/tokens.dark.json`、`.template-spec/design/tokens/tokens.compact.json`、`.template-spec/design/tokens/variables.css`、`.template-spec/design/tokens/variables.dark.css`;它们是派生实现视图,不得反向覆盖规范源。
15
+ - 本技能执行清单:`references/design-system.md`,用于 Agent 执行和评审,不替代 `.template-spec/design/design.md`。
16
16
  - 历史输入包:`/Users/zhudaoming/Downloads/Product-Design-System`,只用于追溯首次引入来源,不作为后续工程依赖。
17
17
  - 默认主题来源:Data Quality 主题经项目适配后落到根 `DESIGN.md`;来源与 AntD v6 设计参考 / Vue 运行时的区别见 `references/data-quality-theme.md`。
18
18
  - Codex `$design-qa` 项目对照:`references/design-qa-theme.md`,不替代官方 `design-qa` 流程,也不改上游插件正文。
19
19
  - 原型阶段合同:`yss-prototype-stage`,用于统一 H1/H2 原型资产和浏览器验证证据。H1/H2 默认使用项目 Token 驱动的 HTML/CSS/JavaScript 离线原型。
20
20
 
21
- 如果只需要快速判断,先读本文件。若要写 UI 规范、实现页面、评审设计或调整 Token,必须按 `DESIGN.md` → `docs/design/design.md` 顺序读取,再按当前主题、密度与输出表面选择对应 Token 文件,不全量预读所有主题;若要执行评审或实现检查,再读 `references/design-system.md`。
21
+ 如果只需要快速判断,先读本文件。若要写 UI 规范、实现页面、评审设计或调整 Token,必须按 `DESIGN.md` → `.template-spec/design/design.md` 顺序读取,再按当前主题、密度与输出表面选择对应 Token 文件,不全量预读所有主题;若要执行评审或实现检查,再读 `references/design-system.md`。
22
22
 
23
23
  ## 使用流程
24
24
 
25
25
  1. 先判断任务阶段:设计系统引入 / 产品设计 / 原型评审 / 前端实现 / UI 改造 / 主题 token 落地。
26
- 2. 读取已有资产:先读根 `DESIGN.md`,再读 `docs/design/design.md` 和 Token 派生快照,最后按任务读取相关 Spec、交互说明、状态矩阵、OpenAPI Draft、现有页面代码。
26
+ 2. 读取已有资产:先读根 `DESIGN.md`,再读 `.template-spec/design/design.md` 和 Token 派生快照,最后按任务读取相关 Spec、交互说明、状态矩阵、OpenAPI Draft、现有页面代码。
27
27
  3. 按设计系统基线约束输出或修改产物:颜色、排版、间距、圆角、动效、组件、状态、响应式。
28
28
  4. 若是产品设计阶段,先使用 `yss-prototype-stage`;规范直出由 YSS HTML adapter 执行;存在已选视觉稿时条件使用 `product-design:index`,其他 Agent 交付等价证据。
29
29
  5. 若是前端实现阶段,配合 `yss-ui`、`yss-ui-business-page-generation`、`yss-formily` 及实际命中的组件专项,但本技能负责风格与体验一致性门禁。
30
- 6. 若发现视觉 Token 或组件变体不足,先更新根 `DESIGN.md` 并重新生成投影;只有治理、流程或验收说明不足时才更新 `docs/design/design.md`。
30
+ 6. 若发现视觉 Token 或组件变体不足,先更新根 `DESIGN.md` 并重新生成投影;只有治理、流程或验收说明不足时才更新 `.template-spec/design/design.md`。
31
31
 
32
32
  ## 核心基线
33
33
 
@@ -62,7 +62,7 @@ description: 建立或核验 YSS 设计系统、主题 Token 与页面视觉一
62
62
 
63
63
  设计类任务至少输出:
64
64
 
65
- - 设计系统引用:明确引用根 `DESIGN.md`、治理说明 `docs/design/design.md` 和所选主题的 Token 快照;原型证据记录规范与 Token 摘要。
65
+ - 设计系统引用:明确引用根 `DESIGN.md`、治理说明 `.template-spec/design/design.md` 和所选主题的 Token 快照;原型证据记录规范与 Token 摘要。
66
66
  - 页面和模块:页面清单、布局结构、主路径、异常路径。
67
67
  - 组件选择:YSS UI / Ant Design 组件映射。
68
68
  - 状态矩阵:加载、空、错、禁用、只读、无权限、冲突、成功。
@@ -99,10 +99,10 @@ description: 建立或核验 YSS 设计系统、主题 Token 与页面视觉一
99
99
  当用户要求“引入设计系统”“形成项目规范”“更新设计系统 skill”时:
100
100
 
101
101
  1. 分析来源设计系统,不原样堆拷贝。
102
- 2. 将稳定视觉 Token 与组件变体先落到根 `DESIGN.md`;治理、流程和验收说明再落到 `docs/design/design.md`。
103
- 3. 运行 `node .template-source/tooling/node/scripts/design-md.mjs export dtcg --write --write-manifest --antd-toolchain <固定antd6.6.4作者目录>` 更新派生视图;运行前先更新 `docs/design/design-system-sync.yaml` 的规范源摘要。
102
+ 2. 将稳定视觉 Token 与组件变体先落到根 `DESIGN.md`;治理、流程和验收说明再落到 `.template-spec/design/design.md`。
103
+ 3. 运行 `node .template-source/tooling/node/scripts/design-md.mjs export dtcg --write --write-manifest --antd-toolchain <固定antd6.6.4作者目录>` 更新派生视图;运行前先更新 `.template-source/design/design-system-sync.yaml` 的规范源摘要。
104
104
  4. 将 Agent 执行入口落到 `.agents/skills/yss-design-system/SKILL.md`,执行清单落到 `references/design-system.md`;两者只引用 Token 名和角色,不复制具体值。
105
- 5. 更新 `docs/design/README.md` 和必要的 `AGENTS.md` 入口规则。
105
+ 5. 更新 `.template-spec/design/README.md` 和必要的 `AGENTS.md` 入口规则。
106
106
  6. 运行 frontmatter、对应 `node --test`、`design-md lint/drift`、技能投影与 lock 校验。
107
107
 
108
108
  默认主题事实见 `references/data-quality-theme.md`;运行时 Ant Design Vue 4 与 AntD v6 设计参考分别记录。
@@ -5,8 +5,8 @@
5
5
  ## Source visual truth
6
6
 
7
7
  - 规范:根 `DESIGN.md`
8
- - 治理说明:`docs/design/design.md`
9
- - Token 投影:`docs/design/tokens/theme.json`、`docs/design/tokens/tokens.default.json`、`docs/design/tokens/variables.css`
8
+ - 治理说明:`.template-spec/design/design.md`
9
+ - Token 投影:`.template-spec/design/tokens/theme.json`、`.template-spec/design/tokens/tokens.default.json`、`.template-spec/design/tokens/variables.css`
10
10
  - 主题选择:默认采用根 `DESIGN.md` 的 Data Quality 浅色主题;仅显式暗色 / 紧凑模式使用对应的 `tokens.dark.json` / `variables.dark.css` / `tokens.compact.json`,以实际消费文件记录摘要。
11
11
  - 实现截图:当前原型或页面在同一 viewport / 主题 / 状态下的渲染
12
12
 
@@ -23,7 +23,7 @@
23
23
  | 功能状态 | `colors.success*` / `warning*` / `error*` / `info-bg` | 改成非功能色装饰 |
24
24
  | 页面 / 容器 / 浮层 | `colors.canvas-layout` / `surface*` | 用阴影或局部硬编码堆叠表面层级 |
25
25
  | 主次文本 | `colors.text*` | 使用历史文本值或页面特例 |
26
- | 运行时变量 | `docs/design/tokens/variables.css` 必须与根规范 digest 同步 | 页面另写一套 Less/CSS 色值 |
26
+ | 运行时变量 | `.template-spec/design/tokens/variables.css` 必须与根规范 digest 同步 | 页面另写一套 Less/CSS 色值 |
27
27
 
28
28
  上游预设色板不是品牌 seed,不要据此判定规范漂移。
29
29
 
@@ -5,8 +5,8 @@
5
5
  权威资料:
6
6
 
7
7
  - 规范源:根 `DESIGN.md`(项目视觉 Token 与组件视觉变体)
8
- - 治理说明:`docs/design/design.md`(生命周期、组件路线、状态与验收)
9
- - 派生快照:`docs/design/tokens/*`(实现映射,不得反向覆盖规范源)
8
+ - 治理说明:`.template-spec/design/design.md`(生命周期、组件路线、状态与验收)
9
+ - 派生快照:`.template-spec/design/tokens/*`(实现映射,不得反向覆盖规范源)
10
10
  - Skill 入口:`.agents/skills/yss-design-system/SKILL.md`
11
11
 
12
12
  ## 设计定位
@@ -205,7 +205,7 @@ YSS UI / Vue:
205
205
 
206
206
  设计评审时检查:
207
207
 
208
- - 是否引用根 `DESIGN.md`、治理说明 `docs/design/design.md` 与所选主题快照,并在原型证据中记录摘要。
208
+ - 是否引用根 `DESIGN.md`、治理说明 `.template-spec/design/design.md` 与所选主题快照,并在原型证据中记录摘要。
209
209
  - 是否符合中后台定位。
210
210
  - 页面清单、主路径、异常路径是否清楚。
211
211
  - 状态矩阵是否完整。
@@ -1,72 +1,28 @@
1
1
  ---
2
2
  name: yss-distributed-id
3
- description: "接入或排查 YSS 分布式 ID:Leaf、CosId、号段、雪花算法或 MyBatis 主键注入。"
3
+ description: "接入或排查 YSS 分布式 ID 的 Segment、Snowflake、主键注入与迁移;旧 CosId/远程调用仅按既有平台线分诊。"
4
4
  ---
5
5
 
6
6
  # yss-distributed-id
7
7
 
8
- 用于处理 `yss-component-distributed-id` 的配置、接入和问题定位。
8
+ 处理 `yss-component-distributed-id` 及 Leaf 消费项目的发号、主键填充与迁移。先从批准的 `platform_configuration.component_platform_line` 选择 [源码索引](references/source-index.md);Boot 2 的历史能力不能推定为 Boot 3 可用能力。无批准合同的既有工程故障可只读分诊,不据此改策略或宣布兼容。
9
9
 
10
- ## 何时使用
10
+ ## 接入决策
11
11
 
12
- - 用户要启用分布式 ID。
13
- - 用户提到 Leaf Segment、Snowflake、CosId、UUID。
14
- - 用户反馈批量插入未自动注入 ID、ID 冲突、ID 类型不匹配。
12
+ 1. 核对实际组件 GAV、平台线、依赖树及当前源码,再确定已有主键策略、注入模式和数据库约束。保持既有 Long 主键及调用方类型,策略变更单独评估数据和 API 影响。
13
+ 2. Boot 3 的数值分布式发号使用本地 Leaf Segment / Snowflake;拦截器仍有 String UUID 分支,但它不是数值发号方案。CosId、Feign/远程注入及旧注解参数是迁移分诊线索,不作为新接入选项;Boot 2 维护以其独立源码索引为准。
14
+ 3. Boot 3 默认 `local + Segment`:引入组件后核对 DataSource、JDBC 驱动、目标方言建表脚本及 `leaf_alloc`。不发号的应用应显式关闭注入及 Segment;选 Snowflake 时显式启用 Snowflake、关闭 Segment,并验证 worker-id 唯一、时钟回拨处理和节点重启行为。`local` 注入须且只能启用一种算法,不要把 ZooKeeper 当作当前 Snowflake 的默认依赖。
15
+ 4. Segment 缺失标签策略、声明、step 和初始水位必须与真实业务表及既有分配记录一致。自动建标签不建表、也不读取业务表最大 ID;迁移前固定停写/切换边界,起点不得低于已分配号段上界,不重置 `leaf_alloc`。
16
+ 5. 主键填充同时核对实体注解、插入方法和参数形态。`IdType.AUTO` 保留数据库自增;`ASSIGN_ID` 或显式 Segment/Snowflake 才走组件发号。已有非零值应保留;生成值与 `Long`、十进制 `String`、`Integer` 的转换及溢出必须验证,不能只凭注解推断批量入口已被拦截。
15
17
 
16
- ## 工作方式
18
+ ## 排障与验证
17
19
 
18
- 1. 先识别项目用的是哪种 ID 策略。
19
- 2. 涉及真实类名、配置项、Leaf 服务或批量插入排障时,先读 `references/source-index.md`,再定位源码或文档。
20
- 3. 再看实体注解、拦截器配置和底层表或注册中心依赖是否齐全。
21
- 4. 修改时优先保持现有策略,不轻易切换算法。
20
+ - 启动失败:按自动配置、注入模式、算法开关、DataSource、`leaf_alloc`、方言顺序定位。`disabled` 仅关闭自动注入;完全不用 Segment 时还须核对其算法开关。
21
+ - 重号/错号:核对跨服务业务 tag、控制表唯一键、当前水位、历史号段、Snowflake worker-id 与时钟;先保留现场,不用重建表或清空控制记录排障。
22
+ - 插入缺 ID:核对 `TableId`/生成策略、实体字段类型、当前公开批量方法及 MyBatis 参数包装是否经过拦截器;再检查消费者自定义 `IdentifierGenerator` 是否接管。
23
+ - 行为修改使用组件父 reactor 的根 `./mvnw` 验证启动、单条/批量主键、迁移边界和目标数据库方言;H2 不能证明生产方言。只读故障分诊与已执行验证分别记录。
22
24
 
23
- ## 源码索引
24
-
25
- - 源码位置不要假设固定目录;先按 `yss-skill-source-index-refresh/references/source-location.md` 定位。
26
- - 当前技能索引:`references/source-index.md`
27
- - 重点源码入口通常包括 `EnableDistributedId`、`AutoIdInterceptor`、Leaf 配置、Leaf REST/Feign/gRPC 模块、ID 策略相关类。
28
-
29
- 当组件源码变化后,用 `yss-skill-source-index-refresh` 刷新索引;刷新或读取前先按源码定位策略确认真实位置。
30
-
31
- ## 检查清单
32
-
33
- - 启动类是否启用了分布式 ID 能力。
34
- - 当前策略是否与部署条件匹配。
35
- - 批量插入链路是否会经过拦截器。
36
- - 实体主键类型与生成策略是否兼容。
37
- - Leaf Segment 场景下 `leaf_alloc` 是否已初始化。
38
- - MyBatis/MyBatis-Plus 的插入方法是否绕过了自动 ID 拦截逻辑。
39
- - 多服务共享号段时,业务 tag/key 是否唯一且稳定。
40
-
41
- ## 策略建议
42
-
43
- - 追求稳定和趋势递增时,优先 Leaf Segment。
44
- - 依赖 ZooKeeper 且要求高吞吐时,可考虑 Snowflake。
45
- - 若项目已有 CosId 统一方案,沿用现有生态。
46
- - 除非业务明确允许,否则不要把 Long 主键切到 String UUID。
47
-
48
- ## 修改约束
49
-
50
- - 不要混用多种主键生成策略而不说明边界。
51
- - 不要仅改实体注解而忽略底层配置和依赖。
52
- - 如果用户只是在做普通 MyBatis-Plus 主键配置,不要过度引入新组件。
53
- - 不要在已有 Long 主键生态里随意改成 String UUID,除非调用方和数据库约束都确认兼容。
54
-
55
- ## 排障顺序
56
-
57
- 1. 确认启用注解和 starter 依赖。
58
- 2. 确认实体主键类型、注解和插入方法。
59
- 3. 确认拦截器是否参与 MyBatis 调用链。
60
- 4. Leaf 场景确认服务、号段表和业务 key。
61
- 5. Snowflake/CosId 场景确认机器号、时钟、注册中心或 worker 分配。
62
- 6. 批量插入失败时确认是否调用了项目推荐批量方法。
63
-
64
- ## 按需读取
65
-
66
- - 源码索引:`references/source-index.md`
67
- - 拦截器与自动注入:`assets/AutoIdInterceptor.java`
68
- - 启用注解:`assets/EnableDistributedId.java`
69
- - Leaf 配置相关:`assets/LeafConf.java`
25
+ 当前源码入口与平台差异见 [能力与迁移说明](references/README.md)。不要从 Skill 的历史示例或旧资产复制生产源码;精确类名、配置和默认值以选定平台线的当前源码为准。
70
26
 
71
27
  ## 平台与源码门禁
72
28
 
@@ -1,5 +1,5 @@
1
1
  version: 1
2
2
  interface:
3
3
  display_name: "YSS Distributed ID"
4
- short_description: "Leaf、CosId 与分布式 ID 接入与配置规范"
5
- default_prompt: "Use $yss-distributed-id to configure or debug distributed ID generation, Leaf, CosId, and MyBatis ID injection."
4
+ short_description: "Leaf Segment、Snowflake 与主键注入排障"
5
+ default_prompt: "Use $yss-distributed-id to configure or debug platform-bound Leaf Segment, Snowflake, and MyBatis ID injection; treat CosId and remote modes as legacy migration cases."
@@ -1,51 +1,15 @@
1
- # 参考资料
1
+ # 分布式 ID 能力与迁移说明
2
2
 
3
- 本文档详细介绍了 `yss-component-distributed-id` 框架的核心组件和实现原理。
3
+ 本文件只说明选择和核验边界。类名、配置默认值及方法签名以所选平台线的生成索引和匹配的干净源码为准,不复制组件实现。
4
4
 
5
- ## 核心类 (Core Classes)
5
+ | 场景 | Boot 3 / Java 17 当前工作树观察 | 核验重点 |
6
+ |---|---|---|
7
+ | Segment | 本地号段;默认 local + Segment | DataSource、目标方言建表、`biz_tag` 唯一键、已分配水位、缺失标签策略 |
8
+ | Snowflake | 本地节点发号;可配置 worker-id,未指定时按节点地址派生 | 所有实例 worker-id 无冲突、时钟回拨和序列等待;不假设 ZooKeeper 注册 |
9
+ | 主键自动填充 | MyBatis 拦截与 MyBatis-Plus `IdentifierGenerator` 两条入口 | `AUTO` 与 `ASSIGN_ID` 区分、已有值保留、批量参数形态、`Integer` 溢出 |
10
+ | String UUID | 本地拦截器仍有 UUID 字符串分支 | 仅核对显式 UUID 策略及 String 字段,不当作 Segment/Snowflake 的数值主键迁移替代 |
11
+ | CosId、Feign/远程注入 | 当前 Boot 3 主线不提供 | 仅对既有项目按其实际平台线和源码做迁移分诊,不把旧模块写成新接入依赖 |
6
12
 
7
- ### 1. AutoIdInterceptor.java
8
- **位置**: `../assets/AutoIdInterceptor.java`
13
+ Segment 从现有业务表接管 ID 时,先记录业务表最大值、`leaf_alloc.max_id` 和尚未用尽的已分配号段,再在停写窗口确定不回退的起点。缺失标签自动创建不会计算这些值;不得删除或重置控制记录。Snowflake 切换需验证新旧机器位语义及所有活跃节点,不在混合写流量时直接换算法。遗留 `feign_segment` 注解仍是明确的拒绝路径,迁移须清理旧注解及依赖,不能用已有非零 ID 掩盖它。
9
14
 
10
- MyBatis 拦截器,是实现自动 ID 注入的核心。
11
-
12
- **拦截逻辑**:
13
- - **拦截点**: `StatementHandler.prepare` 方法。
14
- - **判断条件**: 仅拦截 `INSERT` 语句。
15
- - **处理流程**:
16
- 1. 获取 SQL 绑定的参数对象 (`parameterObject`)。
17
- 2. 支持处理单对象、`List`、`Array` 和 `Map` (MyBatis 多参数封装)。
18
- 3. 遍历参数对象的实体类,检查是否有 `@Entity` (JPA) 或 `@TableName` (MP) 注解。
19
- 4. 扫描实体字段,查找 `@GeneratedValue` 或 `@TableId` 注解。
20
- 5. 根据注解指定的策略 (`segment`, `snowflake`, `cosid_segment` 等),调用对应的 ID 生成器获取 ID。
21
- 6. 通过反射将 ID 设置到实体的相应字段中。
22
-
23
- ### 2. EnableDistributedId.java
24
- **位置**: `../assets/EnableDistributedId.java`
25
-
26
- 开启分布式 ID 功能的注解。
27
-
28
- **属性**:
29
- - `autoRegister`: 是否自动注册配置,默认为 `true`。
30
- - `cosid`: 是否开启 CosId 模式,默认为 `false` (即默认使用 Leaf 模式)。
31
-
32
- **作用**:
33
- - 导入 `LeafDataSourceConfiguration` 和 `EnableDistributedImportSelector`,从而根据配置加载相应的 Bean。
34
-
35
- ### 3. LeafConf.java
36
- **位置**: `../assets/LeafConf.java`
37
-
38
- Leaf 模式的配置类,对应 `spring.leaf` 配置项。
39
-
40
- **属性**:
41
- - `leafSegmentEnable`: 是否开启号段模式。
42
- - `leafSnowflakeEnable`: 是否开启雪花算法模式。
43
-
44
- ## ID 生成策略详解
45
-
46
- | 策略名称 | 依赖组件 | 描述 | 适用场景 |
47
- | :--- | :--- | :--- | :--- |
48
- | **Leaf Segment** | DB (MySQL) | 基于数据库号段,每次从 DB 获取一个号段到内存,高性能,ID 趋势递增。 | 大多数业务场景,高可用要求高。 |
49
- | **Leaf Snowflake** | Zookeeper | 基于 Twitter 雪花算法,依赖 ZK 进行 WorkerID 管理。 | 对 ID 生成速度要求极高,且不依赖 DB 的场景。 |
50
- | **CosId Segment** | DB (MySQL) | CosId 的号段模式实现,支持更丰富的配置(如步长动态调整)。 | 需要 CosId 特性或作为 Leaf 的替代方案。 |
51
- | **UUID** | JDK | 标准 UUID。 | 无需有序、不关心存储空间的场景。 |
15
+ 只读分诊可参考当前组件 `readme.md` 和源码路径提示;组件子树 dirty、索引 tree 不一致或兼容证据未 verified 时,这些观察不构成精确接入或发布结论。
@@ -25,7 +25,7 @@ Read `references/source-index.md` as a path-hint index whenever the task depends
25
25
  4. Check `YssGlobalExceptionProperties` when global exception output/logging behavior is configurable.
26
26
  5. Keep logging semantics aligned: business exceptions usually do not require error-stack logging; system/unknown exceptions usually do.
27
27
  6. In the `target-domain-model` profile, Domain owns stable error meaning and parameters but does not depend directly on YSS `BizException` or HTTP. Translate at the Web boundary after verifying the component handler precedence.
28
- 7. MVC Profile 的稳定业务错误归 service/core;Repository 保留 cause;server 持有 HTTP 映射与脱敏。不要为了复用错误码引入 Domain 层或让 core 依赖 client。分层依据 `docs/agents/backend-architecture-profiles.md`。
28
+ 7. MVC Profile 的稳定业务错误归 service/core;Repository 保留 cause;server 持有 HTTP 映射与脱敏。不要为了复用错误码引入 Domain 层或让 core 依赖 client。分层依据 `.template-spec/agents/backend-architecture-profiles.md`。
29
29
 
30
30
  ## Boot 3 Current Source Behavior
31
31
 
@@ -32,7 +32,7 @@ description: Use when creating a new YSS frontend micro-application from the sta
32
32
 
33
33
  ## Workflow
34
34
 
35
- 采用专职前端 profile 或显式 `frontend_delivery` 绑定时,先按 `docs/process/frontend-backend-delivery.md` 实际核验战略与后端联合交付。缺任一输入只能诊断和回交;输入通过后准备计划/合同,正式实现、生成和恢复仍须当前批准的 Slice Contract 冻结接收摘要。接口或部署版本漂移时重新接收,不复用旧成功输出。
35
+ 采用专职前端 profile 或显式 `frontend_delivery` 绑定时,先按 `.template-spec/process/frontend-backend-delivery.md` 实际核验战略与后端联合交付。缺任一输入只能诊断和回交;输入通过后准备计划/合同,正式实现、生成和恢复仍须当前批准的 Slice Contract 冻结接收摘要。接口或部署版本漂移时重新接收,不复用旧成功输出。
36
36
 
37
37
  1. 确认当前任务已经通过 Harness 入口分诊、逐项目脚手架决定已由真实用户确认,且 schema v4 合同已由生命周期批准、持久化并保持当前。
38
38
  2. 确认目标是外部实现仓库;只有用户明确选择时才输出到 Harness 仓库的 `apps/frontend/<project>/`。`apps/frontend/` 只能作为项目容器,`app/frontend/`、`app/backend/` 及其子路径禁止作为输出位置。`git-submodule` 只能在已初始化且附加分支的子仓工作树生成;空 gitlink、detached HEAD、`--force` 覆盖挂载点不得当成普通目录。
@@ -42,7 +42,7 @@ description: Use when creating a new YSS frontend micro-application from the sta
42
42
  6. 有 API 影响时核验 OpenAPI Freeze 记录和 JSON 派生记录,将摘要一致的 JSON 原样物化到 `<frontend>/openapi/openapi.json`;`openapi_impact=not-applicable` 时必须有原因并禁止生成 API client。
43
43
  7. 保持模板既有的前端代码生成配置不变;本 Harness 只将 SHA-256 一致的 JSON 原样交给既有前端代码生成流程,不修改该配置、不在此仓库执行生成,也不设置生成 CI 门禁。目标前端项目在需要时手动运行其既有命令。
44
44
  8. 企业 registry / 认证由目标环境用户级 npm 配置提供,禁止复制来源 `.npmrc` 或 token。实际执行并记录 `pnpm install --frozen-lockfile`、`pnpm lint:check`、`pnpm type-check`、`pnpm build`、`pnpm build:standalone` 的退出码和日志;缺失脚本只能由批准的工程基线提供替代命令。任何必需命令失败都阻断。
45
- 9. 按 `docs/templates/implementation-repo-registry-template.md` 回写前端实现仓库登记。
45
+ 9. 按 `.template-spec/templates/implementation-repo-registry-template.md` 回写前端实现仓库登记。
46
46
 
47
47
  ## Expected Template Shape
48
48
 
@@ -28,7 +28,7 @@ function walk(root) {
28
28
  });
29
29
  }
30
30
  function validate(contract, outputDir) {
31
- validateJsonSchema(contract, path.join(REPOSITORY_ROOT, "docs/process/schemas/project-scaffold-contract.schema.json"), { label: "Project Scaffold Contract v4" });
31
+ validateJsonSchema(contract, path.join(REPOSITORY_ROOT, ".template-spec/process/schemas/project-scaffold-contract.schema.json"), { label: "Project Scaffold Contract v4" });
32
32
  if (contract.schema_version !== 4 || contract.kind !== "project-scaffold-contract") fail("frontend scaffold requires Project Scaffold Contract schema v4");
33
33
  if (contract.status !== "approved" || contract.current_version !== true || !contract.persisted_ref) fail("scaffold contract must be approved, persisted and current");
34
34
  if (contract.delivery_role !== "frontend" || contract.scaffold_kind !== "frontend-yss-vue3" || contract.generator_skill !== "yss-frontend-scaffold-generator") fail("contract is not for the YSS frontend generator");
@@ -9,8 +9,8 @@ const assets = path.join(skill, 'assets/data-quality-v1');
9
9
  const sha = bytes => `sha256:${createHash('sha256').update(bytes).digest('hex')}`;
10
10
  const walk = root => readdirSync(root, { withFileTypes: true }).flatMap(item => item.isDirectory() ? walk(path.join(root, item.name)) : [path.join(root, item.name)]);
11
11
  const design = readFileSync(path.join(repository, 'DESIGN.md'));
12
- const theme = JSON.parse(readFileSync(path.join(repository, 'docs/design/tokens/theme.json')));
13
- const css = readFileSync(path.join(repository, 'docs/design/tokens/variables.css'), 'utf8');
12
+ const theme = JSON.parse(readFileSync(path.join(repository, '.template-spec/design/tokens/theme.json')));
13
+ const css = readFileSync(path.join(repository, '.template-spec/design/tokens/variables.css'), 'utf8');
14
14
  const token = name => css.match(new RegExp(`--${name}: ([^;]+);`))[1];
15
15
  const projection = { ...theme, accessibility: { primaryControl: token('yss-color-primary-control'), primaryControlHover: token('yss-color-primary-control-hover') } };
16
16
  const generated = { 'DESIGN.md': design, 'packages/src/config/theme.json': Buffer.from(JSON.stringify(projection, null, 2) + '\n') };
@@ -5,15 +5,15 @@ description: "编译或重验 YSS Slice Implementation Contract、最小 Skill
5
5
 
6
6
  # YSS Implementation Contract Compiler
7
7
 
8
- 已有生命周期资产优先用 `scripts/contract view <资产> --kind <类型>` 阅读;执行任务用 `--profile task --unit <ID>`,绑定与校验明细用 `--profile full`。视图不授予执行权限,仍按本 Skill 的原始来源和批准门禁处理。类型、准备和迁移见 `docs/process/contract-reading.md`。
8
+ 已有生命周期资产优先用 `scripts/contract view <资产> --kind <类型>` 阅读;执行任务用 `--profile task --unit <ID>`,绑定与校验明细用 `--profile full`。视图不授予执行权限,仍按本 Skill 的原始来源和批准门禁处理。类型、准备和迁移见 `.template-spec/process/contract-reading.md`。
9
9
 
10
10
  阶段 7 的实现合同编译器。它把已批准的生命周期资产、垂直切片、capability 和窄 Recipe 编译为 `Slice Implementation Contract` v3 草案;不批准合同、不写业务代码、不设置 `ready-for-agent`。
11
11
 
12
- 文档输出时按 `lifecycle-document-output` 条件调用 `i-have-adhd`,读取 `docs/process/document-writing.md`;作用域仅限当前产物,派发时传递条件及引用。
12
+ 文档输出时按 `lifecycle-document-output` 条件调用 `i-have-adhd`,读取 `.template-spec/process/document-writing.md`;作用域仅限当前产物,派发时传递条件及引用。
13
13
 
14
14
  ## 文档写作
15
15
 
16
- 撰写实现合同的解释正文和切片交接说明前,读取 `docs/process/document-writing.md` 的共用写法及工程契约 / Ticket 指引;不改变结构化合同、批准状态或就绪条件。
16
+ 撰写实现合同的解释正文和切片交接说明前,读取 `.template-spec/process/document-writing.md` 的共用写法及工程契约 / Ticket 指引;不改变结构化合同、批准状态或就绪条件。
17
17
 
18
18
  ## 输入
19
19
 
@@ -22,8 +22,8 @@ description: "编译或重验 YSS Slice Implementation Contract、最小 Skill
22
22
  ## 编译循环
23
23
 
24
24
  1. 判断 frontend/backend/API/data/domain/cross-repo 影响,并按 [compiler-contract.yaml](references/compiler-contract.yaml) 把 impact 映射为入口 capability;逐项填写 backend `component_impacts`。
25
- 2. 按 `docs/process/delivery-preflight.md` 只读检查当前阶段交付前提,再检查工程存在性和核心/长尾 skill 可用性。既有 Java/Maven 工程按 `docs/process/existing-backend-architecture.md` 加载登记、工程基线、独立观测的原始引用与摘要;不伪填生成器或 H2。
26
- 3. 从 `docs/agents/yss-skill-registry.yaml` 选择一个或多个窄 Recipe,合并 `required_capabilities`;Recipe 不得直接引用 skill。
25
+ 2. 按 `.template-spec/process/delivery-preflight.md` 只读检查当前阶段交付前提,再检查工程存在性和核心/长尾 skill 可用性。既有 Java/Maven 工程按 `.template-spec/process/existing-backend-architecture.md` 加载登记、工程基线、独立观测的原始引用与摘要;不伪填生成器或 H2。
26
+ 3. 从 `.template-spec/agents/yss-skill-registry.yaml` 选择一个或多个窄 Recipe,合并 `required_capabilities`;Recipe 不得直接引用 skill。
27
27
  4. 由 capability 解析入口 skill,只递归 `context-required`;`context-conditional` 仅在显式 condition 命中时加载,其他依赖类型只进入原因链,不扩张执行上下文。
28
28
  5. 按“Recipe 声明顺序 → 依赖拓扑 → skill ID”确定性排序,去重 skill 并保留全部原因;冻结 Registry 与编译器合同 SHA-256。
29
29
  6. 为切片生成基线合同;为当前行为生成工作单元增量路由。
@@ -32,11 +32,11 @@ description: "编译或重验 YSS Slice Implementation Contract、最小 Skill
32
32
 
33
33
  完整草案使用 `scripts/slice-contract prepare` 或 `prepareSliceImplementationContract` 从已有 Ticket / checkpoint 和必要细化组装;执行前读取唯一 YAML,视图和检查报告不授予权限。
34
34
 
35
- 合同结构见 [slice-implementation-contract.md](references/slice-implementation-contract.md),专项返回协议见 [yss-skill-execution-result.md](references/yss-skill-execution-result.md)。前端、后端和测试子任务必须由生命周期主控从批准的 Slice Contract 编译任务包;任务包 schema 为 `docs/process/schemas/subagent-task-package.schema.json`,技能列表必须来自 `taskPackageDefaults`,不能由编译器或执行 Agent 另行手写。
35
+ 合同结构见 [slice-implementation-contract.md](references/slice-implementation-contract.md),专项返回协议见 [yss-skill-execution-result.md](references/yss-skill-execution-result.md)。前端、后端和测试子任务必须由生命周期主控从批准的 Slice Contract 编译任务包;任务包 schema 为 `.template-spec/process/schemas/subagent-task-package.schema.json`,技能列表必须来自 `taskPackageDefaults`,不能由编译器或执行 Agent 另行手写。
36
36
 
37
37
  ## 硬规则
38
38
 
39
- 采用专职前端 profile 或显式 `frontend_delivery` 绑定时,先按 `docs/process/frontend-backend-delivery.md` 实际核验战略与后端联合交付。缺任一输入只能诊断和回交;输入通过后准备计划/合同,正式实现、生成和恢复仍须当前批准的 Slice Contract 冻结接收摘要。接口或部署版本漂移时重新接收,不复用旧成功输出。
39
+ 采用专职前端 profile 或显式 `frontend_delivery` 绑定时,先按 `.template-spec/process/frontend-backend-delivery.md` 实际核验战略与后端联合交付。缺任一输入只能诊断和回交;输入通过后准备计划/合同,正式实现、生成和恢复仍须当前批准的 Slice Contract 冻结接收摘要。接口或部署版本漂移时重新接收,不复用旧成功输出。
40
40
 
41
41
  - 编译器不得输出 `approved`、`ready-for-agent` 或 `completed`。
42
42
  - Registry 和编译规则保持 schema v2;新 Slice 使用 v3,v2 按原规则读取和显式迁移。schema v1 一律拒绝,不自动升级,不提供旧技能名兼容。
@@ -49,7 +49,7 @@ description: "编译或重验 YSS Slice Implementation Contract、最小 Skill
49
49
  - Harness 内实现路径必须落在 `apps/backend/<project>/` 或 `apps/frontend/<project>/` 的具体项目目录;`apps/backend/`、`apps/frontend/` 只能作为容器,`app/backend/`、`app/frontend/` 及其子路径一律阻断。外部实现仓库使用其登记的真实项目根路径。`git-submodule` 使用 `implementation_path_policy: git-submodule-harness-apps`,空 gitlink、detached HEAD 或 `--force` 覆盖挂载点不得脚手架;`inspectWorkingTreeScope.writable` 必须为显式布尔值。
50
50
  - 当前用户、缓存、审计、Excel、分布式 ID、请求校验、错误映射、加解密或网关韧性命中时,必须按 `compiler-contract.yaml` 的 `impact_to_capabilities` 补齐入口 capability;不能只在 `boundaries.md` 中提及。仅复用已经验证的平台认证 / 授权能力不算 component impact,不自动增加权限专项 skill。
51
51
  - 业务行为使用 `behavior-tdd`;只有机械脚手架/生成物可用 `controlled-generation`,并记录例外和验证。
52
- - 阶段 5 若命中交付面且无已有工程,按 Project Scaffold Contract schema v4 编译 `controlled-generation` 合同 draft。后端先读取已通过 `gate.backend-architecture-platform-approved` 的架构与精确 Spring Boot 版本决定,并以原始字节 digest 绑定批准且当前的 Technical Design、Data Architecture Decision v1、API Contract Decision v1 及 `gate.engineering-contract-approved` 真实批准记录;编译器不得自行默认、提问或批准。既有工程核验并复用当前登记架构及固定工程基线/POM 中的实际版本,不重新询问或生成。API `required` 时工程批准还必须直接绑定冻结 OpenAPI YAML 的版本与摘要,`not-applicable` 时必须有影响评估、明确原因和证据。前端绑定标准模板精确 commit、应用标识、路由、OpenAPI 影响、目标路径和 `init_git` 决定。合同经生命周期批准并持久化后才能运行生成器。历史后端 schema v3 只允许 Manifest 只读恢复审计,并须补齐 API 对账,不得新生成;前端只接受 v4。生成与验证完成、仓库登记并通过 `check.implementation-repositories-ready` 后,才编译 Ticket 与业务 Slice Contract。
52
+ - 阶段 5 若命中交付面且无已有工程,按 Project Scaffold Contract schema v4 编译 `controlled-generation` 合同 draft。后端先读取已通过 `gate.backend-architecture-platform-approved` 的架构与精确 Spring Boot 版本决定,并以原始字节 digest 绑定批准且当前的 Technical Design、Data Architecture Decision v1、API Contract Decision(新建 v2;历史 v1 只读兼容,准备与迁移见 `.template-spec/process/contract-reading.md`) 及 `gate.engineering-contract-approved` 真实批准记录;编译器不得自行默认、提问或批准。既有工程核验并复用当前登记架构及固定工程基线/POM 中的实际版本,不重新询问或生成。API `required` 时工程批准还必须直接绑定冻结 OpenAPI YAML 的版本与摘要,`not-applicable` 时必须有影响评估、明确原因和证据。前端绑定标准模板精确 commit、应用标识、路由、OpenAPI 影响、目标路径和 `init_git` 决定。合同经生命周期批准并持久化后才能运行生成器。历史后端 schema v3 只允许 Manifest 只读恢复审计,并须补齐 API 对账,不得新生成;前端只接受 v4。生成与验证完成、仓库登记并通过 `check.implementation-repositories-ready` 后,才编译 Ticket 与业务 Slice Contract。
53
53
  - 脚手架合同在编译阶段只能是 `draft` / `ready-for-lifecycle-review` / `blocked`;只有生命周期编排器可以把已持久化脚手架合同标记为 `approved`。脚手架合同只覆盖业务代码前的工程骨架工作单元;生成、基线校验和合同重编译完成后,它不能替代脚手架后的 Slice Implementation Contract。
54
54
  - 脚手架输出消费批准的脚手架合同;脚手架后的所有生成后端代码都必须绑定当前批准且版本当前的 Slice Implementation Contract、主 YSS skill、依赖闭包、允许写路径、预期证据和 YSS Skill Execution Result。打印命令、`./mvnw validate` 单项通过或脚手架成功不能替代合同批准;生成范围从机械内容变成业务行为时触发完整重路由。
55
55
  - 专项结果中的越界路径、缺失证据、`drift`、`violation` 或 `new_impacts` 必须阻断或重路由。
@@ -72,6 +72,6 @@ description: "编译或重验 YSS Slice Implementation Contract、最小 Skill
72
72
 
73
73
  ## 后端脚手架平台承接
74
74
 
75
- 消费生命周期已确认的架构与 `platform_configuration` v2;不得自行选择、批准或静默升级 Boot/Java。平台清单执行 `scripts/backend-platforms` 查询;只允许已验证 YSS 组合,新生成缺少配置或证据即阻断。决定、合同、Manifest 与下游架构身份须绑定同一平台及兼容摘要。详见 仓库共享合同 `docs/engineering/backend-platforms.md`。
75
+ 消费生命周期已确认的架构与 `platform_configuration` v2;不得自行选择、批准或静默升级 Boot/Java。平台清单执行 `scripts/backend-platforms` 查询;只允许已验证 YSS 组合,新生成缺少配置或证据即阻断。决定、合同、Manifest 与下游架构身份须绑定同一平台及兼容摘要。详见 仓库共享合同 `.template-spec/engineering/backend-platforms.md`。
76
76
 
77
77
  后端 Slice 解析出 `component_binding: required` 的 capability 或其主 Skill 时,必须在同一平台兼容条目中逐项解析 `component_capabilities`。编译结果保存 `component_bindings` 与 `component_bindings_digest`;未登记、未验证、架构证据缺失、构件坐标冲突或摘要漂移均阻断。旧合同含组件 Skill 但没有组件绑定时直接 `stale`,重新编译并交生命周期批准,禁止自动补字段后沿用原批准。
@@ -1,6 +1,6 @@
1
1
  # YSS Skill Boundaries
2
2
 
3
- > Generated by `scripts/generate-yss-skill-boundaries` from `docs/agents/yss-skill-registry.yaml` and `compiler-contract.yaml`. Do not hand-edit.
3
+ > Generated by `scripts/generate-yss-skill-boundaries` from `.template-spec/agents/yss-skill-registry.yaml` and `compiler-contract.yaml`. Do not hand-edit.
4
4
 
5
5
  实现入口先选择 capability 或窄 Recipe,再由实现合同编译器计算最小 skill 闭包。下面是派生阅读视图,不是第二套路由事实源。
6
6