@jakkrichm/create-nexus-devflow 2.1.0 → 2.2.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 (56) hide show
  1. package/dist/bin/create-nexus-devflow.js +28 -4
  2. package/dist/bin/create-nexus-devflow.js.map +1 -1
  3. package/dist/lib/project-metadata.d.ts +1 -1
  4. package/dist/lib/project-metadata.js +3 -2
  5. package/dist/lib/project-metadata.js.map +1 -1
  6. package/dist/lib/update.js +7 -3
  7. package/dist/lib/update.js.map +1 -1
  8. package/package.json +1 -1
  9. package/template/.agents/skills/adopt/SKILL.md +58 -5
  10. package/template/.agents/skills/doctor/SKILL.md +23 -16
  11. package/template/.agents/skills/implement/SKILL.md +2 -2
  12. package/template/.agents/skills/onboard/SKILL.md +18 -17
  13. package/template/.agents/skills/rollback/SKILL.md +1 -1
  14. package/template/.claude/skills/00-explore/SKILL.md +2 -2
  15. package/template/.claude/skills/10-define/SKILL.md +2 -2
  16. package/template/.claude/skills/20-spec/SKILL.md +1 -2
  17. package/template/.claude/skills/30-plan/SKILL.md +1 -2
  18. package/template/.claude/skills/40-execute/SKILL.md +2 -2
  19. package/template/.claude/skills/50-verify/SKILL.md +2 -2
  20. package/template/.claude/skills/60-report/SKILL.md +2 -2
  21. package/template/.claude/skills/70-deliver/SKILL.md +2 -2
  22. package/template/.claude/skills/adopt/SKILL.md +191 -75
  23. package/template/.claude/skills/audit/SKILL.md +267 -133
  24. package/template/.claude/skills/autopilot/SKILL.md +226 -167
  25. package/template/.claude/skills/brainstorm/SKILL.md +62 -0
  26. package/template/.claude/skills/brief/SKILL.md +93 -92
  27. package/template/.claude/skills/check/SKILL.md +96 -76
  28. package/template/.claude/skills/ci/SKILL.md +140 -61
  29. package/template/.claude/skills/complete/SKILL.md +156 -101
  30. package/template/.claude/skills/convert-any-to-md/SKILL.md +2 -2
  31. package/template/.claude/skills/convert-any-to-md/references/setup.md +29 -0
  32. package/template/.claude/skills/convert-any-to-md/scripts/convert_any_to_md.py +487 -0
  33. package/template/.claude/skills/convert-any-to-md/scripts/requirements.txt +3 -0
  34. package/template/.claude/skills/debug/SKILL.md +124 -49
  35. package/template/.claude/skills/devflow/SKILL.md +9 -3
  36. package/template/.claude/skills/discovery/SKILL.md +150 -129
  37. package/template/.claude/skills/doctor/SKILL.md +195 -72
  38. package/template/.claude/skills/feature/SKILL.md +195 -151
  39. package/template/.claude/skills/fix/SKILL.md +41 -90
  40. package/template/.claude/skills/idea/SKILL.md +2 -2
  41. package/template/.claude/skills/implement/SKILL.md +189 -46
  42. package/template/.claude/skills/onboard/SKILL.md +216 -85
  43. package/template/.claude/skills/overview/SKILL.md +44 -29
  44. package/template/.claude/skills/prototype/SKILL.md +82 -27
  45. package/template/.claude/skills/release/SKILL.md +119 -130
  46. package/template/.claude/skills/report-html/SKILL.md +2 -2
  47. package/template/.claude/skills/rollback/SKILL.md +123 -77
  48. package/template/.claude/skills/status/SKILL.md +109 -0
  49. package/template/.claude/skills/test/SKILL.md +2 -2
  50. package/template/.claude/skills/tests/SKILL.md +126 -0
  51. package/template/.claude/skills/try/SKILL.md +77 -65
  52. package/template/AGENTS.md +2 -1
  53. package/template/devflow/build-plan.md +8 -0
  54. package/template/devflow/history/features/README.md +5 -0
  55. package/template/devflow/history/fixes/README.md +5 -0
  56. package/template/devflow/history/rollbacks/README.md +5 -0
@@ -1,157 +1,201 @@
1
1
  ---
2
2
  name: feature
3
- description: "[Devflow] Fast-Track Feature stage in DevFlow (Blueprint Mode) - turn a build-plan item, sub-feature (4a, 4b), idea, or requirement into the living current-feature.md contract with automatic sizing & splitting."
4
- argument-hint: "{feature title, number, 4a, IDEA-xxx, or empty for next item}"
3
+ description: "[devflow][F] Turn a feature from build-plan.md into a buildable spec. With no argument, specs the next unchecked item in the build plan; given a number or name, specs that one. If a clearly new feature does not match the plan, proposes a reviewed plan addition, refreshes the overview after approval, then specs it. Sizes the feature and splits anything too big into smaller sub-features (4a, 4b, ...), writes small, reviewable build steps to devflow/context/current-feature.md, then red-teams its own draft for gaps, oversized steps, and scope creep before stopping at a review gate. Use when the user runs /feature, names or numbers a feature, asks to add and start a new feature, or asks to spec out, break down, or start the next feature."
5
4
  ---
6
5
 
7
- # Fast-Track: Feature (Blueprint Mode)
6
+ # feature - turn a build-plan feature into a buildable spec
8
7
 
9
- $ARGUMENTS
8
+ Where this sits in the workflow:
9
+
10
+ project-overview.md + build-plan.md -> [this skill] -> build
11
+ (source of truth, (which feature (the spec for (code,
12
+ from /overview) to build) one feature) reviewed)
10
13
 
11
- Fast-Track entry point combining Discovery, Definition, Specification, and Implementation Planning into one streamlined, review-gated step for **new features or enhancements**. Creates and maintains the **Single Living Spec (`devflow/context/current-feature.md`)** for the feature run. Supports intake from Build Plan (`devflow/build-plan.md`), Sub-features (`4a`, `4b`), or Idea Inbox (`IDEA-xxx`).
12
-
13
- Includes built-in **Multi-Factor Sizing Heuristic & Interactive Split Gate** to prevent context overflow on oversized tasks (`L`/`XL`).
14
-
15
- ---
16
-
17
- ## Invocations & Aliases
18
-
19
- - `/feature`: Specs the next unchecked feature from `devflow/build-plan.md`
20
- - `/feature <number | title>`: Specs a specific feature from the build plan or a new requirement
21
- - `/feature <number[a-z]>` (e.g. `/feature 4a`): Specs a specific sub-feature
22
- - `/feature IDEA-xxx`: Intake and promote a pending idea from `devflow/ideas.md`
23
- - `$feature`: Codex CLI invocation
24
-
25
- ---
26
-
27
- ## Fast-Track Mainline Workflow
28
-
29
- ```text
30
- /feature (หรือ /fix) ──▶ /implement ──▶ /check ──▶ /complete
31
- ```
32
-
33
- ---
34
-
35
- ## Behavior & Contract
36
-
37
- When invoked:
38
-
39
- ### 1. Single Active Run Guardrail (One Thing at a Time)
40
- 1. Inspect `devflow/context/current-stage.md` and `devflow/context/current-feature.md`.
41
- 2. If `Active Running ID` is not `None` and `Current Stage` is not `Idle`, or if `current-feature.md` contains an active uncompleted spec:
42
- - **HALT and reject opening a new feature**.
43
- - Explain to the user that an active run is currently in progress:
44
- > ⚠️ *"มีงาน `{active_id}` กำลังดำเนินการอยู่ กรุณาปิดงานเดิมด้วย `/complete` หรือ `70-deliver` (หรือสั่ง `/rollback`) ก่อนเริ่มงานใหม่"*
45
-
46
- ---
47
-
48
- ### 2. Sizing Heuristic & Sub-Feature Splitting Engine
49
-
50
- Before locking the spec, evaluate the target scope:
51
-
52
- 1. **Multi-Factor Sizing Heuristic**:
53
- - **Files Touched**: $\ge 6$ files predicted to be created or modified.
54
- - **Architectural Layers**: $\ge 3$ distinct layers (e.g. DB Schema/Migration + Backend API + Frontend UI + State Store).
55
- - **Task Complexity**: $\ge 6$ checklist tasks or heavy multi-service integrations.
56
- 2. **Interactive Split Gate**:
57
- - If the feature is assessed as `L` or `XL` and no explicit sub-feature notation (`4a`) was requested:
58
- - **Draft Sub-Feature Proposals**: Break into 2-3 focused sub-features (e.g. `4a: Backend Schema & Core APIs (Size: M)`, `4b: Frontend UI & Client State (Size: M)`).
59
- - **Prompt User in Thai**:
60
- > ⚠️ *"ฟีเจอร์นี้มีขนาดใหญ่ (`L`/`XL`) เพื่อรักษาคุณภาพและป้องกัน Context Overflow แนะนำให้แบ่งเป็น sub-features ดังนี้:*
61
- > *- `4a: [ขอบเขตย่อยส่วนที่ 1]` (Size: M)*
62
- > *- `4b: [ขอบเขตย่อยส่วนที่ 2]` (Size: M)*
63
- > *คุณต้องการให้เปิด Spec เริ่มทำ `4a` ทันทีเลยไหมครับ?"*
64
- - If the user confirms or provides a sub-feature argument (e.g. `4a`), proceed with the sub-feature spec.
65
-
66
- ---
67
-
68
- ### 3. Work Identity & Source Resolution
69
-
70
- 1. **No Argument**:
71
- - Inspect `devflow/build-plan.md` (or `devflow/ideas.md`).
72
- - Pick the first unchecked feature (`- [ ]`) or sub-feature (`- [ ] 4a.`) in sequence.
73
- 2. **Sub-Feature Notation** (e.g. `4a`, `038b-slug`):
74
- - Allocate sub-feature running ID with alpha suffix: `xxx[a-z]-slug` (e.g. `038a-auth-schema-and-api`).
75
- - Set Git branch: `feature/xxx[a-z]-slug`.
76
- 3. **Idea Inbox Intake** (e.g. `IDEA-001`):
77
- - Read `devflow/ideas.md` and extract the idea's title, raw problem statement, AI Feasibility notes, and Quick Seed points.
78
- - In `devflow/ideas.md`, update the item's status to `[x] Claimed ({ID})` and move it under `## 📦 Archived / Shipped Ideas`.
79
- 4. **Number or Title**:
80
- - Match item in `devflow/build-plan.md` or treat as a new planned addition.
81
- 5. Determine next sequential ID:
82
- - For standard feature: `xxx-slug` (e.g. `038-payment-gateway`).
83
- - For sub-feature: `xxx[a-z]-slug` (e.g. `038a-payment-api`, `038b-payment-ui`).
84
- 6. Identify Git branch naming:
85
- - `feature/{ID}`
86
-
87
- ---
88
-
89
- ### 4. Generate the Living Spec (`devflow/context/current-feature.md`)
90
-
91
- Write `devflow/context/current-feature.md` using the structured template below in **Thai (`th`)**:
92
-
93
- ```markdown
94
- # 📐 [{ID}] {Feature Title} (Living Spec)
95
-
96
- > **Status**: In-Progress
97
- > **Track**: Fast-Track (Blueprint Mode - Feature)
98
- > **Category**: Feature
99
- > **Branch**: `{branch_name}`
100
- > **Created Date**: {YYYY-MM-DD}
101
- > **Owner**: {Contributor or Team}
102
-
103
- ---
104
-
105
- ## 1. Specification & Scope
106
- - **Problem Statement**: {ปัญหาหรือที่มาของฟีเจอร์นี้}
107
- - **In-Scope**:
108
- - {ขอบเขตสิ่งที่ต้องทำสำหรับฟีเจอร์นี้}
109
- - **Out-of-Scope**:
110
- - {สิ่งที่ไม่ทำในรอบนี้}
111
- - **Acceptance Criteria**:
112
- - [ ] AC-1: {เงื่อนไขการตรวจรับข้อที่ 1}
113
- - [ ] AC-2: {เงื่อนไขการตรวจรับข้อที่ 2}
114
-
115
- ## 2. Plan & Test Strategy
116
- - **Files to Modify / Create**:
117
- - `{path/to/file1}`: {หน้าที่ที่ต้องสร้าง/แก้ไข}
118
- - `{path/to/file2}`: {หน้าที่ที่ต้องสร้าง/แก้ไข}
119
- - **Test Decision**: `Required (TDD)` | `Manual/Command Only` | `Not Required`
120
- - *Rationale*: {เหตุผลความจำเป็นในการเขียนเทสต์}
121
- - *Planned Cases*: {กรณีทดสอบหลักตาม AAA Pattern}
122
- - **Impact & Rollback Strategy**:
123
- - *Impact*: {ผลกระทบต่อโมดูลอื่น}
124
- - *Rollback*: {วิธีย้อนคืนการทำงานกรณีเกิดปัญหา}
125
-
126
- ## 3. Implementation Checklist
127
- - [ ] Task 1.1: {งานย่อยข้อที่ 1}
128
- - [ ] Task 1.2: {งานย่อยข้อที่ 2}
129
- - [ ] Task 1.3: {งานย่อยข้อที่ 3}
130
-
131
- ## 4. Implementation Record
132
- - *(จะถูกบันทึกเมื่อรัน /implement)*
133
-
134
- ## 5. Verification Evidence
135
- - *(จะถูกบันทึกเมื่อรัน /check)*
136
-
137
- ## 6. Release & Handoff
138
- - *(จะถูกบันทึกเมื่อรัน /complete)*
139
- ```
140
-
141
- ---
142
-
143
- ### 5. Update Workspace Status
144
- Update `devflow/context/current-stage.md`:
145
- - `Active Discovery ID`: `None`
146
- - `Active Running ID`: `{ID}`
147
- - `Current Stage`: `feature (Fast-Track -> Ready for /implement)`
148
- - `Living Spec`: `devflow/context/current-feature.md`
149
- - `Last Updated`: `{YYYY-MM-DD}`
150
-
151
- ---
152
-
153
- ### 6. Output Summary & Next Step
154
- Report to the user in **Thai (`th`)**:
155
- - Running ID and allocated branch (`feature/{ID}`)
156
- - Summary of Scope, Acceptance Criteria, and Sizing evaluation
157
- - Explicit next step: `/implement` (หรือ `$implement`)
14
+ `build-plan.md` is intentionally high-level - one line per feature, no detail,
15
+ no ordering ceremony. All of that is this skill's job: take one listed feature,
16
+ read the full context from `project-overview.md`, and turn it into something
17
+ buildable.
18
+
19
+ ## Input
20
+
21
+ A feature from `build-plan.md`, by number or name - e.g. `/feature 3` or
22
+ `/feature "typing engine"`.
23
+
24
+ The request may also describe a genuinely new feature that is not in the build
25
+ plan yet. That goes through the new-feature intake in Step 1. Never silently add
26
+ scope to the user-owned plans.
27
+
28
+ **With no argument, build the next one.** `/feature` on its own specs the first
29
+ unchecked item in `build-plan.md`. The build plan is a checklist; finished
30
+ features are checked off, so the first unchecked item is always what's next. (If a
31
+ big item has been split into sub-items, the next unchecked sub-item is the target.)
32
+
33
+ ## Step 1 - pick the target
34
+
35
+ - Given a number or name that matches a build-plan item -> use it.
36
+ - Given a request that clearly describes a new feature with no reasonable match
37
+ in the build plan -> follow **New-feature intake** below.
38
+ - No argument -> read `build-plan.md` top to bottom and take the first unchecked
39
+ leaf (a plain item, or a sub-item under one that was split).
40
+
41
+ ### New-feature intake
42
+
43
+ Use this path for a new product capability, not a bug or small unplanned change.
44
+ Those still belong in `/fix`.
45
+
46
+ 1. Search checked and unchecked items for an existing or near-duplicate feature.
47
+ If the wording may simply be a mistaken name, show the closest matches instead
48
+ of creating new scope.
49
+ 2. If it is genuinely new, propose one feature-sized checkbox line and where it
50
+ belongs in `build-plan.md`. Preserve completed items and their numbering. Use
51
+ the next unused whole number for a new top-level item. If the existing plan is
52
+ complete, place it under an existing later milestone heading or propose a
53
+ `## Post-MVP` heading.
54
+ 3. Check whether the feature materially changes the product direction, users,
55
+ data, stack, monetization, UI/UX, or deployment. Include exact proposed edits
56
+ to the relevant `project-plan.md` sections only when needed. An incremental
57
+ feature normally changes only `build-plan.md`.
58
+ 4. Stop for approval before editing either user-owned plan. Show the complete
59
+ proposed plan change, including any project-plan edits, in the review request.
60
+ 5. After approval, write the plan changes, follow the installed `overview` skill
61
+ to regenerate `devflow/context/project-overview.md`, then resume this skill
62
+ with the newly added build-plan item as the target. If overview finds a
63
+ contradiction or decision the user must resolve, stop there and do not spec
64
+ against unresolved context.
65
+
66
+ The result follows the same normal loop as any other planned feature. Do not
67
+ create a second build plan or bypass overview regeneration.
68
+
69
+ **If the build plan isn't a checklist yet** - a plain list with no `- [ ]` boxes -
70
+ treat every item as unchecked: take the first item as the target, and offer to
71
+ convert the list to a checklist so progress is trackable from here on. Proceed
72
+ with the first item whether or not the user wants the conversion.
73
+
74
+ State which feature you're building before going further.
75
+
76
+ ## Step 2 - size it, and split if too big
77
+
78
+ Read the target line from `build-plan.md`, then pull full context from
79
+ `devflow/context/project-overview.md` (the data model, stack, and conventions). Decide
80
+ how big the feature is:
81
+
82
+ - **Small enough to build and review as one unit** -> one spec. Continue to
83
+ Step 3.
84
+ - **Too big for one reviewable spec** -> split it. Propose a short list of
85
+ sub-features in chat (title + one line each), let the user adjust it, then write
86
+ those sub-items back under the parent in `build-plan.md` as an indented
87
+ checklist (`4a`, `4b`, `4c` ...). Spec only the **first** sub-feature now; the
88
+ rest get picked up on later `/feature` runs.
89
+
90
+ Two levels of breakdown - don't confuse them:
91
+
92
+ - **Sub-features** (here) - each is big enough to stand alone: its own branch,
93
+ spec, review-and-merge cycle, and archive entry.
94
+ - **Build steps** (in the spec, Step 3) - small diffs *within* one feature.
95
+
96
+ Worked example - "Authentication" is too big for one spec, so it splits into
97
+ sub-features in `build-plan.md`:
98
+
99
+ - [ ] 4. Authentication
100
+ - [ ] 4a. Registration - sign-up page + create Profile and handle
101
+ - [ ] 4b. Login - sign-in page + session
102
+ - [ ] 4c. Route protection - gate saving/drills/leaderboard, plus sign-out
103
+
104
+ Then *within* 4a, the build steps are small: first "registration page UI", then
105
+ "register server action + validation + redirect". The page and its logic are
106
+ steps, not separate features.
107
+
108
+ This sizing call is the skill's job, not the build plan's - that's exactly why the
109
+ build plan starts high-level.
110
+
111
+ ## Step 3 - write the spec
112
+
113
+ For the one (sub-)feature being built now, write a full spec to
114
+ `devflow/context/current-feature.md` (create `devflow/context/` if needed), following
115
+ `reference/feature-spec-template.md`. Fill every section: goal, in/out of scope,
116
+ the build loop, small build steps as a checklist (`- [ ]`, each with an observable
117
+ "done when" - `/implement` ticks them off and resumes from the first unchecked
118
+ one), files/areas, data/contracts, testing, and notes for the AI.
119
+
120
+ **Visual or replication features need a reference image.** If the feature is
121
+ "make it look like X" - recreating an existing design, matching a mockup, or
122
+ rebuilding a Canva/Figma artifact - prose underspecifies the target and the build
123
+ will approximate it wrong. Ask the user for a screenshot or image if one isn't
124
+ already provided, save it under `devflow/reference/` (create the folder if
125
+ needed), and link it from the spec's Design reference section. Don't write a
126
+ visual spec from words alone when an image could exist.
127
+
128
+ **If `prototypes/` exists, that is your design reference.** When `/prototype` has
129
+ run, the repo holds `prototypes/theme.css` (the locked design tokens) and
130
+ `prototypes/*.html` (the visual mockups). For a UI-facing feature, link the
131
+ relevant mockups from the spec's Design reference section instead of asking for a
132
+ screenshot - they beat a flat image, since they carry the exact tokens. Treat
133
+ `theme.css` as the source of truth for colors, type, and spacing, and make the
134
+ feature's **first build step** port those tokens into the app's global stylesheet
135
+ (`@theme` for Tailwind v4, or the project's equivalent) before building components
136
+ against the mockups. The mockups are throwaway: once the look is built they get
137
+ discarded at `/complete`.
138
+
139
+ This is a draft. Don't present it yet - critique it first.
140
+
141
+ ## Step 4 - red-team the draft, then tighten
142
+
143
+ Before the user reads it, turn on the spec yourself and try to break it. The
144
+ cheapest place to catch a scope problem or an oversized step is here, before any
145
+ code exists. Run the draft against these questions:
146
+
147
+ - **Coverage.** What does this feature need that no step delivers? Push on the
148
+ unhappy paths the happy-path spec skipped: empty / missing / malformed input,
149
+ the error / loading / empty states, the first-run case, failure of anything
150
+ external it calls.
151
+ - **Visual fidelity.** If this is a look-alike or replication feature, is a
152
+ reference image linked in the spec - or are we about to build a design blind
153
+ from prose? If `prototypes/` exists, are the relevant mockups linked as the
154
+ Design reference and is porting `theme.css` into the app the first build step?
155
+ If a real design exists and nothing is captured, get it before building, not
156
+ after the approximation lands.
157
+ - **Step size.** Would any step's diff be too big to read in one sitting? If so,
158
+ split it - oversized steps defeat the review gate.
159
+ - **Order.** Does each step leave the app working, and depend only on earlier
160
+ steps, never a later one? Resequence if not.
161
+ - **Contracts.** Is any type, route, or stored shape that a later feature will
162
+ touch left undefined here? Lock it now and flag it load-bearing.
163
+ - **Scope honesty.** Is anything creeping in that belongs to a later feature? Is
164
+ anything pushed to "out of scope" that this feature actually can't ship without?
165
+ - **Done-whens.** Is each one observable and checkable by `/check`, or is it a
166
+ vague "it works"? Make it concrete.
167
+ - **Testing.** Does the predicted coverage match the gate - in-scope logic gets a
168
+ test when a `test` command is declared in `AGENTS.md`, UI/integration rides on
169
+ screenshot + build?
170
+
171
+ Apply the fixes to `current-feature.md`. Then stop and present the spec, leading
172
+ with a short **"what the critique changed"** note - the splits, gaps, or scope
173
+ cuts you made (or "nothing - the draft held up"). That note is the point: it shows
174
+ the gate working before a line of code is written.
175
+
176
+ Tell the user to review and adjust. This skill plans; it never starts building.
177
+
178
+ ## Rules the spec must follow
179
+
180
+ - **Small, reviewable steps.** Each step ends with something working and a diff
181
+ small enough to read in full. If a step's diff would be too big to review, the
182
+ step is too big - split it. This review gate is the point.
183
+ - **Build in order.** Sequence the steps so each builds on the last and leaves
184
+ the app working.
185
+ - **Lock data contracts early.** If a shape (type, API response, stored field) is
186
+ used by a later feature, define it now and flag it as load-bearing.
187
+ - **Flag client vs server** and any conventions from `devflow/context/coding-standards.md`
188
+ (for example, filtering user-scoped queries by the authenticated user's id).
189
+ - **Scope honestly.** State what is deferred so the feature stays contained.
190
+
191
+ ## When a (sub-)feature is done
192
+
193
+ Check its box in `build-plan.md` (and the parent item once all its sub-items are
194
+ checked), archive the finished `devflow/context/current-feature.md` to
195
+ `devflow/history/features/NN-name.md`, then run `/feature` again for the next one.
196
+
197
+ ## Formatting
198
+
199
+ Format the output to match the project's conventions in
200
+ `devflow/context/ai-interaction.md`: concise, scannable markdown, with lists for
201
+ enumerations and tables for matrices rather than dense paragraphs.
@@ -1,108 +1,59 @@
1
1
  ---
2
2
  name: fix
3
- description: "[Devflow] Fast-Track Fix stage in DevFlow (Blueprint Mode) - define, spec, plan, and create the living current-feature.md contract in context for bug fixes."
4
- argument-hint: "{bug description, issue ID, or IDEA-xxx}"
3
+ description: "[devflow][F] Document an ad-hoc bug fix or small change (one not in the build plan) into devflow/context/current-feature.md so it runs through the same build loop. Writes a short fix spec and stops; then /implement builds it and /complete logs it to devflow/history/fixes/ and merges. Use when the user runs /fix, reports a bug, or asks to fix or change something that isn't a planned build-plan feature."
5
4
  ---
6
5
 
7
- # Fast-Track: Fix (Blueprint Mode)
6
+ # fix - document an ad-hoc fix, then build it like anything else
8
7
 
9
- $ARGUMENTS
8
+ Where this sits in the workflow:
10
9
 
11
- Fast-Track entry point combining Bug Triage, Root Cause Isolation, Specification, and Implementation Planning into one streamlined, review-gated step for **bug fixes and hotfixes**. Creates and maintains the **Single Living Spec (`devflow/context/current-feature.md`)** for the fix run.
10
+ /fix -> /implement -> /complete -> back to your features
11
+ (spec (build it, (log to devflow/history/fixes/
12
+ the fix) reviewed) + merge)
12
13
 
13
- ## Invocations & Aliases
14
+ A fix is a bug or small change that isn't a planned build-plan feature. It runs
15
+ through the same loop as a feature (build with review gates, iterate, then merge);
16
+ it just starts here instead of `/feature`, and is logged separately.
14
17
 
15
- - `/fix <bug-description>` or `fix <bug-description>`: Fast-Track ad-hoc bugfix workflow
16
- - `/fix IDEA-xxx`: Intake and fix a reported issue or idea from `devflow/ideas.md`
17
- - `$fix`: Codex CLI invocation
18
+ ## Input
18
19
 
19
- ## Fast-Track Mainline Workflow
20
+ A description of the bug or change, for example `/fix "password reset email never
21
+ sends"`. If the user just reported the problem in chat, use that.
20
22
 
21
- ```text
22
- /feature (หรือ /fix) ──▶ /implement ──▶ /check ──▶ /complete
23
- ```
23
+ The input may also be a finding ID from `devflow/context/findings.md`, alone
24
+ or with a description, for example `/fix F-03`. Pull the problem statement from
25
+ that ledger entry. Use this form only between work items, when
26
+ `current-feature.md` is the reset stub: this skill overwrites that file, so
27
+ while a spec is active, repair its findings through `/implement` instead.
24
28
 
25
- ## Behavior & Contract
29
+ ## Step 1 - write the fix spec
26
30
 
27
- When invoked:
31
+ Pull context from `devflow/context/project-overview.md` and `devflow/context/coding-standards.md`,
32
+ then write a short spec to `devflow/context/current-feature.md` (this file holds whatever
33
+ is being built now, feature or fix). Keep it lighter than a feature spec:
28
34
 
29
- ### 1. Single Active Run Guardrail (One Thing at a Time)
30
- 1. Inspect `devflow/context/current-stage.md` and `devflow/context/current-feature.md`.
31
- 2. If `Active Running ID` is not `None` and `Current Stage` is not `Idle`, or if `current-feature.md` contains an active uncompleted spec:
32
- - **HALT and reject opening a new fix**.
33
- - Explain to the user that an active run is currently in progress:
34
- > ⚠️ *"มีงาน `{active_id}` กำลังดำเนินการอยู่ กรุณาปิดงานเดิมด้วย `/complete` หรือ `70-deliver` (หรือสั่ง `/rollback`) ก่อนเริ่มงานใหม่"*
35
+ - **Title** - the bug or change in a few words.
36
+ - **Type:** Fix (so `/complete` logs it to `devflow/history/fixes/`, not `devflow/history/features/`).
37
+ - **Fixes:** `<finding id>` - only when the fix targets a ledger finding. The
38
+ stamp makes the repair traceable: `/implement` marks that finding `fixed`
39
+ when the repairing step lands, and `/audit` re-reviews it before it closes.
40
+ - **The problem** - what's wrong or what needs to change, and where.
41
+ - **The fix** - the approach, and anything it must not break.
42
+ - **Build steps** - usually one small step; split only if the diff would be too
43
+ big to read. Each ends with an observable "done when".
44
+ - **Verify** - how to confirm it's fixed (what to click or test).
35
45
 
36
- ### 2. Work Identity & Issue Intake
37
- 1. **Idea / Issue Inbox Intake**: If the argument is an identifier (e.g. `IDEA-001`):
38
- - Read `devflow/ideas.md` or issue notes and extract problem statement and root cause hints.
39
- - In `devflow/ideas.md`, update status to `[x] Claimed ({ID})` and move under `## 📦 Archived / Shipped Ideas`.
40
- 2. Inspect `devflow/history/HISTORY.md` and determine the next sequential ID without prefix (e.g. `022-{slug}`).
41
- 3. Identify Git branch naming:
42
- - `fix/{xxx-slug}`
46
+ Then stop. Tell the user to review the fix spec, then run `/implement` to build it.
43
47
 
44
- ### 3. Generate the Living Spec (`devflow/context/current-feature.md`)
45
- Write `devflow/context/current-feature.md` using the structured template below in **Thai (`th`)**:
48
+ ## Rules
46
49
 
47
- ```markdown
48
- # 📐 [{ID}] {Bug/Fix Title} (Living Spec)
50
+ - A fix is not a build-plan item; don't add it to `build-plan.md`.
51
+ - Keep it small. If it's really a new feature, use `/feature` and the build plan
52
+ instead.
53
+ - Same conventions as everything else (`devflow/context/coding-standards.md`).
49
54
 
50
- > **Status**: In-Progress
51
- > **Track**: Fast-Track (Blueprint Mode - Fix)
52
- > **Category**: Fix
53
- > **Branch**: `{branch_name}`
54
- > **Created Date**: {YYYY-MM-DD}
55
- > **Owner**: {Contributor or Team}
55
+ ## Formatting
56
56
 
57
- ---
58
-
59
- ## 1. Specification & Scope
60
- - **Problem Statement & Reproduction**: {อาการบั๊กที่พบ ขั้นตอนที่ทำให้เกิดปัญหา หรือ Error Log}
61
- - **Root Cause Analysis**: {สาเหตุที่แท้จริงของบั๊ก}
62
- - **In-Scope**:
63
- - {ขอบเขตการแก้ไขบั๊กและการป้องกัน regression}
64
- - **Out-of-Scope**:
65
- - {สิ่งที่ไม่แตะต้องหรืออยู่นอกเหนือการแก้จุดนี้}
66
- - **Acceptance Criteria**:
67
- - [ ] AC-1: {เงื่อนไขการแก้ปัญหาสำเร็จและพฤติกรรมที่ถูกต้อง}
68
- - [ ] AC-2: {มี Regression Test ป้องกันไม่ให้เกิดซ้ำ}
69
-
70
- ## 2. Plan & Test Strategy
71
- - **Files to Modify / Create**:
72
- - `{path/to/file1}`: {หน้าที่ที่ต้องแก้ไข}
73
- - `{path/to/test_file}`: {เทสต์เคสจำลองและป้องกันบั๊ก}
74
- - **Test Decision**: `Required (TDD / Regression Test)`
75
- - *Rationale*: {การแก้บั๊กต้องมี Regression Test ยืนยันเสมอ}
76
- - *Planned Cases*: {เคสทดสอบจำลองบั๊ก (Red) และทดสอบหลังแก้ (Green)}
77
- - **Impact & Rollback Strategy**:
78
- - *Impact*: {ผลกระทบต่อโมดูลข้างเคียง}
79
- - *Rollback*: {วิธีย้อนคืนการทำงานกรณีเกิดปัญหา}
80
-
81
- ## 3. Implementation Checklist
82
- - [ ] Task 1.1: {เขียน Regression Test เพื่อ reproduce บั๊ก}
83
- - [ ] Task 1.2: {แก้ไขโค้ดที่จุดเกิดเหตุ}
84
- - [ ] Task 1.3: {รันชุดทดสอบเพื่อยืนยันว่าบั๊กหายและไม่กระทบจุดอื่น}
85
-
86
- ## 4. Implementation Record
87
- - *(จะถูกบันทึกเมื่อรัน /implement)*
88
-
89
- ## 5. Verification Evidence
90
- - *(จะถูกบันทึกเมื่อรัน /check)*
91
-
92
- ## 6. Release & Handoff
93
- - *(จะถูกบันทึกเมื่อรัน /complete)*
94
- ```
95
-
96
- ### 4. Update Workspace Status
97
- Update `devflow/context/current-stage.md`:
98
- - `Active Discovery ID`: `None`
99
- - `Active Running ID`: `{ID}`
100
- - `Current Stage`: `fix (Fast-Track -> Ready for /implement)`
101
- - `Living Spec`: `devflow/context/current-feature.md`
102
- - `Last Updated`: `{YYYY-MM-DD}`
103
-
104
- ### 5. Output Summary & Next Step
105
- Report to the user:
106
- - Running ID and allocated branch
107
- - Summary of Scope, Reproduction, and Acceptance Criteria
108
- - Explicit next step: `/implement`
57
+ Format the output to match the project's conventions in
58
+ `devflow/context/ai-interaction.md`: concise, scannable markdown, with lists for
59
+ enumerations and tables for matrices rather than dense paragraphs.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: idea
3
- description: "[Devflow] Quick idea capture and AI enrichment - analyze feasibility, value, key points, and record into devflow/ideas.md inbox."
3
+ description: "[devflow][B] Quick idea capture and AI enrichment - analyze feasibility, value, key points, and record into devflow/ideas.md inbox."
4
4
  argument-hint: "\"<idea text or description>\""
5
5
  ---
6
6
 
@@ -54,4 +54,4 @@ Report to the user:
54
54
  - Allocated Idea ID: `[IDEA-xxx]`
55
55
  - Summary of Feasibility & Value analysis
56
56
  - Seed points saved
57
- - Instructions for promotion: "เมื่อพร้อมลงมือทำ สามารถพิมพ์ `/spec IDEA-xxx` หรือ `/00-explore IDEA-xxx` ได้ทันที"
57
+ - Instructions for promotion: "เมื่อพร้อมลงมือทำ สามารถพิมพ์ `/spec IDEA-xxx` หรือ `/00-explore IDEA-xxx` ได้ทันที"