brain-dev 2.0.3 → 2.0.4

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.
@@ -22,6 +22,12 @@ Supports creating new ADRs, listing existing ones, and searching decision histor
22
22
  - `search <query>` — Search ADRs by keyword or tag
23
23
  </context>
24
24
 
25
+ <critical-rules>
26
+ - ALWAYS use `npx brain-dev adr` to manage ADRs. Never manually create ADR files in .brain/adrs/.
27
+ - The CLI assigns sequential IDs, applies the template, and tracks status lifecycle.
28
+ - Manual ADR creation can cause ID conflicts and missing metadata.
29
+ </critical-rules>
30
+
25
31
  <process>
26
32
  1. Run the brain CLI to manage ADRs:
27
33
  ```bash
@@ -21,6 +21,14 @@ Auto mode generates a runbook of steps. Follow each step's instructions sequenti
21
21
  Each step tells you which agent to spawn and what prompt to use.
22
22
  </context>
23
23
 
24
+ <critical-rules>
25
+ - ALWAYS run `npx brain-dev execute --auto` to start. Never manually chain brain commands as a substitute.
26
+ - Follow the generated runbook EXACTLY — each step tells you which command to run.
27
+ - DO NOT skip steps or reorder them — the runbook respects phase dependencies.
28
+ - On error, follow the error recovery decision tree in the runbook — do not improvise.
29
+ - ALWAYS run `npx brain-dev execute --auto --stop` when done or on failure.
30
+ </critical-rules>
31
+
24
32
  <process>
25
33
  1. Run: `npx brain-dev execute --auto` (or `--dry-run` to preview)
26
34
  2. Follow the generated runbook instructions step by step
@@ -23,6 +23,12 @@ Ensures all phases are verified before completing.
23
23
  - `--force` — Force completion even if some verifications are pending
24
24
  </context>
25
25
 
26
+ <critical-rules>
27
+ - ALWAYS run `npx brain-dev complete` FIRST. Never manually create git tags or archive files.
28
+ - DO NOT skip the completion audit — it verifies all phases passed before archiving.
29
+ - DO NOT mark phases as complete without running this command — it updates state, creates audit trails, and generates release notes.
30
+ </critical-rules>
31
+
26
32
  <process>
27
33
  1. Run the brain CLI to complete the milestone:
28
34
  ```bash
@@ -25,6 +25,12 @@ When no subcommand is given, launches an interactive menu.
25
25
  - `--global` — Apply to global config instead of project config
26
26
  </context>
27
27
 
28
+ <critical-rules>
29
+ - ALWAYS use `npx brain-dev config` to change settings. Never manually edit brain.json config fields.
30
+ - The CLI validates values against the schema — manual edits can set invalid values that break the pipeline.
31
+ - Use `config docs` to see available settings before making changes.
32
+ </critical-rules>
33
+
28
34
  <process>
29
35
  1. Run the brain CLI to manage configuration:
30
36
  ```bash
@@ -21,6 +21,13 @@ Creates a CONTEXT.md file that feeds into the planning process.
21
21
  `$ARGUMENTS` is the phase number (e.g., `1`, `2`).
22
22
  </context>
23
23
 
24
+ <critical-rules>
25
+ - ALWAYS run `npx brain-dev discuss` FIRST. Never skip discussion and go straight to planning.
26
+ - DO NOT assume you know the right approach — the discuss step surfaces gray areas that cause rework later.
27
+ - DO NOT write CONTEXT.md manually — the CLI provides the discuss template with stack-specific guidance.
28
+ - Decisions made here feed directly into planning. Skipping discuss = plans based on assumptions.
29
+ </critical-rules>
30
+
24
31
  <process>
25
32
  1. Run the brain CLI for the given phase:
26
33
  ```bash
@@ -22,6 +22,13 @@ Discovers plans, analyzes dependencies, groups into waves, spawns subagents, and
22
22
  - `--gaps-only` — Execute only gap closure plans created by verify
23
23
  </context>
24
24
 
25
+ <critical-rules>
26
+ - ALWAYS run `npx brain-dev execute` FIRST. Never manually implement plan tasks yourself.
27
+ - DO NOT read PLAN.md files and execute them manually — the CLI handles agent spawning, wave ordering, and progress tracking.
28
+ - DO NOT skip to verification without running execute — the executor agent creates SUMMARY.md files that the verifier needs.
29
+ - If execution fails, follow the EXECUTION FAILED output — do not improvise a fix outside the pipeline.
30
+ </critical-rules>
31
+
25
32
  <process>
26
33
  1. Run the brain CLI to execute plans:
27
34
  ```bash
@@ -21,6 +21,12 @@ Optionally auto-repairs safe issues with --fix.
21
21
  - `--quick` — Run only critical checks, skip deep analysis
22
22
  </context>
23
23
 
24
+ <critical-rules>
25
+ - ALWAYS run `npx brain-dev health` FIRST. Never manually fix hooks, templates, or state files.
26
+ - The CLI knows which repairs are safe (auto-repairable) vs which need manual intervention.
27
+ - DO NOT manually edit .brain/brain.json to fix health issues — use `--fix` flag instead.
28
+ </critical-rules>
29
+
24
30
  <process>
25
31
  1. Run the brain CLI to check health:
26
32
  ```bash
@@ -11,6 +11,12 @@ allowed-tools:
11
11
  Set up Brain for an existing or new project. Detects your stack, maps the codebase, then asks what you want to do next.
12
12
  </objective>
13
13
 
14
+ <critical-rules>
15
+ - ALWAYS run `npx brain-dev new-project` FIRST. Never manually create PROJECT.md or edit brain.json project fields.
16
+ - The CLI detects your stack, maps workspace siblings, and sets up detection.json — manual setup misses this.
17
+ - ALWAYS use AskUserQuestion for the goal question — do not print options as text.
18
+ </critical-rules>
19
+
14
20
  <process>
15
21
  1. Run the detection:
16
22
  ```bash
@@ -14,6 +14,11 @@ Safe to close the session after this command completes.
14
14
  No arguments required. Captures current session state automatically.
15
15
  </context>
16
16
 
17
+ <critical-rules>
18
+ - ALWAYS run `npx brain-dev pause` to save state. Never manually write continue-here.md or edit session files.
19
+ - The CLI captures decisions, plan state, and active work context that manual saves miss.
20
+ </critical-rules>
21
+
17
22
  <process>
18
23
  1. Run the brain CLI to save state:
19
24
  ```bash
@@ -24,6 +24,13 @@ Default flow: Research (if needed) -> Plan -> Verify -> Done.
24
24
  - `--skip-verify` — Skip the verification loop after plan creation
25
25
  </context>
26
26
 
27
+ <critical-rules>
28
+ - ALWAYS run `npx brain-dev plan` FIRST. Never write PLAN.md files manually.
29
+ - DO NOT skip the plan-checker verification loop — it catches requirement gaps and file ownership conflicts.
30
+ - DO NOT proceed to execute without running plan — plans contain must_haves that the verifier checks against.
31
+ - If planning fails, use `/brain:discuss` to clarify requirements — do not force a plan through.
32
+ </critical-rules>
33
+
27
34
  <process>
28
35
  1. Run the brain CLI to generate plans:
29
36
  ```bash
@@ -27,6 +27,14 @@ Use subagent_type "brain-executor" for execution.
27
27
  Use subagent_type "brain-verifier" for verification (--full mode only).
28
28
  </agents>
29
29
 
30
+ <critical-rules>
31
+ - ALWAYS run `npx brain-dev quick` FIRST. Never skip the CLI and code directly.
32
+ - Even quick tasks go through plan → execute → commit. The CLI generates the planner/executor prompts.
33
+ - DO NOT manually write code without first having a plan from the CLI.
34
+ - Follow the `nextAction` field in each CLI output — do not guess the next step.
35
+ - If the task needs discussion or verification, use `/brain:new-task` instead.
36
+ </critical-rules>
37
+
30
38
  <process>
31
39
  1. Run: `npx brain-dev quick [--full] "task description"`
32
40
  - CLI creates task directory, generates planner prompt
@@ -12,6 +12,12 @@ Check for interrupted sessions and recover safely.
12
12
  Default mode shows what happened. Use --fix to auto-resume or --rollback to revert.
13
13
  </objective>
14
14
 
15
+ <critical-rules>
16
+ - ALWAYS run `npx brain-dev recover` FIRST. Never manually edit brain.json, delete lock files, or reset state.
17
+ - Manual state edits can corrupt the project — the CLI validates consistency before making changes.
18
+ - Review the recovery briefing before choosing --fix or --rollback.
19
+ </critical-rules>
20
+
15
21
  <process>
16
22
  1. Run: `npx brain-dev recover`
17
23
  2. Review the recovery briefing
@@ -24,6 +24,13 @@ Stories are Brain's primary way to organize significant work. A story creates:
24
24
  - Phases (discuss → plan → execute → verify → complete)
25
25
  </context>
26
26
 
27
+ <critical-rules>
28
+ - ALWAYS run `npx brain-dev story` FIRST. Never manually create research, requirements, or roadmap files.
29
+ - DO NOT skip the research phase — it uses 6 parallel researchers that find pitfalls you'd miss manually.
30
+ - DO NOT start coding before the story is fully activated (research → requirements → roadmap → activate).
31
+ - After each step, run `npx brain-dev story --continue` — do not guess the next step.
32
+ </critical-rules>
33
+
27
34
  <process>
28
35
  1. Start: `npx brain-dev story "v1.1 Feature title"`
29
36
  2. Answer the vision/scope questions
@@ -22,6 +22,13 @@ Produces a VERIFICATION.md report with pass/gaps/human_needed status.
22
22
  - `--auto-recover` — Automatically create and execute gap closure plans for failures
23
23
  </context>
24
24
 
25
+ <critical-rules>
26
+ - ALWAYS run `npx brain-dev verify` FIRST. Never manually check must_haves yourself.
27
+ - DO NOT declare work "done" or "verified" without running the verify command — it performs 3-level checks (exists, substantive, wired) that catch issues manual review misses.
28
+ - DO NOT skip verification to save time — unverified work creates technical debt and regressions.
29
+ - If verification finds gaps, use `/brain:plan --gaps` to create fix plans — do not manually patch.
30
+ </critical-rules>
31
+
25
32
  <process>
26
33
  1. Run the brain CLI to verify the phase:
27
34
  ```bash
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "brain-dev",
3
- "version": "2.0.3",
3
+ "version": "2.0.4",
4
4
  "description": "AI-powered development workflow orchestrator",
5
5
  "author": "halilcosdu",
6
6
  "license": "MIT",