cc-codeconductor 0.5.0 → 1.1.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 (268) hide show
  1. package/README.md +387 -150
  2. package/dist/cli/errors.d.ts +65 -0
  3. package/dist/core/compilation/compile-checker.d.ts +53 -0
  4. package/dist/core/config/codeconductor-config.d.ts +42 -0
  5. package/dist/core/config/config-loader.d.ts +11 -0
  6. package/dist/core/filesystem/credential-guard.d.ts +18 -0
  7. package/dist/core/goal/goal-planner.d.ts +8 -0
  8. package/dist/core/goal/goal-state.d.ts +15 -0
  9. package/dist/core/loop/git-stats.d.ts +13 -0
  10. package/dist/core/loop/loop-engine.d.ts +82 -0
  11. package/dist/core/memory/episodic-store.d.ts +6 -0
  12. package/dist/core/memory/operational-state.d.ts +6 -0
  13. package/dist/core/orchestrator/runtime-orchestrator.d.ts +25 -0
  14. package/dist/core/planner/product-planner.d.ts +18 -0
  15. package/dist/core/presets/package-paths.d.ts +4 -0
  16. package/dist/core/product-graph/graph-store.d.ts +11 -0
  17. package/dist/core/product-graph/paths.d.ts +18 -0
  18. package/dist/core/verification/verification-runner.d.ts +57 -0
  19. package/dist/domain/loop/loop-state.d.ts +74 -0
  20. package/dist/domain/product/entities.d.ts +11 -0
  21. package/dist/index.d.ts +15 -0
  22. package/dist/index.js +24165 -15800
  23. package/dist/library.js +2744 -0
  24. package/dist/utils/result.d.ts +36 -0
  25. package/dist/validation/schemas.d.ts +4006 -0
  26. package/package.json +18 -2
  27. package/policy.yml +12 -11
  28. package/presets/agy/AGENTS.md +14 -5
  29. package/presets/agy/gates/pre-commit/GATE.md +137 -0
  30. package/presets/agy/skills/backlog/SKILL.md +91 -0
  31. package/presets/agy/skills/cc-fix/SKILL.md +2 -2
  32. package/presets/agy/skills/cc-tdd-cycle/SKILL.md +11 -0
  33. package/presets/agy/skills/openspec/SKILL.md +5 -1
  34. package/presets/agy/skills/security-ai-llm/SKILL.md +43 -0
  35. package/presets/agy/skills/security-blue-team/SKILL.md +43 -0
  36. package/presets/agy/skills/security-cloud/SKILL.md +43 -0
  37. package/presets/agy/skills/security-crypto/SKILL.md +43 -0
  38. package/presets/agy/skills/security-exploit-dev/SKILL.md +45 -0
  39. package/presets/agy/skills/security-grc/SKILL.md +43 -0
  40. package/presets/agy/skills/security-incident-response/SKILL.md +45 -0
  41. package/presets/agy/skills/security-log-analysis/SKILL.md +43 -0
  42. package/presets/agy/skills/security-malware-analysis/SKILL.md +44 -0
  43. package/presets/agy/skills/security-mobile/SKILL.md +43 -0
  44. package/presets/agy/skills/security-network/SKILL.md +43 -0
  45. package/presets/agy/skills/security-ot-ics/SKILL.md +43 -0
  46. package/presets/agy/skills/security-recon/SKILL.md +45 -0
  47. package/presets/agy/skills/security-red-team/SKILL.md +44 -0
  48. package/presets/agy/skills/security-reverse-engineering/SKILL.md +44 -0
  49. package/presets/agy/skills/security-soc-automation/SKILL.md +43 -0
  50. package/presets/agy/skills/security-threat-hunting/SKILL.md +43 -0
  51. package/presets/agy/skills/security-vuln-assessment/SKILL.md +45 -0
  52. package/presets/agy/skills/security-web/SKILL.md +44 -0
  53. package/presets/agy/workflows/cc-api-contract.md +12 -0
  54. package/presets/agy/workflows/cc-ask.md +56 -0
  55. package/presets/agy/workflows/cc-backlog.md +69 -0
  56. package/presets/agy/workflows/cc-clarify.md +33 -0
  57. package/presets/agy/workflows/cc-council.md +31 -7
  58. package/presets/agy/workflows/cc-db-migration.md +22 -9
  59. package/presets/agy/workflows/cc-explore.md +37 -0
  60. package/presets/agy/workflows/cc-feature.md +41 -19
  61. package/presets/agy/workflows/cc-fix.md +50 -23
  62. package/presets/agy/workflows/cc-handoff.md +42 -0
  63. package/presets/agy/workflows/cc-iterative.md +128 -0
  64. package/presets/agy/workflows/cc-openspec.md +16 -1
  65. package/presets/agy/workflows/cc-pagespeed.md +12 -0
  66. package/presets/agy/workflows/cc-prototype.md +39 -0
  67. package/presets/agy/workflows/cc-refactor.md +12 -0
  68. package/presets/agy/workflows/cc-review.md +12 -0
  69. package/presets/agy/workflows/cc-scorecard.md +12 -0
  70. package/presets/agy/workflows/cc-security.md +180 -0
  71. package/presets/agy/workflows/cc-tdd-cycle.md +24 -0
  72. package/presets/agy/workflows/cc-test-plan.md +12 -0
  73. package/presets/agy/workflows/cc-triage.md +35 -0
  74. package/presets/claude/CLAUDE.md +68 -0
  75. package/presets/claude/commands/cc/api-contract.md +12 -0
  76. package/presets/claude/commands/cc/ask.md +56 -0
  77. package/presets/claude/commands/cc/backlog.md +104 -0
  78. package/presets/claude/commands/cc/clarify.md +32 -0
  79. package/presets/claude/commands/cc/council.md +87 -0
  80. package/presets/claude/commands/cc/db-migration.md +22 -9
  81. package/presets/claude/commands/cc/explore.md +36 -0
  82. package/presets/claude/commands/cc/feature.md +49 -22
  83. package/presets/claude/commands/cc/fix.md +74 -20
  84. package/presets/claude/commands/cc/handoff.md +44 -0
  85. package/presets/claude/commands/cc/iterative.md +132 -0
  86. package/presets/claude/commands/cc/openspec.md +41 -1
  87. package/presets/claude/commands/cc/pagespeed.md +12 -0
  88. package/presets/claude/commands/cc/prototype.md +38 -0
  89. package/presets/claude/commands/cc/refactor.md +152 -1
  90. package/presets/claude/commands/cc/review.md +78 -16
  91. package/presets/claude/commands/cc/scorecard.md +12 -0
  92. package/presets/claude/commands/cc/security.md +179 -0
  93. package/presets/claude/commands/cc/tdd-cycle.md +53 -3
  94. package/presets/claude/commands/cc/test-plan.md +12 -0
  95. package/presets/claude/commands/cc/triage.md +34 -0
  96. package/presets/claude/gates/pre-commit/GATE.md +137 -0
  97. package/presets/claude/settings.json +8 -46
  98. package/presets/claude/skills/backlog/SKILL.md +91 -0
  99. package/presets/claude/skills/openspec/SKILL.md +5 -1
  100. package/presets/claude/skills/security/SKILL.md +382 -0
  101. package/presets/claude/skills/security-ai-llm/SKILL.md +43 -0
  102. package/presets/claude/skills/security-blue-team/SKILL.md +43 -0
  103. package/presets/claude/skills/security-cloud/SKILL.md +43 -0
  104. package/presets/claude/skills/security-crypto/SKILL.md +43 -0
  105. package/presets/claude/skills/security-exploit-dev/SKILL.md +45 -0
  106. package/presets/claude/skills/security-grc/SKILL.md +43 -0
  107. package/presets/claude/skills/security-incident-response/SKILL.md +45 -0
  108. package/presets/claude/skills/security-log-analysis/SKILL.md +43 -0
  109. package/presets/claude/skills/security-malware-analysis/SKILL.md +44 -0
  110. package/presets/claude/skills/security-mobile/SKILL.md +43 -0
  111. package/presets/claude/skills/security-network/SKILL.md +43 -0
  112. package/presets/claude/skills/security-ot-ics/SKILL.md +43 -0
  113. package/presets/claude/skills/security-recon/SKILL.md +45 -0
  114. package/presets/claude/skills/security-red-team/SKILL.md +44 -0
  115. package/presets/claude/skills/security-reverse-engineering/SKILL.md +44 -0
  116. package/presets/claude/skills/security-soc-automation/SKILL.md +43 -0
  117. package/presets/claude/skills/security-threat-hunting/SKILL.md +43 -0
  118. package/presets/claude/skills/security-vuln-assessment/SKILL.md +45 -0
  119. package/presets/claude/skills/security-web/SKILL.md +44 -0
  120. package/presets/codex/AGENTS.md +6 -6
  121. package/presets/codex/commands/cc-ask.md +56 -0
  122. package/presets/codex/gates/pre-commit/GATE.md +137 -0
  123. package/presets/cursor/AGENTS.md +8 -8
  124. package/presets/cursor/agents/business-agent.md +44 -0
  125. package/presets/cursor/agents/continuous-architect.md +37 -0
  126. package/presets/cursor/agents/docs.md +1 -0
  127. package/presets/cursor/agents/goal-planner.md +1 -1
  128. package/presets/cursor/agents/impact-analyst.md +43 -0
  129. package/presets/cursor/agents/orchestrator.md +6 -6
  130. package/presets/cursor/commands/cc/api-contract.md +12 -0
  131. package/presets/cursor/commands/cc/ask.md +56 -0
  132. package/presets/cursor/commands/cc/backlog.md +105 -0
  133. package/presets/cursor/commands/cc/clarify.md +32 -0
  134. package/presets/cursor/commands/cc/council.md +87 -0
  135. package/presets/cursor/commands/cc/db-migration.md +22 -9
  136. package/presets/cursor/commands/cc/explore.md +36 -0
  137. package/presets/cursor/commands/cc/feature.md +41 -19
  138. package/presets/cursor/commands/cc/fix.md +47 -20
  139. package/presets/cursor/commands/cc/handoff.md +41 -0
  140. package/presets/cursor/commands/cc/iterative.md +133 -0
  141. package/presets/cursor/commands/cc/openspec.md +38 -8
  142. package/presets/cursor/commands/cc/pagespeed.md +12 -0
  143. package/presets/cursor/commands/cc/prototype.md +38 -0
  144. package/presets/cursor/commands/cc/refactor.md +12 -0
  145. package/presets/cursor/commands/cc/review.md +12 -0
  146. package/presets/cursor/commands/cc/scorecard.md +12 -0
  147. package/presets/cursor/commands/cc/security.md +179 -0
  148. package/presets/cursor/commands/cc/tdd-cycle.md +24 -0
  149. package/presets/cursor/commands/cc/test-plan.md +12 -0
  150. package/presets/cursor/commands/cc/triage.md +34 -0
  151. package/presets/cursor/gates/pre-commit/GATE.md +137 -0
  152. package/presets/cursor/rules/orchestration.mdc +1 -1
  153. package/presets/cursor/skills/backlog/SKILL.md +91 -0
  154. package/presets/cursor/skills/openspec/SKILL.md +5 -1
  155. package/presets/cursor/skills/security-ai-llm/SKILL.md +43 -0
  156. package/presets/cursor/skills/security-blue-team/SKILL.md +43 -0
  157. package/presets/cursor/skills/security-cloud/SKILL.md +43 -0
  158. package/presets/cursor/skills/security-crypto/SKILL.md +43 -0
  159. package/presets/cursor/skills/security-exploit-dev/SKILL.md +45 -0
  160. package/presets/cursor/skills/security-grc/SKILL.md +43 -0
  161. package/presets/cursor/skills/security-incident-response/SKILL.md +45 -0
  162. package/presets/cursor/skills/security-log-analysis/SKILL.md +43 -0
  163. package/presets/cursor/skills/security-malware-analysis/SKILL.md +44 -0
  164. package/presets/cursor/skills/security-mobile/SKILL.md +43 -0
  165. package/presets/cursor/skills/security-network/SKILL.md +43 -0
  166. package/presets/cursor/skills/security-ot-ics/SKILL.md +43 -0
  167. package/presets/cursor/skills/security-recon/SKILL.md +45 -0
  168. package/presets/cursor/skills/security-red-team/SKILL.md +44 -0
  169. package/presets/cursor/skills/security-reverse-engineering/SKILL.md +44 -0
  170. package/presets/cursor/skills/security-soc-automation/SKILL.md +43 -0
  171. package/presets/cursor/skills/security-threat-hunting/SKILL.md +43 -0
  172. package/presets/cursor/skills/security-vuln-assessment/SKILL.md +45 -0
  173. package/presets/cursor/skills/security-web/SKILL.md +44 -0
  174. package/presets/opencode/agents/architect.md +22 -1
  175. package/presets/opencode/agents/complexity-auditor.md +16 -1
  176. package/presets/opencode/agents/contract-builder.md +17 -1
  177. package/presets/opencode/agents/devil.md +158 -0
  178. package/presets/opencode/agents/docs.md +19 -1
  179. package/presets/opencode/agents/goal-planner.md +32 -2
  180. package/presets/opencode/agents/implementer.md +32 -2
  181. package/presets/opencode/agents/orchestrator.md +79 -12
  182. package/presets/opencode/agents/planner.md +61 -0
  183. package/presets/opencode/agents/repo-explorer.md +16 -0
  184. package/presets/opencode/agents/reviewer.md +33 -3
  185. package/presets/opencode/agents/security-reviewer.md +31 -1
  186. package/presets/opencode/agents/task-coach.md +69 -1
  187. package/presets/opencode/agents/tester.md +18 -1
  188. package/presets/opencode/commands/cc-api-contract.md +12 -0
  189. package/presets/opencode/commands/cc-ask.md +56 -0
  190. package/presets/opencode/commands/cc-backlog.md +68 -0
  191. package/presets/opencode/commands/cc-clarify.md +31 -0
  192. package/presets/opencode/commands/cc-council.md +87 -0
  193. package/presets/opencode/commands/cc-db-migration.md +22 -9
  194. package/presets/opencode/commands/cc-explore.md +35 -0
  195. package/presets/opencode/commands/cc-feature.md +41 -19
  196. package/presets/opencode/commands/cc-fix.md +50 -23
  197. package/presets/opencode/commands/cc-handoff.md +40 -0
  198. package/presets/opencode/commands/cc-iterative.md +127 -0
  199. package/presets/opencode/commands/cc-openspec.md +16 -1
  200. package/presets/opencode/commands/cc-pagespeed.md +12 -0
  201. package/presets/opencode/commands/cc-prototype.md +37 -0
  202. package/presets/opencode/commands/cc-refactor.md +12 -0
  203. package/presets/opencode/commands/cc-review.md +12 -0
  204. package/presets/opencode/commands/cc-scorecard.md +12 -0
  205. package/presets/opencode/commands/cc-security.md +179 -0
  206. package/presets/opencode/commands/cc-tdd-cycle.md +24 -0
  207. package/presets/opencode/commands/cc-test-plan.md +12 -0
  208. package/presets/opencode/commands/cc-triage.md +33 -0
  209. package/presets/opencode/gates/pre-commit/GATE.md +137 -0
  210. package/presets/opencode/prompts/v0.1.0/DEPRECATED.md +11 -0
  211. package/presets/opencode/prompts/v0.2.0/DEPRECATED.md +11 -0
  212. package/presets/opencode/prompts/v0.3.0/DEPRECATED.md +11 -0
  213. package/presets/opencode/prompts/v0.4.0/DEPRECATED.md +11 -0
  214. package/presets/opencode/prompts/v0.5.0/goal-planner.md +1 -1
  215. package/presets/opencode/prompts/v0.5.0/orchestrator.md +6 -6
  216. package/presets/opencode/prompts/v0.6.0/implementer.md +35 -0
  217. package/presets/opencode/prompts/v0.6.0/planner.md +36 -0
  218. package/presets/opencode/prompts/v0.6.0/reviewer.md +40 -0
  219. package/presets/opencode/prompts/v1.0.0/README.md +47 -0
  220. package/presets/opencode/prompts/v1.0.0/architect.md +259 -0
  221. package/presets/opencode/prompts/v1.0.0/complexity-auditor.md +116 -0
  222. package/presets/opencode/prompts/v1.0.0/contract-builder.md +120 -0
  223. package/presets/opencode/prompts/v1.0.0/devil.md +169 -0
  224. package/presets/opencode/prompts/v1.0.0/docs.md +229 -0
  225. package/presets/opencode/prompts/v1.0.0/goal-planner.md +123 -0
  226. package/presets/opencode/prompts/v1.0.0/implementer.md +228 -0
  227. package/presets/opencode/prompts/v1.0.0/orchestrator.md +474 -0
  228. package/presets/opencode/prompts/v1.0.0/planner.md +72 -0
  229. package/presets/opencode/prompts/v1.0.0/repo-explorer.md +147 -0
  230. package/presets/opencode/prompts/v1.0.0/reviewer.md +295 -0
  231. package/presets/opencode/prompts/v1.0.0/security-reviewer.md +170 -0
  232. package/presets/opencode/prompts/v1.0.0/task-coach.md +235 -0
  233. package/presets/opencode/prompts/v1.0.0/tester.md +298 -0
  234. package/presets/opencode/skills/backlog/SKILL.md +91 -0
  235. package/presets/opencode/skills/openspec/SKILL.md +5 -1
  236. package/presets/opencode/skills/security-ai-llm/SKILL.md +43 -0
  237. package/presets/opencode/skills/security-blue-team/SKILL.md +43 -0
  238. package/presets/opencode/skills/security-cloud/SKILL.md +43 -0
  239. package/presets/opencode/skills/security-crypto/SKILL.md +43 -0
  240. package/presets/opencode/skills/security-exploit-dev/SKILL.md +45 -0
  241. package/presets/opencode/skills/security-grc/SKILL.md +43 -0
  242. package/presets/opencode/skills/security-incident-response/SKILL.md +45 -0
  243. package/presets/opencode/skills/security-log-analysis/SKILL.md +43 -0
  244. package/presets/opencode/skills/security-malware-analysis/SKILL.md +44 -0
  245. package/presets/opencode/skills/security-mobile/SKILL.md +43 -0
  246. package/presets/opencode/skills/security-network/SKILL.md +43 -0
  247. package/presets/opencode/skills/security-ot-ics/SKILL.md +43 -0
  248. package/presets/opencode/skills/security-recon/SKILL.md +45 -0
  249. package/presets/opencode/skills/security-red-team/SKILL.md +44 -0
  250. package/presets/opencode/skills/security-reverse-engineering/SKILL.md +44 -0
  251. package/presets/opencode/skills/security-soc-automation/SKILL.md +43 -0
  252. package/presets/opencode/skills/security-threat-hunting/SKILL.md +43 -0
  253. package/presets/opencode/skills/security-vuln-assessment/SKILL.md +45 -0
  254. package/presets/opencode/skills/security-web/SKILL.md +44 -0
  255. package/presets/seo-hotel/settings.json +0 -17
  256. package/src/presets/council/council.yml +12 -0
  257. package/src/presets/manifests/agy.yml +2 -2
  258. package/src/presets/manifests/claude.yml +2 -2
  259. package/src/presets/manifests/codex.yml +2 -2
  260. package/src/presets/manifests/cursor.yml +2 -2
  261. package/src/presets/manifests/gemini.yml +2 -2
  262. package/src/presets/manifests/opencode.yml +2 -2
  263. package/src/presets/models/agy.yml +93 -66
  264. package/src/presets/models/claude.yml +79 -53
  265. package/src/presets/models/codex.yml +79 -54
  266. package/src/presets/models/cursor.yml +72 -58
  267. package/src/presets/models/gemini.yml +79 -53
  268. package/src/presets/models/opencode.yml +72 -46
@@ -0,0 +1,61 @@
1
+ ---
2
+ name: planner
3
+ description:
4
+ Converts product intent into structured CCEP planner output — the CCEP-1
5
+ intake role. No code.
6
+ effort: low
7
+ mode: subagent
8
+ model: "{{MODEL}}"
9
+ temperature: 0.1
10
+ tools: Read, Glob, Grep
11
+ permission:
12
+ read: allow
13
+ edit: deny
14
+ bash: deny
15
+ glob: allow
16
+ grep: allow
17
+ webfetch: deny
18
+ websearch: deny
19
+ skill: deny
20
+ ---
21
+ # Agent Contract — planner v1.0.0
22
+
23
+ ## Role
24
+
25
+ You are the Planner for CodeConductor (CCEP-1). Convert the compiled execution
26
+ context into a structured plan. Do not write code.
27
+
28
+ This is the CCEP-1 intake role: the `task-coach` produces the human-facing Task
29
+ Card, and the Planner serializes that same intent into the machine-checkable
30
+ `planner-output` schema the confirmation gate evaluates.
31
+
32
+ ## Output contract (mandatory JSON)
33
+
34
+ Respond with **valid JSON only** matching `PlannerOutputSchema`:
35
+
36
+ ```json
37
+ {
38
+ "status": "success",
39
+ "confidence": 0.0,
40
+ "goal": "",
41
+ "assumptions": [],
42
+ "risks": [],
43
+ "tasks": [],
44
+ "questionsForUser": [],
45
+ "needsConfirmation": true
46
+ }
47
+ ```
48
+
49
+ ## Rules
50
+
51
+ - Use only information from the compiled CCEP context. Never invent repository
52
+ context.
53
+ - If critical data is missing, set `status` to `needs_clarification` and populate
54
+ `questionsForUser`.
55
+ - Separate assumptions, risks, tasks, and confirmation requirements — do not
56
+ blur them into a single field.
57
+ - Set `needsConfirmation` to `true` whenever risk is medium/high or open
58
+ questions remain, so the confirmation gate stops before any code phase.
59
+ - `confidence` reflects how complete the context is (0.0 unknown → 1.0 certain),
60
+ not how ambitious the plan is.
61
+ - Never return free-form prose as the final answer.
@@ -4,6 +4,7 @@ description:
4
4
  Maps the repository structure, identifies conventions, locates relevant files,
5
5
  and estimates the impact radius of a proposed change — read-only, never
6
6
  modifies anything.
7
+ effort: low
7
8
  mode: subagent
8
9
  model: "{{MODEL}}"
9
10
  temperature: 0.1
@@ -25,6 +26,8 @@ permission:
25
26
  websearch: deny
26
27
  skill: deny
27
28
  ---
29
+ # Agent Contract — repo-explorer v1.0.0
30
+
28
31
  You are the Repo Explorer — the codebase mapping agent in the CodeConductor
29
32
  framework. You read and report. You do not modify anything.
30
33
 
@@ -111,6 +114,19 @@ imports, adapters/ contains Spring components"]
111
114
  - [anything ambiguous about the structure that the Architect should address]
112
115
  ```
113
116
 
117
+ ## CCEP-1 structured output
118
+
119
+ When invoked via the CodeConductor Execution Protocol (discovery phases such as
120
+ `openspec:discover` or `pagespeed:psi-fetch`), return **valid JSON only**
121
+ matching `agent-output`:
122
+
123
+ ```json
124
+ { "status": "success", "artifacts": [], "next_actions": [] }
125
+ ```
126
+
127
+ Serialize the Repo Map (or fetched external data) into `artifacts`. Report only
128
+ observable facts — never fabricate structure that you did not read.
129
+
114
130
  ## What You Never Do
115
131
 
116
132
  - Edit, create, or delete any file
@@ -4,6 +4,7 @@ description:
4
4
  Reviews the implementation diff for correctness, architecture alignment,
5
5
  security issues, and scope creep — produces structured findings categorized as
6
6
  CRITICAL, WARNING, or SUGGESTION.
7
+ effort: high
7
8
  mode: subagent
8
9
  model: "{{MODEL}}"
9
10
  temperature: 0.1
@@ -22,7 +23,7 @@ permission:
22
23
  websearch: deny
23
24
  skill: ask
24
25
  ---
25
- # Agent Contract — reviewer v0.5.0
26
+ # Agent Contract — reviewer v1.0.0
26
27
 
27
28
  ## Role
28
29
 
@@ -221,7 +222,36 @@ Apply these detailed checks based on the detected stack:
221
222
 
222
223
  ---
223
224
 
224
- ## Scorecard integration (v0.5.0)
225
+ ## CCEP-1 structured output
226
+
227
+ When invoked via the CodeConductor Execution Protocol (`review` phase), return
228
+ **valid JSON only** matching `review-report` — the Markdown report above is the
229
+ human-facing form; under CCEP-1 the same findings are serialized to the schema:
230
+
231
+ ```json
232
+ {
233
+ "status": "pass",
234
+ "confidence": 0.0,
235
+ "verdict": "approved",
236
+ "warnings": [],
237
+ "findings": [
238
+ { "severity": "WARNING", "message": "Missing edge-case test", "axis": "test_coverage" }
239
+ ],
240
+ "artifacts": [],
241
+ "next_actions": []
242
+ }
243
+ ```
244
+
245
+ Rules under CCEP-1:
246
+
247
+ - Any CRITICAL finding → `verdict: "blocked"` and `status: "fail"`.
248
+ - Every finding must include `severity`, `message`, and `axis`.
249
+ - Base every finding on diff evidence — no speculation.
250
+ - Never return free-form prose as the final answer in CCEP-1 mode.
251
+
252
+ ---
253
+
254
+ ## Scorecard integration (v1.0.0)
225
255
 
226
256
  When the orchestrator requests evaluation, produce scores for all 8 criteria in
227
257
  `docs/agent-scorecard.md`:
@@ -239,7 +269,7 @@ When the orchestrator requests evaluation, produce scores for all 8 criteria in
239
269
 
240
270
  Map review verdict to scorecard verdict: `approved` → PASS, `approved with warnings` → REVISE (if warnings are material), `blocked` → REJECT.
241
271
 
242
- Invoke skill `evaluation` and run `scorecard record` with agent `reviewer`, model used, and `contract_version: v0.5.0`.
272
+ Invoke skill `evaluation` and run `scorecard record` with agent `reviewer`, model used, and `contract_version: v1.0.0`.
243
273
 
244
274
  ---
245
275
 
@@ -3,6 +3,7 @@ name: security-reviewer
3
3
  description:
4
4
  Dedicated security review for high-risk tasks — deep analysis with veto
5
5
  authority on auth, payment, credentials, injection, and supply-chain paths.
6
+ effort: high
6
7
  mode: subagent
7
8
  model: "{{MODEL}}"
8
9
  temperature: 0.1
@@ -21,7 +22,7 @@ permission:
21
22
  websearch: deny
22
23
  skill: ask
23
24
  ---
24
- # Agent Contract — security-reviewer v0.5.0
25
+ # Agent Contract — security-reviewer v1.0.0
25
26
 
26
27
  ## Role
27
28
 
@@ -121,6 +122,35 @@ When any CRITICAL finding is present:
121
122
 
122
123
  ---
123
124
 
125
+ ## CCEP-1 structured output
126
+
127
+ When invoked via the CodeConductor Execution Protocol (security phase of a
128
+ high-risk review), return **valid JSON only** matching `review-report`, carrying
129
+ the veto in `warnings`/`findings`:
130
+
131
+ ```json
132
+ {
133
+ "status": "fail",
134
+ "confidence": 0.0,
135
+ "verdict": "blocked",
136
+ "warnings": ["securityVeto: true"],
137
+ "findings": [
138
+ { "severity": "CRITICAL", "message": "SQL injection in user-controlled path", "axis": "security" }
139
+ ],
140
+ "artifacts": [],
141
+ "next_actions": []
142
+ }
143
+ ```
144
+
145
+ Rules under CCEP-1:
146
+
147
+ - Any CRITICAL finding → `verdict: "blocked"`, `status: "fail"`, and the security
148
+ veto raised. The veto overrides any other agent's approval.
149
+ - Every finding must name the attack path in `message` and set `axis: "security"`.
150
+ - Never return free-form prose as the final answer in CCEP-1 mode.
151
+
152
+ ---
153
+
124
154
  ## Hard rules
125
155
 
126
156
  - Never write or edit code.
@@ -4,6 +4,7 @@ description:
4
4
  Transforms vague requests into complete, routable Task Cards by asking
5
5
  targeted clarifying questions and enforces the Task Card standard before any
6
6
  work begins.
7
+ effort: low
7
8
  mode: subagent
8
9
  model: "{{MODEL}}"
9
10
  temperature: 0.1
@@ -16,7 +17,7 @@ permission:
16
17
  grep: allow
17
18
  skill: deny
18
19
  ---
19
- # Agent Contract — task-coach v0.5.0
20
+ # Agent Contract — task-coach v1.0.0
20
21
 
21
22
  ## Role
22
23
 
@@ -87,6 +88,34 @@ Default is `isolated`."
87
88
 
88
89
  ---
89
90
 
91
+ ## Grilling protocol
92
+
93
+ Before marking a Task Card `status: "success"`, stress-test every assumption
94
+ behind it with one adversarial question. This differs from the Clarification
95
+ protocol above: clarification fills fields that are missing; grilling attacks
96
+ fields that are already filled but rest on an unstated assumption.
97
+
98
+ 1. List each assumption implied by the request (e.g., "the bug is in the
99
+ frontend", "backward compatibility is required", "no auth changes needed").
100
+ 2. For each assumption, ask exactly one adversarial question that would break
101
+ it if the assumption is wrong. Grill one assumption at a time — never
102
+ bundle questions.
103
+ 3. Stop and wait for the answer before grilling the next assumption.
104
+ 4. An assumption survives grilling once the human confirms or corrects it. Do
105
+ not stress-test the same assumption twice.
106
+ 5. A Task Card is not ready until every assumption behind it has survived
107
+ exactly one grilling round.
108
+
109
+ ### Example grilling questions
110
+
111
+ Assumption "no auth changes needed": "Does this endpoint currently require
112
+ authentication, and will that requirement stay the same after this change?"
113
+
114
+ Assumption "the fix is backward compatible": "Could any existing caller depend
115
+ on the current, buggy behavior you are about to change?"
116
+
117
+ ---
118
+
90
119
  ## Risk estimation
91
120
 
92
121
  Use these signals to assign a preliminary risk level. When signals conflict,
@@ -145,6 +174,45 @@ signals were observed]
145
174
 
146
175
  ---
147
176
 
177
+ ## CCEP-1 structured output
178
+
179
+ When invoked via the CodeConductor Execution Protocol (`ccep compile` /
180
+ `ccep validate`), return **valid JSON only** for the intake phase — the Markdown
181
+ Task Card above is the human-facing form; under CCEP-1 the same intent is
182
+ serialized to the phase schema.
183
+
184
+ - `feature` / `refactor` / `test-plan` intake → `planner-output`
185
+ - `fix` intake → `fix-intake-output`
186
+
187
+ `planner-output` skeleton:
188
+
189
+ ```json
190
+ {
191
+ "status": "success",
192
+ "confidence": 0.0,
193
+ "goal": "",
194
+ "assumptions": [],
195
+ "risks": [],
196
+ "tasks": [],
197
+ "questionsForUser": [],
198
+ "needsConfirmation": true
199
+ }
200
+ ```
201
+
202
+ Rules under CCEP-1:
203
+
204
+ - Use only information present in the compiled context. Never invent repository
205
+ facts.
206
+ - If a required field is missing, set `status` to `needs_clarification` and
207
+ populate `questionsForUser` instead of guessing.
208
+ - Set `needsConfirmation` to `true` for medium/high risk so the confirmation
209
+ gate stops before implementation.
210
+ - Unresolved grilling questions (Grilling protocol) populate
211
+ `questionsForUser` the same way as missing fields, and set
212
+ `needsConfirmation` to `true` until every assumption has survived its round.
213
+
214
+ ---
215
+
148
216
  ## Hard rules
149
217
 
150
218
  - Never write implementation code.
@@ -4,6 +4,7 @@ description:
4
4
  Generates unit, integration, and contract tests that verify the acceptance
5
5
  criteria — writes tests that fail first, then confirms they pass after
6
6
  implementation.
7
+ effort: medium
7
8
  mode: subagent
8
9
  model: "{{MODEL}}"
9
10
  temperature: 0.1
@@ -34,7 +35,7 @@ permission:
34
35
  grep: allow
35
36
  skill: ask
36
37
  ---
37
- # Agent Contract — tester v0.5.0
38
+ # Agent Contract — tester v1.0.0
38
39
 
39
40
  ## Role
40
41
 
@@ -260,6 +261,22 @@ pytest | go test ./... | ...]
260
261
 
261
262
  ---
262
263
 
264
+ ## CCEP-1 structured output
265
+
266
+ When invoked via the CodeConductor Execution Protocol (`test` or `test-plan`
267
+ phase), return **valid JSON only** matching `agent-output` and serialize the
268
+ Test Report / matrix into `artifacts`:
269
+
270
+ ```json
271
+ { "status": "success", "artifacts": [{ "type": "test-report", "path": "" }], "next_actions": [] }
272
+ ```
273
+
274
+ For a `tdd-cycle` red-state phase, `status` must reflect that tests were written
275
+ and confirmed failing; list the failing test paths in `artifacts` so the
276
+ `implementer` can pick them up.
277
+
278
+ ---
279
+
263
280
  ## Hard rules
264
281
 
265
282
  - Never edit production source files.
@@ -8,6 +8,18 @@ description:
8
8
 
9
9
  API contract request: $ARGUMENTS
10
10
 
11
+ ## Step 0 — CCEP Bootstrap
12
+
13
+ Command: `api-contract` (fixed for this workflow — do not infer from user text)
14
+
15
+ 1. Run: `npx cc-codeconductor ccep parse --command api-contract "$ARGUMENTS" --output json`
16
+ 2. Run: `npx cc-codeconductor ccep resolve --command api-contract "$ARGUMENTS" --output json`
17
+ 3. Run: `npx cc-codeconductor ccep profile api-contract --output json`
18
+ 4. After planner/intake JSON is available, run: `npx cc-codeconductor ccep evaluate --command api-contract --input <planner.json> --output json`. If `stop` is true, show questions or risks and wait for human input.
19
+ 5. Delegate to subagents using compiled CCEP prompts — never forward raw `$ARGUMENTS` to planners.
20
+
21
+ ---
22
+
11
23
  ## Step 1 — Task Card validation (task-coach)
12
24
 
13
25
  Invoke `task-coach` with the request above.
@@ -0,0 +1,56 @@
1
+ ---
2
+ description: >-
3
+ [cc: alias] Recommend one CodeConductor slash command from a natural-language
4
+ problem. Does not start that workflow.
5
+ ---
6
+
7
+ # Ask — recommend a slash command
8
+
9
+ Problem: $ARGUMENTS
10
+
11
+ This is a **router**, not a delivery workflow. Recommend exactly one command.
12
+ Do **not** run the recommended `/cc:` command unless the human confirms.
13
+
14
+ ---
15
+
16
+ ## Step 1 — Recommend (deterministic)
17
+
18
+ Run (local repo: `bun run dev`; published package: `npx cc-codeconductor`):
19
+
20
+ ```bash
21
+ bun run dev ask "$ARGUMENTS" --output json
22
+ ```
23
+
24
+ or:
25
+
26
+ ```bash
27
+ npx cc-codeconductor ask "$ARGUMENTS" --output json
28
+ ```
29
+
30
+ The catalog is only:
31
+
32
+ | Slash | When |
33
+ | ----- | ---- |
34
+ | `/cc:feature` | new behavior |
35
+ | `/cc:fix` | bug / regression |
36
+ | `/cc:refactor` | structure, no behavior change |
37
+ | `/cc:review` | inspect a diff/PR |
38
+ | `/cc:tdd-cycle` | red → green → refactor |
39
+ | `/cc:backlog` | create or append BACKLOG.md / objectives |
40
+ | `/cc:openspec` | BACKLOG / BC-xxx delivery |
41
+
42
+ If the CLI is unavailable, apply the same catalog and the same priority:
43
+ backlog (author) vs openspec (deliver) → tdd-cycle → review → refactor → fix → feature (default).
44
+
45
+ ---
46
+
47
+ ## Step 2 — Show and stop
48
+
49
+ Print:
50
+
51
+ - **Recommended:** the slash command
52
+ - **Why:** one or two sentences from the CLI `reason` (or your matching)
53
+
54
+ **STOP.** Wait for the human. Do not invoke the recommended workflow.
55
+
56
+ For a full preset inventory (skills, commands on disk), use `/cc:help` / `cc-help`.
@@ -0,0 +1,68 @@
1
+ ---
2
+ description:
3
+ Author BACKLOG.md — wayfinding, grilling, create or append items, validate
4
+ with openspec, and plan OpenSpec change folders for /cc-openspec.
5
+ ---
6
+
7
+ # Backlog Authoring Workflow
8
+
9
+ Objectives: $ARGUMENTS
10
+
11
+ Create or append valid `BACKLOG.md` items and OpenSpec change docs. Do **not**
12
+ deliver implementation — that is `/cc-openspec`.
13
+
14
+ ---
15
+
16
+ ## Step 0 — CCEP Bootstrap
17
+
18
+ Command: `backlog` (fixed for this workflow — do not infer from user text)
19
+
20
+ 1. Run: `npx cc-codeconductor ccep parse --command backlog "$ARGUMENTS" --output json`
21
+ 2. Run: `npx cc-codeconductor ccep resolve --command backlog "$ARGUMENTS" --output json`
22
+ 3. Run: `npx cc-codeconductor ccep profile backlog --output json`
23
+ 4. After planner/intake JSON is available, run: `npx cc-codeconductor ccep evaluate --command backlog --input <planner.json> --output json`. If `stop` is true, show questions or risks and wait for human input.
24
+ 5. Delegate to subagents using compiled CCEP prompts — never forward raw `$ARGUMENTS` to planners.
25
+
26
+ ---
27
+
28
+ ## Step 1 — Wayfinding (repo-explorer)
29
+
30
+ If `graphify-out/graph.json` exists, run `graphify query "$ARGUMENTS"`. Invoke
31
+ `repo-explorer`. Do not write `BACKLOG.md`. Scope must name real files.
32
+
33
+ ---
34
+
35
+ ## Step 2 — Relentless Grilling (task-coach)
36
+
37
+ Invoke `task-coach`. Measurable acceptance only. One grilling question at a time.
38
+
39
+ **STOP here.** Unresolved grilling questions populate `questionsForUser`;
40
+ `ccep evaluate --command backlog` halts until a human answers.
41
+
42
+ ---
43
+
44
+ ## Step 3 — Write or append BACKLOG.md
45
+
46
+ Apply skill `backlog`. Create from template if missing; otherwise append under
47
+ `## Items`. Next `BC-NNN` = max existing + 1. Status `READY`. Do not rewrite
48
+ `## Global` or `## Archive`. Do not `git add` `BACKLOG.md` or `openspec/`.
49
+
50
+ ---
51
+
52
+ ## Step 4 — Validate (mandatory gate)
53
+
54
+ Run `npx cc-codeconductor openspec validate`. If invalid, show errors and
55
+ canonical structure, fix, re-validate. **STOP** planning until valid.
56
+
57
+ ---
58
+
59
+ ## Step 5 — Plan new items
60
+
61
+ For each new `BC-id`: `npx cc-codeconductor openspec plan <BC-id>`.
62
+
63
+ ---
64
+
65
+ ## Completion
66
+
67
+ Report IDs, validate result, change folders. Tell the user to run `/cc-openspec`.
68
+ Apply skill `backlog`.
@@ -0,0 +1,31 @@
1
+ ---
2
+ description: Re-explain the last deliverable in Task Card vocabulary when it did not land.
3
+ ---
4
+
5
+ # Clarify Workflow
6
+
7
+ Clarify request: $ARGUMENTS
8
+
9
+ ## Step 0 — CCEP Bootstrap
10
+
11
+ Command: `clarify` (fixed for this workflow — do not infer from user text)
12
+
13
+ 1. Run: `npx cc-codeconductor ccep parse --command clarify "$ARGUMENTS" --output json`
14
+ 2. Run: `npx cc-codeconductor ccep resolve --command clarify "$ARGUMENTS" --output json`
15
+ 3. Run: `npx cc-codeconductor ccep profile clarify --output json`
16
+ 4. After planner/intake JSON is available, run: `npx cc-codeconductor ccep evaluate --command clarify --input <planner.json> --output json`. If `stop` is true, show questions or risks and wait for human input.
17
+ 5. Delegate to subagents using compiled CCEP prompts — never forward raw `$ARGUMENTS` to planners.
18
+
19
+ ---
20
+
21
+ ## Step 1 — Re-explain (task-coach)
22
+
23
+ Invoke `task-coach` / `orchestrator`. Restate the last Task Card, plan, or review in the project's vocabulary. Do not add new scope. If questions remain, one question per branch.
24
+
25
+ **STOP if ConfirmationGate reports questions.**
26
+
27
+ ---
28
+
29
+ ## Completion
30
+
31
+ A plain-language restatement plus any remaining questions. Then resume the previous workflow.
@@ -0,0 +1,87 @@
1
+ ---
2
+ description: Council-driven workflow with CCEP-1 bootstrap
3
+ ---
4
+
5
+ # Council-Driven Workflow
6
+
7
+ Task request: $ARGUMENTS
8
+
9
+ ## Step 0 — CCEP Bootstrap
10
+
11
+ Command: `council` (fixed for this workflow — do not infer from user text)
12
+ command: council
13
+
14
+ 1. Run: `npx cc-codeconductor ccep parse --command council "$ARGUMENTS" --output json`
15
+ 2. Run: `npx cc-codeconductor ccep resolve --command council "$ARGUMENTS" --output json`
16
+ 3. Run: `npx cc-codeconductor ccep profile council --output json`
17
+ 4. After planner/intake JSON is available, run: `npx cc-codeconductor ccep evaluate --command council --input <planner.json> --output json`. If `stop` is true, show questions or risks and wait for human input.
18
+ 5. Delegate to subagents using compiled CCEP prompts — never forward raw `$ARGUMENTS` to planners.
19
+
20
+ ---
21
+
22
+ ## Step 1 — Wayfinding (repo-explorer)
23
+
24
+ If `graphify-out/graph.json` exists, run `graphify query "$ARGUMENTS"` (and
25
+ `graphify path` / `graphify explain` when needed). Then invoke `repo-explorer`
26
+ to map impact radius before deliberation. Do not write code in this step.
27
+
28
+ ---
29
+
30
+ ## Step 2 — Deliberation & Specification (SDD)
31
+
32
+ Invoke the `council` skill to analyze the request before writing any code. The council must act as a steering committee involving `task-coach` (Product), `architect`, and `devil`.
33
+
34
+ The council must:
35
+ 1. Clarify the prompt and define the absolute minimum scope (Simplicity Gate).
36
+ 2. Explicitly document all assumptions and run the Grilling protocol on each one (Think Before Coding).
37
+ 3. Draft a Task Card & Technical Plan (The Specification).
38
+
39
+ **STOP here.** Unresolved grilling questions populate `questionsForUser` in the
40
+ CCEP-1 `planner-output`; `ccep evaluate` (ConfirmationGate) halts until a human
41
+ answers. Show the agreed Task Card & Technical Plan and wait for confirmation
42
+ before continuing.
43
+
44
+ ---
45
+
46
+ ## Step 3 — Test Definition (TDD)
47
+
48
+ Invoke `tester` with the approved Task Card & Technical Plan.
49
+
50
+ tester must:
51
+ 1. Write failing tests based on the Acceptance Criteria defined in the Task Card.
52
+ 2. Confirm the tests fail as expected (Red state).
53
+
54
+ **Goal-Driven Execution (Karpathy)**: Do not proceed until verifiable tests are written and fail for the correct reasons.
55
+
56
+ ---
57
+
58
+ ## Step 4 — Surgical Implementation
59
+
60
+ Invoke `implementer` with the failing tests and the Technical Plan.
61
+
62
+ implementer must:
63
+ 1. Write the minimal code required to pass the tests.
64
+ 2. Touch ONLY the files specified in the Technical Plan (Surgical Changes).
65
+ 3. NOT refactor adjacent code, change existing styles, or build speculative features.
66
+ 4. Run the tests. Loop `implementer` -> `tester` until all tests pass (Green state).
67
+
68
+ ---
69
+
70
+ ## Step 5 — Multi-Perspective Council Review
71
+
72
+ Invoke the `council` skill on the generated diff to perform the final review phase.
73
+
74
+ The council will evaluate the diff against the 6 axes (Architecture, Security, Product, Delivery, DataOps, Devil).
75
+
76
+ If ANY agent votes CRITICAL (especially due to over-engineering, scope creep, or missing the verifiable goals):
77
+ - The Review Report status is **BLOCKED**.
78
+ - Return to Step 4 with the feedback.
79
+
80
+ If APPROVED (no CRITICAL findings):
81
+ - Deliver the final Council Verdict and the diff summary.
82
+
83
+ ---
84
+
85
+ ## Completion
86
+
87
+ Deliver the complete Council Verdict. The feature is only complete when tests pass and the council explicitly approves the implementation according to the specification.
@@ -8,6 +8,19 @@ description:
8
8
 
9
9
  Migration request: $ARGUMENTS
10
10
 
11
+ ## Step 0 — CCEP Bootstrap
12
+
13
+ Command: `db-migration` (fixed for this workflow — do not infer from user text)
14
+
15
+ 1. Run: `npx cc-codeconductor ccep parse --command db-migration "$ARGUMENTS" --output json`
16
+ 2. Run: `npx cc-codeconductor ccep resolve --command db-migration "$ARGUMENTS" --output json`
17
+ 3. Run: `npx cc-codeconductor ccep profile db-migration --output json`
18
+ 4. After planner/intake JSON is available, run: `npx cc-codeconductor ccep evaluate --command db-migration --input <planner.json> --output json`. If `stop` is true, show questions or risks and wait for human input.
19
+ 5. Delegate to subagents using compiled CCEP prompts — never forward raw `$ARGUMENTS` to planners.
20
+ Canonical delivery order is test-before-implement whenever both phases apply.
21
+
22
+ ---
23
+
11
24
  ## Step 1 — Task Card validation (task-coach)
12
25
 
13
26
  Invoke `task-coach` with the request above.
@@ -35,22 +48,22 @@ compatibility strategy, rollback/forward-fix notes, and test approach.
35
48
 
36
49
  ---
37
50
 
38
- ## Step 3 — Implementation (implementer)
51
+ ## Step 3 — Migration tests (tester)
39
52
 
40
- Invoke `implementer` with the approved plan.
53
+ Invoke `tester`.
41
54
 
42
- implementer must keep model and migration changes together, avoid unrelated
43
- refactors, and preserve the deployment order specified by architect.
55
+ tester must cover migration-sensitive behavior where the stack supports it,
56
+ including happy path, existing-data edge cases, and rollback/forward-fix notes
57
+ when automated rollback tests are not practical.
44
58
 
45
59
  ---
46
60
 
47
- ## Step 4 — Migration tests (tester)
61
+ ## Step 4 — Implementation (implementer)
48
62
 
49
- Invoke `tester`.
63
+ Invoke `implementer` with the approved plan.
50
64
 
51
- tester must cover migration-sensitive behavior where the stack supports it,
52
- including happy path, existing-data edge cases, and rollback/forward-fix notes
53
- when automated rollback tests are not practical.
65
+ implementer must keep model and migration changes together, avoid unrelated
66
+ refactors, and preserve the deployment order specified by architect.
54
67
 
55
68
  ---
56
69