@uoyo/mvtt 2.0.0-beta.0 → 2.0.0-beta.2

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 (151) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +194 -209
  3. package/dist/build/assembler.d.ts.map +1 -1
  4. package/dist/build/assembler.js +2 -0
  5. package/dist/build/assembler.js.map +1 -1
  6. package/dist/build/plan-validator.d.ts +26 -0
  7. package/dist/build/plan-validator.d.ts.map +1 -0
  8. package/dist/build/plan-validator.js +225 -0
  9. package/dist/build/plan-validator.js.map +1 -0
  10. package/dist/build/section-loader.d.ts.map +1 -1
  11. package/dist/build/section-loader.js +45 -9
  12. package/dist/build/section-loader.js.map +1 -1
  13. package/dist/cli.d.ts.map +1 -1
  14. package/dist/cli.js +2 -11
  15. package/dist/cli.js.map +1 -1
  16. package/dist/commands/doctor.d.ts.map +1 -1
  17. package/dist/commands/doctor.js +0 -1
  18. package/dist/commands/doctor.js.map +1 -1
  19. package/dist/commands/install.d.ts +1 -4
  20. package/dist/commands/install.d.ts.map +1 -1
  21. package/dist/commands/install.js +18 -14
  22. package/dist/commands/install.js.map +1 -1
  23. package/dist/commands/migrate.d.ts +16 -0
  24. package/dist/commands/migrate.d.ts.map +1 -0
  25. package/dist/commands/migrate.js +118 -0
  26. package/dist/commands/migrate.js.map +1 -0
  27. package/dist/commands/update.d.ts.map +1 -1
  28. package/dist/commands/update.js +35 -2
  29. package/dist/commands/update.js.map +1 -1
  30. package/dist/fs/core-manifest.d.ts +17 -0
  31. package/dist/fs/core-manifest.d.ts.map +1 -0
  32. package/dist/fs/core-manifest.js +76 -0
  33. package/dist/fs/core-manifest.js.map +1 -0
  34. package/dist/fs/install-manifest.d.ts +1 -2
  35. package/dist/fs/install-manifest.d.ts.map +1 -1
  36. package/dist/fs/install-manifest.js +1 -2
  37. package/dist/fs/install-manifest.js.map +1 -1
  38. package/dist/fs/materialize.d.ts.map +1 -1
  39. package/dist/fs/materialize.js +23 -3
  40. package/dist/fs/materialize.js.map +1 -1
  41. package/dist/types/core-manifest.d.ts +12 -0
  42. package/dist/types/core-manifest.d.ts.map +1 -0
  43. package/dist/types/core-manifest.js +2 -0
  44. package/dist/types/core-manifest.js.map +1 -0
  45. package/dist/types/registry.d.ts +13 -5
  46. package/dist/types/registry.d.ts.map +1 -1
  47. package/install-manifest.yaml +31 -27
  48. package/package.json +57 -57
  49. package/registry.yaml +198 -209
  50. package/sources/defaults/config.yaml +27 -30
  51. package/sources/defaults/project-context.yaml +15 -26
  52. package/sources/defaults/session.yaml +31 -23
  53. package/sources/knowledge/core/manifest.yaml +4 -45
  54. package/sources/sections/activation-load-config.md +11 -5
  55. package/sources/sections/activation-load-context.md +26 -11
  56. package/sources/sections/activation-preflight.md +14 -4
  57. package/sources/sections/footer-next-steps.md +35 -9
  58. package/sources/sections/output-language-constraint.md +11 -0
  59. package/sources/sections/role-header.md +13 -13
  60. package/sources/sections/session-update.md +47 -0
  61. package/sources/skills/mvt-analyze/business.md +69 -33
  62. package/sources/skills/mvt-analyze/manifest.yaml +90 -89
  63. package/sources/skills/mvt-analyze-code/business.md +82 -35
  64. package/sources/skills/mvt-analyze-code/manifest.yaml +96 -88
  65. package/sources/skills/mvt-bug-detect/business.md +101 -0
  66. package/sources/skills/mvt-bug-detect/manifest.yaml +84 -0
  67. package/sources/skills/mvt-check-context/business.md +89 -42
  68. package/sources/skills/mvt-check-context/manifest.yaml +63 -74
  69. package/sources/skills/mvt-cleanup/business.md +80 -31
  70. package/sources/skills/mvt-cleanup/manifest.yaml +85 -93
  71. package/sources/skills/mvt-config/business.md +94 -26
  72. package/sources/skills/mvt-config/manifest.yaml +96 -108
  73. package/sources/skills/mvt-create-skill/business.md +231 -111
  74. package/sources/skills/mvt-create-skill/manifest.yaml +91 -79
  75. package/sources/skills/mvt-design/business.md +116 -34
  76. package/sources/skills/mvt-design/manifest.yaml +96 -105
  77. package/sources/skills/mvt-fix/business.md +132 -28
  78. package/sources/skills/mvt-fix/manifest.yaml +85 -86
  79. package/sources/skills/mvt-help/business.md +74 -70
  80. package/sources/skills/mvt-help/manifest.yaml +67 -61
  81. package/sources/skills/mvt-implement/business.md +91 -32
  82. package/sources/skills/mvt-implement/manifest.yaml +80 -96
  83. package/sources/skills/mvt-init/business.md +164 -49
  84. package/sources/skills/mvt-init/manifest.yaml +101 -93
  85. package/sources/skills/mvt-manage-context/business.md +175 -0
  86. package/sources/skills/mvt-manage-context/manifest.yaml +123 -0
  87. package/sources/skills/mvt-plan-dev/business.md +75 -0
  88. package/sources/skills/mvt-plan-dev/manifest.yaml +91 -0
  89. package/sources/skills/mvt-quick-dev/business.md +99 -0
  90. package/sources/skills/mvt-quick-dev/manifest.yaml +69 -0
  91. package/sources/skills/mvt-refactor/business.md +104 -33
  92. package/sources/skills/mvt-refactor/manifest.yaml +86 -101
  93. package/sources/skills/mvt-resume/business.md +137 -0
  94. package/sources/skills/mvt-resume/manifest.yaml +71 -0
  95. package/sources/skills/mvt-review/business.md +112 -49
  96. package/sources/skills/mvt-review/manifest.yaml +87 -106
  97. package/sources/skills/mvt-status/business.md +71 -24
  98. package/sources/skills/mvt-status/manifest.yaml +66 -74
  99. package/sources/skills/mvt-sync-context/business.md +150 -25
  100. package/sources/skills/mvt-sync-context/manifest.yaml +96 -84
  101. package/sources/skills/mvt-template/business.md +96 -49
  102. package/sources/skills/mvt-template/manifest.yaml +63 -71
  103. package/sources/skills/mvt-test/business.md +104 -36
  104. package/sources/skills/mvt-test/manifest.yaml +102 -111
  105. package/sources/skills/mvt-update-plan/business.md +72 -0
  106. package/sources/skills/mvt-update-plan/manifest.yaml +132 -0
  107. package/sources/templates/analyze-output/body.md +15 -38
  108. package/sources/templates/analyze-output/manifest.yaml +11 -11
  109. package/sources/templates/design-output/body.md +17 -50
  110. package/sources/templates/design-output/manifest.yaml +11 -11
  111. package/sources/templates/implement-output/body.md +11 -32
  112. package/sources/templates/implement-output/manifest.yaml +11 -11
  113. package/sources/templates/project-context/body.md +13 -0
  114. package/sources/templates/project-context/manifest.yaml +12 -0
  115. package/sources/templates/review-output/body.md +11 -45
  116. package/sources/templates/review-output/manifest.yaml +11 -11
  117. package/sources/templates/test-output/body.md +7 -31
  118. package/sources/templates/test-output/manifest.yaml +11 -11
  119. package/dist/fs/protection.d.ts +0 -15
  120. package/dist/fs/protection.d.ts.map +0 -1
  121. package/dist/fs/protection.js +0 -16
  122. package/dist/fs/protection.js.map +0 -1
  123. package/sources/knowledge/core/review-principles.md +0 -51
  124. package/sources/knowledge/patterns/clean-architecture/manifest.yaml +0 -66
  125. package/sources/knowledge/patterns/clean-architecture/review-checklist.md +0 -230
  126. package/sources/knowledge/patterns/ddd/manifest.yaml +0 -83
  127. package/sources/knowledge/patterns/ddd/review-checklist.md +0 -226
  128. package/sources/knowledge/patterns/ddd/tactical-patterns.md +0 -12
  129. package/sources/knowledge/patterns/frontend-react/manifest.yaml +0 -44
  130. package/sources/knowledge/patterns/frontend-react/review-checklist.md +0 -78
  131. package/sources/knowledge/patterns/manifest.yaml +0 -113
  132. package/sources/skills/mvt-add-context/business.md +0 -47
  133. package/sources/skills/mvt-add-context/manifest.yaml +0 -83
  134. package/sources/templates/analyze-code-output/body.md +0 -44
  135. package/sources/templates/analyze-code-output/manifest.yaml +0 -11
  136. package/sources/templates/cleanup-output/body.md +0 -9
  137. package/sources/templates/cleanup-output/manifest.yaml +0 -11
  138. package/sources/templates/config-output/body.md +0 -11
  139. package/sources/templates/config-output/manifest.yaml +0 -11
  140. package/sources/templates/context-check-output/body.md +0 -32
  141. package/sources/templates/context-check-output/manifest.yaml +0 -11
  142. package/sources/templates/fix-output/body.md +0 -30
  143. package/sources/templates/fix-output/manifest.yaml +0 -11
  144. package/sources/templates/init-output/body.md +0 -34
  145. package/sources/templates/init-output/manifest.yaml +0 -11
  146. package/sources/templates/refactor-output/body.md +0 -32
  147. package/sources/templates/refactor-output/manifest.yaml +0 -11
  148. package/sources/templates/status-output/body.md +0 -36
  149. package/sources/templates/status-output/manifest.yaml +0 -11
  150. package/sources/templates/sync-context-output/body.md +0 -16
  151. package/sources/templates/sync-context-output/manifest.yaml +0 -11
@@ -1,28 +1,132 @@
1
- ## Execution Flow
2
-
3
- ### Step 1: Understand the Issue
4
- - Parse user description of the bug
5
- - Identify affected files and modules
6
- - Reproduce or confirm the issue
7
-
8
- ### Step 2: Root Cause Analysis
9
- - Generate hypotheses for the bug cause
10
- - Examine relevant code for each hypothesis
11
- - Test each hypothesis against the evidence
12
- - Identify the confirmed root cause
13
-
14
- ### Step 3: Plan the Fix
15
- - Determine the minimal change required
16
- - Check for side effects on related code
17
- - Verify the fix won't break existing behavior
18
-
19
- ### Step 4: Apply the Fix
20
- - Make the targeted code change
21
- - Verify fix addresses the root cause
22
- - Document what was changed and why
23
-
24
- ### Step 5: Update Workspace
25
- 1. Update `.ai-agents/workspace/session.yaml`:
26
- - Set `session.last_command: "/mvt-fix"`
27
- - Append one-line summary to `recent_actions` (keep max 3)
28
- - Do NOT update `progress` (shortcut operation)
1
+ ## Execution Flow
2
+
3
+ ### Step 1: Resolve Input Source
4
+ - Determine the diagnosis source by checking in priority order:
5
+
6
+ | Priority | Source | Condition | What to Load |
7
+ |----------|--------|-----------|--------------|
8
+ | 1 | Review artifact | `review.md` exists in active change artifacts | Critical + Warning findings as fix targets |
9
+ | 2 | Bug detection result | `/mvt-bug-detect` was executed in the current conversation | Root cause, affected files, severity, reproduction status from conversation history |
10
+ | 3 | Direct user input | User provided bug description in conversation | Bug description text |
11
+
12
+ - **1a. Review artifact (mvt-review output)**
13
+ - Read `.ai-agents/workspace/artifacts/{active_change.id}/review.md`
14
+ - Extract Critical + Warning findings as fix targets. For each finding: file, line range, observation, recommendation serve as pre-verified diagnosis.
15
+ - If multiple Critical findings exist, ask user which to address first.
16
+ - Skip Steps 2-4, proceed directly to Step 5.
17
+
18
+ - **1b. Bug detection result (mvt-bug-detect output)**
19
+ - Extract analysis results from the most recent `/mvt-bug-detect` execution in conversation history: Status, Root Cause, Severity, Affected files, Similar issues.
20
+ - If Status is `NotABug` or `Inconclusive` — STOP, report finding, do not proceed to fix.
21
+ - Skip Steps 2-4, proceed directly to Step 5 with extracted context.
22
+
23
+ - **1c. Direct user input (no upstream artifact)**
24
+ - Read bug description from user message.
25
+ - Execute Steps 2-4 for self-contained diagnosis.
26
+
27
+ - **Fallback**: If no source yields content, ask user to describe the bug or run `/mvt-bug-detect` first.
28
+ - **Recommended (read if available, do not block on absence)**:
29
+ - Recent git state: `git diff HEAD`, `git log -n 10 --oneline` -- to surface recent changes that may correlate with the regression.
30
+
31
+ ### Step 2: Reproduce & Localize (only for source 1c)
32
+ **Skip this step if Step 1 resolved to source 1a (review artifact) or 1b (bug detection).**
33
+ - **What**: confirm the bug is reproducible (or, if not reproducible, mark it explicitly as "report-only") and identify the smallest set of files that contain the suspected fault.
34
+ - **How**:
35
+ 1. Extract concrete signals from the bug description: error message text, stack trace frames, file paths, function/class names, input data.
36
+ 2. For each signal, locate matching code (Grep / Glob).
37
+ 3. Build a candidate file list with one-line justification per file.
38
+ 4. If reproduction steps are provided, attempt to reproduce (run command, write minimal repro snippet) before forming hypotheses.
39
+ - **Branches**:
40
+
41
+ | Condition | Action |
42
+ |-----------|--------|
43
+ | Reproducible locally | Capture observed vs expected, proceed to Step 3 |
44
+ | Not reproducible, signals are concrete (stack trace + paths) | Continue with static analysis only, mark "unverified repro" in fix notes |
45
+ | Not reproducible, signals are vague | STOP -- ask user for: minimal repro, exact error, environment, last-known-good version |
46
+
47
+ ### Step 3: Generate Hypotheses (only for source 1c)
48
+ **Skip this step if Step 1 resolved to source 1a or 1b.**
49
+ - **What**: produce 1-5 candidate root causes, each with a falsifiable check.
50
+ - **How**: derive hypotheses from the dominant input signal using the table below. Combine sources when multiple are available.
51
+
52
+ | Dominant signal | Hypothesis sources |
53
+ |-----------------|--------------------|
54
+ | Stack trace | Top frame in user code, recently changed code in any frame, null/undefined origin, type mismatch at boundary |
55
+ | Error message | Exact-string search in repo, typed exception class hierarchy, library docs for that error |
56
+ | Recent git diff | Files changed in last N commits intersecting with localized files (Step 2), commit messages mentioning related modules |
57
+ | Behavioral description (no error) | Module boundary mismatches, off-by-one / null-handling, async/race, state leakage, configuration drift |
58
+
59
+ - Each hypothesis must be written as: `<claim> -- evidence: <pointer> -- check: <how to verify>`.
60
+
61
+ ### Step 4: Verify Root Cause (only for source 1c)
62
+ **Skip this step if Step 1 resolved to source 1a or 1b.**
63
+ - **What**: reduce the hypothesis set to one confirmed root cause.
64
+ - **How**:
65
+ 1. For each hypothesis, run its check (read code, add tracing, run a focused script). Cheapest check first.
66
+ 2. Eliminate hypotheses that fail their checks.
67
+ 3. STOP and report if all hypotheses are eliminated -- do not invent new ones silently; ask the user for more information.
68
+ - **Branches**:
69
+
70
+ | Result | Action |
71
+ |--------|--------|
72
+ | Exactly one hypothesis confirmed | Record as root cause, proceed to Step 5 |
73
+ | Multiple hypotheses still plausible | Pick the cheapest fix that addresses ALL of them, OR ask user to prioritize |
74
+ | Zero hypotheses survive | STOP, surface findings, request more info from user |
75
+
76
+ ### Step 5: Plan the Fix
77
+ - **What**: decide the change scope and minimum-risk patch shape.
78
+ - **How**: classify the fix using the table below. Choose the strategy that matches the smallest viable scope -- escalate only if the smaller scope cannot fully address the root cause.
79
+ - For source 1a (review.md): each Critical/Warning finding maps to a fix; classify individually.
80
+ - For source 1b (bug detection result): use the root cause and affected files from the diagnosis to determine fix class directly.
81
+ - For source 1c: classify based on self-contained diagnosis from Steps 2-4.
82
+
83
+ | Fix class | Indicator | Strategy |
84
+ |-----------|-----------|----------|
85
+ | One-liner | Typo, off-by-one, missing null check, wrong constant | Apply directly, minimal review |
86
+ | Single-file | Logic localized to one module, no public API change | Apply, list affected callers in fix notes |
87
+ | Multi-module | Touches >1 module or shared utility | List impacted modules, read each call site before editing, group by commit if possible |
88
+ | Cross-architecture | Requires layering change, new dependency, or interface redesign | STOP -- recommend `/mvt-design` (or `/mvt-refactor` if behavior is preserved); do NOT implement here |
89
+
90
+ - Identify regression risk: which existing tests cover this code? If none, decide whether to add a regression test in Step 7.
91
+
92
+ ### Step 6: User Confirmation
93
+ - **When to confirm before applying**:
94
+ - Multi-module class or above.
95
+ - The fix changes a public/exported symbol or a configuration default.
96
+ - The reproduction was unverified (Step 2).
97
+ - The fix deletes existing behavior (not just adjusts it).
98
+ - **When to apply silently**:
99
+ - One-liner / single-file class AND fix is purely additive or correctional AND reproduction was verified.
100
+ - **Confirmation prompt format**: present `Root cause: ...`, `Proposed change: <files + summary>`, `Risk: <regression scope>`, then ask `Apply? (y / n / show-diff)`.
101
+
102
+ ### Step 7: Apply the Fix
103
+ - For source 1a (review.md): apply fixes per finding; re-run the review's relevant checks (not reproduction) to confirm each fix addresses its finding.
104
+ - Make the targeted code change.
105
+ - If no test covered the regression and the fix class is multi-module or above, add a minimal regression test alongside the fix.
106
+ - Re-run the original repro (if any) to confirm resolution.
107
+ - If repro still fails -> revert, return to Step 3 with the new evidence.
108
+
109
+ ### Step 8: Write Fix Notes
110
+ - **Path**: `.ai-agents/workspace/artifacts/{change-id}/fix-notes.md` if an `active_change` exists; otherwise inline in the conversation only (no artifact -- shortcut operation).
111
+ - **Structure** (each section is a single paragraph or list):
112
+ - `Symptom` -- what the user saw / reported.
113
+ - `Input Source` -- "Review artifact" | "Bug detection result" | "Direct user input".
114
+ - `Reproduction` -- verified | unverified | not-applicable, with steps if verified.
115
+ - `Hypotheses considered` -- bulleted, one line each, marking the confirmed one. (Skip if source 1a or 1b provided a pre-verified root cause.)
116
+ - `Root cause` -- one paragraph.
117
+ - `Patch summary` -- files touched + one-line per file.
118
+ - `Regression risk` -- scope of behavior potentially affected, plus what tests guard it.
119
+ - `Follow-ups` -- TODOs, deferred refactors, related issues.
120
+
121
+ ### Step 9: (session update handled by shared section)
122
+
123
+ ## Edge Cases & Errors
124
+
125
+ | Case | Handling |
126
+ |------|----------|
127
+ | Bug is intermittent / racy | Mark reproduction as "flaky", state confidence level explicitly, prefer adding instrumentation over speculative fix |
128
+ | Fix would require breaking a downstream API | STOP -- escalate to `/mvt-design` or `/mvt-refactor`; do not silently break contracts |
129
+ | Root cause is in a third-party dependency | Document the upstream issue, apply a minimal local workaround clearly labeled as temporary |
130
+ | User aborts at Step 6 | Do not write fix notes; record the diagnosis as a comment in the conversation only |
131
+ | Fix relies on changes the user has uncommitted in another branch | Surface the conflict before editing; do not overwrite |
132
+ | `active_change` is missing entirely | Apply fix without writing artifact (shortcut mode), summarize result in conversation |
@@ -1,86 +1,85 @@
1
- name: mvt-fix
2
- output: .claude/skills/mvt-fix/SKILL.md
3
-
4
- frontmatter:
5
- name: mvt-fix
6
- description: "Diagnose and fix bugs or issues in the codebase. Performs root cause analysis and applies targeted fixes. Use when user reports a bug, error, or wants to fix an issue."
7
-
8
- sections:
9
- - type: inline
10
- content: |
11
- # MVT Fix
12
-
13
- ## Purpose
14
-
15
- Diagnose bugs and issues, perform root cause analysis, and apply targeted fixes. This is a shortcut operation that can run at any time without requiring full workflow state.
16
-
17
- - type: shared
18
- source: sections/role-header.md
19
- params:
20
- role: Developer
21
- role_desc: "an Implementation Specialist"
22
- decision_rules:
23
- - rule: "Bug description provided -> Analyze the issue, propose fix, apply after user confirms"
24
- - rule: "Error message provided -> Trace to root cause, fix the source not the symptom"
25
- - rule: "Multiple possible causes -> List hypotheses with evidence, verify each"
26
- - rule: "Fix requires architecture change -> Stop and suggest `/mvt-design`"
27
- - rule: "Fix affects other modules -> Document impact scope before applying"
28
- boundaries:
29
- - scope: "re-analyze requirements"
30
- skill: "/mvt-analyze"
31
- - scope: "evaluate architecture"
32
- skill: "/mvt-design"
33
- - scope: "review own fix"
34
- skill: "/mvt-review"
35
-
36
- - type: shared
37
- source: sections/activation-load-context.md
38
- params:
39
- extended_context:
40
- - "Related source files only (load based on bug description)"
41
-
42
- - type: shared
43
- source: sections/activation-load-config.md
44
-
45
- - type: shared
46
- source: sections/activation-preflight.md
47
- params:
48
- checks:
49
- - order: "1"
50
- field: "session.initialized_at"
51
- level: "WARN"
52
- message: 'Session not initialized. Run `/mvt-init` first.'
53
-
54
- - type: inline
55
- content: |
56
- ### Shortcut Operation Rules
57
- - Can execute at any time without checking workflow prerequisites
58
- - Do NOT update `progress` in `session.yaml` after completion
59
- - Only update `session.last_command` and `recent_actions`
60
-
61
- ### Step 4: Execute
62
- Proceed to Execution Flow below.
63
-
64
- - type: file
65
- source: ./business.md
66
-
67
- - type: inline
68
- content: |
69
- ## Output Format
70
-
71
- Read and use the output template from: `.ai-agents/skills/_templates/fix-output.md`
72
-
73
- If a custom version exists at `.ai-agents/skills/_templates/custom/fix-output.md`, use the custom version instead.
74
-
75
- Fill the template placeholders with the fix results.
76
-
77
- Every response MUST end with a Suggested Next Steps section.
78
-
79
- - type: shared
80
- source: sections/footer-next-steps.md
81
- params:
82
- next_primary: mvt-review
83
- next_primary_desc: "Verify the fix"
84
- next_alternatives:
85
- - skill: mvt-test
86
- when: "Add regression tests"
1
+ name: mvt-fix
2
+ output: .claude/skills/mvt-fix/SKILL.md
3
+
4
+ frontmatter:
5
+ name: mvt-fix
6
+ description: "Diagnose and fix bugs or issues in the codebase. This skill should be used when user reports a bug, encounters an error, or wants to diagnose and resolve an issue."
7
+
8
+ sections:
9
+ - type: inline
10
+ content: |
11
+ # MVT Fix
12
+
13
+ ## Purpose
14
+
15
+ Diagnose bugs and issues, perform root cause analysis, and apply targeted fixes. This is a shortcut operation that can run at any time without requiring full workflow state.
16
+
17
+ - type: shared
18
+ source: sections/role-header.md
19
+ params:
20
+ role: Developer
21
+ role_desc: "an Implementation Specialist"
22
+ decision_rules:
23
+ - rule: "Bug description provided -> Analyze the issue, propose fix, apply after user confirms"
24
+ - rule: "Error message provided -> Trace to root cause, fix the source not the symptom"
25
+ - rule: "Multiple possible causes -> List hypotheses with evidence, verify each"
26
+ - rule: "Fix requires architecture change -> Stop and suggest `/mvt-design`"
27
+ - rule: "Fix affects other modules -> Document impact scope before applying"
28
+ boundaries:
29
+ - scope: "re-analyze requirements"
30
+ skill: "/mvt-analyze"
31
+ - scope: "evaluate architecture"
32
+ skill: "/mvt-design"
33
+ - scope: "review own fix"
34
+ skill: "/mvt-review"
35
+ - scope: "diagnose bugs without fixing"
36
+ skill: "/mvt-bug-detect"
37
+
38
+ - type: shared
39
+ source: sections/activation-load-context.md
40
+ params:
41
+ extended_context:
42
+ - "Related source files only (load based on bug description)"
43
+
44
+ - type: shared
45
+ source: sections/activation-load-config.md
46
+
47
+ - type: shared
48
+ source: sections/output-language-constraint.md
49
+
50
+ - type: shared
51
+ source: sections/activation-preflight.md
52
+ params:
53
+ checks:
54
+ - order: "1"
55
+ field: "session.initialized_at"
56
+ level: "WARN"
57
+ message: 'Session not initialized. Run `/mvt-init` first.'
58
+
59
+ - type: inline
60
+ content: |
61
+ ### Shortcut Operation Rules
62
+ - Can execute at any time without checking workflow prerequisites
63
+ - Do NOT update `progress` (this is a shortcut operation, not a workflow phase)
64
+
65
+ - type: file
66
+ source: ./business.md
67
+
68
+ - type: shared
69
+ source: sections/session-update.md
70
+
71
+ - type: shared
72
+ source: sections/footer-next-steps.md
73
+ params:
74
+ current_skill: mvt-fix
75
+ conditional_suggestions:
76
+ conditions:
77
+ - condition: "fix applied, root cause had wide impact"
78
+ primary: "mvt-review"
79
+ primary_desc: "Review the fix for side effects"
80
+ - condition: "fix applied, needs test coverage"
81
+ primary: "mvt-test"
82
+ primary_desc: "Add regression tests"
83
+ - condition: "bug too complex for targeted fix"
84
+ primary: "mvt-design"
85
+ primary_desc: "Design architectural solution"
@@ -1,70 +1,74 @@
1
- ## Execution Flow
2
-
3
- ### Step 1: Load Current State
4
- - Read session.yaml: check initialization, active change, phase progress
5
- - Read project-context.yaml: check project info completeness
6
- - Read config.yaml: check pattern.active
7
-
8
- ### Step 2: Assess User Position
9
- Determine where the user is in the workflow and what to recommend:
10
-
11
- | Condition | Recommendation |
12
- |-----------|---------------|
13
- | Not initialized | `/mvt-init` -- Initialize the project |
14
- | Initialized, no requirements | `/mvt-analyze` -- Analyze requirements |
15
- | Requirements exist, no architecture | `/mvt-design` -- Design architecture |
16
- | Architecture exists, not implemented | `/mvt-implement` -- Implement the design |
17
- | Implemented, not reviewed | `/mvt-review` -- Review the code |
18
- | Reviewed, not tested | `/mvt-test` -- Write tests |
19
- | All phases complete | `/mvt-cleanup` or start new feature |
20
-
21
- ### Step 3: Display Skills Catalog
22
- Show all available skills grouped by category:
23
-
24
- **Workflow Skills** (sequential phases):
25
- | Skill | Description |
26
- |-------|-------------|
27
- | `/mvt-analyze` | Analyze requirements and extract domain concepts |
28
- | `/mvt-analyze-code` | Reverse-analyze existing code to generate context |
29
- | `/mvt-design` | Create architecture design based on requirements |
30
- | `/mvt-implement` | Implement features based on architecture design |
31
- | `/mvt-review` | Code review for quality and standards compliance |
32
- | `/mvt-test` | Generate tests to validate implementations |
33
-
34
- **Shortcut Skills** (anytime, no prerequisites):
35
- | Skill | Description |
36
- |-------|-------------|
37
- | `/mvt-fix` | Diagnose and fix bugs or issues |
38
- | `/mvt-refactor` | Refactor code while preserving behavior |
39
-
40
- **Project Management Skills**:
41
- | Skill | Description |
42
- |-------|-------------|
43
- | `/mvt-init` | Initialize or refresh project setup |
44
- | `/mvt-status` | Show current project and workflow status |
45
- | `/mvt-config` | Manage framework configuration |
46
- | `/mvt-sync-context` | Synchronize context with code changes |
47
- | `/mvt-cleanup` | Clean up workspace artifacts |
48
-
49
- **Utility Skills**:
50
- | Skill | Description |
51
- |-------|-------------|
52
- | `/mvt-help` | Show this help information |
53
- | `/mvt-create-skill` | Create custom MVTT skills through guided workflow |
54
- | `/mvt-add-context` | Interactively add or update project context |
55
- | `/mvt-check-context` | Analyze context token load and optimization |
56
- | `/mvt-template` | View, customize, and manage output templates |
57
-
58
- ### Step 4: Show Workflow Diagram
59
- Display the standard workflow with current position highlighted:
60
-
61
- ```mermaid
62
- flowchart LR
63
- A[analyze] --> B[design] --> C[implement] --> D[review] --> E[test]
64
- ```
65
-
66
- Color-code based on current progress: green (done), yellow (current/recommended), gray (pending).
67
-
68
- ### Step 5: Respond to User Questions
69
- - If user asks about a specific skill -> Provide usage details for that skill
70
- - If user asks "what should I do next" -> Give contextual recommendation based on Step 2
1
+ ## Execution Flow
2
+
3
+ ### Step 1: Load Inputs
4
+ - **Recommended**:
5
+ - `.ai-agents/knowledge/project/_generated/project-context.md` -- existence check only, to detect whether semantic context has been generated.
6
+ - **Fallback**: any missing optional file is treated as "feature absent" for assessment purposes; do not abort. If `registry.yaml` itself is missing, surface the error and recommend `mvtt install`.
7
+
8
+ ### Step 2: Assess User Position
9
+ - **What**: pick exactly one recommended next skill based on the current workspace state.
10
+ - **How**: walk the table top-to-bottom; the first row whose condition holds wins.
11
+
12
+ | Condition | Recommendation |
13
+ |-----------|---------------|
14
+ | `session.yaml` missing or `initialized_at` empty | `/mvt-init` -- Initialize the project |
15
+ | Initialized AND `project-context.md` does not exist | `/mvt-analyze-code` -- Analyze existing code |
16
+ | No requirements (no `analysis.md` for active change AND no completed `/mvt-analyze` in `skill_history`) | `/mvt-analyze` -- Analyze requirements |
17
+ | No requirements, but user describes a simple change directly | `/mvt-quick-dev` -- Implement a simple change quickly |
18
+ | Requirements present, no `design.md` | `/mvt-design` -- Design architecture |
19
+ | `design.md` exists, change is large (Change Tracking lists > 5 files OR ADR includes breaking change OR > 1 new module) | `/mvt-plan-dev` -- Decompose into tracked plan |
20
+ | `design.md` (or `plan.yaml`) ready, no `implementation.md` | `/mvt-implement` -- Implement the design |
21
+ | `implementation.md` exists, no `review.md` | `/mvt-review` -- Review the code |
22
+ | `review.md` exists with no Critical findings, no `test-design.md` | `/mvt-test` -- Write tests |
23
+ | `review.md` has Critical findings | `/mvt-fix` -- Fix critical issues before continuing |
24
+ | All of the above complete | `/mvt-cleanup` -- Tidy artifacts, OR start a new feature with `/mvt-analyze` |
25
+
26
+ ### Step 3: Display Skills Catalog
27
+ Read `registry.yaml` > `skills` section.
28
+ Group skills by `category` field and display as tables:
29
+ - `workflow` -> "Workflow Skills (sequential phases)"
30
+ - `shortcut` -> "Shortcut Skills (anytime, no prerequisites)"
31
+ - `project` -> "Project Management Skills"
32
+ - `utility` -> "Utility Skills"
33
+
34
+ For each skill, show: `/{skill-name}` | `description` field from registry.
35
+ Sort within each group by declaration order in registry.
36
+
37
+ ### Step 4: Show Workflow Diagram
38
+ Display the standard workflow with current position highlighted:
39
+
40
+ ```mermaid
41
+ flowchart LR
42
+ A[init] --> B[analyze-code] --> C[analyze] --> D[design] --> D2[plan-dev]
43
+ D --> E[implement]
44
+ D2 --> E
45
+ E --> F[review] --> G[test]
46
+
47
+ C -.->|simple change| Q[quick-dev]
48
+ ```
49
+
50
+ Color-code based on current progress: green (done), yellow (current/recommended), gray (pending). The "current" node is whichever skill the Step 2 table recommended; "done" is determined by the same evidence the Step 2 table consumed.
51
+
52
+ ### Step 5: Respond to User Questions
53
+ - **What**: handle the user's free-form question after the catalog is rendered.
54
+ - **How**:
55
+
56
+ | Question pattern | Response |
57
+ |------------------|----------|
58
+ | "What should I do next?" / no specific question | Repeat the Step 2 recommendation in one line, followed by a one-clause reason citing the matched condition |
59
+ | "What does `/mvt-X` do?" / asks about a specific skill | Read the skill's metadata from `registry.yaml`, show: name, description, category, dependencies, knowledge entries (if any), template (if any). If the skill has a `path`, mention "see SKILL.md for the full procedure" -- do NOT inline the full SKILL.md content (too large) |
60
+ | "Compare `/mvt-X` and `/mvt-Y`" | Pull descriptions from registry; if both are workflow skills, mention their relative position in the diagram |
61
+ | Asks about something not in registry | Reply: "No skill matches that. Available skills: see catalog above." Do not invent skills |
62
+
63
+ ### Step 6: (session update handled by shared section)
64
+
65
+ ## Edge Cases & Errors
66
+
67
+ | Case | Handling |
68
+ |------|----------|
69
+ | `registry.yaml` missing | STOP at Step 1; recommend `mvtt install`; show no catalog |
70
+ | `session.yaml` missing | Render catalog (Step 3) and diagram (Step 4) without the "current position" highlight; Step 2 recommends `/mvt-init` |
71
+ | `recent_changes[]` references a `plan_path` that no longer exists | Ignore for help purposes; do not warn -- `/mvt-status` is the right place for that |
72
+ | User invokes `/mvt-help` while inside an active change with Critical review findings | Step 2's recommendation is `/mvt-fix`; surface this prominently above the catalog |
73
+ | User asks about a custom skill (registry entry with `custom: true`) | Treat identically to built-ins; the only difference is showing `custom: true` in the metadata view |
74
+ | Workflow diagram cannot be rendered (mermaid unsupported in environment) | Fall back to a textual flow: `init -> analyze-code -> analyze -> design -> [plan-dev] -> implement -> review -> test` |
@@ -1,61 +1,67 @@
1
- name: mvt-help
2
- output: .claude/skills/mvt-help/SKILL.md
3
-
4
- frontmatter:
5
- name: mvt-help
6
- description: "Show available skills, current project status, and workflow guidance. Use when user is new to MVTT, wants to know what commands are available, or needs guidance on what to do next."
7
-
8
- sections:
9
- - type: inline
10
- content: |
11
- # MVT Help
12
-
13
- ## Purpose
14
-
15
- Help users navigate the MVTT framework by showing available skills, current project status, and contextual guidance on what to do next. This is the entry point for new users and a quick reference for experienced ones.
16
-
17
- ## Role
18
-
19
- You are the **Conductor** -- a Workflow Coordinator.
20
-
21
- - type: shared
22
- source: sections/activation-load-context.md
23
-
24
- - type: shared
25
- source: sections/activation-load-config.md
26
-
27
- - type: inline
28
- content: |
29
- ### Step 3: Pre-flight Checks
30
- - No blocking checks required.
31
-
32
- ### Step 4: Execute
33
- Proceed to Execution Flow below.
34
-
35
- - type: file
36
- source: ./business.md
37
-
38
- - type: inline
39
- content: |
40
- ## Output Format
41
-
42
- Output is generated inline (no external template). Structure:
43
-
44
- ```markdown
45
- ## MVT Help
46
-
47
- ### Current Status
48
- - **Project**: {name} ({initialized/not initialized})
49
- - **Current Phase**: {phase}
50
- - **Recommended Next**: `/mvt-{next}` -- {description}
51
-
52
- ### Workflow
53
- {Mermaid flowchart with current position highlighted}
54
-
55
- ### Available Skills
56
- {Skills tables grouped by category, as defined in Step 3}
57
-
58
- ---
59
- **Suggested Next Steps**:
60
- - `/mvt-{recommended}` -- {description}
61
- ```
1
+ name: mvt-help
2
+ output: .claude/skills/mvt-help/SKILL.md
3
+
4
+ frontmatter:
5
+ name: mvt-help
6
+ description: "Show available skills, current project status, and workflow guidance. This skill should be used when user is new to MVTT, wants to discover available commands, or needs guidance on what to do next."
7
+
8
+ sections:
9
+ - type: inline
10
+ content: |
11
+ # MVT Help
12
+
13
+ ## Purpose
14
+
15
+ Navigate the MVTT framework by showing available skills, current project status, and contextual guidance on what to do next. Entry point for new users and quick reference for experienced ones.
16
+
17
+ ## Role
18
+
19
+ You are the **Conductor** -- a Workflow Coordinator.
20
+
21
+ - type: shared
22
+ source: sections/activation-load-context.md
23
+
24
+ - type: shared
25
+ source: sections/activation-load-config.md
26
+
27
+ - type: shared
28
+ source: sections/output-language-constraint.md
29
+
30
+ - type: inline
31
+ content: |
32
+ ### Step 3: Pre-flight Checks
33
+ - No blocking checks required.
34
+
35
+ - type: file
36
+ source: ./business.md
37
+
38
+ - type: inline
39
+ content: |
40
+ ## Output Format
41
+
42
+ Output is generated inline (no external template). Structure:
43
+
44
+ ```markdown
45
+ ## MVT Help
46
+
47
+ ### Current Status
48
+ - **Project**: {name} ({initialized/not initialized})
49
+ - **Last Skill**: {last command from skill_history}
50
+ - **Recommended Next**: `/mvt-{next}` -- {description}
51
+
52
+ ### Workflow
53
+ {Mermaid flowchart with current position highlighted}
54
+
55
+ ### Available Skills
56
+ {Skills tables grouped by category, as defined in Step 3}
57
+ ```
58
+
59
+ - type: shared
60
+ source: sections/session-update.md
61
+ params:
62
+ read_only: true
63
+
64
+ - type: shared
65
+ source: sections/footer-next-steps.md
66
+ params:
67
+ current_skill: mvt-help