@jakkrichm/create-nexus-devflow 2.0.6 → 2.0.8

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.
@@ -0,0 +1,111 @@
1
+ const starterTemplates = {
2
+ projectOverview: `# Project Overview
3
+
4
+ > **DevFlow Context Source of Truth.**
5
+ > Single AI-facing source of truth for project architecture, stack, and shipped capabilities.
6
+ > Run \`/onboard\` (for fresh projects) or \`/adopt\` (for existing codebases) to populate this file automatically.
7
+
8
+ ## 1. Project Summary
9
+
10
+ - **Name**: [Project Name]
11
+ - **Description**: [One-line summary of project purpose]
12
+ - **Primary Stack**: [Framework / Language / Runtime]
13
+
14
+ ## 2. Architecture & Modules
15
+
16
+ - \`src/\` - Core application source code
17
+
18
+ ## 3. Shipped Capabilities
19
+
20
+ - None recorded yet. Run \`/onboard\` or \`/adopt\` to initialize.
21
+ `,
22
+
23
+ codingStandards: `# Coding Standards
24
+
25
+ > Project conventions and rules to follow during development.
26
+ > Run \`/onboard\` (or \`/adopt\` for existing codebases) to tune these standards to your specific stack.
27
+
28
+ ## Architecture and Conventions
29
+
30
+ - Write clean, modular, and maintainable code with clear single responsibilities.
31
+ - Prefer TypeScript and explicit interfaces where available.
32
+ - Keep dependencies lean and justified.
33
+
34
+ ## Code Organization & Style
35
+
36
+ - Structure source code following framework-native conventions.
37
+ - Keep functions focused and avoid deeply nested logic.
38
+ - Use consistent naming conventions (camelCase for functions/variables, PascalCase for components/types).
39
+
40
+ ## Error Handling & Security
41
+
42
+ - Handle errors explicitly and provide meaningful error messages.
43
+ - Never hardcode credentials, secrets, or API keys in source code.
44
+ - Sanitize and validate all user inputs.
45
+
46
+ ## Testing & Quality
47
+
48
+ - Follow the TDD workflow for behavior-changing code units.
49
+ - Run tests and linting before completing features or fixes.
50
+ `,
51
+
52
+ currentStage: `# Current DevFlow Run Status
53
+
54
+ - **Active Discovery ID**: None
55
+ - **Active Running ID**: None
56
+ - **Current Stage**: Idle
57
+ - **Last Completed Run**: None
58
+ - **Last Updated**: -
59
+ `,
60
+
61
+ findings: `# Findings Ledger
62
+
63
+ > Review findings raised by \`/security-review\` or QA audits.
64
+ > Resolved findings are tracked with durable IDs.
65
+
66
+ - **Total Open P0/P1**: 0
67
+ - **Total Tracked**: 0
68
+
69
+ _No findings recorded._
70
+ `,
71
+
72
+ aiInteraction: `# AI Interaction Guidelines for DevFlow
73
+
74
+ > **DevFlow is an agentic workflow layer**, overlaying on top of scaffolded or existing codebases.
75
+
76
+ ## Communication & Interaction
77
+
78
+ - Be concise and direct in communication.
79
+ - Explain technical trade-offs and non-obvious design decisions briefly.
80
+ - Always confirm before performing major refactors or destructive operations.
81
+ - Maintain markdown-first evidence for all stage activities.
82
+
83
+ ## Artifact Language
84
+
85
+ - Default language for user-facing artifacts and summaries is Thai (\`th\`), while code, paths, and identifiers remain in English.
86
+ - Use exact schema headings when validators check for specific contract sections.
87
+
88
+ ## Output Formatting
89
+
90
+ - Use GitHub-style markdown for clean scanning.
91
+ - Use lists for steps, options, and findings.
92
+ - Use tables for comparative matrices or stage summaries.
93
+ - Use backticks for paths, filenames, identifiers, and CLI commands.
94
+
95
+ ## DevFlow Timeline Lifecycle
96
+
97
+ \`\`\`text
98
+ /00-Discover -> /10-Define -> /20-Spec -> /30-Plan -> /40-Implement -> /50-Verify -> /60-Report -> /70-Release
99
+ \`\`\`
100
+
101
+ - Run \`/00-Discover\` to explore requests under a Discovery ID.
102
+ - Run \`/10-Define\` to set delivery boundaries and allocate Running IDs.
103
+ - Run \`/20-Spec\` and \`/30-Plan\` to establish formal delivery specifications and execution plans.
104
+ - Run \`/40-Implement\` for step-by-step code implementation with evidence.
105
+ - Run \`/50-Verify\`, \`/60-Report\`, and \`/70-Release\` for quality verification, reporting, and release packaging.
106
+ `
107
+ };
108
+
109
+ module.exports = {
110
+ starterTemplates
111
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jakkrichm/create-nexus-devflow",
3
- "version": "2.0.6",
3
+ "version": "2.0.8",
4
4
  "description": "Install or update the agent-ready DevFlow 2.0 workflow layer into a scaffolded or existing project.",
5
5
  "license": "MIT",
6
6
  "author": "Jakkrich",
@@ -0,0 +1,95 @@
1
+ ---
2
+ name: adopt
3
+ description: Bootstrap Nexus-DevFlow into an existing (brownfield) codebase. Surveys the real repository (read-only), interviews the user for intent, generates project-overview.md and coding-standards.md from existing code, tunes AGENTS.md commands, and seeds the initial Discovery or Run map. Use when the user runs adopt, /adopt, $adopt, is overlaying DevFlow onto an app that already has meaningful code, or asks to adopt DevFlow into an existing project. For freshly scaffolded or early projects, use onboard instead.
4
+ ---
5
+
6
+ # adopt - Bootstrap Nexus-DevFlow from an Existing Codebase
7
+
8
+ Where this sits in the workflow:
9
+
10
+ ```text
11
+ existing codebase -> [adopt] -> project-overview + coding-standards -> /00-discover or /10-define
12
+ (already has code) (survey + (seeded from the real code; (first feature / refactoring
13
+ interview) shipped architecture documented) delivery lifecycle)
14
+ ```
15
+
16
+ Standard onboarding assumes a freshly scaffolded, near-empty app. That does not fit a codebase that already has thousands of lines of working code.
17
+
18
+ `/adopt` is the brownfield on-ramp for Nexus-DevFlow: it reads what is already there, asks only for what the code cannot reveal (the *intent*, the *why*, and the *upcoming roadmap*), and produces the exact context files the rest of the DevFlow lifecycle expects (`project-overview.md`, `coding-standards.md`, `AGENTS.md` commands).
19
+
20
+ ---
21
+
22
+ ## Input
23
+
24
+ A description of what the project is, if provided. Otherwise, inspect the repository directly. No argument is required.
25
+
26
+ ---
27
+
28
+ ## Step 0 - Confirm Brownfield Safety
29
+
30
+ Inspect `devflow/context/project-overview.md` and `devflow/context/coding-standards.md`:
31
+
32
+ - If they contain default placeholders or empty templates, proceed.
33
+ - If they already hold rich, user-owned content, stop and inform the user; offer to refresh specific sections rather than overwriting existing context without confirmation.
34
+
35
+ Never run a framework scaffolder (DevFlow is an overlay, never a generator).
36
+
37
+ ---
38
+
39
+ ## Step 1 - Survey the Codebase (Read-Only)
40
+
41
+ Read the repository to establish the facts. Change nothing in this step:
42
+
43
+ - **Stack & Tooling**: Languages, frameworks, and versions from manifest files (`package.json`, `requirements.txt`, `pyproject.toml`, `go.mod`, `Cargo.toml`, etc.). Note the active package manager from lockfiles.
44
+ - **Commands**: Real dev, build, test, lint, and verify scripts.
45
+ - **Conventions in Practice**: Directory layout, component naming, state management, styling, data-fetching, error handling, validation. Read what the code *actually does*.
46
+ - **Testing Reality**: Inspect existing test suites, runners, and coverage. Be honest about test status.
47
+ - **Shipped Capabilities & Architecture**: Inferred from routes, pages, controllers, database schemas, and entry points.
48
+
49
+ Keep structured notes for generation in Step 3.
50
+
51
+ ---
52
+
53
+ ## Step 2 - Interview for Intent
54
+
55
+ The code reveals *what* and *how*, but not *why* or *what next*. Ask a short set of 3-4 questions to fill the gaps:
56
+
57
+ 1. **Purpose & Users**: What is the core problem this project solves, and who are the target users?
58
+ 2. **Architecture Status**: Is the current structure and stack intentional, or are there legacy parts/technical debt the team wants to change or refactor?
59
+ 3. **Upcoming Roadmap**: What are the top priorities to build, fix, or refactor next?
60
+ 4. **Clarifications**: Anything the survey got wrong or missed?
61
+
62
+ *(If the user already provided this context in the prompt, skip questions that are already answered).*
63
+
64
+ ---
65
+
66
+ ## Step 3 - Generate the Context Artifacts
67
+
68
+ Write the baseline context files drawn from the survey (facts) and interview (intent):
69
+
70
+ 1. **`devflow/context/project-overview.md`**:
71
+ - Project Name, Purpose, and Target Users
72
+ - Architecture summary and directory layout
73
+ - Shipped capabilities and existing major modules
74
+ - Key technical stack components and verified commands
75
+ - Known technical debt or architectural focus areas
76
+
77
+ 2. **`devflow/context/coding-standards.md`**:
78
+ - Rewrite defaults to reflect the project's *actual* conventions discovered in Step 1
79
+ - Framework patterns, state management, error handling, styling, and test rules based on real code
80
+
81
+ 3. **`AGENTS.md` Commands Section**:
82
+ - Fill in the real dev, build, test, lint, and verify commands found during survey.
83
+
84
+ ---
85
+
86
+ ## Step 4 - Review Gate and Handoff
87
+
88
+ Present the adoption summary for review:
89
+
90
+ - Shipped features and architectural baseline recorded
91
+ - Inferred conventions and coding standards
92
+ - Available verified commands in `AGENTS.md`
93
+ - Recommended next step:
94
+ - Run `00-discover` (or `/00-discover`, `$00-discover`) to explore the next major initiative or feature
95
+ - Run `10-define` (or `/10-define`, `$10-define`) to immediately scope a delivery run for known roadmap items
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: devflow
3
- description: Flagship interactive guide, intent router, workspace state inspector, and sitemap for Nexus-DevFlow workflows. Inspects current workspace state, maps natural language requests to matching stages/commands, and provides a cheat sheet of all available DevFlow skills. Use when the user runs /devflow, asks how to use devflow, asks what command to run next, or needs guidance on DevFlow lifecycle paths.
3
+ description: Flagship interactive guide, intent router, workspace state inspector, and sitemap for Nexus-DevFlow workflows. Inspects current workspace state, maps natural language requests to matching stages/commands, and provides a cheat sheet of all available DevFlow skills. Use when the user runs devflow, /devflow, $devflow, status, asks how to use devflow, asks what command to run next, or needs guidance on DevFlow lifecycle paths.
4
4
  ---
5
5
 
6
6
  # devflow - Interactive Workflow Guide & Intent Router for Nexus-DevFlow
@@ -9,78 +9,87 @@ Use this skill to guide the user on what to do next, inspect current workspace s
9
9
 
10
10
  ## Input
11
11
 
12
- - **No argument (`/devflow`)**: Inspect current workspace state (active run in `devflow/runs/` or `devflow/context/current-stage.md`, active discovery in `devflow/discoveries/`, open findings in `devflow/context/findings.md`, and project overview in `devflow/context/project-overview.md`) and recommend the exact next action.
13
- - **With user request (`/devflow "<request>"`)**: Classify the user's intent and guide them to the matching DevFlow 2.0 stage or companion command path.
12
+ - **No argument (`devflow`, `/devflow`, `$devflow`, or `status`)**: Inspect current workspace state (active run in `devflow/runs/` or `devflow/context/current-stage.md`, active discovery in `devflow/discoveries/`, open findings in `devflow/context/findings.md`, and project overview in `devflow/context/project-overview.md`) and recommend the exact next action.
13
+ - **With user request (`devflow "<request>"`)**: Classify the user's intent and guide them to the matching DevFlow 2.0 stage or companion command path.
14
14
 
15
15
  ## Workspace State Inspection
16
16
 
17
17
  When invoked without an argument (or when determining the next step), inspect:
18
18
 
19
- 1. **Active Delivery Run**: Read `devflow/context/current-stage.md` and check `devflow/runs/{RUNNING_ID}/` for active artifacts (`10-define.md`, `20-spec.md`, `30-plan.md`, `40-implement.md`, `50-verify.md`, `60-report.md`, `70-release.md`).
20
- 2. **Active Discovery**: Check `devflow/discoveries/` for open discovery notes.
21
- 3. **Audit Findings Ledger**: Check `devflow/context/findings.md` for open high-severity findings.
22
- 4. **Project Overview**: Read `devflow/context/project-overview.md` for overall stack and context.
19
+ 1. **Project Setup Baseline**: Read `devflow/context/project-overview.md` and `devflow/context/coding-standards.md`. If they are empty or default placeholders, recommend `/onboard` (for fresh projects) or `/adopt` (for existing codebases).
20
+ 2. **Active Delivery Run**: Read `devflow/context/current-stage.md` and check `devflow/runs/{RUNNING_ID}/` for active artifacts (`10-define.md`, `20-spec.md`, `30-plan.md`, `40-implement.md`, `50-verify.md`, `60-report.md`, `70-release.md`).
21
+ 3. **Active Discovery**: Check `devflow/discoveries/` for open discovery notes.
22
+ 4. **Audit Findings Ledger**: Check `devflow/context/findings.md` for open high-severity findings.
23
23
 
24
24
  ### State-Based Recommendation Rules
25
25
 
26
- - If a run is at `10-define.md` -> Recommend `/20-spec {RUNNING_ID}`.
27
- - If a run is at `20-spec.md` -> Recommend `/30-plan {RUNNING_ID}`.
28
- - If a run is at `30-plan.md` -> Recommend `/40-implement {RUNNING_ID}`.
29
- - If a run is at `40-implement.md` with incomplete tasks -> Recommend `/40-implement {RUNNING_ID}`.
30
- - If a run is at `40-implement.md` with all tasks done -> Recommend `/50-verify {RUNNING_ID}`.
31
- - If a run passed `50-verify.md` -> Recommend `/60-report {RUNNING_ID}` then `/70-release {RUNNING_ID}`.
32
- - If no run is active and user wants to explore an idea -> Recommend `/00-discover` or `Brainstorm`.
33
- - If no run is active and open P0/P1 findings exist -> Recommend `Security-Review` or `Debug`.
26
+ - If context is empty/unconfigured -> Recommend `onboard` (for fresh project) or `adopt` (for brownfield codebase).
27
+ - If a run is at `10-define.md` -> Recommend `20-spec {RUNNING_ID}` (or `/20-spec`, `$20-spec`, `spec`).
28
+ - If a run is at `20-spec.md` -> Recommend `30-plan {RUNNING_ID}` (or `/30-plan`, `$30-plan`, `plan`).
29
+ - If a run is at `30-plan.md` -> Recommend `40-implement {RUNNING_ID}` (or `/40-implement`, `$40-implement`, `implement`).
30
+ - If a run is at `40-implement.md` with incomplete tasks -> Recommend `40-implement {RUNNING_ID}`.
31
+ - If a run is at `40-implement.md` with all tasks done -> Recommend `50-verify {RUNNING_ID}` (or `/50-verify`, `$50-verify`, `verify`).
32
+ - If a run passed `50-verify.md` -> Recommend `60-report {RUNNING_ID}` then `70-release {RUNNING_ID}`.
33
+ - If no run is active and user wants to explore an idea -> Recommend `00-discover` (or `discover`, `Brainstorm`).
34
+ - If no run is active and open P0/P1 findings exist -> Recommend `security-review` or `debug`.
35
+ - If user asks to check system health or configuration -> Recommend `doctor` (or `/doctor`, `$doctor`).
34
36
 
35
37
  ## Intent Classification & Skill Routing
36
38
 
37
39
  When the user specifies a request, map it to the matching DevFlow 2.0 stage or companion command:
38
40
 
39
- | User Intent / Request Type | Recommended Skill | Lifecycle Path |
40
- | --- | --- | --- |
41
- | "Explore a new request / idea" | `/00-discover` | `/00-discover` -> `/10-define` -> `/20-spec` -> ... |
42
- | "Define delivery boundaries and ID" | `/10-define` | `/10-define` -> `/20-spec` -> `/30-plan` |
43
- | "Write formal markdown specification" | `/20-spec` | `/20-spec` -> `/30-plan` -> `/40-implement` |
44
- | "Break down spec into actionable plan" | `/30-plan` | `/30-plan` -> `/40-implement` -> `/50-verify` |
45
- | "Execute code implementation" | `/40-implement` | `/40-implement` -> `/50-verify` |
46
- | "Verify code quality & QA review" | `/50-verify` | `/50-verify` -> `/60-report` -> `/70-release` |
47
- | "Generate summary HTML/MD report" | `/60-report` | `/60-report` -> `/70-release` |
48
- | "Package for PR merge or deployment" | `/70-release` | `/70-release` |
49
- | "High-level goal or long-running task" | `Goal` | `Goal` -> `/00-discover` |
50
- | "Brainstorm ideas without allocating ID" | `Brainstorm` | `Brainstorm` -> `/00-discover` |
51
- | "Deep codebase or web research" | `Research` | `Research` |
52
- | "Investigate failure or root cause" | `Debug` | `Debug` -> `/40-implement` or `/10-define` |
53
- | "Product framing & PRD creation" | `PRD` | `PRD` -> `/00-discover` |
54
- | "Intake and triage incoming bugs" | `Issue-Triage` | `Issue-Triage` -> `Debug` or `/10-define` |
55
- | "High-severity security audit" | `Security-Review` | `Security-Review` |
56
- | "Manage project knowledge base" | `Wiki` | `Wiki` |
57
- | "Verify or update DevFlow setup" | `Check-For-Updates` | `Check-For-Updates` |
41
+ | User Intent / Request Type | Recommended Skill | Normal Name / Alias | Lifecycle Path |
42
+ | :--- | :--- | :--- | :--- |
43
+ | "Setup DevFlow on fresh/new project" | `onboard` | `onboard` / `setup` | `onboard` -> `00-discover` or `10-define` |
44
+ | "Adopt DevFlow on existing codebase" | `adopt` | `adopt` / `bootstrap` | `adopt` -> `00-discover` or `10-define` |
45
+ | "Check setup health & diagnostics" | `doctor` | `doctor` / `health` | `doctor` |
46
+ | "Explore a new request / idea" | `00-discover` | `discover` | `00-discover` -> `10-define` -> `20-spec` -> ... |
47
+ | "Define delivery boundaries and ID" | `10-define` | `define` | `10-define` -> `20-spec` -> `30-plan` |
48
+ | "Write formal markdown specification" | `20-spec` | `spec` | `20-spec` -> `30-plan` -> `40-implement` |
49
+ | "Break down spec into actionable plan" | `30-plan` | `plan` | `30-plan` -> `40-implement` -> `50-verify` |
50
+ | "Execute code implementation" | `40-implement` | `implement` | `40-implement` -> `50-verify` |
51
+ | "Verify code quality & QA review" | `50-verify` | `verify` | `50-verify` -> `60-report` -> `70-release` |
52
+ | "Generate summary HTML/MD report" | `60-report` | `report` | `60-report` -> `70-release` |
53
+ | "Package for PR merge or deployment" | `70-release` | `release` | `70-release` |
54
+ | "High-level goal or long-running task" | `goal` | `goal` | `goal` -> `00-discover` |
55
+ | "Brainstorm ideas without allocating ID" | `brainstorm` | `brainstorm` | `brainstorm` -> `00-discover` |
56
+ | "Deep codebase or web research" | `research` | `research` | `research` |
57
+ | "Investigate failure or root cause" | `debug` | `debug` | `debug` -> `40-implement` or `10-define` |
58
+ | "Product framing & PRD creation" | `prd` | `prd` | `prd` -> `00-discover` |
59
+ | "Intake and triage incoming bugs" | `issue-triage` | `issue-triage` | `issue-triage` -> `debug` or `10-define` |
60
+ | "High-severity security audit" | `security-review` | `security-review` | `security-review` |
61
+ | "Manage project knowledge base" | `wiki` | `wiki` | `wiki` |
62
+ | "Verify or update DevFlow setup" | `check-for-updates` | `check-for-updates` | `check-for-updates` |
58
63
 
59
64
  ## Available Skills Sitemap
60
65
 
61
66
  Always provide a clean summary of available Nexus-DevFlow skills grouped by lifecycle stage:
62
67
 
63
68
  ### 1. Mainline Lifecycle Stages (Linear Order)
64
- - `/00-discover` - Explore request, route inquiries, go/no-go under Discovery ID
65
- - `/10-define` - Lock delivery boundaries and allocate Running ID (`devflow/runs/{ID}`)
66
- - `/20-spec` - Formalize markdown-first specifications and acceptance criteria
67
- - `/30-plan` - Transform spec into executable task breakdown
68
- - `/40-implement` - Execute planned tasks incrementally with evidence
69
- - `/50-verify` - Senior QA review, validation checks, and pass/fail gate
70
- - `/60-report` - Generate standardized markdown and HTML summary report
71
- - `/70-release` - Package verified work for PR merge or deployment
69
+ - `00-discover` (`discover`, `/00-discover`, `$00-discover`) - Explore request, route inquiries, go/no-go under Discovery ID
70
+ - `10-define` (`define`, `/10-define`, `$10-define`) - Lock delivery boundaries and allocate Running ID (`devflow/runs/{ID}`)
71
+ - `20-spec` (`spec`, `/20-spec`, `$20-spec`) - Formalize markdown-first specifications and acceptance criteria
72
+ - `30-plan` (`plan`, `/30-plan`, `$30-plan`) - Transform spec into executable task breakdown with test decisions
73
+ - `40-implement` (`implement`, `/40-implement`, `$40-implement`) - Execute planned tasks incrementally with evidence
74
+ - `50-verify` (`verify`, `/50-verify`, `$50-verify`) - Senior QA review, validation checks, and pass/fail gate
75
+ - `60-report` (`report`, `/60-report`, `$60-report`) - Generate standardized markdown and HTML summary report
76
+ - `70-release` (`release`, `/70-release`, `$70-release`) - Package verified work for PR merge or deployment
72
77
 
73
78
  ### 2. Public Companion Commands
74
- - `Goal` - Route broad goals before Discovery
75
- - `Brainstorm` - Ideate without allocating running IDs
76
- - `Research` - Conduct codebase or web research
77
- - `Debug` - Root cause investigation before or during implementation
78
- - `PRD` - Product framing before delivery commitment
79
- - `Issue-Triage` - Intake and triage incoming bug reports
80
- - `Security-Review` - High-severity security review
81
- - `Wiki` - Knowledge base management under `devflow/wiki/`
82
- - `Check-For-Updates` - Verify or upgrade DevFlow setup
83
- - `Help` - Process assistance and stage routing
79
+ - `devflow` (`status`, `/devflow`, `$devflow`) - Guide, state inspector, and intent router
80
+ - `onboard` (`/onboard`, `$onboard`) - Baseline stack setup for freshly scaffolded projects
81
+ - `adopt` (`/adopt`, `$adopt`) - Survey and bootstrap DevFlow into existing brownfield projects
82
+ - `doctor` (`/doctor`, `$doctor`) - Read-only health check for setup, scripts, and workflow drift
83
+ - `goal` - Route broad goals before Discovery
84
+ - `brainstorm` - Ideate without allocating running IDs
85
+ - `research` - Conduct codebase or web research
86
+ - `debug` - Root cause investigation before or during implementation
87
+ - `prd` - Product framing before delivery commitment
88
+ - `issue-triage` - Intake and triage incoming bug reports
89
+ - `security-review` - High-severity security review
90
+ - `wiki` - Knowledge base management under `devflow/wiki/`
91
+ - `check-for-updates` - Verify or upgrade DevFlow setup
92
+ - `help` - Process assistance and stage routing
84
93
 
85
94
  ### 3. Engineering & Specialist Skills
86
95
  - **Frontend & UI**: `frontend-ui-engineering`, `nextjs-react-expert`, `tailwind-patterns`, `ui-ux-pro-max`, `mobile-design`
@@ -0,0 +1,84 @@
1
+ ---
2
+ name: doctor
3
+ description: Read-only DevFlow health check and diagnostics. Inspects DevFlow setup, tool adapters, context files integrity, AGENTS.md commands validity, active runs in devflow/runs/, checklist completeness, and detects workflow drift. Use when the user runs doctor, /doctor, $doctor, asks to diagnose DevFlow, or wants to check project workflow health.
4
+ ---
5
+
6
+ # doctor - Read-Only DevFlow Health Check & Diagnostics
7
+
8
+ Where this sits in the workflow:
9
+
10
+ ```text
11
+ Any time during development -> [doctor] -> Health Report & Actionable Fixes
12
+ (read-only inspection) (diagnostics) (remediation recommendations)
13
+ ```
14
+
15
+ `/doctor` is a safe, read-only diagnostic skill that verifies whether your repository's Nexus-DevFlow configuration, context files, tool adapters, commands, and active runs are healthy and aligned.
16
+
17
+ ---
18
+
19
+ ## Input
20
+
21
+ No argument is required.
22
+
23
+ ---
24
+
25
+ ## Diagnostics Checklist
26
+
27
+ Run through these 5 health checks:
28
+
29
+ ### Check 1: Core Framework & Context Files Integrity
30
+ - Check if [AGENTS.md](AGENTS.md) and [CLAUDE.md](CLAUDE.md) exist and are populated.
31
+ - Check required context files under `devflow/context/`:
32
+ - `project-overview.md` (Check if still empty/placeholder -> recommend `/onboard` or `/adopt`)
33
+ - `coding-standards.md` (Check if customized for stack)
34
+ - `ai-interaction.md` (Check if rules are configured)
35
+ - `current-stage.md` (Check if active run matches filesystem)
36
+ - `findings.md` (Check if ledger exists)
37
+
38
+ ### Check 2: Tool Adapters Parity
39
+ - Check if `.agents/skills/` exists and contains core lifecycle skills (`00-discover` through `70-release`, `devflow`, `onboard`, `adopt`, `doctor`).
40
+ - Check if `.claude/skills/` is in sync with `.agents/skills/`.
41
+
42
+ ### Check 3: Commands & Script Verification
43
+ - Inspect the Commands section in `AGENTS.md`.
44
+ - Cross-reference with project manifest (`package.json`, `pyproject.toml`, `Cargo.toml`, etc.):
45
+ - Does the `Dev` command exist in scripts?
46
+ - Does the `Build` command exist in scripts?
47
+ - Does the `Test` command exist in scripts?
48
+ - Does the `Verify` command exist in scripts?
49
+
50
+ ### Check 4: Active Runs & Workflow Drift Detection
51
+ - Inspect `devflow/runs/`:
52
+ - Are there active runs?
53
+ - Is `current-stage.md` consistent with the latest stage artifact in the active run?
54
+ - Are checklists (`checklists/implementation-checklist.md`, `checklists/verification-checklist.md`) properly tracked?
55
+ - Detect stage skips or workflow drift (e.g. jumping from `10-define` directly to `40-implement` without `20-spec` and `30-plan`).
56
+
57
+ ### Check 5: Findings Ledger Inspection
58
+ - Inspect `devflow/context/findings.md`:
59
+ - Are there open P0 or P1 findings that block release?
60
+ - Are resolved findings properly closed?
61
+
62
+ ---
63
+
64
+ ## Output Format
65
+
66
+ Present a clean, scannable diagnostic report:
67
+
68
+ ```markdown
69
+ # 🩺 Nexus-DevFlow Health Report
70
+
71
+ ## Overall Status: [HEALTHY | WARNING | ACTION REQUIRED]
72
+
73
+ | Component | Status | Details |
74
+ | :--- | :--- | :--- |
75
+ | **Context Files** | [PASS / WARN] | project-overview.md, coding-standards.md status |
76
+ | **Tool Adapters** | [PASS / WARN] | .agents and .claude parity |
77
+ | **Configured Commands**| [PASS / WARN] | dev, build, test, verify alignment |
78
+ | **Active Runs & Drift**| [PASS / WARN] | active run status, stage progression |
79
+ | **Findings Ledger** | [PASS / WARN] | open P0/P1 issues count |
80
+
81
+ ### Recommended Remediation Actions:
82
+ 1. [Action item if any warning or failure detected]
83
+ 2. [Suggested next command, e.g. /devflow, /onboard, /adopt, etc.]
84
+ ```
@@ -0,0 +1,129 @@
1
+ ---
2
+ name: onboard
3
+ description: Set up Nexus-DevFlow after overlaying it onto a freshly scaffolded or early project. Detects the stack, tunes AGENTS.md commands and conventions, customizes coding-standards.md, checks .gitignore and tool adapters, initializes project-overview.md, and guides the user to /00-discover or /10-define. Use when the user runs onboard, /onboard, $onboard, just installed DevFlow into a new project, or asks what to do after installation. For an existing app with meaningful shipped features, use adopt instead.
4
+ ---
5
+
6
+ # onboard - Finish the Nexus-DevFlow Setup for Fresh Projects
7
+
8
+ Where this sits in the workflow:
9
+
10
+ ```text
11
+ scaffold app -> overlay DevFlow -> [onboard] -> /00-discover or /10-define -> Mainline Loop
12
+ (user/tool) (create-nexus) (tune setup) (discovery / run scoping) (20-spec -> 70-release)
13
+ ```
14
+
15
+ `/onboard` is the fresh-project on-ramp for Nexus-DevFlow. It assumes the application was scaffolded first (e.g. via `create-next-app`, `create-vite`, `cargo new`, etc.) and DevFlow was overlaid after.
16
+
17
+ Run `/onboard` before starting discovery or delivery runs. Its job is to make DevFlow fit the real project from day one: detecting commands, project name, coding conventions, ignore rules, and tool adapters.
18
+
19
+ Use `/adopt` instead when the app already has substantial shipped code, working routes, and existing business logic.
20
+
21
+ ---
22
+
23
+ ## Input
24
+
25
+ No argument is required. If the user provides context about the stack, database, authentication, or preferred tooling, use it as a hint and verify against files.
26
+
27
+ ---
28
+
29
+ ## Step 0 - Confirm Onboarding vs Adoption
30
+
31
+ Inspect the repository and context files:
32
+
33
+ - If the project is freshly scaffolded with minimal boilerplate, proceed.
34
+ - If `devflow/context/project-overview.md` and `devflow/context/coding-standards.md` already contain rich, user-customized content, do not overwrite them without explicit confirmation.
35
+ - If the repository already has substantial existing routes, controllers, or database models, stop and recommend `/adopt` instead.
36
+
37
+ Never run a framework scaffolder. DevFlow is already overlaid.
38
+
39
+ ---
40
+
41
+ ## Step 1 - Survey the Project Facts
42
+
43
+ Read only enough to identify the setup:
44
+
45
+ - **Package Manager & Lockfile**: `pnpm-lock.yaml`, `package-lock.json`, `yarn.lock`, `bun.lockb`, `Cargo.lock`, `poetry.lock`, `go.sum`, etc.
46
+ - **Manifest Scripts**: `package.json`, `pyproject.toml`, `go.mod`, `Cargo.toml`, etc.
47
+ - **Framework & Configs**: `tsconfig.json`, `next.config.*`, `vite.config.*`, `astro.config.*`, `tailwind.config.*`, database configs, test configs.
48
+ - **Source Layout**: `src/`, `app/`, `pages/`, `components/`, `lib/`, etc.
49
+ - **Existing Git & Ignore Rules**: `.gitignore`, git branches.
50
+ - **Project Name**: Extracted from manifest, root directory, or user.
51
+
52
+ ---
53
+
54
+ ## Step 2 - Update Entry Files (AGENTS.md & CLAUDE.md)
55
+
56
+ 1. **Update `AGENTS.md` Commands**:
57
+ - Fill in the actual commands found in the project:
58
+ - `Dev`: dev server command (e.g. `npm run dev`)
59
+ - `Build`: production build command (e.g. `npm run build`)
60
+ - `Test`: test runner command (e.g. `npm test`, `vitest`, `pytest`)
61
+ - `Lint / Typecheck`: linting and typechecking commands
62
+ - `Verify`: combined verification command if present (e.g. `npm run check` or `npm run typecheck && npm test && npm run build`)
63
+ - If no test command exists, state explicitly that testing is opt-in and not yet configured.
64
+
65
+ 2. **Update `CLAUDE.md`**:
66
+ - Replace any `# Project Name` placeholder with the real detected project name.
67
+ - Keep `@AGENTS.md` and `@devflow/context/...` imports intact.
68
+
69
+ ---
70
+
71
+ ## Step 3 - Tune Coding Standards
72
+
73
+ Update `devflow/context/coding-standards.md` to match the detected stack:
74
+
75
+ - Framework, rendering model, and component architecture
76
+ - Package manager and runtime
77
+ - Project directory conventions
78
+ - Styling approach (Tailwind CSS, Vanilla CSS, CSS Modules)
79
+ - Data fetching, state management, and API boundaries
80
+ - Validation and error handling expectations
81
+ - Testing expectations
82
+
83
+ Keep core general rules (functional style, small focused functions, clear naming) and replace template placeholders with real patterns.
84
+
85
+ ---
86
+
87
+ ## Step 4 - Check AI Interaction Rules
88
+
89
+ Review `devflow/context/ai-interaction.md` and adjust if needed:
90
+ - Language preferences (`artifact_language: "th"` or `"en"`)
91
+ - Branching conventions
92
+ - Review checkpoint expectations
93
+
94
+ ---
95
+
96
+ ## Step 5 - Check Ignore Files, Visibility & Tool Adapters
97
+
98
+ 1. **Update `.gitignore`**: Ensure common build artifacts, dependencies, and environment files are ignored.
99
+ 2. **DevFlow Visibility**:
100
+ - By default, keep DevFlow files tracked in git for team collaboration.
101
+ - If local-only mode is requested, add `devflow/`, `.agents/`, `.claude/`, `CLAUDE.md` to `.gitignore` while keeping `AGENTS.md` public.
102
+ 3. **Tool Adapters**:
103
+ - Codex & Antigravity use `.agents/skills/`.
104
+ - Claude Code uses `.claude/skills/`.
105
+ - Both can coexist cleanly.
106
+
107
+ ---
108
+
109
+ ## Step 6 - Initialize Project Overview
110
+
111
+ Populate `devflow/context/project-overview.md` with baseline information:
112
+ - Project Name and One-line Summary
113
+ - Tech Stack & Tooling Architecture
114
+ - Initial Repository Structure
115
+ - Available Verified Commands
116
+
117
+ ---
118
+
119
+ ## Step 7 - Handoff to Planning
120
+
121
+ Present a concise onboarding summary report:
122
+
123
+ - Stack, framework, and package manager detected
124
+ - Commands configured in `AGENTS.md`
125
+ - Files tuned during onboarding
126
+ - Adapter status (`.agents/`, `.claude/`)
127
+ - Recommended next step:
128
+ - Run `00-discover` (or `/00-discover`, `$00-discover`) to explore the first feature or product direction
129
+ - Run `10-define` (or `/10-define`, `$10-define`) if the initial delivery slice is already clear and ready for execution