Orchestrate 8 specialized teammate agents for comprehensive code quality evaluation. Each agent is a plugin subagent — spawn them as teammates and aggregate their findings.
Agents
All agents are read-only — they analyze code and report findings via SendMessage.
the-crucible:namer— Naming: misleading, vague, type-encoded, scope-mismatched identifiersthe-crucible:complexity-reviewer— Complexity: nesting, flag arguments, duplication, premature abstractionthe-crucible:comment-reviewer— Comments: noise, staleness, refactoring signals, commented-out codethe-crucible:test-reviewer— Tests: false confidence, implementation coupling, flakiness, coverage gapsthe-crucible:error-handling-reviewer— Errors: silent swallowing, context loss, resource leaks, async error lossthe-crucible:security-reviewer— Security: injection, access control, secrets, crypto, data exposurethe-crucible:observability-reviewer— Observability: logging, metrics, tracing, cardinality, context propagationthe-crucible:docs-auditor— Documentation: missing API docs, stale docs, contract gaps
Workflow
Phase 0: Create Team
Create a review team and 8 tasks — one per agent:
TeamCreate(name="code-review")
For each agent in the table above:
TaskCreate(team_name="code-review", title="{agent_name}", description="Review {target}")
Phase 1: Spawn Reviewers
Spawn all 8 agents in parallel as teammates using their subagent_type. The agent files define each reviewer's
expertise, patterns, and constraints — the prompt parameter only needs to specify the target and team context:
For each agent:
Agent(
subagent_type="{subagent_type}",
prompt="Review all code in {target}. Send your findings to the leader via SendMessage.",
team_name="code-review",
task_id="{task_id}"
)
Phase 2: Aggregate and Present Findings
As teammates send messages, aggregate findings:
- Collect all messages from the 8 reviewers
- Deduplicate overlapping findings across agents
- Present to user organized by severity (Critical > Issues > Recommendations)
- Ask user which issues to address
Phase 3: Apply Fixes
Address findings based on user direction:
- Fix critical issues first, then issues, then recommendations
- User may skip categories or individual findings
- Continue until user says to stop or all addressed
Usage
Run code quality evaluation on src/auth/
Example interaction flow:
- User: "Run code quality evaluation on src/auth/"
- Create team "code-review" with 8 tasks
- Spawn 8 teammate agents by subagent_type
- Teammates send findings via messages
- Aggregate and present: "Found 2 critical, 5 issues, 3 recommendations. Which to address?"
- User picks categories or specific findings to fix
- Apply fixes iteratively