moicle 1.3.1 → 1.4.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.
- package/README.md +2 -1
- package/assets/architecture/ddd-architecture.md +337 -0
- package/assets/architecture/go-backend.md +770 -693
- package/assets/architecture/laravel-backend.md +388 -156
- package/assets/skills/architect-review/SKILL.md +292 -372
- package/assets/skills/deep-debug/SKILL.md +114 -0
- package/assets/skills/new-feature/SKILL.md +232 -252
- package/assets/skills/refactor/SKILL.md +261 -679
- package/assets/skills/sync-docs/SKILL.md +115 -74
- package/assets/templates/go-gin/CLAUDE.md +671 -121
- package/package.json +1 -1
- package/assets/architecture/clean-architecture.md +0 -143
- package/assets/skills/go-module/SKILL.md +0 -77
- package/assets/skills/ship/SKILL.md +0 -297
|
@@ -10,16 +10,16 @@ Automated workflow that reads codebase and existing docs to generate a complete,
|
|
|
10
10
|
## Workflow Overview
|
|
11
11
|
|
|
12
12
|
```
|
|
13
|
-
┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐
|
|
14
|
-
│ 1. SCAN │──▶│2. GENERATE──▶│ 3. REVIEW │──▶│4. COMPLETE│
|
|
15
|
-
└──────────┘ └──────────┘ └──────────┘ └──────────┘
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
13
|
+
┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐
|
|
14
|
+
│ 1. SCAN │──▶│1.5 CONFIRM──▶│2. GENERATE──▶│ 3. REVIEW │──▶│4. COMPLETE│
|
|
15
|
+
└──────────┘ └──────────┘ └──────────┘ └──────────┘ └──────────┘
|
|
16
|
+
▲ │
|
|
17
|
+
│ Feedback │
|
|
18
|
+
└──────────────┘
|
|
19
|
+
(loop until pass)
|
|
20
20
|
```
|
|
21
21
|
|
|
22
|
-
**Key**: Phase 3 REVIEW automatically loops back to Phase 2 GENERATE if issues are found.
|
|
22
|
+
**Key**: Phase 1.5 CONFIRM asks user to choose between REFACTOR (full restructure) or UPDATE (keep structure, update & link only). Phase 3 REVIEW automatically loops back to Phase 2 GENERATE if issues are found.
|
|
23
23
|
|
|
24
24
|
---
|
|
25
25
|
|
|
@@ -89,7 +89,7 @@ Automated workflow that reads codebase and existing docs to generate a complete,
|
|
|
89
89
|
|
|
90
90
|
### Docs Output Plan
|
|
91
91
|
- docs/README.md (index)
|
|
92
|
-
- docs/business.md (business overview -
|
|
92
|
+
- docs/business.md (business overview - non-technical, business language only)
|
|
93
93
|
- docs/architecture.md
|
|
94
94
|
- docs/use-cases/[usecase-name].md (per use case)
|
|
95
95
|
- docs/diagrams/ (embedded in use case files via mermaid)
|
|
@@ -103,16 +103,57 @@ Automated workflow that reads codebase and existing docs to generate a complete,
|
|
|
103
103
|
|
|
104
104
|
---
|
|
105
105
|
|
|
106
|
+
## Phase 1.5: CONFIRM
|
|
107
|
+
|
|
108
|
+
**Goal**: Ask the user how they want to handle docs before generating.
|
|
109
|
+
|
|
110
|
+
### Actions
|
|
111
|
+
|
|
112
|
+
1. **Present scan results** from Phase 1 to the user (current structure, identified use cases, docs plan)
|
|
113
|
+
|
|
114
|
+
2. **Ask the user**:
|
|
115
|
+
```
|
|
116
|
+
How would you like to proceed with the docs?
|
|
117
|
+
|
|
118
|
+
1. Refactor - Restructure docs into the standard template (docs/README.md, business.md, architecture.md, use-cases/) and relink everything
|
|
119
|
+
2. Update & Link only - Keep the current docs structure as-is, only update content and fix linking
|
|
120
|
+
|
|
121
|
+
(Choose 1 or 2)
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
3. **Based on the choice, set the mode for Phase 2**:
|
|
125
|
+
- **REFACTOR mode (choice 1)**: Run Phase 2 GENERATE in full - create new structure, migrate useful content from old docs into the new template, remove/replace old doc files that are no longer needed
|
|
126
|
+
- **UPDATE mode (choice 2)**: Run Phase 2 in update-only mode - preserve existing file/folder structure, only update content inside existing files to match current code, add/fix links between files, add mermaid diagrams where missing, DO NOT move/rename/delete existing files
|
|
127
|
+
|
|
128
|
+
### Gate
|
|
129
|
+
- [ ] User has chosen a mode (REFACTOR or UPDATE)
|
|
130
|
+
- [ ] Mode is recorded for Phase 2 to handle accordingly
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
106
134
|
## Phase 2: GENERATE
|
|
107
135
|
|
|
108
|
-
**Goal**: Generate all documentation files
|
|
136
|
+
**Goal**: Generate all documentation files based on the selected mode from Phase 1.5
|
|
137
|
+
|
|
138
|
+
### Mode Selection
|
|
139
|
+
|
|
140
|
+
- **REFACTOR mode**: Create an entirely new docs structure following the template below. If old docs exist, migrate useful content into the new structure. May remove/replace old files.
|
|
141
|
+
- **UPDATE mode**: Preserve the existing file/folder structure. Only perform:
|
|
142
|
+
- Update content in existing doc files to match current code
|
|
143
|
+
- Add/fix links between files (relative links)
|
|
144
|
+
- Add mermaid diagrams to existing files where missing
|
|
145
|
+
- Add new files ONLY when there are undocumented use cases/features
|
|
146
|
+
- DO NOT move, rename, or delete existing files
|
|
147
|
+
- Ensure there is 1 index file (README.md or existing index) linking to all docs
|
|
148
|
+
|
|
149
|
+
> **The templates below apply fully to REFACTOR mode. For UPDATE mode, use them as content/format reference only — do NOT force the structure.**
|
|
109
150
|
|
|
110
151
|
### Output Structure
|
|
111
152
|
|
|
112
153
|
```
|
|
113
154
|
docs/
|
|
114
155
|
├── README.md # Index - links to all sub-files
|
|
115
|
-
├── business.md # Business overview -
|
|
156
|
+
├── business.md # Business overview - non-technical, business language only
|
|
116
157
|
├── architecture.md # Architecture overview + system diagram
|
|
117
158
|
└── use-cases/
|
|
118
159
|
├── [use-case-1].md # Use case doc + sequence diagram
|
|
@@ -134,7 +175,7 @@ docs/
|
|
|
134
175
|
## Table of Contents
|
|
135
176
|
|
|
136
177
|
### Business
|
|
137
|
-
- [Business Overview](./business.md) -
|
|
178
|
+
- [Business Overview](./business.md) - Business overview, goals, target users
|
|
138
179
|
|
|
139
180
|
### Architecture
|
|
140
181
|
- [Architecture Overview](./architecture.md) - System architecture, layers, and patterns
|
|
@@ -162,84 +203,84 @@ docs/
|
|
|
162
203
|
|
|
163
204
|
### 2.2 Generate `docs/business.md` (Business Overview)
|
|
164
205
|
|
|
165
|
-
|
|
206
|
+
This file is written entirely in business language. NO code, NO class/function names, NO technical jargon. Target audience: stakeholders, product owners, business analysts - people who don't need to know the code.
|
|
166
207
|
|
|
167
208
|
```markdown
|
|
168
|
-
# [Project Name] -
|
|
209
|
+
# [Project Name] - Business Overview
|
|
169
210
|
|
|
170
|
-
##
|
|
211
|
+
## What is this product?
|
|
171
212
|
|
|
172
|
-
[2-3
|
|
213
|
+
[2-3 paragraphs describing the product in everyday language. Explain what problem it solves, for whom, and why it's needed.]
|
|
173
214
|
|
|
174
|
-
##
|
|
215
|
+
## Target Users
|
|
175
216
|
|
|
176
|
-
### [
|
|
177
|
-
- **
|
|
178
|
-
- **
|
|
179
|
-
- **
|
|
217
|
+
### [Role 1] - e.g., End User
|
|
218
|
+
- **Who**: [description]
|
|
219
|
+
- **Needs**: [what they need from the product]
|
|
220
|
+
- **What they do**: [key actions on the system]
|
|
180
221
|
|
|
181
|
-
### [
|
|
182
|
-
- **
|
|
183
|
-
- **
|
|
184
|
-
- **
|
|
222
|
+
### [Role 2] - e.g., Administrator
|
|
223
|
+
- **Who**: [description]
|
|
224
|
+
- **Needs**: [what they need]
|
|
225
|
+
- **What they do**: [key actions on the system]
|
|
185
226
|
|
|
186
|
-
##
|
|
227
|
+
## Core Business Processes
|
|
187
228
|
|
|
188
|
-
### [
|
|
189
|
-
[
|
|
229
|
+
### [Process 1] - e.g., Registration and first-time use
|
|
230
|
+
[Describe each step from the user's perspective. No mention of API, database, or any technical details.]
|
|
190
231
|
|
|
191
|
-
1. [
|
|
192
|
-
2. [
|
|
193
|
-
3. [
|
|
232
|
+
1. [Step 1 - what the user does]
|
|
233
|
+
2. [Step 2 - how the system responds]
|
|
234
|
+
3. [Step N]
|
|
194
235
|
|
|
195
|
-
### [
|
|
196
|
-
[
|
|
236
|
+
### [Process 2] - e.g., Placing an order
|
|
237
|
+
[Same approach - describe from a business perspective]
|
|
197
238
|
|
|
198
|
-
##
|
|
239
|
+
## Key Features
|
|
199
240
|
|
|
200
|
-
|
|
|
201
|
-
|
|
202
|
-
| [
|
|
203
|
-
| [
|
|
241
|
+
| Feature | Description | Used by |
|
|
242
|
+
|---------|-------------|---------|
|
|
243
|
+
| [Feature 1] | [explain in business language] | [role] |
|
|
244
|
+
| [Feature 2] | [explain] | [role] |
|
|
204
245
|
|
|
205
|
-
##
|
|
246
|
+
## Business Rules
|
|
206
247
|
|
|
207
|
-
|
|
248
|
+
Key rules the system follows:
|
|
208
249
|
|
|
209
|
-
1. **[
|
|
210
|
-
2. **[
|
|
211
|
-
3. **[
|
|
250
|
+
1. **[Rule 1]**: [explain - e.g., "Every order must contain at least 1 product"]
|
|
251
|
+
2. **[Rule 2]**: [explain - e.g., "Users can only request a refund within 7 days"]
|
|
252
|
+
3. **[Rule N]**: [explain]
|
|
212
253
|
|
|
213
|
-
##
|
|
254
|
+
## Business Entity Relationships
|
|
214
255
|
|
|
215
|
-
[
|
|
216
|
-
-
|
|
217
|
-
-
|
|
218
|
-
-
|
|
256
|
+
[Describe key relationships in plain text, e.g.:]
|
|
257
|
+
- A **customer** can create multiple **orders**
|
|
258
|
+
- An **order** contains multiple **products**
|
|
259
|
+
- A **product** belongs to a **category**
|
|
219
260
|
|
|
220
|
-
##
|
|
261
|
+
## Value Flow
|
|
221
262
|
|
|
222
|
-
[
|
|
263
|
+
[Describe how the product creates value for each stakeholder:]
|
|
223
264
|
|
|
224
|
-
-
|
|
225
|
-
-
|
|
226
|
-
-
|
|
265
|
+
- **For [role 1]**: [value they receive]
|
|
266
|
+
- **For [role 2]**: [value they receive]
|
|
267
|
+
- **For the business**: [value the business receives]
|
|
227
268
|
|
|
228
|
-
##
|
|
269
|
+
## Business Glossary
|
|
229
270
|
|
|
230
|
-
|
|
|
231
|
-
|
|
232
|
-
| [
|
|
233
|
-
| [
|
|
271
|
+
| Term | Definition |
|
|
272
|
+
|------|-----------|
|
|
273
|
+
| [Term 1] | [explain in the product's context] |
|
|
274
|
+
| [Term 2] | [explain] |
|
|
234
275
|
```
|
|
235
276
|
|
|
236
|
-
**
|
|
237
|
-
-
|
|
238
|
-
-
|
|
239
|
-
-
|
|
240
|
-
-
|
|
241
|
-
-
|
|
242
|
-
- Extract business rules
|
|
277
|
+
**IMPORTANT rules for business.md**:
|
|
278
|
+
- DO NOT use words like: API, endpoint, database, repository, controller, service, model, schema, query, migration, route, middleware, component, module, class, function, method, interface, type
|
|
279
|
+
- NO code blocks whatsoever
|
|
280
|
+
- NO file path references or code file names
|
|
281
|
+
- Write as if explaining to someone who doesn't know programming
|
|
282
|
+
- Use the project's business domain language (e.g., "order" instead of "Order entity", "user" instead of "User model")
|
|
283
|
+
- Extract business rules from code logic (validation, conditions, constraints) and express them in business language
|
|
243
284
|
|
|
244
285
|
### 2.3 Generate `docs/architecture.md` (Technical)
|
|
245
286
|
|
|
@@ -382,12 +423,12 @@ Run through ALL checks below. If ANY check fails, fix and re-check.
|
|
|
382
423
|
- [ ] All relative links in README.md point to existing files
|
|
383
424
|
|
|
384
425
|
#### 3.2 Business Check
|
|
385
|
-
- [ ] `docs/business.md`
|
|
386
|
-
- [ ] `docs/business.md`
|
|
387
|
-
- [ ] `docs/business.md`
|
|
388
|
-
- [ ]
|
|
389
|
-
- [ ]
|
|
390
|
-
- [ ] Glossary
|
|
426
|
+
- [ ] `docs/business.md` contains NO technical jargon (API, endpoint, database, repository, controller, service, model, schema, query, migration, route, middleware, component, module, class, function, method, interface, type)
|
|
427
|
+
- [ ] `docs/business.md` has NO code blocks
|
|
428
|
+
- [ ] `docs/business.md` does NOT reference file paths
|
|
429
|
+
- [ ] Business processes are fully described from the user's perspective
|
|
430
|
+
- [ ] Business rules are correctly extracted from code logic
|
|
431
|
+
- [ ] Glossary contains all domain-specific terms
|
|
391
432
|
|
|
392
433
|
#### 3.3 Content Check
|
|
393
434
|
- [ ] Architecture diagram reflects actual codebase layers
|
|
@@ -517,14 +558,14 @@ docs/
|
|
|
517
558
|
|
|
518
559
|
### Review Loop
|
|
519
560
|
```
|
|
520
|
-
Generate → Review → Pass? → Complete
|
|
521
|
-
|
|
561
|
+
Scan → Confirm (Refactor/Update?) → Generate → Review → Pass? → Complete
|
|
562
|
+
→ Fail? → Fix → Review again (max 3x)
|
|
522
563
|
```
|
|
523
564
|
|
|
524
565
|
## Success Criteria
|
|
525
566
|
|
|
526
567
|
Documentation sync is complete when:
|
|
527
|
-
1. Business overview
|
|
568
|
+
1. Business overview written entirely in business language, no technical jargon
|
|
528
569
|
2. All codebase features are documented as use cases
|
|
529
570
|
3. Architecture accurately reflects codebase
|
|
530
571
|
4. Every use case has a sequence diagram
|