moai-adk 0.9.0__py3-none-any.whl β†’ 0.15.1__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.

Files changed (186) hide show
  1. moai_adk/cli/commands/init.py +14 -2
  2. moai_adk/cli/commands/update.py +214 -56
  3. moai_adk/core/issue_creator.py +2 -2
  4. moai_adk/core/project/detector.py +201 -12
  5. moai_adk/core/project/initializer.py +62 -1
  6. moai_adk/core/project/phase_executor.py +48 -6
  7. moai_adk/core/tags/ci_validator.py +34 -4
  8. moai_adk/core/tags/pre_commit_validator.py +40 -2
  9. moai_adk/core/tags/reporter.py +2 -3
  10. moai_adk/core/tags/validator.py +1 -1
  11. moai_adk/core/template_engine.py +20 -5
  12. moai_adk/templates/.claude/agents/alfred/backend-expert.md +319 -0
  13. moai_adk/templates/.claude/agents/alfred/devops-expert.md +464 -0
  14. moai_adk/templates/.claude/agents/alfred/doc-syncer.md +1 -1
  15. moai_adk/templates/.claude/agents/alfred/frontend-expert.md +357 -0
  16. moai_adk/templates/.claude/agents/alfred/git-manager.md +2 -2
  17. moai_adk/templates/.claude/agents/alfred/implementation-planner.md +76 -3
  18. moai_adk/templates/.claude/agents/alfred/project-manager.md +49 -10
  19. moai_adk/templates/.claude/agents/alfred/quality-gate.md +3 -3
  20. moai_adk/templates/.claude/agents/alfred/spec-builder.md +180 -41
  21. moai_adk/templates/.claude/agents/alfred/tag-agent.md +74 -0
  22. moai_adk/templates/.claude/agents/alfred/tdd-implementer.md +107 -5
  23. moai_adk/templates/.claude/agents/alfred/trust-checker.md +2 -2
  24. moai_adk/templates/.claude/agents/alfred/ui-ux-expert.md +571 -0
  25. moai_adk/templates/.claude/commands/alfred/0-project.md +928 -263
  26. moai_adk/templates/.claude/commands/alfred/1-plan.md +220 -68
  27. moai_adk/templates/.claude/commands/alfred/2-run.md +299 -51
  28. moai_adk/templates/.claude/commands/alfred/3-sync.md +452 -51
  29. moai_adk/templates/.claude/commands/alfred/9-feedback.md +1 -1
  30. moai_adk/templates/.claude/hooks/alfred/core/project.py +25 -27
  31. moai_adk/templates/.claude/hooks/alfred/core/timeout.py +136 -0
  32. moai_adk/templates/.claude/hooks/alfred/core/ttl_cache.py +108 -0
  33. moai_adk/templates/.claude/hooks/alfred/core/version_cache.py +4 -4
  34. moai_adk/templates/.claude/hooks/alfred/handlers/__init__.py +29 -0
  35. moai_adk/templates/.claude/hooks/alfred/post_tool__log_changes.py +11 -19
  36. moai_adk/templates/.claude/hooks/alfred/pre_tool__auto_checkpoint.py +11 -19
  37. moai_adk/templates/.claude/hooks/alfred/session_end__cleanup.py +11 -19
  38. moai_adk/templates/.claude/hooks/alfred/session_start__show_project_info.py +10 -18
  39. moai_adk/templates/.claude/hooks/alfred/shared/core/__init__.py +2 -2
  40. moai_adk/templates/.claude/hooks/alfred/shared/core/checkpoint.py +3 -3
  41. moai_adk/templates/.claude/hooks/alfred/shared/core/context.py +5 -5
  42. moai_adk/templates/.claude/hooks/alfred/shared/core/project.py +40 -41
  43. moai_adk/templates/.claude/hooks/alfred/shared/core/tags.py +55 -23
  44. moai_adk/templates/.claude/hooks/alfred/shared/core/version_cache.py +4 -4
  45. moai_adk/templates/.claude/hooks/alfred/shared/handlers/notification.py +132 -3
  46. moai_adk/templates/.claude/hooks/alfred/shared/handlers/session.py +9 -10
  47. moai_adk/templates/.claude/hooks/alfred/shared/handlers/tool.py +3 -6
  48. moai_adk/templates/.claude/hooks/alfred/shared/handlers/user.py +19 -0
  49. moai_adk/templates/.claude/hooks/alfred/user_prompt__jit_load_docs.py +14 -22
  50. moai_adk/templates/.claude/hooks/alfred/utils/__init__.py +1 -0
  51. moai_adk/templates/.claude/hooks/alfred/utils/timeout.py +161 -0
  52. moai_adk/templates/.claude/settings.json +5 -5
  53. moai_adk/templates/.claude/skills/moai-alfred-agent-guide/SKILL.md +70 -0
  54. moai_adk/templates/.claude/skills/moai-alfred-agent-guide/examples.md +62 -0
  55. moai_adk/templates/{.moai/memory/CLAUDE-AGENTS-GUIDE.md β†’ .claude/skills/moai-alfred-agent-guide/reference.md} +34 -0
  56. moai_adk/templates/.claude/skills/moai-alfred-config-schema/SKILL.md +56 -0
  57. moai_adk/templates/.claude/skills/moai-alfred-config-schema/examples.md +28 -0
  58. moai_adk/templates/.claude/skills/moai-alfred-config-schema/reference.md +444 -0
  59. moai_adk/templates/.claude/skills/moai-alfred-context-budget/SKILL.md +62 -0
  60. moai_adk/templates/.claude/skills/moai-alfred-context-budget/examples.md +28 -0
  61. moai_adk/templates/.claude/skills/moai-alfred-context-budget/reference.md +405 -0
  62. moai_adk/templates/.claude/skills/moai-alfred-dev-guide/SKILL.md +51 -0
  63. moai_adk/templates/.claude/skills/moai-alfred-dev-guide/examples.md +355 -0
  64. moai_adk/templates/.claude/skills/moai-alfred-dev-guide/reference.md +239 -0
  65. moai_adk/templates/.claude/skills/moai-alfred-expertise-detection/SKILL.md +323 -0
  66. moai_adk/templates/.claude/skills/moai-alfred-expertise-detection/examples.md +286 -0
  67. moai_adk/templates/.claude/skills/moai-alfred-expertise-detection/reference.md +126 -0
  68. moai_adk/templates/.claude/skills/moai-alfred-gitflow-policy/SKILL.md +74 -0
  69. moai_adk/templates/.claude/skills/moai-alfred-gitflow-policy/examples.md +4 -0
  70. moai_adk/templates/.claude/skills/moai-alfred-gitflow-policy/reference.md +269 -0
  71. moai_adk/templates/.claude/skills/moai-alfred-issue-labels/SKILL.md +19 -0
  72. moai_adk/templates/.claude/skills/moai-alfred-issue-labels/examples.md +4 -0
  73. moai_adk/templates/.claude/skills/moai-alfred-persona-roles/SKILL.md +198 -0
  74. moai_adk/templates/.claude/skills/moai-alfred-persona-roles/examples.md +431 -0
  75. moai_adk/templates/.claude/skills/moai-alfred-persona-roles/reference.md +141 -0
  76. moai_adk/templates/.claude/skills/moai-alfred-practices/SKILL.md +89 -0
  77. moai_adk/templates/.claude/skills/moai-alfred-practices/examples.md +122 -0
  78. moai_adk/templates/.claude/skills/moai-alfred-proactive-suggestions/SKILL.md +508 -0
  79. moai_adk/templates/.claude/skills/moai-alfred-proactive-suggestions/examples.md +481 -0
  80. moai_adk/templates/.claude/skills/moai-alfred-proactive-suggestions/reference.md +100 -0
  81. moai_adk/templates/.claude/skills/moai-alfred-reporting/SKILL.md +273 -0
  82. moai_adk/templates/.claude/skills/moai-alfred-rules/SKILL.md +77 -0
  83. moai_adk/templates/.claude/skills/moai-alfred-rules/examples.md +265 -0
  84. moai_adk/templates/.claude/skills/moai-alfred-session-state/SKILL.md +19 -0
  85. moai_adk/templates/.claude/skills/moai-alfred-session-state/examples.md +4 -0
  86. moai_adk/templates/.claude/skills/moai-alfred-session-state/reference.md +84 -0
  87. moai_adk/templates/.claude/skills/{moai-spec-authoring β†’ moai-alfred-spec-authoring}/SKILL.md +5 -5
  88. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-extended/SKILL.md +115 -0
  89. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-extended/examples.md +4 -0
  90. moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-extended/reference.md +348 -0
  91. moai_adk/templates/.claude/skills/moai-alfred-todowrite-pattern/SKILL.md +19 -0
  92. moai_adk/templates/.claude/skills/moai-alfred-todowrite-pattern/examples.md +4 -0
  93. moai_adk/templates/.claude/skills/moai-alfred-todowrite-pattern/reference.md +211 -0
  94. moai_adk/templates/.claude/skills/moai-alfred-workflow/SKILL.md +288 -0
  95. moai_adk/templates/.claude/skills/moai-cc-skill-descriptions/SKILL.md +19 -0
  96. moai_adk/templates/.claude/skills/moai-cc-skill-descriptions/examples.md +4 -0
  97. moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/SKILL.md +3 -3
  98. moai_adk/templates/.claude/skills/moai-design-systems/SKILL.md +802 -0
  99. moai_adk/templates/.claude/skills/moai-design-systems/examples.md +1238 -0
  100. moai_adk/templates/.claude/skills/moai-design-systems/reference.md +673 -0
  101. moai_adk/templates/.claude/skills/moai-domain-frontend/SKILL.md +17 -13
  102. moai_adk/templates/.claude/skills/moai-lang-go/SKILL.md +15 -12
  103. moai_adk/templates/.claude/skills/moai-lang-java/SKILL.md +14 -12
  104. moai_adk/templates/.claude/skills/moai-lang-php/SKILL.md +14 -11
  105. moai_adk/templates/.claude/skills/moai-lang-python/SKILL.md +10 -8
  106. moai_adk/templates/.claude/skills/moai-lang-rust/SKILL.md +15 -12
  107. moai_adk/templates/.claude/skills/moai-lang-scala/SKILL.md +13 -11
  108. moai_adk/templates/.claude/skills/moai-lang-typescript/SKILL.md +16 -10
  109. moai_adk/templates/.claude/skills/moai-project-documentation.md +622 -0
  110. moai_adk/templates/.git-hooks/pre-push +143 -0
  111. moai_adk/templates/.github/workflows/c-tag-validation.yml +11 -0
  112. moai_adk/templates/.github/workflows/cpp-tag-validation.yml +11 -0
  113. moai_adk/templates/.github/workflows/csharp-tag-validation.yml +11 -0
  114. moai_adk/templates/.github/workflows/dart-tag-validation.yml +11 -0
  115. moai_adk/templates/.github/workflows/go-tag-validation.yml +130 -0
  116. moai_adk/templates/.github/workflows/java-tag-validation.yml +11 -0
  117. moai_adk/templates/.github/workflows/javascript-tag-validation.yml +135 -0
  118. moai_adk/templates/.github/workflows/kotlin-tag-validation.yml +11 -0
  119. moai_adk/templates/.github/workflows/moai-gitflow.yml +182 -25
  120. moai_adk/templates/.github/workflows/moai-release-pipeline.yml +35 -29
  121. moai_adk/templates/.github/workflows/php-tag-validation.yml +11 -0
  122. moai_adk/templates/.github/workflows/python-tag-validation.yml +118 -0
  123. moai_adk/templates/.github/workflows/release.yml +76 -7
  124. moai_adk/templates/.github/workflows/ruby-tag-validation.yml +11 -0
  125. moai_adk/templates/.github/workflows/rust-tag-validation.yml +11 -0
  126. moai_adk/templates/.github/workflows/shell-tag-validation.yml +11 -0
  127. moai_adk/templates/.github/workflows/spec-issue-sync.yml +208 -41
  128. moai_adk/templates/.github/workflows/swift-tag-validation.yml +11 -0
  129. moai_adk/templates/.github/workflows/tag-report.yml +269 -0
  130. moai_adk/templates/.github/workflows/tag-validation.yml +186 -0
  131. moai_adk/templates/.github/workflows/typescript-tag-validation.yml +154 -0
  132. moai_adk/templates/.moai/config.json +3 -1
  133. moai_adk/templates/CLAUDE.md +940 -45
  134. moai_adk/templates/workflows/go-tag-validation.yml +30 -0
  135. moai_adk/templates/workflows/javascript-tag-validation.yml +41 -0
  136. moai_adk/templates/workflows/python-tag-validation.yml +42 -0
  137. moai_adk/templates/workflows/typescript-tag-validation.yml +31 -0
  138. moai_adk/utils/banner.py +5 -5
  139. {moai_adk-0.9.0.dist-info β†’ moai_adk-0.15.1.dist-info}/METADATA +1253 -527
  140. {moai_adk-0.9.0.dist-info β†’ moai_adk-0.15.1.dist-info}/RECORD +169 -109
  141. moai_adk/templates/.claude/hooks/alfred/alfred_hooks.py +0 -209
  142. moai_adk/templates/.claude/hooks/alfred/notification__handle_events.py +0 -102
  143. moai_adk/templates/.claude/hooks/alfred/stop__handle_interrupt.py +0 -102
  144. moai_adk/templates/.claude/hooks/alfred/subagent_stop__handle_subagent_end.py +0 -102
  145. moai_adk/templates/.claude/output-styles/alfred/agentic-coding.md +0 -640
  146. moai_adk/templates/.claude/output-styles/alfred/moai-adk-learning.md +0 -696
  147. moai_adk/templates/.claude/output-styles/alfred/study-with-alfred.md +0 -474
  148. moai_adk/templates/.github/ISSUE_TEMPLATE/spec.yml +0 -176
  149. moai_adk/templates/.github/PULL_REQUEST_TEMPLATE.md +0 -69
  150. moai_adk/templates/.moai/memory/DEVELOPMENT-GUIDE.md +0 -344
  151. moai_adk/templates/.moai/memory/SPEC-METADATA.md +0 -356
  152. moai_adk/templates/.moai/memory/gitflow-protection-policy.md +0 -330
  153. moai_adk/templates/.moai/project/product.md +0 -161
  154. moai_adk/templates/.moai/project/structure.md +0 -156
  155. moai_adk/templates/.moai/project/tech.md +0 -227
  156. moai_adk/templates/README.md +0 -256
  157. moai_adk/templates/__init__.py +0 -2
  158. /moai_adk/templates/{.moai/memory/ISSUE-LABEL-MAPPING.md β†’ .claude/skills/moai-alfred-issue-labels/reference.md} +0 -0
  159. /moai_adk/templates/{.moai/memory/CLAUDE-PRACTICES.md β†’ .claude/skills/moai-alfred-practices/reference.md} +0 -0
  160. /moai_adk/templates/{.moai/memory/CLAUDE-RULES.md β†’ .claude/skills/moai-alfred-rules/reference.md} +0 -0
  161. /moai_adk/templates/.claude/skills/{moai-spec-authoring β†’ moai-alfred-spec-authoring}/README.md +0 -0
  162. /moai_adk/templates/.claude/skills/{moai-spec-authoring β†’ moai-alfred-spec-authoring}/examples/validate-spec.sh +0 -0
  163. /moai_adk/templates/.claude/skills/{moai-spec-authoring β†’ moai-alfred-spec-authoring}/examples.md +0 -0
  164. /moai_adk/templates/.claude/skills/{moai-spec-authoring β†’ moai-alfred-spec-authoring}/reference.md +0 -0
  165. /moai_adk/templates/{.moai/memory/SKILLS-DESCRIPTION-POLICY.md β†’ .claude/skills/moai-cc-skill-descriptions/reference.md} +0 -0
  166. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/CHECKLIST.md +0 -0
  167. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/EXAMPLES.md +0 -0
  168. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/INTERACTIVE-DISCOVERY.md +0 -0
  169. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/METADATA.md +0 -0
  170. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/PARALLEL-ANALYSIS-REPORT.md +0 -0
  171. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/PYTHON-VERSION-MATRIX.md +0 -0
  172. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/SKILL-FACTORY-WORKFLOW.md +0 -0
  173. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/SKILL-UPDATE-ADVISOR.md +0 -0
  174. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/STEP-BY-STEP-GUIDE.md +0 -0
  175. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/STRUCTURE.md +0 -0
  176. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/WEB-RESEARCH.md +0 -0
  177. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/reference.md +0 -0
  178. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/scripts/generate-structure.sh +0 -0
  179. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/scripts/validate-skill.sh +0 -0
  180. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/templates/SKILL_TEMPLATE.md +0 -0
  181. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/templates/examples-template.md +0 -0
  182. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/templates/reference-template.md +0 -0
  183. /moai_adk/templates/.claude/skills/{moai-skill-factory β†’ moai-cc-skill-factory}/templates/scripts-template.sh +0 -0
  184. {moai_adk-0.9.0.dist-info β†’ moai_adk-0.15.1.dist-info}/WHEEL +0 -0
  185. {moai_adk-0.9.0.dist-info β†’ moai_adk-0.15.1.dist-info}/entry_points.txt +0 -0
  186. {moai_adk-0.9.0.dist-info β†’ moai_adk-0.15.1.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,62 @@
1
+ # Agent Selection Examples
2
+
3
+ ## Example 1: New Feature Request
4
+
5
+ **User**: "Add two-factor authentication"
6
+
7
+ **Decision Tree**:
8
+ ```
9
+ Task = Feature Implementation
10
+ ↓
11
+ Create SPEC first? β†’ YES
12
+ Invoke: spec-builder
13
+ ↓
14
+ Write Tests? β†’ YES
15
+ Invoke: tdd-implementer
16
+ ↓
17
+ Need Code Review? β†’ YES
18
+ Invoke: quality-gate + Skill("moai-foundation-trust")
19
+ ↓
20
+ Update Documentation? β†’ YES
21
+ Invoke: doc-syncer
22
+ ```
23
+
24
+ **Result**: Proper agent sequence avoids rework
25
+
26
+ ---
27
+
28
+ ## Example 2: Bug Fix Triage
29
+
30
+ **Error**: "TypeError: undefined is not a function"
31
+
32
+ **Agent Sequence**:
33
+ 1. Invoke: debug-helper
34
+ - Analyze stack trace
35
+ - Identify root cause
36
+ 2. Invoke: tdd-implementer
37
+ - Write regression test
38
+ - Fix implementation
39
+ 3. Invoke: git-manager
40
+ - Commit with @TAG
41
+
42
+ ---
43
+
44
+ ## Example 3: Large Codebase Exploration
45
+
46
+ **Task**: "How is authentication implemented?"
47
+
48
+ βœ… Correct:
49
+ ```
50
+ Invoke: Explore(prompt="Find auth flow, entry points, models")
51
+ Result: Clear architecture map
52
+ ```
53
+
54
+ ❌ Wrong:
55
+ ```
56
+ Manual grep for 20+ files
57
+ Result: Bloated context, still confused
58
+ ```
59
+
60
+ ---
61
+
62
+ Learn more in `reference.md` for complete decision tree and multi-agent patterns.
@@ -68,6 +68,40 @@ The **code-builder pipeline** runs two Sonnet specialists in sequence: **impleme
68
68
 
69
69
  ---
70
70
 
71
+ ## Expert Agents (Proactively Triggered by SPEC Keywords)
72
+
73
+ | Expert Agent | Model | Specialty | Trigger Keywords | Trigger Source |
74
+ | ----------------------- | ------ | ----------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | ------------------- |
75
+ | **backend-expert** πŸ”§ | Sonnet | Backend architecture, API design, database schema, microservices, authentication | 'backend', 'api', 'server', 'database', 'microservice', 'deployment', 'authentication' | implementation-planner |
76
+ | **frontend-expert** πŸ’» | Sonnet | Frontend architecture, component design, state management, UI/UX implementation | 'frontend', 'ui', 'page', 'component', 'client-side', 'browser', 'web interface' | implementation-planner |
77
+ | **devops-expert** πŸš€ | Sonnet | DevOps strategy, deployment automation, containerization, CI/CD, cloud infrastructure | 'deployment', 'docker', 'kubernetes', 'ci/cd', 'pipeline', 'infrastructure', 'railway', 'vercel', 'aws' | implementation-planner |
78
+ | **ui-ux-expert** 🎨 | Sonnet | UI/UX design, accessibility (WCAG 2.1 AA/AAA), design systems, Figma MCP, design-to-code | 'design', 'ux', 'ui', 'accessibility', 'a11y', 'user experience', 'wireframe', 'prototype', 'design system', 'figma', 'user research', 'persona', 'journey map' | implementation-planner |
79
+
80
+ ### How Expert Agents Work
81
+
82
+ 1. **Automatic Keyword Detection**: When `implementation-planner` analyzes a SPEC, it scans for expert trigger keywords
83
+ 2. **Proactive Delegation**: If keywords match, `implementation-planner` automatically invokes the relevant expert agent(s)
84
+ 3. **Expert Consultation**: Each expert provides domain-specific architecture guidance, technology recommendations, and risk analysis
85
+ 4. **Integration**: Expert feedback is integrated into the implementation plan and tagged with `@EXPERT:DOMAIN` for traceability
86
+
87
+ ### Example: Full-Stack Authentication SPEC
88
+
89
+ ```
90
+ SPEC Keywords: 'api', 'authentication', 'design', 'accessibility'
91
+
92
+ β†’ Trigger backend-expert (for API & auth architecture)
93
+ β†’ Trigger ui-ux-expert (for login UI & accessibility)
94
+
95
+ Result:
96
+ @SPEC:AUTH-001 | @EXPERT:BACKEND | @EXPERT:UIUX
97
+
98
+ Implementation Plan includes:
99
+ - Backend: JWT token strategy, rate limiting, audit logging
100
+ - UI/UX: Accessible login form (WCAG 2.1 AA), error messaging
101
+ ```
102
+
103
+ ---
104
+
71
105
  ## Zero-project Specialists
72
106
 
73
107
  | Sub-agent | Model | Focus | Trigger |
@@ -0,0 +1,56 @@
1
+ ---
2
+ name: moai-alfred-config-schema
3
+ description: ".moai/config.json official schema documentation, structure validation, project metadata, language settings, and configuration migration guide. Use when setting up project configuration or understanding config.json structure."
4
+ allowed-tools: "Read, Grep"
5
+ ---
6
+
7
+ ## What It Does
8
+
9
+ `.moai/config.json` 파일의 곡식 μŠ€ν‚€λ§ˆμ™€ 각 ν•„λ“œμ˜ λͺ©μ , μœ νš¨ν•œ κ°’, λ§ˆμ΄κ·Έλ ˆμ΄μ…˜ κ·œμΉ™μ„ μ •μ˜ν•©λ‹ˆλ‹€.
10
+
11
+ ## When to Use
12
+
13
+ - βœ… Project μ΄ˆκΈ°ν™” ν›„ config.json μ„€μ •
14
+ - βœ… config.json μŠ€ν‚€λ§ˆ 이해
15
+ - βœ… Language settings, git strategy, TAG configuration λ³€κ²½
16
+ - βœ… Legacy config λ§ˆμ΄κ·Έλ ˆμ΄μ…˜
17
+
18
+ ## Schema Overview
19
+
20
+ ```json
21
+ {
22
+ "version": "0.7.0",
23
+ "project": {
24
+ "name": "ProjectName",
25
+ "codebase_language": "python",
26
+ "conversation_language": "ko",
27
+ "conversation_language_name": "Korean"
28
+ },
29
+ "language": {
30
+ "conversation_language": "ko",
31
+ "conversation_language_name": "Korean"
32
+ },
33
+ "git": {
34
+ "strategy": "github-pr",
35
+ "main_branch": "main",
36
+ "protected": true
37
+ },
38
+ "tag": {
39
+ "prefix_style": "DOMAIN-###"
40
+ }
41
+ }
42
+ ```
43
+
44
+ ## Top-Level Sections
45
+
46
+ - **version**: Configuration version (do not edit)
47
+ - **project**: Name, codebase language, conversation language
48
+ - **language**: Multi-language support settings
49
+ - **git**: GitHub workflow strategy
50
+ - **tag**: TAG system configuration
51
+
52
+ ---
53
+
54
+ Learn more in `reference.md` for complete schema reference, validation rules, and migration examples.
55
+
56
+ **Related Skills**: moai-alfred-dev-guide, moai-foundation-specs
@@ -0,0 +1,28 @@
1
+ # Config.json Examples
2
+
3
+ ## Example: Korean Project Setup
4
+
5
+ ```json
6
+ {
7
+ "version": "0.7.0",
8
+ "project": {
9
+ "name": "MyKoreanProject",
10
+ "codebase_language": "python",
11
+ "conversation_language": "ko",
12
+ "conversation_language_name": "Korean"
13
+ },
14
+ "language": {
15
+ "conversation_language": "ko",
16
+ "conversation_language_name": "Korean"
17
+ },
18
+ "git": {
19
+ "strategy": "github-pr",
20
+ "main_branch": "main",
21
+ "protected": true
22
+ }
23
+ }
24
+ ```
25
+
26
+ ---
27
+
28
+ Learn more in `reference.md`.
@@ -0,0 +1,444 @@
1
+ # MoAI-ADK config.json Schema Documentation
2
+
3
+ > **Purpose**: This document defines the official schema structure for `.moai/config.json` file, which serves as the single source of truth for all MoAI-ADK project configuration.
4
+
5
+ ---
6
+
7
+ ## πŸ“‹ Schema Overview
8
+
9
+ The `.moai/config.json` file contains all project-level configuration for MoAI-ADK, including:
10
+ - Project metadata and settings
11
+ - User preferences (language, nickname)
12
+ - Git workflow strategies
13
+ - TAG system configuration
14
+ - Constitution principles
15
+
16
+ ---
17
+
18
+ ## πŸ—οΈ Schema Structure
19
+
20
+ ### Top-Level Sections
21
+
22
+ ```json
23
+ {
24
+ "_meta": { /* Metadata about the config file itself */ },
25
+ "moai": { /* MoAI-ADK version info */ },
26
+ "project": { /* Project-specific settings */ },
27
+ "user": { /* User preferences */ },
28
+ "constitution": { /* Development principles */ },
29
+ "git_strategy": { /* Git workflow configuration */ },
30
+ "pipeline": { /* Command pipeline settings */ },
31
+ "tags": { /* TAG system configuration */ }
32
+ }
33
+ ```
34
+
35
+ ---
36
+
37
+ ## πŸ“– Section Definitions
38
+
39
+ ### 1. `_meta` Section
40
+
41
+ **Purpose**: Internal metadata for config structure tracking and TAG traceability.
42
+
43
+ **Schema**:
44
+ ```json
45
+ {
46
+ "_meta": {
47
+ "@CODE:CONFIG-STRUCTURE-001": "@DOC:JSON-CONFIG-001",
48
+ "@SPEC:PROJECT-CONFIG-001": "@SPEC:MOAI-CONFIG-001"
49
+ }
50
+ }
51
+ ```
52
+
53
+ **Fields**:
54
+ - `@CODE:*`: TAG references to code implementation
55
+ - `@SPEC:*`: TAG references to specification documents
56
+
57
+ ---
58
+
59
+ ### 2. `moai` Section
60
+
61
+ **Purpose**: Track MoAI-ADK package version for compatibility checks.
62
+
63
+ **Schema**:
64
+ ```json
65
+ {
66
+ "moai": {
67
+ "version": "0.4.6"
68
+ }
69
+ }
70
+ ```
71
+
72
+ **Fields**:
73
+ - `version` (string, required): MoAI-ADK version in SemVer format (e.g., "0.4.6")
74
+
75
+ ---
76
+
77
+ ### 3. `project` Section
78
+
79
+ **Purpose**: Core project settings including name, mode, language preferences, and optimization status.
80
+
81
+ **Schema**:
82
+ ```json
83
+ {
84
+ "project": {
85
+ "name": "MoAI-ADK",
86
+ "description": "MoAI-Agentic Development Kit",
87
+ "mode": "personal",
88
+ "locale": "ko",
89
+ "conversation_language": "ko",
90
+ "conversation_language_name": "ν•œκ΅­μ–΄",
91
+ "language": "python",
92
+ "moai_adk_version": "0.4.6",
93
+ "initialized": true,
94
+ "optimized": true,
95
+ "optimized_at": "2025-10-22T12:45:00Z",
96
+ "created_at": "2025-10-21 23:59:19"
97
+ }
98
+ }
99
+ ```
100
+
101
+ **Fields**:
102
+ - `name` (string, required): Project name
103
+ - `description` (string, optional): Brief project description
104
+ - `mode` (enum, required): Project mode β€” `"personal"` | `"team"`
105
+ - `locale` (string, required): System locale code (e.g., `"ko"`, `"en"`, `"ja"`)
106
+ - `conversation_language` (string, required): Language code for all Alfred dialogs and documentation (e.g., `"ko"`, `"en"`, `"ja"`, `"zh"`)
107
+ - `conversation_language_name` (string, required): Display name of conversation language (e.g., `"ν•œκ΅­μ–΄"`, `"English"`)
108
+ - `language` (string, required): Primary codebase language (e.g., `"python"`, `"typescript"`)
109
+ - `moai_adk_version` (string, required): MoAI-ADK version this project was initialized with
110
+ - `initialized` (boolean, required): Whether project initialization completed
111
+ - `optimized` (boolean, required): Whether template optimization completed
112
+ - `optimized_at` (string, optional): ISO 8601 timestamp of optimization completion
113
+ - `created_at` (string, required): Project creation timestamp
114
+
115
+ **Notes**:
116
+ - `conversation_language` is set during `/alfred:0-project` STEP 0.1
117
+ - `language` is auto-detected during `/alfred:0-project` STEP 1 or can be manually specified
118
+
119
+ ---
120
+
121
+ ### 4. `user` Section (NEW in v0.4.6)
122
+
123
+ **Purpose**: User-specific preferences for personalized Alfred experience.
124
+
125
+ **Schema**:
126
+ ```json
127
+ {
128
+ "user": {
129
+ "nickname": "GOOSμ˜€λΌλ²„λ‹ˆ"
130
+ }
131
+ }
132
+ ```
133
+
134
+ **Fields**:
135
+ - `nickname` (string, required): User's chosen nickname for personalized communication
136
+ - Length: 1-50 characters
137
+ - Allows emoji, spaces, and special characters
138
+ - Set during `/alfred:0-project` STEP 0.2
139
+ - Used by all sub-agents to address the user (e.g., "μ•ˆλ…•ν•˜μ„Έμš”, GOOSμ˜€λΌλ²„λ‹ˆλ‹˜!")
140
+ - Displayed in `CLAUDE.md` under "## ν”„λ‘œμ νŠΈ 정보 | Project Information"
141
+
142
+ **Usage**:
143
+ - Alfred and all sub-agents receive `user_nickname` as a context parameter
144
+ - Language-specific honorifics are applied automatically (e.g., "λ‹˜" in Korean)
145
+ - Enhances user experience by personalizing all interactions
146
+
147
+ ---
148
+
149
+ ### 5. `constitution` Section
150
+
151
+ **Purpose**: Define development principles and quality gates enforced by MoAI-ADK.
152
+
153
+ **Schema**:
154
+ ```json
155
+ {
156
+ "constitution": {
157
+ "enforce_tdd": true,
158
+ "require_tags": true,
159
+ "test_coverage_target": 85,
160
+ "simplicity_threshold": 5,
161
+ "principles": {
162
+ "simplicity": {
163
+ "max_projects": 5,
164
+ "notes": "Default recommendation. Adjust in .moai/config.json or via SPEC/ADR with documented rationale based on project size."
165
+ }
166
+ }
167
+ }
168
+ }
169
+ ```
170
+
171
+ **Fields**:
172
+ - `enforce_tdd` (boolean, required): Whether TDD workflow is mandatory
173
+ - `require_tags` (boolean, required): Whether @TAG annotations are required
174
+ - `test_coverage_target` (integer, required): Minimum test coverage percentage (default: 85)
175
+ - `simplicity_threshold` (integer, required): Max number of concurrent projects (default: 5)
176
+ - `principles` (object, optional): Additional principle definitions
177
+
178
+ ---
179
+
180
+ ### 6. `git_strategy` Section
181
+
182
+ **Purpose**: Configure Git workflow automation based on project mode.
183
+
184
+ **Schema**:
185
+ ```json
186
+ {
187
+ "git_strategy": {
188
+ "personal": {
189
+ "auto_checkpoint": "event-driven",
190
+ "checkpoint_events": ["delete", "refactor", "merge", "script", "critical-file"],
191
+ "checkpoint_type": "local-branch",
192
+ "max_checkpoints": 10,
193
+ "cleanup_days": 7,
194
+ "push_to_remote": false,
195
+ "auto_commit": true,
196
+ "branch_prefix": "feature/",
197
+ "develop_branch": "develop",
198
+ "main_branch": "main"
199
+ },
200
+ "team": {
201
+ "use_gitflow": true,
202
+ "auto_pr": true,
203
+ "draft_pr": true,
204
+ "feature_prefix": "feature/SPEC-",
205
+ "develop_branch": "develop",
206
+ "main_branch": "main"
207
+ }
208
+ }
209
+ }
210
+ ```
211
+
212
+ **Personal Mode Fields**:
213
+ - `auto_checkpoint` (enum): `"event-driven"` | `"manual"` | `"disabled"`
214
+ - `checkpoint_events` (array): List of events triggering auto-checkpoint
215
+ - `checkpoint_type` (enum): `"local-branch"` | `"git-stash"` | `"backup-dir"`
216
+ - `max_checkpoints` (integer): Max number of checkpoints to retain
217
+ - `cleanup_days` (integer): Days before old checkpoints are removed
218
+ - `push_to_remote` (boolean): Whether to push checkpoints to remote
219
+ - `auto_commit` (boolean): Auto-commit changes after TDD cycles
220
+ - `branch_prefix` (string): Prefix for feature branches
221
+ - `develop_branch` (string): Name of develop branch
222
+ - `main_branch` (string): Name of main/production branch
223
+
224
+ **Team Mode Fields**:
225
+ - `use_gitflow` (boolean): Enable GitFlow branching strategy
226
+ - `auto_pr` (boolean): Auto-create PR after feature completion
227
+ - `draft_pr` (boolean): Create PRs in draft mode by default
228
+ - `feature_prefix` (string): Prefix for feature branches (includes SPEC ID)
229
+ - `develop_branch` (string): Name of develop branch
230
+ - `main_branch` (string): Name of main/production branch
231
+
232
+ ---
233
+
234
+ ### 7. `pipeline` Section
235
+
236
+ **Purpose**: Define available Alfred commands and track current workflow stage.
237
+
238
+ **Schema**:
239
+ ```json
240
+ {
241
+ "pipeline": {
242
+ "available_commands": [
243
+ "/alfred:0-project",
244
+ "/alfred:1-plan",
245
+ "/alfred:2-run",
246
+ "/alfred:3-sync"
247
+ ],
248
+ "current_stage": "initialized"
249
+ }
250
+ }
251
+ ```
252
+
253
+ **Fields**:
254
+ - `available_commands` (array, required): List of available Alfred commands
255
+ - `current_stage` (string, required): Current workflow stage (e.g., `"initialized"`, `"planning"`, `"building"`, `"syncing"`)
256
+
257
+ ---
258
+
259
+ ### 8. `tags` Section
260
+
261
+ **Purpose**: Configure TAG system behavior and storage policy.
262
+
263
+ **Schema**:
264
+ ```json
265
+ {
266
+ "tags": {
267
+ "storage_type": "code_scan",
268
+ "auto_sync": true,
269
+ "categories": ["REQ", "DESIGN", "TASK", "TEST", "FEATURE", "API", "UI", "DATA"],
270
+ "code_scan_policy": {
271
+ "no_intermediate_cache": true,
272
+ "realtime_validation": true,
273
+ "scan_tools": ["rg", "grep"],
274
+ "scan_command": "rg '@TAG' -n",
275
+ "philosophy": "The source of truth for TAGs lives in the code itself"
276
+ }
277
+ }
278
+ }
279
+ ```
280
+
281
+ **Fields**:
282
+ - `storage_type` (enum, required): `"code_scan"` | `"registry_file"`
283
+ - `auto_sync` (boolean, required): Auto-sync TAGs during `/alfred:3-sync`
284
+ - `categories` (array, required): List of valid TAG categories
285
+ - `code_scan_policy` (object, required): Configuration for code-first TAG scanning
286
+ - `no_intermediate_cache` (boolean): Never use intermediate TAG cache files
287
+ - `realtime_validation` (boolean): Validate TAGs on every operation
288
+ - `scan_tools` (array): Tools used for TAG scanning (e.g., `["rg", "grep"]`)
289
+ - `scan_command` (string): Command to scan for TAGs
290
+ - `philosophy` (string): Description of TAG philosophy
291
+
292
+ ---
293
+
294
+ ## πŸ”„ Schema Evolution
295
+
296
+ ### Version History
297
+
298
+ | Version | Date | Changes |
299
+ | ------- | ---------- | ------------------------------------------------------ |
300
+ | v0.4.6 | 2025-10-23 | Added `user` section with `nickname` field |
301
+ | v0.4.2 | 2025-10-22 | Added `conversation_language` and `language_name` fields |
302
+ | v0.4.0 | 2025-10-20 | Initial schema documentation |
303
+
304
+ ### Migration Guide
305
+
306
+ **From v0.4.5 β†’ v0.4.6**:
307
+ - Add `user` section with `nickname` field
308
+ - No breaking changes; existing configs remain compatible
309
+
310
+ **Example Migration**:
311
+ ```json
312
+ // Before (v0.4.5)
313
+ {
314
+ "project": {
315
+ "conversation_language": "ko",
316
+ "conversation_language_name": "ν•œκ΅­μ–΄"
317
+ }
318
+ }
319
+
320
+ // After (v0.4.6)
321
+ {
322
+ "project": {
323
+ "conversation_language": "ko",
324
+ "conversation_language_name": "ν•œκ΅­μ–΄"
325
+ },
326
+ "user": {
327
+ "nickname": "GOOSμ˜€λΌλ²„λ‹ˆ"
328
+ }
329
+ }
330
+ ```
331
+
332
+ ---
333
+
334
+ ## πŸ“š Related Documentation
335
+
336
+ - **Template Processing**: `/src/moai_adk/cli/template_processor.py`
337
+ - **Project Initialization**: `/.claude/commands/alfred/0-project.md`
338
+ - **project-manager Agent**: `/.claude/agents/alfred/project-manager.md`
339
+ - **CLAUDE.md Template**: `/src/moai_adk/templates/CLAUDE.md`
340
+
341
+ ---
342
+
343
+ ## βœ… Validation Rules
344
+
345
+ ### Required Fields per Section
346
+
347
+ **Minimum Valid Config**:
348
+ ```json
349
+ {
350
+ "moai": {
351
+ "version": "0.4.6"
352
+ },
353
+ "project": {
354
+ "name": "MyProject",
355
+ "mode": "personal",
356
+ "locale": "en",
357
+ "conversation_language": "en",
358
+ "conversation_language_name": "English",
359
+ "language": "python",
360
+ "initialized": true
361
+ },
362
+ "user": {
363
+ "nickname": "Developer"
364
+ },
365
+ "constitution": {
366
+ "enforce_tdd": true,
367
+ "require_tags": true,
368
+ "test_coverage_target": 85
369
+ },
370
+ "tags": {
371
+ "storage_type": "code_scan",
372
+ "auto_sync": true
373
+ }
374
+ }
375
+ ```
376
+
377
+ ### Validation Checklist
378
+
379
+ - [ ] `moai.version` matches installed package version
380
+ - [ ] `project.mode` is either `"personal"` or `"team"`
381
+ - [ ] `project.conversation_language` is a valid ISO 639-1 code
382
+ - [ ] `user.nickname` length is between 1-50 characters
383
+ - [ ] `constitution.test_coverage_target` is between 0-100
384
+ - [ ] `tags.storage_type` is valid enum value
385
+ - [ ] All required fields are present
386
+
387
+ ---
388
+
389
+ ## πŸ› οΈ Usage Examples
390
+
391
+ ### Reading Config in Python
392
+
393
+ ```python
394
+ import json
395
+ from pathlib import Path
396
+
397
+ def read_config():
398
+ config_path = Path(".moai/config.json")
399
+ with open(config_path, "r", encoding="utf-8") as f:
400
+ return json.load(f)
401
+
402
+ config = read_config()
403
+ user_nickname = config.get("user", {}).get("nickname", "Developer")
404
+ conversation_language = config["project"]["conversation_language"]
405
+ ```
406
+
407
+ ### Updating User Nickname
408
+
409
+ ```python
410
+ import json
411
+ from pathlib import Path
412
+
413
+ def update_user_nickname(new_nickname: str):
414
+ config_path = Path(".moai/config.json")
415
+
416
+ # Read existing config
417
+ with open(config_path, "r", encoding="utf-8") as f:
418
+ config = json.load(f)
419
+
420
+ # Update user section
421
+ if "user" not in config:
422
+ config["user"] = {}
423
+ config["user"]["nickname"] = new_nickname
424
+
425
+ # Write back
426
+ with open(config_path, "w", encoding="utf-8") as f:
427
+ json.dump(config, f, indent=2, ensure_ascii=False)
428
+ ```
429
+
430
+ ---
431
+
432
+ ## πŸ“ Notes
433
+
434
+ - **SSOT**: This config file is the single source of truth for all project settings
435
+ - **No Duplication**: Never duplicate config values in code or other files
436
+ - **Encoding**: Always use UTF-8 encoding to support international characters in nicknames and language names
437
+ - **Validation**: Always validate config structure before reading values
438
+ - **Migration**: When adding new fields, provide sensible defaults for backwards compatibility
439
+
440
+ ---
441
+
442
+ **Last Updated**: 2025-10-23
443
+ **Version**: v0.4.6
444
+ **Maintainer**: cc-manager
@@ -0,0 +1,62 @@
1
+ ---
2
+ name: moai-alfred-context-budget
3
+ description: "Claude Code context window optimization strategies, JIT retrieval, progressive loading, memory file patterns, and cleanup practices. Use when optimizing context usage, managing large projects, or implementing efficient workflows."
4
+ allowed-tools: "Read, Grep"
5
+ ---
6
+
7
+ ## What It Does
8
+
9
+ Claude Code context budget (100K-200K tokens)의 효율적 관리 μ „λž΅, progressive disclosure, JIT retrieval, memory file ꡬ쑰화 방법을 μ œκ³΅ν•©λ‹ˆλ‹€.
10
+
11
+ ## When to Use
12
+
13
+ - βœ… Context limit 도달 μœ„ν—˜μ„± μžˆμ„ λ•Œ
14
+ - βœ… λŒ€κ·œλͺ¨ ν”„λ‘œμ νŠΈμ˜ context 관리 ν•„μš”
15
+ - βœ… Session handoff μ€€λΉ„
16
+ - βœ… Memory file ꡬ쑰 섀계/정리
17
+
18
+ ## Context Budget Overview
19
+
20
+ ```
21
+ Total: 100K-200K tokens
22
+ β”œβ”€β”€ System Prompt: ~2K
23
+ β”œβ”€β”€ Tools & Instructions: ~5K
24
+ β”œβ”€β”€ Session History: ~30K
25
+ β”œβ”€β”€ Project Context: ~40K
26
+ └── Available for Response: ~23K
27
+ ```
28
+
29
+ ## Progressive Disclosure Pattern
30
+
31
+ 1. **Metadata** (always): Skill name, description, triggers
32
+ 2. **Content** (on-demand): Full SKILL.md when invoked
33
+ 3. **Supporting** (JIT): Examples, templates when referenced
34
+
35
+ ## JIT Retrieval Principles
36
+
37
+ - Pull only what you need for immediate step
38
+ - Prefer `Explore` over manual file hunting
39
+ - Cache critical insights for reuse
40
+ - Remove unnecessary files regularly
41
+
42
+ ## Best Practices
43
+
44
+ βœ… DO:
45
+ - Use Explore for large searches
46
+ - Cache results in memory files
47
+ - Keep memory files < 500 lines each
48
+ - Update session-summary.md before task switches
49
+ - Archive completed work
50
+
51
+ ❌ DON'T:
52
+ - Load entire src/ directory upfront
53
+ - Duplicate context between files
54
+ - Store memory files outside `.moai/memory/`
55
+ - Leave stale session notes (archive or delete)
56
+ - Cache raw code (summarize instead)
57
+
58
+ ---
59
+
60
+ Learn more in `reference.md` for detailed JIT strategy, memory patterns, context budget calculations, and management practices.
61
+
62
+ **Related Skills**: moai-alfred-practices, moai-cc-memory