specweave 0.29.2 → 0.30.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (366) hide show
  1. package/README.md +65 -16
  2. package/bin/specweave.js +16 -0
  3. package/dist/plugins/specweave-ado/lib/ado-spec-commit-sync.d.ts +1 -1
  4. package/dist/plugins/specweave-ado/lib/ado-spec-commit-sync.d.ts.map +1 -1
  5. package/dist/plugins/specweave-ado/lib/ado-spec-commit-sync.js +1 -1
  6. package/dist/plugins/specweave-ado/lib/ado-spec-commit-sync.js.map +1 -1
  7. package/dist/plugins/specweave-ado/lib/ado-spec-content-sync.d.ts +1 -1
  8. package/dist/plugins/specweave-ado/lib/ado-spec-content-sync.d.ts.map +1 -1
  9. package/dist/plugins/specweave-ado/lib/ado-spec-content-sync.js +1 -1
  10. package/dist/plugins/specweave-ado/lib/ado-spec-content-sync.js.map +1 -1
  11. package/dist/plugins/specweave-ado/lib/conflict-resolver.d.ts +134 -0
  12. package/dist/plugins/specweave-ado/lib/conflict-resolver.d.ts.map +1 -0
  13. package/dist/plugins/specweave-ado/lib/conflict-resolver.js +423 -0
  14. package/dist/plugins/specweave-ado/lib/conflict-resolver.js.map +1 -0
  15. package/dist/plugins/specweave-github/lib/github-client-v2.d.ts +23 -1
  16. package/dist/plugins/specweave-github/lib/github-client-v2.d.ts.map +1 -1
  17. package/dist/plugins/specweave-github/lib/github-client-v2.js +95 -0
  18. package/dist/plugins/specweave-github/lib/github-client-v2.js.map +1 -1
  19. package/dist/plugins/specweave-github/lib/github-spec-commit-sync.d.ts +1 -1
  20. package/dist/plugins/specweave-github/lib/github-spec-commit-sync.d.ts.map +1 -1
  21. package/dist/plugins/specweave-github/lib/github-spec-commit-sync.js +1 -1
  22. package/dist/plugins/specweave-github/lib/github-spec-commit-sync.js.map +1 -1
  23. package/dist/plugins/specweave-github/lib/github-spec-content-sync.d.ts +1 -1
  24. package/dist/plugins/specweave-github/lib/github-spec-content-sync.d.ts.map +1 -1
  25. package/dist/plugins/specweave-github/lib/github-spec-content-sync.js +1 -1
  26. package/dist/plugins/specweave-github/lib/github-spec-content-sync.js.map +1 -1
  27. package/dist/plugins/specweave-github/lib/types.d.ts +20 -0
  28. package/dist/plugins/specweave-github/lib/types.d.ts.map +1 -1
  29. package/dist/plugins/specweave-jira/lib/jira-spec-commit-sync.d.ts +1 -1
  30. package/dist/plugins/specweave-jira/lib/jira-spec-commit-sync.d.ts.map +1 -1
  31. package/dist/plugins/specweave-jira/lib/jira-spec-commit-sync.js +1 -1
  32. package/dist/plugins/specweave-jira/lib/jira-spec-commit-sync.js.map +1 -1
  33. package/dist/plugins/specweave-jira/lib/jira-spec-content-sync.d.ts +1 -1
  34. package/dist/plugins/specweave-jira/lib/jira-spec-content-sync.d.ts.map +1 -1
  35. package/dist/plugins/specweave-jira/lib/jira-spec-content-sync.js +1 -1
  36. package/dist/plugins/specweave-jira/lib/jira-spec-content-sync.js.map +1 -1
  37. package/dist/plugins/specweave-jira/lib/setup-wizard.d.ts +2 -2
  38. package/dist/plugins/specweave-jira/lib/setup-wizard.d.ts.map +1 -1
  39. package/dist/plugins/specweave-jira/lib/setup-wizard.js +1 -1
  40. package/dist/plugins/specweave-jira/lib/setup-wizard.js.map +1 -1
  41. package/dist/src/adapters/claude/adapter.js +1 -1
  42. package/dist/src/adapters/claude/adapter.js.map +1 -1
  43. package/dist/src/cli/commands/detect-project.js +1 -1
  44. package/dist/src/cli/commands/detect-project.js.map +1 -1
  45. package/dist/src/cli/commands/detect-specs.js +1 -1
  46. package/dist/src/cli/commands/detect-specs.js.map +1 -1
  47. package/dist/src/cli/commands/import-docs.js +1 -1
  48. package/dist/src/cli/commands/import-docs.js.map +1 -1
  49. package/dist/src/cli/commands/init-multiproject.js +1 -1
  50. package/dist/src/cli/commands/init-multiproject.js.map +1 -1
  51. package/dist/src/cli/commands/init.d.ts.map +1 -1
  52. package/dist/src/cli/commands/init.js +31 -1
  53. package/dist/src/cli/commands/init.js.map +1 -1
  54. package/dist/src/cli/commands/jobs.js +15 -1
  55. package/dist/src/cli/commands/jobs.js.map +1 -1
  56. package/dist/src/cli/commands/migrate-to-multiproject.js +1 -1
  57. package/dist/src/cli/commands/migrate-to-multiproject.js.map +1 -1
  58. package/dist/src/cli/commands/switch-project.js +1 -1
  59. package/dist/src/cli/commands/switch-project.js.map +1 -1
  60. package/dist/src/cli/commands/sync-scheduled.d.ts +38 -0
  61. package/dist/src/cli/commands/sync-scheduled.d.ts.map +1 -0
  62. package/dist/src/cli/commands/sync-scheduled.js +170 -0
  63. package/dist/src/cli/commands/sync-scheduled.js.map +1 -0
  64. package/dist/src/cli/helpers/init/external-import-grouping.d.ts +53 -0
  65. package/dist/src/cli/helpers/init/external-import-grouping.d.ts.map +1 -0
  66. package/dist/src/cli/helpers/init/external-import-grouping.js +287 -0
  67. package/dist/src/cli/helpers/init/external-import-grouping.js.map +1 -0
  68. package/dist/src/cli/helpers/init/external-import.d.ts +1 -34
  69. package/dist/src/cli/helpers/init/external-import.d.ts.map +1 -1
  70. package/dist/src/cli/helpers/init/external-import.js +15 -486
  71. package/dist/src/cli/helpers/init/external-import.js.map +1 -1
  72. package/dist/src/cli/helpers/init/living-docs-preflight.d.ts +58 -0
  73. package/dist/src/cli/helpers/init/living-docs-preflight.d.ts.map +1 -0
  74. package/dist/src/cli/helpers/init/living-docs-preflight.js +290 -0
  75. package/dist/src/cli/helpers/init/living-docs-preflight.js.map +1 -0
  76. package/dist/src/cli/helpers/init/sync-profile-helpers.d.ts +48 -0
  77. package/dist/src/cli/helpers/init/sync-profile-helpers.d.ts.map +1 -0
  78. package/dist/src/cli/helpers/init/sync-profile-helpers.js +238 -0
  79. package/dist/src/cli/helpers/init/sync-profile-helpers.js.map +1 -0
  80. package/dist/src/cli/helpers/init/types.d.ts +1 -0
  81. package/dist/src/cli/helpers/init/types.d.ts.map +1 -1
  82. package/dist/src/cli/helpers/issue-tracker/ado.d.ts.map +1 -1
  83. package/dist/src/cli/helpers/issue-tracker/ado.js +113 -3
  84. package/dist/src/cli/helpers/issue-tracker/ado.js.map +1 -1
  85. package/dist/src/cli/helpers/issue-tracker/index.d.ts.map +1 -1
  86. package/dist/src/cli/helpers/issue-tracker/index.js +2 -287
  87. package/dist/src/cli/helpers/issue-tracker/index.js.map +1 -1
  88. package/dist/src/cli/helpers/issue-tracker/sync-config-writer.d.ts +25 -0
  89. package/dist/src/cli/helpers/issue-tracker/sync-config-writer.d.ts.map +1 -0
  90. package/dist/src/cli/helpers/issue-tracker/sync-config-writer.js +306 -0
  91. package/dist/src/cli/helpers/issue-tracker/sync-config-writer.js.map +1 -0
  92. package/dist/src/cli/helpers/issue-tracker/types.d.ts +27 -0
  93. package/dist/src/cli/helpers/issue-tracker/types.d.ts.map +1 -1
  94. package/dist/src/cli/helpers/issue-tracker/types.js.map +1 -1
  95. package/dist/src/cli/workers/living-docs-worker.d.ts +16 -0
  96. package/dist/src/cli/workers/living-docs-worker.d.ts.map +1 -0
  97. package/dist/src/cli/workers/living-docs-worker.js +395 -0
  98. package/dist/src/cli/workers/living-docs-worker.js.map +1 -0
  99. package/dist/src/core/background/job-dependency.d.ts +45 -0
  100. package/dist/src/core/background/job-dependency.d.ts.map +1 -0
  101. package/dist/src/core/background/job-dependency.js +144 -0
  102. package/dist/src/core/background/job-dependency.js.map +1 -0
  103. package/dist/src/core/background/job-launcher.d.ts +21 -1
  104. package/dist/src/core/background/job-launcher.d.ts.map +1 -1
  105. package/dist/src/core/background/job-launcher.js +93 -0
  106. package/dist/src/core/background/job-launcher.js.map +1 -1
  107. package/dist/src/core/background/types.d.ts +73 -2
  108. package/dist/src/core/background/types.d.ts.map +1 -1
  109. package/dist/src/core/brownfield/importer.js +1 -1
  110. package/dist/src/core/brownfield/importer.js.map +1 -1
  111. package/dist/src/core/comment-builder.d.ts +1 -1
  112. package/dist/src/core/comment-builder.d.ts.map +1 -1
  113. package/dist/src/core/{cost-tracker.d.ts → cost/cost-tracker.d.ts} +2 -2
  114. package/dist/src/core/cost/cost-tracker.d.ts.map +1 -0
  115. package/dist/src/core/{cost-tracker.js → cost/cost-tracker.js} +2 -2
  116. package/dist/src/core/cost/cost-tracker.js.map +1 -0
  117. package/dist/src/core/credentials/credentials-manager.d.ts.map +1 -0
  118. package/dist/src/core/credentials/credentials-manager.js.map +1 -0
  119. package/dist/src/core/increment/discipline-checker.js +1 -1
  120. package/dist/src/core/increment/discipline-checker.js.map +1 -1
  121. package/dist/src/core/increment/increment-archiver.d.ts +9 -8
  122. package/dist/src/core/increment/increment-archiver.d.ts.map +1 -1
  123. package/dist/src/core/increment/increment-archiver.js +40 -42
  124. package/dist/src/core/increment/increment-archiver.js.map +1 -1
  125. package/dist/src/core/increment/increment-status.d.ts.map +1 -0
  126. package/dist/src/core/{increment-status.js → increment/increment-status.js} +1 -1
  127. package/dist/src/core/increment/increment-status.js.map +1 -0
  128. package/dist/src/core/increment/increment-utils.d.ts.map +1 -0
  129. package/dist/src/core/increment/increment-utils.js.map +1 -0
  130. package/dist/src/core/increment/metadata-validator.js +1 -1
  131. package/dist/src/core/increment/metadata-validator.js.map +1 -1
  132. package/dist/src/core/living-docs/checkpoint-manager.d.ts +120 -0
  133. package/dist/src/core/living-docs/checkpoint-manager.d.ts.map +1 -0
  134. package/dist/src/core/living-docs/checkpoint-manager.js +231 -0
  135. package/dist/src/core/living-docs/checkpoint-manager.js.map +1 -0
  136. package/dist/src/core/living-docs/discovery.d.ts +91 -0
  137. package/dist/src/core/living-docs/discovery.d.ts.map +1 -0
  138. package/dist/src/core/living-docs/discovery.js +656 -0
  139. package/dist/src/core/living-docs/discovery.js.map +1 -0
  140. package/dist/src/core/living-docs/feature-archiver.d.ts +23 -4
  141. package/dist/src/core/living-docs/feature-archiver.d.ts.map +1 -1
  142. package/dist/src/core/living-docs/feature-archiver.js +133 -30
  143. package/dist/src/core/living-docs/feature-archiver.js.map +1 -1
  144. package/dist/src/core/living-docs/foundation-builder.d.ts +37 -0
  145. package/dist/src/core/living-docs/foundation-builder.d.ts.map +1 -0
  146. package/dist/src/core/living-docs/foundation-builder.js +357 -0
  147. package/dist/src/core/living-docs/foundation-builder.js.map +1 -0
  148. package/dist/src/core/living-docs/living-docs-sync.d.ts +58 -0
  149. package/dist/src/core/living-docs/living-docs-sync.d.ts.map +1 -1
  150. package/dist/src/core/living-docs/living-docs-sync.js +204 -7
  151. package/dist/src/core/living-docs/living-docs-sync.js.map +1 -1
  152. package/dist/src/core/living-docs/module-analyzer.d.ts +97 -0
  153. package/dist/src/core/living-docs/module-analyzer.d.ts.map +1 -0
  154. package/dist/src/core/living-docs/module-analyzer.js +427 -0
  155. package/dist/src/core/living-docs/module-analyzer.js.map +1 -0
  156. package/dist/src/core/living-docs/suggestions-generator.d.ts +112 -0
  157. package/dist/src/core/living-docs/suggestions-generator.d.ts.map +1 -0
  158. package/dist/src/core/living-docs/suggestions-generator.js +362 -0
  159. package/dist/src/core/living-docs/suggestions-generator.js.map +1 -0
  160. package/dist/src/core/living-docs/workitem-matcher.d.ts +116 -0
  161. package/dist/src/core/living-docs/workitem-matcher.d.ts.map +1 -0
  162. package/dist/src/core/living-docs/workitem-matcher.js +356 -0
  163. package/dist/src/core/living-docs/workitem-matcher.js.map +1 -0
  164. package/dist/src/core/{plugin-loader.d.ts → plugins/plugin-loader.d.ts} +1 -1
  165. package/dist/src/core/plugins/plugin-loader.d.ts.map +1 -0
  166. package/dist/src/core/{plugin-loader.js → plugins/plugin-loader.js} +2 -2
  167. package/dist/src/core/plugins/plugin-loader.js.map +1 -0
  168. package/dist/src/core/{project-manager.d.ts → project/project-manager.d.ts} +1 -1
  169. package/dist/src/core/project/project-manager.d.ts.map +1 -0
  170. package/dist/src/core/{project-manager.js → project/project-manager.js} +3 -3
  171. package/dist/src/core/project/project-manager.js.map +1 -0
  172. package/dist/src/core/project/project-structure-detector.d.ts.map +1 -0
  173. package/dist/src/core/project/project-structure-detector.js.map +1 -0
  174. package/dist/src/core/{rfc-generator-v2.d.ts → rfc/rfc-generator-v2.d.ts} +1 -1
  175. package/dist/src/core/rfc/rfc-generator-v2.d.ts.map +1 -0
  176. package/dist/src/core/{rfc-generator-v2.js → rfc/rfc-generator-v2.js} +1 -1
  177. package/dist/src/core/rfc/rfc-generator-v2.js.map +1 -0
  178. package/dist/src/core/scheduler/index.d.ts +1 -0
  179. package/dist/src/core/scheduler/index.d.ts.map +1 -1
  180. package/dist/src/core/scheduler/index.js +1 -0
  181. package/dist/src/core/scheduler/index.js.map +1 -1
  182. package/dist/src/core/scheduler/scheduled-job.d.ts +1 -1
  183. package/dist/src/core/scheduler/scheduled-job.d.ts.map +1 -1
  184. package/dist/src/core/scheduler/scheduled-job.js.map +1 -1
  185. package/dist/src/core/scheduler/session-sync-executor.d.ts +138 -0
  186. package/dist/src/core/scheduler/session-sync-executor.d.ts.map +1 -0
  187. package/dist/src/core/scheduler/session-sync-executor.js +333 -0
  188. package/dist/src/core/scheduler/session-sync-executor.js.map +1 -0
  189. package/dist/src/core/{spec-content-sync.d.ts → specs/spec-content-sync.d.ts} +2 -2
  190. package/dist/src/core/specs/spec-content-sync.d.ts.map +1 -0
  191. package/dist/src/core/{spec-content-sync.js → specs/spec-content-sync.js} +1 -1
  192. package/dist/src/core/specs/spec-content-sync.js.map +1 -0
  193. package/dist/src/core/{spec-detector.d.ts → specs/spec-detector.d.ts} +1 -1
  194. package/dist/src/core/specs/spec-detector.d.ts.map +1 -0
  195. package/dist/src/core/{spec-detector.js → specs/spec-detector.js} +1 -1
  196. package/dist/src/core/specs/spec-detector.js.map +1 -0
  197. package/dist/src/core/{spec-identifier-detector.d.ts → specs/spec-identifier-detector.d.ts} +2 -2
  198. package/dist/src/core/specs/spec-identifier-detector.d.ts.map +1 -0
  199. package/dist/src/core/{spec-identifier-detector.js → specs/spec-identifier-detector.js} +1 -1
  200. package/dist/src/core/specs/spec-identifier-detector.js.map +1 -0
  201. package/dist/src/core/specs/spec-metadata-manager.js +1 -1
  202. package/dist/src/core/specs/spec-metadata-manager.js.map +1 -1
  203. package/dist/src/core/specs/spec-task-mapper.d.ts.map +1 -0
  204. package/dist/src/core/specs/spec-task-mapper.js.map +1 -0
  205. package/dist/src/core/sync/sync-audit-logger.d.ts +62 -0
  206. package/dist/src/core/sync/sync-audit-logger.d.ts.map +1 -1
  207. package/dist/src/core/sync/sync-audit-logger.js +59 -0
  208. package/dist/src/core/sync/sync-audit-logger.js.map +1 -1
  209. package/dist/src/importers/item-converter.d.ts +51 -27
  210. package/dist/src/importers/item-converter.d.ts.map +1 -1
  211. package/dist/src/importers/item-converter.js +219 -179
  212. package/dist/src/importers/item-converter.js.map +1 -1
  213. package/dist/src/importers/markdown-generator.d.ts +75 -0
  214. package/dist/src/importers/markdown-generator.d.ts.map +1 -0
  215. package/dist/src/importers/markdown-generator.js +250 -0
  216. package/dist/src/importers/markdown-generator.js.map +1 -0
  217. package/dist/src/integrations/ado/ado-client.d.ts +93 -0
  218. package/dist/src/integrations/ado/ado-client.d.ts.map +1 -1
  219. package/dist/src/integrations/ado/ado-client.js +172 -1
  220. package/dist/src/integrations/ado/ado-client.js.map +1 -1
  221. package/dist/src/integrations/jira/jira-client.d.ts +44 -0
  222. package/dist/src/integrations/jira/jira-client.d.ts.map +1 -1
  223. package/dist/src/integrations/jira/jira-client.js +119 -1
  224. package/dist/src/integrations/jira/jira-client.js.map +1 -1
  225. package/dist/src/integrations/jira/jira-incremental-mapper.js +2 -2
  226. package/dist/src/integrations/jira/jira-incremental-mapper.js.map +1 -1
  227. package/dist/src/integrations/jira/jira-mapper.js +1 -1
  228. package/dist/src/integrations/jira/jira-mapper.js.map +1 -1
  229. package/dist/src/living-docs/epic-id-allocator.d.ts +177 -0
  230. package/dist/src/living-docs/epic-id-allocator.d.ts.map +1 -0
  231. package/dist/src/living-docs/epic-id-allocator.js +363 -0
  232. package/dist/src/living-docs/epic-id-allocator.js.map +1 -0
  233. package/dist/src/sync/external-change-puller.d.ts +94 -0
  234. package/dist/src/sync/external-change-puller.d.ts.map +1 -0
  235. package/dist/src/sync/external-change-puller.js +181 -0
  236. package/dist/src/sync/external-change-puller.js.map +1 -0
  237. package/dist/src/sync/index.d.ts +4 -0
  238. package/dist/src/sync/index.d.ts.map +1 -1
  239. package/dist/src/sync/index.js +2 -0
  240. package/dist/src/sync/index.js.map +1 -1
  241. package/dist/src/sync/living-docs-updater.d.ts +93 -0
  242. package/dist/src/sync/living-docs-updater.d.ts.map +1 -0
  243. package/dist/src/sync/living-docs-updater.js +218 -0
  244. package/dist/src/sync/living-docs-updater.js.map +1 -0
  245. package/dist/src/testing/test-generator.js +1 -1
  246. package/dist/src/testing/test-generator.js.map +1 -1
  247. package/dist/src/utils/cost-reporter.d.ts +1 -1
  248. package/dist/src/utils/cost-reporter.d.ts.map +1 -1
  249. package/dist/src/utils/model-selection.js +4 -4
  250. package/dist/src/utils/model-selection.js.map +1 -1
  251. package/dist/src/utils/pricing-constants.d.ts +2 -2
  252. package/dist/src/utils/pricing-constants.js +2 -2
  253. package/package.json +1 -1
  254. package/plugins/specweave/.claude-plugin/plugin.json +1 -28
  255. package/plugins/specweave/agents/code-standards-detective/AGENT.md +3 -3
  256. package/plugins/specweave/agents/infrastructure/AGENT.md +4 -0
  257. package/plugins/specweave/agents/performance/AGENT.md +2 -2
  258. package/plugins/specweave/agents/reflective-reviewer/AGENT.md +3 -3
  259. package/plugins/specweave/agents/translator/AGENT.md +2 -2
  260. package/plugins/specweave/commands/specweave-costs.md +2 -2
  261. package/plugins/specweave/commands/specweave-do.md +2 -2
  262. package/plugins/specweave/hooks/lib/scheduler-startup.sh +59 -8
  263. package/plugins/specweave/skills/code-reviewer/SKILL.md +1 -1
  264. package/plugins/specweave/skills/role-orchestrator/README.md +1 -1
  265. package/plugins/specweave-ado/agents/ado-manager/AGENT.md +8 -2
  266. package/plugins/specweave-ado/agents/ado-multi-project-mapper/AGENT.md +2 -2
  267. package/plugins/specweave-ado/agents/ado-sync-judge/AGENT.md +2 -2
  268. package/plugins/specweave-ado/lib/ado-spec-commit-sync.d.ts +1 -1
  269. package/plugins/specweave-ado/lib/ado-spec-commit-sync.js +1 -1
  270. package/plugins/specweave-ado/lib/ado-spec-commit-sync.ts +1 -1
  271. package/plugins/specweave-ado/lib/ado-spec-content-sync.js +1 -1
  272. package/plugins/specweave-ado/lib/ado-spec-content-sync.ts +1 -1
  273. package/plugins/specweave-ado/lib/conflict-resolver.js +87 -0
  274. package/plugins/specweave-ado/lib/conflict-resolver.ts +124 -0
  275. package/plugins/specweave-ado/skills/specweave-ado-mapper/SKILL.md +1 -1
  276. package/plugins/specweave-backend/agents/database-optimizer/AGENT.md +3 -3
  277. package/plugins/specweave-backend/skills/dotnet-backend/SKILL.md +1 -1
  278. package/plugins/specweave-backend/skills/nodejs-backend/SKILL.md +1 -1
  279. package/plugins/specweave-backend/skills/python-backend/SKILL.md +1 -1
  280. package/plugins/specweave-confluent/agents/confluent-architect/AGENT.md +6 -1
  281. package/plugins/specweave-diagrams/agents/diagrams-architect/AGENT.md +2 -2
  282. package/plugins/specweave-diagrams/skills/diagrams-architect/SKILL.md +1 -1
  283. package/plugins/specweave-frontend/agents/frontend-architect/AGENT.md +4 -0
  284. package/plugins/specweave-github/agents/github-manager/AGENT.md +1 -1
  285. package/plugins/specweave-github/agents/github-task-splitter/AGENT.md +11 -1
  286. package/plugins/specweave-github/agents/user-story-updater/AGENT.md +6 -1
  287. package/plugins/specweave-github/hooks/.specweave/logs/hooks-debug.log +90 -0
  288. package/plugins/specweave-github/lib/github-client-v2.js +97 -0
  289. package/plugins/specweave-github/lib/github-client-v2.ts +115 -1
  290. package/plugins/specweave-github/lib/github-spec-commit-sync.d.ts +1 -1
  291. package/plugins/specweave-github/lib/github-spec-commit-sync.js +1 -1
  292. package/plugins/specweave-github/lib/github-spec-commit-sync.ts +1 -1
  293. package/plugins/specweave-github/lib/github-spec-content-sync.js +1 -1
  294. package/plugins/specweave-github/lib/github-spec-content-sync.ts +1 -1
  295. package/plugins/specweave-github/lib/types.ts +21 -0
  296. package/plugins/specweave-infrastructure/agents/devops/AGENT.md +1 -1
  297. package/plugins/specweave-infrastructure/agents/network-engineer/AGENT.md +3 -3
  298. package/plugins/specweave-infrastructure/agents/observability-engineer/AGENT.md +2 -2
  299. package/plugins/specweave-infrastructure/agents/performance-engineer/AGENT.md +3 -3
  300. package/plugins/specweave-infrastructure/agents/sre/AGENT.md +2 -2
  301. package/plugins/specweave-jira/agents/jira-manager/AGENT.md +11 -1
  302. package/plugins/specweave-jira/commands/import-projects.js +1 -1
  303. package/plugins/specweave-jira/commands/import-projects.ts +1 -1
  304. package/plugins/specweave-jira/lib/jira-spec-commit-sync.d.ts +1 -1
  305. package/plugins/specweave-jira/lib/jira-spec-commit-sync.js +1 -1
  306. package/plugins/specweave-jira/lib/jira-spec-commit-sync.ts +1 -1
  307. package/plugins/specweave-jira/lib/jira-spec-content-sync.js +1 -1
  308. package/plugins/specweave-jira/lib/jira-spec-content-sync.ts +1 -1
  309. package/plugins/specweave-jira/lib/setup-wizard.js +2 -2
  310. package/plugins/specweave-jira/lib/setup-wizard.ts +2 -2
  311. package/plugins/specweave-jira/skills/specweave-jira-mapper/SKILL.md +1 -1
  312. package/plugins/specweave-kafka/agents/kafka-architect/AGENT.md +5 -1
  313. package/plugins/specweave-kafka/agents/kafka-devops/AGENT.md +6 -1
  314. package/plugins/specweave-kafka/agents/kafka-observability/AGENT.md +6 -1
  315. package/plugins/specweave-kubernetes/agents/kubernetes-architect/AGENT.md +3 -3
  316. package/plugins/specweave-ml/agents/data-scientist/AGENT.md +2 -1
  317. package/plugins/specweave-ml/agents/ml-engineer/AGENT.md +2 -1
  318. package/plugins/specweave-ml/agents/mlops-engineer/AGENT.md +3 -3
  319. package/plugins/specweave-mobile/agents/mobile-architect/AGENT.md +6 -1
  320. package/plugins/specweave-payments/agents/payment-integration/AGENT.md +3 -3
  321. package/plugins/specweave-release/agents/release-manager/AGENT.md +6 -1
  322. package/plugins/specweave-release/commands/specweave-release-npm.md +8 -0
  323. package/plugins/specweave-release/hooks/.specweave/logs/dora-tracking.log +135 -0
  324. package/plugins/specweave-testing/agents/qa-engineer/AGENT.md +5 -0
  325. package/src/templates/AGENTS.md.template +97 -0
  326. package/dist/src/core/cost-tracker.d.ts.map +0 -1
  327. package/dist/src/core/cost-tracker.js.map +0 -1
  328. package/dist/src/core/credentials-manager.d.ts.map +0 -1
  329. package/dist/src/core/credentials-manager.js.map +0 -1
  330. package/dist/src/core/increment-status.d.ts.map +0 -1
  331. package/dist/src/core/increment-status.js.map +0 -1
  332. package/dist/src/core/increment-utils.d.ts.map +0 -1
  333. package/dist/src/core/increment-utils.js.map +0 -1
  334. package/dist/src/core/plugin-loader.d.ts.map +0 -1
  335. package/dist/src/core/plugin-loader.js.map +0 -1
  336. package/dist/src/core/project-manager.d.ts.map +0 -1
  337. package/dist/src/core/project-manager.js.map +0 -1
  338. package/dist/src/core/project-structure-detector.d.ts.map +0 -1
  339. package/dist/src/core/project-structure-detector.js.map +0 -1
  340. package/dist/src/core/rfc-generator-v2.d.ts.map +0 -1
  341. package/dist/src/core/rfc-generator-v2.js.map +0 -1
  342. package/dist/src/core/spec-content-sync.d.ts.map +0 -1
  343. package/dist/src/core/spec-content-sync.js.map +0 -1
  344. package/dist/src/core/spec-detector.d.ts.map +0 -1
  345. package/dist/src/core/spec-detector.js.map +0 -1
  346. package/dist/src/core/spec-identifier-detector.d.ts.map +0 -1
  347. package/dist/src/core/spec-identifier-detector.js.map +0 -1
  348. package/dist/src/core/spec-task-mapper.d.ts.map +0 -1
  349. package/dist/src/core/spec-task-mapper.js.map +0 -1
  350. package/dist/src/utils/spec-parser.d.ts +0 -145
  351. package/dist/src/utils/spec-parser.d.ts.map +0 -1
  352. package/dist/src/utils/spec-parser.js +0 -640
  353. package/dist/src/utils/spec-parser.js.map +0 -1
  354. package/plugins/specweave/agents/pm/AGENT.md.bak2 +0 -1754
  355. package/plugins/specweave/hooks/hooks.json.bak +0 -72
  356. package/plugins/specweave/hooks/hooks.json.v1-backup +0 -16
  357. package/plugins/specweave/hooks/v2/hooks.json +0 -16
  358. /package/dist/src/core/{credentials-manager.d.ts → credentials/credentials-manager.d.ts} +0 -0
  359. /package/dist/src/core/{credentials-manager.js → credentials/credentials-manager.js} +0 -0
  360. /package/dist/src/core/{increment-status.d.ts → increment/increment-status.d.ts} +0 -0
  361. /package/dist/src/core/{increment-utils.d.ts → increment/increment-utils.d.ts} +0 -0
  362. /package/dist/src/core/{increment-utils.js → increment/increment-utils.js} +0 -0
  363. /package/dist/src/core/{project-structure-detector.d.ts → project/project-structure-detector.d.ts} +0 -0
  364. /package/dist/src/core/{project-structure-detector.js → project/project-structure-detector.js} +0 -0
  365. /package/dist/src/core/{spec-task-mapper.d.ts → specs/spec-task-mapper.d.ts} +0 -0
  366. /package/dist/src/core/{spec-task-mapper.js → specs/spec-task-mapper.js} +0 -0
@@ -31,7 +31,7 @@ Display a comprehensive cost dashboard showing:
31
31
  ### 2. Load Cost Data
32
32
 
33
33
  ```typescript
34
- import { CostTracker } from '../core/cost-tracker';
34
+ import { CostTracker } from '../core/cost/cost-tracker';
35
35
  import { CostReporter } from '../utils/cost-reporter';
36
36
  import fs from 'fs-extra';
37
37
  import path from 'path';
@@ -169,7 +169,7 @@ COST BY AGENT
169
169
  RECENT SESSIONS
170
170
  ───────────────────────────────────────────────────────────────
171
171
  2025-10-31 14:32:15
172
- Agent: pm Model: sonnet
172
+ Agent: pm Model: opus
173
173
  Cost: $ 0.0150 Savings: $ 0.0350
174
174
 
175
175
  2025-10-31 13:15:42
@@ -32,8 +32,8 @@ You are helping the user implement a SpecWeave increment by executing tasks from
32
32
 
33
33
  - `--model <tier>`: Optional. Override model selection for all tasks
34
34
  - `haiku`: Fast, cheap execution (3x faster, 20x cheaper than Sonnet)
35
- - `sonnet`: Balanced quality and speed (default for complex tasks)
36
- - `opus`: Maximum quality (rare, use only for critical decisions)
35
+ - `sonnet`: Balanced quality and speed
36
+ - `opus`: Maximum quality (default for all tasks)
37
37
  - If omitted, uses model hints from tasks.md (recommended)
38
38
 
39
39
  ---
@@ -1,7 +1,14 @@
1
1
  #!/bin/bash
2
- # scheduler-startup.sh - Check for due jobs on session start
3
- # Called from session-start hook to initialize scheduler
4
- set -e
2
+ # scheduler-startup.sh - Execute due sync jobs on session start
3
+ # Called from session-start hook to run overdue scheduled jobs
4
+ #
5
+ # This implements the "pragmatic hybrid" approach:
6
+ # - No background daemon required
7
+ # - Sync runs at Claude Code session boundaries
8
+ # - Respects permission gates (canUpdateExternalItems, etc.)
9
+ #
10
+ # CRITICAL (v0.28.70): NEVER use 'set -e' in hooks - causes Claude Code crashes
11
+ set +e
5
12
 
6
13
  # Skip if hooks disabled
7
14
  [[ "${SPECWEAVE_DISABLE_HOOKS:-0}" == "1" ]] && exit 0
@@ -18,11 +25,14 @@ done
18
25
  # Paths
19
26
  SCHEDULED_JOBS_FILE="$PROJECT_ROOT/.specweave/state/scheduled-jobs.json"
20
27
  CONFIG_FILE="$PROJECT_ROOT/.specweave/config.json"
28
+ LOG_FILE="$PROJECT_ROOT/.specweave/logs/scheduler.log"
29
+
30
+ # Ensure logs directory exists
31
+ mkdir -p "$PROJECT_ROOT/.specweave/logs" 2>/dev/null || true
21
32
 
22
33
  # Check if scheduler is enabled
23
34
  if [[ -f "$CONFIG_FILE" ]]; then
24
35
  # Check if sync.orchestration.scheduler.enabled is true
25
- # Use node for reliable JSON parsing
26
36
  SCHEDULER_ENABLED=$(node -e "
27
37
  try {
28
38
  const config = require('$CONFIG_FILE');
@@ -36,6 +46,21 @@ if [[ -f "$CONFIG_FILE" ]]; then
36
46
  if [[ "$SCHEDULER_ENABLED" != "true" ]]; then
37
47
  exit 0
38
48
  fi
49
+
50
+ # Check autoSyncOnSessionStart (defaults to true)
51
+ AUTO_SYNC=$(node -e "
52
+ try {
53
+ const config = require('$CONFIG_FILE');
54
+ const auto = config?.sync?.orchestration?.scheduler?.autoSyncOnSessionStart ?? true;
55
+ console.log(auto ? 'true' : 'false');
56
+ } catch(e) {
57
+ console.log('true');
58
+ }
59
+ " 2>/dev/null || echo "true")
60
+
61
+ if [[ "$AUTO_SYNC" != "true" ]]; then
62
+ exit 0
63
+ fi
39
64
  fi
40
65
 
41
66
  # Check if scheduled jobs file exists
@@ -65,8 +90,34 @@ if [[ "$DUE_JOBS" == "[]" ]]; then
65
90
  exit 0
66
91
  fi
67
92
 
68
- # Log due jobs (for debugging)
69
- echo "📅 Due sync jobs: $DUE_JOBS" >> "$PROJECT_ROOT/.specweave/logs/scheduler.log" 2>/dev/null || true
93
+ # Log due jobs
94
+ TIMESTAMP=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
95
+ echo "[$TIMESTAMP] Session start - due jobs: $DUE_JOBS" >> "$LOG_FILE" 2>/dev/null || true
96
+
97
+ # Execute due sync jobs using the TypeScript executor
98
+ # Run in background to avoid blocking session start
99
+ RESULT=$(node -e "
100
+ const { executeSessionSync } = require('$PROJECT_ROOT/node_modules/specweave/dist/core/scheduler/session-sync-executor.js');
101
+ executeSessionSync('$PROJECT_ROOT', { silent: false })
102
+ .then(r => console.log(r))
103
+ .catch(e => console.log(JSON.stringify({ error: e.message })));
104
+ " 2>&1) || RESULT='{"error":"Executor not found"}'
105
+
106
+ # Log result
107
+ echo "[$TIMESTAMP] Execution result: $RESULT" >> "$LOG_FILE" 2>/dev/null || true
70
108
 
71
- # Output status (will be captured by hook system)
72
- echo "{\"continue\": true, \"systemMessage\": \"📅 Scheduled sync jobs ready to run. Use /specweave:sync-now to execute.\"}"
109
+ # Parse result for system message
110
+ EXECUTED_COUNT=$(echo "$RESULT" | node -e "
111
+ const data = JSON.parse(require('fs').readFileSync('/dev/stdin', 'utf-8'));
112
+ console.log(data.executedCount || 0);
113
+ " 2>/dev/null || echo "0")
114
+
115
+ SUCCESS_COUNT=$(echo "$RESULT" | node -e "
116
+ const data = JSON.parse(require('fs').readFileSync('/dev/stdin', 'utf-8'));
117
+ console.log(data.successCount || 0);
118
+ " 2>/dev/null || echo "0")
119
+
120
+ # Output status message if jobs were executed
121
+ if [[ "$EXECUTED_COUNT" != "0" ]]; then
122
+ echo "{\"continue\": true, \"systemMessage\": \"📅 Session sync: $SUCCESS_COUNT/$EXECUTED_COUNT sync jobs executed successfully.\"}"
123
+ fi
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: code-reviewer
3
3
  description: Code review expert for security vulnerabilities, performance, and best practices. Activates for review code, code review, security review, PR review, pull request review, check my code, code quality, vulnerability scan, OWASP, code analysis, static analysis.
4
- model: claude-sonnet-4-5-20250929
4
+ model: claude-opus-4-5-20251101
5
5
  ---
6
6
 
7
7
  You are an elite code review expert specializing in modern code analysis techniques, AI-powered review tools, and production-grade quality assurance.
@@ -2,7 +2,7 @@
2
2
 
3
3
  **Status**: To be developed
4
4
  **Priority**: CRITICAL (Highest priority)
5
- **Claude Model**: Sonnet (reasoning + efficiency)
5
+ **Claude Model**: Opus 4.5 (best reasoning + quality)
6
6
 
7
7
  ## Purpose
8
8
 
@@ -1,15 +1,21 @@
1
1
  ---
2
2
  name: ado-manager
3
+ description: Azure DevOps integration specialist. Expert in ADO REST API, work item management, and SpecWeave increment synchronization. Handles Epics, Features, User Stories, bidirectional sync, and rate limiting.
3
4
  role: Azure DevOps Integration Specialist
4
5
  context: |
5
6
  You are an expert in Azure DevOps (ADO) REST API integration, work item management, and SpecWeave increment synchronization.
6
-
7
+
7
8
  Your responsibilities:
8
9
  - Create and manage ADO work items (Epics, Features, User Stories)
9
10
  - Sync SpecWeave increment progress to ADO
10
11
  - Handle bidirectional sync (ADO ↔ SpecWeave)
11
12
  - Troubleshoot ADO API issues
12
13
  - Optimize sync performance and rate limiting
14
+ model: claude-opus-4-5-20251101
15
+ model_preference: opus
16
+ cost_profile: execution
17
+ fallback_behavior: flexible
18
+ max_response_tokens: 2000
13
19
  ---
14
20
 
15
21
  ## 🚀 How to Invoke This Agent
@@ -22,7 +28,7 @@ context: |
22
28
  Task({
23
29
  subagent_type: "specweave-ado:ado-manager:ado-manager",
24
30
  prompt: "Your task description here",
25
- model: "haiku" // optional: haiku, sonnet, opus
31
+ model: "opus" // default: opus (best quality)
26
32
  });
27
33
  ```
28
34
 
@@ -2,7 +2,7 @@
2
2
  name: ado-multi-project-mapper
3
3
  description: Expert in mapping SpecWeave specs to multiple Azure DevOps projects with intelligent project detection and cross-project coordination. Handles project-per-team, area-path-based, and team-based strategies. Manages bidirectional sync across multiple projects.
4
4
  tools: Read, Write, Edit, Bash, Glob
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  ## 🚀 How to Invoke This Agent
@@ -15,7 +15,7 @@ model: claude-sonnet-4-5-20250929
15
15
  Task({
16
16
  subagent_type: "specweave-ado:ado-multi-project-mapper:ado-multi-project-mapper",
17
17
  prompt: "Your task description here",
18
- model: "haiku" // optional: haiku, sonnet, opus
18
+ model: "opus" // default: opus (best quality)
19
19
  });
20
20
  ```
21
21
 
@@ -2,7 +2,7 @@
2
2
  name: ado-sync-judge
3
3
  description: LLM Judge for verifying Azure DevOps synchronization correctness, conflict resolution, and lifecycle management. Validates that external tool status wins, increments complete strictly, and specs sync flexibly.
4
4
  tools: Read, Grep, Bash
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  ## 🚀 How to Invoke This Agent
@@ -15,7 +15,7 @@ model: claude-sonnet-4-5-20250929
15
15
  Task({
16
16
  subagent_type: "specweave-ado:ado-sync-judge:ado-sync-judge",
17
17
  prompt: "Your task description here",
18
- model: "haiku" // optional: haiku, sonnet, opus
18
+ model: "opus" // default: opus (best quality)
19
19
  });
20
20
  ```
21
21
 
@@ -6,7 +6,7 @@
6
6
  */
7
7
  import { AdoClientV2 } from './ado-client-v2.js';
8
8
  import { GitCommit, GitRepository } from '../../../src/utils/git-utils.js';
9
- import { UserStory } from '../../../src/core/spec-task-mapper.js';
9
+ import { UserStory } from '../../../src/core/specs/spec-task-mapper.js';
10
10
  export interface SyncOptions {
11
11
  incrementPath: string;
12
12
  dryRun?: boolean;
@@ -9,7 +9,7 @@ import {
9
9
  import {
10
10
  getSpecTaskMapping,
11
11
  getCompletedUserStories
12
- } from "../../../src/core/spec-task-mapper.js";
12
+ } from "../../../src/core/specs/spec-task-mapper.js";
13
13
  import {
14
14
  buildUserStoryComment,
15
15
  buildCommitBatchComment,
@@ -22,7 +22,7 @@ import {
22
22
  getCompletedUserStories,
23
23
  SpecTaskMapping,
24
24
  UserStory,
25
- } from '../../../src/core/spec-task-mapper.js';
25
+ } from '../../../src/core/specs/spec-task-mapper.js';
26
26
  import {
27
27
  buildUserStoryComment,
28
28
  buildCommitBatchComment,
@@ -3,7 +3,7 @@ import {
3
3
  detectContentChanges,
4
4
  hasExternalLink,
5
5
  updateSpecWithExternalLink
6
- } from "../../../src/core/spec-content-sync.js";
6
+ } from "../../../src/core/specs/spec-content-sync.js";
7
7
  import { SpecIncrementMapper } from "../../../src/core/sync/spec-increment-mapper.js";
8
8
  import * as path from "path";
9
9
  import * as fs from "fs/promises";
@@ -18,7 +18,7 @@ import {
18
18
  updateSpecWithExternalLink,
19
19
  SpecContent,
20
20
  ContentSyncResult,
21
- } from '../../../src/core/spec-content-sync.js';
21
+ } from '../../../src/core/specs/spec-content-sync.js';
22
22
  import { SyncProfile } from '../../../src/core/types/sync-profile.js';
23
23
  import { SpecIncrementMapper, TaskInfo } from '../../../src/core/sync/spec-increment-mapper.js';
24
24
  import * as path from 'path';
@@ -97,6 +97,93 @@ class ConflictResolver {
97
97
  this.resolutionLog.push(resolution);
98
98
  return resolution;
99
99
  }
100
+ /**
101
+ * Compare timestamps to determine winner (Increment 0089)
102
+ *
103
+ * For pull sync, we compare local lastModified vs external ChangedDate.
104
+ * The more recent timestamp wins.
105
+ *
106
+ * @param localTimestamp - Local file lastModified timestamp (ISO string or null)
107
+ * @param externalTimestamp - External tool ChangedDate (ISO string)
108
+ * @returns Comparison result with winner and reasoning
109
+ */
110
+ compareTimestamps(localTimestamp, externalTimestamp) {
111
+ const externalDate = new Date(externalTimestamp);
112
+ if (!localTimestamp) {
113
+ return {
114
+ winner: "external",
115
+ localTimestamp: null,
116
+ externalTimestamp,
117
+ timeDiffMs: 0,
118
+ reason: "No local timestamp available, external wins by default"
119
+ };
120
+ }
121
+ const localDate = new Date(localTimestamp);
122
+ const timeDiffMs = externalDate.getTime() - localDate.getTime();
123
+ if (timeDiffMs > 0) {
124
+ console.log(`\u{1F4CA} Timestamp Comparison:`);
125
+ console.log(` Local: ${localTimestamp}`);
126
+ console.log(` External: ${externalTimestamp}`);
127
+ console.log(` \u2705 Winner: EXTERNAL (${Math.round(timeDiffMs / 6e4)}min newer)`);
128
+ return {
129
+ winner: "external",
130
+ localTimestamp,
131
+ externalTimestamp,
132
+ timeDiffMs,
133
+ reason: `External is ${Math.round(timeDiffMs / 6e4)} minutes newer`
134
+ };
135
+ }
136
+ if (timeDiffMs < 0) {
137
+ console.log(`\u{1F4CA} Timestamp Comparison:`);
138
+ console.log(` Local: ${localTimestamp}`);
139
+ console.log(` External: ${externalTimestamp}`);
140
+ console.log(` \u2705 Winner: LOCAL (${Math.round(Math.abs(timeDiffMs) / 6e4)}min newer)`);
141
+ return {
142
+ winner: "local",
143
+ localTimestamp,
144
+ externalTimestamp,
145
+ timeDiffMs,
146
+ reason: `Local is ${Math.round(Math.abs(timeDiffMs) / 6e4)} minutes newer`
147
+ };
148
+ }
149
+ return {
150
+ winner: "none",
151
+ localTimestamp,
152
+ externalTimestamp,
153
+ timeDiffMs: 0,
154
+ reason: "Timestamps are identical, no conflict"
155
+ };
156
+ }
157
+ /**
158
+ * Resolve conflict using timestamp comparison (Increment 0089)
159
+ *
160
+ * Combines timestamp comparison with status conflict resolution.
161
+ * Used by ExternalChangePuller for pull sync.
162
+ *
163
+ * @param field - The field being compared (e.g., 'status')
164
+ * @param localValue - Current local value
165
+ * @param externalValue - Value from external tool
166
+ * @param localTimestamp - Local lastModified timestamp
167
+ * @param externalTimestamp - External ChangedDate
168
+ * @returns Conflict resolution result
169
+ */
170
+ resolveWithTimestamp(field, localValue, externalValue, localTimestamp, externalTimestamp) {
171
+ const comparison = this.compareTimestamps(localTimestamp, externalTimestamp);
172
+ const resolution = {
173
+ field,
174
+ localValue,
175
+ externalValue,
176
+ resolution: comparison.winner === "local" ? "local" : "external",
177
+ resolvedValue: comparison.winner === "local" ? localValue : externalValue,
178
+ reason: comparison.reason,
179
+ timestamp: (/* @__PURE__ */ new Date()).toISOString()
180
+ };
181
+ console.log(`\u{1F4CA} Conflict Resolved (${field}):`);
182
+ console.log(` Winner: ${comparison.winner.toUpperCase()}`);
183
+ console.log(` Reason: ${comparison.reason}`);
184
+ this.resolutionLog.push(resolution);
185
+ return resolution;
186
+ }
100
187
  /**
101
188
  * Resolve priority conflict - EXTERNAL WINS
102
189
  */
@@ -24,6 +24,17 @@ export interface ConflictResolution {
24
24
  timestamp: string;
25
25
  }
26
26
 
27
+ /**
28
+ * Timestamp comparison result for pull sync (Increment 0089)
29
+ */
30
+ export interface TimestampComparisonResult {
31
+ winner: 'local' | 'external' | 'none';
32
+ localTimestamp: string | null;
33
+ externalTimestamp: string;
34
+ timeDiffMs: number;
35
+ reason: string;
36
+ }
37
+
27
38
  export interface SpecMetadata {
28
39
  id: string;
29
40
  title: string;
@@ -183,6 +194,119 @@ export class ConflictResolver {
183
194
  return resolution;
184
195
  }
185
196
 
197
+ /**
198
+ * Compare timestamps to determine winner (Increment 0089)
199
+ *
200
+ * For pull sync, we compare local lastModified vs external ChangedDate.
201
+ * The more recent timestamp wins.
202
+ *
203
+ * @param localTimestamp - Local file lastModified timestamp (ISO string or null)
204
+ * @param externalTimestamp - External tool ChangedDate (ISO string)
205
+ * @returns Comparison result with winner and reasoning
206
+ */
207
+ public compareTimestamps(
208
+ localTimestamp: string | null,
209
+ externalTimestamp: string
210
+ ): TimestampComparisonResult {
211
+ const externalDate = new Date(externalTimestamp);
212
+
213
+ // If no local timestamp, external wins by default
214
+ if (!localTimestamp) {
215
+ return {
216
+ winner: 'external',
217
+ localTimestamp: null,
218
+ externalTimestamp,
219
+ timeDiffMs: 0,
220
+ reason: 'No local timestamp available, external wins by default',
221
+ };
222
+ }
223
+
224
+ const localDate = new Date(localTimestamp);
225
+ const timeDiffMs = externalDate.getTime() - localDate.getTime();
226
+
227
+ // External is more recent → external wins
228
+ if (timeDiffMs > 0) {
229
+ console.log(`📊 Timestamp Comparison:`);
230
+ console.log(` Local: ${localTimestamp}`);
231
+ console.log(` External: ${externalTimestamp}`);
232
+ console.log(` ✅ Winner: EXTERNAL (${Math.round(timeDiffMs / 60000)}min newer)`);
233
+
234
+ return {
235
+ winner: 'external',
236
+ localTimestamp,
237
+ externalTimestamp,
238
+ timeDiffMs,
239
+ reason: `External is ${Math.round(timeDiffMs / 60000)} minutes newer`,
240
+ };
241
+ }
242
+
243
+ // Local is more recent → local wins (don't overwrite local changes)
244
+ if (timeDiffMs < 0) {
245
+ console.log(`📊 Timestamp Comparison:`);
246
+ console.log(` Local: ${localTimestamp}`);
247
+ console.log(` External: ${externalTimestamp}`);
248
+ console.log(` ✅ Winner: LOCAL (${Math.round(Math.abs(timeDiffMs) / 60000)}min newer)`);
249
+
250
+ return {
251
+ winner: 'local',
252
+ localTimestamp,
253
+ externalTimestamp,
254
+ timeDiffMs,
255
+ reason: `Local is ${Math.round(Math.abs(timeDiffMs) / 60000)} minutes newer`,
256
+ };
257
+ }
258
+
259
+ // Same timestamp → no conflict
260
+ return {
261
+ winner: 'none',
262
+ localTimestamp,
263
+ externalTimestamp,
264
+ timeDiffMs: 0,
265
+ reason: 'Timestamps are identical, no conflict',
266
+ };
267
+ }
268
+
269
+ /**
270
+ * Resolve conflict using timestamp comparison (Increment 0089)
271
+ *
272
+ * Combines timestamp comparison with status conflict resolution.
273
+ * Used by ExternalChangePuller for pull sync.
274
+ *
275
+ * @param field - The field being compared (e.g., 'status')
276
+ * @param localValue - Current local value
277
+ * @param externalValue - Value from external tool
278
+ * @param localTimestamp - Local lastModified timestamp
279
+ * @param externalTimestamp - External ChangedDate
280
+ * @returns Conflict resolution result
281
+ */
282
+ public resolveWithTimestamp(
283
+ field: string,
284
+ localValue: any,
285
+ externalValue: any,
286
+ localTimestamp: string | null,
287
+ externalTimestamp: string
288
+ ): ConflictResolution {
289
+ const comparison = this.compareTimestamps(localTimestamp, externalTimestamp);
290
+
291
+ const resolution: ConflictResolution = {
292
+ field,
293
+ localValue,
294
+ externalValue,
295
+ resolution: comparison.winner === 'local' ? 'local' : 'external',
296
+ resolvedValue: comparison.winner === 'local' ? localValue : externalValue,
297
+ reason: comparison.reason,
298
+ timestamp: new Date().toISOString(),
299
+ };
300
+
301
+ // Log the resolution
302
+ console.log(`📊 Conflict Resolved (${field}):`);
303
+ console.log(` Winner: ${comparison.winner.toUpperCase()}`);
304
+ console.log(` Reason: ${comparison.reason}`);
305
+
306
+ this.resolutionLog.push(resolution);
307
+ return resolution;
308
+ }
309
+
186
310
  /**
187
311
  * Resolve priority conflict - EXTERNAL WINS
188
312
  */
@@ -2,7 +2,7 @@
2
2
  name: specweave-ado-mapper
3
3
  description: Expert in bidirectional conversion between SpecWeave increments and Azure DevOps (ADO) Epics/Features/User Stories/Tasks. Handles export (increment → ADO), import (ADO → increment), and bidirectional sync with conflict resolution. Activates for ADO sync, Azure DevOps sync, work item creation, import from ADO.
4
4
  tools: Read, Write, Edit, Bash
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  # Specweave Ado Mapper Skill
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  name: database-optimizer
3
3
  description: Expert database optimizer specializing in modern performance tuning, query optimization, and scalable architectures. Masters advanced indexing, N+1 resolution, multi-tier caching, partitioning strategies, and cloud database optimization. Handles complex query analysis, migration strategies, and performance monitoring. Use PROACTIVELY for database optimization, performance issues, or scalability challenges.
4
- model: claude-haiku-4-5-20251001
5
- model_preference: sonnet
4
+ model: claude-opus-4-5-20251101
5
+ model_preference: opus
6
6
  cost_profile: planning
7
7
  fallback_behavior: strict
8
8
  ---
@@ -17,7 +17,7 @@ fallback_behavior: strict
17
17
  Task({
18
18
  subagent_type: "specweave-backend:database-optimizer:database-optimizer",
19
19
  prompt: "Your task description here",
20
- model: "haiku" // optional: haiku, sonnet, opus
20
+ model: "opus" // default: opus (best quality)
21
21
  });
22
22
  ```
23
23
 
@@ -2,7 +2,7 @@
2
2
  name: dotnet-backend
3
3
  description: .NET/C# backend developer for ASP.NET Core APIs with Entity Framework Core. Builds REST APIs, minimal APIs, gRPC services, authentication with Identity/JWT, authorization, database operations, background services, SignalR real-time features. Activates for: .NET, C#, ASP.NET Core, Entity Framework Core, EF Core, .NET Core, minimal API, Web API, gRPC, authentication .NET, Identity, JWT .NET, authorization, LINQ, async/await C#, background service, IHostedService, SignalR, SQL Server, PostgreSQL .NET, dependency injection, middleware .NET.
4
4
  tools: Read, Write, Edit, Bash
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  # .NET Backend Agent - ASP.NET Core & Enterprise API Expert
@@ -2,7 +2,7 @@
2
2
  name: nodejs-backend
3
3
  description: Node.js/TypeScript backend developer. Builds Express.js, Fastify, NestJS APIs with Prisma ORM, TypeORM, Mongoose. Implements REST APIs, GraphQL, authentication (JWT, session, OAuth), authorization, database operations, background jobs, WebSockets, real-time features, API validation, error handling, middleware. Activates for: Node.js, NodeJS, Express, Fastify, NestJS, TypeScript backend, API, REST API, GraphQL, Prisma, TypeORM, Mongoose, MongoDB, PostgreSQL with Node, MySQL with Node, authentication backend, JWT, passport.js, bcrypt, async/await, promises, middleware, error handling, validation, Zod, class-validator, background jobs, Bull, BullMQ, Redis, WebSocket, Socket.io, real-time.
4
4
  tools: Read, Write, Edit, Bash
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  # Node.js Backend Agent - API & Server Development Expert
@@ -2,7 +2,7 @@
2
2
  name: python-backend
3
3
  description: Python backend developer for FastAPI, Django, Flask APIs with SQLAlchemy, Django ORM, Pydantic validation. Implements REST APIs, async operations, database integration, authentication, data processing with pandas/numpy, machine learning integration, background tasks with Celery, API documentation with OpenAPI/Swagger. Activates for: Python, Python backend, FastAPI, Django, Flask, SQLAlchemy, Django ORM, Pydantic, async Python, asyncio, uvicorn, REST API Python, authentication Python, pandas, numpy, data processing, machine learning, ML API, Celery, Redis Python, PostgreSQL Python, MongoDB Python, type hints, Python typing.
4
4
  tools: Read, Write, Edit, Bash
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  # Python Backend Agent - API & Data Processing Expert
@@ -1,6 +1,11 @@
1
1
  ---
2
2
  name: confluent-architect
3
3
  description: Confluent Cloud architecture specialist. Expert in eCKU sizing, cluster linking, multi-region strategies, Schema Registry HA, ksqlDB deployment, Stream Governance, and cost optimization. Activates for confluent cloud architecture, ecku sizing, cluster linking, multi-region kafka, schema registry ha, stream governance, cost optimization.
4
+ model: claude-opus-4-5-20251101
5
+ model_preference: opus
6
+ cost_profile: planning
7
+ fallback_behavior: strict
8
+ max_response_tokens: 2000
4
9
  ---
5
10
 
6
11
  ## 🚀 How to Invoke This Agent
@@ -13,7 +18,7 @@ description: Confluent Cloud architecture specialist. Expert in eCKU sizing, clu
13
18
  Task({
14
19
  subagent_type: "specweave-confluent:confluent-architect:confluent-architect",
15
20
  prompt: "Your task description here",
16
- model: "haiku" // optional: haiku, sonnet, opus
21
+ model: "opus" // default: opus (best quality)
17
22
  });
18
23
  ```
19
24
 
@@ -2,7 +2,7 @@
2
2
  name: diagrams-architect
3
3
  description: Expert in creating Mermaid diagrams following C4 Model conventions. Generates C4 Context/Container/Component diagrams, sequence diagrams, ER diagrams, and deployment diagrams with correct syntax and placement.
4
4
  tools: Read, Write, Edit
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  model_preference: auto
7
7
  cost_profile: hybrid
8
8
  fallback_behavior: auto
@@ -18,7 +18,7 @@ fallback_behavior: auto
18
18
  Task({
19
19
  subagent_type: "specweave-diagrams:diagrams-architect:diagrams-architect",
20
20
  prompt: "Your task description here",
21
- model: "haiku" // optional: haiku, sonnet, opus
21
+ model: "opus" // default: opus (best quality)
22
22
  });
23
23
  ```
24
24
 
@@ -2,7 +2,7 @@
2
2
  name: diagrams-architect
3
3
  description: Expert in creating Mermaid diagrams following C4 Model and SpecWeave conventions. Specializes in system architecture, sequence diagrams, ER diagrams, and deployment diagrams. Activates for diagram creation, architecture visualization, data modeling, sequence flows, C4 diagrams, HLD, LLD.
4
4
  tools: Read, Write, Edit
5
- model: claude-sonnet-4-5-20250929
5
+ model: claude-opus-4-5-20251101
6
6
  ---
7
7
 
8
8
  # Diagrams Architect Skill
@@ -8,6 +8,10 @@ tools:
8
8
  - Bash
9
9
  - Glob
10
10
  - Grep
11
+ model: claude-opus-4-5-20251101
12
+ model_preference: opus
13
+ cost_profile: planning
14
+ fallback_behavior: strict
11
15
  max_response_tokens: 2000
12
16
  ---
13
17
 
@@ -52,7 +52,7 @@ GitHub issues MUST use living docs format:
52
52
  Task({
53
53
  subagent_type: "specweave-github:github-manager:SpecWeave Sync",
54
54
  prompt: "Your task description here",
55
- model: "haiku" // optional: haiku, sonnet, opus
55
+ model: "opus" // default: opus (best quality)
56
56
  });
57
57
  ```
58
58
 
@@ -1,3 +1,13 @@
1
+ ---
2
+ name: github-task-splitter
3
+ description: Expert agent for splitting SpecWeave tasks across multiple GitHub repositories based on architecture patterns. Analyzes task dependencies across services and creates tracking issues in multiple repositories for multi-repo architectures.
4
+ model: claude-opus-4-5-20251101
5
+ model_preference: opus
6
+ cost_profile: planning
7
+ fallback_behavior: strict
8
+ max_response_tokens: 2000
9
+ ---
10
+
1
11
  # GitHub Task Splitter Agent
2
12
 
3
13
  Expert agent for splitting SpecWeave tasks across multiple GitHub repositories based on architecture patterns.
@@ -12,7 +22,7 @@ Expert agent for splitting SpecWeave tasks across multiple GitHub repositories b
12
22
  Task({
13
23
  subagent_type: "specweave-github:github-task-splitter:github-task-splitter",
14
24
  prompt: "Split tasks for increment 0015-shopping-cart across frontend, backend, and shared repositories",
15
- model: "haiku" // optional: haiku, sonnet, opus
25
+ model: "opus" // default: opus (best quality)
16
26
  });
17
27
  ```
18
28