maestro-flow-one 0.2.1 → 0.2.3
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/maestro-flow/commands/learn/decompose.md +10 -15
- package/maestro-flow/commands/learn/follow.md +11 -16
- package/maestro-flow/commands/learn/investigate.md +18 -22
- package/maestro-flow/commands/learn/retro.md +23 -26
- package/maestro-flow/commands/learn/second-opinion.md +11 -16
- package/maestro-flow/commands/lifecycle/analyze.md +8 -0
- package/maestro-flow/commands/lifecycle/brainstorm.md +8 -0
- package/maestro-flow/commands/lifecycle/collab.md +333 -0
- package/maestro-flow/commands/lifecycle/execute.md +11 -3
- package/maestro-flow/commands/lifecycle/learn.md +4 -4
- package/maestro-flow/commands/lifecycle/plan.md +8 -0
- package/maestro-flow/commands/lifecycle/tools-execute.md +117 -0
- package/maestro-flow/commands/lifecycle/tools-register.md +137 -0
- package/maestro-flow/commands/lifecycle/ui-codify.md +67 -0
- package/maestro-flow/commands/manage/harvest.md +1 -1
- package/maestro-flow/commands/manage/learn.md +5 -7
- package/maestro-flow/commands/manage/wiki.md +1 -1
- package/maestro-flow/commands/milestone/complete.md +6 -6
- package/maestro-flow/commands/quality/auto-test.md +1 -1
- package/maestro-flow/commands/quality/debug.md +8 -0
- package/maestro-flow/commands/quality/retrospective.md +4 -5
- package/maestro-flow/commands/quality/review.md +8 -0
- package/maestro-flow/commands/spec/add.md +25 -4
- package/maestro-flow/commands/spec/load.md +26 -6
- package/maestro-flow/commands/spec/setup.md +2 -2
- package/maestro-flow/commands/wiki/connect.md +1 -1
- package/maestro-flow/commands/wiki/digest.md +5 -6
- package/package.json +1 -1
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: maestro-ui-codify
|
|
3
|
+
description: Extract design system from code, generate reference package, persist as knowledge assets
|
|
4
|
+
argument-hint: "<source-path> [--package-name <name>] [--output-dir <path>] [--overwrite]"
|
|
5
|
+
allowed-tools:
|
|
6
|
+
- Read
|
|
7
|
+
- Write
|
|
8
|
+
- Edit
|
|
9
|
+
- Bash
|
|
10
|
+
- Glob
|
|
11
|
+
- Grep
|
|
12
|
+
- Agent
|
|
13
|
+
- Skill
|
|
14
|
+
---
|
|
15
|
+
<purpose>
|
|
16
|
+
Codify UI design system from existing source code. 4-phase pipeline:
|
|
17
|
+
|
|
18
|
+
1. **Validate** (inline): Parameter validation, workspace setup, file discovery
|
|
19
|
+
2. **Extract** (3 parallel agents): Style Agent + Animation Agent + Layout Agent produce design-tokens.json, animation-tokens.json, layout-templates.json
|
|
20
|
+
3. **Package** (agent): Copy tokens to package directory, generate preview.html + preview.css
|
|
21
|
+
4. **Knowhow** (manifest + skill): Build knowhow-manifest.json, call codify-to-knowhow to persist as knowledge assets
|
|
22
|
+
|
|
23
|
+
Position in pipeline: code -> **ui-codify** -> knowhow + specs
|
|
24
|
+
</purpose>
|
|
25
|
+
|
|
26
|
+
<deferred_reading>
|
|
27
|
+
- [ui-codify.md](~/.maestro/workflows/ui-codify.md) — read always (main workflow orchestrator)
|
|
28
|
+
- [ui-codify-extract.md](~/.maestro/workflows/ui-codify-extract.md) — read when Phase 2 starts (style extraction with 3 agents)
|
|
29
|
+
- [ui-codify-package.md](~/.maestro/workflows/ui-codify-package.md) — read when Phase 3 starts (reference package generation)
|
|
30
|
+
- [ui-codify-knowhow.md](~/.maestro/workflows/ui-codify-knowhow.md) — read when Phase 4 starts (knowledge asset generation)
|
|
31
|
+
</deferred_reading>
|
|
32
|
+
|
|
33
|
+
<context>
|
|
34
|
+
$ARGUMENTS — source path (required) with optional flags.
|
|
35
|
+
|
|
36
|
+
Flags:
|
|
37
|
+
- `<source-path>` (positional, required): Directory containing CSS/SCSS/JS/TS/HTML source files
|
|
38
|
+
- `--package-name <name>`: Package name for reference output (default: auto-generated from source directory)
|
|
39
|
+
- `--output-dir <path>`: Output directory for reference package (default: `.workflow/reference_style`)
|
|
40
|
+
- `--overwrite`: Allow overwriting existing package directory
|
|
41
|
+
</context>
|
|
42
|
+
|
|
43
|
+
<execution>
|
|
44
|
+
Route to `~/.maestro/workflows/ui-codify.md` and follow completely.
|
|
45
|
+
|
|
46
|
+
The workflow orchestrates 4 phases with deferred loading of phase-specific workflow files. Each phase reads its workflow file only when execution reaches that phase.
|
|
47
|
+
</execution>
|
|
48
|
+
|
|
49
|
+
<error_codes>
|
|
50
|
+
| Code | Severity | Description | Stage |
|
|
51
|
+
|------|----------|-------------|-------|
|
|
52
|
+
| E001 | error | Source path argument required | parse_input |
|
|
53
|
+
| E002 | error | Source path not found or not a directory | validate |
|
|
54
|
+
| E003 | error | Package directory exists without --overwrite flag | validate |
|
|
55
|
+
| W001 | warning | animation-tokens.json not found (optional, extraction continues) | extract |
|
|
56
|
+
</error_codes>
|
|
57
|
+
|
|
58
|
+
<success_criteria>
|
|
59
|
+
- [ ] Source path validated and file discovery completed
|
|
60
|
+
- [ ] design-tokens.json generated with color, typography, spacing tokens
|
|
61
|
+
- [ ] layout-templates.json generated with component patterns (universal/specialized)
|
|
62
|
+
- [ ] animation-tokens.json generated (optional, W001 if missing)
|
|
63
|
+
- [ ] preview.html + preview.css generated as interactive showcase
|
|
64
|
+
- [ ] knowhow-manifest.json created with AST/DCS assets and spec entries
|
|
65
|
+
- [ ] codify-to-knowhow called and completed successfully
|
|
66
|
+
- [ ] Temporary workspace cleaned up
|
|
67
|
+
</success_criteria>
|
|
@@ -54,7 +54,7 @@ Extraction patterns, classification rules, routing infrastructure, and fragment
|
|
|
54
54
|
- Review wiki entries → `maestro wiki list --type note`
|
|
55
55
|
- Connect wiki graph → `/wiki-connect --fix`
|
|
56
56
|
- Triage issues → `/manage-issue list --source harvest`
|
|
57
|
-
- View specs → `/spec-load --
|
|
57
|
+
- View specs → `/spec-load --role implement`
|
|
58
58
|
- Full retrospective → `/quality-retrospective`
|
|
59
59
|
</execution>
|
|
60
60
|
|
|
@@ -16,7 +16,7 @@ Unified atomic knowledge capture for the workflow learning library. Captures two
|
|
|
16
16
|
- **Insights**: Timeless "eureka moment" entries (patterns, gotchas, techniques) — the default mode
|
|
17
17
|
- **Tips**: Quick contextual notes for cross-session recovery (formerly in `manage-knowhow-capture tip`)
|
|
18
18
|
|
|
19
|
-
Both types are stored in `.workflow/
|
|
19
|
+
Both types are stored in `.workflow/specs/learnings.md` as `<spec-entry>` blocks with auto-detected phase linkage and keyword-based category inference. Tips are distinguished by `source: "tip"` and implicitly tagged `tip`. Same store as retrospective output, so search and list see the entire knowledge corpus.
|
|
20
20
|
</purpose>
|
|
21
21
|
|
|
22
22
|
<required_reading>
|
|
@@ -30,7 +30,7 @@ Arguments: $ARGUMENTS
|
|
|
30
30
|
- `"<insight text>"` (or any non-keyword text) → insight capture mode
|
|
31
31
|
- `tip <text>` → tip capture mode (quick contextual note, auto-tagged `tip`)
|
|
32
32
|
- `list` → list recent entries (default 20)
|
|
33
|
-
- `search <query>` → text search across
|
|
33
|
+
- `search <query>` → `maestro spec load --category learning` or text search across `specs/learnings.md`
|
|
34
34
|
- `show <INS-id>` → full detail with phase context
|
|
35
35
|
- empty → AskUserQuestion to prompt for text
|
|
36
36
|
|
|
@@ -47,21 +47,19 @@ Follow `~/.maestro/workflows/learn.md` Stages 1–5 in order.
|
|
|
47
47
|
| E001 | error | `.workflow/` not initialized — run `/maestro-init` first | parse_input |
|
|
48
48
|
| E002 | error | Unknown `--category` value (allowed: pattern, antipattern, decision, tool, gotcha, technique, tip) | parse_input |
|
|
49
49
|
| E003 | error | `show` mode requires an INS-id argument | show |
|
|
50
|
-
| E004 | error | Insight id not found in
|
|
50
|
+
| E004 | error | Insight id not found in `specs/learnings.md` | show |
|
|
51
51
|
| W001 | warning | Auto-phase detection found a current_phase but no matching artifact in registry; phase set to null | capture |
|
|
52
|
-
| W002 | warning | learning-index.json out of sync with lessons.jsonl (different row count); offer to rebuild | list/search |
|
|
53
52
|
</error_codes>
|
|
54
53
|
|
|
55
54
|
<success_criteria>
|
|
56
55
|
- [ ] Mode correctly routed (capture / list / search / show)
|
|
57
|
-
- [ ] Capture:
|
|
58
|
-
- [ ] Capture: `learning-index.json` updated with matching entry
|
|
56
|
+
- [ ] Capture: `<spec-entry>` block appended to `specs/learnings.md` with all required fields
|
|
59
57
|
- [ ] Capture: phase auto-link resolves correctly via artifact registry when `state.json` has `current_phase`
|
|
60
58
|
- [ ] Capture: category inference produces a sensible default when `--category` absent
|
|
61
59
|
- [ ] List: filters apply, output sorted newest-first, default limit 20
|
|
62
60
|
- [ ] Search: results ranked by title (3) > tags (2) > summary (1) match
|
|
63
61
|
- [ ] Show: full insight displayed with phase context and routed-artifact link if any
|
|
64
|
-
- [ ] No file modifications outside `.workflow/
|
|
62
|
+
- [ ] No file modifications outside `.workflow/knowhow/`
|
|
65
63
|
- [ ] Confirmation banner displayed with INS-id and next-step hints
|
|
66
64
|
- [ ] Next step: `/manage-learn list` to browse, or `/manage-learn search <query>` to find related insights
|
|
67
65
|
</success_criteria>
|
|
@@ -34,7 +34,7 @@ $ARGUMENTS — subcommand and optional flags.
|
|
|
34
34
|
| No args | Same as `health` |
|
|
35
35
|
|
|
36
36
|
**Flags:**
|
|
37
|
-
- `--type <type>` — Filter by wiki type: spec, knowhow, note,
|
|
37
|
+
- `--type <type>` — Filter by wiki type: spec, knowhow, note, issue
|
|
38
38
|
- `--fix` — Auto-fix issues found during cleanup (remove broken links, suggest connections)
|
|
39
39
|
- `--json` — Output in JSON format
|
|
40
40
|
</context>
|
|
@@ -13,7 +13,7 @@ allowed-tools:
|
|
|
13
13
|
---
|
|
14
14
|
|
|
15
15
|
<purpose>
|
|
16
|
-
Mark a milestone as complete after its audit has passed. Archives all scratch artifacts to `milestones/{M}/artifacts/`, moves artifact entries from `state.json.artifacts[]` to `milestone_history`, extracts final
|
|
16
|
+
Mark a milestone as complete after its audit has passed. Archives all scratch artifacts to `milestones/{M}/artifacts/`, moves artifact entries from `state.json.artifacts[]` to `milestone_history`, extracts final knowhow, and advances to the next milestone.
|
|
17
17
|
</purpose>
|
|
18
18
|
|
|
19
19
|
<required_reading>
|
|
@@ -34,14 +34,14 @@ Milestone: $ARGUMENTS (optional -- defaults to current_milestone from state.json
|
|
|
34
34
|
<execution>
|
|
35
35
|
Follow '~/.maestro/workflows/milestone-complete.md' completely.
|
|
36
36
|
|
|
37
|
-
Archive flow steps (validation, directory archival, artifact history,
|
|
37
|
+
Archive flow steps (validation, directory archival, artifact history, knowhow extraction, state advancement, cleanup) are defined in workflow `milestone-complete.md`.
|
|
38
38
|
|
|
39
39
|
### Knowledge Promotion Inquiry
|
|
40
40
|
|
|
41
|
-
After
|
|
41
|
+
After knowhow extraction (step 4), scan `learnings.md` for promotion candidates:
|
|
42
42
|
|
|
43
|
-
1. **High-frequency pattern detection**: Scan all `<spec-entry
|
|
44
|
-
→ Ask: "Keyword '{keyword}' appears in {N}
|
|
43
|
+
1. **High-frequency pattern detection**: Scan all `<spec-entry>` entries with `roles="implement"` for keyword overlap (≥2 entries sharing keywords):
|
|
44
|
+
→ Ask: "Keyword '{keyword}' appears in {N} knowhow entries. Should this be promoted to a formal coding convention? (`/spec-add coding`)"
|
|
45
45
|
|
|
46
46
|
2. **Convention drift detection**: Compare executed task summaries against `coding-conventions.md` and `architecture-constraints.md`:
|
|
47
47
|
→ Ask: "Were any established conventions bypassed during this milestone? Should conventions be updated?"
|
|
@@ -68,7 +68,7 @@ If user confirms promotion, invoke `Skill({ skill: "spec-add", args: "<category>
|
|
|
68
68
|
- [ ] Audit report verified as PASS
|
|
69
69
|
- [ ] Scratch artifacts moved to milestones/{M}/artifacts/
|
|
70
70
|
- [ ] Artifact entries archived to milestone_history
|
|
71
|
-
- [ ]
|
|
71
|
+
- [ ] Knowhow extracted to specs/learnings.md
|
|
72
72
|
- [ ] state.json updated: next milestone as current, artifacts[] cleared
|
|
73
73
|
- [ ] Roadmap snapshot saved
|
|
74
74
|
- [ ] project.md Context updated with milestone summary
|
|
@@ -85,7 +85,7 @@ Append to state.json.artifacts[]:
|
|
|
85
85
|
**Next-step routing on completion:**
|
|
86
86
|
- Converged (>=95%) → `/maestro-verify {phase}`
|
|
87
87
|
- All requirements verified (spec source) → `/maestro-milestone-audit`
|
|
88
|
-
- Bugs discovered → `/quality-debug --from-
|
|
88
|
+
- Bugs discovered → `/quality-debug --from-uat {phase}`
|
|
89
89
|
- Max iter, >80% → `/quality-test {phase}` for manual UAT
|
|
90
90
|
- Max iter, <80% → `/quality-debug {phase}`
|
|
91
91
|
- Coverage still low → `/quality-auto-test {phase} --layer {missing}`
|
|
@@ -49,6 +49,14 @@ Extract conclusions from related artifacts that may affect this debug session
|
|
|
49
49
|
2. **Wiki prior knowledge**: Run `maestro wiki search "<symptom keywords>" --json 2>/dev/null`. If results found, check for prior investigations on similar issues to avoid re-investigation.
|
|
50
50
|
3. Both are optional — proceed without if unavailable.
|
|
51
51
|
|
|
52
|
+
### Role Knowledge
|
|
53
|
+
1. Browse accumulated knowledge for this role:
|
|
54
|
+
`maestro wiki list --role analyze`
|
|
55
|
+
2. Analyze the index, identify entries relevant to the current task
|
|
56
|
+
3. Load selected documents:
|
|
57
|
+
`maestro wiki load <id1> [id2] [id3...]`
|
|
58
|
+
4. Review loaded knowledge before proceeding
|
|
59
|
+
|
|
52
60
|
**Output**: `DEBUG_DIR = .workflow/scratch/{YYYYMMDD}-debug-P{N}-{slug}/` (P{N} = phase number when phase-scoped; omit for standalone). Output directory rules defined in workflow debug.md Step 4.
|
|
53
61
|
</context>
|
|
54
62
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: quality-retrospective
|
|
3
|
-
description: Phase retrospective with insight routing to specs and
|
|
3
|
+
description: Phase retrospective with insight routing to specs and knowhow
|
|
4
4
|
argument-hint: "[phase|N..M] [--lens technical|process|quality|decision] [--all] [--no-route] [--compare N] [-y]"
|
|
5
5
|
allowed-tools:
|
|
6
6
|
- Read
|
|
@@ -13,7 +13,7 @@ allowed-tools:
|
|
|
13
13
|
- AskUserQuestion
|
|
14
14
|
---
|
|
15
15
|
<purpose>
|
|
16
|
-
Post-execution multi-perspective retrospective (复盘) for completed phases. Consumes existing execution artifacts (verification.json, review.json, issues.jsonl, plan.json, .summaries/, uat.md, state.json) and runs four parallel lenses — technical, process, quality, decision — to distill reusable insights. Routes each insight into the appropriate store: spec stub for reusable patterns, memory tip for process notes, issue for recurring gaps. Auto-scans for unreviewed completed phases and reports the backlog. Every insight is also persisted to `.workflow/
|
|
16
|
+
Post-execution multi-perspective retrospective (复盘) for completed phases. Consumes existing execution artifacts (verification.json, review.json, issues.jsonl, plan.json, .summaries/, uat.md, state.json) and runs four parallel lenses — technical, process, quality, decision — to distill reusable insights. Routes each insight into the appropriate store: spec stub for reusable patterns, memory tip for process notes, issue for recurring gaps. Auto-scans for unreviewed completed phases and reports the backlog. Every insight is also persisted to `.workflow/knowhow/specs/learnings.md` as `<spec-entry>` blocks for cross-phase queryability.
|
|
17
17
|
</purpose>
|
|
18
18
|
|
|
19
19
|
<required_reading>
|
|
@@ -70,9 +70,8 @@ Follow `~/.maestro/workflows/retrospective.md` Stages 1–8 in order. Key invari
|
|
|
70
70
|
- [ ] Spec entries (if any) appended as `<spec-entry>` to matching `.workflow/specs/{category-file}.md`
|
|
71
71
|
- [ ] Issue rows (if any) match canonical issues.jsonl schema (status "open", full issue_history, all required fields)
|
|
72
72
|
- [ ] Note tips (if any) created via `Skill({ skill: "manage-learn", args: "tip ..." })`
|
|
73
|
-
- [ ] `
|
|
74
|
-
- [ ] `learning-index.json` updated and parseable
|
|
73
|
+
- [ ] `specs/learnings.md` appended with one `<spec-entry>` per insight regardless of routing target
|
|
75
74
|
- [ ] No existing phase artifacts modified (verification.json, review.json, plan.json untouched)
|
|
76
75
|
- [ ] Confirmation banner displays routing counts and next-step suggestions
|
|
77
|
-
- [ ] Next step: `/manage-status` to review state, or `/manage-issue list --source retrospective` to triage created issues, or `/manage-learn list` to browse the
|
|
76
|
+
- [ ] Next step: `/manage-status` to review state, or `/manage-issue list --source retrospective` to triage created issues, or `/manage-learn list` to browse the knowhow library
|
|
78
77
|
</success_criteria>
|
|
@@ -54,6 +54,14 @@ Extract conclusions from related artifacts that may affect this review. Pass as
|
|
|
54
54
|
2. **Wiki constraints**: Run `maestro wiki search "architecture constraint" --json 2>/dev/null`. If results found, pass as `wiki_context` to reviewer agents for evaluating code against documented decisions.
|
|
55
55
|
3. Both are optional — proceed without if unavailable.
|
|
56
56
|
|
|
57
|
+
### Role Knowledge
|
|
58
|
+
1. Browse accumulated knowledge for this role:
|
|
59
|
+
`maestro wiki list --role review`
|
|
60
|
+
2. Analyze the index, identify entries relevant to the current task
|
|
61
|
+
3. Load selected documents:
|
|
62
|
+
`maestro wiki load <id1> [id2] [id3...]`
|
|
63
|
+
4. Review loaded knowledge before proceeding
|
|
64
|
+
|
|
57
65
|
**Output**: `REVIEW_DIR = .workflow/scratch/{YYYYMMDD}-review-P{N}-{slug}/` (P{N} = phase number, enables directory-level identification as state.json fallback)
|
|
58
66
|
</context>
|
|
59
67
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: spec-add
|
|
3
|
-
description: Add spec entry by category
|
|
4
|
-
argument-hint: "[--scope project|global|team|personal] <category> <content>"
|
|
3
|
+
description: Add spec entry by category with role tagging
|
|
4
|
+
argument-hint: "[--scope project|global|team|personal] [--roles <csv>] <category> <content>"
|
|
5
5
|
allowed-tools:
|
|
6
6
|
- Read
|
|
7
7
|
- Write
|
|
@@ -13,6 +13,7 @@ allowed-tools:
|
|
|
13
13
|
Add a knowledge entry to the specs system using `<spec-entry>` closed-tag format.
|
|
14
14
|
Each category maps 1:1 to a single target file — no dual-write.
|
|
15
15
|
Supports 4 scopes: project (default), global, team, personal.
|
|
16
|
+
Entries use `roles` attribute to declare which agent roles should load them.
|
|
16
17
|
</purpose>
|
|
17
18
|
|
|
18
19
|
<required_reading>
|
|
@@ -20,9 +21,29 @@ Supports 4 scopes: project (default), global, team, personal.
|
|
|
20
21
|
</required_reading>
|
|
21
22
|
|
|
22
23
|
<context>
|
|
23
|
-
$ARGUMENTS -- expects `[--scope <scope>] [--uid <uid>] <category> <content>`
|
|
24
|
+
$ARGUMENTS -- expects `[--scope <scope>] [--uid <uid>] [--roles <csv>] <category> <content>`
|
|
25
|
+
|
|
26
|
+
**Options:**
|
|
27
|
+
- `--roles <csv>` — Comma-separated roles (implement, plan, test, review, analyze, explore). Determines which agents load this entry via `spec load --role`.
|
|
28
|
+
- `--ref <path>` — Create as index entry referencing a knowhow document. If the path exists, only creates the spec index entry. If path doesn't exist, also creates the knowhow file.
|
|
29
|
+
- `--knowhow-type <type>` — Knowhow document type when creating with --ref (asset, blueprint, document, template, recipe, reference, decision)
|
|
24
30
|
|
|
25
31
|
Scope-to-directory mapping, category-to-file mapping, and entry format defined in workflow specs-add.md.
|
|
32
|
+
|
|
33
|
+
**Examples:**
|
|
34
|
+
```bash
|
|
35
|
+
# Tool spec with roles (stored in tools.md)
|
|
36
|
+
/spec-add tools "Integration Test Flow" "## Steps\n1. Setup\n2. Run" --roles "implement,test" --keywords "testing,api"
|
|
37
|
+
|
|
38
|
+
# Tool spec with ref to detailed knowhow
|
|
39
|
+
/spec-add tools "OAuth PKCE Flow" "完整 PKCE 集成流程" --roles "implement" --ref knowhow/RCP-oauth-pkce.md
|
|
40
|
+
|
|
41
|
+
# Standard spec with role
|
|
42
|
+
/spec-add coding "Named exports" "Always use named exports" --roles "implement"
|
|
43
|
+
|
|
44
|
+
# Legacy style (no --roles, backward compat)
|
|
45
|
+
/spec-add arch "OAuth PKCE 集成" "完整流程设计" --ref knowhow/AST-oauth-flow.md
|
|
46
|
+
```
|
|
26
47
|
</context>
|
|
27
48
|
|
|
28
49
|
<execution>
|
|
@@ -34,7 +55,7 @@ Follow '~/.maestro/workflows/specs-add.md' completely.
|
|
|
34
55
|
|------|----------|-------------|-------|
|
|
35
56
|
| E001 | fatal | Category and content are both required | parse_input |
|
|
36
57
|
| E002 | fatal | Specs directory not initialized -- run `maestro spec init --scope <scope>` | validate_entry |
|
|
37
|
-
| E003 | fatal | Invalid category -- must be one of: coding, arch, quality, debug, test, review, learning | parse_input |
|
|
58
|
+
| E003 | fatal | Invalid category -- must be one of: coding, arch, quality, debug, test, review, learning, tools | parse_input |
|
|
38
59
|
| E004 | fatal | Invalid scope -- must be one of: project, global, team, personal | parse_input |
|
|
39
60
|
| E005 | fatal | Personal scope requires uid -- use `--uid` or run `maestro collab join` first | parse_input |
|
|
40
61
|
</error_codes>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: spec-load
|
|
3
3
|
description: Load specs and lessons for current context
|
|
4
|
-
argument-hint: "[--
|
|
4
|
+
argument-hint: "[--role <role>] [--keyword <word>]"
|
|
5
5
|
allowed-tools:
|
|
6
6
|
- Read
|
|
7
7
|
- Bash
|
|
@@ -9,8 +9,8 @@ allowed-tools:
|
|
|
9
9
|
- Grep
|
|
10
10
|
---
|
|
11
11
|
<purpose>
|
|
12
|
-
Load
|
|
13
|
-
|
|
12
|
+
Load relevant specs filtered by role (primary), category (file-level), and/or keyword (entry-level).
|
|
13
|
+
Role-based loading: loads the role's primary doc in full + matching entries from other files.
|
|
14
14
|
</purpose>
|
|
15
15
|
|
|
16
16
|
<required_reading>
|
|
@@ -20,14 +20,34 @@ Supports filtering by category (file-level) and keyword (entry-level via `<spec-
|
|
|
20
20
|
<context>
|
|
21
21
|
$ARGUMENTS -- optional flags and keyword
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
**Flags:**
|
|
24
|
+
- `--role <role>` — Load by role: primary role doc (full) + cross-file entries with matching roles attr. Roles: implement, plan, test, review, analyze, explore, brainstorm, research.
|
|
25
|
+
- `--keyword <word>` — Filter by keyword within entries
|
|
26
|
+
|
|
27
|
+
**File → Primary Role mapping:**
|
|
28
|
+
| File | Role |
|
|
29
|
+
|------|------|
|
|
30
|
+
| coding-conventions.md | implement |
|
|
31
|
+
| architecture-constraints.md | plan |
|
|
32
|
+
| test-conventions.md | test |
|
|
33
|
+
| review-standards.md | review |
|
|
34
|
+
| debug-notes.md | analyze |
|
|
35
|
+
| quality-rules.md | review |
|
|
36
|
+
| learnings.md | implement |
|
|
37
|
+
| tools.md | _(per-entry roles)_ |
|
|
24
38
|
|
|
25
39
|
**Examples:**
|
|
26
40
|
```
|
|
41
|
+
/spec-load --role implement # coding全文 + 跨文件implement条目
|
|
42
|
+
/spec-load --role review # review-standards + quality-rules + 跨文件review条目
|
|
43
|
+
/spec-load --role implement --keyword auth
|
|
27
44
|
/spec-load --keyword auth
|
|
28
|
-
/spec-load --category coding --keyword naming
|
|
29
|
-
/spec-load --category arch
|
|
30
45
|
```
|
|
46
|
+
|
|
47
|
+
**Ref entries:**
|
|
48
|
+
When loading entries with `ref` attribute, only the summary is shown with a load command:
|
|
49
|
+
→ Detail: maestro wiki load <knowhow-id>
|
|
50
|
+
Use the load command to read the full referenced document.
|
|
31
51
|
</context>
|
|
32
52
|
|
|
33
53
|
<execution>
|
|
@@ -11,7 +11,7 @@ allowed-tools:
|
|
|
11
11
|
---
|
|
12
12
|
<purpose>
|
|
13
13
|
Initialize the project-level specs directory by scanning the codebase for conventions, patterns, and tech stack.
|
|
14
|
-
Core files (coding, arch,
|
|
14
|
+
Core files (coding, arch, knowhow) are always created. Optional files (quality, debug, test, review) are created only when relevant signals are detected.
|
|
15
15
|
All output lands in `.workflow/specs/`.
|
|
16
16
|
</purpose>
|
|
17
17
|
|
|
@@ -44,7 +44,7 @@ Follow '~/.maestro/workflows/specs-setup.md' completely.
|
|
|
44
44
|
|
|
45
45
|
<success_criteria>
|
|
46
46
|
- [ ] `.workflow/specs/` directory created
|
|
47
|
-
- [ ] Core files always created: `coding-conventions.md`, `architecture-constraints.md`, `
|
|
47
|
+
- [ ] Core files always created: `coding-conventions.md`, `architecture-constraints.md`, `knowhow.md`
|
|
48
48
|
- [ ] Optional files created when detected: `quality-rules.md` (linter/CI), `test-conventions.md` (test framework), `debug-notes.md` (on demand), `review-standards.md` (on demand)
|
|
49
49
|
- [ ] Report displayed with summary and next steps
|
|
50
50
|
</success_criteria>
|
|
@@ -56,7 +56,7 @@ Follow '~/.maestro/workflows/wiki-connect.md' completely (Stages 1-6).
|
|
|
56
56
|
- [ ] If --fix: entries updated with new `related` links
|
|
57
57
|
- [ ] If --fix: new health score computed and delta reported
|
|
58
58
|
- [ ] Report written to `wiki-connections-{date}.md`
|
|
59
|
-
- [ ] Graph insights appended to `
|
|
59
|
+
- [ ] Graph insights appended to `specs/learnings.md` as `<spec-entry>` blocks
|
|
60
60
|
- [ ] No unintended entry modifications (only `related` field changed)
|
|
61
61
|
- [ ] Summary displayed with next-step routing
|
|
62
62
|
</success_criteria>
|
|
@@ -48,7 +48,7 @@ Follow '~/.maestro/workflows/wiki-digest.md' completely (Stages 1-8).
|
|
|
48
48
|
| E001 | error | No wiki entries found (empty index) | Initialize wiki content first |
|
|
49
49
|
| E002 | error | Topic search returned 0 results | Broaden topic or check wiki content |
|
|
50
50
|
| W001 | warning | Too few entries (<5) for meaningful theme clustering | Digest produced but themes may be trivial |
|
|
51
|
-
| W002 | warning |
|
|
51
|
+
| W002 | warning | specs/learnings.md not found — skipping cross-reference | Proceed without knowhow context |
|
|
52
52
|
| W003 | warning | Some entry bodies failed to load — partial summaries | Note incomplete entries in digest |
|
|
53
53
|
</error_codes>
|
|
54
54
|
|
|
@@ -57,13 +57,12 @@ Follow '~/.maestro/workflows/wiki-digest.md' completely (Stages 1-8).
|
|
|
57
57
|
- [ ] Baseline health score recorded
|
|
58
58
|
- [ ] Entries clustered into 3-5 semantic themes
|
|
59
59
|
- [ ] Per-theme analysis: summary, key entries, gaps, health
|
|
60
|
-
- [ ] Cross-reference with
|
|
60
|
+
- [ ] Cross-reference with specs/learnings.md completed
|
|
61
61
|
- [ ] Coverage heatmap generated (type × theme matrix)
|
|
62
62
|
- [ ] Knowledge gaps identified with suggested actions
|
|
63
63
|
- [ ] If `--create-issues`: gap issues created in `issues.jsonl` (deduped)
|
|
64
|
-
- [ ] Digest written to `digest-{slug}-{date}.md`
|
|
65
|
-
- [ ] Meta-insights appended to `
|
|
66
|
-
- [ ]
|
|
67
|
-
- [ ] No files modified outside `.workflow/learning/` and `.workflow/issues/` (issues only when `--create-issues`)
|
|
64
|
+
- [ ] Digest written to `KNW-digest-{slug}-{date}.md`
|
|
65
|
+
- [ ] Meta-insights appended to `specs/learnings.md` as `<spec-entry>` blocks
|
|
66
|
+
- [ ] No files modified outside `.workflow/knowhow/` and `.workflow/issues/` (issues only when `--create-issues`)
|
|
68
67
|
- [ ] Summary displayed with key findings and next-step routing
|
|
69
68
|
</success_criteria>
|
package/package.json
CHANGED