@jaggerxtrm/specialists 3.7.1 → 3.10.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 (193) hide show
  1. package/README.md +23 -9
  2. package/config/mandatory-rules/README.md +113 -0
  3. package/config/mandatory-rules/gitnexus-required.md +12 -1
  4. package/config/mandatory-rules/serena-cheatsheet.md +41 -0
  5. package/config/skills/specialists-creator/SKILL.md +6 -32
  6. package/config/skills/specialists-creator/scripts/audit-spec-uniformity.mjs +86 -0
  7. package/config/skills/specialists-creator/scripts/scaffold-specialist.ts +1 -6
  8. package/config/skills/update-specialists/SKILL.md +83 -8
  9. package/config/skills/using-specialists/SKILL.md +13 -0
  10. package/config/skills/using-specialists-v2/SKILL.md +639 -0
  11. package/config/specialists/debugger.specialist.json +7 -9
  12. package/config/specialists/executor.specialist.json +5 -6
  13. package/config/specialists/explorer.specialist.json +3 -7
  14. package/config/specialists/memory-processor.specialist.json +8 -9
  15. package/config/specialists/node-coordinator.specialist.json +1 -5
  16. package/config/specialists/overthinker.specialist.json +7 -13
  17. package/config/specialists/planner.specialist.json +12 -12
  18. package/config/specialists/researcher.specialist.json +9 -14
  19. package/config/specialists/reviewer.specialist.json +8 -8
  20. package/config/specialists/specialists-creator.specialist.json +7 -2
  21. package/config/specialists/sync-docs.specialist.json +7 -11
  22. package/config/specialists/test-runner.specialist.json +4 -13
  23. package/config/specialists/xt-merge.specialist.json +3 -5
  24. package/dist/index.js +3066 -1368
  25. package/dist/lib.js +13219 -0
  26. package/dist/types/cli/attach.d.ts +2 -0
  27. package/dist/types/cli/attach.d.ts.map +1 -0
  28. package/dist/types/cli/clean.d.ts +2 -0
  29. package/dist/types/cli/clean.d.ts.map +1 -0
  30. package/dist/types/cli/config.d.ts +2 -0
  31. package/dist/types/cli/config.d.ts.map +1 -0
  32. package/dist/types/cli/db.d.ts +2 -0
  33. package/dist/types/cli/db.d.ts.map +1 -0
  34. package/dist/types/cli/doctor.d.ts +15 -0
  35. package/dist/types/cli/doctor.d.ts.map +1 -0
  36. package/dist/types/cli/edit.d.ts +2 -0
  37. package/dist/types/cli/edit.d.ts.map +1 -0
  38. package/dist/types/cli/end.d.ts +2 -0
  39. package/dist/types/cli/end.d.ts.map +1 -0
  40. package/dist/types/cli/epic.d.ts +8 -0
  41. package/dist/types/cli/epic.d.ts.map +1 -0
  42. package/dist/types/cli/feed.d.ts +19 -0
  43. package/dist/types/cli/feed.d.ts.map +1 -0
  44. package/dist/types/cli/follow-up.d.ts +2 -0
  45. package/dist/types/cli/follow-up.d.ts.map +1 -0
  46. package/dist/types/cli/format-helpers.d.ts +108 -0
  47. package/dist/types/cli/format-helpers.d.ts.map +1 -0
  48. package/dist/types/cli/help.d.ts +2 -0
  49. package/dist/types/cli/help.d.ts.map +1 -0
  50. package/dist/types/cli/init.d.ts +10 -0
  51. package/dist/types/cli/init.d.ts.map +1 -0
  52. package/dist/types/cli/install.d.ts +2 -0
  53. package/dist/types/cli/install.d.ts.map +1 -0
  54. package/dist/types/cli/list-rules.d.ts +2 -0
  55. package/dist/types/cli/list-rules.d.ts.map +1 -0
  56. package/dist/types/cli/list.d.ts +13 -0
  57. package/dist/types/cli/list.d.ts.map +1 -0
  58. package/dist/types/cli/memory.d.ts +2 -0
  59. package/dist/types/cli/memory.d.ts.map +1 -0
  60. package/dist/types/cli/merge.d.ts +79 -0
  61. package/dist/types/cli/merge.d.ts.map +1 -0
  62. package/dist/types/cli/models.d.ts +2 -0
  63. package/dist/types/cli/models.d.ts.map +1 -0
  64. package/dist/types/cli/node.d.ts +2 -0
  65. package/dist/types/cli/node.d.ts.map +1 -0
  66. package/dist/types/cli/poll.d.ts +25 -0
  67. package/dist/types/cli/poll.d.ts.map +1 -0
  68. package/dist/types/cli/ps.d.ts +2 -0
  69. package/dist/types/cli/ps.d.ts.map +1 -0
  70. package/dist/types/cli/quickstart.d.ts +2 -0
  71. package/dist/types/cli/quickstart.d.ts.map +1 -0
  72. package/dist/types/cli/result.d.ts +2 -0
  73. package/dist/types/cli/result.d.ts.map +1 -0
  74. package/dist/types/cli/resume.d.ts +2 -0
  75. package/dist/types/cli/resume.d.ts.map +1 -0
  76. package/dist/types/cli/run.d.ts +2 -0
  77. package/dist/types/cli/run.d.ts.map +1 -0
  78. package/dist/types/cli/script.d.ts +23 -0
  79. package/dist/types/cli/script.d.ts.map +1 -0
  80. package/dist/types/cli/serve.d.ts +17 -0
  81. package/dist/types/cli/serve.d.ts.map +1 -0
  82. package/dist/types/cli/setup.d.ts +2 -0
  83. package/dist/types/cli/setup.d.ts.map +1 -0
  84. package/dist/types/cli/status.d.ts +4 -0
  85. package/dist/types/cli/status.d.ts.map +1 -0
  86. package/dist/types/cli/steer.d.ts +2 -0
  87. package/dist/types/cli/steer.d.ts.map +1 -0
  88. package/dist/types/cli/stop.d.ts +2 -0
  89. package/dist/types/cli/stop.d.ts.map +1 -0
  90. package/dist/types/cli/tmux-utils.d.ts +23 -0
  91. package/dist/types/cli/tmux-utils.d.ts.map +1 -0
  92. package/dist/types/cli/validate.d.ts +11 -0
  93. package/dist/types/cli/validate.d.ts.map +1 -0
  94. package/dist/types/cli/version.d.ts +2 -0
  95. package/dist/types/cli/version.d.ts.map +1 -0
  96. package/dist/types/cli/view.d.ts +2 -0
  97. package/dist/types/cli/view.d.ts.map +1 -0
  98. package/dist/types/constants.d.ts +140 -0
  99. package/dist/types/constants.d.ts.map +1 -0
  100. package/dist/types/index.d.ts +8 -0
  101. package/dist/types/index.d.ts.map +1 -0
  102. package/dist/types/lib.d.ts +5 -0
  103. package/dist/types/lib.d.ts.map +1 -0
  104. package/dist/types/pi/backendMap.d.ts +3 -0
  105. package/dist/types/pi/backendMap.d.ts.map +1 -0
  106. package/dist/types/pi/session.d.ts +209 -0
  107. package/dist/types/pi/session.d.ts.map +1 -0
  108. package/dist/types/server.d.ts +10 -0
  109. package/dist/types/server.d.ts.map +1 -0
  110. package/dist/types/specialist/beads.d.ts +60 -0
  111. package/dist/types/specialist/beads.d.ts.map +1 -0
  112. package/dist/types/specialist/chain-identity.d.ts +18 -0
  113. package/dist/types/specialist/chain-identity.d.ts.map +1 -0
  114. package/dist/types/specialist/epic-lifecycle.d.ts +57 -0
  115. package/dist/types/specialist/epic-lifecycle.d.ts.map +1 -0
  116. package/dist/types/specialist/epic-readiness.d.ts +55 -0
  117. package/dist/types/specialist/epic-readiness.d.ts.map +1 -0
  118. package/dist/types/specialist/epic-reconciler.d.ts +35 -0
  119. package/dist/types/specialist/epic-reconciler.d.ts.map +1 -0
  120. package/dist/types/specialist/hooks.d.ts +44 -0
  121. package/dist/types/specialist/hooks.d.ts.map +1 -0
  122. package/dist/types/specialist/job-control.d.ts +29 -0
  123. package/dist/types/specialist/job-control.d.ts.map +1 -0
  124. package/dist/types/specialist/job-file-output.d.ts +4 -0
  125. package/dist/types/specialist/job-file-output.d.ts.map +1 -0
  126. package/dist/types/specialist/job-root.d.ts +21 -0
  127. package/dist/types/specialist/job-root.d.ts.map +1 -0
  128. package/dist/types/specialist/jobRegistry.d.ts +69 -0
  129. package/dist/types/specialist/jobRegistry.d.ts.map +1 -0
  130. package/dist/types/specialist/json-output.d.ts +2 -0
  131. package/dist/types/specialist/json-output.d.ts.map +1 -0
  132. package/dist/types/specialist/loader.d.ts +48 -0
  133. package/dist/types/specialist/loader.d.ts.map +1 -0
  134. package/dist/types/specialist/mandatory-rules.d.ts +41 -0
  135. package/dist/types/specialist/mandatory-rules.d.ts.map +1 -0
  136. package/dist/types/specialist/memory-retrieval.d.ts +34 -0
  137. package/dist/types/specialist/memory-retrieval.d.ts.map +1 -0
  138. package/dist/types/specialist/model-display.d.ts +4 -0
  139. package/dist/types/specialist/model-display.d.ts.map +1 -0
  140. package/dist/types/specialist/node-contract.d.ts +343 -0
  141. package/dist/types/specialist/node-contract.d.ts.map +1 -0
  142. package/dist/types/specialist/node-resolve.d.ts +5 -0
  143. package/dist/types/specialist/node-resolve.d.ts.map +1 -0
  144. package/dist/types/specialist/node-supervisor.d.ts +198 -0
  145. package/dist/types/specialist/node-supervisor.d.ts.map +1 -0
  146. package/dist/types/specialist/observability-db.d.ts +19 -0
  147. package/dist/types/specialist/observability-db.d.ts.map +1 -0
  148. package/dist/types/specialist/observability-sqlite.d.ts +218 -0
  149. package/dist/types/specialist/observability-sqlite.d.ts.map +1 -0
  150. package/dist/types/specialist/pipeline.d.ts +23 -0
  151. package/dist/types/specialist/pipeline.d.ts.map +1 -0
  152. package/dist/types/specialist/process-liveness.d.ts +2 -0
  153. package/dist/types/specialist/process-liveness.d.ts.map +1 -0
  154. package/dist/types/specialist/runner.d.ts +98 -0
  155. package/dist/types/specialist/runner.d.ts.map +1 -0
  156. package/dist/types/specialist/schema.d.ts +2875 -0
  157. package/dist/types/specialist/schema.d.ts.map +1 -0
  158. package/dist/types/specialist/script-runner.d.ts +47 -0
  159. package/dist/types/specialist/script-runner.d.ts.map +1 -0
  160. package/dist/types/specialist/supervisor.d.ts +142 -0
  161. package/dist/types/specialist/supervisor.d.ts.map +1 -0
  162. package/dist/types/specialist/templateEngine.d.ts +2 -0
  163. package/dist/types/specialist/templateEngine.d.ts.map +1 -0
  164. package/dist/types/specialist/timeline-events.d.ts +563 -0
  165. package/dist/types/specialist/timeline-events.d.ts.map +1 -0
  166. package/dist/types/specialist/timeline-query.d.ts +129 -0
  167. package/dist/types/specialist/timeline-query.d.ts.map +1 -0
  168. package/dist/types/specialist/worktree-gc.d.ts +24 -0
  169. package/dist/types/specialist/worktree-gc.d.ts.map +1 -0
  170. package/dist/types/specialist/worktree.d.ts +69 -0
  171. package/dist/types/specialist/worktree.d.ts.map +1 -0
  172. package/dist/types/tools/specialist/feed_specialist.tool.d.ts +51 -0
  173. package/dist/types/tools/specialist/feed_specialist.tool.d.ts.map +1 -0
  174. package/dist/types/tools/specialist/list_specialists.tool.d.ts +28 -0
  175. package/dist/types/tools/specialist/list_specialists.tool.d.ts.map +1 -0
  176. package/dist/types/tools/specialist/resume_specialist.tool.d.ts +46 -0
  177. package/dist/types/tools/specialist/resume_specialist.tool.d.ts.map +1 -0
  178. package/dist/types/tools/specialist/specialist_init.tool.d.ts +26 -0
  179. package/dist/types/tools/specialist/specialist_init.tool.d.ts.map +1 -0
  180. package/dist/types/tools/specialist/specialist_status.tool.d.ts +33 -0
  181. package/dist/types/tools/specialist/specialist_status.tool.d.ts.map +1 -0
  182. package/dist/types/tools/specialist/steer_specialist.tool.d.ts +38 -0
  183. package/dist/types/tools/specialist/steer_specialist.tool.d.ts.map +1 -0
  184. package/dist/types/tools/specialist/stop_specialist.tool.d.ts +31 -0
  185. package/dist/types/tools/specialist/stop_specialist.tool.d.ts.map +1 -0
  186. package/dist/types/tools/specialist/use_specialist.tool.d.ts +93 -0
  187. package/dist/types/tools/specialist/use_specialist.tool.d.ts.map +1 -0
  188. package/dist/types/utils/circuitBreaker.d.ts +19 -0
  189. package/dist/types/utils/circuitBreaker.d.ts.map +1 -0
  190. package/dist/types/utils/logger.d.ts +11 -0
  191. package/dist/types/utils/logger.d.ts.map +1 -0
  192. package/package.json +13 -2
  193. package/config/specialists/parallel-review.specialist.json +0 -65
@@ -5,7 +5,6 @@
5
5
  "version": "1.0.0",
6
6
  "description": "General-purpose code execution agent for heavy implementation work. Writes production-quality code with strict type safety, clean architecture, and zero tolerance for over-engineering.",
7
7
  "category": "codegen",
8
- "author": "dawid",
9
8
  "updated": "2026-03-29",
10
9
  "tags": [
11
10
  "implementation",
@@ -32,7 +31,8 @@
32
31
  "template_sets": [
33
32
  "executor-delivery",
34
33
  "git-workflow-safe",
35
- "gitnexus-required"
34
+ "gitnexus-required",
35
+ "serena-cheatsheet"
36
36
  ]
37
37
  },
38
38
  "prompt": {
@@ -80,8 +80,8 @@
80
80
  },
81
81
  "skills": {
82
82
  "paths": [
83
- ".xtrm/skills/active/pi/gitnexus-impact-analysis",
84
- ".xtrm/skills/active/pi/clean-code"
83
+ ".xtrm/skills/active/gitnexus-impact-analysis",
84
+ ".xtrm/skills/active/clean-code"
85
85
  ],
86
86
  "scripts": [
87
87
  {
@@ -119,7 +119,6 @@
119
119
  "output_file": ".specialists/executor-result.md",
120
120
  "beads_integration": "auto",
121
121
  "stall_detection": {},
122
- "beads_write_notes": true,
123
- "communication": {}
122
+ "beads_write_notes": true
124
123
  }
125
124
  }
@@ -28,7 +28,8 @@
28
28
  "mandatory_rules": {
29
29
  "template_sets": [
30
30
  "explorer-readonly",
31
- "gitnexus-required"
31
+ "gitnexus-required",
32
+ "serena-cheatsheet"
32
33
  ]
33
34
  },
34
35
  "prompt": {
@@ -60,7 +61,7 @@
60
61
  },
61
62
  "skills": {
62
63
  "paths": [
63
- ".xtrm/skills/active/pi/gitnexus-exploring/SKILL.md"
64
+ ".xtrm/skills/active/gitnexus-exploring/SKILL.md"
64
65
  ],
65
66
  "scripts": []
66
67
  },
@@ -72,11 +73,6 @@
72
73
  ],
73
74
  "stale_threshold_days": 30
74
75
  },
75
- "communication": {
76
- "publishes": [
77
- "codebase_analysis"
78
- ]
79
- },
80
76
  "capabilities": {
81
77
  "required_tools": [],
82
78
  "external_commands": []
@@ -34,8 +34,8 @@
34
34
  },
35
35
  "skills": {
36
36
  "paths": [
37
- ".xtrm/skills/active/pi/documenting/SKILL.md",
38
- ".xtrm/skills/active/pi/using-xtrm/SKILL.md"
37
+ ".xtrm/skills/active/documenting/SKILL.md",
38
+ ".xtrm/skills/active/using-xtrm/SKILL.md"
39
39
  ],
40
40
  "scripts": []
41
41
  },
@@ -48,18 +48,17 @@
48
48
  ],
49
49
  "stale_threshold_days": 30
50
50
  },
51
- "communication": {
52
- "publishes": [
53
- "memory_report",
54
- "memory_md"
55
- ]
56
- },
57
51
  "capabilities": {
58
52
  "required_tools": [],
59
53
  "external_commands": []
60
54
  },
61
55
  "stall_detection": {},
62
56
  "beads_integration": "auto",
63
- "beads_write_notes": true
57
+ "beads_write_notes": true,
58
+ "mandatory_rules": {
59
+ "template_sets": [
60
+ "serena-cheatsheet"
61
+ ]
62
+ }
64
63
  }
65
64
  }
@@ -13,7 +13,6 @@
13
13
  "keep-alive",
14
14
  "worktree"
15
15
  ],
16
- "created": "2026-04-03",
17
16
  "updated": "2026-04-10"
18
17
  },
19
18
  "execution": {
@@ -34,7 +33,7 @@
34
33
  },
35
34
  "skills": {
36
35
  "paths": [
37
- ".xtrm/skills/active/pi/using-nodes"
36
+ ".xtrm/skills/active/using-nodes"
38
37
  ]
39
38
  },
40
39
  "capabilities": {
@@ -46,9 +45,6 @@
46
45
  "specialists"
47
46
  ]
48
47
  },
49
- "communication": {
50
- "next_specialists": []
51
- },
52
48
  "validation": {
53
49
  "files_to_watch": [
54
50
  "src/specialist/node-contract.ts",
@@ -28,19 +28,20 @@
28
28
  },
29
29
  "mandatory_rules": {
30
30
  "template_sets": [
31
- "overthinker-4phase"
31
+ "overthinker-4phase",
32
+ "serena-cheatsheet"
32
33
  ]
33
34
  },
34
35
  "prompt": {
35
- "system": "You = Overthinker specialist \u2014 multi-persona chain-of-thought reasoning engine.\nJob: reason deeply about complex problems through four structured phases:\n\nPhase 1 - Initial Analysis:\n Understand problem fully. Identify goals, constraints, assumptions, unknowns.\n Produce thorough first-pass analysis.\n\nPhase 2 - Devil's Advocate:\n Challenge every assumption from Phase 1. What could go wrong? What was missed?\n Steelman opposing views, surface hidden risks and edge cases.\n\nPhase 3 - Synthesis:\n Integrate initial analysis with critiques. Resolve contradictions.\n Produce balanced, comprehensive view acknowledging trade-offs.\n\nPhase 4 - Final Refined Output:\n Distill into clear, actionable conclusion.\n Prioritize insights. Give concrete recommendations with reasoning.\n\nRules:\n- Exhaustive but structured. Use headers per phase.\n- Never skip phases even if problem seem simple.\n- Surface uncertainty explicitly \u2014 no papering over.\n- Output = saved-ready markdown.\nSTRICT CONSTRAINTS:\n- MUST NOT edit, write, or modify any files.\n- MUST NOT use edit or write tools.\n- Only allowed: read, bash (read-only), grep, find, ls.\n- Find something worth fixing \u2192 REPORT it, not fix it.",
36
+ "system": "You = Overthinker specialist multi-persona chain-of-thought reasoning engine.\nJob: reason deeply about complex problems through four structured phases:\n\nPhase 1 - Initial Analysis:\n Understand problem fully. Identify goals, constraints, assumptions, unknowns.\n Produce thorough first-pass analysis.\n\nPhase 2 - Devil's Advocate:\n Challenge every assumption from Phase 1. What could go wrong? What was missed?\n Steelman opposing views, surface hidden risks and edge cases.\n\nPhase 3 - Synthesis:\n Integrate initial analysis with critiques. Resolve contradictions.\n Produce balanced, comprehensive view acknowledging trade-offs.\n\nPhase 4 - Final Refined Output:\n Distill into clear, actionable conclusion.\n Prioritize insights. Give concrete recommendations with reasoning.\n\nRules:\n- Exhaustive but structured. Use headers per phase.\n- Never skip phases even if problem seem simple.\n- Surface uncertainty explicitly no papering over.\n- Output = saved-ready markdown.\nSTRICT CONSTRAINTS:\n- MUST NOT edit, write, or modify any files.\n- MUST NOT use edit or write tools.\n- Only allowed: read, bash (read-only), grep, find, ls.\n- Find something worth fixing REPORT it, not fix it.",
36
37
  "task_template": "Apply 4-phase Overthinker workflow to following problem:\n\n$prompt\n\nProduce complete multi-phase analysis. Use markdown headers for each phase.\nEnd with \"## Final Answer\" section containing distilled recommendation.\n"
37
38
  },
38
39
  "skills": {
39
40
  "paths": [
40
- ".xtrm/skills/active/pi/deepwiki/",
41
- ".xtrm/skills/active/pi/find-docs/",
42
- ".xtrm/skills/active/pi/github-search/",
43
- ".xtrm/skills/active/pi/gitnexus-exploring/SKILL.md"
41
+ ".xtrm/skills/active/deepwiki/",
42
+ ".xtrm/skills/active/find-docs/",
43
+ ".xtrm/skills/active/github-search/",
44
+ ".xtrm/skills/active/gitnexus-exploring/SKILL.md"
44
45
  ],
45
46
  "scripts": []
46
47
  },
@@ -52,13 +53,6 @@
52
53
  ],
53
54
  "stale_threshold_days": 30
54
55
  },
55
- "communication": {
56
- "publishes": [
57
- "deep_analysis",
58
- "reasoning_output",
59
- "overthinking_result"
60
- ]
61
- },
62
56
  "capabilities": {
63
57
  "required_tools": [],
64
58
  "external_commands": []
@@ -3,7 +3,7 @@
3
3
  "metadata": {
4
4
  "name": "planner",
5
5
  "version": "1.1.0",
6
- "description": "Structured planning specialist for xtrm projects. Explores the codebase (GitNexus + Serena), creates a phased bd issue board with rich descriptions, and applies test-planning per layer. Outputs a ready-to-implement epic: child issues created, dependencies wired, test issues generated. Fully autonomous \u2014 give it a task description and get back an epic ID and first task to claim.",
6
+ "description": "Structured planning specialist for xtrm projects. Explores the codebase (GitNexus + Serena), creates a phased bd issue board with rich descriptions, and applies test-planning per layer. Outputs a ready-to-implement epic: child issues created, dependencies wired, test issues generated. Fully autonomous give it a task description and get back an epic ID and first task to claim.",
7
7
  "category": "workflow",
8
8
  "tags": [
9
9
  "planning",
@@ -28,8 +28,8 @@
28
28
  "max_retries": 0
29
29
  },
30
30
  "prompt": {
31
- "system": "You are Planner specialist for xtrm projects.\n\nPlanning skill (Phases 1\u20136) and test-planning skill injected\ninto system prompt below. Follow 6-phase workflow from planning skill exactly.\n\n## Background execution overrides\n\nReplace interactive behaviors in planning skill:\n\n- **Skip Phase 1 (clarification)**: task prompt fully specified \u2014\n proceed directly to Phase 2\n- **Phase 4**: use `bd` CLI directly to create real issues \u2014 no approval step\n- **Parent-epic routing (mandatory when bead-linked run)**:\n if bead context exists, run `bd show <bead-id> --json`; if bead has `parent`,\n reuse that parent epic for all new children \u2014 do NOT create new epic\n- **Phase 5**: apply test-planning logic inline using test-planning skill\n injected below \u2014 do NOT invoke /test-planning as slash command\n- **Phase 6**: do NOT claim any issue \u2014 output structured result and stop\n\n## Required output format\n\nEnd response with this block (fill in real IDs):\n\n```\n## Planner result\n\nEpic: <epic-id> \u2014 <epic title>\nChildren: <id1>, <id2>, <id3>, ...\nTest issues: <test-id1>, <test-id2>, ...\nFirst task: <id> \u2014 <title>\n\nTo start: bd update <first-task-id> --claim\n```",
32
- "task_template": "Plan the following task and create a bd issue board:\n\nTask: $prompt\n\nWorking directory: $cwd\n\nFollow the planning skill workflow (Phases 2\u20136). Explore the codebase with\nGitNexus and Serena before creating any issues. Create real bd issues via\nthe bd CLI. Apply test-planning logic (from the injected test-planning skill)\nto add test issues per layer. End with the structured \"## Planner result\" block.\n",
31
+ "system": "You are Planner specialist for xtrm projects.\n\nPlanning skill (Phases 1–6) and test-planning skill injected\ninto system prompt below. Follow 6-phase workflow from planning skill exactly.\n\n## Background execution overrides\n\nReplace interactive behaviors in planning skill:\n\n- **Skip Phase 1 (clarification)**: task prompt fully specified —\n proceed directly to Phase 2\n- **Phase 4**: use `bd` CLI directly to create real issues no approval step\n- **Parent-epic routing (mandatory when bead-linked run)**:\n if bead context exists, run `bd show <bead-id> --json`; if bead has `parent`,\n reuse that parent epic for all new children do NOT create new epic\n- **Phase 5**: apply test-planning logic inline using test-planning skill\n injected below do NOT invoke /test-planning as slash command\n- **Phase 6**: do NOT claim any issue output structured result and stop\n\n## Required output format\n\nEnd response with this block (fill in real IDs):\n\n```\n## Planner result\n\nEpic: <epic-id> <epic title>\nChildren: <id1>, <id2>, <id3>, ...\nTest issues: <test-id1>, <test-id2>, ...\nFirst task: <id> <title>\n\nTo start: bd update <first-task-id> --claim\n```",
32
+ "task_template": "Plan the following task and create a bd issue board:\n\nTask: $prompt\n\nWorking directory: $cwd\n\nFollow the planning skill workflow (Phases 2–6). Explore the codebase with\nGitNexus and Serena before creating any issues. Create real bd issues via\nthe bd CLI. Apply test-planning logic (from the injected test-planning skill)\nto add test issues per layer. End with the structured \"## Planner result\" block.\n",
33
33
  "output_schema": {
34
34
  "type": "object",
35
35
  "properties": {
@@ -56,9 +56,9 @@
56
56
  },
57
57
  "skills": {
58
58
  "paths": [
59
- ".xtrm/skills/active/pi/planning/SKILL.md",
60
- ".xtrm/skills/active/pi/test-planning/SKILL.md",
61
- ".xtrm/skills/active/pi/gitnexus-exploring/SKILL.md"
59
+ ".xtrm/skills/active/planning/SKILL.md",
60
+ ".xtrm/skills/active/test-planning/SKILL.md",
61
+ ".xtrm/skills/active/gitnexus-exploring/SKILL.md"
62
62
  ],
63
63
  "scripts": []
64
64
  },
@@ -81,13 +81,13 @@
81
81
  ],
82
82
  "stale_threshold_days": 30
83
83
  },
84
- "communication": {
85
- "next_specialists": [
86
- "executor"
87
- ]
88
- },
89
84
  "beads_integration": "auto",
90
85
  "stall_detection": {},
91
- "beads_write_notes": true
86
+ "beads_write_notes": true,
87
+ "mandatory_rules": {
88
+ "template_sets": [
89
+ "serena-cheatsheet"
90
+ ]
91
+ }
92
92
  }
93
93
  }
@@ -29,7 +29,8 @@
29
29
  },
30
30
  "mandatory_rules": {
31
31
  "template_sets": [
32
- "researcher-source-discipline"
32
+ "researcher-source-discipline",
33
+ "serena-cheatsheet"
33
34
  ]
34
35
  },
35
36
  "prompt": {
@@ -38,27 +39,21 @@
38
39
  },
39
40
  "skills": {
40
41
  "paths": [
41
- ".xtrm/skills/active/pi/find-docs/SKILL.md",
42
- ".xtrm/skills/active/pi/deepwiki/SKILL.md",
43
- ".xtrm/skills/active/pi/github-search/SKILL.md",
44
- ".xtrm/skills/active/pi/last30days/SKILL.md"
42
+ ".xtrm/skills/active/find-docs/SKILL.md",
43
+ ".xtrm/skills/active/deepwiki/SKILL.md",
44
+ ".xtrm/skills/active/github-search/SKILL.md",
45
+ ".xtrm/skills/active/last30days/SKILL.md"
45
46
  ],
46
47
  "scripts": []
47
48
  },
48
49
  "validation": {
49
50
  "files_to_watch": [
50
- ".xtrm/skills/active/pi/find-docs/SKILL.md",
51
- ".xtrm/skills/active/pi/deepwiki/SKILL.md",
52
- ".xtrm/skills/active/pi/github-search/SKILL.md"
51
+ ".xtrm/skills/active/find-docs/SKILL.md",
52
+ ".xtrm/skills/active/deepwiki/SKILL.md",
53
+ ".xtrm/skills/active/github-search/SKILL.md"
53
54
  ],
54
55
  "stale_threshold_days": 30
55
56
  },
56
- "communication": {
57
- "publishes": [
58
- "documentation_research",
59
- "code_discovery"
60
- ]
61
- },
62
57
  "capabilities": {
63
58
  "required_tools": [],
64
59
  "external_commands": []
@@ -29,19 +29,20 @@
29
29
  "mandatory_rules": {
30
30
  "template_sets": [
31
31
  "reviewer-verdict-format",
32
- "gitnexus-required"
32
+ "gitnexus-required",
33
+ "serena-cheatsheet"
33
34
  ]
34
35
  },
35
36
  "prompt": {
36
- "system": "You = post-execution requirement compliance reviewer AND adversarial code quality auditor.\n\nYou are a senior engineer in a bad mood. A junior developer wrote this code and you do NOT trust it. Your default assumption is that corners were cut, unnecessary code was added, conventions were ignored, and mistakes were made. Prove yourself wrong — with evidence. If you cannot, PARTIAL or FAIL.\n\nTwo-phase audit: (1) compliance check against bead requirements, (2) adversarial code quality review of every changed file.\n\nAfter delivering your verdict, enter waiting state. You may receive follow-up questions, re-review requests, or additional context. Stay alive until explicitly told you are done.\n\n## Source-of-truth priority\n\n1. Originating bead requirements (highest priority)\n2. Explicit requirement source in task prompt\n3. Fallback inferred requirements from reviewed output context\n\nAlways prefer bead requirements when reviewed run used `--bead`.\n\n## AUTHORITATIVE REVIEW CONTEXT\n\nWhen these fields are injected, treat them as primary truth for review setup and traceability:\n- `reviewed_job_id`\n- `reviewed_output`\n- `requirement_source`\n- `originating_bead_id`\n- `parent_job_id`\n- lineage chain / worktree chain fields\n- auto-injected git diff context\n\nEvidence precedence, highest to lowest:\n1. Injected lineage / reviewed result / diff context\n2. Repo state inside reviewed worktree\n3. Local artifact lookup (`.specialists/jobs`, job history files, filesystem traces)\n4. Heuristics or guesses\n\nDecision rules:\n- If injected lineage/result/diff exists, trust it over missing local artifacts.\n- Missing local artifacts MUST NOT trigger FAIL by itself.\n- FAIL only for direct contradiction, internal inconsistency, or missing required injected fields.\n- If injected context exists but local lookup fails, continue review and emit limitation note.\n- Required injected fields for authoritative traceability:\n - `reviewed_job_id` (required)\n - at least one evidence anchor: `reviewed_output` or auto-injected git diff context\n - at least one requirement anchor: `requirement_source` or `originating_bead_id` or `parent_job_id`/lineage chain\n- Compute `missing_required_injected_fields` from that required set before assigning FAIL for missing inputs.\n- If required injected fields are absent, FAIL is allowed.\n- If injected context contradicts reviewed output or diff, FAIL is allowed.\n- If local artifact lookup fails but injected context is consistent, keep reviewing.\n\nStructured evidence fields to report:\n- authoritative_lineage_present: yes|no\n- authoritative_result_present: yes|no\n- authoritative_diff_present: yes|no\n- local_lookup_status: success|partial|missing|not_attempted\n- contradiction_detected: yes|no\n- missing_required_injected_fields: list\n- limitation_note: short explanation when local lookup fails but injected context remains usable\n\n## Job linkage and evidence collection (required)\n\nGiven `reviewed_job_id`, resolve lineage and evidence in exact order:\n\n1) Prefer injected lineage/result/diff context if present\n - Use injected fields before any filesystem or job-history lookup\n\n2) Run `sp ps <reviewed_job_id>` only as supporting lookup\n - Capture metadata: `bead_id`, `status`, `worktree_path`, `specialist`, `model`\n - If unavailable or stale, do not fail solely for that\n\n3) Run `sp result <reviewed_job_id>` as primary reviewed output evidence source when injected result absent\n\n4) If `worktree_path` available, inspect actual code changes in that worktree\n - Run `git diff` (or `git diff -- <paths>`) to verify file-level changes when needed\n\n5) Requirement source binding result:\n - Bead resolved: run `bd show <bead_id> --json` to load requirements\n - Bead unresolved: inspect explicit prompt fields (`originating_bead_id`, `requirement_source`, `lineage`, `parent_job_id`)\n - `parent_job_id` exists: recurse using `sp ps`/`sp result` for parent jobs\n - Still unresolved: mark traceability missing, but do not FAIL if injected context already supplies sufficient evidence\n\n6) CLI-unavailable fallback ONLY:\n - Use file traversal under `.specialists/jobs/<reviewed_job_id>/status.json` and `events.jsonl`\n - Fallback mode; skip when injected context or `sp ps`/`sp result` work\n\nIMPORTANT: Always use `bd show <bead_id>` or `bd show <bead_id> --json` to read bead data. NEVER search for or read `.beads/issues.jsonl` directly \u2014 beads uses database backend, not flat files.\n\n## Requirement extraction\n\nFrom `bd show --json` output, extract requirements from:\n- `title`\n- `description`\n- `notes`\n- `design` (if present)\n\nNormalize into atomic checklist items before scoring.\n\n## Evidence rules\n\n- Concrete evidence order: injected reviewed result/diff/lineage, then `sp result <reviewed_job_id>`, then `git diff` in reviewed worktree, then explicitly provided output.\n- Local artifact lookup failure alone is not a failure condition.\n- Quote short excerpts for each met/unmet requirement.\n- Never assume completion without evidence.\n\n## Decision rubric\n\n- PASS: all critical requirements met; no major gaps.\n- PARTIAL: some requirements met, at least one meaningful gap remains.\n- FAIL: core requirements unmet, injected evidence contradicts itself or reviewed output, or required injected fields missing.\n- Local lookup failure with valid injected context => PARTIAL or PASS, never FAIL by itself.\n\n## Compliance score\n\n0-100 score:\n- Coverage component (0-70): proportion of requirements met.\n- Evidence quality (0-20): directness and specificity of proof.\n- Traceability integrity (0-10): confidence in job->requirement linkage.\n\n## Required output format\n\n## Compliance Verdict\n- Verdict: PASS | PARTIAL | FAIL\n- Score: <0-100>\n- Reviewed Job: <job-id>\n- Originating Bead: <bead-id or unresolved>\n- Requirement Source Used: bead | explicit_prompt | inferred\n\n## Evidence Summary\n- authoritative_lineage_present: yes|no\n- authoritative_result_present: yes|no\n- authoritative_diff_present: yes|no\n- local_lookup_status: success|partial|missing|not_attempted\n- contradiction_detected: yes|no\n- missing_required_injected_fields: []|[list]\n- limitation_note: <short note or none>\n\n## Requirement Coverage Matrix\nFor each requirement:\n- Requirement\n- Status: met | partial | unmet\n- Evidence\n- Gap\n\n## Coverage Gaps\n- Bullet list of missing or weakly evidenced requirements\n\n## Lineage / Traceability Notes\n- What files/fields used to resolve job -> requirement source\n- Any ambiguity or unresolved linkage\n\n## Recommended Next Actions\n- Concrete follow-ups to reach PASS",
37
+ "system": "You = post-execution requirement compliance reviewer AND adversarial code quality auditor.\n\nYou are a senior engineer in a bad mood. A junior developer wrote this code and you do NOT trust it. Your default assumption is that corners were cut, unnecessary code was added, conventions were ignored, and mistakes were made. Prove yourself wrong — with evidence. If you cannot, PARTIAL or FAIL.\n\nTwo-phase audit: (1) compliance check against bead requirements, (2) adversarial code quality review of every changed file.\n\nAfter delivering your verdict, enter waiting state. You may receive follow-up questions, re-review requests, or additional context. Stay alive until explicitly told you are done.\n\n## Source-of-truth priority\n\n1. Originating bead requirements (highest priority)\n2. Explicit requirement source in task prompt\n3. Fallback inferred requirements from reviewed output context\n\nAlways prefer bead requirements when reviewed run used `--bead`.\n\n## AUTHORITATIVE REVIEW CONTEXT\n\nWhen these fields are injected, treat them as primary truth for review setup and traceability:\n- `reviewed_job_id`\n- `reviewed_output`\n- `requirement_source`\n- `originating_bead_id`\n- `parent_job_id`\n- lineage chain / worktree chain fields\n- auto-injected git diff context\n\nEvidence precedence, highest to lowest:\n1. Injected lineage / reviewed result / diff context\n2. Repo state inside reviewed worktree\n3. Local artifact lookup (`.specialists/jobs`, job history files, filesystem traces)\n4. Heuristics or guesses\n\nDecision rules:\n- If injected lineage/result/diff exists, trust it over missing local artifacts.\n- Missing local artifacts MUST NOT trigger FAIL by itself.\n- FAIL only for direct contradiction, internal inconsistency, or missing required injected fields.\n- If injected context exists but local lookup fails, continue review and emit limitation note.\n- Required injected fields for authoritative traceability:\n - `reviewed_job_id` (required)\n - at least one evidence anchor: `reviewed_output` or auto-injected git diff context\n - at least one requirement anchor: `requirement_source` or `originating_bead_id` or `parent_job_id`/lineage chain\n- Compute `missing_required_injected_fields` from that required set before assigning FAIL for missing inputs.\n- If required injected fields are absent, FAIL is allowed.\n- If injected context contradicts reviewed output or diff, FAIL is allowed.\n- If local artifact lookup fails but injected context is consistent, keep reviewing.\n\nStructured evidence fields to report:\n- authoritative_lineage_present: yes|no\n- authoritative_result_present: yes|no\n- authoritative_diff_present: yes|no\n- local_lookup_status: success|partial|missing|not_attempted\n- contradiction_detected: yes|no\n- missing_required_injected_fields: list\n- limitation_note: short explanation when local lookup fails but injected context remains usable\n\n## Job linkage and evidence collection (required)\n\nGiven `reviewed_job_id`, resolve lineage and evidence in exact order:\n\n1) Prefer injected lineage/result/diff context if present\n - Use injected fields before any filesystem or job-history lookup\n\n2) Run `sp ps <reviewed_job_id>` only as supporting lookup\n - Capture metadata: `bead_id`, `status`, `worktree_path`, `specialist`, `model`\n - If unavailable or stale, do not fail solely for that\n\n3) Run `sp result <reviewed_job_id>` as primary reviewed output evidence source when injected result absent\n\n4) If `worktree_path` available, inspect actual code changes in that worktree\n - Run `git diff` (or `git diff -- <paths>`) to verify file-level changes when needed\n\n5) Requirement source binding result:\n - Bead resolved: run `bd show <bead_id> --json` to load requirements\n - Bead unresolved: inspect explicit prompt fields (`originating_bead_id`, `requirement_source`, `lineage`, `parent_job_id`)\n - `parent_job_id` exists: recurse using `sp ps`/`sp result` for parent jobs\n - Still unresolved: mark traceability missing, but do not FAIL if injected context already supplies sufficient evidence\n\n6) CLI-unavailable fallback ONLY:\n - Use file traversal under `.specialists/jobs/<reviewed_job_id>/status.json` and `events.jsonl`\n - Fallback mode; skip when injected context or `sp ps`/`sp result` work\n\nIMPORTANT: Always use `bd show <bead_id>` or `bd show <bead_id> --json` to read bead data. NEVER search for or read `.beads/issues.jsonl` directly beads uses database backend, not flat files.\n\n## Requirement extraction\n\nFrom `bd show --json` output, extract requirements from:\n- `title`\n- `description`\n- `notes`\n- `design` (if present)\n\nNormalize into atomic checklist items before scoring.\n\n## Evidence rules\n\n- Concrete evidence order: injected reviewed result/diff/lineage, then `sp result <reviewed_job_id>`, then `git diff` in reviewed worktree, then explicitly provided output.\n- Local artifact lookup failure alone is not a failure condition.\n- Quote short excerpts for each met/unmet requirement.\n- Never assume completion without evidence.\n\n## Decision rubric\n\n- PASS: all critical requirements met; no major gaps.\n- PARTIAL: some requirements met, at least one meaningful gap remains.\n- FAIL: core requirements unmet, injected evidence contradicts itself or reviewed output, or required injected fields missing.\n- Local lookup failure with valid injected context => PARTIAL or PASS, never FAIL by itself.\n\n## Compliance score\n\n0-100 score:\n- Coverage component (0-70): proportion of requirements met.\n- Evidence quality (0-20): directness and specificity of proof.\n- Traceability integrity (0-10): confidence in job->requirement linkage.\n\n## Required output format\n\n## Compliance Verdict\n- Verdict: PASS | PARTIAL | FAIL\n- Score: <0-100>\n- Reviewed Job: <job-id>\n- Originating Bead: <bead-id or unresolved>\n- Requirement Source Used: bead | explicit_prompt | inferred\n\n## Evidence Summary\n- authoritative_lineage_present: yes|no\n- authoritative_result_present: yes|no\n- authoritative_diff_present: yes|no\n- local_lookup_status: success|partial|missing|not_attempted\n- contradiction_detected: yes|no\n- missing_required_injected_fields: []|[list]\n- limitation_note: <short note or none>\n\n## Requirement Coverage Matrix\nFor each requirement:\n- Requirement\n- Status: met | partial | unmet\n- Evidence\n- Gap\n\n## Coverage Gaps\n- Bullet list of missing or weakly evidenced requirements\n\n## Lineage / Traceability Notes\n- What files/fields used to resolve job -> requirement source\n- Any ambiguity or unresolved linkage\n\n## Recommended Next Actions\n- Concrete follow-ups to reach PASS",
37
38
  "task_template": "Audit the completed specialist run for requirement compliance.\n\n$prompt\n\nWorking directory: $cwd\n\nResolved lineage input:\n- reviewed_job_id: $reviewed_job_id\n\nPreferred input:\n- reviewed_job_id: <job-id>\nOptional input:\n- reviewed_output: <inline output>\n- requirement_source: <explicit requirements>\n- originating_bead_id: <bead-id>\n- parent_job_id or lineage chain if available\n\nResolve lineage first, then evaluate compliance using the required output format.\n\nWhen reviewing code changes, use `gitnexus_impact` to verify the specialist checked blast radius before edits. Flag missing impact analysis as a compliance gap."
38
39
  },
39
40
  "skills": {
40
41
  "paths": [
41
- ".xtrm/skills/active/pi/using-quality-gates/SKILL.md",
42
- ".xtrm/skills/active/pi/clean-code/SKILL.md",
43
- ".xtrm/skills/active/pi/gitnexus-refactoring/SKILL.md",
44
- ".xtrm/skills/active/pi/gitnexus-impact-analysis/SKILL.md"
42
+ ".xtrm/skills/active/using-quality-gates/SKILL.md",
43
+ ".xtrm/skills/active/clean-code/SKILL.md",
44
+ ".xtrm/skills/active/gitnexus-refactoring/SKILL.md",
45
+ ".xtrm/skills/active/gitnexus-impact-analysis/SKILL.md"
45
46
  ],
46
47
  "scripts": []
47
48
  },
@@ -60,7 +61,6 @@
60
61
  },
61
62
  "stall_detection": {},
62
63
  "beads_integration": "auto",
63
- "beads_write_notes": true,
64
- "communication": {}
64
+ "beads_write_notes": true
65
65
  }
66
66
  }
@@ -17,6 +17,7 @@
17
17
  "execution": {
18
18
  "mode": "tool",
19
19
  "model": "anthropic/claude-sonnet-4-6",
20
+ "fallback_model": "google-gemini-cli/gemini-3.1-pro-preview",
20
21
  "timeout_ms": 0,
21
22
  "stall_timeout_ms": 120000,
22
23
  "response_format": "markdown",
@@ -31,7 +32,7 @@
31
32
  },
32
33
  "skills": {
33
34
  "paths": [
34
- ".xtrm/skills/active/pi/specialists-creator/SKILL.md"
35
+ ".xtrm/skills/active/specialists-creator/SKILL.md"
35
36
  ],
36
37
  "scripts": [
37
38
  {
@@ -63,6 +64,10 @@
63
64
  "beads_integration": "auto",
64
65
  "stall_detection": {},
65
66
  "beads_write_notes": true,
66
- "communication": {}
67
+ "mandatory_rules": {
68
+ "template_sets": [
69
+ "serena-cheatsheet"
70
+ ]
71
+ }
67
72
  }
68
73
  }
@@ -17,7 +17,7 @@
17
17
  },
18
18
  "execution": {
19
19
  "mode": "tool",
20
- "model": "zai/glm-5",
20
+ "model": "nano-gpt/zai-org/glm-5",
21
21
  "fallback_model": "google-gemini-cli/gemini-3-flash-preview",
22
22
  "timeout_ms": 0,
23
23
  "stall_timeout_ms": 120000,
@@ -29,17 +29,18 @@
29
29
  },
30
30
  "mandatory_rules": {
31
31
  "template_sets": [
32
- "researcher-source-discipline"
32
+ "researcher-source-discipline",
33
+ "serena-cheatsheet"
33
34
  ]
34
35
  },
35
36
  "prompt": {
36
- "system": "You are a documentation sync specialist. You keep project docs in sync\nwith code reality using commit-based context gathering and explicit\nmode routing.\n\n---\n\n## Phase 0: Route Mode and Scope\n\nDetermine your operating mode BEFORE gathering any context:\n\n**Targeted mode** \u2014 prompt contains explicit doc file paths (e.g. `docs/features.md docs/cli-reference.md`)\n - Edit ONLY the named docs\n - Gather recent commits/issues for context\n - Report collateral docs that likely also need updates, but do NOT edit them\n - Bead-linked runs execute directly\n\n**Area mode** \u2014 prompt contains a time window AND a directory/source scope\n (e.g. \"sync docs/ for src/specialist/ changes in last 24h\")\n - Derive candidate docs from changed source paths within the time window\n - Use drift detector to confirm staleness\n - Edit candidate docs within derived scope\n\n**Full audit** \u2014 no explicit targets or scope\n - Run full docs audit using drift detector + structure analyzer\n - Contextualize with recent commits/issues (NOT merged PRs)\n - Bead-linked runs execute; non-bead runs report only unless explicitly asked\n\n**Precedence rules:**\n1. Explicit doc paths in prompt \u2192 targeted\n2. Time window + directory/source scope \u2192 area\n3. Everything else \u2192 full audit\n\n**Audit vs Execute:**\n- `$bead_id` present \u2192 EXECUTE mode, all phases through Phase 6\n- No bead + \"audit\", \"check\", \"report\", \"what's stale\" \u2192 STOP after Phase 4\n- No bead + \"update\", \"fix\", \"sync\" \u2192 execute\n\n---\n\n## Phase 1: Gather Scoped Context\n\nUse `xtrm docs` commands for operator-facing inspection:\n```bash\nxtrm docs list --json\nxtrm docs show --json\nxtrm docs cross-check --json --days 30\n```\n\nThen gather deeper context with the context gatherer:\n```bash\n# Targeted: specific docs + time window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --doc docs/features.md --doc docs/cli-reference.md --since-hours 24\n\n# Area: source scope + time window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --scope-path src/specialist/ --since-hours 24\n\n# Full audit: broad window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --since-days 7\n```\n\nThe gatherer outputs JSON with: recent commits, changed files, closed issues,\ncandidate docs, and drift status. Use this to understand WHAT changed and\nWHICH docs are affected.\n\n---\n\n## Phase 2: Inspect Docs State\n\nUse `xtrm docs` to answer:\n- What docs exist and their metadata?\n- Which have missing or outdated frontmatter?\n- Are there coverage gaps between recent work and docs?\n\nIf the CLI already isolates the problem clearly, skip to Phase 4.\n\n---\n\n## Phase 3: Detect Drift\n\nRun drift detector filtered to your scope:\n```bash\n# Targeted: check specific docs\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --json\n\n# Full: all docs\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --since 30 --json\n```\n\nA doc is stale when it declares `source_of_truth_for` globs and commits\naffecting matching files exist AFTER its `synced_at` hash.\n\n---\n\n## Phase 4: Plan Delta\n\nBefore editing, identify:\n- Docs to update (within scope)\n- Docs to leave untouched\n- Collateral docs to report only (targeted mode)\n\n**If audit-only, stop here and output the report.**\n\n---\n\n## Phase 5: Execute Fixes\n\n- Update content + bump `version` + `updated` in frontmatter\n- After each doc update, stamp it:\n ```bash\n python3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py update-sync <doc-path>\n ```\n- Add CHANGELOG entry if warranted\n- Targeted mode: ONLY edit the named docs. Report others as suggestions.\n\n---\n\n## Phase 6: Validate\n\nRe-run both layers:\n```bash\nxtrm docs list --json\nxtrm docs cross-check --json --days 30\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --json\n```\n\nConfirm the updated docs no longer show as stale.\n",
37
+ "system": "You are a documentation sync specialist. You keep project docs in sync\nwith code reality using commit-based context gathering and explicit\nmode routing.\n\n---\n\n## Phase 0: Route Mode and Scope\n\nDetermine your operating mode BEFORE gathering any context:\n\n**Targeted mode** prompt contains explicit doc file paths (e.g. `docs/features.md docs/cli-reference.md`)\n - Edit ONLY the named docs\n - Gather recent commits/issues for context\n - Report collateral docs that likely also need updates, but do NOT edit them\n - Bead-linked runs execute directly\n\n**Area mode** prompt contains a time window AND a directory/source scope\n (e.g. \"sync docs/ for src/specialist/ changes in last 24h\")\n - Derive candidate docs from changed source paths within the time window\n - Use drift detector to confirm staleness\n - Edit candidate docs within derived scope\n\n**Full audit** no explicit targets or scope\n - Run full docs audit using drift detector + structure analyzer\n - Contextualize with recent commits/issues (NOT merged PRs)\n - Bead-linked runs execute; non-bead runs report only unless explicitly asked\n\n**Precedence rules:**\n1. Explicit doc paths in prompt targeted\n2. Time window + directory/source scope area\n3. Everything else full audit\n\n**Audit vs Execute:**\n- `$bead_id` present EXECUTE mode, all phases through Phase 6\n- No bead + \"audit\", \"check\", \"report\", \"what's stale\" STOP after Phase 4\n- No bead + \"update\", \"fix\", \"sync\" execute\n\n---\n\n## Phase 1: Gather Scoped Context\n\nUse `xtrm docs` commands for operator-facing inspection:\n```bash\nxtrm docs list --json\nxtrm docs show --json\nxtrm docs cross-check --json --days 30\n```\n\nThen gather deeper context with the context gatherer:\n```bash\n# Targeted: specific docs + time window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --doc docs/features.md --doc docs/cli-reference.md --since-hours 24\n\n# Area: source scope + time window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --scope-path src/specialist/ --since-hours 24\n\n# Full audit: broad window\npython3 .xtrm/skills/default/sync-docs/scripts/context_gatherer.py \\\n --since-days 7\n```\n\nThe gatherer outputs JSON with: recent commits, changed files, closed issues,\ncandidate docs, and drift status. Use this to understand WHAT changed and\nWHICH docs are affected.\n\n---\n\n## Phase 2: Inspect Docs State\n\nUse `xtrm docs` to answer:\n- What docs exist and their metadata?\n- Which have missing or outdated frontmatter?\n- Are there coverage gaps between recent work and docs?\n\nIf the CLI already isolates the problem clearly, skip to Phase 4.\n\n---\n\n## Phase 3: Detect Drift\n\nRun drift detector filtered to your scope:\n```bash\n# Targeted: check specific docs\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --json\n\n# Full: all docs\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --since 30 --json\n```\n\nA doc is stale when it declares `source_of_truth_for` globs and commits\naffecting matching files exist AFTER its `synced_at` hash.\n\n---\n\n## Phase 4: Plan Delta\n\nBefore editing, identify:\n- Docs to update (within scope)\n- Docs to leave untouched\n- Collateral docs to report only (targeted mode)\n\n**If audit-only, stop here and output the report.**\n\n---\n\n## Phase 5: Execute Fixes\n\n- Update content + bump `version` + `updated` in frontmatter\n- After each doc update, stamp it:\n ```bash\n python3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py update-sync <doc-path>\n ```\n- Add CHANGELOG entry if warranted\n- Targeted mode: ONLY edit the named docs. Report others as suggestions.\n\n---\n\n## Phase 6: Validate\n\nRe-run both layers:\n```bash\nxtrm docs list --json\nxtrm docs cross-check --json --days 30\npython3 .xtrm/skills/default/sync-docs/scripts/drift_detector.py scan --json\n```\n\nConfirm the updated docs no longer show as stale.\n",
37
38
  "task_template": "$prompt\n\n$pre_script_output\n\nWorking directory: $cwd\n\nBead context ID: $bead_id (empty = no bead linked)\nIf bead context ID is present, execute all phases and apply fixes directly.\nIf bead context ID is empty, report findings before making changes unless\nthe task explicitly asks for fixes.\n"
38
39
  },
39
40
  "skills": {
40
41
  "paths": [
41
- ".xtrm/skills/active/pi/sync-docs/",
42
- ".xtrm/skills/active/pi/gitnexus-exploring/SKILL.md"
42
+ ".xtrm/skills/active/sync-docs/",
43
+ ".xtrm/skills/active/gitnexus-exploring/SKILL.md"
43
44
  ],
44
45
  "scripts": [
45
46
  {
@@ -66,17 +67,12 @@
66
67
  "validation": {
67
68
  "files_to_watch": [
68
69
  "config/specialists/sync-docs.specialist.yaml",
69
- ".xtrm/skills/active/pi/sync-docs/SKILL.md",
70
+ ".xtrm/skills/active/sync-docs/SKILL.md",
70
71
  ".xtrm/skills/default/sync-docs/scripts/context_gatherer.py",
71
72
  ".xtrm/skills/default/sync-docs/scripts/drift_detector.py"
72
73
  ],
73
74
  "stale_threshold_days": 30
74
75
  },
75
- "communication": {
76
- "next_specialists": [
77
- "reviewer"
78
- ]
79
- },
80
76
  "output_file": ".specialists/sync-docs-report.md",
81
77
  "beads_integration": "auto",
82
78
  "stall_detection": {},
@@ -27,7 +27,8 @@
27
27
  },
28
28
  "mandatory_rules": {
29
29
  "template_sets": [
30
- "test-runner-execution-scope"
30
+ "test-runner-execution-scope",
31
+ "serena-cheatsheet"
31
32
  ]
32
33
  },
33
34
  "prompt": {
@@ -37,19 +38,14 @@
37
38
  "skills": {
38
39
  "scripts": [
39
40
  {
40
- "path": "bun --bun vitest run --reporter=verbose 2>&1 | tail -100",
41
41
  "phase": "pre",
42
- "inject_output": true
42
+ "inject_output": true,
43
+ "run": "bun --bun vitest run --reporter=verbose 2>&1 | tail -100"
43
44
  }
44
45
  ],
45
46
  "paths": []
46
47
  },
47
48
  "capabilities": {
48
- "diagnostic_scripts": [
49
- "bun --bun vitest run --reporter=verbose 2>&1 | tail -50",
50
- "cat vitest.config.ts",
51
- "cat package.json | grep -A5 '\"test\"'"
52
- ],
53
49
  "required_tools": [],
54
50
  "external_commands": []
55
51
  },
@@ -60,11 +56,6 @@
60
56
  ],
61
57
  "stale_threshold_days": 30
62
58
  },
63
- "communication": {
64
- "publishes": [
65
- "test_results"
66
- ]
67
- },
68
59
  "stall_detection": {},
69
60
  "beads_integration": "auto",
70
61
  "beads_write_notes": true
@@ -34,7 +34,7 @@
34
34
  },
35
35
  "skills": {
36
36
  "paths": [
37
- ".xtrm/skills/active/pi/xt-merge/SKILL.md"
37
+ ".xtrm/skills/active/xt-merge/SKILL.md"
38
38
  ],
39
39
  "scripts": []
40
40
  },
@@ -42,13 +42,11 @@
42
42
  "files_to_watch": [
43
43
  "src/specialist/schema.ts",
44
44
  "src/specialist/runner.ts",
45
- ".xtrm/skills/active/pi/xt-merge/SKILL.md"
45
+ ".xtrm/skills/active/xt-merge/SKILL.md"
46
46
  ],
47
47
  "stale_threshold_days": 30
48
48
  },
49
- "communication": {
50
- "output_to": ".specialists/merge-prs-result.md"
51
- },
49
+ "output_file": ".specialists/merge-prs-result.md",
52
50
  "capabilities": {
53
51
  "required_tools": [],
54
52
  "external_commands": []