moai-adk 0.8.1__py3-none-any.whl → 0.8.3__py3-none-any.whl
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.
Potentially problematic release.
This version of moai-adk might be problematic. Click here for more details.
- moai_adk/cli/commands/update.py +15 -4
- moai_adk/core/config/migration.py +1 -1
- moai_adk/core/issue_creator.py +7 -3
- moai_adk/core/tags/__init__.py +86 -0
- moai_adk/core/tags/ci_validator.py +433 -0
- moai_adk/core/tags/cli.py +283 -0
- moai_adk/core/tags/generator.py +109 -0
- moai_adk/core/tags/inserter.py +99 -0
- moai_adk/core/tags/mapper.py +126 -0
- moai_adk/core/tags/parser.py +76 -0
- moai_adk/core/tags/pre_commit_validator.py +355 -0
- moai_adk/core/tags/reporter.py +957 -0
- moai_adk/core/tags/tags.py +149 -0
- moai_adk/core/tags/validator.py +897 -0
- moai_adk/templates/.claude/agents/alfred/cc-manager.md +25 -2
- moai_adk/templates/.claude/agents/alfred/debug-helper.md +24 -12
- moai_adk/templates/.claude/agents/alfred/doc-syncer.md +19 -12
- moai_adk/templates/.claude/agents/alfred/git-manager.md +20 -12
- moai_adk/templates/.claude/agents/alfred/implementation-planner.md +19 -12
- moai_adk/templates/.claude/agents/alfred/project-manager.md +29 -2
- moai_adk/templates/.claude/agents/alfred/quality-gate.md +25 -2
- moai_adk/templates/.claude/agents/alfred/skill-factory.md +30 -2
- moai_adk/templates/.claude/agents/alfred/spec-builder.md +26 -11
- moai_adk/templates/.claude/agents/alfred/tag-agent.md +30 -8
- moai_adk/templates/.claude/agents/alfred/tdd-implementer.md +27 -12
- moai_adk/templates/.claude/agents/alfred/trust-checker.md +25 -2
- moai_adk/templates/.claude/commands/alfred/0-project.md +5 -0
- moai_adk/templates/.claude/commands/alfred/1-plan.md +82 -19
- moai_adk/templates/.claude/commands/alfred/2-run.md +72 -15
- moai_adk/templates/.claude/commands/alfred/3-sync.md +74 -14
- moai_adk/templates/.claude/hooks/alfred/.moai/cache/version-check.json +9 -0
- moai_adk/templates/.claude/hooks/alfred/README.md +258 -145
- moai_adk/templates/.claude/hooks/alfred/TROUBLESHOOTING.md +471 -0
- moai_adk/templates/.claude/hooks/alfred/alfred_hooks.py +92 -57
- moai_adk/templates/.claude/hooks/alfred/core/version_cache.py +198 -0
- moai_adk/templates/.claude/hooks/alfred/notification__handle_events.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/post_tool__log_changes.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/pre_tool__auto_checkpoint.py +108 -0
- moai_adk/templates/.claude/hooks/alfred/session_end__cleanup.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/session_start__show_project_info.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/{core → shared/core}/project.py +286 -19
- moai_adk/templates/.claude/hooks/alfred/shared/core/version_cache.py +198 -0
- moai_adk/templates/.claude/hooks/alfred/{handlers → shared/handlers}/session.py +21 -7
- moai_adk/templates/.claude/hooks/alfred/stop__handle_interrupt.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/subagent_stop__handle_subagent_end.py +102 -0
- moai_adk/templates/.claude/hooks/alfred/user_prompt__jit_load_docs.py +120 -0
- moai_adk/templates/.claude/settings.json +5 -5
- moai_adk/templates/.claude/skills/moai-foundation-ears/SKILL.md +9 -6
- moai_adk/templates/.claude/skills/moai-spec-authoring/README.md +56 -56
- moai_adk/templates/.claude/skills/moai-spec-authoring/SKILL.md +101 -100
- moai_adk/templates/.claude/skills/moai-spec-authoring/examples/validate-spec.sh +3 -3
- moai_adk/templates/.claude/skills/moai-spec-authoring/examples.md +219 -219
- moai_adk/templates/.claude/skills/moai-spec-authoring/reference.md +287 -287
- moai_adk/templates/.github/ISSUE_TEMPLATE/spec.yml +9 -11
- moai_adk/templates/.github/PULL_REQUEST_TEMPLATE.md +9 -21
- moai_adk/templates/.github/workflows/moai-release-create.yml +100 -0
- moai_adk/templates/.github/workflows/moai-release-pipeline.yml +182 -0
- moai_adk/templates/.github/workflows/release.yml +49 -0
- moai_adk/templates/.github/workflows/tag-report.yml +261 -0
- moai_adk/templates/.github/workflows/tag-validation.yml +176 -0
- moai_adk/templates/.moai/config.json +6 -1
- moai_adk/templates/.moai/hooks/install.sh +79 -0
- moai_adk/templates/.moai/hooks/pre-commit.sh +66 -0
- moai_adk/templates/CLAUDE.md +39 -40
- moai_adk/templates/src/moai_adk/core/__init__.py +5 -0
- moai_adk/templates/src/moai_adk/core/tags/__init__.py +86 -0
- moai_adk/templates/src/moai_adk/core/tags/ci_validator.py +433 -0
- moai_adk/templates/src/moai_adk/core/tags/cli.py +283 -0
- moai_adk/templates/src/moai_adk/core/tags/pre_commit_validator.py +355 -0
- moai_adk/templates/src/moai_adk/core/tags/reporter.py +957 -0
- moai_adk/templates/src/moai_adk/core/tags/validator.py +897 -0
- {moai_adk-0.8.1.dist-info → moai_adk-0.8.3.dist-info}/METADATA +240 -14
- {moai_adk-0.8.1.dist-info → moai_adk-0.8.3.dist-info}/RECORD +85 -50
- moai_adk/templates/.claude/hooks/alfred/HOOK_SCHEMA_VALIDATION.md +0 -313
- moai_adk/templates/.moai/memory/config-schema.md +0 -444
- /moai_adk/templates/.claude/hooks/alfred/{core → shared/core}/__init__.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{core → shared/core}/checkpoint.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{core → shared/core}/context.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{core → shared/core}/tags.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{handlers → shared/handlers}/__init__.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{handlers → shared/handlers}/notification.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{handlers → shared/handlers}/tool.py +0 -0
- /moai_adk/templates/.claude/hooks/alfred/{handlers → shared/handlers}/user.py +0 -0
- /moai_adk/templates/.moai/memory/{issue-label-mapping.md → ISSUE-LABEL-MAPPING.md} +0 -0
- {moai_adk-0.8.1.dist-info → moai_adk-0.8.3.dist-info}/WHEEL +0 -0
- {moai_adk-0.8.1.dist-info → moai_adk-0.8.3.dist-info}/entry_points.txt +0 -0
- {moai_adk-0.8.1.dist-info → moai_adk-0.8.3.dist-info}/licenses/LICENSE +0 -0
|
@@ -109,13 +109,59 @@ Users can run commands like this:
|
|
|
109
109
|
|
|
110
110
|
## 🔍 STEP 1: Project analysis and planning
|
|
111
111
|
|
|
112
|
-
|
|
112
|
+
STEP 1 consists of **two independent phases** to provide flexible workflow based on user request clarity:
|
|
113
113
|
|
|
114
|
-
|
|
114
|
+
### 📋 STEP 1 Workflow Overview
|
|
115
115
|
|
|
116
|
-
|
|
116
|
+
```
|
|
117
|
+
┌─────────────────────────────────────────────────────────────┐
|
|
118
|
+
│ STEP 1: Project Analysis & Planning │
|
|
119
|
+
├─────────────────────────────────────────────────────────────┤
|
|
120
|
+
│ │
|
|
121
|
+
│ Phase A (OPTIONAL) │
|
|
122
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
123
|
+
│ │ 🔍 Explore Agent │ │
|
|
124
|
+
│ │ • Find relevant files by keywords │ │
|
|
125
|
+
│ │ • Locate existing SPEC documents │ │
|
|
126
|
+
│ │ • Identify implementation patterns │ │
|
|
127
|
+
│ └─────────────────────────────────────────┘ │
|
|
128
|
+
│ ↓ │
|
|
129
|
+
│ (exploration results) │
|
|
130
|
+
│ ↓ │
|
|
131
|
+
│ Phase B (REQUIRED) │
|
|
132
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
133
|
+
│ │ ⚙️ spec-builder Agent │ │
|
|
134
|
+
│ │ • Analyze project documents │ │
|
|
135
|
+
│ │ • Propose SPEC candidates │ │
|
|
136
|
+
│ │ • Design EARS structure │ │
|
|
137
|
+
│ │ • Request user approval │ │
|
|
138
|
+
│ └─────────────────────────────────────────┘ │
|
|
139
|
+
│ ↓ │
|
|
140
|
+
│ (user approval via AskUserQuestion) │
|
|
141
|
+
│ ↓ │
|
|
142
|
+
│ PROCEED TO STEP 2 │
|
|
143
|
+
└─────────────────────────────────────────────────────────────┘
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
**Key Points**:
|
|
147
|
+
- **Phase A is optional** - Skip if user provides clear SPEC title
|
|
148
|
+
- **Phase B is required** - Always runs to analyze project and create SPEC
|
|
149
|
+
- **Results flow forward** - Exploration results (if any) are passed to spec-builder
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
### 🔍 Phase A: Codebase Exploration (OPTIONAL)
|
|
154
|
+
|
|
155
|
+
**Use the Explore agent when user request is unclear or needs context.**
|
|
156
|
+
|
|
157
|
+
#### When to use Phase A:
|
|
158
|
+
|
|
159
|
+
- ✅ User uses vague keywords ("where is...", "find me...", "related to...")
|
|
160
|
+
- ✅ Need to understand existing code structure before planning
|
|
161
|
+
- ✅ Feature spans multiple files or modules
|
|
162
|
+
- ❌ User provides clear SPEC title (skip to Phase B)
|
|
117
163
|
|
|
118
|
-
|
|
164
|
+
#### How to invoke Explore agent:
|
|
119
165
|
|
|
120
166
|
```
|
|
121
167
|
Invoking the Task tool (Explore agent):
|
|
@@ -125,18 +171,20 @@ Invoking the Task tool (Explore agent):
|
|
|
125
171
|
- File location (src/, tests/, docs/)
|
|
126
172
|
- Relevant SPEC document (.moai/specs/)
|
|
127
173
|
- Existing implementation code
|
|
128
|
-
|
|
174
|
+
thoroughness level: medium"
|
|
129
175
|
```
|
|
130
176
|
|
|
131
|
-
**
|
|
132
|
-
- ✅ Users use keywords like “where am”, “find me”, etc.
|
|
133
|
-
- ✅ Need to understand existing code structure
|
|
134
|
-
- ✅ Investigate features across multiple files
|
|
135
|
-
- ❌ Given a clear SPEC title (straight into spec-builder)
|
|
177
|
+
**Note**: If user provides clear SPEC title, skip Phase A and proceed directly to Phase B.
|
|
136
178
|
|
|
137
|
-
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
### ⚙️ Phase B: SPEC Planning (REQUIRED)
|
|
182
|
+
|
|
183
|
+
**Call the spec-builder agent to analyze project and create SPEC documents.**
|
|
138
184
|
|
|
139
|
-
**
|
|
185
|
+
This phase is **always required** regardless of whether Phase A was executed.
|
|
186
|
+
|
|
187
|
+
#### How to invoke spec-builder:
|
|
140
188
|
|
|
141
189
|
```
|
|
142
190
|
Call the Task tool:
|
|
@@ -154,6 +202,12 @@ All SPEC documents and analysis must be generated in conversation_language.
|
|
|
154
202
|
- If conversation_language is 'ja' (Japanese): Generate ALL analysis, plans, and SPEC documents in Japanese
|
|
155
203
|
- If conversation_language is other language: Follow the specified language
|
|
156
204
|
|
|
205
|
+
SKILL INVOCATION:
|
|
206
|
+
Use explicit Skill() calls when needed:
|
|
207
|
+
- Skill("moai-foundation-specs") for SPEC structure guidance
|
|
208
|
+
- Skill("moai-foundation-ears") for EARS syntax requirements
|
|
209
|
+
- Skill("moai-alfred-spec-metadata-validation") for metadata validation
|
|
210
|
+
|
|
157
211
|
TASK:
|
|
158
212
|
Please analyze the project document and suggest SPEC candidates.
|
|
159
213
|
Run in analysis mode, and must include the following:
|
|
@@ -166,6 +220,8 @@ User input: $ARGUMENTS
|
|
|
166
220
|
(Optional) Explore results: $EXPLORE_RESULTS"""
|
|
167
221
|
```
|
|
168
222
|
|
|
223
|
+
**Note**: If Phase A was executed, pass the exploration results via `$EXPLORE_RESULTS` variable.
|
|
224
|
+
|
|
169
225
|
### Plan analysis progress
|
|
170
226
|
|
|
171
227
|
1. **Project document analysis**
|
|
@@ -218,6 +274,13 @@ ALL SPEC documents MUST be generated in conversation_language:
|
|
|
218
274
|
YAML frontmatter and @TAG identifiers MUST remain in English.
|
|
219
275
|
Code examples and technical keywords can be mixed (code in English, narrative in user language).
|
|
220
276
|
|
|
277
|
+
SKILL INVOCATION:
|
|
278
|
+
Use explicit Skill() calls when needed:
|
|
279
|
+
- Skill("moai-foundation-specs") for SPEC structure guidance
|
|
280
|
+
- Skill("moai-foundation-ears") for EARS syntax requirements
|
|
281
|
+
- Skill("moai-alfred-spec-metadata-validation") for metadata validation
|
|
282
|
+
- Skill("moai-alfred-tag-scanning") for TAG chain references
|
|
283
|
+
|
|
221
284
|
TASK:
|
|
222
285
|
Please fill out the SPEC document according to the plan approved in STEP 1.
|
|
223
286
|
Create a specification for the EARS structure."""
|
|
@@ -372,7 +435,7 @@ Only if the user selects **"Proceed"** or **"Start"** will Alfred call the spec-
|
|
|
372
435
|
### State-driven Requirements
|
|
373
436
|
- When the WHILE token is in an unexpired state, the system must allow access to the protected resource.
|
|
374
437
|
|
|
375
|
-
###
|
|
438
|
+
### Unwanted Behaviors
|
|
376
439
|
- If the IF token has expired, the system must return a 401 Unauthorized response.
|
|
377
440
|
```
|
|
378
441
|
|
|
@@ -414,7 +477,7 @@ priority: high
|
|
|
414
477
|
You must include a HISTORY section **right after the YAML Front Matter**:
|
|
415
478
|
|
|
416
479
|
```markdown
|
|
417
|
-
# @SPEC:
|
|
480
|
+
# @SPEC:DOMAIN-NNN: JWT-based authentication system
|
|
418
481
|
|
|
419
482
|
## HISTORY
|
|
420
483
|
|
|
@@ -460,7 +523,7 @@ updated: 2025-09-15
|
|
|
460
523
|
author: @username
|
|
461
524
|
---
|
|
462
525
|
|
|
463
|
-
# @SPEC:
|
|
526
|
+
# @SPEC:DOMAIN-NNN: [SPEC title]
|
|
464
527
|
|
|
465
528
|
## HISTORY
|
|
466
529
|
[Change history by version – see example above]
|
|
@@ -484,11 +547,11 @@ author: @username
|
|
|
484
547
|
### Optional (Optional function)
|
|
485
548
|
- If WHERE [condition], the system can [operate]
|
|
486
549
|
|
|
487
|
-
###
|
|
488
|
-
- IF [condition], the system must
|
|
550
|
+
### Unwanted Behaviors
|
|
551
|
+
- IF [condition], the system must [respond appropriately with error handling or quality gates]
|
|
489
552
|
|
|
490
553
|
## Traceability (@TAG)
|
|
491
|
-
- **SPEC**: @SPEC:
|
|
554
|
+
- **SPEC**: @SPEC:DOMAIN-NNN
|
|
492
555
|
- **TEST**: tests/auth/test_service.py
|
|
493
556
|
- **CODE**: src/auth/service.py
|
|
494
557
|
- **DOC**: docs/api/authentication.md
|
|
@@ -630,7 +693,7 @@ done
|
|
|
630
693
|
**CodeRabbit review includes:**
|
|
631
694
|
- ✅ YAML frontmatter validation (7 required fields)
|
|
632
695
|
- ✅ HISTORY section structure and completeness
|
|
633
|
-
- ✅ EARS requirements clarity (Ubiquitous/Event/State/Optional/
|
|
696
|
+
- ✅ EARS requirements clarity (Ubiquitous/Event-driven/State-driven/Optional/Unwanted Behaviors)
|
|
634
697
|
- ✅ Acceptance criteria quality (Given-When-Then scenarios)
|
|
635
698
|
- ✅ @TAG system compliance (SPEC/TEST/CODE/DOC traceability)
|
|
636
699
|
- ✅ Documentation and formatting
|
|
@@ -96,13 +96,59 @@ Users can run commands as follows:
|
|
|
96
96
|
|
|
97
97
|
## 🔍 STEP 1: SPEC analysis and execution plan establishment
|
|
98
98
|
|
|
99
|
-
|
|
99
|
+
STEP 1 consists of **two independent phases** to provide flexible workflow based on task complexity:
|
|
100
100
|
|
|
101
|
-
|
|
101
|
+
### 📋 STEP 1 Workflow Overview
|
|
102
102
|
|
|
103
|
-
|
|
103
|
+
```
|
|
104
|
+
┌─────────────────────────────────────────────────────────────┐
|
|
105
|
+
│ STEP 1: SPEC Analysis & Planning │
|
|
106
|
+
├─────────────────────────────────────────────────────────────┤
|
|
107
|
+
│ │
|
|
108
|
+
│ Phase A (OPTIONAL) │
|
|
109
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
110
|
+
│ │ 🔍 Explore Agent │ │
|
|
111
|
+
│ │ • Browse existing codebase │ │
|
|
112
|
+
│ │ • Find similar implementations │ │
|
|
113
|
+
│ │ • Identify patterns & architecture │ │
|
|
114
|
+
│ └─────────────────────────────────────────┘ │
|
|
115
|
+
│ ↓ │
|
|
116
|
+
│ (exploration results) │
|
|
117
|
+
│ ↓ │
|
|
118
|
+
│ Phase B (REQUIRED) │
|
|
119
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
120
|
+
│ │ ⚙️ implementation-planner Agent │ │
|
|
121
|
+
│ │ • Analyze SPEC requirements │ │
|
|
122
|
+
│ │ • Design execution strategy │ │
|
|
123
|
+
│ │ • Create implementation plan │ │
|
|
124
|
+
│ │ • Request user approval │ │
|
|
125
|
+
│ └─────────────────────────────────────────┘ │
|
|
126
|
+
│ ↓ │
|
|
127
|
+
│ (user approval via AskUserQuestion) │
|
|
128
|
+
│ ↓ │
|
|
129
|
+
│ PROCEED TO STEP 2 │
|
|
130
|
+
└─────────────────────────────────────────────────────────────┘
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
**Key Points**:
|
|
134
|
+
- **Phase A is optional** - Skip if you don't need to explore existing code
|
|
135
|
+
- **Phase B is required** - Always runs to analyze SPEC and create execution plan
|
|
136
|
+
- **Results flow forward** - Exploration results (if any) are passed to implementation-planner
|
|
137
|
+
|
|
138
|
+
---
|
|
139
|
+
|
|
140
|
+
### 🔍 Phase A: Codebase Exploration (OPTIONAL)
|
|
141
|
+
|
|
142
|
+
**Use the Explore agent when you need to understand existing code before planning.**
|
|
143
|
+
|
|
144
|
+
#### When to use Phase A:
|
|
104
145
|
|
|
105
|
-
|
|
146
|
+
- ✅ Need to understand existing code structure/patterns
|
|
147
|
+
- ✅ Need to find similar function implementations for reference
|
|
148
|
+
- ✅ Need to understand project architectural rules
|
|
149
|
+
- ✅ Need to check libraries and versions being used
|
|
150
|
+
|
|
151
|
+
#### How to invoke Explore agent:
|
|
106
152
|
|
|
107
153
|
```
|
|
108
154
|
Invoking the Task tool (Explore agent):
|
|
@@ -112,35 +158,39 @@ Invoking the Task tool (Explore agent):
|
|
|
112
158
|
- Similar function implementation code (src/)
|
|
113
159
|
- Test patterns for reference (tests/)
|
|
114
160
|
- Architectural patterns and design patterns
|
|
115
|
-
-
|
|
161
|
+
- Current libraries and versions (package.json, requirements.txt)
|
|
116
162
|
thoroughness level: medium"
|
|
117
163
|
```
|
|
118
164
|
|
|
119
|
-
**
|
|
120
|
-
- ✅ When you need to understand the existing code structure/pattern
|
|
121
|
-
- ✅ When you need to refer to how a similar function is implemented
|
|
122
|
-
- ✅ When you need to understand the architectural rules of the project
|
|
123
|
-
- ✅ Check the library and version being used
|
|
165
|
+
**Note**: If you skip Phase A, proceed directly to Phase B.
|
|
124
166
|
|
|
125
|
-
|
|
167
|
+
---
|
|
168
|
+
|
|
169
|
+
### ⚙️ Phase B: Execution Planning (REQUIRED)
|
|
126
170
|
|
|
127
|
-
**
|
|
171
|
+
**Call the implementation-planner agent to analyze SPEC and establish execution strategy.**
|
|
172
|
+
|
|
173
|
+
This phase is **always required** regardless of whether Phase A was executed.
|
|
174
|
+
|
|
175
|
+
#### How to invoke implementation-planner:
|
|
128
176
|
|
|
129
177
|
```
|
|
130
|
-
Task tool call
|
|
178
|
+
Task tool call:
|
|
131
179
|
- subagent_type: "implementation-planner"
|
|
132
180
|
- description: "SPEC analysis and establishment of execution strategy"
|
|
133
181
|
- prompt: "Please analyze the SPEC of $ARGUMENTS and establish an execution plan.
|
|
134
182
|
It must include the following:
|
|
135
183
|
1. SPEC requirements extraction and complexity assessment
|
|
136
184
|
2. Library and tool selection (using WebFetch)
|
|
137
|
-
|
|
185
|
+
3. TAG chain design
|
|
138
186
|
4. Step-by-step execution plan
|
|
139
187
|
5. Risks and response plans
|
|
140
|
-
6. Create action plan and use `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)` to confirm the next action with the user
|
|
188
|
+
6. Create action plan and use `AskUserQuestion tool (documented in moai-alfred-interactive-questions skill)` to confirm the next action with the user
|
|
141
189
|
(Optional) Explore results: $EXPLORE_RESULTS"
|
|
142
190
|
```
|
|
143
191
|
|
|
192
|
+
**Note**: If Phase A was executed, pass the exploration results via `$EXPLORE_RESULTS` variable.
|
|
193
|
+
|
|
144
194
|
### SPEC analysis in progress
|
|
145
195
|
|
|
146
196
|
1. **SPEC document analysis**
|
|
@@ -202,6 +252,13 @@ Code and technical output MUST be in English.
|
|
|
202
252
|
Code comments MAY be in {{CONVERSATION_LANGUAGE}} if appropriate.
|
|
203
253
|
Test descriptions and documentation can use {{CONVERSATION_LANGUAGE}}.
|
|
204
254
|
|
|
255
|
+
SKILL INVOCATION:
|
|
256
|
+
Use explicit Skill() calls when needed:
|
|
257
|
+
- Skill("moai-alfred-language-detection") for project language detection
|
|
258
|
+
- Skill("moai-lang-python") or language-specific Skills for best practices
|
|
259
|
+
- Skill("moai-essentials-debug") when tests fail
|
|
260
|
+
- Skill("moai-essentials-refactor") during REFACTOR phase
|
|
261
|
+
|
|
205
262
|
TASK: Execute the task according to the plan approved in STEP 1.
|
|
206
263
|
|
|
207
264
|
For TDD scenario:
|
|
@@ -102,15 +102,60 @@ Users can run the command as follows:
|
|
|
102
102
|
|
|
103
103
|
## 🔍 STEP 1: Analyze synchronization scope and establish plan
|
|
104
104
|
|
|
105
|
-
|
|
105
|
+
STEP 1 consists of **two independent phases** to provide flexible workflow based on project complexity:
|
|
106
106
|
|
|
107
|
-
|
|
107
|
+
### 📋 STEP 1 Workflow Overview
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
```
|
|
110
|
+
┌─────────────────────────────────────────────────────────────┐
|
|
111
|
+
│ STEP 1: Synchronization Analysis & Planning │
|
|
112
|
+
├─────────────────────────────────────────────────────────────┤
|
|
113
|
+
│ │
|
|
114
|
+
│ Phase A (OPTIONAL) │
|
|
115
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
116
|
+
│ │ 🔍 Explore Agent │ │
|
|
117
|
+
│ │ • Navigate complex TAG chains │ │
|
|
118
|
+
│ │ • Scan entire TAG system │ │
|
|
119
|
+
│ │ • Identify orphan TAGs │ │
|
|
120
|
+
│ └─────────────────────────────────────────┘ │
|
|
121
|
+
│ ↓ │
|
|
122
|
+
│ (exploration results) │
|
|
123
|
+
│ ↓ │
|
|
124
|
+
│ Phase B (REQUIRED) │
|
|
125
|
+
│ ┌─────────────────────────────────────────┐ │
|
|
126
|
+
│ │ ⚙️ tag-agent + doc-syncer Agents │ │
|
|
127
|
+
│ │ • Verify TAG integrity (full project) │ │
|
|
128
|
+
│ │ • Analyze Git changes │ │
|
|
129
|
+
│ │ • Create synchronization plan │ │
|
|
130
|
+
│ │ • Request user approval │ │
|
|
131
|
+
│ └─────────────────────────────────────────┘ │
|
|
132
|
+
│ ↓ │
|
|
133
|
+
│ (user approval via AskUserQuestion) │
|
|
134
|
+
│ ↓ │
|
|
135
|
+
│ PROCEED TO STEP 2 │
|
|
136
|
+
└─────────────────────────────────────────────────────────────┘
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
**Key Points**:
|
|
140
|
+
- **Phase A is optional** - Skip for simple single-SPEC changes
|
|
141
|
+
- **Phase B is required** - Always runs to verify TAGs and plan sync
|
|
142
|
+
- **Results flow forward** - Exploration results (if any) are passed to tag-agent
|
|
143
|
+
- **⚠️ Important**: tag-agent verifies ENTIRE PROJECT, not just changed files
|
|
144
|
+
|
|
145
|
+
---
|
|
110
146
|
|
|
111
|
-
### 🔍 TAG
|
|
147
|
+
### 🔍 Phase A: TAG Chain Navigation (OPTIONAL)
|
|
148
|
+
|
|
149
|
+
**Use the Explore agent for complex or extensive TAG chains.**
|
|
150
|
+
|
|
151
|
+
#### When to use Phase A:
|
|
152
|
+
|
|
153
|
+
- ✅ Large projects (100+ files)
|
|
154
|
+
- ✅ Need comprehensive TAG chain integrity verification
|
|
155
|
+
- ✅ Changes span multiple SPECs or modules
|
|
156
|
+
- ❌ Simple changes to a single SPEC (skip to Phase B)
|
|
112
157
|
|
|
113
|
-
|
|
158
|
+
#### How to invoke Explore agent:
|
|
114
159
|
|
|
115
160
|
```
|
|
116
161
|
Invoking the Task tool (Explore agent):
|
|
@@ -120,20 +165,22 @@ Invoking the Task tool (Explore agent):
|
|
|
120
165
|
- @SPEC TAG location (.moai/specs/)
|
|
121
166
|
- @TEST TAG location (tests/)
|
|
122
167
|
- @CODE TAG location (src/)
|
|
123
|
-
|
|
168
|
+
- @DOC TAG location (docs/)
|
|
124
169
|
- Detect orphan TAGs and broken references
|
|
125
|
-
|
|
170
|
+
thoroughness level: very thorough"
|
|
126
171
|
```
|
|
127
172
|
|
|
128
|
-
**
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
173
|
+
**Note**: For simple changes, skip Phase A and proceed directly to Phase B.
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
### ⚙️ Phase B: TAG Verification & Sync Planning (REQUIRED)
|
|
178
|
+
|
|
179
|
+
**Call tag-agent and doc-syncer to verify TAG integrity and plan synchronization.**
|
|
133
180
|
|
|
134
|
-
|
|
181
|
+
This phase is **always required** and runs **two agents sequentially**:
|
|
135
182
|
|
|
136
|
-
|
|
183
|
+
#### How to invoke agents:
|
|
137
184
|
|
|
138
185
|
```
|
|
139
186
|
1. Tag-agent call (TAG verification - FULL PROJECT SCOPE):
|
|
@@ -175,6 +222,12 @@ Documentation updates MUST respect conversation_language:
|
|
|
175
222
|
- Code comments: {{CONVERSATION_LANGUAGE}} (when not technical keywords)
|
|
176
223
|
- Technical documentation and YAML frontmatter: English
|
|
177
224
|
|
|
225
|
+
SKILL INVOCATION:
|
|
226
|
+
Use explicit Skill() calls when needed:
|
|
227
|
+
- Skill("moai-foundation-tags") for TAG chain validation
|
|
228
|
+
- Skill("moai-foundation-trust") for quality gate checks
|
|
229
|
+
- Skill("moai-alfred-tag-scanning") for TAG inventory updates
|
|
230
|
+
|
|
178
231
|
TASK:
|
|
179
232
|
Please analyze Git changes and establish a document synchronization plan.
|
|
180
233
|
Ensure all documentation updates align with the conversation_language setting.
|
|
@@ -183,6 +236,13 @@ $ARGUMENTS
|
|
|
183
236
|
(Optional) TAG validation results: $TAG_VALIDATION_RESULTS"""
|
|
184
237
|
```
|
|
185
238
|
|
|
239
|
+
**Note**:
|
|
240
|
+
- **Sequential execution**: Run tag-agent first, then doc-syncer
|
|
241
|
+
- **Results flow**: TAG validation results from tag-agent are passed to doc-syncer via `$TAG_VALIDATION_RESULTS`
|
|
242
|
+
- **Phase A results**: If Phase A was executed, exploration results are passed to tag-agent via `$EXPLORE_RESULTS`
|
|
243
|
+
|
|
244
|
+
---
|
|
245
|
+
|
|
186
246
|
### Synchronization analysis in progress
|
|
187
247
|
|
|
188
248
|
1. **Check project status**
|