moai-adk 0.3.7__tar.gz → 0.3.10__tar.gz

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 (90) hide show
  1. {moai_adk-0.3.7 → moai_adk-0.3.10}/.gitignore +7 -12
  2. {moai_adk-0.3.7 → moai_adk-0.3.10}/PKG-INFO +1 -18
  3. {moai_adk-0.3.7 → moai_adk-0.3.10}/README.md +0 -17
  4. {moai_adk-0.3.7 → moai_adk-0.3.10}/pyproject.toml +1 -1
  5. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/__init__.py +1 -1
  6. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/init.py +27 -34
  7. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/processor.py +14 -25
  8. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/commands/alfred/1-spec.md +2 -0
  9. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/commands/alfred/2-build.md +2 -0
  10. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/commands/alfred/3-sync.md +2 -0
  11. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/core/__init__.py +6 -0
  12. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/core/context.py +2 -45
  13. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/settings.json +11 -30
  14. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/project/product.md +45 -5
  15. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/project/structure.md +9 -3
  16. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/project/tech.md +9 -3
  17. moai_adk-0.3.10/src/moai_adk/templates/CLAUDE.md +727 -0
  18. moai_adk-0.3.7/src/moai_adk/templates/.claude/hooks/alfred/core/tags.py +0 -244
  19. {moai_adk-0.3.7 → moai_adk-0.3.10}/LICENSE +0 -0
  20. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/__main__.py +0 -0
  21. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/__init__.py +0 -0
  22. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/__init__.py +0 -0
  23. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/backup.py +0 -0
  24. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/doctor.py +0 -0
  25. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/restore.py +0 -0
  26. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/status.py +0 -0
  27. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/commands/update.py +0 -0
  28. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/main.py +0 -0
  29. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/prompts/__init__.py +0 -0
  30. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/cli/prompts/init_prompts.py +0 -0
  31. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/__init__.py +0 -0
  32. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/__init__.py +0 -0
  33. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/branch.py +0 -0
  34. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/branch_manager.py +0 -0
  35. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/checkpoint.py +0 -0
  36. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/commit.py +0 -0
  37. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/event_detector.py +0 -0
  38. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/git/manager.py +0 -0
  39. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/__init__.py +0 -0
  40. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/backup_utils.py +0 -0
  41. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/checker.py +0 -0
  42. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/detector.py +0 -0
  43. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/initializer.py +0 -0
  44. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/phase_executor.py +0 -0
  45. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/project/validator.py +0 -0
  46. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/quality/__init__.py +0 -0
  47. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/quality/trust_checker.py +0 -0
  48. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/quality/validators/__init__.py +0 -0
  49. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/quality/validators/base_validator.py +0 -0
  50. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/__init__.py +0 -0
  51. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/backup.py +0 -0
  52. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/config.py +0 -0
  53. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/languages.py +0 -0
  54. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/core/template/merger.py +0 -0
  55. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/cc-manager.md +0 -0
  56. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/debug-helper.md +0 -0
  57. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/doc-syncer.md +0 -0
  58. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/git-manager.md +0 -0
  59. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/implementation-planner.md +0 -0
  60. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/project-manager.md +0 -0
  61. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/quality-gate.md +0 -0
  62. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/spec-builder.md +0 -0
  63. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/tag-agent.md +0 -0
  64. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/tdd-implementer.md +0 -0
  65. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/agents/alfred/trust-checker.md +0 -0
  66. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/commands/alfred/0-project.md +0 -0
  67. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/README.md +0 -0
  68. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/alfred_hooks.py +0 -0
  69. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/core/checkpoint.py +0 -0
  70. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/core/project.py +0 -0
  71. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/handlers/__init__.py +0 -0
  72. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/handlers/notification.py +0 -0
  73. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/handlers/session.py +0 -0
  74. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/handlers/tool.py +0 -0
  75. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/hooks/alfred/handlers/user.py +0 -0
  76. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/output-styles/alfred/agentic-coding.md +0 -0
  77. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/output-styles/alfred/moai-adk-learning.md +0 -0
  78. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.claude/output-styles/alfred/study-with-alfred.md +0 -0
  79. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.github/PULL_REQUEST_TEMPLATE.md +0 -0
  80. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.github/workflows/moai-gitflow.yml +0 -0
  81. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.gitignore +0 -0
  82. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/config.json +0 -0
  83. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/hooks/pre-push.sample +0 -0
  84. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/memory/development-guide.md +0 -0
  85. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/memory/gitflow-protection-policy.md +0 -0
  86. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/.moai/memory/spec-metadata.md +0 -0
  87. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/templates/__init__.py +0 -0
  88. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/utils/__init__.py +0 -0
  89. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/utils/banner.py +0 -0
  90. {moai_adk-0.3.7 → moai_adk-0.3.10}/src/moai_adk/utils/logger.py +0 -0
@@ -33,14 +33,9 @@ docs/_build/
33
33
  docs/*
34
34
  !docs/public/
35
35
 
36
- # MoAI Project (user-specific, except templates)
37
- /.moai/
38
- !src/moai_adk/templates/.moai/
39
-
40
- # Reports (legacy - covered by /.moai/)
41
- # .moai/reports/*.md
42
- # .moai/reports/*.json
43
- # .moai/reports/*.html
36
+ # MoAI Project - 모두 공개
37
+ # /.moai/ - 공개로 전환
38
+ # !src/moai_adk/templates/.moai/ - 이미 공개
44
39
 
45
40
  # Virtual environment
46
41
  venv/
@@ -55,11 +50,11 @@ env/
55
50
  *.swo
56
51
  *~
57
52
 
58
- # Claude Code (user-specific)
53
+ # Claude Code - 모두 공개
59
54
  AGENTS.md
60
- CLAUDE.md
61
- /.claude/
62
- !src/moai_adk/templates/.claude/
55
+ # CLAUDE.md - 공개로 전환
56
+ # /.claude/ - 공개로 전환
57
+ # !src/moai_adk/templates/.claude/ - 이미 공개
63
58
 
64
59
  # OS
65
60
  .DS_Store
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: moai-adk
3
- Version: 0.3.7
3
+ Version: 0.3.10
4
4
  Summary: MoAI Agentic Development Kit - SPEC-First TDD with Alfred SuperAgent
5
5
  Project-URL: Homepage, https://github.com/modu-ai/moai-adk
6
6
  Project-URL: Repository, https://github.com/modu-ai/moai-adk
@@ -603,7 +603,6 @@ src/todo/routes.py # @CODE:TODO-001:API
603
603
  "created_at": "2025-10-17T10:00:00Z"
604
604
  }
605
605
  ```
606
- ```
607
606
 
608
607
  ---
609
608
 
@@ -772,22 +771,6 @@ git pull origin develop
772
771
 
773
772
  ---
774
773
 
775
- ### 시나리오 3: Release 준비
776
-
777
- ```bash
778
- # 표준 방식 (권장):
779
- git checkout develop
780
- gh pr create --base main --head develop --title "Release v1.0.0"
781
-
782
- # 직접 push 방식 (허용):
783
- git checkout develop
784
- git push origin main # ⚠️ Advisory 경고 표시되지만 진행됨
785
- git tag -a v1.0.0 -m "Release v1.0.0"
786
- git push origin v1.0.0
787
- ```
788
-
789
- ---
790
-
791
774
  ## ■ AI 모델 선택 가이드
792
775
 
793
776
  MoAI-ADK는 **Haiku 4.5**와 **Sonnet 4.5** 두 가지 AI 모델을 전략적으로 활용하여 **최적의 성능과 비용 효율**을 제공합니다.
@@ -565,7 +565,6 @@ src/todo/routes.py # @CODE:TODO-001:API
565
565
  "created_at": "2025-10-17T10:00:00Z"
566
566
  }
567
567
  ```
568
- ```
569
568
 
570
569
  ---
571
570
 
@@ -734,22 +733,6 @@ git pull origin develop
734
733
 
735
734
  ---
736
735
 
737
- ### 시나리오 3: Release 준비
738
-
739
- ```bash
740
- # 표준 방식 (권장):
741
- git checkout develop
742
- gh pr create --base main --head develop --title "Release v1.0.0"
743
-
744
- # 직접 push 방식 (허용):
745
- git checkout develop
746
- git push origin main # ⚠️ Advisory 경고 표시되지만 진행됨
747
- git tag -a v1.0.0 -m "Release v1.0.0"
748
- git push origin v1.0.0
749
- ```
750
-
751
- ---
752
-
753
736
  ## ■ AI 모델 선택 가이드
754
737
 
755
738
  MoAI-ADK는 **Haiku 4.5**와 **Sonnet 4.5** 두 가지 AI 모델을 전략적으로 활용하여 **최적의 성능과 비용 효율**을 제공합니다.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "moai-adk"
3
- version = "0.3.7"
3
+ version = "0.3.10"
4
4
  description = "MoAI Agentic Development Kit - SPEC-First TDD with Alfred SuperAgent"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.13"
@@ -4,5 +4,5 @@
4
4
  SPEC-First TDD Framework with Alfred SuperAgent
5
5
  """
6
6
 
7
- __version__ = "0.3.7"
7
+ __version__ = "0.3.9"
8
8
  __all__ = ["__version__"]
@@ -134,45 +134,20 @@ def init(
134
134
 
135
135
  console.print("\n[cyan]🚀 Starting installation...[/cyan]\n")
136
136
 
137
- # 4. Check for reinitialization (SPEC-INIT-003 v0.3.0)
137
+ # 4. Check for reinitialization (SPEC-INIT-003 v0.3.0) - DEFAULT TO FORCE MODE
138
138
  initializer = ProjectInitializer(project_path)
139
139
 
140
140
  if initializer.is_initialized():
141
- if non_interactive and not force:
142
- # Non-interactive mode (without force): Reject reinitialization
143
- console.print("\n[yellow] Project already initialized[/yellow]")
144
- console.print(f"[dim] Location: {project_path}/.moai/[/dim]")
145
- console.print("[dim] Use --force to reinitialize or interactive mode[/dim]\n")
146
- raise click.Abort()
147
-
148
- if force:
149
- # Force mode: Reinitialize without confirmation
150
- console.print("\n[green]🔄 Force reinitializing project...[/green]\n")
141
+ # Always reinitialize without confirmation (force mode by default)
142
+ if non_interactive:
143
+ console.print("\n[green]🔄 Reinitializing project (force mode)...[/green]\n")
151
144
  else:
152
- # Interactive mode: Reinitialization prompt
153
- console.print("\n⚠️ [yellow]Project already initialized[/yellow]")
154
- console.print(f" Location: {project_path}/.moai/\n")
155
-
156
- console.print("[cyan]This will:[/cyan]")
157
- console.print(" ✓ Backup existing files to .moai-backups/{timestamp}/")
158
- console.print(" • CLAUDE.md")
159
- console.print(" • .claude/ (settings, commands, hooks)")
160
- console.print(" • .moai/ (all configurations and specs)")
161
- console.print(" ✓ Update template files from moai-adk v0.3.0")
162
- console.print(" • .claude/ → Latest Alfred commands")
163
- console.print(" • .moai/memory/ → Latest development guides")
164
- console.print(" • CLAUDE.md → Latest project documentation")
165
- console.print(" ✓ Preserve your content")
166
- console.print(" • .moai/project/ (product/structure/tech.md)")
167
- console.print(" • .moai/specs/ (all SPEC documents)\n")
168
-
169
- if not Confirm.ask("Would you like to update the project templates?", default=True):
170
- console.print("\n[yellow]Reinit cancelled.[/yellow]\n")
171
- raise click.Abort()
172
-
173
- console.print("\n[green]🔄 Starting reinit process...[/green]\n")
145
+ # Interactive mode: Simple notification
146
+ console.print("\n[cyan]🔄 Reinitializing project...[/cyan]")
147
+ console.print(" Backup will be created at .moai-backups/{timestamp}/\n")
174
148
 
175
149
  # 5. Initialize project (Progress Bar with 5 phases)
150
+ # Always allow reinit (force mode by default)
176
151
  is_reinit = initializer.is_initialized()
177
152
 
178
153
  # Reinit mode: set config.json optimized to false (v0.3.1+)
@@ -220,7 +195,7 @@ def init(
220
195
  language=language,
221
196
  backup_enabled=True,
222
197
  progress_callback=callback,
223
- reinit=is_reinit, # SPEC-INIT-003 v0.3.0
198
+ reinit=True, # Always allow reinit (force mode by default)
224
199
  )
225
200
 
226
201
  # 6. Output results
@@ -241,7 +216,25 @@ def init(
241
216
  f" [dim]📄 Files:[/dim] {len(result.created_files)} created"
242
217
  )
243
218
  console.print(f" [dim]⏱️ Duration:[/dim] {result.duration}ms")
219
+
220
+ # Show backup info if reinitialized
221
+ if is_reinit:
222
+ backup_dir = project_path / ".moai-backups"
223
+ if backup_dir.exists():
224
+ latest_backup = max(backup_dir.iterdir(), key=lambda p: p.stat().st_mtime)
225
+ console.print(f" [dim]💾 Backup:[/dim] {latest_backup.name}/")
226
+
244
227
  console.print(f"\n{separator}")
228
+
229
+ # Show config merge notice if reinitialized
230
+ if is_reinit:
231
+ console.print("\n[yellow]⚠️ Configuration Notice:[/yellow]")
232
+ console.print(" All template files have been [bold]force overwritten[/bold]")
233
+ console.print(" Previous files are backed up in [cyan].moai-backups/{timestamp}/[/cyan]")
234
+ console.print("\n [cyan]To merge your previous config:[/cyan]")
235
+ console.print(" Run [bold]/alfred:0-project[/bold] command in Claude Code")
236
+ console.print(" It will merge backup config when [dim]optimized=false[/dim]\n")
237
+
245
238
  console.print("\n[cyan]🚀 Next Steps:[/cyan]")
246
239
  if not is_current_dir:
247
240
  console.print(
@@ -23,7 +23,8 @@ class TemplateProcessor:
23
23
  ".moai/specs/", # User SPEC documents
24
24
  ".moai/reports/", # User reports
25
25
  ".moai/project/", # User project documents (product/structure/tech.md)
26
- ".moai/config.json", # User configuration (merged via /alfred:9-update flow)
26
+ # config.json is now FORCE OVERWRITTEN (backup in .moai-backups/)
27
+ # Merge via /alfred:0-project when optimized=false
27
28
  ]
28
29
 
29
30
  # Paths excluded from backups
@@ -277,7 +278,7 @@ class TemplateProcessor:
277
278
  if not silent:
278
279
  console.print(f" ✅ .claude/{folder}/ overwritten")
279
280
 
280
- # 2. Copy other files/folders individually (preserve existing, with substitution)
281
+ # 2. Copy other files/folders individually (FORCE OVERWRITE all files)
281
282
  all_warnings = []
282
283
  for item in src.iterdir():
283
284
  rel_path = item.relative_to(src)
@@ -288,16 +289,12 @@ class TemplateProcessor:
288
289
  continue
289
290
 
290
291
  if item.is_file():
291
- # Copy file, skip if exists (preserve user modifications)
292
- if not dst_item.exists():
293
- # Copy with variable substitution for text files
294
- warnings = self._copy_file_with_substitution(item, dst_item)
295
- all_warnings.extend(warnings)
292
+ # FORCE OVERWRITE: Always copy files (no skip)
293
+ warnings = self._copy_file_with_substitution(item, dst_item)
294
+ all_warnings.extend(warnings)
296
295
  elif item.is_dir():
297
- # Copy directory recursively (preserve existing files)
298
- if not dst_item.exists():
299
- # Recursively copy directory with substitution
300
- self._copy_dir_with_substitution(item, dst_item)
296
+ # FORCE OVERWRITE: Always copy directories (no skip)
297
+ self._copy_dir_with_substitution(item, dst_item)
301
298
 
302
299
  # Print warnings if any
303
300
  if all_warnings and not silent:
@@ -362,9 +359,7 @@ class TemplateProcessor:
362
359
 
363
360
  dst_item = dst / rel_path
364
361
  if item.is_file():
365
- # Skip existing files to preserve user content (v0.3.0)
366
- if dst_item.exists():
367
- continue
362
+ # FORCE OVERWRITE: Always copy files (no skip)
368
363
  dst_item.parent.mkdir(parents=True, exist_ok=True)
369
364
  # Copy with variable substitution
370
365
  warnings = self._copy_file_with_substitution(item, dst_item)
@@ -382,7 +377,7 @@ class TemplateProcessor:
382
377
  console.print(" ✅ .moai/ copy complete (variables substituted)")
383
378
 
384
379
  def _copy_claude_md(self, silent: bool = False) -> None:
385
- """Copy CLAUDE.md with smart merging and variable substitution."""
380
+ """Copy CLAUDE.md with FORCE OVERWRITE."""
386
381
  src = self.template_root / "CLAUDE.md"
387
382
  dst = self.target_path / "CLAUDE.md"
388
383
 
@@ -391,16 +386,10 @@ class TemplateProcessor:
391
386
  console.print("⚠️ CLAUDE.md template not found")
392
387
  return
393
388
 
394
- # Preserve project information when the file exists
395
- if dst.exists():
396
- self._merge_claude_md(src, dst)
397
- if not silent:
398
- console.print(" 🔄 CLAUDE.md merged (project information preserved)")
399
- else:
400
- # Copy with variable substitution
401
- self._copy_file_with_substitution(src, dst)
402
- if not silent:
403
- console.print(" ✅ CLAUDE.md copy complete")
389
+ # FORCE OVERWRITE: Always copy template (backup already created in Phase 1)
390
+ self._copy_file_with_substitution(src, dst)
391
+ if not silent:
392
+ console.print(" ✅ CLAUDE.md overwritten (backup available in .moai-backups/)")
404
393
 
405
394
  def _merge_claude_md(self, src: Path, dst: Path) -> None:
406
395
  """Delegate the smart merge for CLAUDE.md.
@@ -50,6 +50,8 @@ allowed-tools:
50
50
 
51
51
  프로젝트 문서를 분석하여 SPEC 후보를 제안하고 구현 전략을 수립한 후 사용자 확인을 받습니다.
52
52
 
53
+ **spec-builder 에이전트가 자동으로 필요한 문서를 로드하여 분석합니다.**
54
+
53
55
  ### 🔍 코드베이스 탐색 (선택사항)
54
56
 
55
57
  **사용자 요청이 불명확하거나 기존 코드 파악이 필요한 경우** Explore 에이전트를 먼저 활용합니다:
@@ -55,6 +55,8 @@ SPEC 문서를 분석하여 언어별 최적화된 TDD 사이클(Red-Green-Refac
55
55
 
56
56
  먼저 지정된 SPEC을 분석하여 구현 계획을 수립하고 사용자 확인을 받습니다.
57
57
 
58
+ **implementation-planner 에이전트가 자동으로 필요한 문서를 로드하여 분석합니다.**
59
+
58
60
  ### 🔍 코드베이스 탐색 (권장)
59
61
 
60
62
  **기존 코드 구조를 파악하거나 유사 패턴을 찾아야 하는 경우** Explore 에이전트를 먼저 활용합니다:
@@ -68,6 +68,8 @@ allowed-tools:
68
68
 
69
69
  프로젝트 상태를 분석하여 동기화 범위를 결정하고 체계적인 동기화 계획을 수립한 후 사용자 확인을 받습니다.
70
70
 
71
+ **doc-syncer 에이전트가 자동으로 TAG 체인 스캔 및 Git 변경사항을 확인하여 분석합니다.**
72
+
71
73
  ### 🔍 TAG 체인 탐색 (선택사항)
72
74
 
73
75
  **TAG 체인이 복잡하거나 광범위한 경우** Explore 에이전트를 먼저 활용합니다:
@@ -77,3 +77,9 @@ class HookResult:
77
77
 
78
78
 
79
79
  __all__ = ["HookPayload", "HookResult"]
80
+
81
+ # Note: core module exports:
82
+ # - HookPayload, HookResult (type definitions)
83
+ # - project.py: detect_language, get_git_info, count_specs, get_project_language
84
+ # - context.py: get_jit_context
85
+ # - checkpoint.py: detect_risky_operation, create_checkpoint, log_checkpoint, list_checkpoints
@@ -1,15 +1,10 @@
1
1
  #!/usr/bin/env python3
2
2
  """Context Engineering utilities
3
3
 
4
- JIT (Just-in-Time) Retrieval 및 워크플로우 컨텍스트 관리
4
+ JIT (Just-in-Time) Retrieval
5
5
  """
6
6
 
7
- import time
8
7
  from pathlib import Path
9
- from typing import Any
10
-
11
- # Workflow context shared across phases
12
- _workflow_context: dict[str, Any] = {}
13
8
 
14
9
 
15
10
  def get_jit_context(prompt: str, cwd: str) -> list[str]:
@@ -69,42 +64,4 @@ def get_jit_context(prompt: str, cwd: str) -> list[str]:
69
64
  return context_files
70
65
 
71
66
 
72
- def save_phase_context(phase: str, data: dict):
73
- """Store per-phase workflow context data.
74
-
75
- Args:
76
- phase: ``"analysis"``, ``"implementation"`` or ``"verification"``.
77
- data: Payload to share with later phases.
78
-
79
- Notes:
80
- - Enables reuse of expensive analysis across phases.
81
- - Entries expire after 10 minutes to avoid stale data.
82
- """
83
- _workflow_context[phase] = {"data": data, "timestamp": time.time()}
84
-
85
-
86
- def load_phase_context(phase: str) -> dict | None:
87
- """Load previously stored workflow context for a phase.
88
-
89
- Returns:
90
- Stored context data or ``None`` when expired or missing.
91
- """
92
- if phase in _workflow_context:
93
- ctx = _workflow_context[phase]
94
- # Only accept entries that are younger than 10 minutes
95
- if time.time() - ctx["timestamp"] < 600:
96
- return ctx["data"]
97
- return None
98
-
99
-
100
- def clear_workflow_context():
101
- """Clear all cached workflow context (call at workflow end)."""
102
- _workflow_context.clear()
103
-
104
-
105
- __all__ = [
106
- "get_jit_context",
107
- "save_phase_context",
108
- "load_phase_context",
109
- "clear_workflow_context",
110
- ]
67
+ __all__ = ["get_jit_context"]
@@ -17,28 +17,6 @@
17
17
  "matcher": "*"
18
18
  }
19
19
  ],
20
- "UserPromptSubmit": [
21
- {
22
- "hooks": [
23
- {
24
- "command": "uv run .claude/hooks/alfred/alfred_hooks.py UserPromptSubmit",
25
- "type": "command"
26
- }
27
- ],
28
- "matcher": "*"
29
- }
30
- ],
31
- "PreCompact": [
32
- {
33
- "hooks": [
34
- {
35
- "command": "uv run .claude/hooks/alfred/alfred_hooks.py PreCompact",
36
- "type": "command"
37
- }
38
- ],
39
- "matcher": "*"
40
- }
41
- ],
42
20
  "PreToolUse": [
43
21
  {
44
22
  "hooks": [
@@ -71,7 +49,6 @@
71
49
  "Bash(git:*)",
72
50
  "Bash(rg:*)",
73
51
  "Bash(ls:*)",
74
- "Bash(cat:*)",
75
52
  "Bash(echo:*)",
76
53
  "Bash(which:*)",
77
54
  "Bash(make:*)",
@@ -91,7 +68,6 @@
91
68
  "Bash(gh pr merge:*)",
92
69
  "Bash(gh repo view:*)",
93
70
  "Bash(gh issue:*)",
94
- "Bash(find:*)",
95
71
  "Bash(mkdir:*)",
96
72
  "Bash(touch:*)",
97
73
  "Bash(cp:*)",
@@ -100,9 +76,7 @@
100
76
  "Bash(diff:*)",
101
77
  "Bash(wc:*)",
102
78
  "Bash(sort:*)",
103
- "Bash(uniq:*)",
104
- "Bash(head:*)",
105
- "Bash(tail:*)"
79
+ "Bash(uniq:*)"
106
80
  ],
107
81
  "ask": [
108
82
  "Bash(git push:*)",
@@ -112,7 +86,9 @@
112
86
  "Bash(uv remove:*)",
113
87
  "Bash(pip install:*)",
114
88
  "Bash(pip3 install:*)",
115
- "Bash(rm:*)"
89
+ "Bash(rm:*)",
90
+ "Bash(sudo:*)",
91
+ "Bash(rm -rf:*)"
116
92
  ],
117
93
  "deny": [
118
94
  "Read(./.env)",
@@ -121,8 +97,13 @@
121
97
  "Read(~/.ssh/**)",
122
98
  "Read(~/.aws/**)",
123
99
  "Read(~/.config/gcloud/**)",
124
- "Bash(sudo:*)",
125
- "Bash(rm -rf:*)",
100
+ "Bash(rm -rf /:*)",
101
+ "Bash(rm -rf /*:*)",
102
+ "Bash(rm -rf C\\:/:*)",
103
+ "Bash(rm -rf C\\:/*:*)",
104
+ "Bash(del /S /Q C\\:/:*)",
105
+ "Bash(rmdir /S /Q C\\:/:*)",
106
+ "Bash(format:*)",
126
107
  "Bash(chmod -R 777:*)",
127
108
  "Bash(dd:*)",
128
109
  "Bash(mkfs:*)",
@@ -1,16 +1,34 @@
1
1
  ---
2
2
  id: PRODUCT-001
3
- version: 0.1.0
3
+ version: 0.1.3
4
4
  status: active
5
5
  created: 2025-10-01
6
- updated: 2025-10-01
7
- authors: ["@project-owner"]
6
+ updated: 2025-10-17
7
+ author: @project-owner
8
+ priority: high
8
9
  ---
9
10
 
10
11
  # {{PROJECT_NAME}} Product Definition
11
12
 
12
13
  ## HISTORY
13
14
 
15
+ ### v0.1.3 (2025-10-17)
16
+ - **UPDATED**: 템플릿 버전 동기화 (v0.3.8)
17
+ - **AUTHOR**: @Alfred
18
+ - **SECTIONS**: Mission (12개 에이전트 최종 확인: Alfred + 11개 전문 에이전트)
19
+ - implementation-planner, tdd-implementer, quality-gate 추가
20
+ - code-builder → implementation-planner + tdd-implementer + quality-gate 분해
21
+
22
+ ### v0.1.2 (2025-10-17)
23
+ - **UPDATED**: 에이전트 수 갱신 (9개 → 11개)
24
+ - **AUTHOR**: @Alfred
25
+ - **SECTIONS**: Mission (Alfred SuperAgent 팀 구성 업데이트)
26
+
27
+ ### v0.1.1 (2025-10-17)
28
+ - **UPDATED**: 템플릿 기본값을 실제 MoAI-ADK 프로젝트 내용으로 갱신
29
+ - **AUTHOR**: @Alfred
30
+ - **SECTIONS**: Mission, User, Problem, Strategy, Success 실제 내용 반영
31
+
14
32
  ### v0.1.0 (2025-10-01)
15
33
  - **INITIAL**: 프로젝트 제품 정의 문서 작성
16
34
  - **AUTHOR**: @project-owner
@@ -20,11 +38,33 @@ authors: ["@project-owner"]
20
38
 
21
39
  ## @DOC:MISSION-001 핵심 미션
22
40
 
23
- **[프로젝트의 핵심 미션과 목표를 정의하세요]**
41
+ > **"SPEC이 없으면 CODE도 없다."**
42
+
43
+ {{PROJECT_NAME}}는 **SPEC-First TDD 방법론**을 통해 플랑켄슈타인 코드를 근본적으로 방지하는 프로젝트입니다.
24
44
 
25
45
  ### 핵심 가치 제안
26
46
 
27
- [이 프로젝트가 제공하는 핵심 가치를 설명하세요]
47
+ #### 4가지 핵심 가치
48
+
49
+ 1. **일관성 (Consistency)**: SPEC → TDD → Sync 3단계 파이프라인으로 개발 품질 보장
50
+ 2. **품질 (Quality)**: TRUST 5원칙 (Test First, Readable, Unified, Secured, Trackable) 자동 적용
51
+ 3. **추적성 (Traceability)**: @TAG 시스템 (`@SPEC → @TEST → @CODE → @DOC`)으로 완벽한 이력 추적
52
+ 4. **범용성 (Universality)**: 다양한 언어 및 프레임워크 지원
53
+
54
+ #### Alfred SuperAgent
55
+
56
+ **Alfred**는 12개 AI 에이전트 팀 (Alfred + 11개 전문 에이전트)을 조율하는 중앙 오케스트레이터입니다:
57
+ - **spec-builder** 🏗️: SPEC 작성 (EARS 방식) - Sonnet
58
+ - **implementation-planner** 📋: SPEC 분석 및 구현 전략 수립 - Sonnet
59
+ - **tdd-implementer** 🔬: TDD RED-GREEN-REFACTOR 전문 구현 - Sonnet
60
+ - **quality-gate** 🛡️: TRUST 원칙 통합 검증 - Haiku
61
+ - **doc-syncer** 📖: 문서 동기화 (Living Document) - Haiku
62
+ - **tag-agent** 🏷️: TAG 시스템 관리 - Haiku
63
+ - **git-manager** 🚀: Git 워크플로우 자동화 - Haiku
64
+ - **debug-helper** 🔍: 런타임 오류 진단 - Sonnet
65
+ - **trust-checker** ✅: TRUST 원칙 검증 - Haiku
66
+ - **cc-manager** 🛠️: Claude Code 설정 관리 - Sonnet
67
+ - **project-manager** 📂: 프로젝트 초기화 - Sonnet
28
68
 
29
69
  ## @SPEC:USER-001 주요 사용자층
30
70
 
@@ -1,16 +1,22 @@
1
1
  ---
2
2
  id: STRUCTURE-001
3
- version: 0.1.0
3
+ version: 0.1.1
4
4
  status: active
5
5
  created: 2025-10-01
6
- updated: 2025-10-01
7
- authors: ["@architect"]
6
+ updated: 2025-10-17
7
+ author: @architect
8
+ priority: medium
8
9
  ---
9
10
 
10
11
  # {{PROJECT_NAME}} Structure Design
11
12
 
12
13
  ## HISTORY
13
14
 
15
+ ### v0.1.1 (2025-10-17)
16
+ - **UPDATED**: 템플릿 버전 동기화 (v0.3.8)
17
+ - **AUTHOR**: @Alfred
18
+ - **SECTIONS**: 메타데이터 표준화 (author 필드 단수형, priority 추가)
19
+
14
20
  ### v0.1.0 (2025-10-01)
15
21
  - **INITIAL**: 프로젝트 구조 설계 문서 작성
16
22
  - **AUTHOR**: @architect
@@ -1,16 +1,22 @@
1
1
  ---
2
2
  id: TECH-001
3
- version: 0.1.0
3
+ version: 0.1.1
4
4
  status: active
5
5
  created: 2025-10-01
6
- updated: 2025-10-01
7
- authors: ["@tech-lead"]
6
+ updated: 2025-10-17
7
+ author: @tech-lead
8
+ priority: medium
8
9
  ---
9
10
 
10
11
  # {{PROJECT_NAME}} Technology Stack
11
12
 
12
13
  ## HISTORY
13
14
 
15
+ ### v0.1.1 (2025-10-17)
16
+ - **UPDATED**: 템플릿 버전 동기화 (v0.3.8)
17
+ - **AUTHOR**: @Alfred
18
+ - **SECTIONS**: 메타데이터 표준화 (author 필드 단수형, priority 추가)
19
+
14
20
  ### v0.1.0 (2025-10-01)
15
21
  - **INITIAL**: 프로젝트 기술 스택 문서 작성
16
22
  - **AUTHOR**: @tech-lead