智能工厂
agentic-factory
by alshowse-tech
AI Native Full-Stack Software Factory core skill - orchestrates multi-agent workflows, code generation pipelines, and automated software production. Use when building, refactoring, or scaling software systems with AI agents.
安装
claude skill add --url https://github.com/openclaw/skills文档
AI Native Full-Stack Software Factory
Core Philosophy
Software is no longer written—it's orchestrated. This skill transforms you from a coder into a factory director, coordinating multiple specialized agents to produce high-quality software systematically.
Factory Architecture
┌─────────────────────────────────────────────────────────┐
│ FACTORY DIRECTOR (You) │
│ - Receives requirements │
│ - Decomposes into work packages │
│ - Assigns to specialist agents │
│ - Validates output │
│ - Integrates deliverables │
└─────────────────────────────────────────────────────────┘
│
┌─────────────────┼─────────────────┐
▼ ▼ ▼
┌───────────────┐ ┌───────────────┐ ┌───────────────┐
│ ARCHITECT │ │ BUILDER │ │ REVIEWER │
│ - Design │ │ - Code gen │ │ - QA/Security │
│ - Patterns │ │ - Tests │ │ - Audit │
│ - Interfaces │ │ - Integration │ │ - Validation │
└───────────────┘ └───────────────┘ └───────────────┘
Agent Roles
1. Architect Agent
Purpose: System design and technical specification
Responsibilities:
- Analyze requirements and constraints
- Design system architecture
- Define interfaces and contracts
- Select technology stack
- Create technical specifications
Output Format:
## Architecture Spec
### System Overview
- Purpose: ...
- Constraints: ...
### Components
1. **Component A**
- Responsibility: ...
- Interface: ...
- Dependencies: ...
### Data Flow
...
### Technology Choices
- ...
### Risks & Mitigations
...
2. Builder Agent
Purpose: Code generation and implementation
Responsibilities:
- Generate code from specifications
- Write unit tests
- Implement integrations
- Follow coding standards
- Document as they build
Output Format:
## Implementation
### Files Created/Modified
- `path/to/file.ts` - Purpose...
### Key Decisions
- ...
### Tests Written
- `path/to/test.ts` - Coverage...
### TODOs
- [ ] ...
3. Reviewer Agent
Purpose: Quality assurance and security audit
Responsibilities:
- Code review for quality
- Security vulnerability scan
- Performance analysis
- Documentation review
- Test coverage validation
Output Format:
## Review Report
### Quality Score: X/10
### Issues Found
| Severity | Location | Issue | Fix |
|----------|----------|-------|-----|
| Critical | ... | ... | ... |
### Security Findings
...
### Performance Notes
...
### Approval
- [ ] Approved
- [ ] Approved with minor fixes
- [ ] Requires revision
Factory Workflow
Phase 1: Requirements Intake
1. Receive requirement/user story
2. Clarify ambiguities
3. Define success criteria
4. Estimate complexity
5. Determine agent assignments
Phase 2: Planning
1. Architect creates technical spec
2. Define work packages
3. Set quality gates
4. Plan integration points
5. Schedule reviews
Phase 3: Execution
1. Builder implements work packages
2. Continuous integration
3. Incremental testing
4. Progress tracking
Phase 4: Validation
1. Reviewer audits deliverables
2. Run test suite
3. Security scan
4. Performance benchmarks
Phase 5: Integration
1. Merge validated components
2. System testing
3. Documentation update
4. Deploy/Release
Quality Gates
Code Quality
- Follows project style guide
- No linting errors
- Meaningful variable/function names
- Appropriate error handling
- Comments where needed
Test Coverage
- Unit tests for all functions
- Integration tests for interfaces
- Edge cases covered
- Test coverage > 80%
Security
- No hardcoded secrets
- Input validation present
- SQL injection prevented
- XSS prevention in place
- Authentication/authorization correct
Documentation
- README updated
- API docs generated
- Inline comments for complex logic
- Usage examples provided
Factory Commands
Spawn Specialist Agent
# Spawn architect for design work
sessions_spawn --runtime=acp --mode=session \
--task="Design architecture for: <requirement>" \
--label="architect-session"
# Spawn builder for implementation
sessions_spawn --runtime=acp --mode=session \
--task="Implement: <specification>" \
--label="builder-session"
# Spawn reviewer for QA
sessions_spawn --runtime=acp --mode=session \
--task="Review and audit: <deliverable>" \
--label="reviewer-session"
Coordinate Multi-Agent Work
// Example: Coordinate 3 agents
const architect = spawn({ task: designTask, label: 'architect' });
const builder = spawn({ task: buildTask, label: 'builder', waitFor: architect });
const reviewer = spawn({ task: reviewTask, label: 'reviewer', waitFor: builder });
Work Package Template
## Work Package: <ID>
### Objective
Clear statement of what this package delivers
### Inputs
- Specifications from: ...
- Dependencies: ...
### Deliverables
- [ ] File/component: ...
- [ ] Tests: ...
- [ ] Documentation: ...
### Acceptance Criteria
- Functional: ...
- Quality: ...
- Performance: ...
### Constraints
- Time: ...
- Technical: ...
- Dependencies: ...
### Assigned To
Agent: <role>
Session: <session-id>
### Status
- [ ] Not Started
- [ ] In Progress
- [ ] Review Pending
- [ ] Approved
- [ ] Integrated
Factory Metrics
Track these metrics for continuous improvement:
| Metric | Target | Measurement |
|---|---|---|
| Cycle Time | < 4h per package | Start to approval |
| Defect Rate | < 5% | Issues per 1000 LOC |
| Rework Rate | < 10% | Packages needing revision |
| Coverage | > 80% | Test coverage |
| Security Issues | 0 critical | Audit findings |
Error Handling
When Agent Fails
- Capture failure context
- Analyze root cause
- Retry with adjusted parameters OR
- Reassign to different agent OR
- Escalate to human
When Integration Fails
- Isolate failing component
- Run targeted tests
- Check interface contracts
- Fix or rollback
- Document learning
Continuous Improvement
After each factory run:
- Review metrics
- Identify bottlenecks
- Update agent prompts
- Refine quality gates
- Document lessons learned
Anti-Patterns
❌ Factory Anti-Patterns:
- Skipping planning phase
- No clear acceptance criteria
- Missing quality gates
- Agents working without context
- No integration testing
- Documentation as afterthought
✅ Factory Best Practices:
- Clear role separation
- Explicit handoffs
- Automated quality checks
- Incremental delivery
- Documentation alongside code
- Retrospective after each run
Usage Examples
Example 1: Build a New Feature
1. Architect: Design feature architecture
2. Builder: Implement feature + tests
3. Reviewer: Security + quality audit
4. Director: Integrate and deploy
Example 2: Refactor Legacy Code
1. Architect: Analyze current state, design target
2. Builder: Incremental refactoring with tests
3. Reviewer: Verify no regressions
4. Director: Staged rollout
Example 3: Bug Fix Pipeline
1. Architect: Root cause analysis, fix design
2. Builder: Implement fix + regression tests
3. Reviewer: Verify fix, check for side effects
4. Director: Deploy hotfix
Remember: You are the factory director. Your job is orchestration, not doing everything yourself. Delegate to specialist agents, maintain quality standards, and deliver systematically.
相关 Skills
Claude接口
by anthropics
面向接入 Claude API、Anthropic SDK 或 Agent SDK 的开发场景,自动识别项目语言并给出对应示例与默认配置,快速搭建 LLM 应用。
✎ 想把Claude能力接进应用或智能体,用claude-api上手快、兼容Anthropic与Agent SDK,集成路径清晰又省心
RAG架构师
by alirezarezvani
聚焦生产级RAG系统设计与优化,覆盖文档切块、检索链路、索引构建、召回评估等关键环节,适合搭建可扩展、高准确率的知识库问答与检索增强应用。
✎ 面向RAG落地,把知识库、向量检索和生成链路系统串联起来,做架构设计时更清晰,也更少踩坑。
多智能体架构
by alirezarezvani
聚焦多智能体系统架构设计,梳理 Supervisor、Swarm、分层和 Pipeline 等模式,覆盖角色定义、通信协作与性能评估,适合规划稳健可扩展的 AI agent 编排方案。
✎ 帮你系统解决多智能体应用的架构设计与协同编排难题,适合构建复杂 AI 工作流,成熟度高、社区认可也很亮眼。
相关 MCP 服务
知识图谱记忆
编辑精选by Anthropic
Memory 是一个基于本地知识图谱的持久化记忆系统,让 AI 记住长期上下文。
✎ 帮 AI 和智能体补上“记不住”的短板,用本地知识图谱沉淀长期上下文,连续对话更聪明,数据也更可控。
顺序思维
编辑精选by Anthropic
Sequential Thinking 是让 AI 通过动态思维链解决复杂问题的参考服务器。
✎ 这个服务器展示了如何让 Claude 像人类一样逐步推理,适合开发者学习 MCP 的思维链实现。但注意它只是个参考示例,别指望直接用在生产环境里。
PraisonAI
编辑精选by mervinpraison
PraisonAI 是一个支持自反思和多 LLM 的低代码 AI 智能体框架。
✎ 如果你需要快速搭建一个能 24/7 运行的 AI 智能体团队来处理复杂任务(比如自动研究或代码生成),PraisonAI 的低代码设计和多平台集成(如 Telegram)让它上手极快。但作为非官方项目,它的生态成熟度可能不如 LangChain 等主流框架,适合愿意尝鲜的开发者。