create-claude-cabinet 0.6.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 (135) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +196 -0
  3. package/bin/create-claude-cabinet.js +8 -0
  4. package/lib/cli.js +624 -0
  5. package/lib/copy.js +152 -0
  6. package/lib/db-setup.js +51 -0
  7. package/lib/metadata.js +42 -0
  8. package/lib/reset.js +193 -0
  9. package/lib/settings-merge.js +93 -0
  10. package/package.json +29 -0
  11. package/templates/EXTENSIONS.md +311 -0
  12. package/templates/README.md +485 -0
  13. package/templates/briefing/_briefing-api-template.md +21 -0
  14. package/templates/briefing/_briefing-architecture-template.md +16 -0
  15. package/templates/briefing/_briefing-cabinet-template.md +20 -0
  16. package/templates/briefing/_briefing-identity-template.md +18 -0
  17. package/templates/briefing/_briefing-scopes-template.md +39 -0
  18. package/templates/briefing/_briefing-template.md +148 -0
  19. package/templates/briefing/_briefing-work-tracking-template.md +18 -0
  20. package/templates/cabinet/committees-template.yaml +49 -0
  21. package/templates/cabinet/composition-patterns.md +240 -0
  22. package/templates/cabinet/eval-protocol.md +208 -0
  23. package/templates/cabinet/lifecycle.md +93 -0
  24. package/templates/cabinet/output-contract.md +148 -0
  25. package/templates/cabinet/prompt-guide.md +266 -0
  26. package/templates/hooks/cor-upstream-guard.sh +79 -0
  27. package/templates/hooks/git-guardrails.sh +67 -0
  28. package/templates/hooks/skill-telemetry.sh +66 -0
  29. package/templates/hooks/skill-tool-telemetry.sh +54 -0
  30. package/templates/hooks/stop-hook.md +56 -0
  31. package/templates/memory/patterns/_pattern-template.md +119 -0
  32. package/templates/memory/patterns/pattern-intelligence-first.md +41 -0
  33. package/templates/rules/enforcement-pipeline.md +151 -0
  34. package/templates/scripts/cor-drift-check.cjs +84 -0
  35. package/templates/scripts/finding-schema.json +94 -0
  36. package/templates/scripts/load-triage-history.js +151 -0
  37. package/templates/scripts/merge-findings.js +126 -0
  38. package/templates/scripts/pib-db-schema.sql +68 -0
  39. package/templates/scripts/pib-db.js +365 -0
  40. package/templates/scripts/triage-server.mjs +98 -0
  41. package/templates/scripts/triage-ui.html +536 -0
  42. package/templates/skills/audit/SKILL.md +273 -0
  43. package/templates/skills/audit/phases/finding-output.md +56 -0
  44. package/templates/skills/audit/phases/member-execution.md +83 -0
  45. package/templates/skills/audit/phases/member-selection.md +44 -0
  46. package/templates/skills/audit/phases/structural-checks.md +54 -0
  47. package/templates/skills/audit/phases/triage-history.md +45 -0
  48. package/templates/skills/cabinet-accessibility/SKILL.md +180 -0
  49. package/templates/skills/cabinet-anti-confirmation/SKILL.md +172 -0
  50. package/templates/skills/cabinet-architecture/SKILL.md +279 -0
  51. package/templates/skills/cabinet-boundary-man/SKILL.md +265 -0
  52. package/templates/skills/cabinet-cor-health/SKILL.md +342 -0
  53. package/templates/skills/cabinet-data-integrity/SKILL.md +157 -0
  54. package/templates/skills/cabinet-debugger/SKILL.md +221 -0
  55. package/templates/skills/cabinet-historian/SKILL.md +253 -0
  56. package/templates/skills/cabinet-organized-mind/SKILL.md +338 -0
  57. package/templates/skills/cabinet-process-therapist/SKILL.md +261 -0
  58. package/templates/skills/cabinet-qa/SKILL.md +205 -0
  59. package/templates/skills/cabinet-record-keeper/SKILL.md +168 -0
  60. package/templates/skills/cabinet-roster-check/SKILL.md +297 -0
  61. package/templates/skills/cabinet-security/SKILL.md +181 -0
  62. package/templates/skills/cabinet-small-screen/SKILL.md +154 -0
  63. package/templates/skills/cabinet-speed-freak/SKILL.md +169 -0
  64. package/templates/skills/cabinet-system-advocate/SKILL.md +194 -0
  65. package/templates/skills/cabinet-technical-debt/SKILL.md +115 -0
  66. package/templates/skills/cabinet-usability/SKILL.md +189 -0
  67. package/templates/skills/cabinet-workflow-cop/SKILL.md +238 -0
  68. package/templates/skills/cor-upgrade/SKILL.md +302 -0
  69. package/templates/skills/debrief/SKILL.md +409 -0
  70. package/templates/skills/debrief/phases/auto-maintenance.md +48 -0
  71. package/templates/skills/debrief/phases/close-work.md +88 -0
  72. package/templates/skills/debrief/phases/health-checks.md +54 -0
  73. package/templates/skills/debrief/phases/inventory.md +40 -0
  74. package/templates/skills/debrief/phases/loose-ends.md +52 -0
  75. package/templates/skills/debrief/phases/record-lessons.md +67 -0
  76. package/templates/skills/debrief/phases/report.md +59 -0
  77. package/templates/skills/debrief/phases/update-state.md +48 -0
  78. package/templates/skills/debrief/phases/upstream-feedback.md +129 -0
  79. package/templates/skills/debrief-quick/SKILL.md +12 -0
  80. package/templates/skills/execute/SKILL.md +293 -0
  81. package/templates/skills/execute/phases/cabinet.md +49 -0
  82. package/templates/skills/execute/phases/commit-and-deploy.md +66 -0
  83. package/templates/skills/execute/phases/load-plan.md +49 -0
  84. package/templates/skills/execute/phases/validators.md +50 -0
  85. package/templates/skills/execute/phases/verification-tools.md +67 -0
  86. package/templates/skills/extract/SKILL.md +168 -0
  87. package/templates/skills/investigate/SKILL.md +160 -0
  88. package/templates/skills/link/SKILL.md +52 -0
  89. package/templates/skills/menu/SKILL.md +61 -0
  90. package/templates/skills/onboard/SKILL.md +356 -0
  91. package/templates/skills/onboard/phases/detect-state.md +79 -0
  92. package/templates/skills/onboard/phases/generate-briefing.md +127 -0
  93. package/templates/skills/onboard/phases/generate-session-loop.md +87 -0
  94. package/templates/skills/onboard/phases/interview.md +233 -0
  95. package/templates/skills/onboard/phases/modularity-menu.md +162 -0
  96. package/templates/skills/onboard/phases/options.md +98 -0
  97. package/templates/skills/onboard/phases/post-onboard-audit.md +121 -0
  98. package/templates/skills/onboard/phases/summary.md +122 -0
  99. package/templates/skills/onboard/phases/work-tracking.md +231 -0
  100. package/templates/skills/orient/SKILL.md +251 -0
  101. package/templates/skills/orient/phases/auto-maintenance.md +48 -0
  102. package/templates/skills/orient/phases/briefing.md +53 -0
  103. package/templates/skills/orient/phases/cabinet.md +46 -0
  104. package/templates/skills/orient/phases/context.md +63 -0
  105. package/templates/skills/orient/phases/data-sync.md +35 -0
  106. package/templates/skills/orient/phases/health-checks.md +50 -0
  107. package/templates/skills/orient/phases/work-scan.md +69 -0
  108. package/templates/skills/orient-quick/SKILL.md +12 -0
  109. package/templates/skills/plan/SKILL.md +358 -0
  110. package/templates/skills/plan/phases/cabinet-critique.md +47 -0
  111. package/templates/skills/plan/phases/calibration-examples.md +75 -0
  112. package/templates/skills/plan/phases/completeness-check.md +44 -0
  113. package/templates/skills/plan/phases/composition-check.md +36 -0
  114. package/templates/skills/plan/phases/overlap-check.md +62 -0
  115. package/templates/skills/plan/phases/plan-template.md +69 -0
  116. package/templates/skills/plan/phases/present.md +60 -0
  117. package/templates/skills/plan/phases/research.md +43 -0
  118. package/templates/skills/plan/phases/work-tracker.md +95 -0
  119. package/templates/skills/publish/SKILL.md +74 -0
  120. package/templates/skills/pulse/SKILL.md +242 -0
  121. package/templates/skills/pulse/phases/auto-fix-scope.md +40 -0
  122. package/templates/skills/pulse/phases/checks.md +58 -0
  123. package/templates/skills/pulse/phases/output.md +54 -0
  124. package/templates/skills/seed/SKILL.md +257 -0
  125. package/templates/skills/seed/phases/build-member.md +93 -0
  126. package/templates/skills/seed/phases/evaluate-existing.md +61 -0
  127. package/templates/skills/seed/phases/maintain.md +92 -0
  128. package/templates/skills/seed/phases/scan-signals.md +86 -0
  129. package/templates/skills/triage-audit/SKILL.md +251 -0
  130. package/templates/skills/triage-audit/phases/apply-verdicts.md +90 -0
  131. package/templates/skills/triage-audit/phases/load-findings.md +38 -0
  132. package/templates/skills/triage-audit/phases/triage-ui.md +66 -0
  133. package/templates/skills/unlink/SKILL.md +35 -0
  134. package/templates/skills/validate/SKILL.md +116 -0
  135. package/templates/skills/validate/phases/validators.md +53 -0
@@ -0,0 +1,233 @@
1
+ # Interview — Conversational Questions Adapted to Mode
2
+
3
+ The heart of onboarding. This is a dialogue, not a form — ask questions,
4
+ listen to answers, follow up on what's interesting or unclear. The quality
5
+ of the briefing layer depends directly on the quality of this conversation.
6
+
7
+ When this file is absent or empty, the default behavior is: ask mode-
8
+ adapted questions as described below, one at a time, with follow-ups.
9
+ To explicitly skip the interview (e.g., when generating context from
10
+ existing documentation), write only `skip: true`.
11
+
12
+ ## System Introduction (First Run Only)
13
+
14
+ Before asking about the project, check: does the user know what Claude
15
+ on Rails does? Ask once:
16
+
17
+ > "Have you used Claude Cabinet before, or is this your first time?"
18
+
19
+ If **first time**, give a brief walkthrough before the interview:
20
+
21
+ > "Let me explain how this works, then we'll set it up for your project.
22
+ >
23
+ > Claude Cabinet gives your Claude Code sessions a **session loop** —
24
+ > a start and end routine that creates continuity between sessions.
25
+ >
26
+ > - **`/orient`** — you type this at the start of a session. It reads
27
+ > where things stand — what you were working on, what's due, what
28
+ > broke. Instead of starting blind, Claude starts informed.
29
+ > - **`/debrief`** — you type this at the end of a session. It records
30
+ > what happened — what got done, what's still open, what you learned.
31
+ > That's what orient reads next time.
32
+ >
33
+ > Neither runs automatically — you invoke them when you're ready. If
34
+ > you forget `/debrief`, Claude will nudge you before the session ends.
35
+ >
36
+ > Beyond the session loop, there are optional modules: **work tracking**
37
+ > (a local task database), **planning** (structured plans with critique
38
+ > before you build), **audit** (expert cabinet members that review your
39
+ > codebase), and more. We'll get to those after we talk about your project.
40
+ >
41
+ > The whole system is customizable through small files called phase files.
42
+ > You don't need to touch them now — that's what this onboarding does."
43
+
44
+ Then proceed to the interview. Keep it conversational — if they ask
45
+ questions about the system, answer them before moving on.
46
+
47
+ If **experienced** (they've used it before, or say "I know how it works"),
48
+ skip the walkthrough entirely and go straight to the interview.
49
+
50
+ ## User Context (Read Before Interviewing)
51
+
52
+ Before asking any questions, read two global files if they exist:
53
+
54
+ 1. **`~/.claude/CLAUDE.md`** — the user's identity and preferences.
55
+ If this has an "About Me" section, you already know who they are
56
+ and what they do. Don't re-ask questions this answers. Acknowledge
57
+ it: "I see you run a real estate fund — let's talk about how this
58
+ project fits into that."
59
+
60
+ 2. **`~/.claude/cor-registry.json`** — a list of all their CoR projects.
61
+ If they have other projects registered, explain what that means and
62
+ ask how this project relates: "I see you're also using Claude on
63
+ Rails in [project X] — that's a separate project you've set up with
64
+ the same session loop. Does this project connect to that one in any
65
+ way? For example, does one feed data to the other, or do they share
66
+ code?" The answer goes into `_briefing.md` so orient and debrief can
67
+ flag when work in one project might affect the other.
68
+
69
+ If neither file exists, that's fine — the installer may not have created
70
+ them (npm install path, or the user skipped the identity questions).
71
+ Proceed normally.
72
+
73
+ ## Communication Calibration
74
+
75
+ Don't ask the user how technical they are. Listen to how they talk.
76
+ Within the first 2-3 answers, you'll know whether they reference
77
+ technical concepts naturally or describe things in terms of outcomes.
78
+ Match their register — mirror their vocabulary, explain at the level
79
+ they're engaging at. Don't talk down, don't talk over.
80
+
81
+ This isn't a variable to detect ("technical_level: 3"). It's a
82
+ conversational stance: meet people where they are. Someone who says
83
+ "I need a REST API with PostgreSQL" gets different follow-ups than
84
+ someone who says "I need a way to track client appointments." Both
85
+ are valid starting points.
86
+
87
+ ## First-Run Questions
88
+
89
+ The detect-state phase identified this as a first run (no CoR context
90
+ layer exists). But "first run" covers two very different situations:
91
+
92
+ ### Greenfield (no project yet, or near-empty directory)
93
+
94
+ The user just ran the CLI in an empty or near-empty directory. There's
95
+ nothing to scan, no workflow to reflect on yet. Questions must be
96
+ **forward-looking** — about intentions, not retrospection.
97
+
98
+ **Questions (ask one at a time, in order — skip or reorder based on
99
+ what the conversation reveals):**
100
+ 1. What are you trying to build?
101
+ 2. What will you be using Claude Code for on this project?
102
+ 3. How do you usually keep track of what needs to be done?
103
+ 4. Will anyone else be working on this with you?
104
+ 5. Have you struggled with anything on past projects that you'd want
105
+ to get ahead of this time?
106
+ 6. How big is this? A weekend project, something you'll be working on
107
+ for months?
108
+ 7. What does done look like, roughly?
109
+
110
+ **Follow-up instincts:**
111
+ - If they describe something ambitious, ask what the first milestone is
112
+ - If they mention past frustrations, dig into what specifically went wrong
113
+ - If they're vague about the project, that's fine — they may be figuring
114
+ it out. Ask what they know so far and what's still open
115
+ - If they mention collaborators, ask how they'll coordinate
116
+
117
+ ### Existing Project (source files, config, or meaningful content present)
118
+
119
+ The user ran the CLI in a project that already has substance. There are
120
+ files to scan — use them for tech detection instead of asking. Focus the
121
+ conversation on **work and pain**, not tooling.
122
+
123
+ **Before asking:** Scan the project for tech signals (package.json,
124
+ Cargo.toml, requirements.txt, Dockerfile, .github/, etc.). Note what
125
+ you find — it informs your follow-ups but doesn't replace the
126
+ conversation. Don't announce what you found; weave it in naturally.
127
+
128
+ **Questions (ask one at a time, in order — skip or reorder based on
129
+ what the conversation reveals):**
130
+ 1. Tell me about this project. What does it do?
131
+ 2. What are you mainly working on right now?
132
+ 3. What tends to break or get forgotten?
133
+ 4. What do you wish Claude knew about this project from the very start
134
+ of every session?
135
+ 5. Is there anything that fails silently — things that go wrong without
136
+ anyone noticing until it's too late?
137
+ 6. How do you currently keep track of what needs to be done?
138
+ 7. What does a typical working session on this project look like?
139
+ 8. Is there a deploy pipeline or remote environment?
140
+
141
+ **Follow-up instincts:**
142
+ - If someone mentions a pain point, ask *why* it happens and how often
143
+ - If someone says "it's just me," ask how they keep context between sessions
144
+ - If someone mentions a team, ask about handoff friction
145
+ - If someone describes their workflow, listen for things that could be
146
+ automated or checked
147
+
148
+ ## Early Re-Run Questions
149
+
150
+ The session loop has been running. Shift from "what is this" to "what
151
+ have you learned."
152
+
153
+ **Questions (ask one at a time, in order — skip or reorder based on
154
+ what the conversation reveals):**
155
+ 1. What has the session loop taught you that the briefing files don't
156
+ currently capture?
157
+ 2. Does orient give you what you need at session start? What's missing?
158
+ 3. Does debrief close the right loops? What falls through?
159
+ 4. Where have you hit friction with the current setup?
160
+ 5. Are there things you keep having to tell Claude that should already be
161
+ in the briefing?
162
+ 6. Any phase files that aren't pulling their weight?
163
+ 7. Has the project changed since the initial onboard?
164
+ 8. Are you ready for any of the modules you skipped last time?
165
+ 9. Anything you've been doing manually that should be automated?
166
+
167
+ ## Mature Re-Run Questions
168
+
169
+ The system has been running long enough to accumulate both value and
170
+ cruft. This is a health check.
171
+
172
+ **Questions (ask one at a time, in order — skip or reorder based on
173
+ what the conversation reveals):**
174
+ 1. Which modules are you actually using regularly?
175
+ 2. Anything that felt useful at first but you've stopped relying on?
176
+ 3. Are there modules you adopted but never really configured properly?
177
+ 4. What gaps have you noticed? Things the system should catch but doesn't.
178
+ 5. Has the project's architecture or priorities shifted since the last
179
+ onboard run?
180
+ 6. Any new pain points that weren't there before?
181
+ 7. Is anything ready to retire?
182
+ 8. Could any of your custom phase files be simplified now that you know
183
+ what you actually need?
184
+ 9. Are there patterns in your memory/feedback that suggest a structural
185
+ change rather than another rule?
186
+
187
+ ## Scope Boundary
188
+
189
+ You are configuring the **process layer** — what Claude should know about
190
+ this project, how sessions start and end, what to track and check. You
191
+ are NOT:
192
+
193
+ - Recommending tech stacks, frameworks, or architecture
194
+ - Advising on what to build or how to build it
195
+ - Making product decisions
196
+
197
+ If the user asks "what should I use?" or "what do you recommend?" for
198
+ their actual project, redirect: "That's a great question for your first
199
+ working session after we finish setup. Right now I'm just learning about
200
+ your project so the session loop knows what to look for. What do you
201
+ know so far about what you'll be building?"
202
+
203
+ Record what they tell you about their intentions and tools — that goes
204
+ into `_briefing.md`. But choosing those tools is their decision, not
205
+ onboard's job.
206
+
207
+ ## Conversation Guidelines
208
+
209
+ - **One question at a time.** Ask a single question, wait for the answer,
210
+ then ask the next one. Never stack multiple questions in one message.
211
+ The rounds below are a *sequence*, not a batch — each bullet is its own
212
+ turn. Follow-ups based on the answer take priority over the next
213
+ planned question.
214
+ - **Follow up on substance.** If an answer reveals something important,
215
+ dig into it before moving on to the next topic.
216
+ - **Note CoR module signals.** When someone describes a pain point that
217
+ maps to a specific module, note it internally for the modularity menu
218
+ phase — but don't interrupt the conversation to pitch the module.
219
+ - **Don't assume answers.** Even if you can see the project's files, ask
220
+ about things like pain points and priorities that only the user knows.
221
+ - **Earn the right to ask about specifics.** Don't ask about tech stack,
222
+ deployment pipelines, or architecture until the conversation has shown
223
+ the user has context to give a meaningful answer. Lead with open
224
+ questions ("tell me about this project") and let specifics emerge
225
+ naturally. If the user is non-technical or early in their thinking,
226
+ those questions may never be appropriate — and that's fine.
227
+ - **Summarize before generating.** After the interview, reflect back what
228
+ you heard: "Here's what I'm taking away from this conversation..." Let
229
+ the user correct before generating files.
230
+ - **For skipped modules (.corrc.json):** If the CLI's `skipped` field
231
+ shows a module was opted out with a reason, weave that into the
232
+ conversation naturally. "I see you're tracking work somewhere else —
233
+ tell me about that" rather than "Module work-tracking was skipped."
@@ -0,0 +1,162 @@
1
+ # Modularity Menu — Present Opt-In Modules
2
+
3
+ Present the Claude Cabinet module hierarchy so the user can decide what to adopt now
4
+ and what to defer. The session loop is mandatory; everything else is
5
+ opt-in. Progressive adoption means starting with what you need and adding
6
+ modules as the project matures.
7
+
8
+ When this file is absent or empty, the default behavior is: read
9
+ `.corrc.json` for module selections made during CLI install, then present
10
+ the module hierarchy with that context. To explicitly skip the menu,
11
+ write only `skip: true`.
12
+
13
+ ## Reading CLI Selections (.corrc.json)
14
+
15
+ If `.corrc.json` exists in the project root, the CLI has already asked
16
+ about module selections. Read the `modules` and `skipped` fields:
17
+
18
+ - **Installed modules** (`modules` map, value `true`): These are already
19
+ set up. Don't re-ask. Confirm what's installed and move on.
20
+ - **Skipped modules** (`skipped` map, with reasons): The user opted out
21
+ during CLI install. The reason matters — it tells you what alternative
22
+ to ask about. For example:
23
+ - `"work-tracking": "User has existing Railway API"` → ask how they
24
+ track work so you can wire phase files to their system
25
+ - `"work-tracking": "Not needed yet"` → note it's available later, move on
26
+ - `"audit": "Project too small"` → respect the decision, note the threshold
27
+
28
+ For skipped modules with alternatives, the interview (previous phase)
29
+ should have already asked about the alternative system. Use those answers
30
+ here to confirm the wiring plan.
31
+
32
+ If `.corrc.json` doesn't exist (manual install or pre-npm adoption),
33
+ fall back to presenting the full menu as described below.
34
+
35
+ ## Module Hierarchy
36
+
37
+ Present these in order from most fundamental to most specialized:
38
+
39
+ ### 1. Session Loop (orient + debrief) — MANDATORY
40
+
41
+ Always set up. This is the minimum viable CoR adoption. Orient reads
42
+ state at session start; debrief writes state at session end. Without
43
+ this, nothing else has a foundation.
44
+
45
+ **What you get:** Context continuity between sessions. Claude starts
46
+ informed and ends by recording what happened. The project gets smarter
47
+ with each session instead of resetting to zero.
48
+
49
+ **Cost:** Two phase directories with a few files each. Runs at the
50
+ start and end of every session (adds 30-60 seconds each).
51
+
52
+ ### 2. Work Tracking — RECOMMENDED
53
+
54
+ How work items are tracked. The work-tracking onboard phase presents the
55
+ options in detail; this is the module-level view.
56
+
57
+ **Options (chosen during onboard work-tracking phase):**
58
+ - **pib-db (SQLite):** Structured, queryable, local-only. CLI interface.
59
+ Integrates with plan/execute and audit findings. Requires `better-sqlite3`.
60
+ - **Markdown (tasks.md):** Simple, git-friendly, zero dependencies. Open
61
+ items are checkbox lines in a file. Good for solo/quick-start projects.
62
+ - **External:** Wire orient/debrief to GitHub Issues, Linear, Jira, etc.
63
+ You customize phase files after onboard.
64
+
65
+ **What you get:** Open actions, due dates, flagged items. Orient surfaces
66
+ what needs attention. Debrief marks things done. Plan creates work items.
67
+
68
+ **Skip if:** You don't need work tracking in the session loop. You can
69
+ always add it later by re-running `/onboard`.
70
+
71
+ ### 3. Planning (plan + execute) — OPT-IN
72
+
73
+ Structured implementation planning with cabinet member-based critique and
74
+ execution with checkpoints.
75
+
76
+ **What you get:** Plans that carry enough detail for a future session to
77
+ execute without re-exploring the codebase. Cabinet member agents that
78
+ critique plans before execution. Execution with structured checkpoints.
79
+
80
+ **Cost:** Plan and execute skill configuration. Cabinet member setup if you
81
+ want critique. Adds deliberation time before building — this is the point.
82
+
83
+ **Skip if:** Your project's work is mostly small, clear tasks that don't
84
+ benefit from structured planning. Add this module when you start hitting
85
+ edge cases or duplicating work.
86
+
87
+ ### 4. Compliance Stack (rules, hooks) — OPT-IN
88
+
89
+ Scoped instructions in `.claude/rules/` and deterministic enforcement
90
+ via hooks in `.claude/settings.json`.
91
+
92
+ **What you get:** Path-specific rules that load automatically (e.g.,
93
+ "when editing tests/, always run the test suite"). Hooks that enforce
94
+ hard guardrails (e.g., block commits without tests, validate file formats).
95
+
96
+ **Cost:** Rule files and hook scripts that need maintenance. Hooks run on
97
+ every tool invocation — poorly written hooks add latency.
98
+
99
+ **Skip if:** Your project doesn't yet have recurring mistakes worth
100
+ encoding. Add rules as patterns emerge from debrief lessons.
101
+
102
+ ### 5. Audit Loop (audit + triage-audit + cabinet members) — OPT-IN
103
+
104
+ Periodic cabinet member analysis of the codebase with structured
105
+ triage of findings.
106
+
107
+ **What you get:** Semantic analysis by specialized cabinet members (security,
108
+ accessibility, data integrity, etc.). Structured findings with severity
109
+ levels. Triage workflow to accept, defer, or dismiss findings.
110
+
111
+ **Cost:** Cabinet member configuration, audit runs (LLM-intensive), triage
112
+ time. This is the most expensive module in compute and attention.
113
+
114
+ **Skip if:** Your project is small enough to review holistically, or
115
+ you're not yet at the stage where systematic quality analysis adds value.
116
+ Add this when the codebase grows beyond what one person can hold in their
117
+ head.
118
+
119
+ ### 6. Capability Seeding (seed) — OPT-IN
120
+
121
+ Bootstrap new skills, cabinet members, or process components from CoR
122
+ skeleton templates.
123
+
124
+ **What you get:** Quick scaffolding of new capabilities with all required
125
+ files and wiring in place.
126
+
127
+ **Cost:** Minimal. This is tooling for extending the system itself.
128
+
129
+ **Skip if:** You're happy with the modules you have and aren't planning
130
+ to build custom skills or cabinet members. Come back to this when you want
131
+ to extend.
132
+
133
+ ## Presentation Guidelines
134
+
135
+ - **Present the full menu** so the user sees the landscape, but recommend
136
+ based on what the interview revealed.
137
+ - **Mark the mandatory module** clearly — the session loop isn't optional.
138
+ - **Connect modules to pain points.** If the user mentioned stale deploys,
139
+ note that health checks (part of the session loop) address this. If they
140
+ mentioned duplicated work, note that the planning module helps.
141
+ - **Respect "not yet."** Deferring a module is fine. The menu is always
142
+ available via re-running onboard.
143
+
144
+ ## Re-Run Presentation
145
+
146
+ For re-runs, augment the menu with current adoption state:
147
+
148
+ ```
149
+ Module Status Notes
150
+ Session loop ACTIVE 3 orient phases, 2 debrief phases
151
+ Work tracking ACTIVE 47 actions, 8 projects
152
+ Planning ACTIVE Using plan + execute
153
+ Compliance stack PARTIAL 2 rules files, no hooks
154
+ Audit loop NOT ADOPTED —
155
+ Capability seeding NOT ADOPTED —
156
+ ```
157
+
158
+ Also surface:
159
+ - **Retirement candidates:** Modules or phase files that show signs of
160
+ disuse (e.g., a health check that hasn't fired in weeks)
161
+ - **Growth candidates:** Modules the project seems ready for based on
162
+ accumulated patterns or interview answers
@@ -0,0 +1,98 @@
1
+ # Options — Structured Decision Points Before Generation
2
+
3
+ After the interview and before generating briefing files, surface the key
4
+ decisions that shape how the project and process layer get set up. Present
5
+ options with trade-offs so the user makes informed choices — not Claude
6
+ making choices for them.
7
+
8
+ When this file is absent or empty, the default behavior is: identify
9
+ decisions implied by the interview, present options, let the user choose.
10
+ To explicitly skip (e.g., the user already has strong opinions from the
11
+ interview), write only `skip: true`.
12
+
13
+ ## When This Phase Activates
14
+
15
+ Not every onboard needs this. Skip it when:
16
+ - The user described a clear tech stack and workflow (nothing to decide)
17
+ - This is a re-run (decisions were already made)
18
+ - The project is already built and this is process-layer-only
19
+
20
+ Run it when the interview revealed **open decisions** — things the user
21
+ hasn't settled yet that will affect what briefing files contain:
22
+
23
+ - "I'm not sure what database to use"
24
+ - "I don't know if I need a backend"
25
+ - "What would you recommend?" (redirected here from the interview)
26
+ - Greenfield project where the user described *what* but not *how*
27
+
28
+ ## How to Present Options
29
+
30
+ For each open decision, present 2-3 concrete options with trade-offs.
31
+ Use two cabinet members internally (do not spawn agents — just
32
+ reason from these viewpoints):
33
+
34
+ ### Architecture Cabinet Member
35
+ Evaluates each option for: complexity, maintenance burden, whether it
36
+ matches the user's described skill level and project scope. Flags when
37
+ an option is overkill for a weekend project or too lightweight for
38
+ something ambitious.
39
+
40
+ ### Boundary Man
41
+ Evaluates each option for: what breaks first, what's hard to change
42
+ later, what locks you in. Flags irreversible decisions that deserve
43
+ extra thought.
44
+
45
+ ### Format
46
+
47
+ ```
48
+ ## [Decision: e.g., "How to store data"]
49
+
50
+ Based on what you described — [reference specific things from interview] —
51
+ here are your options:
52
+
53
+ **Option A: [name]**
54
+ - What it is: [1 sentence]
55
+ - Good for: [when this is the right choice]
56
+ - Trade-off: [what you give up]
57
+
58
+ **Option B: [name]**
59
+ - What it is: [1 sentence]
60
+ - Good for: [when this is the right choice]
61
+ - Trade-off: [what you give up]
62
+
63
+ **Option C: [name]** (if applicable)
64
+ - ...
65
+
66
+ What sounds right for your situation?
67
+ ```
68
+
69
+ ### Tone
70
+
71
+ - **Present, don't prescribe.** "Here are your options" not "I recommend X."
72
+ - **Reference the interview.** "You mentioned it's just you and this is a
73
+ side project, so..." — ground options in their specific situation.
74
+ - **Be honest about complexity.** If one option is simpler but limited,
75
+ say so. If another is powerful but requires more setup, say so.
76
+ - **Respect "I don't know."** If the user can't decide, suggest starting
77
+ with the simplest option and note that it can be changed later. Don't
78
+ pressure decisions.
79
+
80
+ ## What This Is NOT
81
+
82
+ - **Not architecture consulting.** You present options the interview
83
+ surfaced, not a comprehensive technology evaluation. If the user wants
84
+ deep architecture advice, that's a working session topic, not onboard.
85
+ - **Not prescriptive.** Never say "you should use X." Always frame as
86
+ options with trade-offs.
87
+ - **Not exhaustive.** 2-3 options per decision. Not every possible
88
+ approach.
89
+
90
+ ## Output
91
+
92
+ The user's choices feed into generate-briefing. Each decision becomes
93
+ concrete content in `_briefing.md` (architecture section), CLAUDE.md
94
+ (conventions), and potentially orient phase files (what to check).
95
+
96
+ If the user defers a decision ("I'll figure that out later"), note it
97
+ in `_briefing.md` as an open question — don't leave the section empty
98
+ without explanation.
@@ -0,0 +1,121 @@
1
+ # Post-Onboard Audit — Configuration Sanity Check
2
+
3
+ After generating all files and presenting the summary, run a lightweight
4
+ audit from the cor-health cabinet member to catch configuration issues before
5
+ the user starts their first session.
6
+
7
+ When this file is absent or empty, the default behavior is: run the audit
8
+ as described below. To explicitly skip it, write only `skip: true`.
9
+
10
+ ## Why This Exists
11
+
12
+ Onboard generates a lot of files from conversation. The interview is
13
+ freeform — the user might mention a database but the data-sync phase
14
+ doesn't get wired. They might skip a module but a phase file references
15
+ it. They might describe a deployment pipeline but no health check covers
16
+ it. These gaps are invisible until orient runs and something is wrong.
17
+
18
+ A quick audit immediately after generation catches these before the user
19
+ starts relying on the configuration.
20
+
21
+ ## What to Check
22
+
23
+ Run as the **cor-health cabinet member** but scoped to what onboard just
24
+ generated. This is NOT a full audit — it's a focused sanity check on
25
+ the fresh configuration.
26
+
27
+ ### 1. Interview–Configuration Coherence
28
+
29
+ Compare what the interview revealed against what was generated:
30
+
31
+ - **Technologies mentioned** → Are they reflected in `_briefing.md` scan
32
+ scopes and relevant phase files?
33
+ - **Pain points described** → Did at least one phase file or health check
34
+ address each significant pain point?
35
+ - **Data sources mentioned** → Is `data-sync.md` wired if the project has
36
+ remote data? Is it absent if the project is purely local?
37
+ - **Collaboration details** → If multiple people work on the project, are
38
+ coordination-relevant checks present?
39
+
40
+ ### 2. Module–Phase Alignment
41
+
42
+ Cross-reference `.corrc.json` (installed vs skipped modules) against the
43
+ generated phase files:
44
+
45
+ - **Skipped modules:** No phase file should reference a skipped module's
46
+ infrastructure. If work-tracking was skipped, no phase should reference
47
+ `pib.db` or `pib-db.js`. If audit was skipped, no phase should reference
48
+ `committees.yaml` or cabinet member activation.
49
+ - **Installed modules:** Each installed module should have at least a
50
+ minimal presence in the generated configuration. A module that's installed
51
+ but has zero phase file references is a configuration gap.
52
+
53
+ ### 3. Structural Basics
54
+
55
+ Quick filesystem checks:
56
+
57
+ - Every generated file is valid markdown (no truncated content, no
58
+ template placeholders left unfilled)
59
+ - Phase files that reference other files point at files that exist
60
+ - `_briefing.md` has non-empty project description, stack, and scan scopes
61
+ - `system-status.md` exists and has initial content
62
+ - Hook scripts in `.claude/hooks/` are executable (if hooks module adopted)
63
+
64
+ ### 4. Technology-Implied Cabinet Members
65
+
66
+ Check whether the project's technology signals suggest cabinet members that
67
+ aren't activated. Cross-reference the interview answers and detected
68
+ technologies against the cabinet member catalog:
69
+
70
+ - **UI framework detected** → usability, accessibility, small-screen
71
+ - **Database detected** → data-integrity
72
+ - **API server detected** → security, speed-freak
73
+ - **Complex architecture (3+ layers/services)** → architecture
74
+ - **Long-running project** → historian
75
+ - **Many skills (5+)** → roster-check
76
+ - **Features shipping regularly** → system-advocate
77
+
78
+ If implied cabinet members aren't in `committees.yaml` (or equivalent), note
79
+ it as a recommendation — not a blocker. The user may have good reasons
80
+ to skip them, or may want to add them later via `/seed`.
81
+
82
+ ### 5. First-Session Readiness
83
+
84
+ Simulate what `/orient` will do on its first run:
85
+
86
+ - Walk through orient's phases mentally. For each phase that will run,
87
+ verify the files it reads exist and have content.
88
+ - If orient would hit an empty phase that should have content (given what
89
+ the interview revealed), flag it.
90
+ - If debrief would try to update a file that doesn't exist yet, flag it.
91
+
92
+ ## How to Present
93
+
94
+ **If everything checks out:** One line after the summary:
95
+
96
+ > "Configuration looks clean — orient should work on first run."
97
+
98
+ **If issues are found:** Present them briefly, grouped by severity:
99
+
100
+ > "Before you run /orient, I noticed a few things:
101
+ >
102
+ > - data-sync.md references your PostgreSQL database, but no connection
103
+ > details are in the phase file. Orient will try to sync and fail.
104
+ > - The security cabinet member is activated but _briefing.md doesn't include
105
+ > API routes in its scan scopes — it won't find anything to review.
106
+ >
107
+ > Want me to fix these now?"
108
+
109
+ Fix issues immediately if the user says yes. This is not a deferred
110
+ finding — it's a pre-flight check.
111
+
112
+ ## What This Is NOT
113
+
114
+ - **Not a full cor-health audit.** That runs periodically via /audit and
115
+ covers telemetry, usage patterns, drift over time. This only checks
116
+ what was just generated.
117
+ - **Not a product quality review.** Whether the _briefing.md is well-written
118
+ or the health checks are comprehensive — that improves through use.
119
+ This just checks that the configuration is structurally sound.
120
+ - **Not blocking.** If the audit finds issues and the user wants to move
121
+ on, let them. The issues will surface again naturally when orient runs.