mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-25 19:48:33 +08:00
feat: migrate all codex team skills from spawn_agents_on_csv to spawn_agent + wait_agent architecture
- Delete 21 old team skill directories using CSV-wave pipeline pattern (~100+ files) - Delete old team-lifecycle (v3) and team-planex-v2 - Create generic team-worker.toml and team-supervisor.toml (replacing tlv4-specific TOMLs) - Convert 19 team skills from Claude Code format (Agent/SendMessage/TaskCreate) to Codex format (spawn_agent/wait_agent/tasks.json/request_user_input) - Update team-lifecycle-v4 to use generic agent types (team_worker/team_supervisor) - Convert all coordinator role files: dispatch.md, monitor.md, role.md - Convert all worker role files: remove run_in_background, fix Bash syntax - Convert all specs/pipelines.md references - Final state: 20 team skills, 217 .md files, zero Claude Code API residuals Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
115
.codex/skills/team-quality-assurance/specs/pipelines.md
Normal file
115
.codex/skills/team-quality-assurance/specs/pipelines.md
Normal file
@@ -0,0 +1,115 @@
|
||||
# QA Pipelines
|
||||
|
||||
Pipeline definitions and task registry for team-quality-assurance.
|
||||
|
||||
## Pipeline Modes
|
||||
|
||||
| Mode | Description | Entry Role |
|
||||
|------|-------------|------------|
|
||||
| discovery | Scout-first: issue discovery then testing | scout |
|
||||
| testing | Skip scout, direct test pipeline | strategist |
|
||||
| full | Complete QA closed loop + regression scan | scout |
|
||||
|
||||
## Pipeline Definitions
|
||||
|
||||
### Discovery Mode (5 tasks, serial)
|
||||
|
||||
```
|
||||
SCOUT-001 -> QASTRAT-001 -> QAGEN-001 -> QARUN-001 -> QAANA-001
|
||||
```
|
||||
|
||||
| Task ID | Role | Dependencies | Description |
|
||||
|---------|------|-------------|-------------|
|
||||
| SCOUT-001 | scout | (none) | Multi-perspective issue scanning |
|
||||
| QASTRAT-001 | strategist | SCOUT-001 | Change scope analysis + test strategy |
|
||||
| QAGEN-001 | generator | QASTRAT-001 | L1 unit test generation |
|
||||
| QARUN-001 | executor | QAGEN-001 | L1 test execution + fix cycles |
|
||||
| QAANA-001 | analyst | QARUN-001 | Defect pattern analysis + quality report |
|
||||
|
||||
### Testing Mode (6 tasks, progressive layers)
|
||||
|
||||
```
|
||||
QASTRAT-001 -> QAGEN-L1-001 -> QARUN-L1-001 -> QAGEN-L2-001 -> QARUN-L2-001 -> QAANA-001
|
||||
```
|
||||
|
||||
| Task ID | Role | Dependencies | Layer | Description |
|
||||
|---------|------|-------------|-------|-------------|
|
||||
| QASTRAT-001 | strategist | (none) | — | Test strategy formulation |
|
||||
| QAGEN-L1-001 | generator | QASTRAT-001 | L1 | L1 unit test generation |
|
||||
| QARUN-L1-001 | executor | QAGEN-L1-001 | L1 | L1 test execution + fix cycles |
|
||||
| QAGEN-L2-001 | generator | QARUN-L1-001 | L2 | L2 integration test generation |
|
||||
| QARUN-L2-001 | executor | QAGEN-L2-001 | L2 | L2 test execution + fix cycles |
|
||||
| QAANA-001 | analyst | QARUN-L2-001 | — | Quality analysis report |
|
||||
|
||||
### Full Mode (8 tasks, parallel windows + regression)
|
||||
|
||||
```
|
||||
SCOUT-001 -> QASTRAT-001 -> [QAGEN-L1-001 || QAGEN-L2-001] -> [QARUN-L1-001 || QARUN-L2-001] -> QAANA-001 -> SCOUT-002
|
||||
```
|
||||
|
||||
| Task ID | Role | Dependencies | Layer | Description |
|
||||
|---------|------|-------------|-------|-------------|
|
||||
| SCOUT-001 | scout | (none) | — | Multi-perspective issue scanning |
|
||||
| QASTRAT-001 | strategist | SCOUT-001 | — | Test strategy formulation |
|
||||
| QAGEN-L1-001 | generator-1 | QASTRAT-001 | L1 | L1 unit test generation (parallel) |
|
||||
| QAGEN-L2-001 | generator-2 | QASTRAT-001 | L2 | L2 integration test generation (parallel) |
|
||||
| QARUN-L1-001 | executor-1 | QAGEN-L1-001 | L1 | L1 test execution + fix cycles (parallel) |
|
||||
| QARUN-L2-001 | executor-2 | QAGEN-L2-001 | L2 | L2 test execution + fix cycles (parallel) |
|
||||
| QAANA-001 | analyst | QARUN-L1-001, QARUN-L2-001 | — | Quality analysis report |
|
||||
| SCOUT-002 | scout | QAANA-001 | — | Regression scan after fixes |
|
||||
|
||||
## GC Loop
|
||||
|
||||
Generator-Executor iterate per test layer until coverage targets are met:
|
||||
|
||||
```
|
||||
QAGEN -> QARUN -> (if coverage < target) -> QAGEN-fix -> QARUN-gc
|
||||
(if coverage >= target) -> next layer or QAANA
|
||||
```
|
||||
|
||||
- Max iterations: 3 per layer
|
||||
- After 3 iterations: accept current coverage with warning
|
||||
|
||||
## Coverage Targets
|
||||
|
||||
| Layer | Name | Default Target |
|
||||
|-------|------|----------------|
|
||||
| L1 | Unit Tests | 80% |
|
||||
| L2 | Integration Tests | 60% |
|
||||
| L3 | E2E Tests | 40% |
|
||||
|
||||
## Scan Perspectives
|
||||
|
||||
| Perspective | Focus |
|
||||
|-------------|-------|
|
||||
| bug | Logic errors, crash paths, null references |
|
||||
| security | Vulnerabilities, auth bypass, data exposure |
|
||||
| test-coverage | Untested code paths, missing assertions |
|
||||
| code-quality | Anti-patterns, complexity, maintainability |
|
||||
| ux | User-facing issues, accessibility (optional) |
|
||||
|
||||
## Session Directory
|
||||
|
||||
```
|
||||
.workflow/.team/QA-<slug>-<YYYY-MM-DD>/
|
||||
├── .msg/messages.jsonl # Message bus log
|
||||
├── .msg/meta.json # Session state + cross-role state
|
||||
├── wisdom/ # Cross-task knowledge
|
||||
│ ├── learnings.md
|
||||
│ ├── decisions.md
|
||||
│ ├── conventions.md
|
||||
│ └── issues.md
|
||||
├── scan/ # Scout output
|
||||
│ └── scan-results.json
|
||||
├── strategy/ # Strategist output
|
||||
│ └── test-strategy.md
|
||||
├── tests/ # Generator output
|
||||
│ ├── L1-unit/
|
||||
│ ├── L2-integration/
|
||||
│ └── L3-e2e/
|
||||
├── results/ # Executor output
|
||||
│ ├── run-001.json
|
||||
│ └── coverage-001.json
|
||||
└── analysis/ # Analyst output
|
||||
└── quality-report.md
|
||||
```
|
||||
131
.codex/skills/team-quality-assurance/specs/team-config.json
Normal file
131
.codex/skills/team-quality-assurance/specs/team-config.json
Normal file
@@ -0,0 +1,131 @@
|
||||
{
|
||||
"team_name": "quality-assurance",
|
||||
"version": "1.0.0",
|
||||
"description": "质量保障团队 - 融合\"软件测试\"和\"问题发现\"两大能力域,形成发现→验证→修复→回归的闭环",
|
||||
"skill_entry": "team-quality-assurance",
|
||||
"invocation": "Skill(skill=\"team-quality-assurance\", args=\"--role=coordinator ...\")",
|
||||
|
||||
"roles": {
|
||||
"coordinator": {
|
||||
"name": "coordinator",
|
||||
"responsibility": "Orchestration",
|
||||
"task_prefix": null,
|
||||
"description": "QA 团队协调者。编排 pipeline:需求澄清 → 模式选择 → 团队创建 → 任务分发 → 监控协调 → 质量门控 → 结果汇报",
|
||||
"message_types_sent": ["mode_selected", "gc_loop_trigger", "quality_gate", "task_unblocked", "error", "shutdown"],
|
||||
"message_types_received": ["scan_ready", "issues_found", "strategy_ready", "tests_generated", "tests_revised", "tests_passed", "tests_failed", "analysis_ready", "quality_report", "error"],
|
||||
"commands": ["dispatch", "monitor"]
|
||||
},
|
||||
"scout": {
|
||||
"name": "scout",
|
||||
"responsibility": "Orchestration (多视角扫描编排)",
|
||||
"task_prefix": "SCOUT-*",
|
||||
"description": "多视角问题侦察员。主动扫描代码库,从 bug、安全、UX、测试覆盖、代码质量等多个视角发现潜在问题",
|
||||
"message_types_sent": ["scan_ready", "issues_found", "error"],
|
||||
"message_types_received": [],
|
||||
"commands": ["scan"],
|
||||
"cli_tools": ["gemini"],
|
||||
"cli_tools": ["gemini"]
|
||||
},
|
||||
"strategist": {
|
||||
"name": "strategist",
|
||||
"responsibility": "Orchestration (策略制定)",
|
||||
"task_prefix": "QASTRAT-*",
|
||||
"description": "测试策略师。分析变更范围,确定测试层级(L1-L3),定义覆盖率目标",
|
||||
"message_types_sent": ["strategy_ready", "error"],
|
||||
"message_types_received": [],
|
||||
"commands": ["analyze-scope"],
|
||||
"cli_tools": ["gemini"],
|
||||
"cli_tools": ["gemini"]
|
||||
},
|
||||
"generator": {
|
||||
"name": "generator",
|
||||
"responsibility": "Code generation (测试代码生成)",
|
||||
"task_prefix": "QAGEN-*",
|
||||
"description": "测试用例生成器。按策略和层级生成测试代码,支持 L1/L2/L3",
|
||||
"message_types_sent": ["tests_generated", "tests_revised", "error"],
|
||||
"message_types_received": [],
|
||||
"commands": ["generate-tests"],
|
||||
"cli_tools": ["gemini"],
|
||||
"cli_tools": ["gemini"]
|
||||
},
|
||||
"executor": {
|
||||
"name": "executor",
|
||||
"responsibility": "Validation (测试执行与修复)",
|
||||
"task_prefix": "QARUN-*",
|
||||
"description": "测试执行者。运行测试套件,收集覆盖率数据,失败时自动修复循环",
|
||||
"message_types_sent": ["tests_passed", "tests_failed", "coverage_report", "error"],
|
||||
"message_types_received": [],
|
||||
"commands": ["run-fix-cycle"],
|
||||
"cli_tools": ["gemini"]
|
||||
},
|
||||
"analyst": {
|
||||
"name": "analyst",
|
||||
"responsibility": "Read-only analysis (质量分析)",
|
||||
"task_prefix": "QAANA-*",
|
||||
"description": "质量分析师。分析缺陷模式、覆盖率差距、测试有效性,生成综合质量报告",
|
||||
"message_types_sent": ["analysis_ready", "quality_report", "error"],
|
||||
"message_types_received": [],
|
||||
"commands": ["quality-report"],
|
||||
"cli_tools": ["gemini"]
|
||||
}
|
||||
},
|
||||
|
||||
"pipeline_modes": {
|
||||
"discovery": {
|
||||
"description": "Scout先行扫描 → 全流程",
|
||||
"stages": ["SCOUT", "QASTRAT", "QAGEN", "QARUN", "QAANA"],
|
||||
"entry_role": "scout"
|
||||
},
|
||||
"testing": {
|
||||
"description": "跳过 Scout → 直接测试",
|
||||
"stages": ["QASTRAT", "QAGEN-L1", "QARUN-L1", "QAGEN-L2", "QARUN-L2", "QAANA"],
|
||||
"entry_role": "strategist"
|
||||
},
|
||||
"full": {
|
||||
"description": "完整 QA 闭环 + 回归扫描",
|
||||
"stages": ["SCOUT", "QASTRAT", "QAGEN-L1", "QAGEN-L2", "QARUN-L1", "QARUN-L2", "QAANA", "SCOUT-REG"],
|
||||
"entry_role": "scout",
|
||||
"parallel_stages": [["QAGEN-L1", "QAGEN-L2"], ["QARUN-L1", "QARUN-L2"]]
|
||||
}
|
||||
},
|
||||
|
||||
"gc_loop": {
|
||||
"max_iterations": 3,
|
||||
"trigger": "coverage < target",
|
||||
"participants": ["generator", "executor"],
|
||||
"flow": "QAGEN-fix → QARUN-gc → evaluate"
|
||||
},
|
||||
|
||||
"shared_memory": {
|
||||
"file": "shared-memory.json",
|
||||
"fields": {
|
||||
"discovered_issues": { "owner": "scout", "type": "array" },
|
||||
"test_strategy": { "owner": "strategist", "type": "object" },
|
||||
"generated_tests": { "owner": "generator", "type": "object" },
|
||||
"execution_results": { "owner": "executor", "type": "object" },
|
||||
"defect_patterns": { "owner": "analyst", "type": "array" },
|
||||
"coverage_history": { "owner": "analyst", "type": "array" },
|
||||
"quality_score": { "owner": "analyst", "type": "number" }
|
||||
}
|
||||
},
|
||||
|
||||
"collaboration_patterns": [
|
||||
"CP-1: Linear Pipeline (Discovery/Testing mode)",
|
||||
"CP-2: Review-Fix Cycle (GC loop: Generator ↔ Executor)",
|
||||
"CP-3: Fan-out (Scout multi-perspective scan)",
|
||||
"CP-5: Escalation (Worker → Coordinator → User)",
|
||||
"CP-9: Dual-Track (Full mode: L1 + L2 parallel)",
|
||||
"CP-10: Post-Mortem (Analyst quality report)"
|
||||
],
|
||||
|
||||
"session_directory": {
|
||||
"pattern": ".workflow/.team/QA-{slug}-{date}",
|
||||
"subdirectories": ["scan", "strategy", "results", "analysis"]
|
||||
},
|
||||
|
||||
"test_layers": {
|
||||
"L1": { "name": "Unit Tests", "default_target": 80 },
|
||||
"L2": { "name": "Integration Tests", "default_target": 60 },
|
||||
"L3": { "name": "E2E Tests", "default_target": 40 }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user