<!-- AUTO-GENERATED by scripts/gen-adapters.js - DO NOT EDIT -->
---
description: "Use when coordinating multi-agent review passes in /audit-project. Details agent specialization, file filtering, and review queue handling."
agent: general
---

> **OpenCode Note**: Invoke agents using `@agent-name` syntax.
> Available agents: task-discoverer, exploration-agent, planning-agent,
> implementation-agent, deslop-agent, delivery-validator, sync-docs-agent, consult-agent
> Example: `@exploration-agent analyze the codebase`


# Phase 2: Multi-Agent Review - Reference

This file contains detailed agent coordination for `/audit-project`.

**Parent document**: `audit-project.md`

**Review Pass Definitions**: See `orchestrate-review` skill for canonical pass definitions (core + conditional). This command uses the same review passes but detects signals from project structure (not just changed files).

## Agent Specialization

### File Filtering by Agent

Each agent reviews only relevant files:

| Agent | File Patterns |
|-------|--------------|
| code-quality-reviewer | All source files (includes error handling) |
| security-expert | Auth, validation, API endpoints, config |
| performance-engineer | Hot paths, algorithms, loops, queries |
| test-quality-guardian | Test files + missing-test signals |
| architecture-reviewer | Cross-module boundaries, core packages |
| database-specialist | Models, queries, migrations |
| api-designer | API routes, controllers, handlers |
| frontend-specialist | Components, state management |
| backend-specialist | Services, domain logic, queues |
| devops-reviewer | CI/CD configs, Dockerfiles |

## Review Queue File

Create a temporary review queue file in the platform state dir. Review passes append JSONL or return JSON for the parent to write.

*(JavaScript reference - not executable in OpenCode)*

## Agent Coordination

Use Task tool to launch agents in parallel:

- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent
- Invoke `@review` agent


## Finding Consolidation

After all agents complete:

*(JavaScript reference - not executable in OpenCode)*

## Queue Cleanup

After fixes and re-review, remove the queue file if no open issues remain:

*(JavaScript reference - not executable in OpenCode)*

## Framework-Specific Patterns

### React Patterns

*(JavaScript reference - not executable in OpenCode)*

### Express Patterns

*(JavaScript reference - not executable in OpenCode)*

### Django Patterns

*(JavaScript reference - not executable in OpenCode)*

## Pattern Application

*(JavaScript reference - not executable in OpenCode)*

## Review Output Format

```markdown
## Agent Reports

### security-expert
**Files Reviewed**: X
**Issues Found**: Y (Z critical, A high)

Findings:
1. [Finding details with file:line]
2. [Finding details with file:line]

### performance-engineer
**Files Reviewed**: X
**Issues Found**: Y

Findings:
1. [Finding details with file:line]

[... per agent]

## Consolidated Summary

**Total Issues**: X
- Critical: Y (must fix)
- High: Z (should fix)
- Medium: A (consider)
- Low: B (nice to have)

**Top Files by Issue Count**:
1. src/api/users.ts: 5 issues
2. src/auth/session.ts: 3 issues
```
