moai-adk 0.8.0__py3-none-any.whl → 0.34.0__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.
- moai_adk/__init__.py +2 -6
- moai_adk/__main__.py +136 -21
- moai_adk/cli/__init__.py +6 -2
- moai_adk/cli/commands/__init__.py +1 -4
- moai_adk/cli/commands/analyze.py +116 -0
- moai_adk/cli/commands/doctor.py +17 -5
- moai_adk/cli/commands/init.py +118 -48
- moai_adk/cli/commands/language.py +248 -0
- moai_adk/cli/commands/status.py +8 -13
- moai_adk/cli/commands/update.py +1978 -149
- moai_adk/cli/main.py +3 -2
- moai_adk/cli/prompts/init_prompts.py +144 -91
- moai_adk/cli/spec_status.py +263 -0
- moai_adk/cli/ui/__init__.py +44 -0
- moai_adk/cli/ui/progress.py +422 -0
- moai_adk/cli/ui/prompts.py +389 -0
- moai_adk/cli/ui/theme.py +129 -0
- moai_adk/cli/worktree/__init__.py +27 -0
- moai_adk/cli/worktree/__main__.py +31 -0
- moai_adk/cli/worktree/cli.py +683 -0
- moai_adk/cli/worktree/exceptions.py +89 -0
- moai_adk/cli/worktree/manager.py +493 -0
- moai_adk/cli/worktree/models.py +65 -0
- moai_adk/cli/worktree/registry.py +422 -0
- moai_adk/core/PHASE2_OPTIMIZATIONS.md +467 -0
- moai_adk/core/__init__.py +0 -1
- moai_adk/core/analysis/__init__.py +9 -0
- moai_adk/core/analysis/session_analyzer.py +400 -0
- moai_adk/core/claude_integration.py +393 -0
- moai_adk/core/command_helpers.py +270 -0
- moai_adk/core/comprehensive_monitoring_system.py +1183 -0
- moai_adk/core/config/__init__.py +6 -0
- moai_adk/core/config/auto_spec_config.py +340 -0
- moai_adk/core/config/migration.py +148 -17
- moai_adk/core/config/unified.py +436 -0
- moai_adk/core/context_manager.py +273 -0
- moai_adk/core/diagnostics/slash_commands.py +0 -1
- moai_adk/core/enterprise_features.py +1404 -0
- moai_adk/core/error_recovery_system.py +1902 -0
- moai_adk/core/event_driven_hook_system.py +1371 -0
- moai_adk/core/git/__init__.py +8 -1
- moai_adk/core/git/branch.py +0 -1
- moai_adk/core/git/branch_manager.py +2 -10
- moai_adk/core/git/checkpoint.py +1 -7
- moai_adk/core/git/commit.py +0 -1
- moai_adk/core/git/conflict_detector.py +413 -0
- moai_adk/core/git/event_detector.py +3 -5
- moai_adk/core/git/manager.py +91 -2
- moai_adk/core/hooks/post_tool_auto_spec_completion.py +901 -0
- moai_adk/core/input_validation_middleware.py +1006 -0
- moai_adk/core/integration/__init__.py +22 -0
- moai_adk/core/integration/engine.py +157 -0
- moai_adk/core/integration/integration_tester.py +226 -0
- moai_adk/core/integration/models.py +88 -0
- moai_adk/core/integration/utils.py +211 -0
- moai_adk/core/issue_creator.py +305 -0
- moai_adk/core/jit_context_loader.py +956 -0
- moai_adk/core/jit_enhanced_hook_manager.py +1987 -0
- moai_adk/core/language_config.py +202 -0
- moai_adk/core/language_config_resolver.py +572 -0
- moai_adk/core/language_validator.py +543 -0
- moai_adk/core/mcp/setup.py +116 -0
- moai_adk/core/merge/__init__.py +9 -0
- moai_adk/core/merge/analyzer.py +481 -0
- moai_adk/core/migration/__init__.py +18 -0
- moai_adk/core/migration/alfred_to_moai_migrator.py +383 -0
- moai_adk/core/migration/backup_manager.py +277 -0
- moai_adk/core/migration/custom_element_scanner.py +358 -0
- moai_adk/core/migration/file_migrator.py +209 -0
- moai_adk/core/migration/interactive_checkbox_ui.py +488 -0
- moai_adk/core/migration/selective_restorer.py +470 -0
- moai_adk/core/migration/template_utils.py +74 -0
- moai_adk/core/migration/user_selection_ui.py +338 -0
- moai_adk/core/migration/version_detector.py +139 -0
- moai_adk/core/migration/version_migrator.py +228 -0
- moai_adk/core/performance/__init__.py +6 -0
- moai_adk/core/performance/cache_system.py +316 -0
- moai_adk/core/performance/parallel_processor.py +116 -0
- moai_adk/core/phase_optimized_hook_scheduler.py +879 -0
- moai_adk/core/project/__init__.py +0 -1
- moai_adk/core/project/backup_utils.py +2 -7
- moai_adk/core/project/checker.py +2 -4
- moai_adk/core/project/detector.py +189 -22
- moai_adk/core/project/initializer.py +218 -27
- moai_adk/core/project/phase_executor.py +416 -44
- moai_adk/core/project/validator.py +7 -32
- moai_adk/core/quality/__init__.py +1 -1
- moai_adk/core/quality/trust_checker.py +37 -101
- moai_adk/core/quality/validators/__init__.py +1 -1
- moai_adk/core/quality/validators/base_validator.py +1 -1
- moai_adk/core/realtime_monitoring_dashboard.py +1724 -0
- moai_adk/core/robust_json_parser.py +611 -0
- moai_adk/core/rollback_manager.py +918 -0
- moai_adk/core/session_manager.py +651 -0
- moai_adk/core/skill_loading_system.py +579 -0
- moai_adk/core/spec/confidence_scoring.py +680 -0
- moai_adk/core/spec/ears_template_engine.py +1247 -0
- moai_adk/core/spec/quality_validator.py +687 -0
- moai_adk/core/spec_status_manager.py +478 -0
- moai_adk/core/template/__init__.py +0 -1
- moai_adk/core/template/backup.py +82 -17
- moai_adk/core/template/config.py +112 -40
- moai_adk/core/template/languages.py +0 -1
- moai_adk/core/template/merger.py +75 -26
- moai_adk/core/template/processor.py +750 -72
- moai_adk/core/template_engine.py +310 -0
- moai_adk/core/template_variable_synchronizer.py +417 -0
- moai_adk/core/unified_permission_manager.py +745 -0
- moai_adk/core/user_behavior_analytics.py +851 -0
- moai_adk/core/version_sync.py +429 -0
- moai_adk/foundation/__init__.py +56 -0
- moai_adk/foundation/backend.py +1027 -0
- moai_adk/foundation/database.py +1115 -0
- moai_adk/foundation/devops.py +1585 -0
- moai_adk/foundation/ears.py +431 -0
- moai_adk/foundation/frontend.py +870 -0
- moai_adk/foundation/git/commit_templates.py +557 -0
- moai_adk/foundation/git.py +376 -0
- moai_adk/foundation/langs.py +484 -0
- moai_adk/foundation/ml_ops.py +1162 -0
- moai_adk/foundation/testing.py +1524 -0
- moai_adk/foundation/trust/trust_principles.py +676 -0
- moai_adk/foundation/trust/validation_checklist.py +1573 -0
- moai_adk/project/__init__.py +0 -0
- moai_adk/project/configuration.py +1084 -0
- moai_adk/project/documentation.py +566 -0
- moai_adk/project/schema.py +447 -0
- moai_adk/statusline/__init__.py +38 -0
- moai_adk/statusline/alfred_detector.py +105 -0
- moai_adk/statusline/config.py +376 -0
- moai_adk/statusline/enhanced_output_style_detector.py +372 -0
- moai_adk/statusline/git_collector.py +190 -0
- moai_adk/statusline/main.py +322 -0
- moai_adk/statusline/metrics_tracker.py +78 -0
- moai_adk/statusline/renderer.py +343 -0
- moai_adk/statusline/update_checker.py +129 -0
- moai_adk/statusline/version_reader.py +741 -0
- moai_adk/templates/.claude/agents/moai/ai-nano-banana.md +670 -0
- moai_adk/templates/.claude/agents/moai/builder-agent.md +474 -0
- moai_adk/templates/.claude/agents/moai/builder-command.md +1172 -0
- moai_adk/templates/.claude/agents/moai/builder-skill.md +666 -0
- moai_adk/templates/.claude/agents/moai/expert-backend.md +899 -0
- moai_adk/templates/.claude/agents/moai/expert-database.md +777 -0
- moai_adk/templates/.claude/agents/moai/expert-debug.md +401 -0
- moai_adk/templates/.claude/agents/moai/expert-devops.md +720 -0
- moai_adk/templates/.claude/agents/moai/expert-frontend.md +734 -0
- moai_adk/templates/.claude/agents/moai/expert-performance.md +657 -0
- moai_adk/templates/.claude/agents/moai/expert-security.md +509 -0
- moai_adk/templates/.claude/agents/moai/expert-testing.md +733 -0
- moai_adk/templates/.claude/agents/moai/expert-uiux.md +1041 -0
- moai_adk/templates/.claude/agents/moai/manager-claude-code.md +432 -0
- moai_adk/templates/.claude/agents/moai/manager-docs.md +573 -0
- moai_adk/templates/.claude/agents/moai/manager-git.md +1020 -0
- moai_adk/templates/.claude/agents/moai/manager-project.md +891 -0
- moai_adk/templates/.claude/agents/moai/manager-quality.md +624 -0
- moai_adk/templates/.claude/agents/moai/manager-spec.md +809 -0
- moai_adk/templates/.claude/agents/moai/manager-strategy.md +780 -0
- moai_adk/templates/.claude/agents/moai/manager-tdd.md +784 -0
- moai_adk/templates/.claude/agents/moai/mcp-context7.md +458 -0
- moai_adk/templates/.claude/agents/moai/mcp-figma.md +1607 -0
- moai_adk/templates/.claude/agents/moai/mcp-notion.md +789 -0
- moai_adk/templates/.claude/agents/moai/mcp-playwright.md +469 -0
- moai_adk/templates/.claude/agents/moai/mcp-sequential-thinking.md +1032 -0
- moai_adk/templates/.claude/commands/moai/0-project.md +1384 -0
- moai_adk/templates/.claude/commands/moai/1-plan.md +1427 -0
- moai_adk/templates/.claude/commands/moai/2-run.md +943 -0
- moai_adk/templates/.claude/commands/moai/3-sync.md +1324 -0
- moai_adk/templates/.claude/commands/moai/9-feedback.md +314 -0
- moai_adk/templates/.claude/hooks/__init__.py +8 -0
- moai_adk/templates/.claude/hooks/moai/__init__.py +8 -0
- moai_adk/templates/.claude/hooks/moai/lib/__init__.py +85 -0
- moai_adk/templates/.claude/hooks/{alfred/core → moai/lib}/checkpoint.py +10 -37
- moai_adk/templates/.claude/hooks/moai/lib/common.py +131 -0
- moai_adk/templates/.claude/hooks/moai/lib/config_manager.py +446 -0
- moai_adk/templates/.claude/hooks/moai/lib/config_validator.py +639 -0
- moai_adk/templates/.claude/hooks/moai/lib/example_config.json +104 -0
- moai_adk/templates/.claude/hooks/moai/lib/git_operations_manager.py +590 -0
- moai_adk/templates/.claude/hooks/moai/lib/language_validator.py +317 -0
- moai_adk/templates/.claude/hooks/moai/lib/models.py +102 -0
- moai_adk/templates/.claude/hooks/moai/lib/path_utils.py +28 -0
- moai_adk/templates/.claude/hooks/moai/lib/project.py +768 -0
- moai_adk/templates/.claude/hooks/moai/lib/test_hooks_improvements.py +443 -0
- moai_adk/templates/.claude/hooks/moai/lib/timeout.py +160 -0
- moai_adk/templates/.claude/hooks/moai/lib/unified_timeout_manager.py +530 -0
- moai_adk/templates/.claude/hooks/moai/session_end__auto_cleanup.py +862 -0
- moai_adk/templates/.claude/hooks/moai/session_start__show_project_info.py +1075 -0
- moai_adk/templates/.claude/output-styles/moai/r2d2.md +560 -0
- moai_adk/templates/.claude/output-styles/moai/yoda.md +359 -0
- moai_adk/templates/.claude/settings.json +78 -50
- moai_adk/templates/.claude/skills/moai-ai-nano-banana/SKILL.md +438 -0
- moai_adk/templates/.claude/skills/moai-ai-nano-banana/examples.md +431 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/SKILL.md +249 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/examples.md +406 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/modules/README.md +44 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/modules/api-documentation.md +130 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/modules/code-documentation.md +152 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/modules/multi-format-output.md +178 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/modules/user-guides.md +147 -0
- moai_adk/templates/.claude/skills/moai-docs-generation/reference.md +328 -0
- moai_adk/templates/.claude/skills/moai-domain-backend/SKILL.md +313 -283
- moai_adk/templates/.claude/skills/moai-domain-backend/examples.md +610 -1525
- moai_adk/templates/.claude/skills/moai-domain-backend/reference.md +423 -619
- moai_adk/templates/.claude/skills/moai-domain-database/SKILL.md +295 -95
- moai_adk/templates/.claude/skills/moai-domain-database/examples.md +817 -16
- moai_adk/templates/.claude/skills/moai-domain-database/modules/README.md +53 -0
- moai_adk/templates/.claude/skills/moai-domain-database/modules/mongodb.md +231 -0
- moai_adk/templates/.claude/skills/moai-domain-database/modules/postgresql.md +169 -0
- moai_adk/templates/.claude/skills/moai-domain-database/modules/redis.md +262 -0
- moai_adk/templates/.claude/skills/moai-domain-database/reference.md +532 -17
- moai_adk/templates/.claude/skills/moai-domain-frontend/SKILL.md +470 -97
- moai_adk/templates/.claude/skills/moai-domain-frontend/examples.md +955 -16
- moai_adk/templates/.claude/skills/moai-domain-frontend/reference.md +651 -18
- moai_adk/templates/.claude/skills/moai-domain-uiux/SKILL.md +455 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/examples.md +560 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/modules/accessibility-wcag.md +260 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/modules/component-architecture.md +228 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/modules/design-system-tokens.md +405 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/modules/icon-libraries.md +401 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/modules/theming-system.md +373 -0
- moai_adk/templates/.claude/skills/moai-domain-uiux/reference.md +243 -0
- moai_adk/templates/.claude/skills/moai-formats-data/SKILL.md +492 -0
- moai_adk/templates/.claude/skills/moai-formats-data/examples.md +804 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/README.md +98 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/SKILL-MODULARIZATION-TEMPLATE.md +278 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/caching-performance.md +459 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/data-validation.md +485 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/json-optimization.md +374 -0
- moai_adk/templates/.claude/skills/moai-formats-data/modules/toon-encoding.md +308 -0
- moai_adk/templates/.claude/skills/moai-formats-data/reference.md +585 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/SKILL.md +202 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/examples.md +732 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/best-practices-checklist.md +616 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-custom-slash-commands-official.md +729 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-hooks-official.md +560 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-iam-official.md +635 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-memory-official.md +543 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-settings-official.md +663 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-skills-official.md +113 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/claude-code-sub-agents-official.md +238 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/complete-configuration-guide.md +175 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/skill-examples.md +1674 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/skill-formatting-guide.md +729 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/sub-agents/sub-agent-examples.md +1513 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/sub-agents/sub-agent-formatting-guide.md +1086 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference/sub-agents/sub-agent-integration-patterns.md +1100 -0
- moai_adk/templates/.claude/skills/moai-foundation-claude/reference.md +209 -0
- moai_adk/templates/.claude/skills/moai-foundation-context/SKILL.md +441 -0
- moai_adk/templates/.claude/skills/moai-foundation-context/examples.md +1048 -0
- moai_adk/templates/.claude/skills/moai-foundation-context/reference.md +246 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/SKILL.md +420 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/examples.md +358 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/README.md +296 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/agents-reference.md +359 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/commands-reference.md +432 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/delegation-patterns.md +757 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/execution-rules.md +687 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/modular-system.md +665 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/progressive-disclosure.md +649 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/spec-first-tdd.md +864 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/token-optimization.md +708 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/modules/trust-5-framework.md +981 -0
- moai_adk/templates/.claude/skills/moai-foundation-core/reference.md +478 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/SKILL.md +315 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/examples.md +228 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/modules/assumption-matrix.md +80 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/modules/cognitive-bias.md +199 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/modules/first-principles.md +140 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/modules/trade-off-analysis.md +154 -0
- moai_adk/templates/.claude/skills/moai-foundation-philosopher/reference.md +157 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/SKILL.md +364 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/examples.md +1232 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/modules/best-practices.md +261 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/modules/integration-patterns.md +194 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/modules/proactive-analysis.md +229 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/modules/trust5-validation.md +169 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/reference.md +1266 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/scripts/quality-gate.sh +668 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/templates/github-actions-quality.yml +481 -0
- moai_adk/templates/.claude/skills/moai-foundation-quality/templates/quality-config.yaml +519 -0
- moai_adk/templates/.claude/skills/moai-lang-cpp/SKILL.md +618 -93
- moai_adk/templates/.claude/skills/moai-lang-csharp/SKILL.md +446 -91
- moai_adk/templates/.claude/skills/moai-lang-elixir/SKILL.md +612 -0
- moai_adk/templates/.claude/skills/moai-lang-flutter/SKILL.md +477 -0
- moai_adk/templates/.claude/skills/moai-lang-flutter/examples.md +1090 -0
- moai_adk/templates/.claude/skills/moai-lang-flutter/reference.md +686 -0
- moai_adk/templates/.claude/skills/moai-lang-go/SKILL.md +346 -94
- moai_adk/templates/.claude/skills/moai-lang-go/examples.md +906 -16
- moai_adk/templates/.claude/skills/moai-lang-go/reference.md +721 -15
- moai_adk/templates/.claude/skills/moai-lang-java/SKILL.md +352 -91
- moai_adk/templates/.claude/skills/moai-lang-java/examples.md +851 -16
- moai_adk/templates/.claude/skills/moai-lang-java/reference.md +278 -18
- moai_adk/templates/.claude/skills/moai-lang-kotlin/SKILL.md +344 -86
- moai_adk/templates/.claude/skills/moai-lang-kotlin/examples.md +993 -16
- moai_adk/templates/.claude/skills/moai-lang-kotlin/reference.md +549 -18
- moai_adk/templates/.claude/skills/moai-lang-php/SKILL.md +617 -96
- moai_adk/templates/.claude/skills/moai-lang-python/SKILL.md +364 -314
- moai_adk/templates/.claude/skills/moai-lang-python/examples.md +849 -496
- moai_adk/templates/.claude/skills/moai-lang-python/reference.md +731 -243
- moai_adk/templates/.claude/skills/moai-lang-r/SKILL.md +545 -89
- moai_adk/templates/.claude/skills/moai-lang-ruby/SKILL.md +650 -87
- moai_adk/templates/.claude/skills/moai-lang-rust/SKILL.md +341 -93
- moai_adk/templates/.claude/skills/moai-lang-rust/examples.md +646 -16
- moai_adk/templates/.claude/skills/moai-lang-rust/reference.md +491 -18
- moai_adk/templates/.claude/skills/moai-lang-scala/SKILL.md +463 -89
- moai_adk/templates/.claude/skills/moai-lang-scala/examples.md +620 -16
- moai_adk/templates/.claude/skills/moai-lang-scala/reference.md +410 -17
- moai_adk/templates/.claude/skills/moai-lang-swift/SKILL.md +486 -112
- moai_adk/templates/.claude/skills/moai-lang-swift/examples.md +905 -16
- moai_adk/templates/.claude/skills/moai-lang-swift/reference.md +659 -17
- moai_adk/templates/.claude/skills/moai-lang-typescript/SKILL.md +333 -92
- moai_adk/templates/.claude/skills/moai-lang-typescript/examples.md +1076 -16
- moai_adk/templates/.claude/skills/moai-lang-typescript/reference.md +718 -21
- moai_adk/templates/.claude/skills/moai-library-mermaid/SKILL.md +300 -0
- moai_adk/templates/.claude/skills/moai-library-mermaid/advanced-patterns.md +465 -0
- moai_adk/templates/.claude/skills/moai-library-mermaid/examples.md +270 -0
- moai_adk/templates/.claude/skills/moai-library-mermaid/optimization.md +440 -0
- moai_adk/templates/.claude/skills/moai-library-mermaid/reference.md +228 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/SKILL.md +319 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/advanced-patterns.md +336 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/examples.md +592 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/advanced-deployment-patterns.md +182 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/advanced-patterns.md +17 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/configuration.md +57 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/content-architecture-optimization.md +162 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/deployment.md +52 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/framework-core-configuration.md +186 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/i18n-setup.md +55 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/modules/mdx-components.md +52 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/optimization.md +303 -0
- moai_adk/templates/.claude/skills/moai-library-nextra/reference.md +379 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/SKILL.md +372 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/examples.md +575 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/modules/advanced-patterns.md +394 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/modules/optimization.md +278 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/modules/shadcn-components.md +457 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/modules/shadcn-theming.md +373 -0
- moai_adk/templates/.claude/skills/moai-library-shadcn/reference.md +74 -0
- moai_adk/templates/.claude/skills/moai-mcp-figma/SKILL.md +402 -0
- moai_adk/templates/.claude/skills/moai-mcp-figma/advanced-patterns.md +607 -0
- moai_adk/templates/.claude/skills/moai-mcp-notion/SKILL.md +300 -0
- moai_adk/templates/.claude/skills/moai-mcp-notion/advanced-patterns.md +537 -0
- moai_adk/templates/.claude/skills/moai-platform-auth0/SKILL.md +290 -0
- moai_adk/templates/.claude/skills/moai-platform-clerk/SKILL.md +390 -0
- moai_adk/templates/.claude/skills/moai-platform-convex/SKILL.md +398 -0
- moai_adk/templates/.claude/skills/moai-platform-firebase-auth/SKILL.md +379 -0
- moai_adk/templates/.claude/skills/moai-platform-firestore/SKILL.md +358 -0
- moai_adk/templates/.claude/skills/moai-platform-neon/SKILL.md +467 -0
- moai_adk/templates/.claude/skills/moai-platform-railway/SKILL.md +377 -0
- moai_adk/templates/.claude/skills/moai-platform-supabase/SKILL.md +466 -0
- moai_adk/templates/.claude/skills/moai-platform-vercel/SKILL.md +482 -0
- moai_adk/templates/.claude/skills/moai-workflow-jit-docs/SKILL.md +449 -0
- moai_adk/templates/.claude/skills/moai-workflow-jit-docs/advanced-patterns.md +379 -0
- moai_adk/templates/.claude/skills/moai-workflow-jit-docs/examples.md +544 -0
- moai_adk/templates/.claude/skills/moai-workflow-jit-docs/optimization.md +286 -0
- moai_adk/templates/.claude/skills/moai-workflow-jit-docs/reference.md +307 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/README.md +190 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/SKILL.md +390 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/__init__.py +520 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/complete_workflow_demo_fixed.py +574 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples/complete_project_setup.py +317 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples/complete_workflow_demo.py +663 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples/config-migration-example.json +190 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples/question-examples.json +175 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples/quick_start.py +196 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/examples.md +547 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/__init__.py +17 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/advanced-patterns.md +158 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/ask_user_integration.py +340 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/batch_questions.py +713 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/config_manager.py +538 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/documentation_manager.py +1336 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/language_initializer.py +730 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/migration_manager.py +608 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/modules/template_optimizer.py +1005 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/reference.md +275 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/schemas/config-schema.json +316 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/schemas/tab_schema.json +1462 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/config-template.json +71 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/doc-templates/product-template.md +44 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/doc-templates/structure-template.md +48 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/doc-templates/tech-template.md +92 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/question-templates/config-manager-setup.json +109 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/question-templates/language-initializer.json +228 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/question-templates/menu-project-config.json +130 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/question-templates/project-batch-questions.json +97 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/templates/question-templates/spec-workflow-setup.json +150 -0
- moai_adk/templates/.claude/skills/moai-workflow-project/test_integration_simple.py +436 -0
- moai_adk/templates/.claude/skills/moai-workflow-spec/SKILL.md +534 -0
- moai_adk/templates/.claude/skills/moai-workflow-spec/examples.md +900 -0
- moai_adk/templates/.claude/skills/moai-workflow-spec/reference.md +704 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/SKILL.md +377 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/examples.md +552 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/modules/code-templates.md +124 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/modules/feedback-templates.md +100 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/modules/template-optimizer.md +138 -0
- moai_adk/templates/.claude/skills/moai-workflow-templates/reference.md +346 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/LICENSE.txt +202 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/SKILL.md +456 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/advanced-patterns.md +576 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/examples/ai-powered-testing.py +294 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/examples/console_logging.py +35 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/examples/element_discovery.py +40 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/examples/static_html_automation.py +34 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/examples.md +672 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/README.md +220 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/ai-debugging.md +845 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/automated-code-review.md +1416 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/performance-optimization.md +1234 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/smart-refactoring.md +1243 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/modules/tdd-context7.md +1260 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/optimization.md +505 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/reference/playwright-best-practices.md +57 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/reference.md +440 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/scripts/with_server.py +218 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/templates/alfred-integration.md +376 -0
- moai_adk/templates/.claude/skills/moai-workflow-testing/workflows/enterprise-testing-workflow.py +571 -0
- moai_adk/templates/.claude/skills/moai-worktree/SKILL.md +411 -0
- moai_adk/templates/.claude/skills/moai-worktree/examples.md +606 -0
- moai_adk/templates/.claude/skills/moai-worktree/modules/integration-patterns.md +982 -0
- moai_adk/templates/.claude/skills/moai-worktree/modules/parallel-development.md +778 -0
- moai_adk/templates/.claude/skills/moai-worktree/modules/worktree-commands.md +646 -0
- moai_adk/templates/.claude/skills/moai-worktree/modules/worktree-management.md +782 -0
- moai_adk/templates/.claude/skills/moai-worktree/reference.md +357 -0
- moai_adk/templates/.git-hooks/pre-commit +128 -0
- moai_adk/templates/.git-hooks/pre-push +365 -0
- moai_adk/templates/.github/workflows/ci-universal.yml +513 -0
- moai_adk/templates/.github/workflows/security-secrets-check.yml +179 -0
- moai_adk/templates/.github/workflows/spec-issue-sync.yml +206 -36
- moai_adk/templates/.gitignore +194 -13
- moai_adk/templates/.mcp.json +31 -0
- moai_adk/templates/.moai/config/config.yaml +58 -0
- moai_adk/templates/.moai/config/questions/_schema.yaml +151 -0
- moai_adk/templates/.moai/config/questions/tab0-init.yaml +251 -0
- moai_adk/templates/.moai/config/questions/tab1-user.yaml +108 -0
- moai_adk/templates/.moai/config/questions/tab2-project.yaml +81 -0
- moai_adk/templates/.moai/config/questions/tab3-git.yaml +634 -0
- moai_adk/templates/.moai/config/questions/tab4-quality.yaml +170 -0
- moai_adk/templates/.moai/config/questions/tab5-system.yaml +87 -0
- moai_adk/templates/.moai/config/sections/git-strategy.yaml +116 -0
- moai_adk/templates/.moai/config/sections/language.yaml +11 -0
- moai_adk/templates/.moai/config/sections/project.yaml +13 -0
- moai_adk/templates/.moai/config/sections/quality.yaml +17 -0
- moai_adk/templates/.moai/config/sections/system.yaml +14 -0
- moai_adk/templates/.moai/config/sections/user.yaml +5 -0
- moai_adk/templates/.moai/config/statusline-config.yaml +92 -0
- moai_adk/templates/.moai/scripts/setup-glm.py +136 -0
- moai_adk/templates/CLAUDE.md +571 -244
- moai_adk/utils/__init__.py +24 -2
- moai_adk/utils/banner.py +9 -13
- moai_adk/utils/common.py +294 -0
- moai_adk/utils/link_validator.py +241 -0
- moai_adk/utils/logger.py +4 -9
- moai_adk/utils/safe_file_reader.py +206 -0
- moai_adk/utils/timeout.py +160 -0
- moai_adk/utils/toon_utils.py +256 -0
- moai_adk/version.py +22 -0
- moai_adk-0.34.0.dist-info/METADATA +2999 -0
- moai_adk-0.34.0.dist-info/RECORD +463 -0
- {moai_adk-0.8.0.dist-info → moai_adk-0.34.0.dist-info}/WHEEL +1 -1
- {moai_adk-0.8.0.dist-info → moai_adk-0.34.0.dist-info}/entry_points.txt +1 -0
- moai_adk/cli/commands/backup.py +0 -80
- moai_adk/templates/.claude/agents/alfred/cc-manager.md +0 -293
- moai_adk/templates/.claude/agents/alfred/debug-helper.md +0 -196
- moai_adk/templates/.claude/agents/alfred/doc-syncer.md +0 -207
- moai_adk/templates/.claude/agents/alfred/git-manager.md +0 -375
- moai_adk/templates/.claude/agents/alfred/implementation-planner.md +0 -343
- moai_adk/templates/.claude/agents/alfred/project-manager.md +0 -246
- moai_adk/templates/.claude/agents/alfred/quality-gate.md +0 -320
- moai_adk/templates/.claude/agents/alfred/skill-factory.md +0 -837
- moai_adk/templates/.claude/agents/alfred/spec-builder.md +0 -272
- moai_adk/templates/.claude/agents/alfred/tag-agent.md +0 -265
- moai_adk/templates/.claude/agents/alfred/tdd-implementer.md +0 -311
- moai_adk/templates/.claude/agents/alfred/trust-checker.md +0 -352
- moai_adk/templates/.claude/commands/alfred/0-project.md +0 -1184
- moai_adk/templates/.claude/commands/alfred/1-plan.md +0 -665
- moai_adk/templates/.claude/commands/alfred/2-run.md +0 -488
- moai_adk/templates/.claude/commands/alfred/3-sync.md +0 -623
- moai_adk/templates/.claude/hooks/alfred/HOOK_SCHEMA_VALIDATION.md +0 -313
- moai_adk/templates/.claude/hooks/alfred/README.md +0 -230
- moai_adk/templates/.claude/hooks/alfred/alfred_hooks.py +0 -174
- moai_adk/templates/.claude/hooks/alfred/core/__init__.py +0 -170
- moai_adk/templates/.claude/hooks/alfred/core/context.py +0 -67
- moai_adk/templates/.claude/hooks/alfred/core/project.py +0 -416
- moai_adk/templates/.claude/hooks/alfred/core/tags.py +0 -198
- moai_adk/templates/.claude/hooks/alfred/handlers/__init__.py +0 -21
- moai_adk/templates/.claude/hooks/alfred/handlers/notification.py +0 -25
- moai_adk/templates/.claude/hooks/alfred/handlers/session.py +0 -161
- moai_adk/templates/.claude/hooks/alfred/handlers/tool.py +0 -90
- moai_adk/templates/.claude/hooks/alfred/handlers/user.py +0 -42
- moai_adk/templates/.claude/hooks/alfred/test_hook_output.py +0 -175
- moai_adk/templates/.claude/output-styles/alfred/agentic-coding.md +0 -640
- moai_adk/templates/.claude/output-styles/alfred/moai-adk-learning.md +0 -696
- moai_adk/templates/.claude/output-styles/alfred/study-with-alfred.md +0 -474
- moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-ears-authoring/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-alfred-git-workflow/SKILL.md +0 -122
- moai_adk/templates/.claude/skills/moai-alfred-git-workflow/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-git-workflow/reference.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/SKILL.md +0 -237
- moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/examples.md +0 -615
- moai_adk/templates/.claude/skills/moai-alfred-interactive-questions/reference.md +0 -653
- moai_adk/templates/.claude/skills/moai-alfred-language-detection/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-alfred-language-detection/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-language-detection/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-spec-metadata-validation/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-tag-scanning/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-alfred-trust-validation/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-alfred-trust-validation/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-alfred-trust-validation/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-cc-agents/SKILL.md +0 -269
- moai_adk/templates/.claude/skills/moai-cc-agents/templates/agent-template.md +0 -32
- moai_adk/templates/.claude/skills/moai-cc-claude-md/SKILL.md +0 -298
- moai_adk/templates/.claude/skills/moai-cc-claude-md/templates/CLAUDE-template.md +0 -26
- moai_adk/templates/.claude/skills/moai-cc-commands/SKILL.md +0 -307
- moai_adk/templates/.claude/skills/moai-cc-commands/templates/command-template.md +0 -21
- moai_adk/templates/.claude/skills/moai-cc-hooks/SKILL.md +0 -252
- moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/pre-bash-check.sh +0 -19
- moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/preserve-permissions.sh +0 -19
- moai_adk/templates/.claude/skills/moai-cc-hooks/scripts/validate-bash-command.py +0 -24
- moai_adk/templates/.claude/skills/moai-cc-mcp-plugins/SKILL.md +0 -199
- moai_adk/templates/.claude/skills/moai-cc-mcp-plugins/templates/settings-mcp-template.json +0 -39
- moai_adk/templates/.claude/skills/moai-cc-memory/SKILL.md +0 -316
- moai_adk/templates/.claude/skills/moai-cc-memory/templates/session-summary-template.md +0 -18
- moai_adk/templates/.claude/skills/moai-cc-settings/SKILL.md +0 -263
- moai_adk/templates/.claude/skills/moai-cc-settings/templates/settings-complete-template.json +0 -30
- moai_adk/templates/.claude/skills/moai-cc-skills/SKILL.md +0 -291
- moai_adk/templates/.claude/skills/moai-cc-skills/templates/SKILL-template.md +0 -15
- moai_adk/templates/.claude/skills/moai-domain-cli-tool/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-cli-tool/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-cli-tool/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-domain-data-science/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-data-science/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-data-science/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-domain-devops/SKILL.md +0 -124
- moai_adk/templates/.claude/skills/moai-domain-devops/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-devops/reference.md +0 -31
- moai_adk/templates/.claude/skills/moai-domain-ml/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-ml/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-ml/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-domain-mobile-app/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-mobile-app/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-mobile-app/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-domain-security/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-security/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-security/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-domain-web-api/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-domain-web-api/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-domain-web-api/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-essentials-debug/SKILL.md +0 -303
- moai_adk/templates/.claude/skills/moai-essentials-debug/examples.md +0 -1064
- moai_adk/templates/.claude/skills/moai-essentials-debug/reference.md +0 -1047
- moai_adk/templates/.claude/skills/moai-essentials-perf/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-essentials-perf/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-essentials-perf/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-essentials-refactor/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-essentials-refactor/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-essentials-refactor/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-essentials-review/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-essentials-review/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-essentials-review/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-foundation-ears/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-foundation-ears/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-ears/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-foundation-git/SKILL.md +0 -122
- moai_adk/templates/.claude/skills/moai-foundation-git/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-git/reference.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-langs/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-foundation-langs/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-langs/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-foundation-specs/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-foundation-specs/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-specs/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-foundation-tags/SKILL.md +0 -113
- moai_adk/templates/.claude/skills/moai-foundation-tags/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-foundation-tags/reference.md +0 -28
- moai_adk/templates/.claude/skills/moai-foundation-trust/SKILL.md +0 -307
- moai_adk/templates/.claude/skills/moai-foundation-trust/examples.md +0 -0
- moai_adk/templates/.claude/skills/moai-foundation-trust/reference.md +0 -1099
- moai_adk/templates/.claude/skills/moai-lang-c/SKILL.md +0 -124
- moai_adk/templates/.claude/skills/moai-lang-c/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-c/reference.md +0 -31
- moai_adk/templates/.claude/skills/moai-lang-cpp/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-cpp/reference.md +0 -31
- moai_adk/templates/.claude/skills/moai-lang-csharp/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-csharp/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-lang-dart/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-lang-dart/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-dart/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-lang-javascript/SKILL.md +0 -125
- moai_adk/templates/.claude/skills/moai-lang-javascript/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-javascript/reference.md +0 -32
- moai_adk/templates/.claude/skills/moai-lang-php/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-php/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-lang-r/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-r/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-lang-ruby/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-ruby/reference.md +0 -31
- moai_adk/templates/.claude/skills/moai-lang-shell/SKILL.md +0 -123
- moai_adk/templates/.claude/skills/moai-lang-shell/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-shell/reference.md +0 -30
- moai_adk/templates/.claude/skills/moai-lang-sql/SKILL.md +0 -124
- moai_adk/templates/.claude/skills/moai-lang-sql/examples.md +0 -29
- moai_adk/templates/.claude/skills/moai-lang-sql/reference.md +0 -31
- moai_adk/templates/.claude/skills/moai-skill-factory/CHECKLIST.md +0 -482
- moai_adk/templates/.claude/skills/moai-skill-factory/EXAMPLES.md +0 -278
- moai_adk/templates/.claude/skills/moai-skill-factory/INTERACTIVE-DISCOVERY.md +0 -524
- moai_adk/templates/.claude/skills/moai-skill-factory/METADATA.md +0 -477
- moai_adk/templates/.claude/skills/moai-skill-factory/PARALLEL-ANALYSIS-REPORT.md +0 -429
- moai_adk/templates/.claude/skills/moai-skill-factory/PYTHON-VERSION-MATRIX.md +0 -391
- moai_adk/templates/.claude/skills/moai-skill-factory/SKILL-FACTORY-WORKFLOW.md +0 -431
- moai_adk/templates/.claude/skills/moai-skill-factory/SKILL-UPDATE-ADVISOR.md +0 -577
- moai_adk/templates/.claude/skills/moai-skill-factory/SKILL.md +0 -271
- moai_adk/templates/.claude/skills/moai-skill-factory/STEP-BY-STEP-GUIDE.md +0 -466
- moai_adk/templates/.claude/skills/moai-skill-factory/STRUCTURE.md +0 -583
- moai_adk/templates/.claude/skills/moai-skill-factory/WEB-RESEARCH.md +0 -526
- moai_adk/templates/.claude/skills/moai-skill-factory/reference.md +0 -465
- moai_adk/templates/.claude/skills/moai-skill-factory/scripts/generate-structure.sh +0 -328
- moai_adk/templates/.claude/skills/moai-skill-factory/scripts/validate-skill.sh +0 -312
- moai_adk/templates/.claude/skills/moai-skill-factory/templates/SKILL_TEMPLATE.md +0 -245
- moai_adk/templates/.claude/skills/moai-skill-factory/templates/examples-template.md +0 -285
- moai_adk/templates/.claude/skills/moai-skill-factory/templates/reference-template.md +0 -278
- moai_adk/templates/.claude/skills/moai-skill-factory/templates/scripts-template.sh +0 -303
- moai_adk/templates/.claude/skills/moai-spec-authoring/README.md +0 -137
- moai_adk/templates/.claude/skills/moai-spec-authoring/SKILL.md +0 -218
- moai_adk/templates/.claude/skills/moai-spec-authoring/examples/validate-spec.sh +0 -161
- moai_adk/templates/.claude/skills/moai-spec-authoring/examples.md +0 -541
- moai_adk/templates/.claude/skills/moai-spec-authoring/reference.md +0 -622
- moai_adk/templates/.github/ISSUE_TEMPLATE/spec.yml +0 -176
- moai_adk/templates/.github/PULL_REQUEST_TEMPLATE.md +0 -69
- moai_adk/templates/.github/workflows/moai-gitflow.yml +0 -256
- moai_adk/templates/.moai/config.json +0 -96
- moai_adk/templates/.moai/memory/CLAUDE-AGENTS-GUIDE.md +0 -208
- moai_adk/templates/.moai/memory/CLAUDE-PRACTICES.md +0 -369
- moai_adk/templates/.moai/memory/CLAUDE-RULES.md +0 -539
- moai_adk/templates/.moai/memory/CONFIG-SCHEMA.md +0 -444
- moai_adk/templates/.moai/memory/DEVELOPMENT-GUIDE.md +0 -344
- moai_adk/templates/.moai/memory/GITFLOW-PROTECTION-POLICY.md +0 -220
- moai_adk/templates/.moai/memory/SKILLS-DESCRIPTION-POLICY.md +0 -218
- moai_adk/templates/.moai/memory/SPEC-METADATA.md +0 -356
- moai_adk/templates/.moai/memory/config-schema.md +0 -444
- moai_adk/templates/.moai/memory/gitflow-protection-policy.md +0 -220
- moai_adk/templates/.moai/memory/spec-metadata.md +0 -356
- moai_adk/templates/.moai/project/product.md +0 -161
- moai_adk/templates/.moai/project/structure.md +0 -156
- moai_adk/templates/.moai/project/tech.md +0 -227
- moai_adk/templates/__init__.py +0 -2
- moai_adk-0.8.0.dist-info/METADATA +0 -1722
- moai_adk-0.8.0.dist-info/RECORD +0 -282
- {moai_adk-0.8.0.dist-info → moai_adk-0.34.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,1722 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: moai-adk
|
|
3
|
-
Version: 0.8.0
|
|
4
|
-
Summary: MoAI Agentic Development Kit - SPEC-First TDD with Alfred SuperAgent & Complete Skills v2.0
|
|
5
|
-
Project-URL: Homepage, https://github.com/modu-ai/moai-adk
|
|
6
|
-
Project-URL: Repository, https://github.com/modu-ai/moai-adk
|
|
7
|
-
Project-URL: Issues, https://github.com/modu-ai/moai-adk/issues
|
|
8
|
-
Project-URL: Changelog, https://github.com/modu-ai/moai-adk/releases
|
|
9
|
-
Author-email: MoAI Team <support@moduai.kr>
|
|
10
|
-
License: MIT
|
|
11
|
-
License-File: LICENSE
|
|
12
|
-
Keywords: agentic,ai,alfred,claude,development,spec-first,tdd,toolkit
|
|
13
|
-
Classifier: Development Status :: 4 - Beta
|
|
14
|
-
Classifier: Intended Audience :: Developers
|
|
15
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
16
|
-
Classifier: Programming Language :: Python :: 3
|
|
17
|
-
Classifier: Programming Language :: Python :: 3.13
|
|
18
|
-
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
19
|
-
Classifier: Topic :: Software Development :: Quality Assurance
|
|
20
|
-
Classifier: Topic :: Software Development :: Testing
|
|
21
|
-
Requires-Python: >=3.13
|
|
22
|
-
Requires-Dist: click>=8.1.0
|
|
23
|
-
Requires-Dist: gitpython>=3.1.45
|
|
24
|
-
Requires-Dist: packaging>=21.0
|
|
25
|
-
Requires-Dist: pyfiglet>=1.0.2
|
|
26
|
-
Requires-Dist: pyyaml>=6.0
|
|
27
|
-
Requires-Dist: questionary>=2.0.0
|
|
28
|
-
Requires-Dist: rich>=13.0.0
|
|
29
|
-
Provides-Extra: dev
|
|
30
|
-
Requires-Dist: mypy>=1.7.0; extra == 'dev'
|
|
31
|
-
Requires-Dist: pytest-cov>=7.0.0; extra == 'dev'
|
|
32
|
-
Requires-Dist: pytest-xdist>=3.8.0; extra == 'dev'
|
|
33
|
-
Requires-Dist: pytest>=8.4.2; extra == 'dev'
|
|
34
|
-
Requires-Dist: ruff>=0.1.0; extra == 'dev'
|
|
35
|
-
Requires-Dist: types-pyyaml>=6.0.0; extra == 'dev'
|
|
36
|
-
Provides-Extra: security
|
|
37
|
-
Requires-Dist: bandit>=1.8.0; extra == 'security'
|
|
38
|
-
Requires-Dist: pip-audit>=2.7.0; extra == 'security'
|
|
39
|
-
Description-Content-Type: text/markdown
|
|
40
|
-
|
|
41
|
-
# MoAI-ADK (Agentic Development Kit)
|
|
42
|
-
|
|
43
|
-
[한국어](README.ko.md) |[English](README.md) | [ไทย](README.th.md) | [日本語](README.ja.md) | [中文](README.zh.md) | [हिन्दी](README.hi.md)
|
|
44
|
-
|
|
45
|
-
[](https://pypi.org/project/moai-adk/)
|
|
46
|
-
[](https://opensource.org/licenses/MIT)
|
|
47
|
-
[](https://www.python.org/)
|
|
48
|
-
[](https://github.com/modu-ai/moai-adk/actions/workflows/moai-gitflow.yml)
|
|
49
|
-
[](https://codecov.io/gh/modu-ai/moai-adk)
|
|
50
|
-
[](https://github.com/modu-ai/moai-adk)
|
|
51
|
-
|
|
52
|
-
> **MoAI-ADK delivers a seamless development workflow that naturally connects SPEC → TEST (TDD) → CODE → DOCUMENTATION with AI.**
|
|
53
|
-
|
|
54
|
-
---
|
|
55
|
-
|
|
56
|
-
## 1. MoAI-ADK at a Glance
|
|
57
|
-
|
|
58
|
-
MoAI-ADK transforms AI-powered development with three core principles. Use the navigation below to jump to the section that matches your needs.
|
|
59
|
-
|
|
60
|
-
If you're **new to MoAI-ADK**, start with "What is MoAI-ADK?".
|
|
61
|
-
If you want to **get started quickly**, jump straight to "5-Minute Quick Start".
|
|
62
|
-
If you've **already installed it and want to understand the concepts**, we recommend "5 Key Concepts".
|
|
63
|
-
|
|
64
|
-
| Question | Jump To |
|
|
65
|
-
| ---------------------------------- | ------------------------------------------------------------------------ |
|
|
66
|
-
| First time here—what is it? | [What is MoAI-ADK?](#what-is-moai-adk) |
|
|
67
|
-
| How do I get started? | [5-Minute Quick Start](#5-minute-quick-start) |
|
|
68
|
-
| What's the basic flow? | [Core Workflow (0 → 3)](#core-workflow-0--3) |
|
|
69
|
-
| What do Plan/Run/Sync commands do? | [Command Cheat Sheet](#command-cheat-sheet) |
|
|
70
|
-
| What are SPEC, TDD, TAG? | [5 Key Concepts](#5-key-concepts) |
|
|
71
|
-
| Tell me about agents/Skills | [Sub-agents & Skills Overview](#sub-agents--skills-overview) |
|
|
72
|
-
| Want to dive deeper? | [Additional Resources](#additional-resources) |
|
|
73
|
-
|
|
74
|
-
---
|
|
75
|
-
|
|
76
|
-
## What is MoAI-ADK?
|
|
77
|
-
|
|
78
|
-
### The Problem: Trust Crisis in AI Development
|
|
79
|
-
|
|
80
|
-
Today, countless developers want help from Claude or ChatGPT, but can't shake one fundamental doubt: **"Can I really trust the code this AI generates?"**
|
|
81
|
-
|
|
82
|
-
The reality looks like this. Ask an AI to "build a login feature" and you'll get syntactically perfect code. But these problems keep repeating:
|
|
83
|
-
|
|
84
|
-
- **Unclear Requirements**: The basic question "What exactly should we build?" remains unanswered. Email/password login? OAuth? 2FA? Everything relies on guessing.
|
|
85
|
-
- **Missing Tests**: Most AIs only test the "happy path". Wrong password? Network error? Three months later, bugs explode in production.
|
|
86
|
-
- **Documentation Drift**: Code gets modified but docs stay the same. The question "Why is this code here?" keeps repeating.
|
|
87
|
-
- **Context Loss**: Even within the same project, you have to explain everything from scratch each time. Project structure, decision rationale, previous attempts—nothing gets recorded.
|
|
88
|
-
- **Impact Tracking Impossible**: When requirements change, you can't track which code is affected.
|
|
89
|
-
|
|
90
|
-
### The Solution: SPEC-First TDD with Alfred SuperAgent
|
|
91
|
-
|
|
92
|
-
**MoAI-ADK** (MoAI Agentic Development Kit) is an open-source framework designed to **systematically solve** these problems.
|
|
93
|
-
|
|
94
|
-
The core principle is simple yet powerful:
|
|
95
|
-
|
|
96
|
-
> **"No tests without code, no SPEC without tests"**
|
|
97
|
-
|
|
98
|
-
More precisely, it's the reverse order:
|
|
99
|
-
|
|
100
|
-
> **"SPEC comes first. No tests without SPEC. No complete documentation without tests and code."**
|
|
101
|
-
|
|
102
|
-
When you follow this order, magical things happen:
|
|
103
|
-
|
|
104
|
-
**1️⃣ Clear Requirements**
|
|
105
|
-
Write SPECs first with the `/alfred:1-plan` command. A vague request like "login feature" transforms into **clear requirements** like "WHEN valid credentials are provided, the system SHALL issue a JWT token". Alfred's spec-builder uses EARS syntax to create professional SPECs in just 3 minutes.
|
|
106
|
-
|
|
107
|
-
**2️⃣ Test Guarantee**
|
|
108
|
-
`/alfred:2-run` automatically performs Test-Driven Development (TDD). It proceeds in RED (failing test) → GREEN (minimal implementation) → REFACTOR (cleanup) order, **guaranteeing 85%+ test coverage**. No more "testing later". Tests drive code creation.
|
|
109
|
-
|
|
110
|
-
**3️⃣ Automatic Documentation Sync**
|
|
111
|
-
A single `/alfred:3-sync` command **synchronizes** all code, tests, and documentation. README, CHANGELOG, API docs, and Living Documents all update automatically. Six months later, code and docs still match.
|
|
112
|
-
|
|
113
|
-
**4️⃣ Tracking with @TAG System**
|
|
114
|
-
Every piece of code, test, and documentation gets a `@TAG:ID`. When requirements change later, one command—`rg "@SPEC:AUTH-001"`—**finds all related tests, implementations, and docs**. You gain confidence during refactoring.
|
|
115
|
-
|
|
116
|
-
**5️⃣ Alfred Remembers Context**
|
|
117
|
-
A team of AI agents collaborate to **remember** your project's structure, decision rationale, and work history. No need to repeat the same questions.
|
|
118
|
-
|
|
119
|
-
### MoAI-ADK's 3 Core Promises
|
|
120
|
-
|
|
121
|
-
For beginners to remember easily, MoAI-ADK's value simplifies to three things:
|
|
122
|
-
|
|
123
|
-
**First, SPEC comes before code**
|
|
124
|
-
Start by clearly defining what to build. Writing SPEC helps discover problems before implementation. Communication costs with teammates drop dramatically.
|
|
125
|
-
|
|
126
|
-
**Second, tests drive code (TDD)**
|
|
127
|
-
Write tests before implementation (RED). Implement minimally to pass tests (GREEN). Then clean up the code (REFACTOR). Result: fewer bugs, confidence in refactoring, code anyone can understand.
|
|
128
|
-
|
|
129
|
-
**Third, documentation and code always match**
|
|
130
|
-
One `/alfred:3-sync` command auto-updates all documentation. README, CHANGELOG, API docs, and Living Documents always sync with code. No more despair when modifying six-month-old code.
|
|
131
|
-
|
|
132
|
-
---
|
|
133
|
-
|
|
134
|
-
## Why Do You Need It?
|
|
135
|
-
|
|
136
|
-
### Real Challenges in AI Development
|
|
137
|
-
|
|
138
|
-
Modern AI-powered development faces various challenges. MoAI-ADK **systematically solves** all these problems:
|
|
139
|
-
|
|
140
|
-
| Concern | Traditional Approach Problem | MoAI-ADK Solution |
|
|
141
|
-
| ------------------------------- | -------------------------------------------------- | ------------------------------------------------------------- |
|
|
142
|
-
| "Can't trust AI code" | Implementation without tests, unclear verification | Enforces SPEC → TEST → CODE order, guarantees 85%+ coverage |
|
|
143
|
-
| "Repeating same explanations" | Context loss, unrecorded project history | Alfred remembers everything, 19 AI team members collaborate |
|
|
144
|
-
| "Hard to write prompts" | Don't know how to write good prompts | `/alfred` commands provide standardized prompts automatically |
|
|
145
|
-
| "Documentation always outdated" | Forget to update docs after code changes | `/alfred:3-sync` auto-syncs with one command |
|
|
146
|
-
| "Don't know what changed where" | Hard to search code, unclear intent | @TAG chain connects SPEC → TEST → CODE → DOC |
|
|
147
|
-
| "Team onboarding takes forever" | New members can't grasp code context | Reading SPEC makes intent immediately clear |
|
|
148
|
-
|
|
149
|
-
### Benefits You Can Experience Right Now
|
|
150
|
-
|
|
151
|
-
From the moment you adopt MoAI-ADK, you'll feel:
|
|
152
|
-
|
|
153
|
-
- **Faster Development**: Clear SPEC reduces round-trip explanation time
|
|
154
|
-
- **Fewer Bugs**: SPEC-based tests catch issues early
|
|
155
|
-
- **Better Code Understanding**: @TAG and SPEC make intent immediately clear
|
|
156
|
-
- **Lower Maintenance Costs**: Code and docs always match
|
|
157
|
-
- **Efficient Team Collaboration**: Clear communication through SPEC and TAG
|
|
158
|
-
|
|
159
|
-
---
|
|
160
|
-
|
|
161
|
-
## 5-Minute Quick Start
|
|
162
|
-
|
|
163
|
-
Now let's start your first project with MoAI-ADK. Follow these 5 steps and in just **5 minutes** you'll have a project with SPEC, TDD, and documentation all connected.
|
|
164
|
-
|
|
165
|
-
### Step 1: Install uv (about 30 seconds)
|
|
166
|
-
|
|
167
|
-
First, install `uv`. `uv` is an ultra-fast Python package manager written in Rust. It's **10+ times faster** than traditional `pip` and works perfectly with MoAI-ADK.
|
|
168
|
-
|
|
169
|
-
```bash
|
|
170
|
-
# macOS/Linux
|
|
171
|
-
curl -LsSf https://astral.sh/uv/install.sh | sh
|
|
172
|
-
|
|
173
|
-
# Windows (PowerShell)
|
|
174
|
-
powershell -c "irm https://astral.sh/uv/install.ps1 | iex"
|
|
175
|
-
|
|
176
|
-
# Verify installation
|
|
177
|
-
uv --version
|
|
178
|
-
# Output: uv 0.x.x
|
|
179
|
-
```
|
|
180
|
-
|
|
181
|
-
**Why uv?** MoAI-ADK is optimized to leverage uv's fast installation speed and stability. Perfect project isolation means no impact on other Python environments.
|
|
182
|
-
|
|
183
|
-
### Step 2: Install MoAI-ADK (about 1 minute)
|
|
184
|
-
|
|
185
|
-
Install MoAI-ADK as a global tool. This won't affect your project dependencies.
|
|
186
|
-
|
|
187
|
-
```bash
|
|
188
|
-
# Install in tool mode (recommended: runs in isolated environment)
|
|
189
|
-
uv tool install moai-adk
|
|
190
|
-
|
|
191
|
-
# Verify installation
|
|
192
|
-
moai-adk --version
|
|
193
|
-
# Output: MoAI-ADK v1.0.0
|
|
194
|
-
```
|
|
195
|
-
|
|
196
|
-
Once installed, you can use the `moai-adk` command anywhere.
|
|
197
|
-
|
|
198
|
-
### Step 3: Create Project (about 1 minute)
|
|
199
|
-
|
|
200
|
-
**To start a new project:**
|
|
201
|
-
|
|
202
|
-
```bash
|
|
203
|
-
moai-adk init my-project
|
|
204
|
-
cd my-project
|
|
205
|
-
```
|
|
206
|
-
|
|
207
|
-
**To add to an existing project:**
|
|
208
|
-
|
|
209
|
-
```bash
|
|
210
|
-
cd your-existing-project
|
|
211
|
-
moai-adk init .
|
|
212
|
-
```
|
|
213
|
-
|
|
214
|
-
This one command automatically generates:
|
|
215
|
-
|
|
216
|
-
```
|
|
217
|
-
my-project/
|
|
218
|
-
├── .moai/ # MoAI-ADK project configuration
|
|
219
|
-
│ ├── config.json # Project settings (language, mode, owner)
|
|
220
|
-
│ ├── project/ # Project information
|
|
221
|
-
│ │ ├── product.md # Product vision and goals
|
|
222
|
-
│ │ ├── structure.md # Directory structure
|
|
223
|
-
│ │ └── tech.md # Tech stack and architecture
|
|
224
|
-
│ ├── memory/ # Alfred's knowledge base (8 files)
|
|
225
|
-
│ │ ├── CLAUDE-AGENTS-GUIDE.md # Sub-agent collaboration guide
|
|
226
|
-
│ │ ├── CLAUDE-RULES.md # Decision rules and standards
|
|
227
|
-
│ │ ├── CLAUDE-PRACTICES.md # Workflow patterns and examples
|
|
228
|
-
│ │ ├── CONFIG-SCHEMA.md # .moai/config.json schema
|
|
229
|
-
│ │ ├── DEVELOPMENT-GUIDE.md # SPEC-First TDD workflow guide
|
|
230
|
-
│ │ ├── GITFLOW-PROTECTION-POLICY.md # Git branch protection
|
|
231
|
-
│ │ ├── SKILLS-DESCRIPTION-POLICY.md # Skills management policy
|
|
232
|
-
│ │ └── SPEC-METADATA.md # SPEC YAML frontmatter standard
|
|
233
|
-
│ ├── specs/ # SPEC files
|
|
234
|
-
│ │ └── SPEC-XXX-001/ # Each SPEC in its own folder
|
|
235
|
-
│ │ └── spec.md # EARS-format specification
|
|
236
|
-
│ └── reports/ # Analysis reports
|
|
237
|
-
├── .claude/ # Claude Code automation
|
|
238
|
-
│ ├── agents/ # 12 Sub-agents
|
|
239
|
-
│ │ └── alfred/
|
|
240
|
-
│ │ ├── project-manager.md # Project initialization
|
|
241
|
-
│ │ ├── spec-builder.md # SPEC authoring (EARS)
|
|
242
|
-
│ │ ├── implementation-planner.md # Architecture & TAG design
|
|
243
|
-
│ │ ├── tdd-implementer.md # RED-GREEN-REFACTOR loop
|
|
244
|
-
│ │ ├── doc-syncer.md # Documentation sync
|
|
245
|
-
│ │ ├── quality-gate.md # TRUST 5 verification
|
|
246
|
-
│ │ ├── tag-agent.md # TAG chain validation
|
|
247
|
-
│ │ ├── trust-checker.md # Code quality checks
|
|
248
|
-
│ │ ├── debug-helper.md # Error analysis & fixes
|
|
249
|
-
│ │ ├── git-manager.md # GitFlow & PR management
|
|
250
|
-
│ │ ├── cc-manager.md # Claude Code optimization
|
|
251
|
-
│ │ └── skill-factory.md # Skills creation & updates
|
|
252
|
-
│ ├── commands/ # 4 Alfred commands
|
|
253
|
-
│ │ └── alfred/
|
|
254
|
-
│ │ ├── 0-project.md # Project initialization
|
|
255
|
-
│ │ ├── 1-plan.md # SPEC authoring
|
|
256
|
-
│ │ ├── 2-run.md # TDD implementation
|
|
257
|
-
│ │ └── 3-sync.md # Documentation sync
|
|
258
|
-
│ ├── skills/ # 58 Claude Skills
|
|
259
|
-
│ │ ├── moai-foundation-* # 6 Foundation tier
|
|
260
|
-
│ │ ├── moai-essentials-* # 4 Essentials tier
|
|
261
|
-
│ │ ├── moai-alfred-* # 7 Alfred tier
|
|
262
|
-
│ │ ├── moai-domain-* # 10 Domain tier
|
|
263
|
-
│ │ ├── moai-lang-* # 18 Language tier
|
|
264
|
-
│ │ ├── moai-cc-* # 8 Claude Code tier
|
|
265
|
-
│ │ ├── moai-skill-factory # 1 Skill Factory
|
|
266
|
-
│ │ └── moai-spec-authoring # 1 SPEC authoring
|
|
267
|
-
│ ├── hooks/ # Event-driven automation
|
|
268
|
-
│ │ └── alfred/
|
|
269
|
-
│ │ └── alfred_hooks.py # 5 hooks (Session, PreTool, etc.)
|
|
270
|
-
│ ├── output-styles/ # Response styles
|
|
271
|
-
│ │ └── alfred/
|
|
272
|
-
│ │ ├── agentic-coding.md # Professional development mode
|
|
273
|
-
│ │ ├── moai-adk-learning.md # Educational explanations mode
|
|
274
|
-
│ │ └── study-with-alfred.md # Interactive learning mode
|
|
275
|
-
│ └── settings.json # Claude Code settings
|
|
276
|
-
├── src/ # Implementation code
|
|
277
|
-
├── tests/ # Test code
|
|
278
|
-
├── docs/ # Auto-generated documentation
|
|
279
|
-
├── CLAUDE.md # Alfred's core directives
|
|
280
|
-
└── README.md
|
|
281
|
-
```
|
|
282
|
-
|
|
283
|
-
### Step 4: Start Alfred in Claude Code (about 2 minutes)
|
|
284
|
-
|
|
285
|
-
Run Claude Code and invoke the Alfred SuperAgent:
|
|
286
|
-
|
|
287
|
-
```bash
|
|
288
|
-
# Run Claude Code
|
|
289
|
-
claude
|
|
290
|
-
```
|
|
291
|
-
|
|
292
|
-
Then enter this in Claude Code's command input:
|
|
293
|
-
|
|
294
|
-
```
|
|
295
|
-
/alfred:0-project
|
|
296
|
-
```
|
|
297
|
-
|
|
298
|
-
This command performs:
|
|
299
|
-
|
|
300
|
-
1. **Collect Project Info**: "Project name?", "Goals?", "Main language?"
|
|
301
|
-
2. **Auto-detect Tech Stack**: Automatically recognizes Python/JavaScript/Go, etc.
|
|
302
|
-
3. **Deploy Skill Packs**: Prepares necessary Skills for your project
|
|
303
|
-
4. **Generate Initial Report**: Project structure, suggested next steps
|
|
304
|
-
|
|
305
|
-
### Step 5: Write First SPEC (about 1 minute)
|
|
306
|
-
|
|
307
|
-
After project initialization completes, write your first feature as a SPEC:
|
|
308
|
-
|
|
309
|
-
```
|
|
310
|
-
/alfred:1-plan "User registration feature"
|
|
311
|
-
```
|
|
312
|
-
|
|
313
|
-
Automatically generated:
|
|
314
|
-
|
|
315
|
-
- `@SPEC:USER-001` - Unique ID assigned
|
|
316
|
-
- `.moai/specs/SPEC-USER-001/spec.md` - Professional SPEC in EARS format
|
|
317
|
-
- `feature/spec-user-001` - Git branch auto-created
|
|
318
|
-
|
|
319
|
-
### Step 6: TDD Implementation (about 3 minutes)
|
|
320
|
-
|
|
321
|
-
Once SPEC is written, implement using TDD:
|
|
322
|
-
|
|
323
|
-
```
|
|
324
|
-
/alfred:2-run USER-001
|
|
325
|
-
```
|
|
326
|
-
|
|
327
|
-
This command handles:
|
|
328
|
-
|
|
329
|
-
- 🔴 **RED**: Automatically write failing test (`@TEST:USER-001`)
|
|
330
|
-
- 🟢 **GREEN**: Minimal implementation to pass test (`@CODE:USER-001`)
|
|
331
|
-
- ♻️ **REFACTOR**: Improve code quality
|
|
332
|
-
|
|
333
|
-
### Step 7: Documentation Sync (about 1 minute)
|
|
334
|
-
|
|
335
|
-
Finally, auto-sync all documentation:
|
|
336
|
-
|
|
337
|
-
```
|
|
338
|
-
/alfred:3-sync
|
|
339
|
-
```
|
|
340
|
-
|
|
341
|
-
Automatically generated/updated:
|
|
342
|
-
|
|
343
|
-
- Living Document (API documentation)
|
|
344
|
-
- README updates
|
|
345
|
-
- CHANGELOG generation
|
|
346
|
-
- @TAG chain validation
|
|
347
|
-
|
|
348
|
-
### Complete!
|
|
349
|
-
|
|
350
|
-
After these 7 steps, everything is ready:
|
|
351
|
-
|
|
352
|
-
✅ Requirements specification (SPEC)
|
|
353
|
-
✅ Test code (85%+ coverage)
|
|
354
|
-
✅ Implementation code (tracked with @TAG)
|
|
355
|
-
✅ API documentation (auto-generated)
|
|
356
|
-
✅ Change history (CHANGELOG)
|
|
357
|
-
✅ Git commit history (RED/GREEN/REFACTOR)
|
|
358
|
-
|
|
359
|
-
**Everything completes in 15 minutes!**
|
|
360
|
-
|
|
361
|
-
### Verify Generated Results
|
|
362
|
-
|
|
363
|
-
Check if the generated results were properly created:
|
|
364
|
-
|
|
365
|
-
```bash
|
|
366
|
-
# 1. Check TAG chain (SPEC → TEST → CODE → DOC)
|
|
367
|
-
rg '@(SPEC|TEST|CODE):USER-001' -n
|
|
368
|
-
|
|
369
|
-
# 2. Run tests
|
|
370
|
-
pytest tests/ -v
|
|
371
|
-
|
|
372
|
-
# 3. Check generated documentation
|
|
373
|
-
cat docs/api/user.md
|
|
374
|
-
cat README.md
|
|
375
|
-
```
|
|
376
|
-
|
|
377
|
-
> 🔍 **Verification Command**: `moai-adk doctor` — Checks if Python/uv versions, `.moai/` structure, and agent/Skills configuration are all ready.
|
|
378
|
-
>
|
|
379
|
-
> ```bash
|
|
380
|
-
> moai-adk doctor
|
|
381
|
-
> ```
|
|
382
|
-
>
|
|
383
|
-
> All green checkmarks mean perfect readiness!
|
|
384
|
-
|
|
385
|
-
---
|
|
386
|
-
|
|
387
|
-
## Understanding CLAUDE.md (Alfred's Configuration Documents)
|
|
388
|
-
|
|
389
|
-
MoAI-ADK's AI coordination is powered by **Alfred**, the MoAI SuperAgent. Alfred's behavior and decision-making are guided by a set of **internal configuration documents** in the `.claude/` directory.
|
|
390
|
-
|
|
391
|
-
### 4-Document Structure
|
|
392
|
-
|
|
393
|
-
When you run MoAI-ADK, Alfred loads configuration from **4 coordinated documents** (stored in your `.claude/` directory):
|
|
394
|
-
|
|
395
|
-
| Document | Size | Purpose | When Alfred Reads It |
|
|
396
|
-
| -------------------------- | ----- | ---------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------- |
|
|
397
|
-
| **CLAUDE.md** | ~7kb | Alfred's identity, core directives, project metadata | At session start (bootstrap) |
|
|
398
|
-
| **CLAUDE-AGENTS-GUIDE.md** | ~14kb | Sub-agent roster (19 members), Skills distribution (55 packs), team structure | When selecting which agent to invoke |
|
|
399
|
-
| **CLAUDE-RULES.md** | ~17kb | Decision-making rules (Skill invocation, Interactive Questions, TAG validation), commit templates, TRUST 5 gates | During each decision point (e.g., when to ask user questions) |
|
|
400
|
-
| **CLAUDE-PRACTICES.md** | ~8kb | Practical workflows, context engineering (JIT retrieval), on-demand agent patterns, real examples | During implementation phase |
|
|
401
|
-
|
|
402
|
-
### Why This Structure Matters
|
|
403
|
-
|
|
404
|
-
**For Developers**: These documents define how Alfred interprets your requirements and orchestrates development. Understanding them helps you:
|
|
405
|
-
|
|
406
|
-
- Write clearer specifications that Alfred understands better
|
|
407
|
-
- Know which agent/Skill will be invoked for your request
|
|
408
|
-
- Understand decision points where Alfred might ask you questions
|
|
409
|
-
|
|
410
|
-
**For AI**: Progressive disclosure means:
|
|
411
|
-
|
|
412
|
-
- **Session Start**: Load only CLAUDE.md (7kb) — minimal overhead
|
|
413
|
-
- **On-Demand**: Load CLAUDE-AGENTS-GUIDE.md, CLAUDE-RULES.md, CLAUDE-PRACTICES.md only when needed
|
|
414
|
-
- **Result**: Faster session boot, cleaner context, clear decision logic
|
|
415
|
-
|
|
416
|
-
### Example: What Happens When You Run `/alfred:2-run`
|
|
417
|
-
|
|
418
|
-
1. **CLAUDE.md** is already loaded → Alfred knows its role and project context
|
|
419
|
-
2. Alfred checks **CLAUDE-RULES.md** → "Should I ask user questions? Which Skill applies here?"
|
|
420
|
-
3. If implementing code: Alfred loads **CLAUDE-AGENTS-GUIDE.md** → "Which agent executes TDD?"
|
|
421
|
-
4. During implementation: Alfred loads **CLAUDE-PRACTICES.md** → "How do I structure the RED → GREEN → REFACTOR workflow?"
|
|
422
|
-
|
|
423
|
-
### Customizing Alfred's Behavior
|
|
424
|
-
|
|
425
|
-
**Most developers never modify these files.** MoAI-ADK ships with optimized defaults.
|
|
426
|
-
|
|
427
|
-
**If you need to customize Alfred's behavior** (rare), edit these documents in your project's `.claude/` directory:
|
|
428
|
-
|
|
429
|
-
- Add new decision rules in **CLAUDE-RULES.md**
|
|
430
|
-
- Adjust agent selection logic in **CLAUDE-AGENTS-GUIDE.md**
|
|
431
|
-
- Document team-specific workflows in **CLAUDE-PRACTICES.md**
|
|
432
|
-
|
|
433
|
-
> ⚠️ **Important**: These are internal configuration files for Alfred, not user guides. Keep them concise and decision-focused. Most teams don't modify them.
|
|
434
|
-
|
|
435
|
-
---
|
|
436
|
-
|
|
437
|
-
## Alfred's Memory Files (.moai/memory/)
|
|
438
|
-
|
|
439
|
-
Alfred's knowledge base consists of **14 memory files** stored in `.moai/memory/`. These files define standards, rules, and guidelines that Alfred and Sub-agents reference during development.
|
|
440
|
-
|
|
441
|
-
### Core Knowledge Base (14 Files)
|
|
442
|
-
|
|
443
|
-
**Core Guides (3 files)**:
|
|
444
|
-
|
|
445
|
-
| File | Size | Purpose | Who Uses It |
|
|
446
|
-
| ------------------------ | ----- | ---------------------------------------- | ---------------------- |
|
|
447
|
-
| `CLAUDE-AGENTS-GUIDE.md` | ~15KB | Sub-agent selection & collaboration | Alfred, Developers |
|
|
448
|
-
| `CLAUDE-PRACTICES.md` | ~12KB | Real-world workflow examples & patterns | Alfred, All Sub-agents |
|
|
449
|
-
| `CLAUDE-RULES.md` | ~19KB | Skill/TAG/Git rules & decision standards | Alfred, All Sub-agents |
|
|
450
|
-
|
|
451
|
-
**Standards (4 files)**:
|
|
452
|
-
|
|
453
|
-
| File | Size | Purpose | Who Uses It |
|
|
454
|
-
| ------------------------------ | ----- | ------------------------------------- | -------------------------- |
|
|
455
|
-
| `CONFIG-SCHEMA.md` | ~12KB | `.moai/config.json` schema definition | project-manager |
|
|
456
|
-
| `DEVELOPMENT-GUIDE.md` | ~14KB | SPEC-First TDD workflow guide | All Sub-agents, Developers |
|
|
457
|
-
| `GITFLOW-PROTECTION-POLICY.md` | ~6KB | Git branch protection policy | git-manager |
|
|
458
|
-
| `SPEC-METADATA.md` | ~9KB | SPEC YAML frontmatter standard (SSOT) | spec-builder, doc-syncer |
|
|
459
|
-
|
|
460
|
-
**Implementation Analysis (7 files)**: Internal reports and policy documents for Skills management, workflow improvements, and team integration analysis.
|
|
461
|
-
|
|
462
|
-
### When Are Memory Files Loaded?
|
|
463
|
-
|
|
464
|
-
**Session Start (Always)**:
|
|
465
|
-
|
|
466
|
-
- `CLAUDE.md`
|
|
467
|
-
- `CLAUDE-AGENTS-GUIDE.md`
|
|
468
|
-
- `CLAUDE-RULES.md`
|
|
469
|
-
|
|
470
|
-
**Just-In-Time (Command Execution)**:
|
|
471
|
-
|
|
472
|
-
- `/alfred:1-plan` → `SPEC-METADATA.md`, `DEVELOPMENT-GUIDE.md`
|
|
473
|
-
- `/alfred:2-run` → `DEVELOPMENT-GUIDE.md`
|
|
474
|
-
- `/alfred:3-sync` → `DEVELOPMENT-GUIDE.md`
|
|
475
|
-
|
|
476
|
-
**Conditional (On-Demand)**:
|
|
477
|
-
|
|
478
|
-
- Config changes → `CONFIG-SCHEMA.md`
|
|
479
|
-
- Git operations → `GITFLOW-PROTECTION-POLICY.md`
|
|
480
|
-
- Skill creation → `SKILLS-DESCRIPTION-POLICY.md`
|
|
481
|
-
|
|
482
|
-
### Why Memory Files Matter
|
|
483
|
-
|
|
484
|
-
1. **Single Source of Truth (SSOT)**: Each standard is defined exactly once, eliminating conflicts
|
|
485
|
-
2. **Context Efficiency**: JIT loading reduces initial session overhead (only 3 files at start)
|
|
486
|
-
3. **Consistent Decisions**: All Sub-agents follow the same rules from `CLAUDE-RULES.md`
|
|
487
|
-
4. **Traceability**: SPEC metadata, @TAG rules, and Git standards all documented
|
|
488
|
-
|
|
489
|
-
### Usage Frequency
|
|
490
|
-
|
|
491
|
-
| Priority | Files | Usage Pattern |
|
|
492
|
-
| --------- | -------------------------------------------------- | ------------------- |
|
|
493
|
-
| Very High | `CLAUDE-RULES.md` | Every decision |
|
|
494
|
-
| High | `DEVELOPMENT-GUIDE.md`, `SPEC-METADATA.md` | All commands |
|
|
495
|
-
| Medium | `CLAUDE-AGENTS-GUIDE.md`, `CLAUDE-PRACTICES.md` | Agent coordination |
|
|
496
|
-
| Low | `CONFIG-SCHEMA.md`, `GITFLOW-PROTECTION-POLICY.md` | Specific operations |
|
|
497
|
-
|
|
498
|
-
> 📚 **Complete Analysis**: See `.moai/memory/MEMORY-FILES-USAGE.md` for comprehensive documentation on who uses each file, when they're loaded, where they're referenced, and why they're needed.
|
|
499
|
-
|
|
500
|
-
---
|
|
501
|
-
|
|
502
|
-
## Keeping MoAI-ADK Up-to-Date
|
|
503
|
-
|
|
504
|
-
### Check Version
|
|
505
|
-
|
|
506
|
-
```bash
|
|
507
|
-
# Check currently installed version
|
|
508
|
-
moai-adk --version
|
|
509
|
-
|
|
510
|
-
# Check latest version on PyPI
|
|
511
|
-
uv tool list # Check current version of moai-adk
|
|
512
|
-
```
|
|
513
|
-
|
|
514
|
-
### Upgrading
|
|
515
|
-
|
|
516
|
-
#### Method 1: MoAI-ADK Built-in Update Command (Recommended - 3-Stage Workflow, v0.6.3+)
|
|
517
|
-
<!-- @DOC:UPDATE-REFACTOR-002-003 -->
|
|
518
|
-
|
|
519
|
-
MoAI-ADK's `update` command provides **automatic tool detection** and **intelligent 3-stage workflow** with **70-80% performance improvement** for templates already synchronized:
|
|
520
|
-
|
|
521
|
-
**Basic 3-Stage Workflow** (automatic tool detection):
|
|
522
|
-
```bash
|
|
523
|
-
# Stage 1: Package version check
|
|
524
|
-
# Shows version comparison, upgrades if needed
|
|
525
|
-
moai-adk update
|
|
526
|
-
|
|
527
|
-
# Stage 2: Config version comparison (NEW in v0.6.3)
|
|
528
|
-
# Compares package template version with project config
|
|
529
|
-
# If already synchronized, exits early (70-80% faster!)
|
|
530
|
-
|
|
531
|
-
# Stage 3: Template sync (only if needed)
|
|
532
|
-
# Creates backup → Syncs templates → Updates config
|
|
533
|
-
# Message: "✓ Templates synced!" or "Templates are up to date!"
|
|
534
|
-
```
|
|
535
|
-
|
|
536
|
-
**Check for updates without applying them**:
|
|
537
|
-
```bash
|
|
538
|
-
# Preview available updates (shows package & config versions)
|
|
539
|
-
moai-adk update --check
|
|
540
|
-
```
|
|
541
|
-
|
|
542
|
-
**Templates-only mode** (skip package upgrade, useful for manual upgrades):
|
|
543
|
-
```bash
|
|
544
|
-
# If you manually upgraded the package, sync templates only
|
|
545
|
-
# Still performs Stage 2 config comparison for accuracy
|
|
546
|
-
moai-adk update --templates-only
|
|
547
|
-
```
|
|
548
|
-
|
|
549
|
-
**CI/CD mode** (auto-confirm all prompts):
|
|
550
|
-
```bash
|
|
551
|
-
# Auto-confirms all prompts - useful in automated pipelines
|
|
552
|
-
# Runs all 3 stages automatically
|
|
553
|
-
moai-adk update --yes
|
|
554
|
-
```
|
|
555
|
-
|
|
556
|
-
**Force mode** (skip backup creation):
|
|
557
|
-
```bash
|
|
558
|
-
# Update without creating backup (use with caution)
|
|
559
|
-
# Still performs config version comparison
|
|
560
|
-
moai-adk update --force
|
|
561
|
-
```
|
|
562
|
-
|
|
563
|
-
**How the 3-Stage Workflow Works** (v0.6.3):
|
|
564
|
-
|
|
565
|
-
| Stage | Condition | Action | Performance |
|
|
566
|
-
|-------|-----------|--------|-------------|
|
|
567
|
-
| **Stage 1** | Package: current < latest | Detects installer → Upgrades package | ~20-30s |
|
|
568
|
-
| **Stage 2** | Config: compare versions | Reads template_version from config.json | ~1s ⚡ **NEW!** |
|
|
569
|
-
| **Stage 3** | Config: package > project | Creates backup → Syncs templates (if needed) | ~10-15s |
|
|
570
|
-
|
|
571
|
-
**Performance Improvement** (v0.6.3):
|
|
572
|
-
- **Same version case**: 12-18s → 3-4s (**70-80% faster!** ⚡)
|
|
573
|
-
- Stage 1: ~1s (version check)
|
|
574
|
-
- Stage 2: ~1s (config comparison)
|
|
575
|
-
- Stage 3: **skipped** (already synchronized)
|
|
576
|
-
|
|
577
|
-
- **CI/CD repeated runs**: **-30% cost reduction**
|
|
578
|
-
- First run: Full sync
|
|
579
|
-
- Subsequent runs: Only version checks (~3-4s)
|
|
580
|
-
|
|
581
|
-
**Why 3 stages?**
|
|
582
|
-
Python processes cannot upgrade themselves while running. The 3-stage workflow is necessary for safety AND performance:
|
|
583
|
-
1. **Stage 1**: Package upgrade detection (compares with PyPI)
|
|
584
|
-
2. **Stage 2**: Template sync necessity detection (compares config versions) - NEW v0.6.3
|
|
585
|
-
3. **Stage 3**: Templates and configuration sync (only if necessary)
|
|
586
|
-
|
|
587
|
-
**Key Improvement in v0.6.3**:
|
|
588
|
-
Previously, all updates would sync templates even if nothing changed. Now, config version comparison (Stage 2) detects when templates are already current, **skipping Stage 3 entirely** (saves 10-15 seconds!)
|
|
589
|
-
|
|
590
|
-
**Config Version Tracking**:
|
|
591
|
-
```json
|
|
592
|
-
{
|
|
593
|
-
"project": {
|
|
594
|
-
"template_version": "0.6.3" // Tracks last synchronized template version
|
|
595
|
-
}
|
|
596
|
-
}
|
|
597
|
-
```
|
|
598
|
-
This field allows MoAI-ADK to accurately determine if templates need synchronization without re-syncing everything.
|
|
599
|
-
|
|
600
|
-
#### Method 2: Upgrade with uv tool command
|
|
601
|
-
|
|
602
|
-
**Upgrade specific tool (recommended)**
|
|
603
|
-
|
|
604
|
-
```bash
|
|
605
|
-
# Upgrade only moai-adk to latest version
|
|
606
|
-
uv tool upgrade moai-adk
|
|
607
|
-
```
|
|
608
|
-
|
|
609
|
-
**Upgrade all installed tools**
|
|
610
|
-
|
|
611
|
-
```bash
|
|
612
|
-
# Upgrade all uv tool installations to latest versions
|
|
613
|
-
uv tool update
|
|
614
|
-
```
|
|
615
|
-
|
|
616
|
-
**Install specific version**
|
|
617
|
-
|
|
618
|
-
```bash
|
|
619
|
-
# Reinstall specific version (e.g., 0.4.2)
|
|
620
|
-
uv tool install moai-adk==0.4.2
|
|
621
|
-
```
|
|
622
|
-
|
|
623
|
-
### Verify After Update
|
|
624
|
-
|
|
625
|
-
```bash
|
|
626
|
-
# 1. Check installed version
|
|
627
|
-
moai-adk --version
|
|
628
|
-
|
|
629
|
-
# 2. Verify project works correctly
|
|
630
|
-
moai-adk doctor
|
|
631
|
-
|
|
632
|
-
# 3. Check updated features in Alfred
|
|
633
|
-
cd your-project
|
|
634
|
-
claude
|
|
635
|
-
/alfred:0-project # Verify new features like language selection
|
|
636
|
-
```
|
|
637
|
-
|
|
638
|
-
> 💡 **New 2-Stage Update Workflow**:
|
|
639
|
-
>
|
|
640
|
-
> - **Stage 1**: `moai-adk update` detects installer (uv tool, pipx, or pip) and upgrades package
|
|
641
|
-
> - **Stage 2**: `moai-adk update` again to sync templates, config, and agent/Skills
|
|
642
|
-
> - **Smart detection**: Auto-detects whether package upgrade is needed based on version comparison
|
|
643
|
-
> - **CI/CD ready**: Use `moai-adk update --yes` for fully automated updates in pipelines
|
|
644
|
-
> - **Manual upgrade path**: Use `moai-adk update --templates-only` after manually upgrading the package
|
|
645
|
-
> - **Rollback safe**: Automatic backups in `.moai-backups/` before template sync
|
|
646
|
-
|
|
647
|
-
---
|
|
648
|
-
|
|
649
|
-
## Core Workflow (0 → 3)
|
|
650
|
-
|
|
651
|
-
Alfred iteratively develops projects with four commands.
|
|
652
|
-
|
|
653
|
-
```mermaid
|
|
654
|
-
%%{init: {'theme':'neutral'}}%%
|
|
655
|
-
graph TD
|
|
656
|
-
Start([User Request]) --> Init[0. Init<br/>/alfred:0-project]
|
|
657
|
-
Init --> Plan[1. Plan & SPEC<br/>/alfred:1-plan]
|
|
658
|
-
Plan --> Run[2. Run & TDD<br/>/alfred:2-run]
|
|
659
|
-
Run --> Sync[3. Sync & Docs<br/>/alfred:3-sync]
|
|
660
|
-
Sync --> Plan
|
|
661
|
-
Sync -.-> End([Release])
|
|
662
|
-
```
|
|
663
|
-
|
|
664
|
-
### 0. INIT — Project Preparation
|
|
665
|
-
|
|
666
|
-
- Questions about project introduction, target, language, mode (locale)
|
|
667
|
-
- Auto-generates `.moai/config.json`, `.moai/project/*` 5 documents
|
|
668
|
-
- Language detection and recommended Skill Pack deployment (Foundation + Essentials + Domain/Language)
|
|
669
|
-
- Template cleanup, initial Git/backup checks
|
|
670
|
-
|
|
671
|
-
### 1. PLAN — Agree on What to Build
|
|
672
|
-
|
|
673
|
-
- Write SPEC with EARS template (includes `@SPEC:ID`)
|
|
674
|
-
- Organize Plan Board, implementation ideas, risk factors
|
|
675
|
-
- Auto-create branch/initial Draft PR in Team mode
|
|
676
|
-
|
|
677
|
-
### 2. RUN — Test-Driven Development (TDD)
|
|
678
|
-
|
|
679
|
-
- Phase 1 `implementation-planner`: Design libraries, folders, TAG layout
|
|
680
|
-
- Phase 2 `tdd-implementer`: RED (failing test) → GREEN (minimal implementation) → REFACTOR (cleanup)
|
|
681
|
-
- quality-gate verifies TRUST 5 principles, coverage changes
|
|
682
|
-
|
|
683
|
-
### 3. SYNC — Documentation & PR Organization
|
|
684
|
-
|
|
685
|
-
- Sync Living Document, README, CHANGELOG, etc.
|
|
686
|
-
- Validate TAG chain and recover orphan TAGs
|
|
687
|
-
- Generate Sync Report, transition Draft → Ready for Review, support `--auto-merge` option
|
|
688
|
-
|
|
689
|
-
---
|
|
690
|
-
|
|
691
|
-
## Command Cheat Sheet
|
|
692
|
-
|
|
693
|
-
| Command | What it does | Key Outputs |
|
|
694
|
-
| ------------------------------ | ----------------------------------------------------------------- | ------------------------------------------------------------------ |
|
|
695
|
-
| `/alfred:0-project` | Collect project description, create config/docs, recommend Skills | `.moai/config.json`, `.moai/project/*`, initial report |
|
|
696
|
-
| `/alfred:1-plan <description>` | Analyze requirements, draft SPEC, write Plan Board | `.moai/specs/SPEC-*/spec.md`, plan/acceptance docs, feature branch |
|
|
697
|
-
| `/alfred:2-run <SPEC-ID>` | Execute TDD, test/implement/refactor, verify quality | `tests/`, `src/` implementation, quality report, TAG connection |
|
|
698
|
-
| `/alfred:3-sync` | Sync docs/README/CHANGELOG, organize TAG/PR status | `docs/`, `.moai/reports/sync-report.md`, Ready PR |
|
|
699
|
-
|
|
700
|
-
> ❗ All commands maintain **Phase 0 (optional) → Phase 1 → Phase 2 → Phase 3** cycle structure. Alfred automatically reports execution status and next-step suggestions.
|
|
701
|
-
|
|
702
|
-
---
|
|
703
|
-
|
|
704
|
-
## SPEC GitHub Issue Automation
|
|
705
|
-
|
|
706
|
-
MoAI-ADK now provides **automatic GitHub Issue synchronization** from SPEC documents, seamlessly integrating requirements with issue tracking in team mode.
|
|
707
|
-
|
|
708
|
-
### How It Works
|
|
709
|
-
|
|
710
|
-
When you create a SPEC document using `/alfred:1-plan` and push it to a feature branch:
|
|
711
|
-
|
|
712
|
-
1. **GitHub Actions Workflow** automatically triggers on PR events
|
|
713
|
-
2. **SPEC Metadata** (ID, version, status, priority) is extracted from YAML frontmatter
|
|
714
|
-
3. **GitHub Issue** is created with full SPEC content and metadata table
|
|
715
|
-
4. **PR Comment** is added with a link to the created issue
|
|
716
|
-
5. **Labels** are automatically applied based on priority (critical, high, medium, low)
|
|
717
|
-
|
|
718
|
-
### What Gets Synchronized
|
|
719
|
-
|
|
720
|
-
**From SPEC to GitHub Issue:**
|
|
721
|
-
- **SPEC ID**: Unique identifier (e.g., AUTH-001, USER-001)
|
|
722
|
-
- **Version**: Semantic versioning (v0.1.0, v1.0.0)
|
|
723
|
-
- **Status**: draft, in-review, in-progress, completed, stable
|
|
724
|
-
- **Priority**: critical, high, medium, low (becomes GitHub label)
|
|
725
|
-
- **Full Content**: EARS requirements, acceptance criteria, dependencies
|
|
726
|
-
|
|
727
|
-
**GitHub Issue Format:**
|
|
728
|
-
```markdown
|
|
729
|
-
# [SPEC-AUTH-001] User Authentication (v1.0.0)
|
|
730
|
-
|
|
731
|
-
## SPEC Metadata
|
|
732
|
-
|
|
733
|
-
| Field | Value |
|
|
734
|
-
|-------|-------|
|
|
735
|
-
| **ID** | AUTH-001 |
|
|
736
|
-
| **Version** | v1.0.0 |
|
|
737
|
-
| **Status** | in-progress |
|
|
738
|
-
| **Priority** | high |
|
|
739
|
-
|
|
740
|
-
## SPEC Document
|
|
741
|
-
|
|
742
|
-
[Full SPEC content from .moai/specs/SPEC-AUTH-001/spec.md]
|
|
743
|
-
|
|
744
|
-
---
|
|
745
|
-
|
|
746
|
-
📎 **Branch**: `feature/AUTH-001`
|
|
747
|
-
🔗 **PR**: #123
|
|
748
|
-
📝 **Auto-synced**: This issue is automatically synchronized from the SPEC document
|
|
749
|
-
```
|
|
750
|
-
|
|
751
|
-
### Features
|
|
752
|
-
|
|
753
|
-
✅ **Automatic Issue Creation**: GitHub Issue created on every PR with SPEC file changes
|
|
754
|
-
✅ **Metadata Extraction**: ID, version, status, priority automatically parsed from YAML frontmatter
|
|
755
|
-
✅ **PR Integration**: Issue linked to PR via automatic comment
|
|
756
|
-
✅ **Label Management**: Priority-based labels (critical, high, medium, low) auto-applied
|
|
757
|
-
✅ **CodeRabbit Review** (local only): AI-powered SPEC quality validation in local development
|
|
758
|
-
|
|
759
|
-
### Setup Requirements
|
|
760
|
-
|
|
761
|
-
**GitHub Actions Workflow**: `.github/workflows/spec-issue-sync.yml`
|
|
762
|
-
**GitHub Issue Template**: `.github/ISSUE_TEMPLATE/spec.yml`
|
|
763
|
-
**GitHub Labels**: `spec`, `planning`, `critical`, `high`, `medium`, `low`
|
|
764
|
-
|
|
765
|
-
All templates are automatically installed with MoAI-ADK and synced during `moai-adk init`.
|
|
766
|
-
|
|
767
|
-
### CodeRabbit Integration (Local Only)
|
|
768
|
-
|
|
769
|
-
When working in your **local development environment**, CodeRabbit provides automatic SPEC quality review:
|
|
770
|
-
|
|
771
|
-
**What CodeRabbit Reviews:**
|
|
772
|
-
- ✅ All 7 required metadata fields (id, version, status, created, updated, author, priority)
|
|
773
|
-
- ✅ HISTORY section formatting and chronological order
|
|
774
|
-
- ✅ EARS requirements structure (Ubiquitous, Event-driven, State-driven, Constraints, Optional)
|
|
775
|
-
- ✅ Acceptance criteria in Given-When-Then format
|
|
776
|
-
- ✅ @TAG system compliance for traceability
|
|
777
|
-
|
|
778
|
-
**CodeRabbit Configuration**: `.coderabbit.yaml` (local only, not distributed in packages)
|
|
779
|
-
|
|
780
|
-
> **Note**: CodeRabbit integration is available only in local development environments. Package users receive core GitHub Issue automation without CodeRabbit review.
|
|
781
|
-
|
|
782
|
-
### Workflow Example
|
|
783
|
-
|
|
784
|
-
```bash
|
|
785
|
-
# 1. Create SPEC
|
|
786
|
-
/alfred:1-plan "User authentication feature"
|
|
787
|
-
|
|
788
|
-
# 2. SPEC file created at .moai/specs/SPEC-AUTH-001/spec.md
|
|
789
|
-
# 3. Feature branch created: feature/SPEC-AUTH-001
|
|
790
|
-
# 4. Draft PR created (team mode)
|
|
791
|
-
|
|
792
|
-
# 5. GitHub Actions automatically:
|
|
793
|
-
# - Parses SPEC metadata
|
|
794
|
-
# - Creates GitHub Issue #45
|
|
795
|
-
# - Adds PR comment: "✅ SPEC GitHub Issue Created - Issue: #45"
|
|
796
|
-
# - Applies labels: spec, planning, high
|
|
797
|
-
|
|
798
|
-
# 6. CodeRabbit reviews SPEC (local only):
|
|
799
|
-
# - Validates metadata
|
|
800
|
-
# - Checks EARS requirements
|
|
801
|
-
# - Provides quality score
|
|
802
|
-
|
|
803
|
-
# 7. Continue with TDD implementation
|
|
804
|
-
/alfred:2-run AUTH-001
|
|
805
|
-
```
|
|
806
|
-
|
|
807
|
-
### Benefits
|
|
808
|
-
|
|
809
|
-
1. **Centralized Tracking**: All SPEC requirements tracked as GitHub Issues
|
|
810
|
-
2. **Team Visibility**: Non-technical stakeholders can follow progress via Issues
|
|
811
|
-
3. **Automated Workflow**: No manual issue creation—fully automated from SPEC to Issue
|
|
812
|
-
4. **Traceability**: Direct link between SPEC files, Issues, PRs, and implementation
|
|
813
|
-
5. **Quality Assurance**: CodeRabbit validates SPEC quality before implementation (local only)
|
|
814
|
-
|
|
815
|
-
---
|
|
816
|
-
|
|
817
|
-
## 5 Key Concepts
|
|
818
|
-
|
|
819
|
-
MoAI-ADK consists of 5 key concepts. Each concept connects to the others, and together they create a powerful development system.
|
|
820
|
-
|
|
821
|
-
### Key Concept 1: SPEC-First (Requirements First)
|
|
822
|
-
|
|
823
|
-
**Metaphor**: Like building a house without an architect, you shouldn't code without a blueprint.
|
|
824
|
-
|
|
825
|
-
**Core Idea**: Before implementation, **clearly define "what to build"**. This isn't just documentation—it's an **executable spec** that both teams and AI can understand.
|
|
826
|
-
|
|
827
|
-
**EARS Syntax 5 Patterns**:
|
|
828
|
-
|
|
829
|
-
1. **Ubiquitous** (basic function): "The system SHALL provide JWT-based authentication"
|
|
830
|
-
2. **Event-driven** (conditional): "WHEN valid credentials are provided, the system SHALL issue a token"
|
|
831
|
-
3. **State-driven** (during state): "WHILE the user is authenticated, the system SHALL allow access to protected resources"
|
|
832
|
-
4. **Optional** (optional): "WHERE a refresh token exists, the system MAY issue a new token"
|
|
833
|
-
5. **Constraints** (constraints): "Token expiration time SHALL NOT exceed 15 minutes"
|
|
834
|
-
|
|
835
|
-
**How?** The `/alfred:1-plan` command automatically creates professional SPECs in EARS format.
|
|
836
|
-
|
|
837
|
-
**What You Get**:
|
|
838
|
-
|
|
839
|
-
- ✅ Clear requirements everyone on the team understands
|
|
840
|
-
- ✅ SPEC-based test cases (what to test is already defined)
|
|
841
|
-
- ✅ When requirements change, track all affected code with `@SPEC:ID` TAG
|
|
842
|
-
|
|
843
|
-
---
|
|
844
|
-
|
|
845
|
-
### Key Concept 2: TDD (Test-Driven Development)
|
|
846
|
-
|
|
847
|
-
**Metaphor**: Like finding the route after setting a destination, you set goals with tests, then write code.
|
|
848
|
-
|
|
849
|
-
**Core Idea**: Write tests **before** implementation. Like checking ingredients before cooking, this clarifies requirements before implementation.
|
|
850
|
-
|
|
851
|
-
**3-Step Cycle**:
|
|
852
|
-
|
|
853
|
-
1. **🔴 RED**: Write a failing test first
|
|
854
|
-
|
|
855
|
-
- Each SPEC requirement becomes a test case
|
|
856
|
-
- Must fail because implementation doesn't exist yet
|
|
857
|
-
- Git commit: `test(AUTH-001): add failing test`
|
|
858
|
-
|
|
859
|
-
2. **🟢 GREEN**: Minimal implementation to pass the test
|
|
860
|
-
|
|
861
|
-
- Make it pass using the simplest approach
|
|
862
|
-
- Passing comes before perfection
|
|
863
|
-
- Git commit: `feat(AUTH-001): implement minimal solution`
|
|
864
|
-
|
|
865
|
-
3. **♻️ REFACTOR**: Clean up and improve code
|
|
866
|
-
- Apply TRUST 5 principles
|
|
867
|
-
- Remove duplication, improve readability
|
|
868
|
-
- Tests must still pass
|
|
869
|
-
- Git commit: `refactor(AUTH-001): improve code quality`
|
|
870
|
-
|
|
871
|
-
**How?** The `/alfred:2-run` command automatically executes these 3 steps.
|
|
872
|
-
|
|
873
|
-
**What You Get**:
|
|
874
|
-
|
|
875
|
-
- ✅ Guaranteed 85%+ coverage (no code without tests)
|
|
876
|
-
- ✅ Refactoring confidence (always verifiable with tests)
|
|
877
|
-
- ✅ Clear Git history (trace RED → GREEN → REFACTOR process)
|
|
878
|
-
|
|
879
|
-
---
|
|
880
|
-
|
|
881
|
-
### Key Concept 3: @TAG System
|
|
882
|
-
|
|
883
|
-
**Metaphor**: Like package tracking numbers, you should be able to trace code's journey.
|
|
884
|
-
|
|
885
|
-
**Core Idea**: Add `@TAG:ID` to all SPECs, tests, code, and documentation to create **one-to-one correspondence**.
|
|
886
|
-
|
|
887
|
-
**TAG Chain**:
|
|
888
|
-
|
|
889
|
-
```
|
|
890
|
-
@SPEC:AUTH-001 (requirements)
|
|
891
|
-
↓
|
|
892
|
-
@TEST:AUTH-001 (test)
|
|
893
|
-
↓
|
|
894
|
-
@CODE:AUTH-001 (implementation)
|
|
895
|
-
↓
|
|
896
|
-
@DOC:AUTH-001 (documentation)
|
|
897
|
-
```
|
|
898
|
-
|
|
899
|
-
**TAG ID Rules**: `<Domain>-<3 digits>`
|
|
900
|
-
|
|
901
|
-
- AUTH-001, AUTH-002, AUTH-003...
|
|
902
|
-
- USER-001, USER-002...
|
|
903
|
-
- Once assigned, **never change**
|
|
904
|
-
|
|
905
|
-
**How to Use?** When requirements change:
|
|
906
|
-
|
|
907
|
-
```bash
|
|
908
|
-
# Find everything related to AUTH-001
|
|
909
|
-
rg '@TAG:AUTH-001' -n
|
|
910
|
-
|
|
911
|
-
# Result: Shows all SPEC, TEST, CODE, DOC at once
|
|
912
|
-
# → Clear what needs modification
|
|
913
|
-
```
|
|
914
|
-
|
|
915
|
-
**How?** The `/alfred:3-sync` command validates TAG chains and detects orphan TAGs (TAGs without correspondence).
|
|
916
|
-
|
|
917
|
-
**What You Get**:
|
|
918
|
-
|
|
919
|
-
- ✅ Clear intent for all code (reading SPEC explains why this code exists)
|
|
920
|
-
- ✅ Instantly identify all affected code during refactoring
|
|
921
|
-
- ✅ Code remains understandable 3 months later (trace TAG → SPEC)
|
|
922
|
-
|
|
923
|
-
---
|
|
924
|
-
|
|
925
|
-
### Key Concept 4: TRUST 5 Principles
|
|
926
|
-
|
|
927
|
-
**Metaphor**: Like a healthy body, good code must satisfy all 5 elements.
|
|
928
|
-
|
|
929
|
-
**Core Idea**: All code must follow these 5 principles. `/alfred:3-sync` automatically verifies them.
|
|
930
|
-
|
|
931
|
-
1. **🧪 Test First** (tests come first)
|
|
932
|
-
|
|
933
|
-
- Test coverage ≥ 85%
|
|
934
|
-
- All code protected by tests
|
|
935
|
-
- Adding feature = adding test
|
|
936
|
-
|
|
937
|
-
2. **📖 Readable** (easy-to-read code)
|
|
938
|
-
|
|
939
|
-
- Functions ≤ 50 lines, files ≤ 300 lines
|
|
940
|
-
- Variable names reveal intent
|
|
941
|
-
- Pass linters (ESLint/ruff/clippy)
|
|
942
|
-
|
|
943
|
-
3. **🎯 Unified** (consistent structure)
|
|
944
|
-
|
|
945
|
-
- Maintain SPEC-based architecture
|
|
946
|
-
- Same patterns repeat (reduces learning curve)
|
|
947
|
-
- Type safety or runtime validation
|
|
948
|
-
|
|
949
|
-
4. **🔒 Secured** (security)
|
|
950
|
-
|
|
951
|
-
- Input validation (defend against XSS, SQL Injection)
|
|
952
|
-
- Password hashing (bcrypt, Argon2)
|
|
953
|
-
- Protect sensitive information (environment variables)
|
|
954
|
-
|
|
955
|
-
5. **🔗 Trackable** (traceability)
|
|
956
|
-
- Use @TAG system
|
|
957
|
-
- Include TAG in Git commits
|
|
958
|
-
- Document all decisions
|
|
959
|
-
|
|
960
|
-
**How?** The `/alfred:3-sync` command automatically performs TRUST verification.
|
|
961
|
-
|
|
962
|
-
**What You Get**:
|
|
963
|
-
|
|
964
|
-
- ✅ Production-quality code guaranteed
|
|
965
|
-
- ✅ Entire team develops with same standards
|
|
966
|
-
- ✅ Fewer bugs, prevent security vulnerabilities in advance
|
|
967
|
-
|
|
968
|
-
---
|
|
969
|
-
|
|
970
|
-
### Key Concept 5: Alfred SuperAgent
|
|
971
|
-
|
|
972
|
-
**Metaphor**: Like a personal assistant, Alfred handles all the complex work.
|
|
973
|
-
|
|
974
|
-
**Core Idea**: **19 AI agents** collaborate to automate the entire development process:
|
|
975
|
-
|
|
976
|
-
**Agent Composition**:
|
|
977
|
-
|
|
978
|
-
- **Alfred SuperAgent**: Overall orchestration (1)
|
|
979
|
-
- **Core Sub-agents**: Specialized tasks like SPEC writing, TDD implementation, documentation sync (10)
|
|
980
|
-
- **Zero-project Specialists**: Project initialization, language detection, etc. (6)
|
|
981
|
-
- **Built-in Agents**: General questions, codebase exploration (2)
|
|
982
|
-
|
|
983
|
-
**55 Claude Skills**:
|
|
984
|
-
|
|
985
|
-
- **Foundation** (6): TRUST/TAG/SPEC/Git/EARS principles
|
|
986
|
-
- **Essentials** (4): Debugging, performance, refactoring, code review
|
|
987
|
-
- **Alfred** (7): Workflow automation
|
|
988
|
-
- **Domain** (10): Backend, frontend, security, etc.
|
|
989
|
-
- **Language** (18): Python, JavaScript, Go, Rust, Java, Kotlin, Swift, Dart, C/C#, Ruby, PHP, SQL, Shell, and more
|
|
990
|
-
- **Ops** (1): Claude Code session management
|
|
991
|
-
- **Other** (2): Skill factory, Spec authoring
|
|
992
|
-
|
|
993
|
-
**How?** `/alfred:*` commands automatically activate the right expert team.
|
|
994
|
-
|
|
995
|
-
**What You Get**:
|
|
996
|
-
|
|
997
|
-
- ✅ No prompt writing needed (use standardized commands)
|
|
998
|
-
- ✅ Automatically remember project context (no repeating same questions)
|
|
999
|
-
- ✅ Auto-assemble optimal expert team (activate appropriate Sub-agents)
|
|
1000
|
-
|
|
1001
|
-
> **Want to learn more?** Check detailed rules in `.moai/memory/development-guide.md`.
|
|
1002
|
-
|
|
1003
|
-
---
|
|
1004
|
-
|
|
1005
|
-
## First Hands-on: Todo API Example
|
|
1006
|
-
|
|
1007
|
-
Let's now **experience MoAI-ADK's complete workflow** firsthand. We'll build a simple "Todo Management API" and see how SPEC, TDD, and documentation connect.
|
|
1008
|
-
|
|
1009
|
-
### Step 1: PLAN - Write SPEC (about 3 minutes)
|
|
1010
|
-
|
|
1011
|
-
```bash
|
|
1012
|
-
/alfred:1-plan "Todo add, view, update, delete API"
|
|
1013
|
-
```
|
|
1014
|
-
|
|
1015
|
-
**Execution Result**:
|
|
1016
|
-
|
|
1017
|
-
Alfred's **spec-builder** automatically generates:
|
|
1018
|
-
|
|
1019
|
-
```yaml
|
|
1020
|
-
# .moai/specs/SPEC-TODO-001/spec.md
|
|
1021
|
-
|
|
1022
|
-
---
|
|
1023
|
-
id: TODO-001
|
|
1024
|
-
version: 0.0.1
|
|
1025
|
-
status: draft
|
|
1026
|
-
created: 2025-10-22
|
|
1027
|
-
updated: 2025-10-22
|
|
1028
|
-
author: @user
|
|
1029
|
-
priority: high
|
|
1030
|
-
---
|
|
1031
|
-
|
|
1032
|
-
# @SPEC:TODO-001: Todo Management API
|
|
1033
|
-
|
|
1034
|
-
## Ubiquitous Requirements
|
|
1035
|
-
- The system SHALL be able to add todos
|
|
1036
|
-
- The system SHALL be able to view all todos
|
|
1037
|
-
- The system SHALL be able to update specific todos
|
|
1038
|
-
- The system SHALL be able to delete todos
|
|
1039
|
-
|
|
1040
|
-
## Event-driven Requirements
|
|
1041
|
-
- WHEN a new todo is requested via POST /todos, the system SHALL save the todo and return a 201 response
|
|
1042
|
-
- WHEN GET /todos/{id} is requested with an existing todo ID, the system SHALL return that todo
|
|
1043
|
-
- WHEN GET is requested with a non-existent todo ID, the system SHALL return a 404 error
|
|
1044
|
-
|
|
1045
|
-
## Constraints
|
|
1046
|
-
- Todo title SHALL be minimum 1 character, maximum 200 characters
|
|
1047
|
-
- Each todo SHALL automatically record creation time
|
|
1048
|
-
```
|
|
1049
|
-
|
|
1050
|
-
**Also auto-generated**:
|
|
1051
|
-
|
|
1052
|
-
- 📋 `Plan Board`: Implementation ideas, risk factors, solution strategies
|
|
1053
|
-
- ✅ `Acceptance Criteria`: Verification standards
|
|
1054
|
-
- 🌿 `feature/spec-todo-001` Git branch
|
|
1055
|
-
|
|
1056
|
-
### Step 2: RUN - TDD Implementation (about 5 minutes)
|
|
1057
|
-
|
|
1058
|
-
```bash
|
|
1059
|
-
/alfred:2-run TODO-001
|
|
1060
|
-
```
|
|
1061
|
-
|
|
1062
|
-
**Phase 1: Establish Implementation Strategy**
|
|
1063
|
-
|
|
1064
|
-
The **implementation-planner** Sub-agent decides:
|
|
1065
|
-
|
|
1066
|
-
- 📚 Libraries: FastAPI + SQLAlchemy
|
|
1067
|
-
- 📁 Folder structure: `src/todo/`, `tests/todo/`
|
|
1068
|
-
- 🏷️ TAG design: `@CODE:TODO-001:API`, `@CODE:TODO-001:MODEL`, `@CODE:TODO-001:REPO`
|
|
1069
|
-
|
|
1070
|
-
**Phase 2: RED → GREEN → REFACTOR**
|
|
1071
|
-
|
|
1072
|
-
**🔴 RED: Write Tests First**
|
|
1073
|
-
|
|
1074
|
-
```python
|
|
1075
|
-
# tests/test_todo_api.py
|
|
1076
|
-
# @TEST:TODO-001 | SPEC: SPEC-TODO-001.md
|
|
1077
|
-
|
|
1078
|
-
import pytest
|
|
1079
|
-
from src.todo.api import create_todo, get_todos
|
|
1080
|
-
|
|
1081
|
-
def test_create_todo_should_return_201_with_todo_id():
|
|
1082
|
-
"""WHEN a new todo is requested via POST /todos,
|
|
1083
|
-
the system SHALL save the todo and return a 201 response"""
|
|
1084
|
-
response = create_todo({"title": "Buy groceries"})
|
|
1085
|
-
assert response.status_code == 201
|
|
1086
|
-
assert "id" in response.json()
|
|
1087
|
-
assert response.json()["title"] == "Buy groceries"
|
|
1088
|
-
|
|
1089
|
-
def test_get_todos_should_return_all_todos():
|
|
1090
|
-
"""The system SHALL be able to view all todos"""
|
|
1091
|
-
create_todo({"title": "Task 1"})
|
|
1092
|
-
create_todo({"title": "Task 2"})
|
|
1093
|
-
|
|
1094
|
-
response = get_todos()
|
|
1095
|
-
assert response.status_code == 200
|
|
1096
|
-
assert len(response.json()) >= 2
|
|
1097
|
-
|
|
1098
|
-
def test_get_todo_with_invalid_id_should_return_404():
|
|
1099
|
-
"""WHEN GET is requested with a non-existent todo ID,
|
|
1100
|
-
the system SHALL return a 404 error"""
|
|
1101
|
-
response = get_todo(999)
|
|
1102
|
-
assert response.status_code == 404
|
|
1103
|
-
```
|
|
1104
|
-
|
|
1105
|
-
**Execute**: `pytest tests/test_todo_api.py -v`
|
|
1106
|
-
**Result**: ❌ All fail (create_todo not defined)
|
|
1107
|
-
|
|
1108
|
-
**Git Commit**:
|
|
1109
|
-
|
|
1110
|
-
```bash
|
|
1111
|
-
git commit -m "🔴 test(TODO-001): add failing API tests"
|
|
1112
|
-
```
|
|
1113
|
-
|
|
1114
|
-
**🟢 GREEN: Minimal Implementation**
|
|
1115
|
-
|
|
1116
|
-
```python
|
|
1117
|
-
# src/todo/api.py
|
|
1118
|
-
# @CODE:TODO-001:API | SPEC: SPEC-TODO-001.md | TEST: tests/test_todo_api.py
|
|
1119
|
-
|
|
1120
|
-
from fastapi import FastAPI, HTTPException
|
|
1121
|
-
from pydantic import BaseModel
|
|
1122
|
-
import uuid
|
|
1123
|
-
|
|
1124
|
-
app = FastAPI()
|
|
1125
|
-
todos_db = {}
|
|
1126
|
-
|
|
1127
|
-
class TodoRequest(BaseModel):
|
|
1128
|
-
title: str
|
|
1129
|
-
|
|
1130
|
-
@app.post("/todos", status_code=201)
|
|
1131
|
-
def create_todo(todo: TodoRequest):
|
|
1132
|
-
"""@CODE:TODO-001:API - POST endpoint"""
|
|
1133
|
-
todo_id = str(uuid.uuid4())
|
|
1134
|
-
todos_db[todo_id] = {"id": todo_id, "title": todo.title}
|
|
1135
|
-
return todos_db[todo_id]
|
|
1136
|
-
|
|
1137
|
-
@app.get("/todos")
|
|
1138
|
-
def get_todos():
|
|
1139
|
-
"""@CODE:TODO-001:API - GET all endpoint"""
|
|
1140
|
-
return list(todos_db.values())
|
|
1141
|
-
|
|
1142
|
-
@app.get("/todos/{todo_id}")
|
|
1143
|
-
def get_todo(todo_id: str):
|
|
1144
|
-
"""@CODE:TODO-001:API - GET by ID endpoint"""
|
|
1145
|
-
if todo_id not in todos_db:
|
|
1146
|
-
raise HTTPException(status_code=404, detail="Todo not found")
|
|
1147
|
-
return todos_db[todo_id]
|
|
1148
|
-
```
|
|
1149
|
-
|
|
1150
|
-
**Execute**: `pytest tests/test_todo_api.py -v`
|
|
1151
|
-
**Result**: ✅ All pass!
|
|
1152
|
-
|
|
1153
|
-
**Git Commit**:
|
|
1154
|
-
|
|
1155
|
-
```bash
|
|
1156
|
-
git commit -m "🟢 feat(TODO-001): implement minimal Todo API"
|
|
1157
|
-
```
|
|
1158
|
-
|
|
1159
|
-
**♻️ REFACTOR: Code Improvement**
|
|
1160
|
-
|
|
1161
|
-
```python
|
|
1162
|
-
# src/todo/models.py
|
|
1163
|
-
# @CODE:TODO-001:MODEL | SPEC: SPEC-TODO-001.md
|
|
1164
|
-
|
|
1165
|
-
from datetime import datetime
|
|
1166
|
-
from sqlalchemy import Column, String, DateTime
|
|
1167
|
-
from sqlalchemy.ext.declarative import declarative_base
|
|
1168
|
-
|
|
1169
|
-
Base = declarative_base()
|
|
1170
|
-
|
|
1171
|
-
class Todo(Base):
|
|
1172
|
-
"""@CODE:TODO-001:MODEL - Todo data model"""
|
|
1173
|
-
__tablename__ = "todos"
|
|
1174
|
-
|
|
1175
|
-
id = Column(String, primary_key=True)
|
|
1176
|
-
title = Column(String(200), nullable=False, index=True) # Constraint: max 200 chars
|
|
1177
|
-
created_at = Column(DateTime, default=datetime.utcnow) # Auto creation time
|
|
1178
|
-
|
|
1179
|
-
def validate(self):
|
|
1180
|
-
"""@CODE:TODO-001:MODEL - Validation"""
|
|
1181
|
-
if not self.title or len(self.title) > 200:
|
|
1182
|
-
raise ValueError("Title must be 1-200 characters")
|
|
1183
|
-
```
|
|
1184
|
-
|
|
1185
|
-
**Execute**: `pytest tests/test_todo_api.py -v`
|
|
1186
|
-
**Result**: ✅ Still all pass!
|
|
1187
|
-
|
|
1188
|
-
**Git Commit**:
|
|
1189
|
-
|
|
1190
|
-
```bash
|
|
1191
|
-
git commit -m "♻️ refactor(TODO-001): add database models and validation"
|
|
1192
|
-
```
|
|
1193
|
-
|
|
1194
|
-
**Phase 3: Quality Verification**
|
|
1195
|
-
|
|
1196
|
-
```bash
|
|
1197
|
-
# TRUST verification
|
|
1198
|
-
✅ Test First: 87% coverage
|
|
1199
|
-
✅ Readable: All functions < 50 lines
|
|
1200
|
-
✅ Unified: Consistent API patterns
|
|
1201
|
-
✅ Secured: Input validation complete
|
|
1202
|
-
✅ Trackable: All code has @TAG:TODO-001
|
|
1203
|
-
```
|
|
1204
|
-
|
|
1205
|
-
### Step 3: SYNC - Documentation Sync (about 1 minute)
|
|
1206
|
-
|
|
1207
|
-
```bash
|
|
1208
|
-
/alfred:3-sync
|
|
1209
|
-
```
|
|
1210
|
-
|
|
1211
|
-
**Automatically Performed**:
|
|
1212
|
-
|
|
1213
|
-
1. **TAG Chain Validation**
|
|
1214
|
-
|
|
1215
|
-
```bash
|
|
1216
|
-
✅ @SPEC:TODO-001 → .moai/specs/SPEC-TODO-001/spec.md
|
|
1217
|
-
✅ @TEST:TODO-001 → tests/test_todo_api.py
|
|
1218
|
-
✅ @CODE:TODO-001 → src/todo/ (3 files)
|
|
1219
|
-
✅ @DOC:TODO-001 → docs/api/todo.md (auto-generated)
|
|
1220
|
-
|
|
1221
|
-
TAG Chain Integrity: 100%
|
|
1222
|
-
Orphan TAGs: None
|
|
1223
|
-
```
|
|
1224
|
-
|
|
1225
|
-
2. **Living Document Generation**
|
|
1226
|
-
|
|
1227
|
-
```markdown
|
|
1228
|
-
# @DOC:TODO-001: Todo Management API
|
|
1229
|
-
|
|
1230
|
-
## Overview
|
|
1231
|
-
|
|
1232
|
-
REST API for managing tasks with CRUD operations.
|
|
1233
|
-
|
|
1234
|
-
## Endpoints
|
|
1235
|
-
|
|
1236
|
-
### Create Todo
|
|
1237
|
-
|
|
1238
|
-
- Method: POST
|
|
1239
|
-
- URL: /todos
|
|
1240
|
-
- Request: {"title": "string (1-200 chars)"}
|
|
1241
|
-
- Response: 201 Created with todo object
|
|
1242
|
-
- Implemented in: @CODE:TODO-001:API
|
|
1243
|
-
- Tested in: @TEST:TODO-001
|
|
1244
|
-
|
|
1245
|
-
### Get All Todos
|
|
1246
|
-
|
|
1247
|
-
- Method: GET
|
|
1248
|
-
- URL: /todos
|
|
1249
|
-
- Response: 200 OK with array of todos
|
|
1250
|
-
|
|
1251
|
-
[... etc ...]
|
|
1252
|
-
```
|
|
1253
|
-
|
|
1254
|
-
3. **README Update**
|
|
1255
|
-
|
|
1256
|
-
```markdown
|
|
1257
|
-
## Features
|
|
1258
|
-
|
|
1259
|
-
- ✅ Todo Management API (TODO-001)
|
|
1260
|
-
```
|
|
1261
|
-
|
|
1262
|
-
4. **CHANGELOG Generation**
|
|
1263
|
-
|
|
1264
|
-
```markdown
|
|
1265
|
-
# Changelog
|
|
1266
|
-
|
|
1267
|
-
## [0.1.0] - 2025-10-22
|
|
1268
|
-
|
|
1269
|
-
### Added
|
|
1270
|
-
|
|
1271
|
-
- Todo Management API with CRUD operations (@SPEC:TODO-001)
|
|
1272
|
-
- Create new todos
|
|
1273
|
-
- List all todos
|
|
1274
|
-
- Update existing todos
|
|
1275
|
-
- Delete todos
|
|
1276
|
-
|
|
1277
|
-
### Implementation Details
|
|
1278
|
-
|
|
1279
|
-
- SPEC: .moai/specs/SPEC-TODO-001/spec.md
|
|
1280
|
-
- Tests: tests/test_todo_api.py (87% coverage)
|
|
1281
|
-
- Code: src/todo/ with models, API, repository layers
|
|
1282
|
-
```
|
|
1283
|
-
|
|
1284
|
-
### Step 4: Verification (about 1 minute)
|
|
1285
|
-
|
|
1286
|
-
Let's verify everything generated is properly connected:
|
|
1287
|
-
|
|
1288
|
-
```bash
|
|
1289
|
-
# 1️⃣ Check TAG chain
|
|
1290
|
-
rg '@(SPEC|TEST|CODE|DOC):TODO-001' -n
|
|
1291
|
-
|
|
1292
|
-
# Output:
|
|
1293
|
-
# .moai/specs/SPEC-TODO-001/spec.md:1: # @SPEC:TODO-001: Todo Management API
|
|
1294
|
-
# tests/test_todo_api.py:2: # @TEST:TODO-001 | SPEC: SPEC-TODO-001.md
|
|
1295
|
-
# src/todo/api.py:5: # @CODE:TODO-001:API | SPEC: SPEC-TODO-001.md
|
|
1296
|
-
# src/todo/models.py:5: # @CODE:TODO-001:MODEL | SPEC: SPEC-TODO-001.md
|
|
1297
|
-
# docs/api/todo.md:1: # @DOC:TODO-001: Todo Management API
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
# 2️⃣ Run tests
|
|
1301
|
-
pytest tests/test_todo_api.py -v
|
|
1302
|
-
# ✅ test_create_todo_should_return_201_with_todo_id PASSED
|
|
1303
|
-
# ✅ test_get_todos_should_return_all_todos PASSED
|
|
1304
|
-
# ✅ test_get_todo_with_invalid_id_should_return_404 PASSED
|
|
1305
|
-
# ✅ 3 passed in 0.05s
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
# 3️⃣ Check generated documentation
|
|
1309
|
-
cat docs/api/todo.md # API documentation auto-generated
|
|
1310
|
-
cat README.md # Todo API added
|
|
1311
|
-
cat CHANGELOG.md # Change history recorded
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
# 4️⃣ Check Git history
|
|
1315
|
-
git log --oneline | head -5
|
|
1316
|
-
# a1b2c3d ✅ sync(TODO-001): update docs and changelog
|
|
1317
|
-
# f4e5d6c ♻️ refactor(TODO-001): add database models
|
|
1318
|
-
# 7g8h9i0 🟢 feat(TODO-001): implement minimal API
|
|
1319
|
-
# 1j2k3l4 🔴 test(TODO-001): add failing tests
|
|
1320
|
-
# 5m6n7o8 🌿 Create feature/spec-todo-001 branch
|
|
1321
|
-
```
|
|
1322
|
-
|
|
1323
|
-
### After 15 Minutes: Complete System
|
|
1324
|
-
|
|
1325
|
-
```
|
|
1326
|
-
✅ SPEC written (3 minutes)
|
|
1327
|
-
└─ @SPEC:TODO-001 TAG assigned
|
|
1328
|
-
└─ Clear requirements in EARS format
|
|
1329
|
-
|
|
1330
|
-
✅ TDD implementation (5 minutes)
|
|
1331
|
-
└─ 🔴 RED: Tests written first
|
|
1332
|
-
└─ 🟢 GREEN: Minimal implementation
|
|
1333
|
-
└─ ♻️ REFACTOR: Quality improvement
|
|
1334
|
-
└─ @TEST:TODO-001, @CODE:TODO-001 TAGs assigned
|
|
1335
|
-
└─ 87% coverage, TRUST 5 principles verified
|
|
1336
|
-
|
|
1337
|
-
✅ Documentation sync (1 minute)
|
|
1338
|
-
└─ Living Document auto-generated
|
|
1339
|
-
└─ README, CHANGELOG updated
|
|
1340
|
-
└─ TAG chain validation complete
|
|
1341
|
-
└─ @DOC:TODO-001 TAG assigned
|
|
1342
|
-
└─ PR status: Draft → Ready for Review
|
|
1343
|
-
|
|
1344
|
-
Result:
|
|
1345
|
-
- 📋 Clear SPEC (SPEC-TODO-001.md)
|
|
1346
|
-
- 🧪 85%+ test coverage (test_todo_api.py)
|
|
1347
|
-
- 💎 Production-quality code (src/todo/)
|
|
1348
|
-
- 📖 Auto-generated API documentation (docs/api/todo.md)
|
|
1349
|
-
- 📝 Change history tracking (CHANGELOG.md)
|
|
1350
|
-
- 🔗 Everything connected with TAGs
|
|
1351
|
-
```
|
|
1352
|
-
|
|
1353
|
-
> **This is MoAI-ADK's true power.** Not just a simple API implementation,
|
|
1354
|
-
> but a **complete development artifact** with everything from SPEC through tests, code, and documentation consistently connected!
|
|
1355
|
-
|
|
1356
|
-
---
|
|
1357
|
-
|
|
1358
|
-
## Sub-agents & Skills Overview
|
|
1359
|
-
|
|
1360
|
-
Alfred works by combining multiple specialized agents with Claude Skills.
|
|
1361
|
-
|
|
1362
|
-
### Core Sub-agents (Plan → Run → Sync)
|
|
1363
|
-
|
|
1364
|
-
| Sub-agent | Model | Role |
|
|
1365
|
-
| ------------------ | ------ | ----------------------------------------------------------------------- |
|
|
1366
|
-
| project-manager 📋 | Sonnet | Project initialization, metadata interviews |
|
|
1367
|
-
| spec-builder 🏗️ | Sonnet | Plan board, EARS SPEC authoring |
|
|
1368
|
-
| code-builder 💎 | Sonnet | Performs complete TDD with `implementation-planner` + `tdd-implementer` |
|
|
1369
|
-
| doc-syncer 📖 | Haiku | Living Doc, README, CHANGELOG sync |
|
|
1370
|
-
| tag-agent 🏷️ | Haiku | TAG inventory, orphan detection |
|
|
1371
|
-
| git-manager 🚀 | Haiku | GitFlow, Draft/Ready, Auto Merge |
|
|
1372
|
-
| debug-helper 🔍 | Sonnet | Failure analysis, fix-forward strategy |
|
|
1373
|
-
| trust-checker ✅ | Haiku | TRUST 5 quality gate |
|
|
1374
|
-
| quality-gate 🛡️ | Haiku | Coverage change and release blocker review |
|
|
1375
|
-
| cc-manager 🛠️ | Sonnet | Claude Code session optimization, Skill deployment |
|
|
1376
|
-
|
|
1377
|
-
### Skills (Progressive Disclosure - v0.4 New!)
|
|
1378
|
-
|
|
1379
|
-
Alfred organizes Claude Skills in a 4-tier architecture using **Progressive Disclosure** to load Just-In-Time only when needed. Each Skill is a production-grade guide stored in `.claude/skills/` directory.
|
|
1380
|
-
|
|
1381
|
-
#### Foundation Tier
|
|
1382
|
-
|
|
1383
|
-
Core skills containing fundamental TRUST/TAG/SPEC/Git/EARS/Language principles
|
|
1384
|
-
|
|
1385
|
-
| Skill | Description |
|
|
1386
|
-
| ----------------------- | ---------------------------------------------------------------------------------- |
|
|
1387
|
-
| `moai-foundation-trust` | TRUST 5-principles (Test 85%+, Readable, Unified, Secured, Trackable) verification |
|
|
1388
|
-
| `moai-foundation-tags` | @TAG markers scan and inventory generation (CODE-FIRST principle) |
|
|
1389
|
-
| `moai-foundation-specs` | SPEC YAML frontmatter validation and HISTORY section management |
|
|
1390
|
-
| `moai-foundation-ears` | EARS (Easy Approach to Requirements Syntax) requirements writing guide |
|
|
1391
|
-
| `moai-foundation-git` | Git workflow automation (branching, TDD commits, PR management) |
|
|
1392
|
-
| `moai-foundation-langs` | Project language/framework auto-detection (package.json, pyproject.toml, etc.) |
|
|
1393
|
-
|
|
1394
|
-
#### Essentials Tier
|
|
1395
|
-
|
|
1396
|
-
Core tools needed for daily development work
|
|
1397
|
-
|
|
1398
|
-
| Skill | Description |
|
|
1399
|
-
| -------------------------- | ---------------------------------------------------------------------- |
|
|
1400
|
-
| `moai-essentials-debug` | Stack trace analysis, error pattern detection, quick diagnosis support |
|
|
1401
|
-
| `moai-essentials-perf` | Performance profiling, bottleneck detection, tuning strategies |
|
|
1402
|
-
| `moai-essentials-refactor` | Refactoring guide, design patterns, code improvement strategies |
|
|
1403
|
-
| `moai-essentials-review` | Automated code review, SOLID principles, code smell detection |
|
|
1404
|
-
|
|
1405
|
-
#### Alfred Tier
|
|
1406
|
-
|
|
1407
|
-
MoAI-ADK internal workflow orchestration skills
|
|
1408
|
-
|
|
1409
|
-
| Skill | Description |
|
|
1410
|
-
| -------------------------------------- | ------------------------------------------------------------------------- |
|
|
1411
|
-
| `moai-alfred-ears-authoring` | EARS syntax validation and requirement pattern guidance |
|
|
1412
|
-
| `moai-alfred-git-workflow` | MoAI-ADK conventions (feature branch, TDD commits, Draft PR) automation |
|
|
1413
|
-
| `moai-alfred-language-detection` | Project language/runtime detection and test tool recommendations |
|
|
1414
|
-
| `moai-alfred-spec-metadata-validation` | SPEC YAML frontmatter and HISTORY section consistency validation |
|
|
1415
|
-
| `moai-alfred-tag-scanning` | Complete @TAG marker scan and inventory generation (CODE-FIRST principle) |
|
|
1416
|
-
| `moai-alfred-trust-validation` | TRUST 5-principles compliance verification |
|
|
1417
|
-
| `moai-alfred-interactive-questions` | Claude Code Tools AskUserQuestion TUI menu standardization |
|
|
1418
|
-
|
|
1419
|
-
#### Domain Tier
|
|
1420
|
-
|
|
1421
|
-
Specialized domain expertise
|
|
1422
|
-
|
|
1423
|
-
| Skill | Description |
|
|
1424
|
-
| -------------------------- | ---------------------------------------------------------------------------------------- |
|
|
1425
|
-
| `moai-domain-backend` | Backend architecture, API design, scaling guide |
|
|
1426
|
-
| `moai-domain-cli-tool` | CLI tool development, argument parsing, POSIX compliance, user-friendly help messages |
|
|
1427
|
-
| `moai-domain-data-science` | Data analysis, visualization, statistical modeling, reproducible research workflows |
|
|
1428
|
-
| `moai-domain-database` | Database design, schema optimization, indexing strategies, migration management |
|
|
1429
|
-
| `moai-domain-devops` | CI/CD pipelines, Docker containerization, Kubernetes orchestration, IaC |
|
|
1430
|
-
| `moai-domain-frontend` | React/Vue/Angular development, state management, performance optimization, accessibility |
|
|
1431
|
-
| `moai-domain-ml` | Machine learning model training, evaluation, deployment, MLOps workflows |
|
|
1432
|
-
| `moai-domain-mobile-app` | Flutter/React Native development, state management, native integration |
|
|
1433
|
-
| `moai-domain-security` | OWASP Top 10, static analysis (SAST), dependency security, secrets management |
|
|
1434
|
-
| `moai-domain-web-api` | REST API, GraphQL design patterns, authentication, versioning, OpenAPI documentation |
|
|
1435
|
-
|
|
1436
|
-
#### Language Tier
|
|
1437
|
-
|
|
1438
|
-
Programming language-specific best practices
|
|
1439
|
-
|
|
1440
|
-
| Skill | Description |
|
|
1441
|
-
| ---------------------- | --------------------------------------------------------- |
|
|
1442
|
-
| `moai-lang-python` | pytest, mypy, ruff, black, uv package management |
|
|
1443
|
-
| `moai-lang-typescript` | Vitest, Biome, strict typing, npm/pnpm |
|
|
1444
|
-
| `moai-lang-javascript` | Jest, ESLint, Prettier, npm package management |
|
|
1445
|
-
| `moai-lang-go` | go test, golint, gofmt, standard library |
|
|
1446
|
-
| `moai-lang-rust` | cargo test, clippy, rustfmt, ownership/borrow checker |
|
|
1447
|
-
| `moai-lang-java` | JUnit, Maven/Gradle, Checkstyle, Spring Boot patterns |
|
|
1448
|
-
| `moai-lang-kotlin` | JUnit, Gradle, ktlint, coroutines, extension functions |
|
|
1449
|
-
| `moai-lang-swift` | XCTest, SwiftLint, iOS/macOS development patterns |
|
|
1450
|
-
| `moai-lang-dart` | flutter test, dart analyze, Flutter widget patterns |
|
|
1451
|
-
| `moai-lang-csharp` | xUnit, .NET tooling, LINQ, async/await patterns |
|
|
1452
|
-
| `moai-lang-cpp` | Google Test, clang-format, modern C++ (C++17/20) |
|
|
1453
|
-
| `moai-lang-c` | Unity test framework, cppcheck, Make build system |
|
|
1454
|
-
| `moai-lang-scala` | ScalaTest, sbt, functional programming patterns |
|
|
1455
|
-
| `moai-lang-ruby` | RSpec, RuboCop, Bundler, Rails patterns |
|
|
1456
|
-
| `moai-lang-php` | PHPUnit, Composer, PSR standards |
|
|
1457
|
-
| `moai-lang-sql` | Test frameworks, query optimization, migration management |
|
|
1458
|
-
| `moai-lang-shell` | bats, shellcheck, POSIX compliance |
|
|
1459
|
-
| `moai-lang-r` | testthat, lintr, data analysis patterns |
|
|
1460
|
-
|
|
1461
|
-
#### Claude Code Ops
|
|
1462
|
-
|
|
1463
|
-
Claude Code session management
|
|
1464
|
-
|
|
1465
|
-
| Skill | Description |
|
|
1466
|
-
| ------------------ | ---------------------------------------------------------------------------------- |
|
|
1467
|
-
| `moai-claude-code` | Claude Code agents, commands, skills, plugins, settings scaffolding and monitoring |
|
|
1468
|
-
|
|
1469
|
-
> **v0.4.6 New Feature**: Claude Skills organized in 4-tier architecture (100% complete in v0.4.6). Each Skill loads via Progressive Disclosure only when needed to minimize context cost. Organized in Foundation → Essentials → Alfred → Domain/Language/Ops tiers, with all skills including production-grade documentation and executable TDD examples.
|
|
1470
|
-
|
|
1471
|
-
---
|
|
1472
|
-
|
|
1473
|
-
## AI Model Selection Guide
|
|
1474
|
-
|
|
1475
|
-
| Scenario | Default Model | Why |
|
|
1476
|
-
| ---------------------------------------------------- | --------------------- | ----------------------------------------------- |
|
|
1477
|
-
| Specifications, design, refactoring, problem solving | **Claude 4.5 Sonnet** | Strong in deep reasoning and structured writing |
|
|
1478
|
-
| Document sync, TAG checks, Git automation | **Claude 4.5 Haiku** | Strong in rapid iteration, string processing |
|
|
1479
|
-
|
|
1480
|
-
- Start with Haiku for patterned tasks; switch to Sonnet when complex judgment is needed.
|
|
1481
|
-
- If you manually change models, noting "why switched" in logs helps collaboration.
|
|
1482
|
-
|
|
1483
|
-
---
|
|
1484
|
-
|
|
1485
|
-
## Claude Code Hooks Guide
|
|
1486
|
-
|
|
1487
|
-
MoAI-ADK provides 4 main **Claude Code Hooks** that seamlessly integrate with your development workflow. These hooks enable automatic checkpoints, JIT context loading, and session monitoring—all happening transparently in the background.
|
|
1488
|
-
|
|
1489
|
-
### What Are Hooks?
|
|
1490
|
-
|
|
1491
|
-
Hooks are **event-driven** scripts that trigger automatically at specific points in your Claude Code session. Think of them as safety guardrails and productivity boosters that work behind the scenes without interrupting your flow.
|
|
1492
|
-
|
|
1493
|
-
### Installed Hooks
|
|
1494
|
-
|
|
1495
|
-
#### 1. SessionStart (Session Initialization)
|
|
1496
|
-
|
|
1497
|
-
**Triggers**: When you start a Claude Code session in your project
|
|
1498
|
-
**Purpose**: Display project status at a glance
|
|
1499
|
-
|
|
1500
|
-
**What You See**:
|
|
1501
|
-
|
|
1502
|
-
```
|
|
1503
|
-
🚀 MoAI-ADK Session Started
|
|
1504
|
-
Language: Python
|
|
1505
|
-
Branch: develop
|
|
1506
|
-
Changes: 2 files
|
|
1507
|
-
SPEC Progress: 12/25 (48%)
|
|
1508
|
-
```
|
|
1509
|
-
|
|
1510
|
-
**Why It Matters**: Instantly understand your project's current state without running multiple commands.
|
|
1511
|
-
|
|
1512
|
-
#### 2. PreToolUse (Before Tool Execution)
|
|
1513
|
-
|
|
1514
|
-
**Triggers**: Before executing file edits, Bash commands, or MultiEdit operations
|
|
1515
|
-
**Purpose**: Detect risky operations and automatically create safety checkpoints + TAG Guard
|
|
1516
|
-
|
|
1517
|
-
**Protection Against**:
|
|
1518
|
-
|
|
1519
|
-
- `rm -rf` (file deletion)
|
|
1520
|
-
- `git merge`, `git reset --hard` (Git dangerous operations)
|
|
1521
|
-
- Editing critical files (`CLAUDE.md`, `config.json`)
|
|
1522
|
-
- Mass edits (10+ files at once via MultiEdit)
|
|
1523
|
-
|
|
1524
|
-
**TAG Guard (New in v0.4.11)**:
|
|
1525
|
-
Automatically detects missing @TAG annotations in changed files:
|
|
1526
|
-
|
|
1527
|
-
- Scans staged, modified, and untracked files
|
|
1528
|
-
- Warns when SPEC/TEST/CODE/DOC files lack required @TAG markers
|
|
1529
|
-
- Configurable rules via `.moai/tag-rules.json`
|
|
1530
|
-
- Non-blocking (gentle reminder, doesn't stop execution)
|
|
1531
|
-
|
|
1532
|
-
**What You See**:
|
|
1533
|
-
|
|
1534
|
-
```
|
|
1535
|
-
🛡️ Checkpoint created: before-delete-20251023-143000
|
|
1536
|
-
Operation: delete
|
|
1537
|
-
```
|
|
1538
|
-
|
|
1539
|
-
Or when TAGs are missing:
|
|
1540
|
-
|
|
1541
|
-
```
|
|
1542
|
-
⚠️ TAG 누락 감지: 생성/수정한 파일 중 @TAG가 없는 항목이 있습니다.
|
|
1543
|
-
- src/auth/service.py → 기대 태그: @CODE:
|
|
1544
|
-
- tests/test_auth.py → 기대 태그: @TEST:
|
|
1545
|
-
권장 조치:
|
|
1546
|
-
1) SPEC/TEST/CODE/DOC 유형에 맞는 @TAG를 파일 상단 주석이나 헤더에 추가
|
|
1547
|
-
2) rg로 확인: rg '@(SPEC|TEST|CODE|DOC):' -n <경로>
|
|
1548
|
-
```
|
|
1549
|
-
|
|
1550
|
-
**Why It Matters**: Prevents data loss from mistakes and ensures @TAG traceability. You can always restore from the checkpoint if something goes wrong.
|
|
1551
|
-
|
|
1552
|
-
#### 3. UserPromptSubmit (Prompt Input)
|
|
1553
|
-
|
|
1554
|
-
**Triggers**: When you submit a prompt to Claude
|
|
1555
|
-
**Purpose**: JIT (Just-In-Time) context loading—automatically add relevant files
|
|
1556
|
-
|
|
1557
|
-
**How It Works**:
|
|
1558
|
-
|
|
1559
|
-
- You type: "Fix AUTH bug"
|
|
1560
|
-
- Hook scans for AUTH-related files
|
|
1561
|
-
- Auto-loads: SPEC, tests, implementation, docs related to AUTH
|
|
1562
|
-
- Claude receives full context without you manually specifying files
|
|
1563
|
-
|
|
1564
|
-
**Why It Matters**: Saves time and ensures Claude has all the relevant context for your request.
|
|
1565
|
-
|
|
1566
|
-
#### 4. SessionEnd (Session Cleanup)
|
|
1567
|
-
|
|
1568
|
-
**Triggers**: When you close your Claude Code session
|
|
1569
|
-
**Purpose**: Cleanup tasks and state preservation
|
|
1570
|
-
|
|
1571
|
-
**Why It Matters**: Ensures clean session transitions and proper state management.
|
|
1572
|
-
|
|
1573
|
-
### Technical Details
|
|
1574
|
-
|
|
1575
|
-
- **Location**: `.claude/hooks/alfred/`
|
|
1576
|
-
- **Environment Variable**: `$CLAUDE_PROJECT_DIR` (dynamically references project root)
|
|
1577
|
-
- **Performance**: Each hook executes in <100ms
|
|
1578
|
-
- **Logging**: Errors output to stderr (stdout reserved for JSON payloads)
|
|
1579
|
-
|
|
1580
|
-
### How to Disable Hooks
|
|
1581
|
-
|
|
1582
|
-
If you need to temporarily disable hooks, edit `.claude/settings.json`:
|
|
1583
|
-
|
|
1584
|
-
```json
|
|
1585
|
-
{
|
|
1586
|
-
"hooks": {
|
|
1587
|
-
"SessionStart": [], // Disabled
|
|
1588
|
-
"PreToolUse": [...] // Still active
|
|
1589
|
-
}
|
|
1590
|
-
}
|
|
1591
|
-
```
|
|
1592
|
-
|
|
1593
|
-
### Troubleshooting
|
|
1594
|
-
|
|
1595
|
-
**Problem: Hook doesn't execute**
|
|
1596
|
-
|
|
1597
|
-
- ✅ Verify `.claude/settings.json` is properly configured
|
|
1598
|
-
- ✅ Check `uv` is installed: `which uv`
|
|
1599
|
-
- ✅ Ensure hook script has execute permissions: `chmod +x .claude/hooks/alfred/alfred_hooks.py`
|
|
1600
|
-
|
|
1601
|
-
**Problem: Performance degradation**
|
|
1602
|
-
|
|
1603
|
-
- ✅ Check if any hook exceeds 100ms execution time
|
|
1604
|
-
- ✅ Disable unnecessary hooks
|
|
1605
|
-
- ✅ Review error messages in stderr output
|
|
1606
|
-
|
|
1607
|
-
**Problem: Too many checkpoints created**
|
|
1608
|
-
|
|
1609
|
-
- ✅ Review PreToolUse trigger conditions
|
|
1610
|
-
- ✅ Adjust detection thresholds in `core/checkpoint.py` if needed
|
|
1611
|
-
|
|
1612
|
-
### Installed Hooks (5 total)
|
|
1613
|
-
|
|
1614
|
-
| Hook | Status | Feature |
|
|
1615
|
-
| -------------------- | --------- | ------------------------------------------------------------------------------------------------------------------ |
|
|
1616
|
-
| **SessionStart** | ✅ Active | Project status summary (language, Git, SPEC progress, checkpoints) |
|
|
1617
|
-
| **PreToolUse** | ✅ Active | Risk detection + auto checkpoint (critical-delete, delete, merge, script) + **TAG Guard** (missing @TAG detection) |
|
|
1618
|
-
| **UserPromptSubmit** | ✅ Active | JIT context loading (auto-load related SPEC, tests, code, docs) |
|
|
1619
|
-
| **PostToolUse** | ✅ Active | Auto-run tests after code changes (9 languages: Python, TS, JS, Go, Rust, Java, Kotlin, Swift, Dart) |
|
|
1620
|
-
| **SessionEnd** | ✅ Active | Session cleanup and state saving |
|
|
1621
|
-
|
|
1622
|
-
### Future Enhancements
|
|
1623
|
-
|
|
1624
|
-
- **Notification**: Important event alerts (logging, notifications)
|
|
1625
|
-
- **Stop/SubagentStop**: Cleanup when agents terminate
|
|
1626
|
-
- Advanced security: `dd` commands, supply chain checks
|
|
1627
|
-
|
|
1628
|
-
### Learn More
|
|
1629
|
-
|
|
1630
|
-
- Comprehensive analysis: `.moai/reports/hooks-analysis-and-implementation.md`
|
|
1631
|
-
- PostToolUse implementation: `.moai/reports/phase3-posttool-implementation-complete.md`
|
|
1632
|
-
- Security enhancements: `.moai/reports/security-enhancement-critical-delete.md`
|
|
1633
|
-
- Hook implementation: `.claude/hooks/alfred/`
|
|
1634
|
-
- Hook tests: `tests/hooks/`
|
|
1635
|
-
|
|
1636
|
-
---
|
|
1637
|
-
|
|
1638
|
-
## Frequently Asked Questions (FAQ)
|
|
1639
|
-
|
|
1640
|
-
- **Q. Can I install on an existing project?**
|
|
1641
|
-
- A. Yes. Run `moai-adk init .` to add only the `.moai/` structure without touching existing code.
|
|
1642
|
-
- **Q. How do I run tests?**
|
|
1643
|
-
- A. `/alfred:2-run` runs them first; rerun `pytest`, `pnpm test`, etc. per language as needed.
|
|
1644
|
-
- **Q. How do I ensure documentation stays current?**
|
|
1645
|
-
- A. `/alfred:3-sync` generates a Sync Report. Check the report in Pull Requests.
|
|
1646
|
-
- **Q. Can I work manually?**
|
|
1647
|
-
- A. Yes, but keep the SPEC → TEST → CODE → DOC order and always leave TAGs.
|
|
1648
|
-
|
|
1649
|
-
---
|
|
1650
|
-
|
|
1651
|
-
## Latest Updates (New!)
|
|
1652
|
-
|
|
1653
|
-
| Version | Key Features | Date |
|
|
1654
|
-
| ----------- | ------------------------------------------------------------------------------------------------ | ---------- |
|
|
1655
|
-
| **v0.5.7** | 🎯 SPEC → GitHub Issue automation + CodeRabbit integration + Auto PR comments | 2025-10-27 |
|
|
1656
|
-
| **v0.4.11** | ✨ TAG Guard system + CLAUDE.md formatting improvements + Code cleanup | 2025-10-23 |
|
|
1657
|
-
| **v0.4.10** | 🔧 Hook robustness improvements + Bilingual documentation + Template language config | 2025-10-23 |
|
|
1658
|
-
| **v0.4.9** | 🎯 Hook JSON schema validation fixes + Comprehensive tests (468/468 passing) | 2025-10-23 |
|
|
1659
|
-
| **v0.4.8** | 🚀 Release automation + PyPI deployment + Skills refinement | 2025-10-23 |
|
|
1660
|
-
| **v0.4.7** | 📖 Korean language optimization + SPEC-First principle documentation | 2025-10-22 |
|
|
1661
|
-
| **v0.4.6** | 🎉 Complete Skills v2.0 (100% Production-Ready) + 85,000 lines official docs + 300+ TDD examples | 2025-10-22 |
|
|
1662
|
-
|
|
1663
|
-
> 📦 **Install Now**: `uv tool install moai-adk==0.4.11` or `pip install moai-adk==0.4.11`
|
|
1664
|
-
|
|
1665
|
-
---
|
|
1666
|
-
|
|
1667
|
-
## Additional Resources
|
|
1668
|
-
|
|
1669
|
-
| Purpose | Resource |
|
|
1670
|
-
| ------------------------- | --------------------------------------------------------------- |
|
|
1671
|
-
| Skills detailed structure | `.claude/skills/` directory (58 Skills) |
|
|
1672
|
-
| Sub-agent details | `.claude/agents/alfred/` directory (12 agents) |
|
|
1673
|
-
| Workflow guide | `.claude/commands/alfred/` (4 commands: 0-project ~ 3-sync) |
|
|
1674
|
-
| Documentation | Coming soon (see `.moai/`, `.claude/`, `docs/` in your project) |
|
|
1675
|
-
| Release notes | GitHub Releases: https://github.com/modu-ai/moai-adk/releases |
|
|
1676
|
-
|
|
1677
|
-
---
|
|
1678
|
-
|
|
1679
|
-
## Community & Support
|
|
1680
|
-
|
|
1681
|
-
| Channel | Link |
|
|
1682
|
-
| ------------------------ | -------------------------------------------------------- |
|
|
1683
|
-
| **GitHub Repository** | https://github.com/modu-ai/moai-adk |
|
|
1684
|
-
| **Issues & Discussions** | https://github.com/modu-ai/moai-adk/issues |
|
|
1685
|
-
| **PyPI Package** | https://pypi.org/project/moai-adk/ (Latest: v0.4.11) |
|
|
1686
|
-
| **Latest Release** | https://github.com/modu-ai/moai-adk/releases/tag/v0.4.11 |
|
|
1687
|
-
| **Documentation** | See `.moai/`, `.claude/`, `docs/` within project |
|
|
1688
|
-
|
|
1689
|
-
---
|
|
1690
|
-
|
|
1691
|
-
## 🚀 MoAI-ADK Philosophy
|
|
1692
|
-
|
|
1693
|
-
> **"No CODE without SPEC"**
|
|
1694
|
-
|
|
1695
|
-
MoAI-ADK is not simply a code generation tool. Alfred SuperAgent with its 19-member team and 56 Claude Skills together guarantee:
|
|
1696
|
-
|
|
1697
|
-
- ✅ **SPEC → TEST (TDD) → CODE → DOCS consistency**
|
|
1698
|
-
- ✅ **Complete history tracking with @TAG system**
|
|
1699
|
-
- ✅ **Guaranteed 87.84%+ coverage**
|
|
1700
|
-
- ✅ **Iterative development with 4-stage workflow (0-project → 1-plan → 2-run → 3-sync)**
|
|
1701
|
-
- ✅ **Collaborate with AI transparently and traceably**
|
|
1702
|
-
|
|
1703
|
-
Start a new experience of **trustworthy AI development** with Alfred! 🤖
|
|
1704
|
-
|
|
1705
|
-
---
|
|
1706
|
-
|
|
1707
|
-
**MoAI-ADK** — SPEC-First TDD with AI SuperAgent & Complete Skills + TAG Guard
|
|
1708
|
-
|
|
1709
|
-
- 📦 PyPI: https://pypi.org/project/moai-adk/
|
|
1710
|
-
- 🏠 GitHub: https://github.com/modu-ai/moai-adk
|
|
1711
|
-
- 📝 License: MIT
|
|
1712
|
-
- ⭐ Skills: 55+ Production-Ready Guides
|
|
1713
|
-
- ✅ Tests: 467/476 Passing (85.60% coverage)
|
|
1714
|
-
- 🏷️ TAG Guard: Automatic @TAG validation in PreToolUse Hook
|
|
1715
|
-
|
|
1716
|
-
---
|
|
1717
|
-
|
|
1718
|
-
## ⭐ Star History
|
|
1719
|
-
|
|
1720
|
-
[](https://www.star-history.com/#modu-ai/moai-adk&Date)
|
|
1721
|
-
|
|
1722
|
-
---
|