harness-moaiadk-patterns
Installation
SKILL.md
moai-adk-go Domain Patterns
Architecture Quick Reference
moai-adk-go is a Go binary (moai) with four subsystems:
- CLI (
internal/cli/*.go,cmd/moai/) — Cobra commands:init,update,hook,build,glm,cc,cg,version,doctor,spec. Subcommand handlers read stdin JSON for hooks, emit structured output for the orchestrator. - Template system (
internal/template/) —go:embed-based scaffolding. Source atinternal/template/templates/, generated artifact atinternal/template/embedded.go(DO NOT EDIT).make buildregenerates.TemplateContext({{.GoBinPath}}/{{.HomeDir}}) renders atmoai init. - Config (
internal/config/) —defaults.go(single source for thresholds),envkeys.go(env-var constants),TemplateContextrenderer. - Hook + CI (
.claude/hooks/moai/*.sh,.github/workflows/) — bash wrapper hooks callingmoai hook <event>; CI guard enforces template neutrality.