feat: expand agents (10), skills (20), and hooks (11) with profile system

Agents:
- Add YAML frontmatter (model, tools) to all 7 existing agents
- New agents: planner (opus), build-error-resolver (sonnet), loop-operator (sonnet)

Skills:
- search-first: research before building (Adopt/Extend/Compose/Build)
- verification-loop: full quality gate pipeline (Build→TypeCheck→Lint→Test→Security→Diff)
- strategic-compact: when and how to run /compact effectively
- autonomous-loops: 6 patterns for autonomous agent workflows
- continuous-learning: extract session learnings into instincts

Hooks:
- Profile system (minimal/standard/strict) via run-with-profile.sh
- config-protection: block linter/formatter config edits (standard)
- suggest-compact: remind about /compact every ~50 tool calls (standard)
- auto-tmux-dev: suggest tmux for dev servers (standard)
- session-save/session-load: persist and restore session context (Stop/SessionStart)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
olekhondera
2026-03-24 20:16:20 +02:00
parent cf86a91e4a
commit db5ba04fb9
26 changed files with 1361 additions and 58 deletions

View File

@@ -16,7 +16,7 @@ Universal starter template for AI-assisted project documentation and agent profi
### Key Features
- 📚 **Complete Documentation Structure** - Pre-built docs hierarchy with navigation index
- 🤖 **AI Agent Profiles** - 7 specialized agent roles (Frontend, Backend, Security, Testing, Code Review, Prompt Engineering, Documentation)
- 🤖 **AI Agent Profiles** - 10 specialized agent roles with model/tool restrictions (Planner, Frontend, Backend, Security, Code Review, Testing, Prompt Engineering, Documentation, Build Error Resolver, Loop Operator)
- 🎯 **Product Archetypes** - Pre-defined patterns for common product types (SaaS, Marketplace, Content Platform)
- 🏗️ **Architecture Guidelines** - Frontend (feature-first) and Backend (modular monolith) best practices
- 🔒 **Security by Default** - OWASP Top 10 compliance, security patterns, and audit checklists
@@ -30,7 +30,7 @@ Universal starter template for AI-assisted project documentation and agent profi
- 🚀 **Phase 0 - Planning** (Template Ready):
- ✅ Complete documentation structure (`/docs`)
-7 AI agent profiles with detailed instructions
-10 AI agent profiles with model/tools frontmatter
- ✅ Frontend & Backend architecture guidelines
- ✅ Security, API design, and payment flow patterns
- ✅ ADR framework and templates
@@ -148,14 +148,17 @@ your-project/
│ │ └── rag-embeddings.md # RAG design & evaluation
│ └── examples/ # Filled-in examples
│ └── RECOMMENDATIONS-example.md
├── agents/ # AI agent profiles
│ ├── frontend-architect.md # Frontend agent profile
│ ├── backend-architect.md # Backend agent profile
│ ├── security-auditor.md # Security agent profile
│ ├── test-engineer.md # Testing agent profile
│ ├── code-reviewer.md # Code review agent profile
│ ├── prompt-engineer.md # Prompt engineering agent
── documentation-expert.md # Documentation specialist
├── agents/ # AI agent profiles (10 agents)
│ ├── planner.md # Implementation planner (opus)
│ ├── frontend-architect.md # Frontend architect (opus)
│ ├── backend-architect.md # Backend architect (opus)
│ ├── security-auditor.md # Security auditor (opus)
│ ├── code-reviewer.md # Code reviewer (sonnet)
│ ├── test-engineer.md # Test engineer (sonnet)
── prompt-engineer.md # Prompt engineer (sonnet)
│ ├── documentation-expert.md # Documentation expert (sonnet)
│ ├── build-error-resolver.md # Build error fixer (sonnet)
│ └── loop-operator.md # Autonomous loop monitor (sonnet)
├── apps/ # Application code (Phase 2+)
│ ├── web/ # Frontend app (Next.js)
│ └── api/ # Backend API (Node.js)
@@ -166,15 +169,22 @@ your-project/
│ ├── deploy.sh # VPS deploy (rsync + npm ci + restart)
│ └── ci-lint-fix.sh # ESLint auto-fix with commit-back
├── .claude/ # Claude Code configuration
│ ├── settings.json # Hooks configuration
│ ├── settings.json # Hooks configuration (profiles, lifecycle)
│ ├── status-update-checklist.md # Docs sync checklist for commits
│ ├── hooks/ # Hook scripts
│ ├── hooks/ # Hook scripts (profile-gated)
│ │ ├── run-with-profile.sh # Profile gate (minimal/standard/strict)
│ │ ├── protect-files.sh # Block edits to sensitive files
│ │ ├── bash-firewall.sh # Block dangerous commands
│ │ ├── post-edit-format.sh # Auto-format after edits
│ │ ├── config-protection.sh # Block linter/formatter config edits
│ │ ├── suggest-compact.sh # Suggest /compact every ~50 calls
│ │ ├── auto-tmux-dev.sh # Suggest tmux for dev servers
│ │ ├── post-edit-format.sh # Auto-format after edits (strict)
│ │ ├── audit-log.sh # Log all Bash commands
│ │ ── commit-docs-reminder.sh # Remind to sync docs on commit
└── skills/ # Slash-command skills (15 total)
│ │ ── commit-docs-reminder.sh # Remind to sync docs on commit
│ ├── session-load.sh # Restore previous session context
│ │ └── session-save.sh # Save session context on stop
│ ├── sessions/ # Session state persistence
│ └── skills/ # Slash-command skills (20 total)
├── .editorconfig # Editor formatting standards
├── .env.example # Environment variables template
├── .woodpecker.yml # Woodpecker CI pipeline config
@@ -217,16 +227,19 @@ your-project/
- **[Security](./docs/backend/security.md)** - OWASP Top 10, auth patterns
- **[Payment Flow](./docs/backend/payment-flow.md)** - Provider-agnostic payment design
**AI Agents:**
**AI Agents (10 profiles, model/tools-gated):**
- **[RULES.md](./RULES.md)** - Agent selection protocol and project rules
- **[Frontend Architect](./agents/frontend-architect.md)** - Frontend specialist agent
- **[Backend Architect](./agents/backend-architect.md)** - Backend specialist agent
- **[Security Auditor](./agents/security-auditor.md)** - Security review agent
- **[Test Engineer](./agents/test-engineer.md)** - Testing specialist agent
- **[Code Reviewer](./agents/code-reviewer.md)** - Code quality agent
- **[Prompt Engineer](./agents/prompt-engineer.md)** - AI prompt specialist
- **[Documentation Expert](./agents/documentation-expert.md)** - Technical writing & docs maintenance
- **[Planner](./agents/planner.md)** - Implementation planner (opus, read-only)
- **[Frontend Architect](./agents/frontend-architect.md)** - Frontend specialist (opus)
- **[Backend Architect](./agents/backend-architect.md)** - Backend specialist (opus)
- **[Security Auditor](./agents/security-auditor.md)** - Security review (opus)
- **[Code Reviewer](./agents/code-reviewer.md)** - Code quality (sonnet)
- **[Test Engineer](./agents/test-engineer.md)** - Testing specialist (sonnet)
- **[Prompt Engineer](./agents/prompt-engineer.md)** - AI prompt specialist (sonnet)
- **[Documentation Expert](./agents/documentation-expert.md)** - Technical writing (sonnet)
- **[Build Error Resolver](./agents/build-error-resolver.md)** - Minimal-diff error fixer (sonnet)
- **[Loop Operator](./agents/loop-operator.md)** - Autonomous loop monitor (sonnet)
---
@@ -342,13 +355,16 @@ This template is optimized for AI-assisted development. Here's the recommended w
Before starting a task, select the appropriate agent based on [`RULES.md`](RULES.md):
- **Frontend tasks** → [`frontend-architect.md`](agents/frontend-architect.md)
- **Backend tasks** → [`backend-architect.md`](agents/backend-architect.md)
- **Security review** → [`security-auditor.md`](agents/security-auditor.md)
- **Testing** → [`test-engineer.md`](agents/test-engineer.md)
- **Code review** → [`code-reviewer.md`](agents/code-reviewer.md)
- **AI/LLM integration** → [`prompt-engineer.md`](agents/prompt-engineer.md)
- **Documentation** → [`documentation-expert.md`](agents/documentation-expert.md)
- **Task planning** → [`planner.md`](agents/planner.md) (opus)
- **Frontend tasks** → [`frontend-architect.md`](agents/frontend-architect.md) (opus)
- **Backend tasks** → [`backend-architect.md`](agents/backend-architect.md) (opus)
- **Security review** → [`security-auditor.md`](agents/security-auditor.md) (opus)
- **Code review** → [`code-reviewer.md`](agents/code-reviewer.md) (sonnet)
- **Testing** → [`test-engineer.md`](agents/test-engineer.md) (sonnet)
- **Build errors** → [`build-error-resolver.md`](agents/build-error-resolver.md) (sonnet)
- **AI/LLM integration** → [`prompt-engineer.md`](agents/prompt-engineer.md) (sonnet)
- **Documentation** → [`documentation-expert.md`](agents/documentation-expert.md) (sonnet)
- **Autonomous loops** → [`loop-operator.md`](agents/loop-operator.md) (sonnet)
### 2. Task Execution
@@ -516,6 +532,6 @@ Inspired by best practices from Next.js, T3 Stack, and enterprise SaaS architect
---
**Status:** Phase 0 🚀 Template Ready - **Ready for Customization**
**Documentation:** 📚 Complete (20+ guides) | **AI Agents:** 🤖 7 specialized profiles
**Documentation:** 📚 Complete (20+ guides) | **AI Agents:** 🤖 10 specialized profiles
**Architecture:** ✅ Frontend (Feature-first) + Backend (Modular Monolith)
**Security:** ✅ OWASP Top 10 patterns | **Deployment:** ✅ Docker + CI/CD templates